From eb35ac1a390d543a0c5060a866b50330f4569529 Mon Sep 17 00:00:00 2001 From: Owl Bot Date: Tue, 9 Jun 2026 10:04:02 +0000 Subject: [PATCH 1/2] feat: update cloud ml ces v1beta client libraries docs: Update comments for `audio_recording_config` and `bigquery_export_settings` in `LoggingSettings`. docs: Update comments for various `InputType` enum values. docs: Update comments for `root_span`, `turns`, and `max_turns` in `Evaluation`. PiperOrigin-RevId: 928656124 fix(php): remove abandoned deps docs(php): fix mulitline phpdoc for mixins PiperOrigin-RevId: 928824112 Source-Link: https://github.com/googleapis/googleapis/commit/bf6e4c7affb3da976ee6a97ea1c542952b493205 Source-Link: https://github.com/googleapis/googleapis-gen/commit/545de85fd686033c97c075ad8b82e38604f11789 Copy-Tag: eyJwIjoiU2VjdXJpdHlQcml2YXRlQ2EvLk93bEJvdC55YW1sIiwiaCI6IjU0NWRlODVmZDY4NjAzM2M5N2MwNzVhZDhiODJlMzg2MDRmMTE3ODkifQ== Copy-Tag: eyJwIjoiU2VydmljZU1hbmFnZW1lbnQvLk93bEJvdC55YW1sIiwiaCI6IjU0NWRlODVmZDY4NjAzM2M5N2MwNzVhZDhiODJlMzg2MDRmMTE3ODkifQ== Copy-Tag: eyJwIjoiU3BlZWNoLy5Pd2xCb3QueWFtbCIsImgiOiI1NDVkZTg1ZmQ2ODYwMzNjOTdjMDc1YWQ4YjgyZTM4NjA0ZjExNzg5In0= Copy-Tag: eyJwIjoiVmVjdG9yU2VhcmNoLy5Pd2xCb3QueWFtbCIsImgiOiI1NDVkZTg1ZmQ2ODYwMzNjOTdjMDc1YWQ4YjgyZTM4NjA0ZjExNzg5In0= Copy-Tag: eyJwIjoiVm13YXJlRW5naW5lLy5Pd2xCb3QueWFtbCIsImgiOiI1NDVkZTg1ZmQ2ODYwMzNjOTdjMDc1YWQ4YjgyZTM4NjA0ZjExNzg5In0= Copy-Tag: eyJwIjoiV29ya2xvYWRNYW5hZ2VyLy5Pd2xCb3QueWFtbCIsImgiOiI1NDVkZTg1ZmQ2ODYwMzNjOTdjMDc1YWQ4YjgyZTM4NjA0ZjExNzg5In0= --- .../Cloud/Security/Privateca/V1/Resources.php | 29 + .../Cloud/Security/Privateca/V1/Service.php | 34 + .../ActivateCertificateAuthorityRequest.php | 252 + .../Security/PrivateCA/V1/AttributeType.php | 104 + .../PrivateCA/V1/AttributeTypeAndValue.php | 144 + .../Cloud/Security/PrivateCA/V1/CaPool.php | 341 + .../PrivateCA/V1/CaPool/IssuancePolicy.php | 602 ++ .../CaPool/IssuancePolicy/AllowedKeyType.php | 113 + .../AllowedKeyType/EcKeyType.php | 73 + .../EcKeyType/EcSignatureAlgorithm.php | 74 + .../AllowedKeyType/RsaKeyType.php | 119 + .../CaPool/IssuancePolicy/IssuanceModes.php | 124 + .../PrivateCA/V1/CaPool/PublishingOptions.php | 209 + .../PublishingOptions/EncodingFormat.php | 65 + .../Security/PrivateCA/V1/CaPool/Tier.php | 62 + .../Security/PrivateCA/V1/Certificate.php | 755 ++ .../V1/Certificate/RevocationDetails.php | 128 + .../PrivateCA/V1/CertificateAuthority.php | 1038 ++ .../V1/CertificateAuthority/AccessUrls.php | 127 + .../CertificateAuthority/KeyVersionSpec.php | 128 + .../SignHashAlgorithm.php | 111 + .../V1/CertificateAuthority/State.php | 108 + .../V1/CertificateAuthority/Type.php | 65 + .../UserDefinedAccessUrls.php | 142 + .../PrivateCA/V1/CertificateConfig.php | 259 + .../PrivateCA/V1/CertificateConfig/KeyId.php | 72 + .../V1/CertificateConfig/SubjectConfig.php | 126 + .../PrivateCA/V1/CertificateDescription.php | 438 + .../CertificateFingerprint.php | 67 + .../V1/CertificateDescription/KeyId.php | 72 + .../SubjectDescription.php | 304 + .../V1/CertificateExtensionConstraints.php | 122 + .../KnownCertificateExtension.php | 120 + .../V1/CertificateIdentityConstraints.php | 216 + .../V1/CertificateRevocationList.php | 448 + .../RevokedCertificate.php | 156 + .../V1/CertificateRevocationList/State.php | 67 + .../PrivateCA/V1/CertificateTemplate.php | 593 ++ .../PrivateCA/V1/CreateCaPoolRequest.php | 258 + .../V1/CreateCertificateAuthorityRequest.php | 268 + .../PrivateCA/V1/CreateCertificateRequest.php | 451 + .../V1/CreateCertificateTemplateRequest.php | 263 + .../PrivateCA/V1/DeleteCaPoolRequest.php | 212 + .../V1/DeleteCertificateAuthorityRequest.php | 292 + .../V1/DeleteCertificateTemplateRequest.php | 166 + .../V1/DisableCertificateAuthorityRequest.php | 212 + .../V1/EnableCertificateAuthorityRequest.php | 166 + .../Security/PrivateCA/V1/EncryptionSpec.php | 71 + .../PrivateCA/V1/FetchCaCertsRequest.php | 166 + .../PrivateCA/V1/FetchCaCertsResponse.php | 76 + .../V1/FetchCaCertsResponse/CertChain.php | 65 + .../FetchCertificateAuthorityCsrRequest.php | 92 + .../FetchCertificateAuthorityCsrResponse.php | 68 + .../PrivateCA/V1/GetCaPoolRequest.php | 87 + .../V1/GetCertificateAuthorityRequest.php | 97 + .../PrivateCA/V1/GetCertificateRequest.php | 92 + .../GetCertificateRevocationListRequest.php | 102 + .../V1/GetCertificateTemplateRequest.php | 97 + .../Cloud/Security/PrivateCA/V1/KeyUsage.php | 164 + .../V1/KeyUsage/ExtendedKeyUsageOptions.php | 263 + .../PrivateCA/V1/KeyUsage/KeyUsageOptions.php | 345 + .../PrivateCA/V1/ListCaPoolsRequest.php | 256 + .../PrivateCA/V1/ListCaPoolsResponse.php | 144 + .../V1/ListCertificateAuthoritiesRequest.php | 265 + .../V1/ListCertificateAuthoritiesResponse.php | 148 + .../ListCertificateRevocationListsRequest.php | 260 + ...ListCertificateRevocationListsResponse.php | 148 + .../V1/ListCertificateTemplatesRequest.php | 260 + .../V1/ListCertificateTemplatesResponse.php | 148 + .../PrivateCA/V1/ListCertificatesRequest.php | 313 + .../PrivateCA/V1/ListCertificatesResponse.php | 144 + .../Cloud/Security/PrivateCA/V1/ObjectId.php | 73 + .../PrivateCA/V1/OperationMetadata.php | 311 + .../Cloud/Security/PrivateCA/V1/PublicKey.php | 106 + .../PrivateCA/V1/PublicKey/KeyFormat.php | 67 + .../V1/RelativeDistinguishedName.php | 69 + .../PrivateCA/V1/RevocationReason.php | 122 + .../PrivateCA/V1/RevokeCertificateRequest.php | 208 + .../Cloud/Security/PrivateCA/V1/Subject.php | 340 + .../Security/PrivateCA/V1/SubjectAltNames.php | 214 + .../PrivateCA/V1/SubjectRequestMode.php | 96 + .../PrivateCA/V1/SubordinateConfig.php | 135 + .../SubordinateConfigChain.php | 68 + .../UndeleteCertificateAuthorityRequest.php | 166 + .../PrivateCA/V1/UpdateCaPoolRequest.php | 216 + .../V1/UpdateCertificateAuthorityRequest.php | 221 + .../PrivateCA/V1/UpdateCertificateRequest.php | 216 + ...UpdateCertificateRevocationListRequest.php | 221 + .../V1/UpdateCertificateTemplateRequest.php | 221 + .../Security/PrivateCA/V1/X509Extension.php | 155 + .../Security/PrivateCA/V1/X509Parameters.php | 302 + .../PrivateCA/V1/X509Parameters/CaOptions.php | 146 + .../V1/X509Parameters/NameConstraints.php | 436 + .../activate_certificate_authority.php | 128 + .../create_ca_pool.php | 97 + .../create_certificate.php | 85 + .../create_certificate_authority.php | 127 + .../create_certificate_template.php | 95 + .../delete_ca_pool.php | 86 + .../delete_certificate_authority.php | 91 + .../delete_certificate_template.php | 87 + .../disable_certificate_authority.php | 91 + .../enable_certificate_authority.php | 91 + .../fetch_ca_certs.php | 80 + .../fetch_certificate_authority_csr.php | 88 + .../get_ca_pool.php | 76 + .../get_certificate.php | 78 + .../get_certificate_authority.php | 80 + .../get_certificate_revocation_list.php | 82 + .../get_certificate_template.php | 79 + .../get_iam_policy.php | 72 + .../get_location.php | 57 + .../list_ca_pools.php | 78 + .../list_certificate_authorities.php | 84 + .../list_certificate_revocation_lists.php | 84 + .../list_certificate_templates.php | 79 + .../list_certificates.php | 91 + .../list_locations.php | 77 + .../revoke_certificate.php | 84 + .../set_iam_policy.php | 77 + .../test_iam_permissions.php | 84 + .../undelete_certificate_authority.php | 92 + .../update_ca_pool.php | 90 + .../update_certificate.php | 67 + .../update_certificate_authority.php | 107 + .../update_certificate_revocation_list.php | 75 + .../update_certificate_template.php | 75 + .../CertificateAuthorityServiceClient.php | 1458 +++ .../v1/src/V1/gapic_metadata.json | 188 + ...icate_authority_service_client_config.json | 206 + ...te_authority_service_descriptor_config.php | 600 ++ ...e_authority_service_rest_client_config.php | 534 ++ .../CertificateAuthorityServiceClientTest.php | 3513 +++++++ .../Api/Servicemanagement/V1/Resources.php | 27 + .../Servicemanagement/V1/Servicemanager.php | 32 + .../ServiceManagement/V1/ChangeReport.php | 85 + .../Cloud/ServiceManagement/V1/ConfigFile.php | 135 + .../V1/ConfigFile/FileType.php | 88 + .../Cloud/ServiceManagement/V1/ConfigRef.php | 71 + .../ServiceManagement/V1/ConfigSource.php | 114 + .../V1/CreateServiceConfigRequest.php | 136 + .../V1/CreateServiceRequest.php | 90 + .../V1/CreateServiceRolloutRequest.php | 136 + .../V1/DeleteServiceRequest.php | 90 + .../Cloud/ServiceManagement/V1/Diagnostic.php | 135 + .../ServiceManagement/V1/Diagnostic/Kind.php | 54 + .../V1/EnableServiceResponse.php | 33 + .../V1/GenerateConfigReportRequest.php | 176 + .../V1/GenerateConfigReportResponse.php | 181 + .../V1/GetServiceConfigRequest.php | 179 + .../V1/GetServiceConfigRequest/ConfigView.php | 55 + .../V1/GetServiceRequest.php | 85 + .../V1/GetServiceRolloutRequest.php | 126 + .../V1/ListServiceConfigsRequest.php | 162 + .../V1/ListServiceConfigsResponse.php | 101 + .../V1/ListServiceRolloutsRequest.php | 235 + .../V1/ListServiceRolloutsResponse.php | 101 + .../V1/ListServicesRequest.php | 215 + .../V1/ListServicesResponse.php | 101 + .../ServiceManagement/V1/ManagedService.php | 110 + .../V1/OperationMetadata.php | 183 + .../V1/OperationMetadata/Status.php | 83 + .../V1/OperationMetadata/Step.php | 101 + .../Cloud/ServiceManagement/V1/Rollout.php | 332 + .../V1/Rollout/DeleteServiceStrategy.php | 34 + .../V1/Rollout/RolloutStatus.php | 91 + .../V1/Rollout/TrafficPercentStrategy.php | 100 + .../V1/SubmitConfigSourceRequest.php | 182 + .../V1/SubmitConfigSourceResponse.php | 77 + .../V1/UndeleteServiceRequest.php | 90 + .../V1/UndeleteServiceResponse.php | 77 + .../ServiceManagerClient/create_service.php | 81 + .../create_service_config.php | 81 + .../create_service_rollout.php | 99 + .../ServiceManagerClient/delete_service.php | 88 + .../generate_config_report.php | 70 + .../ServiceManagerClient/get_iam_policy.php | 72 + .../V1/ServiceManagerClient/get_service.php | 72 + .../get_service_config.php | 78 + .../get_service_rollout.php | 76 + .../list_service_configs.php | 78 + .../list_service_rollouts.php | 90 + .../V1/ServiceManagerClient/list_services.php | 66 + .../ServiceManagerClient/set_iam_policy.php | 77 + .../submit_config_source.php | 100 + .../test_iam_permissions.php | 84 + .../ServiceManagerClient/undelete_service.php | 89 + .../v1/src/V1/Client/ServiceManagerClient.php | 775 ++ .../v1/src/V1/gapic_metadata.json | 98 + .../service_manager_client_config.json | 112 + .../service_manager_descriptor_config.php | 270 + .../service_manager_rest_client_config.php | 240 + .../V1/Client/ServiceManagerClientTest.php | 1566 +++ .../Google/Cloud/Speech/V2/CloudSpeech.php | 34 + .../Cloud/Speech/V2/LocationsMetadata.php | 24 + .../Google/Cloud/Speech/V2/AccessMetadata.php | 68 + .../V2/AccessMetadata/ConstraintType.php | 55 + .../Speech/V2/AutoDetectDecodingConfig.php | 46 + .../Speech/V2/BatchRecognizeFileMetadata.php | 239 + .../Speech/V2/BatchRecognizeFileResult.php | 306 + .../Speech/V2/BatchRecognizeMetadata.php | 68 + .../Cloud/Speech/V2/BatchRecognizeRequest.php | 394 + .../ProcessingStrategy.php | 56 + .../Speech/V2/BatchRecognizeResponse.php | 113 + .../Cloud/Speech/V2/BatchRecognizeResults.php | 117 + .../BatchRecognizeTranscriptionMetadata.php | 146 + .../Cloud/Speech/V2/CloudStorageResult.php | 143 + .../src/Google/Cloud/Speech/V2/Config.php | 175 + .../Speech/V2/CreateCustomClassRequest.php | 223 + .../Speech/V2/CreatePhraseSetRequest.php | 223 + .../Speech/V2/CreateRecognizerRequest.php | 223 + .../Google/Cloud/Speech/V2/CustomClass.php | 607 ++ .../Cloud/Speech/V2/CustomClass/ClassItem.php | 67 + .../Cloud/Speech/V2/CustomClass/State.php | 62 + .../Cloud/Speech/V2/CustomPromptConfig.php | 71 + .../Speech/V2/DeleteCustomClassRequest.php | 210 + .../Speech/V2/DeletePhraseSetRequest.php | 205 + .../Speech/V2/DeleteRecognizerRequest.php | 205 + .../Google/Cloud/Speech/V2/DenoiserConfig.php | 118 + .../Speech/V2/ExplicitDecodingConfig.php | 167 + .../ExplicitDecodingConfig/AudioEncoding.php | 131 + .../Cloud/Speech/V2/GcsOutputConfig.php | 71 + .../Cloud/Speech/V2/GetConfigRequest.php | 92 + .../Cloud/Speech/V2/GetCustomClassRequest.php | 87 + .../Cloud/Speech/V2/GetPhraseSetRequest.php | 87 + .../Cloud/Speech/V2/GetRecognizerRequest.php | 87 + .../Cloud/Speech/V2/InlineOutputConfig.php | 33 + .../Google/Cloud/Speech/V2/InlineResult.php | 153 + .../Cloud/Speech/V2/LanguageMetadata.php | 68 + .../Speech/V2/ListCustomClassesRequest.php | 221 + .../Speech/V2/ListCustomClassesResponse.php | 114 + .../Cloud/Speech/V2/ListPhraseSetsRequest.php | 217 + .../Speech/V2/ListPhraseSetsResponse.php | 114 + .../Speech/V2/ListRecognizersRequest.php | 217 + .../Speech/V2/ListRecognizersResponse.php | 114 + .../Cloud/Speech/V2/LocationsMetadata.php | 126 + .../Google/Cloud/Speech/V2/ModelFeature.php | 102 + .../Google/Cloud/Speech/V2/ModelFeatures.php | 67 + .../Google/Cloud/Speech/V2/ModelMetadata.php | 68 + .../V2/NativeOutputFileFormatConfig.php | 33 + .../Cloud/Speech/V2/OperationMetadata.php | 841 ++ .../Cloud/Speech/V2/OutputFormatConfig.php | 181 + .../src/Google/Cloud/Speech/V2/PhraseSet.php | 657 ++ .../Cloud/Speech/V2/PhraseSet/Phrase.php | 143 + .../Cloud/Speech/V2/PhraseSet/State.php | 62 + .../Cloud/Speech/V2/RecognitionConfig.php | 487 + .../Cloud/Speech/V2/RecognitionFeatures.php | 473 + .../RecognitionFeatures/MultiChannelMode.php | 58 + .../Speech/V2/RecognitionOutputConfig.php | 171 + .../Speech/V2/RecognitionResponseMetadata.php | 159 + .../Cloud/Speech/V2/RecognizeRequest.php | 434 + .../Cloud/Speech/V2/RecognizeResponse.php | 116 + .../src/Google/Cloud/Speech/V2/Recognizer.php | 799 ++ .../Cloud/Speech/V2/Recognizer/State.php | 61 + .../Speech/V2/SpeakerDiarizationConfig.php | 109 + .../Cloud/Speech/V2/SpeechAdaptation.php | 107 + .../SpeechAdaptation/AdaptationPhraseSet.php | 112 + .../V2/SpeechRecognitionAlternative.php | 175 + .../Speech/V2/SpeechRecognitionResult.php | 211 + .../Speech/V2/SrtOutputFileFormatConfig.php | 35 + .../Speech/V2/StreamingRecognitionConfig.php | 237 + .../V2/StreamingRecognitionFeatures.php | 199 + .../EndpointingSensitivity.php | 75 + .../VoiceActivityTimeout.php | 137 + .../Speech/V2/StreamingRecognitionResult.php | 320 + .../Speech/V2/StreamingRecognizeRequest.php | 180 + .../Speech/V2/StreamingRecognizeResponse.php | 247 + .../SpeechEventType.php | 79 + .../Speech/V2/TranscriptNormalization.php | 82 + .../V2/TranscriptNormalization/Entry.php | 135 + .../Cloud/Speech/V2/TranslationConfig.php | 68 + .../Speech/V2/UndeleteCustomClassRequest.php | 173 + .../Speech/V2/UndeletePhraseSetRequest.php | 168 + .../Speech/V2/UndeleteRecognizerRequest.php | 168 + .../Cloud/Speech/V2/UpdateConfigRequest.php | 148 + .../Speech/V2/UpdateCustomClassRequest.php | 196 + .../Speech/V2/UpdatePhraseSetRequest.php | 191 + .../Speech/V2/UpdateRecognizerRequest.php | 191 + .../Speech/V2/VttOutputFileFormatConfig.php | 34 + .../src/Google/Cloud/Speech/V2/WordInfo.php | 307 + .../V2/SpeechClient/batch_recognize.php | 88 + .../V2/SpeechClient/create_custom_class.php | 86 + .../V2/SpeechClient/create_phrase_set.php | 86 + .../V2/SpeechClient/create_recognizer.php | 86 + .../V2/SpeechClient/delete_custom_class.php | 85 + .../V2/SpeechClient/delete_phrase_set.php | 84 + .../V2/SpeechClient/delete_recognizer.php | 84 + .../v2/samples/V2/SpeechClient/get_config.php | 73 + .../V2/SpeechClient/get_custom_class.php | 73 + .../samples/V2/SpeechClient/get_location.php | 57 + .../V2/SpeechClient/get_phrase_set.php | 73 + .../V2/SpeechClient/get_recognizer.php | 75 + .../V2/SpeechClient/list_custom_classes.php | 77 + .../V2/SpeechClient/list_locations.php | 69 + .../V2/SpeechClient/list_phrase_sets.php | 77 + .../V2/SpeechClient/list_recognizers.php | 77 + .../v2/samples/V2/SpeechClient/recognize.php | 75 + .../V2/SpeechClient/streaming_recognize.php | 81 + .../V2/SpeechClient/undelete_custom_class.php | 85 + .../V2/SpeechClient/undelete_phrase_set.php | 84 + .../V2/SpeechClient/undelete_recognizer.php | 84 + .../samples/V2/SpeechClient/update_config.php | 59 + .../V2/SpeechClient/update_custom_class.php | 71 + .../V2/SpeechClient/update_phrase_set.php | 71 + .../V2/SpeechClient/update_recognizer.php | 71 + .../Speech/v2/src/V2/Client/SpeechClient.php | 1120 +++ .../Speech/v2/src/V2/gapic_metadata.json | 143 + .../V2/resources/speech_client_config.json | 158 + .../V2/resources/speech_descriptor_config.php | 461 + .../resources/speech_rest_client_config.php | 358 + .../tests/Unit/V2/Client/SpeechClientTest.php | 2801 ++++++ .../Google/Cloud/Vectorsearch/V1/Common.php | 24 + .../Cloud/Vectorsearch/V1/DataObject.php | 28 + .../V1/DataObjectSearchService.php | 32 + .../Vectorsearch/V1/DataObjectService.php | 31 + .../Cloud/Vectorsearch/V1/EmbeddingConfig.php | 25 + .../Cloud/Vectorsearch/V1/EncryptionSpec.php | 26 + .../Vectorsearch/V1/VectorsearchService.php | 38 + .../V1/AggregateDataObjectsRequest.php | 154 + .../V1/AggregateDataObjectsResponse.php | 68 + .../VectorSearch/V1/AggregationMethod.php | 54 + .../V1/BatchCreateDataObjectsRequest.php | 118 + .../V1/BatchCreateDataObjectsResponse.php | 68 + .../V1/BatchDeleteDataObjectsRequest.php | 128 + .../V1/BatchSearchDataObjectsRequest.php | 149 + .../CombineResultsOptions.php | 159 + .../V1/BatchSearchDataObjectsResponse.php | 71 + .../V1/BatchUpdateDataObjectsRequest.php | 138 + .../V1/BatchUpdateDataObjectsResponse.php | 34 + .../Cloud/VectorSearch/V1/Collection.php | 411 + .../V1/CreateCollectionRequest.php | 257 + .../V1/CreateDataObjectRequest.php | 189 + .../VectorSearch/V1/CreateIndexRequest.php | 267 + .../Cloud/VectorSearch/V1/DataObject.php | 317 + .../V1/DedicatedInfrastructure.php | 121 + .../AutoscalingSpec.php | 125 + .../V1/DedicatedInfrastructure/Mode.php | 61 + .../V1/DeleteCollectionRequest.php | 155 + .../V1/DeleteDataObjectRequest.php | 134 + .../VectorSearch/V1/DeleteIndexRequest.php | 165 + .../Cloud/VectorSearch/V1/DenseScannIndex.php | 67 + .../V1/DenseScannIndex/FeatureNormType.php | 61 + .../Cloud/VectorSearch/V1/DenseVector.php | 67 + .../VectorSearch/V1/DenseVectorField.php | 115 + .../Cloud/VectorSearch/V1/DistanceMetric.php | 61 + .../VectorSearch/V1/EmbeddingTaskType.php | 103 + .../Cloud/VectorSearch/V1/EncryptionSpec.php | 80 + .../V1/ExportDataObjectsMetadata.php | 121 + .../V1/ExportDataObjectsRequest.php | 118 + .../GcsExportDestination.php | 105 + .../GcsExportDestination/Format.php | 54 + .../V1/ExportDataObjectsResponse.php | 33 + .../VectorSearch/V1/GetCollectionRequest.php | 81 + .../VectorSearch/V1/GetDataObjectRequest.php | 92 + .../Cloud/VectorSearch/V1/GetIndexRequest.php | 81 + .../V1/ImportDataObjectsMetadata.php | 190 + .../V1/ImportDataObjectsRequest.php | 114 + .../GcsImportConfig.php | 151 + .../V1/ImportDataObjectsResponse.php | 78 + .../Google/Cloud/VectorSearch/V1/Index.php | 489 + .../V1/ListCollectionsRequest.php | 221 + .../V1/ListCollectionsResponse.php | 135 + .../VectorSearch/V1/ListIndexesRequest.php | 221 + .../VectorSearch/V1/ListIndexesResponse.php | 101 + .../VectorSearch/V1/OperationMetadata.php | 311 + .../Cloud/VectorSearch/V1/OutputFields.php | 135 + .../V1/QueryDataObjectsRequest.php | 256 + .../V1/QueryDataObjectsResponse.php | 110 + .../Google/Cloud/VectorSearch/V1/Ranker.php | 75 + .../VectorSearch/V1/ReciprocalRankFusion.php | 67 + .../Google/Cloud/VectorSearch/V1/Search.php | 141 + .../V1/SearchDataObjectsRequest.php | 275 + .../V1/SearchDataObjectsResponse.php | 109 + .../Cloud/VectorSearch/V1/SearchHint.php | 111 + .../VectorSearch/V1/SearchHint/IndexHint.php | 79 + .../VectorSearch/V1/SearchHint/KnnHint.php | 34 + .../Cloud/VectorSearch/V1/SearchResult.php | 125 + .../Cloud/VectorSearch/V1/SemanticSearch.php | 327 + .../Cloud/VectorSearch/V1/SparseVector.php | 101 + .../VectorSearch/V1/SparseVectorField.php | 33 + .../Cloud/VectorSearch/V1/TextSearch.php | 237 + .../V1/UpdateCollectionRequest.php | 282 + .../V1/UpdateDataObjectRequest.php | 142 + .../VectorSearch/V1/UpdateIndexRequest.php | 272 + .../Google/Cloud/VectorSearch/V1/Vector.php | 108 + .../Cloud/VectorSearch/V1/VectorField.php | 108 + .../Cloud/VectorSearch/V1/VectorSearch.php | 368 + .../VectorSearch/V1/VertexEmbeddingConfig.php | 152 + .../aggregate_data_objects.php | 80 + .../batch_search_data_objects.php | 79 + .../get_location.php | 57 + .../list_locations.php | 78 + .../query_data_objects.php | 81 + .../search_data_objects.php | 81 + .../batch_create_data_objects.php | 104 + .../batch_delete_data_objects.php | 91 + .../batch_update_data_objects.php | 85 + .../create_data_object.php | 85 + .../delete_data_object.php | 76 + .../get_data_object.php | 78 + .../DataObjectServiceClient/get_location.php | 57 + .../list_locations.php | 78 + .../update_data_object.php | 59 + .../create_collection.php | 92 + .../create_index.php | 104 + .../delete_collection.php | 84 + .../delete_index.php | 87 + .../export_data_objects.php | 89 + .../get_collection.php | 75 + .../VectorSearchServiceClient/get_index.php | 76 + .../get_location.php | 57 + .../import_data_objects.php | 88 + .../list_collections.php | 76 + .../list_indexes.php | 80 + .../list_locations.php | 78 + .../update_collection.php | 71 + .../update_index.php | 84 + .../Client/DataObjectSearchServiceClient.php | 441 + .../src/V1/Client/DataObjectServiceClient.php | 520 + .../V1/Client/VectorSearchServiceClient.php | 762 ++ .../v1/src/V1/gapic_metadata.json | 181 + ...a_object_search_service_client_config.json | 64 + ...bject_search_service_descriptor_config.php | 130 + ...ject_search_service_rest_client_config.php | 148 + .../data_object_service_client_config.json | 103 + .../data_object_service_descriptor_config.php | 151 + ...data_object_service_rest_client_config.php | 186 + .../vector_search_service_client_config.json | 116 + ...ector_search_service_descriptor_config.php | 286 + ...ctor_search_service_rest_client_config.php | 246 + .../DataObjectSearchServiceClientTest.php | 510 + .../V1/Client/DataObjectServiceClientTest.php | 710 ++ .../Client/VectorSearchServiceClientTest.php | 1599 ++++ .../Cloud/Vmwareengine/V1/Vmwareengine.php | 34 + .../Vmwareengine/V1/VmwareengineResources.php | 29 + .../VmwareEngine/V1/AutoscalingSettings.php | 240 + .../AutoscalingSettings/AutoscalingPolicy.php | 302 + .../V1/AutoscalingSettings/Thresholds.php | 102 + .../Google/Cloud/VmwareEngine/V1/Cluster.php | 411 + .../Cloud/VmwareEngine/V1/Cluster/State.php | 84 + .../VmwareEngine/V1/CreateClusterRequest.php | 306 + .../V1/CreateExternalAccessRuleRequest.php | 313 + .../V1/CreateExternalAddressRequest.php | 313 + .../V1/CreateHcxActivationKeyRequest.php | 313 + .../V1/CreateLoggingServerRequest.php | 313 + .../CreateManagementDnsZoneBindingRequest.php | 317 + .../V1/CreateNetworkPeeringRequest.php | 308 + .../V1/CreateNetworkPolicyRequest.php | 318 + .../V1/CreatePrivateCloudRequest.php | 306 + .../V1/CreatePrivateConnectionRequest.php | 308 + .../V1/CreateVmwareEngineNetworkRequest.php | 333 + .../Cloud/VmwareEngine/V1/Credentials.php | 101 + .../VmwareEngine/V1/DeleteClusterRequest.php | 140 + .../V1/DeleteExternalAccessRuleRequest.php | 180 + .../V1/DeleteExternalAddressRequest.php | 180 + .../V1/DeleteLoggingServerRequest.php | 180 + .../DeleteManagementDnsZoneBindingRequest.php | 180 + .../V1/DeleteNetworkPeeringRequest.php | 180 + .../V1/DeleteNetworkPolicyRequest.php | 180 + .../V1/DeletePrivateCloudRequest.php | 262 + .../V1/DeletePrivateConnectionRequest.php | 180 + .../V1/DeleteVmwareEngineNetworkRequest.php | 226 + .../VmwareEngine/V1/DnsBindPermission.php | 130 + .../Cloud/VmwareEngine/V1/DnsForwarding.php | 207 + .../V1/DnsForwarding/ForwardingRule.php | 104 + .../VmwareEngine/V1/ExternalAccessRule.php | 620 ++ .../V1/ExternalAccessRule/Action.php | 62 + .../V1/ExternalAccessRule/IpRange.php | 156 + .../V1/ExternalAccessRule/State.php | 75 + .../Cloud/VmwareEngine/V1/ExternalAddress.php | 342 + .../VmwareEngine/V1/ExternalAddress/State.php | 75 + ...hNetworkPolicyExternalAddressesRequest.php | 202 + ...NetworkPolicyExternalAddressesResponse.php | 110 + .../VmwareEngine/V1/GetClusterRequest.php | 102 + .../V1/GetDnsBindPermissionRequest.php | 107 + .../V1/GetDnsForwardingRequest.php | 102 + .../V1/GetExternalAccessRuleRequest.php | 102 + .../V1/GetExternalAddressRequest.php | 102 + .../V1/GetHcxActivationKeyRequest.php | 101 + .../V1/GetLoggingServerRequest.php | 102 + .../V1/GetManagementDnsZoneBindingRequest.php | 102 + .../V1/GetNetworkPeeringRequest.php | 102 + .../V1/GetNetworkPolicyRequest.php | 102 + .../Cloud/VmwareEngine/V1/GetNodeRequest.php | 92 + .../VmwareEngine/V1/GetNodeTypeRequest.php | 102 + .../V1/GetPrivateCloudRequest.php | 102 + .../V1/GetPrivateConnectionRequest.php | 102 + .../VmwareEngine/V1/GetSubnetRequest.php | 102 + .../V1/GetVmwareEngineNetworkRequest.php | 102 + .../V1/GrantDnsBindPermissionRequest.php | 241 + .../src/Google/Cloud/VmwareEngine/V1/Hcx.php | 169 + .../Cloud/VmwareEngine/V1/Hcx/State.php | 68 + .../VmwareEngine/V1/HcxActivationKey.php | 236 + .../V1/HcxActivationKey/State.php | 68 + .../VmwareEngine/V1/ListClustersRequest.php | 322 + .../VmwareEngine/V1/ListClustersResponse.php | 144 + .../V1/ListExternalAccessRulesRequest.php | 366 + .../V1/ListExternalAccessRulesResponse.php | 144 + .../V1/ListExternalAddressesRequest.php | 367 + .../V1/ListExternalAddressesResponse.php | 144 + .../V1/ListHcxActivationKeysRequest.php | 203 + .../V1/ListHcxActivationKeysResponse.php | 144 + .../V1/ListLoggingServersRequest.php | 371 + .../V1/ListLoggingServersResponse.php | 144 + .../ListManagementDnsZoneBindingsRequest.php | 371 + .../ListManagementDnsZoneBindingsResponse.php | 144 + .../V1/ListNetworkPeeringsRequest.php | 357 + .../V1/ListNetworkPeeringsResponse.php | 140 + .../V1/ListNetworkPoliciesRequest.php | 361 + .../V1/ListNetworkPoliciesResponse.php | 144 + .../VmwareEngine/V1/ListNodeTypesRequest.php | 312 + .../VmwareEngine/V1/ListNodeTypesResponse.php | 144 + .../VmwareEngine/V1/ListNodesRequest.php | 198 + .../VmwareEngine/V1/ListNodesResponse.php | 106 + .../V1/ListPeeringRoutesRequest.php | 239 + .../V1/ListPeeringRoutesResponse.php | 106 + .../V1/ListPrivateCloudsRequest.php | 362 + .../V1/ListPrivateCloudsResponse.php | 144 + ...tPrivateConnectionPeeringRoutesRequest.php | 189 + ...PrivateConnectionPeeringRoutesResponse.php | 106 + .../V1/ListPrivateConnectionsRequest.php | 357 + .../V1/ListPrivateConnectionsResponse.php | 140 + .../VmwareEngine/V1/ListSubnetsRequest.php | 199 + .../VmwareEngine/V1/ListSubnetsResponse.php | 144 + .../V1/ListVmwareEngineNetworksRequest.php | 357 + .../V1/ListVmwareEngineNetworksResponse.php | 140 + .../VmwareEngine/V1/LocationMetadata.php | 69 + .../V1/LocationMetadata/Capability.php | 55 + .../Cloud/VmwareEngine/V1/LoggingServer.php | 349 + .../V1/LoggingServer/Protocol.php | 83 + .../V1/LoggingServer/SourceType.php | 61 + .../V1/ManagementDnsZoneBinding.php | 370 + .../V1/ManagementDnsZoneBinding/State.php | 83 + .../Cloud/VmwareEngine/V1/NetworkConfig.php | 260 + .../Cloud/VmwareEngine/V1/NetworkPeering.php | 775 ++ .../V1/NetworkPeering/PeerNetworkType.php | 101 + .../VmwareEngine/V1/NetworkPeering/State.php | 75 + .../Cloud/VmwareEngine/V1/NetworkPolicy.php | 470 + .../V1/NetworkPolicy/NetworkService.php | 109 + .../V1/NetworkPolicy/NetworkService/State.php | 69 + .../src/Google/Cloud/VmwareEngine/V1/Node.php | 299 + .../Cloud/VmwareEngine/V1/Node/State.php | 75 + .../Google/Cloud/VmwareEngine/V1/NodeType.php | 439 + .../VmwareEngine/V1/NodeType/Capability.php | 55 + .../Cloud/VmwareEngine/V1/NodeType/Kind.php | 61 + .../Cloud/VmwareEngine/V1/NodeTypeConfig.php | 113 + .../src/Google/Cloud/VmwareEngine/V1/Nsx.php | 169 + .../Cloud/VmwareEngine/V1/Nsx/State.php | 61 + .../VmwareEngine/V1/OperationMetadata.php | 311 + .../Cloud/VmwareEngine/V1/PeeringRoute.php | 273 + .../V1/PeeringRoute/Direction.php | 61 + .../VmwareEngine/V1/PeeringRoute/Type.php | 69 + .../Cloud/VmwareEngine/V1/Principal.php | 109 + .../Cloud/VmwareEngine/V1/PrivateCloud.php | 637 ++ .../V1/PrivateCloud/ManagementCluster.php | 181 + .../VmwareEngine/V1/PrivateCloud/State.php | 91 + .../VmwareEngine/V1/PrivateCloud/Type.php | 65 + .../VmwareEngine/V1/PrivateConnection.php | 604 ++ .../V1/PrivateConnection/PeeringState.php | 63 + .../V1/PrivateConnection/RoutingMode.php | 65 + .../V1/PrivateConnection/State.php | 90 + .../V1/PrivateConnection/Type.php | 76 + .../RepairManagementDnsZoneBindingRequest.php | 179 + .../V1/ResetNsxCredentialsRequest.php | 185 + .../V1/ResetVcenterCredentialsRequest.php | 251 + .../V1/RevokeDnsBindPermissionRequest.php | 241 + .../V1/ShowNsxCredentialsRequest.php | 107 + .../V1/ShowVcenterCredentialsRequest.php | 177 + .../V1/StretchedClusterConfig.php | 133 + .../Google/Cloud/VmwareEngine/V1/Subnet.php | 262 + .../Cloud/VmwareEngine/V1/Subnet/State.php | 90 + .../V1/UndeletePrivateCloudRequest.php | 140 + .../VmwareEngine/V1/UpdateClusterRequest.php | 233 + .../V1/UpdateDnsForwardingRequest.php | 235 + .../V1/UpdateExternalAccessRuleRequest.php | 235 + .../V1/UpdateExternalAddressRequest.php | 235 + .../V1/UpdateLoggingServerRequest.php | 235 + .../UpdateManagementDnsZoneBindingRequest.php | 235 + .../V1/UpdateNetworkPeeringRequest.php | 235 + .../V1/UpdateNetworkPolicyRequest.php | 235 + .../V1/UpdatePrivateCloudRequest.php | 195 + .../V1/UpdatePrivateConnectionRequest.php | 235 + .../VmwareEngine/V1/UpdateSubnetRequest.php | 157 + .../V1/UpdateVmwareEngineNetworkRequest.php | 240 + .../Google/Cloud/VmwareEngine/V1/Vcenter.php | 169 + .../Cloud/VmwareEngine/V1/Vcenter/State.php | 61 + .../VmwareEngine/V1/VmwareEngineNetwork.php | 396 + .../V1/VmwareEngineNetwork/State.php | 75 + .../V1/VmwareEngineNetwork/Type.php | 63 + .../V1/VmwareEngineNetwork/VpcNetwork.php | 114 + .../VmwareEngineNetwork/VpcNetwork/Type.php | 73 + .../V1/VmwareEngineClient/create_cluster.php | 111 + .../create_external_access_rule.php | 109 + .../create_external_address.php | 109 + .../create_hcx_activation_key.php | 108 + .../create_logging_server.php | 136 + .../create_management_dns_zone_binding.php | 116 + .../create_network_peering.php | 140 + .../create_network_policy.php | 115 + .../create_private_cloud.php | 139 + .../create_private_connection.php | 150 + .../create_vmware_engine_network.php | 118 + .../V1/VmwareEngineClient/delete_cluster.php | 92 + .../delete_external_access_rule.php | 89 + .../delete_external_address.php | 91 + .../delete_logging_server.php | 89 + .../delete_management_dns_zone_binding.php | 91 + .../delete_network_peering.php | 91 + .../delete_network_policy.php | 90 + .../delete_private_cloud.php | 101 + .../delete_private_connection.php | 90 + .../delete_vmware_engine_network.php | 91 + ...etch_network_policy_external_addresses.php | 85 + .../V1/VmwareEngineClient/get_cluster.php | 80 + .../get_dns_bind_permission.php | 78 + .../VmwareEngineClient/get_dns_forwarding.php | 79 + .../get_external_access_rule.php | 80 + .../get_external_address.php | 80 + .../get_hcx_activation_key.php | 80 + .../V1/VmwareEngineClient/get_iam_policy.php | 72 + .../V1/VmwareEngineClient/get_location.php | 57 + .../VmwareEngineClient/get_logging_server.php | 80 + .../get_management_dns_zone_binding.php | 80 + .../get_network_peering.php | 82 + .../VmwareEngineClient/get_network_policy.php | 79 + .../V1/VmwareEngineClient/get_node.php | 79 + .../V1/VmwareEngineClient/get_node_type.php | 75 + .../VmwareEngineClient/get_private_cloud.php | 75 + .../get_private_connection.php | 81 + .../V1/VmwareEngineClient/get_subnet.php | 80 + .../get_vmware_engine_network.php | 82 + .../grant_dns_bind_permission.php | 94 + .../V1/VmwareEngineClient/list_clusters.php | 84 + .../list_external_access_rules.php | 84 + .../list_external_addresses.php | 86 + .../list_hcx_activation_keys.php | 85 + .../V1/VmwareEngineClient/list_locations.php | 62 + .../list_logging_servers.php | 86 + .../list_management_dns_zone_bindings.php | 85 + .../list_network_peerings.php | 80 + .../list_network_policies.php | 79 + .../V1/VmwareEngineClient/list_node_types.php | 80 + .../V1/VmwareEngineClient/list_nodes.php | 85 + .../list_peering_routes.php | 84 + .../list_private_clouds.php | 80 + ...list_private_connection_peering_routes.php | 83 + .../list_private_connections.php | 79 + .../V1/VmwareEngineClient/list_subnets.php | 85 + .../list_vmware_engine_networks.php | 79 + .../repair_management_dns_zone_binding.php | 93 + .../reset_nsx_credentials.php | 92 + .../reset_vcenter_credentials.php | 92 + .../revoke_dns_bind_permission.php | 93 + .../V1/VmwareEngineClient/set_iam_policy.php | 77 + .../show_nsx_credentials.php | 80 + .../show_vcenter_credentials.php | 80 + .../test_iam_permissions.php | 84 + .../undelete_private_cloud.php | 90 + .../V1/VmwareEngineClient/update_cluster.php | 82 + .../update_dns_forwarding.php | 101 + .../update_external_access_rule.php | 75 + .../update_external_address.php | 80 + .../update_logging_server.php | 110 + .../update_management_dns_zone_binding.php | 75 + .../update_network_peering.php | 118 + .../update_network_policy.php | 101 + .../update_private_cloud.php | 118 + .../update_private_connection.php | 129 + .../V1/VmwareEngineClient/update_subnet.php | 79 + .../update_vmware_engine_network.php | 90 + .../v1/src/V1/Client/VmwareEngineClient.php | 3013 ++++++ .../v1/src/V1/gapic_metadata.json | 413 + .../vmware_engine_client_config.json | 449 + .../vmware_engine_descriptor_config.php | 1430 +++ .../vmware_engine_rest_client_config.php | 1083 +++ .../Unit/V1/Client/VmwareEngineClientTest.php | 8496 +++++++++++++++++ .../Cloud/Workloadmanager/V1/Service.php | 32 + .../Cloud/WorkloadManager/V1/AgentCommand.php | 105 + .../V1/BigQueryDestination.php | 105 + .../Cloud/WorkloadManager/V1/Command.php | 111 + .../V1/CreateEvaluationRequest.php | 242 + .../V1/DeleteEvaluationRequest.php | 193 + .../V1/DeleteExecutionRequest.php | 155 + .../Cloud/WorkloadManager/V1/Evaluation.php | 597 ++ .../V1/Evaluation/EvaluationType.php | 68 + .../Cloud/WorkloadManager/V1/Execution.php | 523 + .../WorkloadManager/V1/Execution/Engine.php | 61 + .../V1/Execution/ExternalDataSources.php | 193 + .../V1/Execution/ExternalDataSources/Type.php | 54 + .../WorkloadManager/V1/Execution/Notice.php | 67 + .../WorkloadManager/V1/Execution/State.php | 68 + .../WorkloadManager/V1/Execution/Summary.php | 135 + .../WorkloadManager/V1/Execution/Type.php | 61 + .../WorkloadManager/V1/ExecutionResult.php | 325 + .../V1/ExecutionResult/Type.php | 61 + .../WorkloadManager/V1/GceInstanceFilter.php | 71 + .../V1/GetEvaluationRequest.php | 81 + .../V1/GetExecutionRequest.php | 81 + .../V1/ListEvaluationsRequest.php | 221 + .../V1/ListEvaluationsResponse.php | 135 + .../V1/ListExecutionResultsRequest.php | 191 + .../V1/ListExecutionResultsResponse.php | 105 + .../V1/ListExecutionsRequest.php | 226 + .../V1/ListExecutionsResponse.php | 135 + .../WorkloadManager/V1/ListRulesRequest.php | 274 + .../WorkloadManager/V1/ListRulesResponse.php | 67 + .../V1/ListScannedResourcesRequest.php | 254 + .../V1/ListScannedResourcesResponse.php | 105 + .../WorkloadManager/V1/OperationMetadata.php | 307 + .../Cloud/WorkloadManager/V1/Resource.php | 135 + .../WorkloadManager/V1/ResourceFilter.php | 216 + .../WorkloadManager/V1/ResourceStatus.php | 67 + .../V1/ResourceStatus/State.php | 69 + .../Google/Cloud/WorkloadManager/V1/Rule.php | 479 + .../WorkloadManager/V1/Rule/RuleType.php | 61 + .../V1/RuleExecutionResult.php | 203 + .../V1/RuleExecutionResult/State.php | 68 + .../Cloud/WorkloadManager/V1/RuleOutput.php | 101 + .../V1/RunEvaluationRequest.php | 242 + .../WorkloadManager/V1/ScannedResource.php | 101 + .../Cloud/WorkloadManager/V1/ShellCommand.php | 135 + .../V1/UpdateEvaluationRequest.php | 225 + .../WorkloadManager/V1/ViolationDetails.php | 169 + .../create_evaluation.php | 89 + .../delete_evaluation.php | 80 + .../delete_execution.php | 85 + .../WorkloadManagerClient/get_evaluation.php | 71 + .../WorkloadManagerClient/get_execution.php | 76 + .../V1/WorkloadManagerClient/get_location.php | 57 + .../list_evaluations.php | 76 + .../list_execution_results.php | 76 + .../WorkloadManagerClient/list_executions.php | 77 + .../WorkloadManagerClient/list_locations.php | 69 + .../V1/WorkloadManagerClient/list_rules.php | 74 + .../list_scanned_resources.php | 75 + .../WorkloadManagerClient/run_evaluation.php | 89 + .../update_evaluation.php | 74 + .../src/V1/Client/WorkloadManagerClient.php | 747 ++ .../v1/src/V1/gapic_metadata.json | 88 + .../workload_manager_client_config.json | 114 + .../workload_manager_descriptor_config.php | 280 + .../workload_manager_rest_client_config.php | 242 + .../V1/Client/WorkloadManagerClientTest.php | 1444 +++ 743 files changed, 141897 insertions(+) create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/GPBMetadata/Google/Cloud/Security/Privateca/V1/Resources.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/GPBMetadata/Google/Cloud/Security/Privateca/V1/Service.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ActivateCertificateAuthorityRequest.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/AttributeType.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/AttributeTypeAndValue.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy/AllowedKeyType.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy/AllowedKeyType/EcKeyType.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy/AllowedKeyType/EcKeyType/EcSignatureAlgorithm.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy/AllowedKeyType/RsaKeyType.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy/IssuanceModes.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/PublishingOptions.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/PublishingOptions/EncodingFormat.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/Tier.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/Certificate.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/Certificate/RevocationDetails.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/AccessUrls.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/KeyVersionSpec.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/SignHashAlgorithm.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/State.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/Type.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/UserDefinedAccessUrls.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateConfig.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateConfig/KeyId.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateConfig/SubjectConfig.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateDescription.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateDescription/CertificateFingerprint.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateDescription/KeyId.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateDescription/SubjectDescription.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateExtensionConstraints.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateExtensionConstraints/KnownCertificateExtension.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateIdentityConstraints.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateRevocationList.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateRevocationList/RevokedCertificate.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateRevocationList/State.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateTemplate.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CreateCaPoolRequest.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CreateCertificateAuthorityRequest.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CreateCertificateRequest.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CreateCertificateTemplateRequest.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/DeleteCaPoolRequest.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/DeleteCertificateAuthorityRequest.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/DeleteCertificateTemplateRequest.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/DisableCertificateAuthorityRequest.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/EnableCertificateAuthorityRequest.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/EncryptionSpec.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/FetchCaCertsRequest.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/FetchCaCertsResponse.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/FetchCaCertsResponse/CertChain.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/FetchCertificateAuthorityCsrRequest.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/FetchCertificateAuthorityCsrResponse.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/GetCaPoolRequest.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/GetCertificateAuthorityRequest.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/GetCertificateRequest.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/GetCertificateRevocationListRequest.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/GetCertificateTemplateRequest.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/KeyUsage.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/KeyUsage/ExtendedKeyUsageOptions.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/KeyUsage/KeyUsageOptions.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCaPoolsRequest.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCaPoolsResponse.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateAuthoritiesRequest.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateAuthoritiesResponse.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateRevocationListsRequest.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateRevocationListsResponse.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateTemplatesRequest.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateTemplatesResponse.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificatesRequest.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificatesResponse.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ObjectId.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/OperationMetadata.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/PublicKey.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/PublicKey/KeyFormat.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/RelativeDistinguishedName.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/RevocationReason.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/RevokeCertificateRequest.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/Subject.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/SubjectAltNames.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/SubjectRequestMode.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/SubordinateConfig.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/SubordinateConfig/SubordinateConfigChain.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UndeleteCertificateAuthorityRequest.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UpdateCaPoolRequest.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UpdateCertificateAuthorityRequest.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UpdateCertificateRequest.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UpdateCertificateRevocationListRequest.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UpdateCertificateTemplateRequest.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/X509Extension.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/X509Parameters.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/X509Parameters/CaOptions.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/X509Parameters/NameConstraints.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/activate_certificate_authority.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/create_ca_pool.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/create_certificate.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/create_certificate_authority.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/create_certificate_template.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/delete_ca_pool.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/delete_certificate_authority.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/delete_certificate_template.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/disable_certificate_authority.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/enable_certificate_authority.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/fetch_ca_certs.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/fetch_certificate_authority_csr.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_ca_pool.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_certificate.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_certificate_authority.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_certificate_revocation_list.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_certificate_template.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_iam_policy.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_location.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_ca_pools.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_certificate_authorities.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_certificate_revocation_lists.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_certificate_templates.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_certificates.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_locations.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/revoke_certificate.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/set_iam_policy.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/test_iam_permissions.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/undelete_certificate_authority.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/update_ca_pool.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/update_certificate.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/update_certificate_authority.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/update_certificate_revocation_list.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/update_certificate_template.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/src/V1/Client/CertificateAuthorityServiceClient.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/src/V1/gapic_metadata.json create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/src/V1/resources/certificate_authority_service_client_config.json create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/src/V1/resources/certificate_authority_service_descriptor_config.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/src/V1/resources/certificate_authority_service_rest_client_config.php create mode 100644 owl-bot-staging/SecurityPrivateCa/v1/tests/Unit/V1/Client/CertificateAuthorityServiceClientTest.php create mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/GPBMetadata/Google/Api/Servicemanagement/V1/Resources.php create mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/GPBMetadata/Google/Api/Servicemanagement/V1/Servicemanager.php create mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ChangeReport.php create mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ConfigFile.php create mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ConfigFile/FileType.php create mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ConfigRef.php create mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ConfigSource.php create mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/CreateServiceConfigRequest.php create mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/CreateServiceRequest.php create mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/CreateServiceRolloutRequest.php create mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/DeleteServiceRequest.php create mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Diagnostic.php create mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Diagnostic/Kind.php create mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/EnableServiceResponse.php create mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GenerateConfigReportRequest.php create mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GenerateConfigReportResponse.php create mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GetServiceConfigRequest.php create mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GetServiceConfigRequest/ConfigView.php create mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GetServiceRequest.php create mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GetServiceRolloutRequest.php create mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServiceConfigsRequest.php create mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServiceConfigsResponse.php create mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServiceRolloutsRequest.php create mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServiceRolloutsResponse.php create mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServicesRequest.php create mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServicesResponse.php create mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ManagedService.php create mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/OperationMetadata.php create mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/OperationMetadata/Status.php create mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/OperationMetadata/Step.php create mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Rollout.php create mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Rollout/DeleteServiceStrategy.php create mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Rollout/RolloutStatus.php create mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Rollout/TrafficPercentStrategy.php create mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/SubmitConfigSourceRequest.php create mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/SubmitConfigSourceResponse.php create mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/UndeleteServiceRequest.php create mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/UndeleteServiceResponse.php create mode 100644 owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/create_service.php create mode 100644 owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/create_service_config.php create mode 100644 owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/create_service_rollout.php create mode 100644 owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/delete_service.php create mode 100644 owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/generate_config_report.php create mode 100644 owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/get_iam_policy.php create mode 100644 owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/get_service.php create mode 100644 owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/get_service_config.php create mode 100644 owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/get_service_rollout.php create mode 100644 owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/list_service_configs.php create mode 100644 owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/list_service_rollouts.php create mode 100644 owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/list_services.php create mode 100644 owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/set_iam_policy.php create mode 100644 owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/submit_config_source.php create mode 100644 owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/test_iam_permissions.php create mode 100644 owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/undelete_service.php create mode 100644 owl-bot-staging/ServiceManagement/v1/src/V1/Client/ServiceManagerClient.php create mode 100644 owl-bot-staging/ServiceManagement/v1/src/V1/gapic_metadata.json create mode 100644 owl-bot-staging/ServiceManagement/v1/src/V1/resources/service_manager_client_config.json create mode 100644 owl-bot-staging/ServiceManagement/v1/src/V1/resources/service_manager_descriptor_config.php create mode 100644 owl-bot-staging/ServiceManagement/v1/src/V1/resources/service_manager_rest_client_config.php create mode 100644 owl-bot-staging/ServiceManagement/v1/tests/Unit/V1/Client/ServiceManagerClientTest.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/GPBMetadata/Google/Cloud/Speech/V2/CloudSpeech.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/GPBMetadata/Google/Cloud/Speech/V2/LocationsMetadata.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/AccessMetadata.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/AccessMetadata/ConstraintType.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/AutoDetectDecodingConfig.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeFileMetadata.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeFileResult.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeMetadata.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeRequest.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeRequest/ProcessingStrategy.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeResponse.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeResults.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeTranscriptionMetadata.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CloudStorageResult.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/Config.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CreateCustomClassRequest.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CreatePhraseSetRequest.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CreateRecognizerRequest.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CustomClass.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CustomClass/ClassItem.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CustomClass/State.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CustomPromptConfig.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/DeleteCustomClassRequest.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/DeletePhraseSetRequest.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/DeleteRecognizerRequest.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/DenoiserConfig.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ExplicitDecodingConfig.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ExplicitDecodingConfig/AudioEncoding.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/GcsOutputConfig.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/GetConfigRequest.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/GetCustomClassRequest.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/GetPhraseSetRequest.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/GetRecognizerRequest.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/InlineOutputConfig.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/InlineResult.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/LanguageMetadata.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListCustomClassesRequest.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListCustomClassesResponse.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListPhraseSetsRequest.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListPhraseSetsResponse.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListRecognizersRequest.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListRecognizersResponse.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/LocationsMetadata.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ModelFeature.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ModelFeatures.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ModelMetadata.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/NativeOutputFileFormatConfig.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/OperationMetadata.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/OutputFormatConfig.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/PhraseSet.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/PhraseSet/Phrase.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/PhraseSet/State.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognitionConfig.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognitionFeatures.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognitionFeatures/MultiChannelMode.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognitionOutputConfig.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognitionResponseMetadata.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognizeRequest.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognizeResponse.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/Recognizer.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/Recognizer/State.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SpeakerDiarizationConfig.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SpeechAdaptation.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SpeechAdaptation/AdaptationPhraseSet.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SpeechRecognitionAlternative.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SpeechRecognitionResult.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SrtOutputFileFormatConfig.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognitionConfig.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognitionFeatures.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognitionFeatures/EndpointingSensitivity.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognitionFeatures/VoiceActivityTimeout.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognitionResult.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognizeRequest.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognizeResponse.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognizeResponse/SpeechEventType.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/TranscriptNormalization.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/TranscriptNormalization/Entry.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/TranslationConfig.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UndeleteCustomClassRequest.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UndeletePhraseSetRequest.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UndeleteRecognizerRequest.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UpdateConfigRequest.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UpdateCustomClassRequest.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UpdatePhraseSetRequest.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UpdateRecognizerRequest.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/VttOutputFileFormatConfig.php create mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/WordInfo.php create mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/batch_recognize.php create mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/create_custom_class.php create mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/create_phrase_set.php create mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/create_recognizer.php create mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/delete_custom_class.php create mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/delete_phrase_set.php create mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/delete_recognizer.php create mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/get_config.php create mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/get_custom_class.php create mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/get_location.php create mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/get_phrase_set.php create mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/get_recognizer.php create mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/list_custom_classes.php create mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/list_locations.php create mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/list_phrase_sets.php create mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/list_recognizers.php create mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/recognize.php create mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/streaming_recognize.php create mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/undelete_custom_class.php create mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/undelete_phrase_set.php create mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/undelete_recognizer.php create mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/update_config.php create mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/update_custom_class.php create mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/update_phrase_set.php create mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/update_recognizer.php create mode 100644 owl-bot-staging/Speech/v2/src/V2/Client/SpeechClient.php create mode 100644 owl-bot-staging/Speech/v2/src/V2/gapic_metadata.json create mode 100644 owl-bot-staging/Speech/v2/src/V2/resources/speech_client_config.json create mode 100644 owl-bot-staging/Speech/v2/src/V2/resources/speech_descriptor_config.php create mode 100644 owl-bot-staging/Speech/v2/src/V2/resources/speech_rest_client_config.php create mode 100644 owl-bot-staging/Speech/v2/tests/Unit/V2/Client/SpeechClientTest.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/Common.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/DataObject.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/DataObjectSearchService.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/DataObjectService.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/EmbeddingConfig.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/EncryptionSpec.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/VectorsearchService.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/AggregateDataObjectsRequest.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/AggregateDataObjectsResponse.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/AggregationMethod.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchCreateDataObjectsRequest.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchCreateDataObjectsResponse.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchDeleteDataObjectsRequest.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchSearchDataObjectsRequest.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchSearchDataObjectsRequest/CombineResultsOptions.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchSearchDataObjectsResponse.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchUpdateDataObjectsRequest.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchUpdateDataObjectsResponse.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/Collection.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/CreateCollectionRequest.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/CreateDataObjectRequest.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/CreateIndexRequest.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DataObject.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DedicatedInfrastructure.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DedicatedInfrastructure/AutoscalingSpec.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DedicatedInfrastructure/Mode.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DeleteCollectionRequest.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DeleteDataObjectRequest.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DeleteIndexRequest.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DenseScannIndex.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DenseScannIndex/FeatureNormType.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DenseVector.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DenseVectorField.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DistanceMetric.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/EmbeddingTaskType.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/EncryptionSpec.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ExportDataObjectsMetadata.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ExportDataObjectsRequest.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ExportDataObjectsRequest/GcsExportDestination.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ExportDataObjectsRequest/GcsExportDestination/Format.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ExportDataObjectsResponse.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/GetCollectionRequest.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/GetDataObjectRequest.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/GetIndexRequest.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ImportDataObjectsMetadata.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ImportDataObjectsRequest.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ImportDataObjectsRequest/GcsImportConfig.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ImportDataObjectsResponse.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/Index.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ListCollectionsRequest.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ListCollectionsResponse.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ListIndexesRequest.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ListIndexesResponse.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/OperationMetadata.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/OutputFields.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/QueryDataObjectsRequest.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/QueryDataObjectsResponse.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/Ranker.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ReciprocalRankFusion.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/Search.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchDataObjectsRequest.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchDataObjectsResponse.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchHint.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchHint/IndexHint.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchHint/KnnHint.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchResult.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SemanticSearch.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SparseVector.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SparseVectorField.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/TextSearch.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/UpdateCollectionRequest.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/UpdateDataObjectRequest.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/UpdateIndexRequest.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/Vector.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/VectorField.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/VectorSearch.php create mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/VertexEmbeddingConfig.php create mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/aggregate_data_objects.php create mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/batch_search_data_objects.php create mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/get_location.php create mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/list_locations.php create mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/query_data_objects.php create mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/search_data_objects.php create mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/batch_create_data_objects.php create mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/batch_delete_data_objects.php create mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/batch_update_data_objects.php create mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/create_data_object.php create mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/delete_data_object.php create mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/get_data_object.php create mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/get_location.php create mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/list_locations.php create mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/update_data_object.php create mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/create_collection.php create mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/create_index.php create mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/delete_collection.php create mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/delete_index.php create mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/export_data_objects.php create mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/get_collection.php create mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/get_index.php create mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/get_location.php create mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/import_data_objects.php create mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/list_collections.php create mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/list_indexes.php create mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/list_locations.php create mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/update_collection.php create mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/update_index.php create mode 100644 owl-bot-staging/VectorSearch/v1/src/V1/Client/DataObjectSearchServiceClient.php create mode 100644 owl-bot-staging/VectorSearch/v1/src/V1/Client/DataObjectServiceClient.php create mode 100644 owl-bot-staging/VectorSearch/v1/src/V1/Client/VectorSearchServiceClient.php create mode 100644 owl-bot-staging/VectorSearch/v1/src/V1/gapic_metadata.json create mode 100644 owl-bot-staging/VectorSearch/v1/src/V1/resources/data_object_search_service_client_config.json create mode 100644 owl-bot-staging/VectorSearch/v1/src/V1/resources/data_object_search_service_descriptor_config.php create mode 100644 owl-bot-staging/VectorSearch/v1/src/V1/resources/data_object_search_service_rest_client_config.php create mode 100644 owl-bot-staging/VectorSearch/v1/src/V1/resources/data_object_service_client_config.json create mode 100644 owl-bot-staging/VectorSearch/v1/src/V1/resources/data_object_service_descriptor_config.php create mode 100644 owl-bot-staging/VectorSearch/v1/src/V1/resources/data_object_service_rest_client_config.php create mode 100644 owl-bot-staging/VectorSearch/v1/src/V1/resources/vector_search_service_client_config.json create mode 100644 owl-bot-staging/VectorSearch/v1/src/V1/resources/vector_search_service_descriptor_config.php create mode 100644 owl-bot-staging/VectorSearch/v1/src/V1/resources/vector_search_service_rest_client_config.php create mode 100644 owl-bot-staging/VectorSearch/v1/tests/Unit/V1/Client/DataObjectSearchServiceClientTest.php create mode 100644 owl-bot-staging/VectorSearch/v1/tests/Unit/V1/Client/DataObjectServiceClientTest.php create mode 100644 owl-bot-staging/VectorSearch/v1/tests/Unit/V1/Client/VectorSearchServiceClientTest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/GPBMetadata/Google/Cloud/Vmwareengine/V1/Vmwareengine.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/GPBMetadata/Google/Cloud/Vmwareengine/V1/VmwareengineResources.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/AutoscalingSettings.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/AutoscalingSettings/AutoscalingPolicy.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/AutoscalingSettings/Thresholds.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Cluster.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Cluster/State.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateClusterRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateExternalAccessRuleRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateExternalAddressRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateHcxActivationKeyRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateLoggingServerRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateManagementDnsZoneBindingRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateNetworkPeeringRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateNetworkPolicyRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreatePrivateCloudRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreatePrivateConnectionRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateVmwareEngineNetworkRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Credentials.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteClusterRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteExternalAccessRuleRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteExternalAddressRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteLoggingServerRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteManagementDnsZoneBindingRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteNetworkPeeringRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteNetworkPolicyRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeletePrivateCloudRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeletePrivateConnectionRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteVmwareEngineNetworkRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DnsBindPermission.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DnsForwarding.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DnsForwarding/ForwardingRule.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAccessRule.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAccessRule/Action.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAccessRule/IpRange.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAccessRule/State.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAddress.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAddress/State.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/FetchNetworkPolicyExternalAddressesRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/FetchNetworkPolicyExternalAddressesResponse.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetClusterRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetDnsBindPermissionRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetDnsForwardingRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetExternalAccessRuleRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetExternalAddressRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetHcxActivationKeyRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetLoggingServerRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetManagementDnsZoneBindingRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetNetworkPeeringRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetNetworkPolicyRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetNodeRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetNodeTypeRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetPrivateCloudRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetPrivateConnectionRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetSubnetRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetVmwareEngineNetworkRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GrantDnsBindPermissionRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Hcx.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Hcx/State.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/HcxActivationKey.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/HcxActivationKey/State.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListClustersRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListClustersResponse.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListExternalAccessRulesRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListExternalAccessRulesResponse.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListExternalAddressesRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListExternalAddressesResponse.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListHcxActivationKeysRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListHcxActivationKeysResponse.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListLoggingServersRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListLoggingServersResponse.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListManagementDnsZoneBindingsRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListManagementDnsZoneBindingsResponse.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNetworkPeeringsRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNetworkPeeringsResponse.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNetworkPoliciesRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNetworkPoliciesResponse.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNodeTypesRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNodeTypesResponse.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNodesRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNodesResponse.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPeeringRoutesRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPeeringRoutesResponse.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateCloudsRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateCloudsResponse.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateConnectionPeeringRoutesRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateConnectionPeeringRoutesResponse.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateConnectionsRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateConnectionsResponse.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListSubnetsRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListSubnetsResponse.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListVmwareEngineNetworksRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListVmwareEngineNetworksResponse.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/LocationMetadata.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/LocationMetadata/Capability.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/LoggingServer.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/LoggingServer/Protocol.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/LoggingServer/SourceType.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ManagementDnsZoneBinding.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ManagementDnsZoneBinding/State.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkConfig.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPeering.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPeering/PeerNetworkType.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPeering/State.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPolicy.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPolicy/NetworkService.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPolicy/NetworkService/State.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Node.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Node/State.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NodeType.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NodeType/Capability.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NodeType/Kind.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NodeTypeConfig.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Nsx.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Nsx/State.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/OperationMetadata.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PeeringRoute.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PeeringRoute/Direction.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PeeringRoute/Type.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Principal.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateCloud.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateCloud/ManagementCluster.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateCloud/State.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateCloud/Type.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateConnection.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateConnection/PeeringState.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateConnection/RoutingMode.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateConnection/State.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateConnection/Type.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/RepairManagementDnsZoneBindingRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ResetNsxCredentialsRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ResetVcenterCredentialsRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/RevokeDnsBindPermissionRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ShowNsxCredentialsRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ShowVcenterCredentialsRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/StretchedClusterConfig.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Subnet.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Subnet/State.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UndeletePrivateCloudRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateClusterRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateDnsForwardingRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateExternalAccessRuleRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateExternalAddressRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateLoggingServerRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateManagementDnsZoneBindingRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateNetworkPeeringRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateNetworkPolicyRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdatePrivateCloudRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdatePrivateConnectionRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateSubnetRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateVmwareEngineNetworkRequest.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Vcenter.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Vcenter/State.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/VmwareEngineNetwork.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/VmwareEngineNetwork/State.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/VmwareEngineNetwork/Type.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/VmwareEngineNetwork/VpcNetwork.php create mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/VmwareEngineNetwork/VpcNetwork/Type.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_cluster.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_external_access_rule.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_external_address.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_hcx_activation_key.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_logging_server.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_management_dns_zone_binding.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_network_peering.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_network_policy.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_private_cloud.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_private_connection.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_vmware_engine_network.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_cluster.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_external_access_rule.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_external_address.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_logging_server.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_management_dns_zone_binding.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_network_peering.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_network_policy.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_private_cloud.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_private_connection.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_vmware_engine_network.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/fetch_network_policy_external_addresses.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_cluster.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_dns_bind_permission.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_dns_forwarding.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_external_access_rule.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_external_address.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_hcx_activation_key.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_iam_policy.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_location.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_logging_server.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_management_dns_zone_binding.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_network_peering.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_network_policy.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_node.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_node_type.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_private_cloud.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_private_connection.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_subnet.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_vmware_engine_network.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/grant_dns_bind_permission.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_clusters.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_external_access_rules.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_external_addresses.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_hcx_activation_keys.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_locations.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_logging_servers.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_management_dns_zone_bindings.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_network_peerings.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_network_policies.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_node_types.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_nodes.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_peering_routes.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_private_clouds.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_private_connection_peering_routes.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_private_connections.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_subnets.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_vmware_engine_networks.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/repair_management_dns_zone_binding.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/reset_nsx_credentials.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/reset_vcenter_credentials.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/revoke_dns_bind_permission.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/set_iam_policy.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/show_nsx_credentials.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/show_vcenter_credentials.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/test_iam_permissions.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/undelete_private_cloud.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_cluster.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_dns_forwarding.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_external_access_rule.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_external_address.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_logging_server.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_management_dns_zone_binding.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_network_peering.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_network_policy.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_private_cloud.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_private_connection.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_subnet.php create mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_vmware_engine_network.php create mode 100644 owl-bot-staging/VmwareEngine/v1/src/V1/Client/VmwareEngineClient.php create mode 100644 owl-bot-staging/VmwareEngine/v1/src/V1/gapic_metadata.json create mode 100644 owl-bot-staging/VmwareEngine/v1/src/V1/resources/vmware_engine_client_config.json create mode 100644 owl-bot-staging/VmwareEngine/v1/src/V1/resources/vmware_engine_descriptor_config.php create mode 100644 owl-bot-staging/VmwareEngine/v1/src/V1/resources/vmware_engine_rest_client_config.php create mode 100644 owl-bot-staging/VmwareEngine/v1/tests/Unit/V1/Client/VmwareEngineClientTest.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/GPBMetadata/Google/Cloud/Workloadmanager/V1/Service.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/AgentCommand.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/BigQueryDestination.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Command.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/CreateEvaluationRequest.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/DeleteEvaluationRequest.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/DeleteExecutionRequest.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Evaluation.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Evaluation/EvaluationType.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/Engine.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/ExternalDataSources.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/ExternalDataSources/Type.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/Notice.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/State.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/Summary.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/Type.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ExecutionResult.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ExecutionResult/Type.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/GceInstanceFilter.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/GetEvaluationRequest.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/GetExecutionRequest.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListEvaluationsRequest.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListEvaluationsResponse.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListExecutionResultsRequest.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListExecutionResultsResponse.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListExecutionsRequest.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListExecutionsResponse.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListRulesRequest.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListRulesResponse.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListScannedResourcesRequest.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListScannedResourcesResponse.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/OperationMetadata.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Resource.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ResourceFilter.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ResourceStatus.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ResourceStatus/State.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Rule.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Rule/RuleType.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/RuleExecutionResult.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/RuleExecutionResult/State.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/RuleOutput.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/RunEvaluationRequest.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ScannedResource.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ShellCommand.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/UpdateEvaluationRequest.php create mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ViolationDetails.php create mode 100644 owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/create_evaluation.php create mode 100644 owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/delete_evaluation.php create mode 100644 owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/delete_execution.php create mode 100644 owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/get_evaluation.php create mode 100644 owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/get_execution.php create mode 100644 owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/get_location.php create mode 100644 owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_evaluations.php create mode 100644 owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_execution_results.php create mode 100644 owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_executions.php create mode 100644 owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_locations.php create mode 100644 owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_rules.php create mode 100644 owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_scanned_resources.php create mode 100644 owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/run_evaluation.php create mode 100644 owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/update_evaluation.php create mode 100644 owl-bot-staging/WorkloadManager/v1/src/V1/Client/WorkloadManagerClient.php create mode 100644 owl-bot-staging/WorkloadManager/v1/src/V1/gapic_metadata.json create mode 100644 owl-bot-staging/WorkloadManager/v1/src/V1/resources/workload_manager_client_config.json create mode 100644 owl-bot-staging/WorkloadManager/v1/src/V1/resources/workload_manager_descriptor_config.php create mode 100644 owl-bot-staging/WorkloadManager/v1/src/V1/resources/workload_manager_rest_client_config.php create mode 100644 owl-bot-staging/WorkloadManager/v1/tests/Unit/V1/Client/WorkloadManagerClientTest.php diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/GPBMetadata/Google/Cloud/Security/Privateca/V1/Resources.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/GPBMetadata/Google/Cloud/Security/Privateca/V1/Resources.php new file mode 100644 index 000000000000..35d57a49c7fe --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/GPBMetadata/Google/Cloud/Security/Privateca/V1/Resources.php @@ -0,0 +1,29 @@ +internalAddGeneratedFile( + "\x0A\xB7n\x0A2google/cloud/security/privateca/v1/resources.proto\x12\"google.cloud.security.privateca.v1\x1A\x19google/api/resource.proto\x1A\x1Egoogle/protobuf/duration.proto\x1A\x1Fgoogle/protobuf/timestamp.proto\x1A\x16google/type/expr.proto\"\x86\x12\x0A\x14CertificateAuthority\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x08\x12S\x0A\x04type\x18\x02 \x01(\x0E2=.google.cloud.security.privateca.v1.CertificateAuthority.TypeB\x06\xE0A\x02\xE0A\x05\x12M\x0A\x06config\x18\x03 \x01(\x0B25.google.cloud.security.privateca.v1.CertificateConfigB\x06\xE0A\x02\xE0A\x05\x123\x0A\x08lifetime\x18\x04 \x01(\x0B2\x19.google.protobuf.DurationB\x06\xE0A\x02\xE0A\x05\x12a\x0A\x08key_spec\x18\x05 \x01(\x0B2G.google.cloud.security.privateca.v1.CertificateAuthority.KeyVersionSpecB\x06\xE0A\x02\xE0A\x05\x12V\x0A\x12subordinate_config\x18\x06 \x01(\x0B25.google.cloud.security.privateca.v1.SubordinateConfigB\x03\xE0A\x01\x12B\x0A\x04tier\x18\x07 \x01(\x0E2/.google.cloud.security.privateca.v1.CaPool.TierB\x03\xE0A\x03\x12R\x0A\x05state\x18\x08 \x01(\x0E2>.google.cloud.security.privateca.v1.CertificateAuthority.StateB\x03\xE0A\x03\x12 \x0A\x13pem_ca_certificates\x18\x09 \x03(\x09B\x03\xE0A\x03\x12d\x0A\x1Bca_certificate_descriptions\x18\x0A \x03(\x0B2:.google.cloud.security.privateca.v1.CertificateDescriptionB\x03\xE0A\x03\x12\x17\x0A\x0Agcs_bucket\x18\x0B \x01(\x09B\x03\xE0A\x05\x12]\x0A\x0Baccess_urls\x18\x0C \x01(\x0B2C.google.cloud.security.privateca.v1.CertificateAuthority.AccessUrlsB\x03\xE0A\x03\x124\x0A\x0Bcreate_time\x18\x0D \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x0E \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bdelete_time\x18\x0F \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bexpire_time\x18\x10 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12Y\x0A\x06labels\x18\x11 \x03(\x0B2D.google.cloud.security.privateca.v1.CertificateAuthority.LabelsEntryB\x03\xE0A\x01\x12u\x0A\x18user_defined_access_urls\x18\x12 \x01(\x0B2N.google.cloud.security.privateca.v1.CertificateAuthority.UserDefinedAccessUrlsB\x03\xE0A\x01\x12\x1A\x0A\x0Dsatisfies_pzs\x18\x13 \x01(\x08B\x03\xE0A\x03\x12\x1A\x0A\x0Dsatisfies_pzi\x18\x14 \x01(\x08B\x03\xE0A\x03\x1AH\x0A\x0AAccessUrls\x12!\x0A\x19ca_certificate_access_url\x18\x01 \x01(\x09\x12\x17\x0A\x0Fcrl_access_urls\x18\x02 \x03(\x09\x1A\xA0\x01\x0A\x0EKeyVersionSpec\x12\x1F\x0A\x15cloud_kms_key_version\x18\x01 \x01(\x09H\x00\x12_\x0A\x09algorithm\x18\x02 \x01(\x0E2J.google.cloud.security.privateca.v1.CertificateAuthority.SignHashAlgorithmH\x00B\x0C\x0A\x0AKeyVersion\x1A`\x0A\x15UserDefinedAccessUrls\x12)\x0A\x1Caia_issuing_certificate_urls\x18\x01 \x03(\x09B\x03\xE0A\x01\x12\x1C\x0A\x0Fcrl_access_urls\x18\x02 \x03(\x09B\x03\xE0A\x01\x1A-\x0A\x0BLabelsEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12\x0D\x0A\x05value\x18\x02 \x01(\x09:\x028\x01\">\x0A\x04Type\x12\x14\x0A\x10TYPE_UNSPECIFIED\x10\x00\x12\x0F\x0A\x0BSELF_SIGNED\x10\x01\x12\x0F\x0A\x0BSUBORDINATE\x10\x02\"p\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x0B\x0A\x07ENABLED\x10\x01\x12\x0C\x0A\x08DISABLED\x10\x02\x12\x0A\x0A\x06STAGED\x10\x03\x12\x1C\x0A\x18AWAITING_USER_ACTIVATION\x10\x04\x12\x0B\x0A\x07DELETED\x10\x05\"\xFC\x01\x0A\x11SignHashAlgorithm\x12#\x0A\x1FSIGN_HASH_ALGORITHM_UNSPECIFIED\x10\x00\x12\x17\x0A\x13RSA_PSS_2048_SHA256\x10\x01\x12\x17\x0A\x13RSA_PSS_3072_SHA256\x10\x02\x12\x17\x0A\x13RSA_PSS_4096_SHA256\x10\x03\x12\x19\x0A\x15RSA_PKCS1_2048_SHA256\x10\x06\x12\x19\x0A\x15RSA_PKCS1_3072_SHA256\x10\x07\x12\x19\x0A\x15RSA_PKCS1_4096_SHA256\x10\x08\x12\x12\x0A\x0EEC_P256_SHA256\x10\x04\x12\x12\x0A\x0EEC_P384_SHA384\x10\x05:\x9D\x01\xEAA\x99\x01\x0A-privateca.googleapis.com/CertificateAuthority\x12hprojects/{project}/locations/{location}/caPools/{ca_pool}/certificateAuthorities/{certificate_authority}\"\xE6\x11\x0A\x06CaPool\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x08\x12E\x0A\x04tier\x18\x02 \x01(\x0E2/.google.cloud.security.privateca.v1.CaPool.TierB\x06\xE0A\x02\xE0A\x05\x12W\x0A\x0Fissuance_policy\x18\x03 \x01(\x0B29.google.cloud.security.privateca.v1.CaPool.IssuancePolicyB\x03\xE0A\x01\x12]\x0A\x12publishing_options\x18\x04 \x01(\x0B2<.google.cloud.security.privateca.v1.CaPool.PublishingOptionsB\x03\xE0A\x01\x12P\x0A\x0Fencryption_spec\x18\x08 \x01(\x0B22.google.cloud.security.privateca.v1.EncryptionSpecB\x03\xE0A\x01\x12K\x0A\x06labels\x18\x05 \x03(\x0B26.google.cloud.security.privateca.v1.CaPool.LabelsEntryB\x03\xE0A\x01\x1A\xFB\x01\x0A\x11PublishingOptions\x12\x1C\x0A\x0Fpublish_ca_cert\x18\x01 \x01(\x08B\x03\xE0A\x01\x12\x18\x0A\x0Bpublish_crl\x18\x02 \x01(\x08B\x03\xE0A\x01\x12i\x0A\x0Fencoding_format\x18\x03 \x01(\x0E2K.google.cloud.security.privateca.v1.CaPool.PublishingOptions.EncodingFormatB\x03\xE0A\x01\"C\x0A\x0EEncodingFormat\x12\x1F\x0A\x1BENCODING_FORMAT_UNSPECIFIED\x10\x00\x12\x07\x0A\x03PEM\x10\x01\x12\x07\x0A\x03DER\x10\x02\x1A\xE2\x0A\x0A\x0EIssuancePolicy\x12h\x0A\x11allowed_key_types\x18\x01 \x03(\x0B2H.google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyTypeB\x03\xE0A\x01\x129\x0A\x11backdate_duration\x18\x07 \x01(\x0B2\x19.google.protobuf.DurationB\x03\xE0A\x01\x126\x0A)allow_requester_specified_not_before_time\x18\x08 \x01(\x08B\x03\xE0A\x01\x128\x0A\x10maximum_lifetime\x18\x02 \x01(\x0B2\x19.google.protobuf.DurationB\x03\xE0A\x01\x12l\x0A\x16allowed_issuance_modes\x18\x03 \x01(\x0B2G.google.cloud.security.privateca.v1.CaPool.IssuancePolicy.IssuanceModesB\x03\xE0A\x01\x12P\x0A\x0Fbaseline_values\x18\x04 \x01(\x0B22.google.cloud.security.privateca.v1.X509ParametersB\x03\xE0A\x01\x12e\x0A\x14identity_constraints\x18\x05 \x01(\x0B2B.google.cloud.security.privateca.v1.CertificateIdentityConstraintsB\x03\xE0A\x01\x12h\x0A\x16passthrough_extensions\x18\x06 \x01(\x0B2C.google.cloud.security.privateca.v1.CertificateExtensionConstraintsB\x03\xE0A\x01\x1A\xC5\x04\x0A\x0EAllowedKeyType\x12b\x0A\x03rsa\x18\x01 \x01(\x0B2S.google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyType.RsaKeyTypeH\x00\x12l\x0A\x0Eelliptic_curve\x18\x02 \x01(\x0B2R.google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyType.EcKeyTypeH\x00\x1AJ\x0A\x0ARsaKeyType\x12\x1D\x0A\x10min_modulus_size\x18\x01 \x01(\x03B\x03\xE0A\x01\x12\x1D\x0A\x10max_modulus_size\x18\x02 \x01(\x03B\x03\xE0A\x01\x1A\x88\x02\x0A\x09EcKeyType\x12\x89\x01\x0A\x13signature_algorithm\x18\x01 \x01(\x0E2g.google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyType.EcKeyType.EcSignatureAlgorithmB\x03\xE0A\x01\"o\x0A\x14EcSignatureAlgorithm\x12&\x0A\"EC_SIGNATURE_ALGORITHM_UNSPECIFIED\x10\x00\x12\x0E\x0A\x0AECDSA_P256\x10\x01\x12\x0E\x0A\x0AECDSA_P384\x10\x02\x12\x0F\x0A\x0BEDDSA_25519\x10\x03B\x0A\x0A\x08key_type\x1A`\x0A\x0DIssuanceModes\x12%\x0A\x18allow_csr_based_issuance\x18\x01 \x01(\x08B\x03\xE0A\x01\x12(\x0A\x1Ballow_config_based_issuance\x18\x02 \x01(\x08B\x03\xE0A\x01\x1A-\x0A\x0BLabelsEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12\x0D\x0A\x05value\x18\x02 \x01(\x09:\x028\x01\"8\x0A\x04Tier\x12\x14\x0A\x10TIER_UNSPECIFIED\x10\x00\x12\x0E\x0A\x0AENTERPRISE\x10\x01\x12\x0A\x0A\x06DEVOPS\x10\x02:_\xEAA\\\x0A\x1Fprivateca.googleapis.com/CaPool\x129projects/{project}/locations/{location}/caPools/{ca_pool}\"'\x0A\x0EEncryptionSpec\x12\x15\x0A\x0Dcloud_kms_key\x18\x01 \x01(\x09\"\xBC\x08\x0A\x19CertificateRevocationList\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x08\x12\x1C\x0A\x0Fsequence_number\x18\x02 \x01(\x03B\x03\xE0A\x03\x12s\x0A\x14revoked_certificates\x18\x03 \x03(\x0B2P.google.cloud.security.privateca.v1.CertificateRevocationList.RevokedCertificateB\x03\xE0A\x03\x12\x14\x0A\x07pem_crl\x18\x04 \x01(\x09B\x03\xE0A\x03\x12\x17\x0A\x0Aaccess_url\x18\x05 \x01(\x09B\x03\xE0A\x03\x12W\x0A\x05state\x18\x06 \x01(\x0E2C.google.cloud.security.privateca.v1.CertificateRevocationList.StateB\x03\xE0A\x03\x124\x0A\x0Bcreate_time\x18\x07 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x08 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12\x18\x0A\x0Brevision_id\x18\x09 \x01(\x09B\x03\xE0A\x03\x12^\x0A\x06labels\x18\x0A \x03(\x0B2I.google.cloud.security.privateca.v1.CertificateRevocationList.LabelsEntryB\x03\xE0A\x01\x1A\xC0\x01\x0A\x12RevokedCertificate\x12>\x0A\x0Bcertificate\x18\x01 \x01(\x09B)\xFAA&\x0A\$privateca.googleapis.com/Certificate\x12\x19\x0A\x11hex_serial_number\x18\x02 \x01(\x09\x12O\x0A\x11revocation_reason\x18\x03 \x01(\x0E24.google.cloud.security.privateca.v1.RevocationReason\x1A-\x0A\x0BLabelsEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12\x0D\x0A\x05value\x18\x02 \x01(\x09:\x028\x01\":\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x0A\x0A\x06ACTIVE\x10\x01\x12\x0E\x0A\x0ASUPERSEDED\x10\x02:\xDC\x01\xEAA\xD8\x01\x0A2privateca.googleapis.com/CertificateRevocationList\x12\xA1\x01projects/{project}/locations/{location}/caPools/{ca_pool}/certificateAuthorities/{certificate_authority}/certificateRevocationLists/{certificate_revocation_list}\"\xAA\x0A\x0A\x0BCertificate\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x08\x12\x16\x0A\x07pem_csr\x18\x02 \x01(\x09B\x03\xE0A\x05H\x00\x12L\x0A\x06config\x18\x03 \x01(\x0B25.google.cloud.security.privateca.v1.CertificateConfigB\x03\xE0A\x05H\x00\x12[\x0A\x1Cissuer_certificate_authority\x18\x04 \x01(\x09B5\xE0A\x03\xFAA/\x0A-privateca.googleapis.com/CertificateAuthority\x123\x0A\x08lifetime\x18\x05 \x01(\x0B2\x19.google.protobuf.DurationB\x06\xE0A\x02\xE0A\x05\x12R\x0A\x14certificate_template\x18\x06 \x01(\x09B4\xE0A\x05\xFAA.\x0A,privateca.googleapis.com/CertificateTemplate\x12Q\x0A\x0Csubject_mode\x18\x07 \x01(\x0E26.google.cloud.security.privateca.v1.SubjectRequestModeB\x03\xE0A\x05\x12b\x0A\x12revocation_details\x18\x08 \x01(\x0B2A.google.cloud.security.privateca.v1.Certificate.RevocationDetailsB\x03\xE0A\x03\x12\x1C\x0A\x0Fpem_certificate\x18\x09 \x01(\x09B\x03\xE0A\x03\x12`\x0A\x17certificate_description\x18\x0A \x01(\x0B2:.google.cloud.security.privateca.v1.CertificateDescriptionB\x03\xE0A\x03\x12\"\x0A\x15pem_certificate_chain\x18\x0B \x03(\x09B\x03\xE0A\x03\x124\x0A\x0Bcreate_time\x18\x0C \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x0D \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12P\x0A\x06labels\x18\x0E \x03(\x0B2;.google.cloud.security.privateca.v1.Certificate.LabelsEntryB\x03\xE0A\x01\x12B\x0A\x19requested_not_before_time\x18\x0F \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x01\x1A\x98\x01\x0A\x11RevocationDetails\x12N\x0A\x10revocation_state\x18\x01 \x01(\x0E24.google.cloud.security.privateca.v1.RevocationReason\x123\x0A\x0Frevocation_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.Timestamp\x1A-\x0A\x0BLabelsEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12\x0D\x0A\x05value\x18\x02 \x01(\x09:\x028\x01:\x7F\xEAA|\x0A\$privateca.googleapis.com/Certificate\x12Tprojects/{project}/locations/{location}/caPools/{ca_pool}/certificates/{certificate}B\x14\x0A\x12certificate_config\"\xA0\x06\x0A\x13CertificateTemplate\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x08\x128\x0A\x10maximum_lifetime\x18\x09 \x01(\x0B2\x19.google.protobuf.DurationB\x03\xE0A\x01\x12R\x0A\x11predefined_values\x18\x02 \x01(\x0B22.google.cloud.security.privateca.v1.X509ParametersB\x03\xE0A\x01\x12e\x0A\x14identity_constraints\x18\x03 \x01(\x0B2B.google.cloud.security.privateca.v1.CertificateIdentityConstraintsB\x03\xE0A\x01\x12h\x0A\x16passthrough_extensions\x18\x04 \x01(\x0B2C.google.cloud.security.privateca.v1.CertificateExtensionConstraintsB\x03\xE0A\x01\x12\x18\x0A\x0Bdescription\x18\x05 \x01(\x09B\x03\xE0A\x01\x124\x0A\x0Bcreate_time\x18\x06 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x07 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12X\x0A\x06labels\x18\x08 \x03(\x0B2C.google.cloud.security.privateca.v1.CertificateTemplate.LabelsEntryB\x03\xE0A\x01\x1A-\x0A\x0BLabelsEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12\x0D\x0A\x05value\x18\x02 \x01(\x09:\x028\x01:\x87\x01\xEAA\x83\x01\x0A,privateca.googleapis.com/CertificateTemplate\x12Sprojects/{project}/locations/{location}/certificateTemplates/{certificate_template}\"\xCE\x06\x0A\x0EX509Parameters\x12D\x0A\x09key_usage\x18\x01 \x01(\x0B2,.google.cloud.security.privateca.v1.KeyUsageB\x03\xE0A\x01\x12U\x0A\x0Aca_options\x18\x02 \x01(\x0B2<.google.cloud.security.privateca.v1.X509Parameters.CaOptionsB\x03\xE0A\x01\x12E\x0A\x0Apolicy_ids\x18\x03 \x03(\x0B2,.google.cloud.security.privateca.v1.ObjectIdB\x03\xE0A\x01\x12\x1D\x0A\x10aia_ocsp_servers\x18\x04 \x03(\x09B\x03\xE0A\x01\x12a\x0A\x10name_constraints\x18\x06 \x01(\x0B2B.google.cloud.security.privateca.v1.X509Parameters.NameConstraintsB\x03\xE0A\x01\x12U\x0A\x15additional_extensions\x18\x05 \x03(\x0B21.google.cloud.security.privateca.v1.X509ExtensionB\x03\xE0A\x01\x1As\x0A\x09CaOptions\x12\x17\x0A\x05is_ca\x18\x01 \x01(\x08B\x03\xE0A\x01H\x00\x88\x01\x01\x12(\x0A\x16max_issuer_path_length\x18\x02 \x01(\x05B\x03\xE0A\x01H\x01\x88\x01\x01B\x08\x0A\x06_is_caB\x19\x0A\x17_max_issuer_path_length\x1A\x89\x02\x0A\x0FNameConstraints\x12\x10\x0A\x08critical\x18\x01 \x01(\x08\x12\x1B\x0A\x13permitted_dns_names\x18\x02 \x03(\x09\x12\x1A\x0A\x12excluded_dns_names\x18\x03 \x03(\x09\x12\x1B\x0A\x13permitted_ip_ranges\x18\x04 \x03(\x09\x12\x1A\x0A\x12excluded_ip_ranges\x18\x05 \x03(\x09\x12!\x0A\x19permitted_email_addresses\x18\x06 \x03(\x09\x12 \x0A\x18excluded_email_addresses\x18\x07 \x03(\x09\x12\x16\x0A\x0Epermitted_uris\x18\x08 \x03(\x09\x12\x15\x0A\x0Dexcluded_uris\x18\x09 \x03(\x09\"\xA9\x02\x0A\x11SubordinateConfig\x12V\x0A\x15certificate_authority\x18\x01 \x01(\x09B5\xE0A\x02\xFAA/\x0A-privateca.googleapis.com/CertificateAuthorityH\x00\x12m\x0A\x10pem_issuer_chain\x18\x02 \x01(\x0B2L.google.cloud.security.privateca.v1.SubordinateConfig.SubordinateConfigChainB\x03\xE0A\x02H\x00\x1A7\x0A\x16SubordinateConfigChain\x12\x1D\x0A\x10pem_certificates\x18\x01 \x03(\x09B\x03\xE0A\x02B\x14\x0A\x12subordinate_config\"\x9D\x01\x0A\x09PublicKey\x12\x10\x0A\x03key\x18\x01 \x01(\x0CB\x03\xE0A\x02\x12L\x0A\x06format\x18\x02 \x01(\x0E27.google.cloud.security.privateca.v1.PublicKey.KeyFormatB\x03\xE0A\x02\"0\x0A\x09KeyFormat\x12\x1A\x0A\x16KEY_FORMAT_UNSPECIFIED\x10\x00\x12\x07\x0A\x03PEM\x10\x01\"\xAC\x04\x0A\x11CertificateConfig\x12`\x0A\x0Esubject_config\x18\x01 \x01(\x0B2C.google.cloud.security.privateca.v1.CertificateConfig.SubjectConfigB\x03\xE0A\x02\x12L\x0A\x0Bx509_config\x18\x02 \x01(\x0B22.google.cloud.security.privateca.v1.X509ParametersB\x03\xE0A\x02\x12F\x0A\x0Apublic_key\x18\x03 \x01(\x0B2-.google.cloud.security.privateca.v1.PublicKeyB\x03\xE0A\x01\x12X\x0A\x0Esubject_key_id\x18\x04 \x01(\x0B2;.google.cloud.security.privateca.v1.CertificateConfig.KeyIdB\x03\xE0A\x01\x1A\xA6\x01\x0A\x0DSubjectConfig\x12A\x0A\x07subject\x18\x01 \x01(\x0B2+.google.cloud.security.privateca.v1.SubjectB\x03\xE0A\x01\x12R\x0A\x10subject_alt_name\x18\x02 \x01(\x0B23.google.cloud.security.privateca.v1.SubjectAltNamesB\x03\xE0A\x01\x1A\x1C\x0A\x05KeyId\x12\x13\x0A\x06key_id\x18\x01 \x01(\x09B\x03\xE0A\x02\"\xC1\x08\x0A\x16CertificateDescription\x12j\x0A\x13subject_description\x18\x01 \x01(\x0B2M.google.cloud.security.privateca.v1.CertificateDescription.SubjectDescription\x12L\x0A\x10x509_description\x18\x02 \x01(\x0B22.google.cloud.security.privateca.v1.X509Parameters\x12A\x0A\x0Apublic_key\x18\x03 \x01(\x0B2-.google.cloud.security.privateca.v1.PublicKey\x12X\x0A\x0Esubject_key_id\x18\x04 \x01(\x0B2@.google.cloud.security.privateca.v1.CertificateDescription.KeyId\x12Z\x0A\x10authority_key_id\x18\x05 \x01(\x0B2@.google.cloud.security.privateca.v1.CertificateDescription.KeyId\x12\x1F\x0A\x17crl_distribution_points\x18\x06 \x03(\x09\x12\$\x0A\x1Caia_issuing_certificate_urls\x18\x07 \x03(\x09\x12k\x0A\x10cert_fingerprint\x18\x08 \x01(\x0B2Q.google.cloud.security.privateca.v1.CertificateDescription.CertificateFingerprint\x12\x1E\x0A\x16tbs_certificate_digest\x18\x09 \x01(\x09\x1A\xD2\x02\x0A\x12SubjectDescription\x12<\x0A\x07subject\x18\x01 \x01(\x0B2+.google.cloud.security.privateca.v1.Subject\x12M\x0A\x10subject_alt_name\x18\x02 \x01(\x0B23.google.cloud.security.privateca.v1.SubjectAltNames\x12\x19\x0A\x11hex_serial_number\x18\x03 \x01(\x09\x12+\x0A\x08lifetime\x18\x04 \x01(\x0B2\x19.google.protobuf.Duration\x123\x0A\x0Fnot_before_time\x18\x05 \x01(\x0B2\x1A.google.protobuf.Timestamp\x122\x0A\x0Enot_after_time\x18\x06 \x01(\x0B2\x1A.google.protobuf.Timestamp\x1A\x1C\x0A\x05KeyId\x12\x13\x0A\x06key_id\x18\x01 \x01(\x09B\x03\xE0A\x01\x1A-\x0A\x16CertificateFingerprint\x12\x13\x0A\x0Bsha256_hash\x18\x01 \x01(\x09\"'\x0A\x08ObjectId\x12\x1B\x0A\x0Eobject_id_path\x18\x01 \x03(\x05B\x03\xE0A\x02\"\x80\x01\x0A\x0DX509Extension\x12D\x0A\x09object_id\x18\x01 \x01(\x0B2,.google.cloud.security.privateca.v1.ObjectIdB\x03\xE0A\x02\x12\x15\x0A\x08critical\x18\x02 \x01(\x08B\x03\xE0A\x01\x12\x12\x0A\x05value\x18\x03 \x01(\x0CB\x03\xE0A\x02\"\xA2\x05\x0A\x08KeyUsage\x12T\x0A\x0Ebase_key_usage\x18\x01 \x01(\x0B2<.google.cloud.security.privateca.v1.KeyUsage.KeyUsageOptions\x12`\x0A\x12extended_key_usage\x18\x02 \x01(\x0B2D.google.cloud.security.privateca.v1.KeyUsage.ExtendedKeyUsageOptions\x12Q\x0A\x1Bunknown_extended_key_usages\x18\x03 \x03(\x0B2,.google.cloud.security.privateca.v1.ObjectId\x1A\xE7\x01\x0A\x0FKeyUsageOptions\x12\x19\x0A\x11digital_signature\x18\x01 \x01(\x08\x12\x1A\x0A\x12content_commitment\x18\x02 \x01(\x08\x12\x18\x0A\x10key_encipherment\x18\x03 \x01(\x08\x12\x19\x0A\x11data_encipherment\x18\x04 \x01(\x08\x12\x15\x0A\x0Dkey_agreement\x18\x05 \x01(\x08\x12\x11\x0A\x09cert_sign\x18\x06 \x01(\x08\x12\x10\x0A\x08crl_sign\x18\x07 \x01(\x08\x12\x15\x0A\x0Dencipher_only\x18\x08 \x01(\x08\x12\x15\x0A\x0Ddecipher_only\x18\x09 \x01(\x08\x1A\xA0\x01\x0A\x17ExtendedKeyUsageOptions\x12\x13\x0A\x0Bserver_auth\x18\x01 \x01(\x08\x12\x13\x0A\x0Bclient_auth\x18\x02 \x01(\x08\x12\x14\x0A\x0Ccode_signing\x18\x03 \x01(\x08\x12\x18\x0A\x10email_protection\x18\x04 \x01(\x08\x12\x15\x0A\x0Dtime_stamping\x18\x05 \x01(\x08\x12\x14\x0A\x0Cocsp_signing\x18\x06 \x01(\x08\"\xBE\x01\x0A\x15AttributeTypeAndValue\x12A\x0A\x04type\x18\x01 \x01(\x0E21.google.cloud.security.privateca.v1.AttributeTypeH\x00\x12A\x0A\x09object_id\x18\x02 \x01(\x0B2,.google.cloud.security.privateca.v1.ObjectIdH\x00\x12\x0D\x0A\x05value\x18\x03 \x01(\x09B\x10\x0A\x0Eattribute_type\"j\x0A\x19RelativeDistinguishedName\x12M\x0A\x0Aattributes\x18\x01 \x03(\x0B29.google.cloud.security.privateca.v1.AttributeTypeAndValue\"\x8D\x02\x0A\x07Subject\x12\x13\x0A\x0Bcommon_name\x18\x01 \x01(\x09\x12\x14\x0A\x0Ccountry_code\x18\x02 \x01(\x09\x12\x14\x0A\x0Corganization\x18\x03 \x01(\x09\x12\x1B\x0A\x13organizational_unit\x18\x04 \x01(\x09\x12\x10\x0A\x08locality\x18\x05 \x01(\x09\x12\x10\x0A\x08province\x18\x06 \x01(\x09\x12\x16\x0A\x0Estreet_address\x18\x07 \x01(\x09\x12\x13\x0A\x0Bpostal_code\x18\x08 \x01(\x09\x12S\x0A\x0Crdn_sequence\x18\x09 \x03(\x0B2=.google.cloud.security.privateca.v1.RelativeDistinguishedName\"\xA9\x01\x0A\x0FSubjectAltNames\x12\x11\x0A\x09dns_names\x18\x01 \x03(\x09\x12\x0C\x0A\x04uris\x18\x02 \x03(\x09\x12\x17\x0A\x0Femail_addresses\x18\x03 \x03(\x09\x12\x14\x0A\x0Cip_addresses\x18\x04 \x03(\x09\x12F\x0A\x0Bcustom_sans\x18\x05 \x03(\x0B21.google.cloud.security.privateca.v1.X509Extension\"\xFA\x01\x0A\x1ECertificateIdentityConstraints\x12.\x0A\x0Ecel_expression\x18\x01 \x01(\x0B2\x11.google.type.ExprB\x03\xE0A\x01\x12+\x0A\x19allow_subject_passthrough\x18\x02 \x01(\x08B\x03\xE0A\x02H\x00\x88\x01\x01\x125\x0A#allow_subject_alt_names_passthrough\x18\x03 \x01(\x08B\x03\xE0A\x02H\x01\x88\x01\x01B\x1C\x0A\x1A_allow_subject_passthroughB&\x0A\$_allow_subject_alt_names_passthrough\"\xB4\x03\x0A\x1FCertificateExtensionConstraints\x12|\x0A\x10known_extensions\x18\x01 \x03(\x0E2].google.cloud.security.privateca.v1.CertificateExtensionConstraints.KnownCertificateExtensionB\x03\xE0A\x01\x12P\x0A\x15additional_extensions\x18\x02 \x03(\x0B2,.google.cloud.security.privateca.v1.ObjectIdB\x03\xE0A\x01\"\xC0\x01\x0A\x19KnownCertificateExtension\x12+\x0A'KNOWN_CERTIFICATE_EXTENSION_UNSPECIFIED\x10\x00\x12\x12\x0A\x0EBASE_KEY_USAGE\x10\x01\x12\x16\x0A\x12EXTENDED_KEY_USAGE\x10\x02\x12\x0E\x0A\x0ACA_OPTIONS\x10\x03\x12\x0E\x0A\x0APOLICY_IDS\x10\x04\x12\x14\x0A\x10AIA_OCSP_SERVERS\x10\x05\x12\x14\x0A\x10NAME_CONSTRAINTS\x10\x06*\xBE\x01\x0A\x0DAttributeType\x12\x1E\x0A\x1AATTRIBUTE_TYPE_UNSPECIFIED\x10\x00\x12\x0F\x0A\x0BCOMMON_NAME\x10\x01\x12\x10\x0A\x0CCOUNTRY_CODE\x10\x02\x12\x10\x0A\x0CORGANIZATION\x10\x03\x12\x17\x0A\x13ORGANIZATIONAL_UNIT\x10\x04\x12\x0C\x0A\x08LOCALITY\x10\x05\x12\x0C\x0A\x08PROVINCE\x10\x06\x12\x12\x0A\x0ESTREET_ADDRESS\x10\x07\x12\x0F\x0A\x0BPOSTAL_CODE\x10\x08*\x87\x02\x0A\x10RevocationReason\x12!\x0A\x1DREVOCATION_REASON_UNSPECIFIED\x10\x00\x12\x12\x0A\x0EKEY_COMPROMISE\x10\x01\x12\$\x0A CERTIFICATE_AUTHORITY_COMPROMISE\x10\x02\x12\x17\x0A\x13AFFILIATION_CHANGED\x10\x03\x12\x0E\x0A\x0ASUPERSEDED\x10\x04\x12\x1A\x0A\x16CESSATION_OF_OPERATION\x10\x05\x12\x14\x0A\x10CERTIFICATE_HOLD\x10\x06\x12\x17\x0A\x13PRIVILEGE_WITHDRAWN\x10\x07\x12\"\x0A\x1EATTRIBUTE_AUTHORITY_COMPROMISE\x10\x08*o\x0A\x12SubjectRequestMode\x12\$\x0A SUBJECT_REQUEST_MODE_UNSPECIFIED\x10\x00\x12\x0B\x0A\x07DEFAULT\x10\x01\x12\x10\x0A\x0CRDN_SEQUENCE\x10\x03\x12\x14\x0A\x10REFLECTED_SPIFFE\x10\x02B\xFC\x01\x0A&com.google.cloud.security.privateca.v1B\x17PrivateCaResourcesProtoP\x01ZDcloud.google.com/go/security/privateca/apiv1/privatecapb;privatecapb\xAA\x02\"Google.Cloud.Security.PrivateCA.V1\xCA\x02\"Google\\Cloud\\Security\\PrivateCA\\V1\xEA\x02&Google::Cloud::Security::PrivateCA::V1b\x06proto3" + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/GPBMetadata/Google/Cloud/Security/Privateca/V1/Service.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/GPBMetadata/Google/Cloud/Security/Privateca/V1/Service.php new file mode 100644 index 000000000000..9ef4ade00b13 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/GPBMetadata/Google/Cloud/Security/Privateca/V1/Service.php @@ -0,0 +1,34 @@ +internalAddGeneratedFile( + "\x0A\xFCr\x0A0google/cloud/security/privateca/v1/service.proto\x12\"google.cloud.security.privateca.v1\x1A\x17google/api/client.proto\x1A\x1Fgoogle/api/field_behavior.proto\x1A\x1Bgoogle/api/field_info.proto\x1A\x19google/api/resource.proto\x1A2google/cloud/security/privateca/v1/resources.proto\x1A#google/longrunning/operations.proto\x1A\x1Bgoogle/protobuf/empty.proto\x1A google/protobuf/field_mask.proto\x1A\x1Fgoogle/protobuf/timestamp.proto\"\x9F\x02\x0A\x18CreateCertificateRequest\x127\x0A\x06parent\x18\x01 \x01(\x09B'\xE0A\x02\xFAA!\x0A\x1Fprivateca.googleapis.com/CaPool\x12\x1B\x0A\x0Ecertificate_id\x18\x02 \x01(\x09B\x03\xE0A\x01\x12I\x0A\x0Bcertificate\x18\x03 \x01(\x0B2/.google.cloud.security.privateca.v1.CertificateB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x04 \x01(\x09B\x03\xE0A\x01\x12\x1A\x0A\x0Dvalidate_only\x18\x05 \x01(\x08B\x03\xE0A\x01\x12-\x0A issuing_certificate_authority_id\x18\x06 \x01(\x09B\x03\xE0A\x01\"S\x0A\x15GetCertificateRequest\x12:\x0A\x04name\x18\x01 \x01(\x09B,\xE0A\x02\xFAA&\x0A\$privateca.googleapis.com/Certificate\"\xAF\x01\x0A\x17ListCertificatesRequest\x127\x0A\x06parent\x18\x01 \x01(\x09B'\xE0A\x02\xFAA!\x0A\x1Fprivateca.googleapis.com/CaPool\x12\x16\x0A\x09page_size\x18\x02 \x01(\x05B\x03\xE0A\x01\x12\x17\x0A\x0Apage_token\x18\x03 \x01(\x09B\x03\xE0A\x01\x12\x13\x0A\x06filter\x18\x04 \x01(\x09B\x03\xE0A\x01\x12\x15\x0A\x08order_by\x18\x05 \x01(\x09B\x03\xE0A\x01\"\x8F\x01\x0A\x18ListCertificatesResponse\x12E\x0A\x0Ccertificates\x18\x01 \x03(\x0B2/.google.cloud.security.privateca.v1.Certificate\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\x12\x13\x0A\x0Bunreachable\x18\x03 \x03(\x09\"\xBA\x01\x0A\x18RevokeCertificateRequest\x12:\x0A\x04name\x18\x01 \x01(\x09B,\xE0A\x02\xFAA&\x0A\$privateca.googleapis.com/Certificate\x12I\x0A\x06reason\x18\x02 \x01(\x0E24.google.cloud.security.privateca.v1.RevocationReasonB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x03\xE0A\x01\"\xB4\x01\x0A\x18UpdateCertificateRequest\x12I\x0A\x0Bcertificate\x18\x01 \x01(\x0B2/.google.cloud.security.privateca.v1.CertificateB\x03\xE0A\x02\x124\x0A\x0Bupdate_mask\x18\x02 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x03\xE0A\x01\"\x84\x02\x0A#ActivateCertificateAuthorityRequest\x12C\x0A\x04name\x18\x01 \x01(\x09B5\xE0A\x02\xFAA/\x0A-privateca.googleapis.com/CertificateAuthority\x12\x1F\x0A\x12pem_ca_certificate\x18\x02 \x01(\x09B\x03\xE0A\x02\x12V\x0A\x12subordinate_config\x18\x03 \x01(\x0B25.google.cloud.security.privateca.v1.SubordinateConfigB\x03\xE0A\x02\x12\x1F\x0A\x0Arequest_id\x18\x04 \x01(\x09B\x0B\xE0A\x01\xE2\x8C\xCF\xD7\x08\x02\x08\x01\"\xFA\x01\x0A!CreateCertificateAuthorityRequest\x127\x0A\x06parent\x18\x01 \x01(\x09B'\xE0A\x02\xFAA!\x0A\x1Fprivateca.googleapis.com/CaPool\x12%\x0A\x18certificate_authority_id\x18\x02 \x01(\x09B\x03\xE0A\x02\x12\\\x0A\x15certificate_authority\x18\x03 \x01(\x0B28.google.cloud.security.privateca.v1.CertificateAuthorityB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x04 \x01(\x09B\x03\xE0A\x01\"\xB3\x01\x0A\"DisableCertificateAuthorityRequest\x12C\x0A\x04name\x18\x01 \x01(\x09B5\xE0A\x02\xFAA/\x0A-privateca.googleapis.com/CertificateAuthority\x12\x1F\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x0B\xE0A\x01\xE2\x8C\xCF\xD7\x08\x02\x08\x01\x12'\x0A\x1Aignore_dependent_resources\x18\x03 \x01(\x08B\x03\xE0A\x01\"\x89\x01\x0A!EnableCertificateAuthorityRequest\x12C\x0A\x04name\x18\x01 \x01(\x09B5\xE0A\x02\xFAA/\x0A-privateca.googleapis.com/CertificateAuthority\x12\x1F\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x0B\xE0A\x01\xE2\x8C\xCF\xD7\x08\x02\x08\x01\"j\x0A#FetchCertificateAuthorityCsrRequest\x12C\x0A\x04name\x18\x01 \x01(\x09B5\xE0A\x02\xFAA/\x0A-privateca.googleapis.com/CertificateAuthority\"<\x0A\$FetchCertificateAuthorityCsrResponse\x12\x14\x0A\x07pem_csr\x18\x01 \x01(\x09B\x03\xE0A\x03\"e\x0A\x1EGetCertificateAuthorityRequest\x12C\x0A\x04name\x18\x01 \x01(\x09B5\xE0A\x02\xFAA/\x0A-privateca.googleapis.com/CertificateAuthority\"\xB9\x01\x0A!ListCertificateAuthoritiesRequest\x127\x0A\x06parent\x18\x01 \x01(\x09B'\xE0A\x02\xFAA!\x0A\x1Fprivateca.googleapis.com/CaPool\x12\x16\x0A\x09page_size\x18\x02 \x01(\x05B\x03\xE0A\x01\x12\x17\x0A\x0Apage_token\x18\x03 \x01(\x09B\x03\xE0A\x01\x12\x13\x0A\x06filter\x18\x04 \x01(\x09B\x03\xE0A\x01\x12\x15\x0A\x08order_by\x18\x05 \x01(\x09B\x03\xE0A\x01\"\xAD\x01\x0A\"ListCertificateAuthoritiesResponse\x12Y\x0A\x17certificate_authorities\x18\x01 \x03(\x0B28.google.cloud.security.privateca.v1.CertificateAuthority\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\x12\x13\x0A\x0Bunreachable\x18\x03 \x03(\x09\"\x8B\x01\x0A#UndeleteCertificateAuthorityRequest\x12C\x0A\x04name\x18\x01 \x01(\x09B5\xE0A\x02\xFAA/\x0A-privateca.googleapis.com/CertificateAuthority\x12\x1F\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x0B\xE0A\x01\xE2\x8C\xCF\xD7\x08\x02\x08\x01\"\xFB\x01\x0A!DeleteCertificateAuthorityRequest\x12C\x0A\x04name\x18\x01 \x01(\x09B5\xE0A\x02\xFAA/\x0A-privateca.googleapis.com/CertificateAuthority\x12\x1F\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x0B\xE0A\x01\xE2\x8C\xCF\xD7\x08\x02\x08\x01\x12'\x0A\x1Aignore_active_certificates\x18\x04 \x01(\x08B\x03\xE0A\x01\x12\x1E\x0A\x11skip_grace_period\x18\x05 \x01(\x08B\x03\xE0A\x01\x12'\x0A\x1Aignore_dependent_resources\x18\x06 \x01(\x08B\x03\xE0A\x01\"\xD8\x01\x0A!UpdateCertificateAuthorityRequest\x12\\\x0A\x15certificate_authority\x18\x01 \x01(\x0B28.google.cloud.security.privateca.v1.CertificateAuthorityB\x03\xE0A\x02\x124\x0A\x0Bupdate_mask\x18\x02 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x02\x12\x1F\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x0B\xE0A\x01\xE2\x8C\xCF\xD7\x08\x02\x08\x01\"\xCC\x01\x0A\x13CreateCaPoolRequest\x129\x0A\x06parent\x18\x01 \x01(\x09B)\xE0A\x02\xFAA#\x0A!locations.googleapis.com/Location\x12\x17\x0A\x0Aca_pool_id\x18\x02 \x01(\x09B\x03\xE0A\x02\x12@\x0A\x07ca_pool\x18\x03 \x01(\x0B2*.google.cloud.security.privateca.v1.CaPoolB\x03\xE0A\x02\x12\x1F\x0A\x0Arequest_id\x18\x04 \x01(\x09B\x0B\xE0A\x01\xE2\x8C\xCF\xD7\x08\x02\x08\x01\"\xAE\x01\x0A\x13UpdateCaPoolRequest\x12@\x0A\x07ca_pool\x18\x01 \x01(\x0B2*.google.cloud.security.privateca.v1.CaPoolB\x03\xE0A\x02\x124\x0A\x0Bupdate_mask\x18\x02 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x02\x12\x1F\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x0B\xE0A\x01\xE2\x8C\xCF\xD7\x08\x02\x08\x01\"\x96\x01\x0A\x13DeleteCaPoolRequest\x125\x0A\x04name\x18\x01 \x01(\x09B'\xE0A\x02\xFAA!\x0A\x1Fprivateca.googleapis.com/CaPool\x12\x1F\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x0B\xE0A\x01\xE2\x8C\xCF\xD7\x08\x02\x08\x01\x12'\x0A\x1Aignore_dependent_resources\x18\x04 \x01(\x08B\x03\xE0A\x01\"h\x0A\x13FetchCaCertsRequest\x128\x0A\x07ca_pool\x18\x01 \x01(\x09B'\xE0A\x02\xFAA!\x0A\x1Fprivateca.googleapis.com/CaPool\x12\x17\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x03\xE0A\x01\"\x8F\x01\x0A\x14FetchCaCertsResponse\x12T\x0A\x08ca_certs\x18\x01 \x03(\x0B2B.google.cloud.security.privateca.v1.FetchCaCertsResponse.CertChain\x1A!\x0A\x09CertChain\x12\x14\x0A\x0Ccertificates\x18\x01 \x03(\x09\"I\x0A\x10GetCaPoolRequest\x125\x0A\x04name\x18\x01 \x01(\x09B'\xE0A\x02\xFAA!\x0A\x1Fprivateca.googleapis.com/CaPool\"\xAC\x01\x0A\x12ListCaPoolsRequest\x129\x0A\x06parent\x18\x01 \x01(\x09B)\xE0A\x02\xFAA#\x0A!locations.googleapis.com/Location\x12\x16\x0A\x09page_size\x18\x02 \x01(\x05B\x03\xE0A\x01\x12\x17\x0A\x0Apage_token\x18\x03 \x01(\x09B\x03\xE0A\x01\x12\x13\x0A\x06filter\x18\x04 \x01(\x09B\x03\xE0A\x01\x12\x15\x0A\x08order_by\x18\x05 \x01(\x09B\x03\xE0A\x01\"\x81\x01\x0A\x13ListCaPoolsResponse\x12<\x0A\x08ca_pools\x18\x01 \x03(\x0B2*.google.cloud.security.privateca.v1.CaPool\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\x12\x13\x0A\x0Bunreachable\x18\x03 \x03(\x09\"o\x0A#GetCertificateRevocationListRequest\x12H\x0A\x04name\x18\x01 \x01(\x09B:\xE0A\x02\xFAA4\x0A2privateca.googleapis.com/CertificateRevocationList\"\xCB\x01\x0A%ListCertificateRevocationListsRequest\x12E\x0A\x06parent\x18\x01 \x01(\x09B5\xE0A\x02\xFAA/\x0A-privateca.googleapis.com/CertificateAuthority\x12\x16\x0A\x09page_size\x18\x02 \x01(\x05B\x03\xE0A\x01\x12\x17\x0A\x0Apage_token\x18\x03 \x01(\x09B\x03\xE0A\x01\x12\x13\x0A\x06filter\x18\x04 \x01(\x09B\x03\xE0A\x01\x12\x15\x0A\x08order_by\x18\x05 \x01(\x09B\x03\xE0A\x01\"\xBB\x01\x0A&ListCertificateRevocationListsResponse\x12c\x0A\x1Ccertificate_revocation_lists\x18\x01 \x03(\x0B2=.google.cloud.security.privateca.v1.CertificateRevocationList\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\x12\x13\x0A\x0Bunreachable\x18\x03 \x03(\x09\"\xE0\x01\x0A&UpdateCertificateRevocationListRequest\x12g\x0A\x1Bcertificate_revocation_list\x18\x01 \x01(\x0B2=.google.cloud.security.privateca.v1.CertificateRevocationListB\x03\xE0A\x02\x124\x0A\x0Bupdate_mask\x18\x02 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x03\xE0A\x01\"\x80\x02\x0A CreateCertificateTemplateRequest\x129\x0A\x06parent\x18\x01 \x01(\x09B)\xE0A\x02\xFAA#\x0A!locations.googleapis.com/Location\x12\$\x0A\x17certificate_template_id\x18\x02 \x01(\x09B\x03\xE0A\x02\x12Z\x0A\x14certificate_template\x18\x03 \x01(\x0B27.google.cloud.security.privateca.v1.CertificateTemplateB\x03\xE0A\x02\x12\x1F\x0A\x0Arequest_id\x18\x04 \x01(\x09B\x0B\xE0A\x01\xE2\x8C\xCF\xD7\x08\x02\x08\x01\"\x87\x01\x0A DeleteCertificateTemplateRequest\x12B\x0A\x04name\x18\x01 \x01(\x09B4\xE0A\x02\xFAA.\x0A,privateca.googleapis.com/CertificateTemplate\x12\x1F\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x0B\xE0A\x01\xE2\x8C\xCF\xD7\x08\x02\x08\x01\"c\x0A\x1DGetCertificateTemplateRequest\x12B\x0A\x04name\x18\x01 \x01(\x09B4\xE0A\x02\xFAA.\x0A,privateca.googleapis.com/CertificateTemplate\"\xB9\x01\x0A\x1FListCertificateTemplatesRequest\x129\x0A\x06parent\x18\x01 \x01(\x09B)\xE0A\x02\xFAA#\x0A!locations.googleapis.com/Location\x12\x16\x0A\x09page_size\x18\x02 \x01(\x05B\x03\xE0A\x01\x12\x17\x0A\x0Apage_token\x18\x03 \x01(\x09B\x03\xE0A\x01\x12\x13\x0A\x06filter\x18\x04 \x01(\x09B\x03\xE0A\x01\x12\x15\x0A\x08order_by\x18\x05 \x01(\x09B\x03\xE0A\x01\"\xA8\x01\x0A ListCertificateTemplatesResponse\x12V\x0A\x15certificate_templates\x18\x01 \x03(\x0B27.google.cloud.security.privateca.v1.CertificateTemplate\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\x12\x13\x0A\x0Bunreachable\x18\x03 \x03(\x09\"\xD5\x01\x0A UpdateCertificateTemplateRequest\x12Z\x0A\x14certificate_template\x18\x01 \x01(\x0B27.google.cloud.security.privateca.v1.CertificateTemplateB\x03\xE0A\x02\x124\x0A\x0Bupdate_mask\x18\x02 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x02\x12\x1F\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x0B\xE0A\x01\xE2\x8C\xCF\xD7\x08\x02\x08\x01\"\x80\x02\x0A\x11OperationMetadata\x124\x0A\x0Bcreate_time\x18\x01 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x121\x0A\x08end_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12\x13\x0A\x06target\x18\x03 \x01(\x09B\x03\xE0A\x03\x12\x11\x0A\x04verb\x18\x04 \x01(\x09B\x03\xE0A\x03\x12\x1B\x0A\x0Estatus_message\x18\x05 \x01(\x09B\x03\xE0A\x03\x12#\x0A\x16requested_cancellation\x18\x06 \x01(\x08B\x03\xE0A\x03\x12\x18\x0A\x0Bapi_version\x18\x07 \x01(\x09B\x03\xE0A\x032\xFA;\x0A\x1BCertificateAuthorityService\x12\xF7\x01\x0A\x11CreateCertificate\x12<.google.cloud.security.privateca.v1.CreateCertificateRequest\x1A/.google.cloud.security.privateca.v1.Certificate\"s\xDAA!parent,certificate,certificate_id\x82\xD3\xE4\x93\x02I\":/v1/{parent=projects/*/locations/*/caPools/*}/certificates:\x0Bcertificate\x12\xC7\x01\x0A\x0EGetCertificate\x129.google.cloud.security.privateca.v1.GetCertificateRequest\x1A/.google.cloud.security.privateca.v1.Certificate\"I\xDAA\x04name\x82\xD3\xE4\x93\x02<\x12:/v1/{name=projects/*/locations/*/caPools/*/certificates/*}\x12\xDA\x01\x0A\x10ListCertificates\x12;.google.cloud.security.privateca.v1.ListCertificatesRequest\x1A<.google.cloud.security.privateca.v1.ListCertificatesResponse\"K\xDAA\x06parent\x82\xD3\xE4\x93\x02<\x12:/v1/{parent=projects/*/locations/*/caPools/*}/certificates\x12\xD7\x01\x0A\x11RevokeCertificate\x12<.google.cloud.security.privateca.v1.RevokeCertificateRequest\x1A/.google.cloud.security.privateca.v1.Certificate\"S\xDAA\x04name\x82\xD3\xE4\x93\x02F\"A/v1/{name=projects/*/locations/*/caPools/*/certificates/*}:revoke:\x01*\x12\xF9\x01\x0A\x11UpdateCertificate\x12<.google.cloud.security.privateca.v1.UpdateCertificateRequest\x1A/.google.cloud.security.privateca.v1.Certificate\"u\xDAA\x17certificate,update_mask\x82\xD3\xE4\x93\x02U2F/v1/{certificate.name=projects/*/locations/*/caPools/*/certificates/*}:\x0Bcertificate\x12\x94\x02\x0A\x1CActivateCertificateAuthority\x12G.google.cloud.security.privateca.v1.ActivateCertificateAuthorityRequest\x1A\x1D.google.longrunning.Operation\"\x8B\x01\xCAA)\x0A\x14CertificateAuthority\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x02R\"M/v1/{name=projects/*/locations/*/caPools/*/certificateAuthorities/*}:activate:\x01*\x12\xCC\x02\x0A\x1ACreateCertificateAuthority\x12E.google.cloud.security.privateca.v1.CreateCertificateAuthorityRequest\x1A\x1D.google.longrunning.Operation\"\xC7\x01\xCAA)\x0A\x14CertificateAuthority\x12\x11OperationMetadata\xDAA5parent,certificate_authority,certificate_authority_id\x82\xD3\xE4\x93\x02]\"D/v1/{parent=projects/*/locations/*/caPools/*}/certificateAuthorities:\x15certificate_authority\x12\x91\x02\x0A\x1BDisableCertificateAuthority\x12F.google.cloud.security.privateca.v1.DisableCertificateAuthorityRequest\x1A\x1D.google.longrunning.Operation\"\x8A\x01\xCAA)\x0A\x14CertificateAuthority\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x02Q\"L/v1/{name=projects/*/locations/*/caPools/*/certificateAuthorities/*}:disable:\x01*\x12\x8E\x02\x0A\x1AEnableCertificateAuthority\x12E.google.cloud.security.privateca.v1.EnableCertificateAuthorityRequest\x1A\x1D.google.longrunning.Operation\"\x89\x01\xCAA)\x0A\x14CertificateAuthority\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x02P\"K/v1/{name=projects/*/locations/*/caPools/*/certificateAuthorities/*}:enable:\x01*\x12\x8C\x02\x0A\x1CFetchCertificateAuthorityCsr\x12G.google.cloud.security.privateca.v1.FetchCertificateAuthorityCsrRequest\x1AH.google.cloud.security.privateca.v1.FetchCertificateAuthorityCsrResponse\"Y\xDAA\x04name\x82\xD3\xE4\x93\x02L\x12J/v1/{name=projects/*/locations/*/caPools/*/certificateAuthorities/*}:fetch\x12\xEC\x01\x0A\x17GetCertificateAuthority\x12B.google.cloud.security.privateca.v1.GetCertificateAuthorityRequest\x1A8.google.cloud.security.privateca.v1.CertificateAuthority\"S\xDAA\x04name\x82\xD3\xE4\x93\x02F\x12D/v1/{name=projects/*/locations/*/caPools/*/certificateAuthorities/*}\x12\x82\x02\x0A\x1AListCertificateAuthorities\x12E.google.cloud.security.privateca.v1.ListCertificateAuthoritiesRequest\x1AF.google.cloud.security.privateca.v1.ListCertificateAuthoritiesResponse\"U\xDAA\x06parent\x82\xD3\xE4\x93\x02F\x12D/v1/{parent=projects/*/locations/*/caPools/*}/certificateAuthorities\x12\x94\x02\x0A\x1CUndeleteCertificateAuthority\x12G.google.cloud.security.privateca.v1.UndeleteCertificateAuthorityRequest\x1A\x1D.google.longrunning.Operation\"\x8B\x01\xCAA)\x0A\x14CertificateAuthority\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x02R\"M/v1/{name=projects/*/locations/*/caPools/*/certificateAuthorities/*}:undelete:\x01*\x12\x83\x02\x0A\x1ADeleteCertificateAuthority\x12E.google.cloud.security.privateca.v1.DeleteCertificateAuthorityRequest\x1A\x1D.google.longrunning.Operation\"\x7F\xCAA)\x0A\x14CertificateAuthority\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x02F*D/v1/{name=projects/*/locations/*/caPools/*/certificateAuthorities/*}\x12\xCE\x02\x0A\x1AUpdateCertificateAuthority\x12E.google.cloud.security.privateca.v1.UpdateCertificateAuthorityRequest\x1A\x1D.google.longrunning.Operation\"\xC9\x01\xCAA)\x0A\x14CertificateAuthority\x12\x11OperationMetadata\xDAA!certificate_authority,update_mask\x82\xD3\xE4\x93\x02s2Z/v1/{certificate_authority.name=projects/*/locations/*/caPools/*/certificateAuthorities/*}:\x15certificate_authority\x12\xDE\x01\x0A\x0CCreateCaPool\x127.google.cloud.security.privateca.v1.CreateCaPoolRequest\x1A\x1D.google.longrunning.Operation\"v\xCAA\x1B\x0A\x06CaPool\x12\x11OperationMetadata\xDAA\x19parent,ca_pool,ca_pool_id\x82\xD3\xE4\x93\x026\"+/v1/{parent=projects/*/locations/*}/caPools:\x07ca_pool\x12\xE0\x01\x0A\x0CUpdateCaPool\x127.google.cloud.security.privateca.v1.UpdateCaPoolRequest\x1A\x1D.google.longrunning.Operation\"x\xCAA\x1B\x0A\x06CaPool\x12\x11OperationMetadata\xDAA\x13ca_pool,update_mask\x82\xD3\xE4\x93\x02>23/v1/{ca_pool.name=projects/*/locations/*/caPools/*}:\x07ca_pool\x12\xA9\x01\x0A\x09GetCaPool\x124.google.cloud.security.privateca.v1.GetCaPoolRequest\x1A*.google.cloud.security.privateca.v1.CaPool\":\xDAA\x04name\x82\xD3\xE4\x93\x02-\x12+/v1/{name=projects/*/locations/*/caPools/*}\x12\xBC\x01\x0A\x0BListCaPools\x126.google.cloud.security.privateca.v1.ListCaPoolsRequest\x1A7.google.cloud.security.privateca.v1.ListCaPoolsResponse\"<\xDAA\x06parent\x82\xD3\xE4\x93\x02-\x12+/v1/{parent=projects/*/locations/*}/caPools\x12\xCF\x01\x0A\x0CDeleteCaPool\x127.google.cloud.security.privateca.v1.DeleteCaPoolRequest\x1A\x1D.google.longrunning.Operation\"g\xCAA*\x0A\x15google.protobuf.Empty\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x02-*+/v1/{name=projects/*/locations/*/caPools/*}\x12\xD3\x01\x0A\x0CFetchCaCerts\x127.google.cloud.security.privateca.v1.FetchCaCertsRequest\x1A8.google.cloud.security.privateca.v1.FetchCaCertsResponse\"P\xDAA\x07ca_pool\x82\xD3\xE4\x93\x02@\";/v1/{ca_pool=projects/*/locations/*/caPools/*}:fetchCaCerts:\x01*\x12\x98\x02\x0A\x1CGetCertificateRevocationList\x12G.google.cloud.security.privateca.v1.GetCertificateRevocationListRequest\x1A=.google.cloud.security.privateca.v1.CertificateRevocationList\"p\xDAA\x04name\x82\xD3\xE4\x93\x02c\x12a/v1/{name=projects/*/locations/*/caPools/*/certificateAuthorities/*/certificateRevocationLists/*}\x12\xAB\x02\x0A\x1EListCertificateRevocationLists\x12I.google.cloud.security.privateca.v1.ListCertificateRevocationListsRequest\x1AJ.google.cloud.security.privateca.v1.ListCertificateRevocationListsResponse\"r\xDAA\x06parent\x82\xD3\xE4\x93\x02c\x12a/v1/{parent=projects/*/locations/*/caPools/*/certificateAuthorities/*}/certificateRevocationLists\x12\x8D\x03\x0A\x1FUpdateCertificateRevocationList\x12J.google.cloud.security.privateca.v1.UpdateCertificateRevocationListRequest\x1A\x1D.google.longrunning.Operation\"\xFE\x01\xCAA.\x0A\x19CertificateRevocationList\x12\x11OperationMetadata\xDAA'certificate_revocation_list,update_mask\x82\xD3\xE4\x93\x02\x9C\x012}/v1/{certificate_revocation_list.name=projects/*/locations/*/caPools/*/certificateAuthorities/*/certificateRevocationLists/*}:\x1Bcertificate_revocation_list\x12\xBA\x02\x0A\x19CreateCertificateTemplate\x12D.google.cloud.security.privateca.v1.CreateCertificateTemplateRequest\x1A\x1D.google.longrunning.Operation\"\xB7\x01\xCAA(\x0A\x13CertificateTemplate\x12\x11OperationMetadata\xDAA3parent,certificate_template,certificate_template_id\x82\xD3\xE4\x93\x02P\"8/v1/{parent=projects/*/locations/*}/certificateTemplates:\x14certificate_template\x12\x9A\x02\x0A\x19DeleteCertificateTemplate\x12D.google.cloud.security.privateca.v1.DeleteCertificateTemplateRequest\x1A\x1D.google.longrunning.Operation\"\x97\x01\xCAAM\x0A\x15google.protobuf.Empty\x124google.cloud.security.privateca.v1.OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x02:*8/v1/{name=projects/*/locations/*/certificateTemplates/*}\x12\xDD\x01\x0A\x16GetCertificateTemplate\x12A.google.cloud.security.privateca.v1.GetCertificateTemplateRequest\x1A7.google.cloud.security.privateca.v1.CertificateTemplate\"G\xDAA\x04name\x82\xD3\xE4\x93\x02:\x128/v1/{name=projects/*/locations/*/certificateTemplates/*}\x12\xF0\x01\x0A\x18ListCertificateTemplates\x12C.google.cloud.security.privateca.v1.ListCertificateTemplatesRequest\x1AD.google.cloud.security.privateca.v1.ListCertificateTemplatesResponse\"I\xDAA\x06parent\x82\xD3\xE4\x93\x02:\x128/v1/{parent=projects/*/locations/*}/certificateTemplates\x12\xBC\x02\x0A\x19UpdateCertificateTemplate\x12D.google.cloud.security.privateca.v1.UpdateCertificateTemplateRequest\x1A\x1D.google.longrunning.Operation\"\xB9\x01\xCAA(\x0A\x13CertificateTemplate\x12\x11OperationMetadata\xDAA certificate_template,update_mask\x82\xD3\xE4\x93\x02e2M/v1/{certificate_template.name=projects/*/locations/*/certificateTemplates/*}:\x14certificate_template\x1AL\xCAA\x18privateca.googleapis.com\xD2A.https://www.googleapis.com/auth/cloud-platformB\xF3\x01\x0A&com.google.cloud.security.privateca.v1B\x0EPrivateCaProtoP\x01ZDcloud.google.com/go/security/privateca/apiv1/privatecapb;privatecapb\xAA\x02\"Google.Cloud.Security.PrivateCA.V1\xCA\x02\"Google\\Cloud\\Security\\PrivateCA\\V1\xEA\x02&Google::Cloud::Security::PrivateCA::V1b\x06proto3" + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ActivateCertificateAuthorityRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ActivateCertificateAuthorityRequest.php new file mode 100644 index 000000000000..8e1b5c725c04 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ActivateCertificateAuthorityRequest.php @@ -0,0 +1,252 @@ +google.cloud.security.privateca.v1.ActivateCertificateAuthorityRequest + */ +class ActivateCertificateAuthorityRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name for this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * Required. The signed CA certificate issued from + * [FetchCertificateAuthorityCsrResponse.pem_csr][google.cloud.security.privateca.v1.FetchCertificateAuthorityCsrResponse.pem_csr]. + * + * Generated from protobuf field string pem_ca_certificate = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $pem_ca_certificate = ''; + /** + * Required. Must include information about the issuer of + * 'pem_ca_certificate', and any further issuers until the self-signed CA. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.SubordinateConfig subordinate_config = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $subordinate_config = null; + /** + * Optional. An 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, (.google.api.field_info) = { + */ + protected $request_id = ''; + + /** + * @param string $name Required. The resource name for this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the format `projects/*/locations/*/caPools/*/certificateAuthorities/*`. Please see + * {@see CertificateAuthorityServiceClient::certificateAuthorityName()} for help formatting this field. + * + * @return \Google\Cloud\Security\PrivateCA\V1\ActivateCertificateAuthorityRequest + * + * @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 for this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. + * @type string $pem_ca_certificate + * Required. The signed CA certificate issued from + * [FetchCertificateAuthorityCsrResponse.pem_csr][google.cloud.security.privateca.v1.FetchCertificateAuthorityCsrResponse.pem_csr]. + * @type \Google\Cloud\Security\PrivateCA\V1\SubordinateConfig $subordinate_config + * Required. Must include information about the issuer of + * 'pem_ca_certificate', and any further issuers until the self-signed CA. + * @type string $request_id + * Optional. An 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\Security\Privateca\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name for this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. + * + * 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 for this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. + * + * 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 signed CA certificate issued from + * [FetchCertificateAuthorityCsrResponse.pem_csr][google.cloud.security.privateca.v1.FetchCertificateAuthorityCsrResponse.pem_csr]. + * + * Generated from protobuf field string pem_ca_certificate = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getPemCaCertificate() + { + return $this->pem_ca_certificate; + } + + /** + * Required. The signed CA certificate issued from + * [FetchCertificateAuthorityCsrResponse.pem_csr][google.cloud.security.privateca.v1.FetchCertificateAuthorityCsrResponse.pem_csr]. + * + * Generated from protobuf field string pem_ca_certificate = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setPemCaCertificate($var) + { + GPBUtil::checkString($var, True); + $this->pem_ca_certificate = $var; + + return $this; + } + + /** + * Required. Must include information about the issuer of + * 'pem_ca_certificate', and any further issuers until the self-signed CA. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.SubordinateConfig subordinate_config = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Security\PrivateCA\V1\SubordinateConfig|null + */ + public function getSubordinateConfig() + { + return $this->subordinate_config; + } + + public function hasSubordinateConfig() + { + return isset($this->subordinate_config); + } + + public function clearSubordinateConfig() + { + unset($this->subordinate_config); + } + + /** + * Required. Must include information about the issuer of + * 'pem_ca_certificate', and any further issuers until the self-signed CA. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.SubordinateConfig subordinate_config = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Security\PrivateCA\V1\SubordinateConfig $var + * @return $this + */ + public function setSubordinateConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\SubordinateConfig::class); + $this->subordinate_config = $var; + + return $this; + } + + /** + * Optional. An 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, (.google.api.field_info) = { + * @return string + */ + public function getRequestId() + { + return $this->request_id; + } + + /** + * Optional. An 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, (.google.api.field_info) = { + * @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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/AttributeType.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/AttributeType.php new file mode 100644 index 000000000000..d96495de8a1e --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/AttributeType.php @@ -0,0 +1,104 @@ +google.cloud.security.privateca.v1.AttributeType + */ +class AttributeType +{ + /** + * Attribute type is unspecified. + * + * Generated from protobuf enum ATTRIBUTE_TYPE_UNSPECIFIED = 0; + */ + const ATTRIBUTE_TYPE_UNSPECIFIED = 0; + /** + * The "common name" of the subject. + * + * Generated from protobuf enum COMMON_NAME = 1; + */ + const COMMON_NAME = 1; + /** + * The country code of the subject. + * + * Generated from protobuf enum COUNTRY_CODE = 2; + */ + const COUNTRY_CODE = 2; + /** + * The organization of the subject. + * + * Generated from protobuf enum ORGANIZATION = 3; + */ + const ORGANIZATION = 3; + /** + * The organizational unit of the subject. + * + * Generated from protobuf enum ORGANIZATIONAL_UNIT = 4; + */ + const ORGANIZATIONAL_UNIT = 4; + /** + * The locality or city of the subject. + * + * Generated from protobuf enum LOCALITY = 5; + */ + const LOCALITY = 5; + /** + * The province, territory, or regional state of the subject. + * + * Generated from protobuf enum PROVINCE = 6; + */ + const PROVINCE = 6; + /** + * The street address of the subject. + * + * Generated from protobuf enum STREET_ADDRESS = 7; + */ + const STREET_ADDRESS = 7; + /** + * The postal code of the subject. + * + * Generated from protobuf enum POSTAL_CODE = 8; + */ + const POSTAL_CODE = 8; + + private static $valueToName = [ + self::ATTRIBUTE_TYPE_UNSPECIFIED => 'ATTRIBUTE_TYPE_UNSPECIFIED', + self::COMMON_NAME => 'COMMON_NAME', + self::COUNTRY_CODE => 'COUNTRY_CODE', + self::ORGANIZATION => 'ORGANIZATION', + self::ORGANIZATIONAL_UNIT => 'ORGANIZATIONAL_UNIT', + self::LOCALITY => 'LOCALITY', + self::PROVINCE => 'PROVINCE', + self::STREET_ADDRESS => 'STREET_ADDRESS', + self::POSTAL_CODE => 'POSTAL_CODE', + ]; + + 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/AttributeTypeAndValue.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/AttributeTypeAndValue.php new file mode 100644 index 000000000000..532af418ab7f --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/AttributeTypeAndValue.php @@ -0,0 +1,144 @@ +google.cloud.security.privateca.v1.AttributeTypeAndValue + */ +class AttributeTypeAndValue extends \Google\Protobuf\Internal\Message +{ + /** + * The value for the attribute type. + * + * Generated from protobuf field string value = 3; + */ + protected $value = ''; + protected $attribute_type; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $type + * The attribute type of the attribute and value pair. + * @type \Google\Cloud\Security\PrivateCA\V1\ObjectId $object_id + * Object ID for an attribute type of an attribute and value pair. + * @type string $value + * The value for the attribute type. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * The attribute type of the attribute and value pair. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.AttributeType type = 1; + * @return int + */ + public function getType() + { + return $this->readOneof(1); + } + + public function hasType() + { + return $this->hasOneof(1); + } + + /** + * The attribute type of the attribute and value pair. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.AttributeType type = 1; + * @param int $var + * @return $this + */ + public function setType($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Security\PrivateCA\V1\AttributeType::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * Object ID for an attribute type of an attribute and value pair. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.ObjectId object_id = 2; + * @return \Google\Cloud\Security\PrivateCA\V1\ObjectId|null + */ + public function getObjectId() + { + return $this->readOneof(2); + } + + public function hasObjectId() + { + return $this->hasOneof(2); + } + + /** + * Object ID for an attribute type of an attribute and value pair. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.ObjectId object_id = 2; + * @param \Google\Cloud\Security\PrivateCA\V1\ObjectId $var + * @return $this + */ + public function setObjectId($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\ObjectId::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * The value for the attribute type. + * + * Generated from protobuf field string value = 3; + * @return string + */ + public function getValue() + { + return $this->value; + } + + /** + * The value for the attribute type. + * + * Generated from protobuf field string value = 3; + * @param string $var + * @return $this + */ + public function setValue($var) + { + GPBUtil::checkString($var, True); + $this->value = $var; + + return $this; + } + + /** + * @return string + */ + public function getAttributeType() + { + return $this->whichOneof("attribute_type"); + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool.php new file mode 100644 index 000000000000..73c9ce2d9be6 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool.php @@ -0,0 +1,341 @@ +google.cloud.security.privateca.v1.CaPool + */ +class CaPool extends \Google\Protobuf\Internal\Message +{ + /** + * Identifier. The resource name for this + * [CaPool][google.cloud.security.privateca.v1.CaPool] in the format + * `projects/{@*}locations/{@*}caPools/*`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + */ + protected $name = ''; + /** + * Required. Immutable. The + * [Tier][google.cloud.security.privateca.v1.CaPool.Tier] of this + * [CaPool][google.cloud.security.privateca.v1.CaPool]. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.Tier tier = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + */ + protected $tier = 0; + /** + * Optional. The + * [IssuancePolicy][google.cloud.security.privateca.v1.CaPool.IssuancePolicy] + * to control how + * [Certificates][google.cloud.security.privateca.v1.Certificate] will be + * issued from this [CaPool][google.cloud.security.privateca.v1.CaPool]. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.IssuancePolicy issuance_policy = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $issuance_policy = null; + /** + * Optional. The + * [PublishingOptions][google.cloud.security.privateca.v1.CaPool.PublishingOptions] + * to follow when issuing + * [Certificates][google.cloud.security.privateca.v1.Certificate] from any + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in this [CaPool][google.cloud.security.privateca.v1.CaPool]. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.PublishingOptions publishing_options = 4 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $publishing_options = null; + /** + * Optional. When + * [EncryptionSpec][google.cloud.security.privateca.v1.EncryptionSpec] is + * provided, the [Subject][google.cloud.security.privateca.v1.Subject], + * [SubjectAltNames][google.cloud.security.privateca.v1.SubjectAltNames], and + * the PEM-encoded certificate fields will be encrypted at rest. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.EncryptionSpec encryption_spec = 8 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $encryption_spec = null; + /** + * Optional. Labels with user-defined metadata. + * + * Generated from protobuf field map labels = 5 [(.google.api.field_behavior) = OPTIONAL]; + */ + private $labels; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Identifier. The resource name for this + * [CaPool][google.cloud.security.privateca.v1.CaPool] in the format + * `projects/{@*}locations/{@*}caPools/*`. + * @type int $tier + * Required. Immutable. The + * [Tier][google.cloud.security.privateca.v1.CaPool.Tier] of this + * [CaPool][google.cloud.security.privateca.v1.CaPool]. + * @type \Google\Cloud\Security\PrivateCA\V1\CaPool\IssuancePolicy $issuance_policy + * Optional. The + * [IssuancePolicy][google.cloud.security.privateca.v1.CaPool.IssuancePolicy] + * to control how + * [Certificates][google.cloud.security.privateca.v1.Certificate] will be + * issued from this [CaPool][google.cloud.security.privateca.v1.CaPool]. + * @type \Google\Cloud\Security\PrivateCA\V1\CaPool\PublishingOptions $publishing_options + * Optional. The + * [PublishingOptions][google.cloud.security.privateca.v1.CaPool.PublishingOptions] + * to follow when issuing + * [Certificates][google.cloud.security.privateca.v1.Certificate] from any + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in this [CaPool][google.cloud.security.privateca.v1.CaPool]. + * @type \Google\Cloud\Security\PrivateCA\V1\EncryptionSpec $encryption_spec + * Optional. When + * [EncryptionSpec][google.cloud.security.privateca.v1.EncryptionSpec] is + * provided, the [Subject][google.cloud.security.privateca.v1.Subject], + * [SubjectAltNames][google.cloud.security.privateca.v1.SubjectAltNames], and + * the PEM-encoded certificate fields will be encrypted at rest. + * @type array|\Google\Protobuf\Internal\MapField $labels + * Optional. Labels with user-defined metadata. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * Identifier. The resource name for this + * [CaPool][google.cloud.security.privateca.v1.CaPool] in the format + * `projects/{@*}locations/{@*}caPools/*`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Identifier. The resource name for this + * [CaPool][google.cloud.security.privateca.v1.CaPool] in the format + * `projects/{@*}locations/{@*}caPools/*`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Required. Immutable. The + * [Tier][google.cloud.security.privateca.v1.CaPool.Tier] of this + * [CaPool][google.cloud.security.privateca.v1.CaPool]. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.Tier tier = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + * @return int + */ + public function getTier() + { + return $this->tier; + } + + /** + * Required. Immutable. The + * [Tier][google.cloud.security.privateca.v1.CaPool.Tier] of this + * [CaPool][google.cloud.security.privateca.v1.CaPool]. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.Tier tier = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + * @param int $var + * @return $this + */ + public function setTier($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Security\PrivateCA\V1\CaPool\Tier::class); + $this->tier = $var; + + return $this; + } + + /** + * Optional. The + * [IssuancePolicy][google.cloud.security.privateca.v1.CaPool.IssuancePolicy] + * to control how + * [Certificates][google.cloud.security.privateca.v1.Certificate] will be + * issued from this [CaPool][google.cloud.security.privateca.v1.CaPool]. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.IssuancePolicy issuance_policy = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\Security\PrivateCA\V1\CaPool\IssuancePolicy|null + */ + public function getIssuancePolicy() + { + return $this->issuance_policy; + } + + public function hasIssuancePolicy() + { + return isset($this->issuance_policy); + } + + public function clearIssuancePolicy() + { + unset($this->issuance_policy); + } + + /** + * Optional. The + * [IssuancePolicy][google.cloud.security.privateca.v1.CaPool.IssuancePolicy] + * to control how + * [Certificates][google.cloud.security.privateca.v1.Certificate] will be + * issued from this [CaPool][google.cloud.security.privateca.v1.CaPool]. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.IssuancePolicy issuance_policy = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\Security\PrivateCA\V1\CaPool\IssuancePolicy $var + * @return $this + */ + public function setIssuancePolicy($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CaPool\IssuancePolicy::class); + $this->issuance_policy = $var; + + return $this; + } + + /** + * Optional. The + * [PublishingOptions][google.cloud.security.privateca.v1.CaPool.PublishingOptions] + * to follow when issuing + * [Certificates][google.cloud.security.privateca.v1.Certificate] from any + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in this [CaPool][google.cloud.security.privateca.v1.CaPool]. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.PublishingOptions publishing_options = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\Security\PrivateCA\V1\CaPool\PublishingOptions|null + */ + public function getPublishingOptions() + { + return $this->publishing_options; + } + + public function hasPublishingOptions() + { + return isset($this->publishing_options); + } + + public function clearPublishingOptions() + { + unset($this->publishing_options); + } + + /** + * Optional. The + * [PublishingOptions][google.cloud.security.privateca.v1.CaPool.PublishingOptions] + * to follow when issuing + * [Certificates][google.cloud.security.privateca.v1.Certificate] from any + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in this [CaPool][google.cloud.security.privateca.v1.CaPool]. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.PublishingOptions publishing_options = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\Security\PrivateCA\V1\CaPool\PublishingOptions $var + * @return $this + */ + public function setPublishingOptions($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CaPool\PublishingOptions::class); + $this->publishing_options = $var; + + return $this; + } + + /** + * Optional. When + * [EncryptionSpec][google.cloud.security.privateca.v1.EncryptionSpec] is + * provided, the [Subject][google.cloud.security.privateca.v1.Subject], + * [SubjectAltNames][google.cloud.security.privateca.v1.SubjectAltNames], and + * the PEM-encoded certificate fields will be encrypted at rest. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.EncryptionSpec encryption_spec = 8 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\Security\PrivateCA\V1\EncryptionSpec|null + */ + public function getEncryptionSpec() + { + return $this->encryption_spec; + } + + public function hasEncryptionSpec() + { + return isset($this->encryption_spec); + } + + public function clearEncryptionSpec() + { + unset($this->encryption_spec); + } + + /** + * Optional. When + * [EncryptionSpec][google.cloud.security.privateca.v1.EncryptionSpec] is + * provided, the [Subject][google.cloud.security.privateca.v1.Subject], + * [SubjectAltNames][google.cloud.security.privateca.v1.SubjectAltNames], and + * the PEM-encoded certificate fields will be encrypted at rest. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.EncryptionSpec encryption_spec = 8 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\Security\PrivateCA\V1\EncryptionSpec $var + * @return $this + */ + public function setEncryptionSpec($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\EncryptionSpec::class); + $this->encryption_spec = $var; + + return $this; + } + + /** + * Optional. Labels with user-defined metadata. + * + * Generated from protobuf field map labels = 5 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Protobuf\Internal\MapField + */ + public function getLabels() + { + return $this->labels; + } + + /** + * Optional. Labels with user-defined metadata. + * + * Generated from protobuf field map labels = 5 [(.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; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy.php new file mode 100644 index 000000000000..30739bffd916 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy.php @@ -0,0 +1,602 @@ +google.cloud.security.privateca.v1.CaPool.IssuancePolicy + */ +class IssuancePolicy extends \Google\Protobuf\Internal\Message +{ + /** + * Optional. If any + * [AllowedKeyType][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyType] + * is specified, then the certificate request's public key must match one of + * the key types listed here. Otherwise, any key may be used. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyType allowed_key_types = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + private $allowed_key_types; + /** + * Optional. If set, all certificates issued from this + * [CaPool][google.cloud.security.privateca.v1.CaPool] will be backdated by + * this duration. The 'not_before_time' will be the issuance time minus this + * [backdate_duration][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.backdate_duration], + * and the 'not_after_time' will be adjusted to preserve the requested + * lifetime. The maximum duration that a certificate can be backdated with + * these options is 48 hours in the past. + * This option cannot be set if + * [allow_requester_specified_not_before_time][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.allow_requester_specified_not_before_time] + * is set. + * + * Generated from protobuf field .google.protobuf.Duration backdate_duration = 7 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $backdate_duration = null; + /** + * Optional. If set to true, allows requesters to specify the + * [requested_not_before_time][google.cloud.security.privateca.v1.Certificate.requested_not_before_time] + * field when creating a + * [Certificate][google.cloud.security.privateca.v1.Certificate]. + * Certificates requested with this option enabled will have a + * 'not_before_time' equal to the value specified in the request. The + * 'not_after_time' will be adjusted to preserve the requested lifetime. The + * maximum time that a certificate can be backdated with these options is 48 + * hours in the past. This option cannot be set if + * [backdate_duration][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.backdate_duration] + * is set. + * + * Generated from protobuf field bool allow_requester_specified_not_before_time = 8 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $allow_requester_specified_not_before_time = false; + /** + * Optional. The maximum lifetime allowed for issued + * [Certificates][google.cloud.security.privateca.v1.Certificate]. Note that + * if the issuing + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * expires before a + * [Certificate][google.cloud.security.privateca.v1.Certificate] resource's + * requested maximum_lifetime, the effective lifetime will be explicitly + * truncated to match it. + * + * Generated from protobuf field .google.protobuf.Duration maximum_lifetime = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $maximum_lifetime = null; + /** + * Optional. If specified, then only methods allowed in the + * [IssuanceModes][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.IssuanceModes] + * may be used to issue + * [Certificates][google.cloud.security.privateca.v1.Certificate]. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.IssuancePolicy.IssuanceModes allowed_issuance_modes = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $allowed_issuance_modes = null; + /** + * Optional. A set of X.509 values that will be applied to all certificates + * issued through this [CaPool][google.cloud.security.privateca.v1.CaPool]. + * If a certificate request includes conflicting values for the same + * properties, they will be overwritten by the values defined here. If a + * certificate request uses a + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * that defines conflicting + * [predefined_values][google.cloud.security.privateca.v1.CertificateTemplate.predefined_values] + * for the same properties, the certificate issuance request will fail. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.X509Parameters baseline_values = 4 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $baseline_values = null; + /** + * Optional. Describes constraints on identities that may appear in + * [Certificates][google.cloud.security.privateca.v1.Certificate] issued + * through this [CaPool][google.cloud.security.privateca.v1.CaPool]. If this + * is omitted, then this [CaPool][google.cloud.security.privateca.v1.CaPool] + * will not add restrictions on a certificate's identity. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateIdentityConstraints identity_constraints = 5 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $identity_constraints = null; + /** + * Optional. Describes the set of X.509 extensions that may appear in a + * [Certificate][google.cloud.security.privateca.v1.Certificate] issued + * through this [CaPool][google.cloud.security.privateca.v1.CaPool]. If a + * certificate request sets extensions that don't appear in the + * [passthrough_extensions][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.passthrough_extensions], + * those extensions will be dropped. If a certificate request uses a + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * with + * [predefined_values][google.cloud.security.privateca.v1.CertificateTemplate.predefined_values] + * that don't appear here, the certificate issuance request will fail. If + * this is omitted, then this + * [CaPool][google.cloud.security.privateca.v1.CaPool] will not add + * restrictions on a certificate's X.509 extensions. These constraints do + * not apply to X.509 extensions set in this + * [CaPool][google.cloud.security.privateca.v1.CaPool]'s + * [baseline_values][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.baseline_values]. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateExtensionConstraints passthrough_extensions = 6 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $passthrough_extensions = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Security\PrivateCA\V1\CaPool\IssuancePolicy\AllowedKeyType[] $allowed_key_types + * Optional. If any + * [AllowedKeyType][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyType] + * is specified, then the certificate request's public key must match one of + * the key types listed here. Otherwise, any key may be used. + * @type \Google\Protobuf\Duration $backdate_duration + * Optional. If set, all certificates issued from this + * [CaPool][google.cloud.security.privateca.v1.CaPool] will be backdated by + * this duration. The 'not_before_time' will be the issuance time minus this + * [backdate_duration][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.backdate_duration], + * and the 'not_after_time' will be adjusted to preserve the requested + * lifetime. The maximum duration that a certificate can be backdated with + * these options is 48 hours in the past. + * This option cannot be set if + * [allow_requester_specified_not_before_time][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.allow_requester_specified_not_before_time] + * is set. + * @type bool $allow_requester_specified_not_before_time + * Optional. If set to true, allows requesters to specify the + * [requested_not_before_time][google.cloud.security.privateca.v1.Certificate.requested_not_before_time] + * field when creating a + * [Certificate][google.cloud.security.privateca.v1.Certificate]. + * Certificates requested with this option enabled will have a + * 'not_before_time' equal to the value specified in the request. The + * 'not_after_time' will be adjusted to preserve the requested lifetime. The + * maximum time that a certificate can be backdated with these options is 48 + * hours in the past. This option cannot be set if + * [backdate_duration][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.backdate_duration] + * is set. + * @type \Google\Protobuf\Duration $maximum_lifetime + * Optional. The maximum lifetime allowed for issued + * [Certificates][google.cloud.security.privateca.v1.Certificate]. Note that + * if the issuing + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * expires before a + * [Certificate][google.cloud.security.privateca.v1.Certificate] resource's + * requested maximum_lifetime, the effective lifetime will be explicitly + * truncated to match it. + * @type \Google\Cloud\Security\PrivateCA\V1\CaPool\IssuancePolicy\IssuanceModes $allowed_issuance_modes + * Optional. If specified, then only methods allowed in the + * [IssuanceModes][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.IssuanceModes] + * may be used to issue + * [Certificates][google.cloud.security.privateca.v1.Certificate]. + * @type \Google\Cloud\Security\PrivateCA\V1\X509Parameters $baseline_values + * Optional. A set of X.509 values that will be applied to all certificates + * issued through this [CaPool][google.cloud.security.privateca.v1.CaPool]. + * If a certificate request includes conflicting values for the same + * properties, they will be overwritten by the values defined here. If a + * certificate request uses a + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * that defines conflicting + * [predefined_values][google.cloud.security.privateca.v1.CertificateTemplate.predefined_values] + * for the same properties, the certificate issuance request will fail. + * @type \Google\Cloud\Security\PrivateCA\V1\CertificateIdentityConstraints $identity_constraints + * Optional. Describes constraints on identities that may appear in + * [Certificates][google.cloud.security.privateca.v1.Certificate] issued + * through this [CaPool][google.cloud.security.privateca.v1.CaPool]. If this + * is omitted, then this [CaPool][google.cloud.security.privateca.v1.CaPool] + * will not add restrictions on a certificate's identity. + * @type \Google\Cloud\Security\PrivateCA\V1\CertificateExtensionConstraints $passthrough_extensions + * Optional. Describes the set of X.509 extensions that may appear in a + * [Certificate][google.cloud.security.privateca.v1.Certificate] issued + * through this [CaPool][google.cloud.security.privateca.v1.CaPool]. If a + * certificate request sets extensions that don't appear in the + * [passthrough_extensions][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.passthrough_extensions], + * those extensions will be dropped. If a certificate request uses a + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * with + * [predefined_values][google.cloud.security.privateca.v1.CertificateTemplate.predefined_values] + * that don't appear here, the certificate issuance request will fail. If + * this is omitted, then this + * [CaPool][google.cloud.security.privateca.v1.CaPool] will not add + * restrictions on a certificate's X.509 extensions. These constraints do + * not apply to X.509 extensions set in this + * [CaPool][google.cloud.security.privateca.v1.CaPool]'s + * [baseline_values][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.baseline_values]. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * Optional. If any + * [AllowedKeyType][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyType] + * is specified, then the certificate request's public key must match one of + * the key types listed here. Otherwise, any key may be used. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyType allowed_key_types = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @return RepeatedField<\Google\Cloud\Security\PrivateCA\V1\CaPool\IssuancePolicy\AllowedKeyType> + */ + public function getAllowedKeyTypes() + { + return $this->allowed_key_types; + } + + /** + * Optional. If any + * [AllowedKeyType][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyType] + * is specified, then the certificate request's public key must match one of + * the key types listed here. Otherwise, any key may be used. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyType allowed_key_types = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\Security\PrivateCA\V1\CaPool\IssuancePolicy\AllowedKeyType[] $var + * @return $this + */ + public function setAllowedKeyTypes($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Security\PrivateCA\V1\CaPool\IssuancePolicy\AllowedKeyType::class); + $this->allowed_key_types = $arr; + + return $this; + } + + /** + * Optional. If set, all certificates issued from this + * [CaPool][google.cloud.security.privateca.v1.CaPool] will be backdated by + * this duration. The 'not_before_time' will be the issuance time minus this + * [backdate_duration][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.backdate_duration], + * and the 'not_after_time' will be adjusted to preserve the requested + * lifetime. The maximum duration that a certificate can be backdated with + * these options is 48 hours in the past. + * This option cannot be set if + * [allow_requester_specified_not_before_time][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.allow_requester_specified_not_before_time] + * is set. + * + * Generated from protobuf field .google.protobuf.Duration backdate_duration = 7 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Protobuf\Duration|null + */ + public function getBackdateDuration() + { + return $this->backdate_duration; + } + + public function hasBackdateDuration() + { + return isset($this->backdate_duration); + } + + public function clearBackdateDuration() + { + unset($this->backdate_duration); + } + + /** + * Optional. If set, all certificates issued from this + * [CaPool][google.cloud.security.privateca.v1.CaPool] will be backdated by + * this duration. The 'not_before_time' will be the issuance time minus this + * [backdate_duration][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.backdate_duration], + * and the 'not_after_time' will be adjusted to preserve the requested + * lifetime. The maximum duration that a certificate can be backdated with + * these options is 48 hours in the past. + * This option cannot be set if + * [allow_requester_specified_not_before_time][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.allow_requester_specified_not_before_time] + * is set. + * + * Generated from protobuf field .google.protobuf.Duration backdate_duration = 7 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Protobuf\Duration $var + * @return $this + */ + public function setBackdateDuration($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); + $this->backdate_duration = $var; + + return $this; + } + + /** + * Optional. If set to true, allows requesters to specify the + * [requested_not_before_time][google.cloud.security.privateca.v1.Certificate.requested_not_before_time] + * field when creating a + * [Certificate][google.cloud.security.privateca.v1.Certificate]. + * Certificates requested with this option enabled will have a + * 'not_before_time' equal to the value specified in the request. The + * 'not_after_time' will be adjusted to preserve the requested lifetime. The + * maximum time that a certificate can be backdated with these options is 48 + * hours in the past. This option cannot be set if + * [backdate_duration][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.backdate_duration] + * is set. + * + * Generated from protobuf field bool allow_requester_specified_not_before_time = 8 [(.google.api.field_behavior) = OPTIONAL]; + * @return bool + */ + public function getAllowRequesterSpecifiedNotBeforeTime() + { + return $this->allow_requester_specified_not_before_time; + } + + /** + * Optional. If set to true, allows requesters to specify the + * [requested_not_before_time][google.cloud.security.privateca.v1.Certificate.requested_not_before_time] + * field when creating a + * [Certificate][google.cloud.security.privateca.v1.Certificate]. + * Certificates requested with this option enabled will have a + * 'not_before_time' equal to the value specified in the request. The + * 'not_after_time' will be adjusted to preserve the requested lifetime. The + * maximum time that a certificate can be backdated with these options is 48 + * hours in the past. This option cannot be set if + * [backdate_duration][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.backdate_duration] + * is set. + * + * Generated from protobuf field bool allow_requester_specified_not_before_time = 8 [(.google.api.field_behavior) = OPTIONAL]; + * @param bool $var + * @return $this + */ + public function setAllowRequesterSpecifiedNotBeforeTime($var) + { + GPBUtil::checkBool($var); + $this->allow_requester_specified_not_before_time = $var; + + return $this; + } + + /** + * Optional. The maximum lifetime allowed for issued + * [Certificates][google.cloud.security.privateca.v1.Certificate]. Note that + * if the issuing + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * expires before a + * [Certificate][google.cloud.security.privateca.v1.Certificate] resource's + * requested maximum_lifetime, the effective lifetime will be explicitly + * truncated to match it. + * + * Generated from protobuf field .google.protobuf.Duration maximum_lifetime = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Protobuf\Duration|null + */ + public function getMaximumLifetime() + { + return $this->maximum_lifetime; + } + + public function hasMaximumLifetime() + { + return isset($this->maximum_lifetime); + } + + public function clearMaximumLifetime() + { + unset($this->maximum_lifetime); + } + + /** + * Optional. The maximum lifetime allowed for issued + * [Certificates][google.cloud.security.privateca.v1.Certificate]. Note that + * if the issuing + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * expires before a + * [Certificate][google.cloud.security.privateca.v1.Certificate] resource's + * requested maximum_lifetime, the effective lifetime will be explicitly + * truncated to match it. + * + * Generated from protobuf field .google.protobuf.Duration maximum_lifetime = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Protobuf\Duration $var + * @return $this + */ + public function setMaximumLifetime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); + $this->maximum_lifetime = $var; + + return $this; + } + + /** + * Optional. If specified, then only methods allowed in the + * [IssuanceModes][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.IssuanceModes] + * may be used to issue + * [Certificates][google.cloud.security.privateca.v1.Certificate]. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.IssuancePolicy.IssuanceModes allowed_issuance_modes = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\Security\PrivateCA\V1\CaPool\IssuancePolicy\IssuanceModes|null + */ + public function getAllowedIssuanceModes() + { + return $this->allowed_issuance_modes; + } + + public function hasAllowedIssuanceModes() + { + return isset($this->allowed_issuance_modes); + } + + public function clearAllowedIssuanceModes() + { + unset($this->allowed_issuance_modes); + } + + /** + * Optional. If specified, then only methods allowed in the + * [IssuanceModes][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.IssuanceModes] + * may be used to issue + * [Certificates][google.cloud.security.privateca.v1.Certificate]. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.IssuancePolicy.IssuanceModes allowed_issuance_modes = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\Security\PrivateCA\V1\CaPool\IssuancePolicy\IssuanceModes $var + * @return $this + */ + public function setAllowedIssuanceModes($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CaPool\IssuancePolicy\IssuanceModes::class); + $this->allowed_issuance_modes = $var; + + return $this; + } + + /** + * Optional. A set of X.509 values that will be applied to all certificates + * issued through this [CaPool][google.cloud.security.privateca.v1.CaPool]. + * If a certificate request includes conflicting values for the same + * properties, they will be overwritten by the values defined here. If a + * certificate request uses a + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * that defines conflicting + * [predefined_values][google.cloud.security.privateca.v1.CertificateTemplate.predefined_values] + * for the same properties, the certificate issuance request will fail. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.X509Parameters baseline_values = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\Security\PrivateCA\V1\X509Parameters|null + */ + public function getBaselineValues() + { + return $this->baseline_values; + } + + public function hasBaselineValues() + { + return isset($this->baseline_values); + } + + public function clearBaselineValues() + { + unset($this->baseline_values); + } + + /** + * Optional. A set of X.509 values that will be applied to all certificates + * issued through this [CaPool][google.cloud.security.privateca.v1.CaPool]. + * If a certificate request includes conflicting values for the same + * properties, they will be overwritten by the values defined here. If a + * certificate request uses a + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * that defines conflicting + * [predefined_values][google.cloud.security.privateca.v1.CertificateTemplate.predefined_values] + * for the same properties, the certificate issuance request will fail. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.X509Parameters baseline_values = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\Security\PrivateCA\V1\X509Parameters $var + * @return $this + */ + public function setBaselineValues($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\X509Parameters::class); + $this->baseline_values = $var; + + return $this; + } + + /** + * Optional. Describes constraints on identities that may appear in + * [Certificates][google.cloud.security.privateca.v1.Certificate] issued + * through this [CaPool][google.cloud.security.privateca.v1.CaPool]. If this + * is omitted, then this [CaPool][google.cloud.security.privateca.v1.CaPool] + * will not add restrictions on a certificate's identity. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateIdentityConstraints identity_constraints = 5 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\Security\PrivateCA\V1\CertificateIdentityConstraints|null + */ + public function getIdentityConstraints() + { + return $this->identity_constraints; + } + + public function hasIdentityConstraints() + { + return isset($this->identity_constraints); + } + + public function clearIdentityConstraints() + { + unset($this->identity_constraints); + } + + /** + * Optional. Describes constraints on identities that may appear in + * [Certificates][google.cloud.security.privateca.v1.Certificate] issued + * through this [CaPool][google.cloud.security.privateca.v1.CaPool]. If this + * is omitted, then this [CaPool][google.cloud.security.privateca.v1.CaPool] + * will not add restrictions on a certificate's identity. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateIdentityConstraints identity_constraints = 5 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\Security\PrivateCA\V1\CertificateIdentityConstraints $var + * @return $this + */ + public function setIdentityConstraints($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CertificateIdentityConstraints::class); + $this->identity_constraints = $var; + + return $this; + } + + /** + * Optional. Describes the set of X.509 extensions that may appear in a + * [Certificate][google.cloud.security.privateca.v1.Certificate] issued + * through this [CaPool][google.cloud.security.privateca.v1.CaPool]. If a + * certificate request sets extensions that don't appear in the + * [passthrough_extensions][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.passthrough_extensions], + * those extensions will be dropped. If a certificate request uses a + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * with + * [predefined_values][google.cloud.security.privateca.v1.CertificateTemplate.predefined_values] + * that don't appear here, the certificate issuance request will fail. If + * this is omitted, then this + * [CaPool][google.cloud.security.privateca.v1.CaPool] will not add + * restrictions on a certificate's X.509 extensions. These constraints do + * not apply to X.509 extensions set in this + * [CaPool][google.cloud.security.privateca.v1.CaPool]'s + * [baseline_values][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.baseline_values]. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateExtensionConstraints passthrough_extensions = 6 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\Security\PrivateCA\V1\CertificateExtensionConstraints|null + */ + public function getPassthroughExtensions() + { + return $this->passthrough_extensions; + } + + public function hasPassthroughExtensions() + { + return isset($this->passthrough_extensions); + } + + public function clearPassthroughExtensions() + { + unset($this->passthrough_extensions); + } + + /** + * Optional. Describes the set of X.509 extensions that may appear in a + * [Certificate][google.cloud.security.privateca.v1.Certificate] issued + * through this [CaPool][google.cloud.security.privateca.v1.CaPool]. If a + * certificate request sets extensions that don't appear in the + * [passthrough_extensions][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.passthrough_extensions], + * those extensions will be dropped. If a certificate request uses a + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * with + * [predefined_values][google.cloud.security.privateca.v1.CertificateTemplate.predefined_values] + * that don't appear here, the certificate issuance request will fail. If + * this is omitted, then this + * [CaPool][google.cloud.security.privateca.v1.CaPool] will not add + * restrictions on a certificate's X.509 extensions. These constraints do + * not apply to X.509 extensions set in this + * [CaPool][google.cloud.security.privateca.v1.CaPool]'s + * [baseline_values][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.baseline_values]. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateExtensionConstraints passthrough_extensions = 6 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\Security\PrivateCA\V1\CertificateExtensionConstraints $var + * @return $this + */ + public function setPassthroughExtensions($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CertificateExtensionConstraints::class); + $this->passthrough_extensions = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy/AllowedKeyType.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy/AllowedKeyType.php new file mode 100644 index 000000000000..a39c3a457850 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy/AllowedKeyType.php @@ -0,0 +1,113 @@ +google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyType + */ +class AllowedKeyType extends \Google\Protobuf\Internal\Message +{ + protected $key_type; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Security\PrivateCA\V1\CaPool\IssuancePolicy\AllowedKeyType\RsaKeyType $rsa + * Represents an allowed RSA key type. + * @type \Google\Cloud\Security\PrivateCA\V1\CaPool\IssuancePolicy\AllowedKeyType\EcKeyType $elliptic_curve + * Represents an allowed Elliptic Curve key type. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * Represents an allowed RSA key type. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyType.RsaKeyType rsa = 1; + * @return \Google\Cloud\Security\PrivateCA\V1\CaPool\IssuancePolicy\AllowedKeyType\RsaKeyType|null + */ + public function getRsa() + { + return $this->readOneof(1); + } + + public function hasRsa() + { + return $this->hasOneof(1); + } + + /** + * Represents an allowed RSA key type. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyType.RsaKeyType rsa = 1; + * @param \Google\Cloud\Security\PrivateCA\V1\CaPool\IssuancePolicy\AllowedKeyType\RsaKeyType $var + * @return $this + */ + public function setRsa($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CaPool\IssuancePolicy\AllowedKeyType\RsaKeyType::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * Represents an allowed Elliptic Curve key type. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyType.EcKeyType elliptic_curve = 2; + * @return \Google\Cloud\Security\PrivateCA\V1\CaPool\IssuancePolicy\AllowedKeyType\EcKeyType|null + */ + public function getEllipticCurve() + { + return $this->readOneof(2); + } + + public function hasEllipticCurve() + { + return $this->hasOneof(2); + } + + /** + * Represents an allowed Elliptic Curve key type. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyType.EcKeyType elliptic_curve = 2; + * @param \Google\Cloud\Security\PrivateCA\V1\CaPool\IssuancePolicy\AllowedKeyType\EcKeyType $var + * @return $this + */ + public function setEllipticCurve($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CaPool\IssuancePolicy\AllowedKeyType\EcKeyType::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * @return string + */ + public function getKeyType() + { + return $this->whichOneof("key_type"); + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy/AllowedKeyType/EcKeyType.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy/AllowedKeyType/EcKeyType.php new file mode 100644 index 000000000000..388f76485b17 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy/AllowedKeyType/EcKeyType.php @@ -0,0 +1,73 @@ +google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyType.EcKeyType + */ +class EcKeyType extends \Google\Protobuf\Internal\Message +{ + /** + * Optional. A signature algorithm that must be used. If this is + * omitted, any EC-based signature algorithm will be allowed. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyType.EcKeyType.EcSignatureAlgorithm signature_algorithm = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $signature_algorithm = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $signature_algorithm + * Optional. A signature algorithm that must be used. If this is + * omitted, any EC-based signature algorithm will be allowed. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * Optional. A signature algorithm that must be used. If this is + * omitted, any EC-based signature algorithm will be allowed. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyType.EcKeyType.EcSignatureAlgorithm signature_algorithm = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @return int + */ + public function getSignatureAlgorithm() + { + return $this->signature_algorithm; + } + + /** + * Optional. A signature algorithm that must be used. If this is + * omitted, any EC-based signature algorithm will be allowed. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyType.EcKeyType.EcSignatureAlgorithm signature_algorithm = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @param int $var + * @return $this + */ + public function setSignatureAlgorithm($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Security\PrivateCA\V1\CaPool\IssuancePolicy\AllowedKeyType\EcKeyType\EcSignatureAlgorithm::class); + $this->signature_algorithm = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy/AllowedKeyType/EcKeyType/EcSignatureAlgorithm.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy/AllowedKeyType/EcKeyType/EcSignatureAlgorithm.php new file mode 100644 index 000000000000..756710e45ed2 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy/AllowedKeyType/EcKeyType/EcSignatureAlgorithm.php @@ -0,0 +1,74 @@ +google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyType.EcKeyType.EcSignatureAlgorithm + */ +class EcSignatureAlgorithm +{ + /** + * Not specified. Signifies that any signature algorithm may be used. + * + * Generated from protobuf enum EC_SIGNATURE_ALGORITHM_UNSPECIFIED = 0; + */ + const EC_SIGNATURE_ALGORITHM_UNSPECIFIED = 0; + /** + * Refers to the Elliptic Curve Digital Signature Algorithm over the + * NIST P-256 curve. + * + * Generated from protobuf enum ECDSA_P256 = 1; + */ + const ECDSA_P256 = 1; + /** + * Refers to the Elliptic Curve Digital Signature Algorithm over the + * NIST P-384 curve. + * + * Generated from protobuf enum ECDSA_P384 = 2; + */ + const ECDSA_P384 = 2; + /** + * Refers to the Edwards-curve Digital Signature Algorithm over curve + * 25519, as described in RFC 8410. + * + * Generated from protobuf enum EDDSA_25519 = 3; + */ + const EDDSA_25519 = 3; + + private static $valueToName = [ + self::EC_SIGNATURE_ALGORITHM_UNSPECIFIED => 'EC_SIGNATURE_ALGORITHM_UNSPECIFIED', + self::ECDSA_P256 => 'ECDSA_P256', + self::ECDSA_P384 => 'ECDSA_P384', + self::EDDSA_25519 => 'EDDSA_25519', + ]; + + 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy/AllowedKeyType/RsaKeyType.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy/AllowedKeyType/RsaKeyType.php new file mode 100644 index 000000000000..ac049c8f0efb --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy/AllowedKeyType/RsaKeyType.php @@ -0,0 +1,119 @@ +google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyType.RsaKeyType + */ +class RsaKeyType extends \Google\Protobuf\Internal\Message +{ + /** + * Optional. The minimum allowed RSA modulus size (inclusive), in bits. + * If this is not set, or if set to zero, the service-level min RSA + * modulus size will continue to apply. + * + * Generated from protobuf field int64 min_modulus_size = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $min_modulus_size = 0; + /** + * Optional. The maximum allowed RSA modulus size (inclusive), in bits. + * If this is not set, or if set to zero, the service will not enforce + * an explicit upper bound on RSA modulus sizes. + * + * Generated from protobuf field int64 max_modulus_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $max_modulus_size = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int|string $min_modulus_size + * Optional. The minimum allowed RSA modulus size (inclusive), in bits. + * If this is not set, or if set to zero, the service-level min RSA + * modulus size will continue to apply. + * @type int|string $max_modulus_size + * Optional. The maximum allowed RSA modulus size (inclusive), in bits. + * If this is not set, or if set to zero, the service will not enforce + * an explicit upper bound on RSA modulus sizes. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * Optional. The minimum allowed RSA modulus size (inclusive), in bits. + * If this is not set, or if set to zero, the service-level min RSA + * modulus size will continue to apply. + * + * Generated from protobuf field int64 min_modulus_size = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @return int|string + */ + public function getMinModulusSize() + { + return $this->min_modulus_size; + } + + /** + * Optional. The minimum allowed RSA modulus size (inclusive), in bits. + * If this is not set, or if set to zero, the service-level min RSA + * modulus size will continue to apply. + * + * Generated from protobuf field int64 min_modulus_size = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @param int|string $var + * @return $this + */ + public function setMinModulusSize($var) + { + GPBUtil::checkInt64($var); + $this->min_modulus_size = $var; + + return $this; + } + + /** + * Optional. The maximum allowed RSA modulus size (inclusive), in bits. + * If this is not set, or if set to zero, the service will not enforce + * an explicit upper bound on RSA modulus sizes. + * + * Generated from protobuf field int64 max_modulus_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return int|string + */ + public function getMaxModulusSize() + { + return $this->max_modulus_size; + } + + /** + * Optional. The maximum allowed RSA modulus size (inclusive), in bits. + * If this is not set, or if set to zero, the service will not enforce + * an explicit upper bound on RSA modulus sizes. + * + * Generated from protobuf field int64 max_modulus_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @param int|string $var + * @return $this + */ + public function setMaxModulusSize($var) + { + GPBUtil::checkInt64($var); + $this->max_modulus_size = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy/IssuanceModes.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy/IssuanceModes.php new file mode 100644 index 000000000000..31f5b86475c2 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy/IssuanceModes.php @@ -0,0 +1,124 @@ +google.cloud.security.privateca.v1.CaPool.IssuancePolicy.IssuanceModes + */ +class IssuanceModes extends \Google\Protobuf\Internal\Message +{ + /** + * Optional. When true, allows callers to create + * [Certificates][google.cloud.security.privateca.v1.Certificate] by + * specifying a CSR. + * + * Generated from protobuf field bool allow_csr_based_issuance = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $allow_csr_based_issuance = false; + /** + * Optional. When true, allows callers to create + * [Certificates][google.cloud.security.privateca.v1.Certificate] by + * specifying a + * [CertificateConfig][google.cloud.security.privateca.v1.CertificateConfig]. + * + * Generated from protobuf field bool allow_config_based_issuance = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $allow_config_based_issuance = false; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type bool $allow_csr_based_issuance + * Optional. When true, allows callers to create + * [Certificates][google.cloud.security.privateca.v1.Certificate] by + * specifying a CSR. + * @type bool $allow_config_based_issuance + * Optional. When true, allows callers to create + * [Certificates][google.cloud.security.privateca.v1.Certificate] by + * specifying a + * [CertificateConfig][google.cloud.security.privateca.v1.CertificateConfig]. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * Optional. When true, allows callers to create + * [Certificates][google.cloud.security.privateca.v1.Certificate] by + * specifying a CSR. + * + * Generated from protobuf field bool allow_csr_based_issuance = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @return bool + */ + public function getAllowCsrBasedIssuance() + { + return $this->allow_csr_based_issuance; + } + + /** + * Optional. When true, allows callers to create + * [Certificates][google.cloud.security.privateca.v1.Certificate] by + * specifying a CSR. + * + * Generated from protobuf field bool allow_csr_based_issuance = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @param bool $var + * @return $this + */ + public function setAllowCsrBasedIssuance($var) + { + GPBUtil::checkBool($var); + $this->allow_csr_based_issuance = $var; + + return $this; + } + + /** + * Optional. When true, allows callers to create + * [Certificates][google.cloud.security.privateca.v1.Certificate] by + * specifying a + * [CertificateConfig][google.cloud.security.privateca.v1.CertificateConfig]. + * + * Generated from protobuf field bool allow_config_based_issuance = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return bool + */ + public function getAllowConfigBasedIssuance() + { + return $this->allow_config_based_issuance; + } + + /** + * Optional. When true, allows callers to create + * [Certificates][google.cloud.security.privateca.v1.Certificate] by + * specifying a + * [CertificateConfig][google.cloud.security.privateca.v1.CertificateConfig]. + * + * Generated from protobuf field bool allow_config_based_issuance = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @param bool $var + * @return $this + */ + public function setAllowConfigBasedIssuance($var) + { + GPBUtil::checkBool($var); + $this->allow_config_based_issuance = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/PublishingOptions.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/PublishingOptions.php new file mode 100644 index 000000000000..07ad3f819067 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/PublishingOptions.php @@ -0,0 +1,209 @@ +google.cloud.security.privateca.v1.CaPool.PublishingOptions + */ +class PublishingOptions extends \Google\Protobuf\Internal\Message +{ + /** + * Optional. When true, publishes each + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s + * CA certificate and includes its URL in the "Authority Information Access" + * X.509 extension in all issued + * [Certificates][google.cloud.security.privateca.v1.Certificate]. If this + * is false, the CA certificate will not be published and the corresponding + * X.509 extension will not be written in issued certificates. + * + * Generated from protobuf field bool publish_ca_cert = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $publish_ca_cert = false; + /** + * Optional. When true, publishes each + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s + * CRL and includes its URL in the "CRL Distribution Points" X.509 extension + * in all issued + * [Certificates][google.cloud.security.privateca.v1.Certificate]. If this + * is false, CRLs will not be published and the corresponding X.509 + * extension will not be written in issued certificates. CRLs will expire 7 + * days from their creation. However, we will rebuild daily. CRLs are also + * rebuilt shortly after a certificate is revoked. + * + * Generated from protobuf field bool publish_crl = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $publish_crl = false; + /** + * Optional. Specifies the encoding format of each + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * resource's CA certificate and CRLs. If this is omitted, CA certificates + * and CRLs will be published in PEM. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.PublishingOptions.EncodingFormat encoding_format = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $encoding_format = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type bool $publish_ca_cert + * Optional. When true, publishes each + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s + * CA certificate and includes its URL in the "Authority Information Access" + * X.509 extension in all issued + * [Certificates][google.cloud.security.privateca.v1.Certificate]. If this + * is false, the CA certificate will not be published and the corresponding + * X.509 extension will not be written in issued certificates. + * @type bool $publish_crl + * Optional. When true, publishes each + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s + * CRL and includes its URL in the "CRL Distribution Points" X.509 extension + * in all issued + * [Certificates][google.cloud.security.privateca.v1.Certificate]. If this + * is false, CRLs will not be published and the corresponding X.509 + * extension will not be written in issued certificates. CRLs will expire 7 + * days from their creation. However, we will rebuild daily. CRLs are also + * rebuilt shortly after a certificate is revoked. + * @type int $encoding_format + * Optional. Specifies the encoding format of each + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * resource's CA certificate and CRLs. If this is omitted, CA certificates + * and CRLs will be published in PEM. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * Optional. When true, publishes each + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s + * CA certificate and includes its URL in the "Authority Information Access" + * X.509 extension in all issued + * [Certificates][google.cloud.security.privateca.v1.Certificate]. If this + * is false, the CA certificate will not be published and the corresponding + * X.509 extension will not be written in issued certificates. + * + * Generated from protobuf field bool publish_ca_cert = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @return bool + */ + public function getPublishCaCert() + { + return $this->publish_ca_cert; + } + + /** + * Optional. When true, publishes each + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s + * CA certificate and includes its URL in the "Authority Information Access" + * X.509 extension in all issued + * [Certificates][google.cloud.security.privateca.v1.Certificate]. If this + * is false, the CA certificate will not be published and the corresponding + * X.509 extension will not be written in issued certificates. + * + * Generated from protobuf field bool publish_ca_cert = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @param bool $var + * @return $this + */ + public function setPublishCaCert($var) + { + GPBUtil::checkBool($var); + $this->publish_ca_cert = $var; + + return $this; + } + + /** + * Optional. When true, publishes each + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s + * CRL and includes its URL in the "CRL Distribution Points" X.509 extension + * in all issued + * [Certificates][google.cloud.security.privateca.v1.Certificate]. If this + * is false, CRLs will not be published and the corresponding X.509 + * extension will not be written in issued certificates. CRLs will expire 7 + * days from their creation. However, we will rebuild daily. CRLs are also + * rebuilt shortly after a certificate is revoked. + * + * Generated from protobuf field bool publish_crl = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return bool + */ + public function getPublishCrl() + { + return $this->publish_crl; + } + + /** + * Optional. When true, publishes each + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s + * CRL and includes its URL in the "CRL Distribution Points" X.509 extension + * in all issued + * [Certificates][google.cloud.security.privateca.v1.Certificate]. If this + * is false, CRLs will not be published and the corresponding X.509 + * extension will not be written in issued certificates. CRLs will expire 7 + * days from their creation. However, we will rebuild daily. CRLs are also + * rebuilt shortly after a certificate is revoked. + * + * Generated from protobuf field bool publish_crl = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @param bool $var + * @return $this + */ + public function setPublishCrl($var) + { + GPBUtil::checkBool($var); + $this->publish_crl = $var; + + return $this; + } + + /** + * Optional. Specifies the encoding format of each + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * resource's CA certificate and CRLs. If this is omitted, CA certificates + * and CRLs will be published in PEM. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.PublishingOptions.EncodingFormat encoding_format = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return int + */ + public function getEncodingFormat() + { + return $this->encoding_format; + } + + /** + * Optional. Specifies the encoding format of each + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * resource's CA certificate and CRLs. If this is omitted, CA certificates + * and CRLs will be published in PEM. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.PublishingOptions.EncodingFormat encoding_format = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @param int $var + * @return $this + */ + public function setEncodingFormat($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Security\PrivateCA\V1\CaPool\PublishingOptions\EncodingFormat::class); + $this->encoding_format = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/PublishingOptions/EncodingFormat.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/PublishingOptions/EncodingFormat.php new file mode 100644 index 000000000000..b5057cbcaed6 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/PublishingOptions/EncodingFormat.php @@ -0,0 +1,65 @@ +google.cloud.security.privateca.v1.CaPool.PublishingOptions.EncodingFormat + */ +class EncodingFormat +{ + /** + * Not specified. By default, PEM format will be used. + * + * Generated from protobuf enum ENCODING_FORMAT_UNSPECIFIED = 0; + */ + const ENCODING_FORMAT_UNSPECIFIED = 0; + /** + * The + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s + * CA certificate and CRLs will be published in PEM format. + * + * Generated from protobuf enum PEM = 1; + */ + const PEM = 1; + /** + * The + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s + * CA certificate and CRLs will be published in DER format. + * + * Generated from protobuf enum DER = 2; + */ + const DER = 2; + + private static $valueToName = [ + self::ENCODING_FORMAT_UNSPECIFIED => 'ENCODING_FORMAT_UNSPECIFIED', + self::PEM => 'PEM', + self::DER => 'DER', + ]; + + 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/Tier.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/Tier.php new file mode 100644 index 000000000000..8f09b78fdacc --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/Tier.php @@ -0,0 +1,62 @@ +google.cloud.security.privateca.v1.CaPool.Tier + */ +class Tier +{ + /** + * Not specified. + * + * Generated from protobuf enum TIER_UNSPECIFIED = 0; + */ + const TIER_UNSPECIFIED = 0; + /** + * Enterprise tier. + * + * Generated from protobuf enum ENTERPRISE = 1; + */ + const ENTERPRISE = 1; + /** + * DevOps tier. + * + * Generated from protobuf enum DEVOPS = 2; + */ + const DEVOPS = 2; + + private static $valueToName = [ + self::TIER_UNSPECIFIED => 'TIER_UNSPECIFIED', + self::ENTERPRISE => 'ENTERPRISE', + self::DEVOPS => 'DEVOPS', + ]; + + 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/Certificate.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/Certificate.php new file mode 100644 index 000000000000..5ae97a2348a6 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/Certificate.php @@ -0,0 +1,755 @@ +google.cloud.security.privateca.v1.Certificate + */ +class Certificate extends \Google\Protobuf\Internal\Message +{ + /** + * Identifier. The resource name for this + * [Certificate][google.cloud.security.privateca.v1.Certificate] in the format + * `projects/{@*}locations/{@*}caPools/{@*}certificates/*`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + */ + protected $name = ''; + /** + * Output only. The resource name of the issuing + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. + * + * Generated from protobuf field string issuer_certificate_authority = 4 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { + */ + protected $issuer_certificate_authority = ''; + /** + * Required. Immutable. The desired lifetime of a certificate. Used to create + * the "not_before_time" and "not_after_time" fields inside an X.509 + * certificate. Note that the lifetime may be truncated if it would extend + * past the life of any certificate authority in the issuing chain. + * + * Generated from protobuf field .google.protobuf.Duration lifetime = 5 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + */ + protected $lifetime = null; + /** + * Immutable. The resource name for a + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * used to issue this certificate, in the format + * `projects/{@*}locations/{@*}certificateTemplates/*`. + * If this is specified, the caller must have the necessary permission to + * use this template. If this is omitted, no template will be used. + * This template must be in the same location as the + * [Certificate][google.cloud.security.privateca.v1.Certificate]. + * + * Generated from protobuf field string certificate_template = 6 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { + */ + protected $certificate_template = ''; + /** + * Immutable. Specifies how the + * [Certificate][google.cloud.security.privateca.v1.Certificate]'s identity + * fields are to be decided. If this is omitted, the `DEFAULT` subject mode + * will be used. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.SubjectRequestMode subject_mode = 7 [(.google.api.field_behavior) = IMMUTABLE]; + */ + protected $subject_mode = 0; + /** + * Output only. Details regarding the revocation of this + * [Certificate][google.cloud.security.privateca.v1.Certificate]. This + * [Certificate][google.cloud.security.privateca.v1.Certificate] is considered + * revoked if and only if this field is present. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.Certificate.RevocationDetails revocation_details = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $revocation_details = null; + /** + * Output only. The pem-encoded, signed X.509 certificate. + * + * Generated from protobuf field string pem_certificate = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $pem_certificate = ''; + /** + * Output only. A structured description of the issued X.509 certificate. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateDescription certificate_description = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $certificate_description = null; + /** + * Output only. The chain that may be used to verify the X.509 certificate. + * Expected to be in issuer-to-root order according to RFC 5246. + * + * Generated from protobuf field repeated string pem_certificate_chain = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + private $pem_certificate_chain; + /** + * Output only. The time at which this + * [Certificate][google.cloud.security.privateca.v1.Certificate] was created. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $create_time = null; + /** + * Output only. The time at which this + * [Certificate][google.cloud.security.privateca.v1.Certificate] was updated. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $update_time = null; + /** + * Optional. Labels with user-defined metadata. + * + * Generated from protobuf field map labels = 14 [(.google.api.field_behavior) = OPTIONAL]; + */ + private $labels; + /** + * Optional. The requested + * [not_before_time][google.cloud.security.privateca.v1.CertificateDescription.SubjectDescription.not_before_time] + * of this [Certificate][google.cloud.security.privateca.v1.Certificate]. This + * field may only be set if the + * [CaPool.IssuancePolicy.allow_requester_specified_not_before_time][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.allow_requester_specified_not_before_time] + * field is set to true for the issuing + * [CaPool][google.cloud.security.privateca.v1.CaPool]. + * If this field is specified, the certificate will be issued with this + * 'not_before_time'. If this is not specified, the 'not_before_time' will be + * set to the issuance time or issuance time minus + * [backdate_duration][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.backdate_duration] + * depending on the [CaPool][google.cloud.security.privateca.v1.CaPool] + * configuration. + * + * Generated from protobuf field .google.protobuf.Timestamp requested_not_before_time = 15 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $requested_not_before_time = null; + protected $certificate_config; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Identifier. The resource name for this + * [Certificate][google.cloud.security.privateca.v1.Certificate] in the format + * `projects/{@*}locations/{@*}caPools/{@*}certificates/*`. + * @type string $pem_csr + * Immutable. A pem-encoded X.509 certificate signing request (CSR). + * @type \Google\Cloud\Security\PrivateCA\V1\CertificateConfig $config + * Immutable. A description of the certificate and key that does not require + * X.509 or ASN.1. + * @type string $issuer_certificate_authority + * Output only. The resource name of the issuing + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. + * @type \Google\Protobuf\Duration $lifetime + * Required. Immutable. The desired lifetime of a certificate. Used to create + * the "not_before_time" and "not_after_time" fields inside an X.509 + * certificate. Note that the lifetime may be truncated if it would extend + * past the life of any certificate authority in the issuing chain. + * @type string $certificate_template + * Immutable. The resource name for a + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * used to issue this certificate, in the format + * `projects/{@*}locations/{@*}certificateTemplates/*`. + * If this is specified, the caller must have the necessary permission to + * use this template. If this is omitted, no template will be used. + * This template must be in the same location as the + * [Certificate][google.cloud.security.privateca.v1.Certificate]. + * @type int $subject_mode + * Immutable. Specifies how the + * [Certificate][google.cloud.security.privateca.v1.Certificate]'s identity + * fields are to be decided. If this is omitted, the `DEFAULT` subject mode + * will be used. + * @type \Google\Cloud\Security\PrivateCA\V1\Certificate\RevocationDetails $revocation_details + * Output only. Details regarding the revocation of this + * [Certificate][google.cloud.security.privateca.v1.Certificate]. This + * [Certificate][google.cloud.security.privateca.v1.Certificate] is considered + * revoked if and only if this field is present. + * @type string $pem_certificate + * Output only. The pem-encoded, signed X.509 certificate. + * @type \Google\Cloud\Security\PrivateCA\V1\CertificateDescription $certificate_description + * Output only. A structured description of the issued X.509 certificate. + * @type string[] $pem_certificate_chain + * Output only. The chain that may be used to verify the X.509 certificate. + * Expected to be in issuer-to-root order according to RFC 5246. + * @type \Google\Protobuf\Timestamp $create_time + * Output only. The time at which this + * [Certificate][google.cloud.security.privateca.v1.Certificate] was created. + * @type \Google\Protobuf\Timestamp $update_time + * Output only. The time at which this + * [Certificate][google.cloud.security.privateca.v1.Certificate] was updated. + * @type array|\Google\Protobuf\Internal\MapField $labels + * Optional. Labels with user-defined metadata. + * @type \Google\Protobuf\Timestamp $requested_not_before_time + * Optional. The requested + * [not_before_time][google.cloud.security.privateca.v1.CertificateDescription.SubjectDescription.not_before_time] + * of this [Certificate][google.cloud.security.privateca.v1.Certificate]. This + * field may only be set if the + * [CaPool.IssuancePolicy.allow_requester_specified_not_before_time][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.allow_requester_specified_not_before_time] + * field is set to true for the issuing + * [CaPool][google.cloud.security.privateca.v1.CaPool]. + * If this field is specified, the certificate will be issued with this + * 'not_before_time'. If this is not specified, the 'not_before_time' will be + * set to the issuance time or issuance time minus + * [backdate_duration][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.backdate_duration] + * depending on the [CaPool][google.cloud.security.privateca.v1.CaPool] + * configuration. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * Identifier. The resource name for this + * [Certificate][google.cloud.security.privateca.v1.Certificate] in the format + * `projects/{@*}locations/{@*}caPools/{@*}certificates/*`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Identifier. The resource name for this + * [Certificate][google.cloud.security.privateca.v1.Certificate] in the format + * `projects/{@*}locations/{@*}caPools/{@*}certificates/*`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Immutable. A pem-encoded X.509 certificate signing request (CSR). + * + * Generated from protobuf field string pem_csr = 2 [(.google.api.field_behavior) = IMMUTABLE]; + * @return string + */ + public function getPemCsr() + { + return $this->readOneof(2); + } + + public function hasPemCsr() + { + return $this->hasOneof(2); + } + + /** + * Immutable. A pem-encoded X.509 certificate signing request (CSR). + * + * Generated from protobuf field string pem_csr = 2 [(.google.api.field_behavior) = IMMUTABLE]; + * @param string $var + * @return $this + */ + public function setPemCsr($var) + { + GPBUtil::checkString($var, True); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * Immutable. A description of the certificate and key that does not require + * X.509 or ASN.1. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateConfig config = 3 [(.google.api.field_behavior) = IMMUTABLE]; + * @return \Google\Cloud\Security\PrivateCA\V1\CertificateConfig|null + */ + public function getConfig() + { + return $this->readOneof(3); + } + + public function hasConfig() + { + return $this->hasOneof(3); + } + + /** + * Immutable. A description of the certificate and key that does not require + * X.509 or ASN.1. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateConfig config = 3 [(.google.api.field_behavior) = IMMUTABLE]; + * @param \Google\Cloud\Security\PrivateCA\V1\CertificateConfig $var + * @return $this + */ + public function setConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CertificateConfig::class); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * Output only. The resource name of the issuing + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. + * + * Generated from protobuf field string issuer_certificate_authority = 4 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { + * @return string + */ + public function getIssuerCertificateAuthority() + { + return $this->issuer_certificate_authority; + } + + /** + * Output only. The resource name of the issuing + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. + * + * Generated from protobuf field string issuer_certificate_authority = 4 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setIssuerCertificateAuthority($var) + { + GPBUtil::checkString($var, True); + $this->issuer_certificate_authority = $var; + + return $this; + } + + /** + * Required. Immutable. The desired lifetime of a certificate. Used to create + * the "not_before_time" and "not_after_time" fields inside an X.509 + * certificate. Note that the lifetime may be truncated if it would extend + * past the life of any certificate authority in the issuing chain. + * + * Generated from protobuf field .google.protobuf.Duration lifetime = 5 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + * @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. Immutable. The desired lifetime of a certificate. Used to create + * the "not_before_time" and "not_after_time" fields inside an X.509 + * certificate. Note that the lifetime may be truncated if it would extend + * past the life of any certificate authority in the issuing chain. + * + * Generated from protobuf field .google.protobuf.Duration lifetime = 5 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + * @param \Google\Protobuf\Duration $var + * @return $this + */ + public function setLifetime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); + $this->lifetime = $var; + + return $this; + } + + /** + * Immutable. The resource name for a + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * used to issue this certificate, in the format + * `projects/{@*}locations/{@*}certificateTemplates/*`. + * If this is specified, the caller must have the necessary permission to + * use this template. If this is omitted, no template will be used. + * This template must be in the same location as the + * [Certificate][google.cloud.security.privateca.v1.Certificate]. + * + * Generated from protobuf field string certificate_template = 6 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { + * @return string + */ + public function getCertificateTemplate() + { + return $this->certificate_template; + } + + /** + * Immutable. The resource name for a + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * used to issue this certificate, in the format + * `projects/{@*}locations/{@*}certificateTemplates/*`. + * If this is specified, the caller must have the necessary permission to + * use this template. If this is omitted, no template will be used. + * This template must be in the same location as the + * [Certificate][google.cloud.security.privateca.v1.Certificate]. + * + * Generated from protobuf field string certificate_template = 6 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setCertificateTemplate($var) + { + GPBUtil::checkString($var, True); + $this->certificate_template = $var; + + return $this; + } + + /** + * Immutable. Specifies how the + * [Certificate][google.cloud.security.privateca.v1.Certificate]'s identity + * fields are to be decided. If this is omitted, the `DEFAULT` subject mode + * will be used. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.SubjectRequestMode subject_mode = 7 [(.google.api.field_behavior) = IMMUTABLE]; + * @return int + */ + public function getSubjectMode() + { + return $this->subject_mode; + } + + /** + * Immutable. Specifies how the + * [Certificate][google.cloud.security.privateca.v1.Certificate]'s identity + * fields are to be decided. If this is omitted, the `DEFAULT` subject mode + * will be used. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.SubjectRequestMode subject_mode = 7 [(.google.api.field_behavior) = IMMUTABLE]; + * @param int $var + * @return $this + */ + public function setSubjectMode($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Security\PrivateCA\V1\SubjectRequestMode::class); + $this->subject_mode = $var; + + return $this; + } + + /** + * Output only. Details regarding the revocation of this + * [Certificate][google.cloud.security.privateca.v1.Certificate]. This + * [Certificate][google.cloud.security.privateca.v1.Certificate] is considered + * revoked if and only if this field is present. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.Certificate.RevocationDetails revocation_details = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Cloud\Security\PrivateCA\V1\Certificate\RevocationDetails|null + */ + public function getRevocationDetails() + { + return $this->revocation_details; + } + + public function hasRevocationDetails() + { + return isset($this->revocation_details); + } + + public function clearRevocationDetails() + { + unset($this->revocation_details); + } + + /** + * Output only. Details regarding the revocation of this + * [Certificate][google.cloud.security.privateca.v1.Certificate]. This + * [Certificate][google.cloud.security.privateca.v1.Certificate] is considered + * revoked if and only if this field is present. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.Certificate.RevocationDetails revocation_details = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Cloud\Security\PrivateCA\V1\Certificate\RevocationDetails $var + * @return $this + */ + public function setRevocationDetails($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\Certificate\RevocationDetails::class); + $this->revocation_details = $var; + + return $this; + } + + /** + * Output only. The pem-encoded, signed X.509 certificate. + * + * 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, signed X.509 certificate. + * + * 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. A structured description of the issued X.509 certificate. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateDescription certificate_description = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Cloud\Security\PrivateCA\V1\CertificateDescription|null + */ + public function getCertificateDescription() + { + return $this->certificate_description; + } + + public function hasCertificateDescription() + { + return isset($this->certificate_description); + } + + public function clearCertificateDescription() + { + unset($this->certificate_description); + } + + /** + * Output only. A structured description of the issued X.509 certificate. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateDescription certificate_description = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Cloud\Security\PrivateCA\V1\CertificateDescription $var + * @return $this + */ + public function setCertificateDescription($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CertificateDescription::class); + $this->certificate_description = $var; + + return $this; + } + + /** + * Output only. The chain that may be used to verify the X.509 certificate. + * Expected to be in issuer-to-root order according to RFC 5246. + * + * Generated from protobuf field repeated string pem_certificate_chain = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return RepeatedField + */ + public function getPemCertificateChain() + { + return $this->pem_certificate_chain; + } + + /** + * Output only. The chain that may be used to verify the X.509 certificate. + * Expected to be in issuer-to-root order according to RFC 5246. + * + * Generated from protobuf field repeated string pem_certificate_chain = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string[] $var + * @return $this + */ + public function setPemCertificateChain($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->pem_certificate_chain = $arr; + + return $this; + } + + /** + * Output only. The time at which this + * [Certificate][google.cloud.security.privateca.v1.Certificate] was created. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 12 [(.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 + * [Certificate][google.cloud.security.privateca.v1.Certificate] was created. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 12 [(.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 + * [Certificate][google.cloud.security.privateca.v1.Certificate] was updated. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 13 [(.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 at which this + * [Certificate][google.cloud.security.privateca.v1.Certificate] was updated. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 13 [(.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. Labels with user-defined metadata. + * + * Generated from protobuf field map labels = 14 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Protobuf\Internal\MapField + */ + public function getLabels() + { + return $this->labels; + } + + /** + * Optional. Labels with user-defined metadata. + * + * Generated from protobuf field map labels = 14 [(.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. The requested + * [not_before_time][google.cloud.security.privateca.v1.CertificateDescription.SubjectDescription.not_before_time] + * of this [Certificate][google.cloud.security.privateca.v1.Certificate]. This + * field may only be set if the + * [CaPool.IssuancePolicy.allow_requester_specified_not_before_time][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.allow_requester_specified_not_before_time] + * field is set to true for the issuing + * [CaPool][google.cloud.security.privateca.v1.CaPool]. + * If this field is specified, the certificate will be issued with this + * 'not_before_time'. If this is not specified, the 'not_before_time' will be + * set to the issuance time or issuance time minus + * [backdate_duration][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.backdate_duration] + * depending on the [CaPool][google.cloud.security.privateca.v1.CaPool] + * configuration. + * + * Generated from protobuf field .google.protobuf.Timestamp requested_not_before_time = 15 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Protobuf\Timestamp|null + */ + public function getRequestedNotBeforeTime() + { + return $this->requested_not_before_time; + } + + public function hasRequestedNotBeforeTime() + { + return isset($this->requested_not_before_time); + } + + public function clearRequestedNotBeforeTime() + { + unset($this->requested_not_before_time); + } + + /** + * Optional. The requested + * [not_before_time][google.cloud.security.privateca.v1.CertificateDescription.SubjectDescription.not_before_time] + * of this [Certificate][google.cloud.security.privateca.v1.Certificate]. This + * field may only be set if the + * [CaPool.IssuancePolicy.allow_requester_specified_not_before_time][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.allow_requester_specified_not_before_time] + * field is set to true for the issuing + * [CaPool][google.cloud.security.privateca.v1.CaPool]. + * If this field is specified, the certificate will be issued with this + * 'not_before_time'. If this is not specified, the 'not_before_time' will be + * set to the issuance time or issuance time minus + * [backdate_duration][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.backdate_duration] + * depending on the [CaPool][google.cloud.security.privateca.v1.CaPool] + * configuration. + * + * Generated from protobuf field .google.protobuf.Timestamp requested_not_before_time = 15 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setRequestedNotBeforeTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->requested_not_before_time = $var; + + return $this; + } + + /** + * @return string + */ + public function getCertificateConfig() + { + return $this->whichOneof("certificate_config"); + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/Certificate/RevocationDetails.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/Certificate/RevocationDetails.php new file mode 100644 index 000000000000..fe4597b96211 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/Certificate/RevocationDetails.php @@ -0,0 +1,128 @@ +google.cloud.security.privateca.v1.Certificate.RevocationDetails + */ +class RevocationDetails extends \Google\Protobuf\Internal\Message +{ + /** + * Indicates why a + * [Certificate][google.cloud.security.privateca.v1.Certificate] was + * revoked. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.RevocationReason revocation_state = 1; + */ + protected $revocation_state = 0; + /** + * The time at which this + * [Certificate][google.cloud.security.privateca.v1.Certificate] was + * revoked. + * + * Generated from protobuf field .google.protobuf.Timestamp revocation_time = 2; + */ + protected $revocation_time = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $revocation_state + * Indicates why a + * [Certificate][google.cloud.security.privateca.v1.Certificate] was + * revoked. + * @type \Google\Protobuf\Timestamp $revocation_time + * The time at which this + * [Certificate][google.cloud.security.privateca.v1.Certificate] was + * revoked. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * Indicates why a + * [Certificate][google.cloud.security.privateca.v1.Certificate] was + * revoked. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.RevocationReason revocation_state = 1; + * @return int + */ + public function getRevocationState() + { + return $this->revocation_state; + } + + /** + * Indicates why a + * [Certificate][google.cloud.security.privateca.v1.Certificate] was + * revoked. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.RevocationReason revocation_state = 1; + * @param int $var + * @return $this + */ + public function setRevocationState($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Security\PrivateCA\V1\RevocationReason::class); + $this->revocation_state = $var; + + return $this; + } + + /** + * The time at which this + * [Certificate][google.cloud.security.privateca.v1.Certificate] was + * revoked. + * + * Generated from protobuf field .google.protobuf.Timestamp revocation_time = 2; + * @return \Google\Protobuf\Timestamp|null + */ + public function getRevocationTime() + { + return $this->revocation_time; + } + + public function hasRevocationTime() + { + return isset($this->revocation_time); + } + + public function clearRevocationTime() + { + unset($this->revocation_time); + } + + /** + * The time at which this + * [Certificate][google.cloud.security.privateca.v1.Certificate] was + * revoked. + * + * Generated from protobuf field .google.protobuf.Timestamp revocation_time = 2; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setRevocationTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->revocation_time = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority.php new file mode 100644 index 000000000000..1316e0d1ec5d --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority.php @@ -0,0 +1,1038 @@ +google.cloud.security.privateca.v1.CertificateAuthority + */ +class CertificateAuthority extends \Google\Protobuf\Internal\Message +{ + /** + * Identifier. The resource name for this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + */ + protected $name = ''; + /** + * Required. Immutable. The + * [Type][google.cloud.security.privateca.v1.CertificateAuthority.Type] of + * this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority.Type type = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + */ + protected $type = 0; + /** + * Required. Immutable. The config used to create a self-signed X.509 + * certificate or CSR. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateConfig config = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + */ + protected $config = null; + /** + * Required. Immutable. The desired lifetime of the CA certificate. Used to + * create the "not_before_time" and "not_after_time" fields inside an X.509 + * certificate. + * + * Generated from protobuf field .google.protobuf.Duration lifetime = 4 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + */ + protected $lifetime = null; + /** + * Required. Immutable. Used when issuing certificates for this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. + * If this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * is a self-signed CertificateAuthority, this key is also used to sign the + * self-signed CA certificate. Otherwise, it is used to sign a CSR. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority.KeyVersionSpec key_spec = 5 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + */ + protected $key_spec = null; + /** + * Optional. If this is a subordinate + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority], + * this field will be set with the subordinate configuration, which describes + * its issuers. This may be updated, but this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * must continue to validate. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.SubordinateConfig subordinate_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $subordinate_config = null; + /** + * Output only. The + * [CaPool.Tier][google.cloud.security.privateca.v1.CaPool.Tier] of the + * [CaPool][google.cloud.security.privateca.v1.CaPool] that includes this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.Tier tier = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $tier = 0; + /** + * Output only. The + * [State][google.cloud.security.privateca.v1.CertificateAuthority.State] for + * this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $state = 0; + /** + * Output only. This + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s + * certificate chain, including the current + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s + * certificate. Ordered such that the root issuer is the final element + * (consistent with RFC 5246). For a self-signed CA, this will only list the + * current + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s + * certificate. + * + * Generated from protobuf field repeated string pem_ca_certificates = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + private $pem_ca_certificates; + /** + * Output only. A structured description of this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s + * CA certificate and its issuers. Ordered as self-to-root. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CertificateDescription ca_certificate_descriptions = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + private $ca_certificate_descriptions; + /** + * Immutable. The name of a Cloud Storage bucket where this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * will publish content, such as the CA certificate and CRLs. This must be a + * bucket name, without any prefixes (such as `gs://`) or suffixes (such as + * `.googleapis.com`). For example, to use a bucket named `my-bucket`, you + * would simply specify `my-bucket`. If not specified, a managed bucket will + * be created. + * + * Generated from protobuf field string gcs_bucket = 11 [(.google.api.field_behavior) = IMMUTABLE]; + */ + protected $gcs_bucket = ''; + /** + * Output only. URLs for accessing content published by this CA, such as the + * CA certificate and CRLs. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority.AccessUrls access_urls = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $access_urls = null; + /** + * Output only. The time at which this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * was created. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $create_time = null; + /** + * Output only. The time at which this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * was last updated. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $update_time = null; + /** + * Output only. The time at which this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * was soft deleted, if it is in the + * [DELETED][google.cloud.security.privateca.v1.CertificateAuthority.State.DELETED] + * state. + * + * Generated from protobuf field .google.protobuf.Timestamp delete_time = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $delete_time = null; + /** + * Output only. The time at which this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * will be permanently purged, if it is in the + * [DELETED][google.cloud.security.privateca.v1.CertificateAuthority.State.DELETED] + * state. + * + * Generated from protobuf field .google.protobuf.Timestamp expire_time = 16 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $expire_time = null; + /** + * Optional. Labels with user-defined metadata. + * + * Generated from protobuf field map labels = 17 [(.google.api.field_behavior) = OPTIONAL]; + */ + private $labels; + /** + * Optional. User-defined URLs for CA certificate and CRLs. The service does + * not publish content to these URLs. It is up to the user to mirror content + * to these URLs. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority.UserDefinedAccessUrls user_defined_access_urls = 18 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $user_defined_access_urls = null; + /** + * Output only. Reserved for future use. + * + * Generated from protobuf field bool satisfies_pzs = 19 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $satisfies_pzs = false; + /** + * Output only. Reserved for future use. + * + * Generated from protobuf field bool satisfies_pzi = 20 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $satisfies_pzi = false; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Identifier. The resource name for this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. + * @type int $type + * Required. Immutable. The + * [Type][google.cloud.security.privateca.v1.CertificateAuthority.Type] of + * this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. + * @type \Google\Cloud\Security\PrivateCA\V1\CertificateConfig $config + * Required. Immutable. The config used to create a self-signed X.509 + * certificate or CSR. + * @type \Google\Protobuf\Duration $lifetime + * Required. Immutable. The desired lifetime of the CA certificate. Used to + * create the "not_before_time" and "not_after_time" fields inside an X.509 + * certificate. + * @type \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority\KeyVersionSpec $key_spec + * Required. Immutable. Used when issuing certificates for this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. + * If this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * is a self-signed CertificateAuthority, this key is also used to sign the + * self-signed CA certificate. Otherwise, it is used to sign a CSR. + * @type \Google\Cloud\Security\PrivateCA\V1\SubordinateConfig $subordinate_config + * Optional. If this is a subordinate + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority], + * this field will be set with the subordinate configuration, which describes + * its issuers. This may be updated, but this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * must continue to validate. + * @type int $tier + * Output only. The + * [CaPool.Tier][google.cloud.security.privateca.v1.CaPool.Tier] of the + * [CaPool][google.cloud.security.privateca.v1.CaPool] that includes this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. + * @type int $state + * Output only. The + * [State][google.cloud.security.privateca.v1.CertificateAuthority.State] for + * this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. + * @type string[] $pem_ca_certificates + * Output only. This + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s + * certificate chain, including the current + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s + * certificate. Ordered such that the root issuer is the final element + * (consistent with RFC 5246). For a self-signed CA, this will only list the + * current + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s + * certificate. + * @type \Google\Cloud\Security\PrivateCA\V1\CertificateDescription[] $ca_certificate_descriptions + * Output only. A structured description of this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s + * CA certificate and its issuers. Ordered as self-to-root. + * @type string $gcs_bucket + * Immutable. The name of a Cloud Storage bucket where this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * will publish content, such as the CA certificate and CRLs. This must be a + * bucket name, without any prefixes (such as `gs://`) or suffixes (such as + * `.googleapis.com`). For example, to use a bucket named `my-bucket`, you + * would simply specify `my-bucket`. If not specified, a managed bucket will + * be created. + * @type \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority\AccessUrls $access_urls + * Output only. URLs for accessing content published by this CA, such as the + * CA certificate and CRLs. + * @type \Google\Protobuf\Timestamp $create_time + * Output only. The time at which this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * was created. + * @type \Google\Protobuf\Timestamp $update_time + * Output only. The time at which this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * was last updated. + * @type \Google\Protobuf\Timestamp $delete_time + * Output only. The time at which this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * was soft deleted, if it is in the + * [DELETED][google.cloud.security.privateca.v1.CertificateAuthority.State.DELETED] + * state. + * @type \Google\Protobuf\Timestamp $expire_time + * Output only. The time at which this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * will be permanently purged, if it is in the + * [DELETED][google.cloud.security.privateca.v1.CertificateAuthority.State.DELETED] + * state. + * @type array|\Google\Protobuf\Internal\MapField $labels + * Optional. Labels with user-defined metadata. + * @type \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority\UserDefinedAccessUrls $user_defined_access_urls + * Optional. User-defined URLs for CA certificate and CRLs. The service does + * not publish content to these URLs. It is up to the user to mirror content + * to these URLs. + * @type bool $satisfies_pzs + * Output only. Reserved for future use. + * @type bool $satisfies_pzi + * Output only. Reserved for future use. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * Identifier. The resource name for this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Identifier. The resource name for this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Required. Immutable. The + * [Type][google.cloud.security.privateca.v1.CertificateAuthority.Type] of + * this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority.Type type = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + * @return int + */ + public function getType() + { + return $this->type; + } + + /** + * Required. Immutable. The + * [Type][google.cloud.security.privateca.v1.CertificateAuthority.Type] of + * this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority.Type type = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + * @param int $var + * @return $this + */ + public function setType($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority\Type::class); + $this->type = $var; + + return $this; + } + + /** + * Required. Immutable. The config used to create a self-signed X.509 + * certificate or CSR. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateConfig config = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + * @return \Google\Cloud\Security\PrivateCA\V1\CertificateConfig|null + */ + public function getConfig() + { + return $this->config; + } + + public function hasConfig() + { + return isset($this->config); + } + + public function clearConfig() + { + unset($this->config); + } + + /** + * Required. Immutable. The config used to create a self-signed X.509 + * certificate or CSR. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateConfig config = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + * @param \Google\Cloud\Security\PrivateCA\V1\CertificateConfig $var + * @return $this + */ + public function setConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CertificateConfig::class); + $this->config = $var; + + return $this; + } + + /** + * Required. Immutable. The desired lifetime of the CA certificate. Used to + * create the "not_before_time" and "not_after_time" fields inside an X.509 + * certificate. + * + * Generated from protobuf field .google.protobuf.Duration lifetime = 4 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + * @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. Immutable. The desired lifetime of the CA certificate. Used to + * create the "not_before_time" and "not_after_time" fields inside an X.509 + * certificate. + * + * Generated from protobuf field .google.protobuf.Duration lifetime = 4 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + * @param \Google\Protobuf\Duration $var + * @return $this + */ + public function setLifetime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); + $this->lifetime = $var; + + return $this; + } + + /** + * Required. Immutable. Used when issuing certificates for this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. + * If this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * is a self-signed CertificateAuthority, this key is also used to sign the + * self-signed CA certificate. Otherwise, it is used to sign a CSR. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority.KeyVersionSpec key_spec = 5 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + * @return \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority\KeyVersionSpec|null + */ + public function getKeySpec() + { + return $this->key_spec; + } + + public function hasKeySpec() + { + return isset($this->key_spec); + } + + public function clearKeySpec() + { + unset($this->key_spec); + } + + /** + * Required. Immutable. Used when issuing certificates for this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. + * If this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * is a self-signed CertificateAuthority, this key is also used to sign the + * self-signed CA certificate. Otherwise, it is used to sign a CSR. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority.KeyVersionSpec key_spec = 5 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; + * @param \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority\KeyVersionSpec $var + * @return $this + */ + public function setKeySpec($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority\KeyVersionSpec::class); + $this->key_spec = $var; + + return $this; + } + + /** + * Optional. If this is a subordinate + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority], + * this field will be set with the subordinate configuration, which describes + * its issuers. This may be updated, but this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * must continue to validate. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.SubordinateConfig subordinate_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\Security\PrivateCA\V1\SubordinateConfig|null + */ + public function getSubordinateConfig() + { + return $this->subordinate_config; + } + + public function hasSubordinateConfig() + { + return isset($this->subordinate_config); + } + + public function clearSubordinateConfig() + { + unset($this->subordinate_config); + } + + /** + * Optional. If this is a subordinate + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority], + * this field will be set with the subordinate configuration, which describes + * its issuers. This may be updated, but this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * must continue to validate. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.SubordinateConfig subordinate_config = 6 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\Security\PrivateCA\V1\SubordinateConfig $var + * @return $this + */ + public function setSubordinateConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\SubordinateConfig::class); + $this->subordinate_config = $var; + + return $this; + } + + /** + * Output only. The + * [CaPool.Tier][google.cloud.security.privateca.v1.CaPool.Tier] of the + * [CaPool][google.cloud.security.privateca.v1.CaPool] that includes this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.Tier tier = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getTier() + { + return $this->tier; + } + + /** + * Output only. The + * [CaPool.Tier][google.cloud.security.privateca.v1.CaPool.Tier] of the + * [CaPool][google.cloud.security.privateca.v1.CaPool] that includes this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.Tier tier = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setTier($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Security\PrivateCA\V1\CaPool\Tier::class); + $this->tier = $var; + + return $this; + } + + /** + * Output only. The + * [State][google.cloud.security.privateca.v1.CertificateAuthority.State] for + * this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getState() + { + return $this->state; + } + + /** + * Output only. The + * [State][google.cloud.security.privateca.v1.CertificateAuthority.State] for + * this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setState($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority\State::class); + $this->state = $var; + + return $this; + } + + /** + * Output only. This + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s + * certificate chain, including the current + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s + * certificate. Ordered such that the root issuer is the final element + * (consistent with RFC 5246). For a self-signed CA, this will only list the + * current + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s + * certificate. + * + * Generated from protobuf field repeated string pem_ca_certificates = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return RepeatedField + */ + public function getPemCaCertificates() + { + return $this->pem_ca_certificates; + } + + /** + * Output only. This + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s + * certificate chain, including the current + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s + * certificate. Ordered such that the root issuer is the final element + * (consistent with RFC 5246). For a self-signed CA, this will only list the + * current + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s + * certificate. + * + * Generated from protobuf field repeated string pem_ca_certificates = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string[] $var + * @return $this + */ + public function setPemCaCertificates($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->pem_ca_certificates = $arr; + + return $this; + } + + /** + * Output only. A structured description of this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s + * CA certificate and its issuers. Ordered as self-to-root. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CertificateDescription ca_certificate_descriptions = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return RepeatedField<\Google\Cloud\Security\PrivateCA\V1\CertificateDescription> + */ + public function getCaCertificateDescriptions() + { + return $this->ca_certificate_descriptions; + } + + /** + * Output only. A structured description of this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s + * CA certificate and its issuers. Ordered as self-to-root. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CertificateDescription ca_certificate_descriptions = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Cloud\Security\PrivateCA\V1\CertificateDescription[] $var + * @return $this + */ + public function setCaCertificateDescriptions($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Security\PrivateCA\V1\CertificateDescription::class); + $this->ca_certificate_descriptions = $arr; + + return $this; + } + + /** + * Immutable. The name of a Cloud Storage bucket where this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * will publish content, such as the CA certificate and CRLs. This must be a + * bucket name, without any prefixes (such as `gs://`) or suffixes (such as + * `.googleapis.com`). For example, to use a bucket named `my-bucket`, you + * would simply specify `my-bucket`. If not specified, a managed bucket will + * be created. + * + * Generated from protobuf field string gcs_bucket = 11 [(.google.api.field_behavior) = IMMUTABLE]; + * @return string + */ + public function getGcsBucket() + { + return $this->gcs_bucket; + } + + /** + * Immutable. The name of a Cloud Storage bucket where this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * will publish content, such as the CA certificate and CRLs. This must be a + * bucket name, without any prefixes (such as `gs://`) or suffixes (such as + * `.googleapis.com`). For example, to use a bucket named `my-bucket`, you + * would simply specify `my-bucket`. If not specified, a managed bucket will + * be created. + * + * Generated from protobuf field string gcs_bucket = 11 [(.google.api.field_behavior) = IMMUTABLE]; + * @param string $var + * @return $this + */ + public function setGcsBucket($var) + { + GPBUtil::checkString($var, True); + $this->gcs_bucket = $var; + + return $this; + } + + /** + * Output only. URLs for accessing content published by this CA, such as the + * CA certificate and CRLs. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority.AccessUrls access_urls = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority\AccessUrls|null + */ + public function getAccessUrls() + { + return $this->access_urls; + } + + public function hasAccessUrls() + { + return isset($this->access_urls); + } + + public function clearAccessUrls() + { + unset($this->access_urls); + } + + /** + * Output only. URLs for accessing content published by this CA, such as the + * CA certificate and CRLs. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority.AccessUrls access_urls = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority\AccessUrls $var + * @return $this + */ + public function setAccessUrls($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority\AccessUrls::class); + $this->access_urls = $var; + + return $this; + } + + /** + * Output only. The time at which this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * was created. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 13 [(.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 + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * was created. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 13 [(.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 + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * was last updated. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 14 [(.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 at which this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * was last updated. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 14 [(.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 time at which this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * was soft deleted, if it is in the + * [DELETED][google.cloud.security.privateca.v1.CertificateAuthority.State.DELETED] + * state. + * + * Generated from protobuf field .google.protobuf.Timestamp delete_time = 15 [(.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. The time at which this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * was soft deleted, if it is in the + * [DELETED][google.cloud.security.privateca.v1.CertificateAuthority.State.DELETED] + * state. + * + * Generated from protobuf field .google.protobuf.Timestamp delete_time = 15 [(.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. The time at which this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * will be permanently purged, if it is in the + * [DELETED][google.cloud.security.privateca.v1.CertificateAuthority.State.DELETED] + * state. + * + * Generated from protobuf field .google.protobuf.Timestamp expire_time = 16 [(.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 + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * will be permanently purged, if it is in the + * [DELETED][google.cloud.security.privateca.v1.CertificateAuthority.State.DELETED] + * state. + * + * Generated from protobuf field .google.protobuf.Timestamp expire_time = 16 [(.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; + } + + /** + * Optional. Labels with user-defined metadata. + * + * Generated from protobuf field map labels = 17 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Protobuf\Internal\MapField + */ + public function getLabels() + { + return $this->labels; + } + + /** + * Optional. Labels with user-defined metadata. + * + * Generated from protobuf field map labels = 17 [(.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. User-defined URLs for CA certificate and CRLs. The service does + * not publish content to these URLs. It is up to the user to mirror content + * to these URLs. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority.UserDefinedAccessUrls user_defined_access_urls = 18 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority\UserDefinedAccessUrls|null + */ + public function getUserDefinedAccessUrls() + { + return $this->user_defined_access_urls; + } + + public function hasUserDefinedAccessUrls() + { + return isset($this->user_defined_access_urls); + } + + public function clearUserDefinedAccessUrls() + { + unset($this->user_defined_access_urls); + } + + /** + * Optional. User-defined URLs for CA certificate and CRLs. The service does + * not publish content to these URLs. It is up to the user to mirror content + * to these URLs. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority.UserDefinedAccessUrls user_defined_access_urls = 18 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority\UserDefinedAccessUrls $var + * @return $this + */ + public function setUserDefinedAccessUrls($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority\UserDefinedAccessUrls::class); + $this->user_defined_access_urls = $var; + + return $this; + } + + /** + * Output only. Reserved for future use. + * + * Generated from protobuf field bool satisfies_pzs = 19 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return bool + */ + public function getSatisfiesPzs() + { + return $this->satisfies_pzs; + } + + /** + * Output only. Reserved for future use. + * + * Generated from protobuf field bool satisfies_pzs = 19 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param bool $var + * @return $this + */ + public function setSatisfiesPzs($var) + { + GPBUtil::checkBool($var); + $this->satisfies_pzs = $var; + + return $this; + } + + /** + * Output only. Reserved for future use. + * + * Generated from protobuf field bool satisfies_pzi = 20 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return bool + */ + public function getSatisfiesPzi() + { + return $this->satisfies_pzi; + } + + /** + * Output only. Reserved for future use. + * + * Generated from protobuf field bool satisfies_pzi = 20 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param bool $var + * @return $this + */ + public function setSatisfiesPzi($var) + { + GPBUtil::checkBool($var); + $this->satisfies_pzi = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/AccessUrls.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/AccessUrls.php new file mode 100644 index 000000000000..7b1f79c445b1 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/AccessUrls.php @@ -0,0 +1,127 @@ +google.cloud.security.privateca.v1.CertificateAuthority.AccessUrls + */ +class AccessUrls extends \Google\Protobuf\Internal\Message +{ + /** + * The URL where this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s + * CA certificate is published. This will only be set for CAs that have been + * activated. + * + * Generated from protobuf field string ca_certificate_access_url = 1; + */ + protected $ca_certificate_access_url = ''; + /** + * The URLs where this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s + * CRLs are published. This will only be set for CAs that have been + * activated. + * + * Generated from protobuf field repeated string crl_access_urls = 2; + */ + private $crl_access_urls; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $ca_certificate_access_url + * The URL where this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s + * CA certificate is published. This will only be set for CAs that have been + * activated. + * @type string[] $crl_access_urls + * The URLs where this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s + * CRLs are published. This will only be set for CAs that have been + * activated. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * The URL where this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s + * CA certificate is published. This will only be set for CAs that have been + * activated. + * + * Generated from protobuf field string ca_certificate_access_url = 1; + * @return string + */ + public function getCaCertificateAccessUrl() + { + return $this->ca_certificate_access_url; + } + + /** + * The URL where this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s + * CA certificate is published. This will only be set for CAs that have been + * activated. + * + * Generated from protobuf field string ca_certificate_access_url = 1; + * @param string $var + * @return $this + */ + public function setCaCertificateAccessUrl($var) + { + GPBUtil::checkString($var, True); + $this->ca_certificate_access_url = $var; + + return $this; + } + + /** + * The URLs where this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s + * CRLs are published. This will only be set for CAs that have been + * activated. + * + * Generated from protobuf field repeated string crl_access_urls = 2; + * @return RepeatedField + */ + public function getCrlAccessUrls() + { + return $this->crl_access_urls; + } + + /** + * The URLs where this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s + * CRLs are published. This will only be set for CAs that have been + * activated. + * + * Generated from protobuf field repeated string crl_access_urls = 2; + * @param string[] $var + * @return $this + */ + public function setCrlAccessUrls($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->crl_access_urls = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/KeyVersionSpec.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/KeyVersionSpec.php new file mode 100644 index 000000000000..02829272751d --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/KeyVersionSpec.php @@ -0,0 +1,128 @@ +google.cloud.security.privateca.v1.CertificateAuthority.KeyVersionSpec + */ +class KeyVersionSpec extends \Google\Protobuf\Internal\Message +{ + protected $KeyVersion; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $cloud_kms_key_version + * The resource name for an existing Cloud KMS CryptoKeyVersion in the + * format + * `projects/{@*}locations/{@*}keyRings/{@*}cryptoKeys/{@*}cryptoKeyVersions/*`. + * This option enables full flexibility in the key's capabilities and + * properties. + * @type int $algorithm + * The algorithm to use for creating a managed Cloud KMS key for a for a + * simplified experience. All managed keys will be have their + * [ProtectionLevel][google.cloud.kms.v1.ProtectionLevel] as `HSM`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * The resource name for an existing Cloud KMS CryptoKeyVersion in the + * format + * `projects/{@*}locations/{@*}keyRings/{@*}cryptoKeys/{@*}cryptoKeyVersions/*`. + * This option enables full flexibility in the key's capabilities and + * properties. + * + * Generated from protobuf field string cloud_kms_key_version = 1; + * @return string + */ + public function getCloudKmsKeyVersion() + { + return $this->readOneof(1); + } + + public function hasCloudKmsKeyVersion() + { + return $this->hasOneof(1); + } + + /** + * The resource name for an existing Cloud KMS CryptoKeyVersion in the + * format + * `projects/{@*}locations/{@*}keyRings/{@*}cryptoKeys/{@*}cryptoKeyVersions/*`. + * This option enables full flexibility in the key's capabilities and + * properties. + * + * Generated from protobuf field string cloud_kms_key_version = 1; + * @param string $var + * @return $this + */ + public function setCloudKmsKeyVersion($var) + { + GPBUtil::checkString($var, True); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * The algorithm to use for creating a managed Cloud KMS key for a for a + * simplified experience. All managed keys will be have their + * [ProtectionLevel][google.cloud.kms.v1.ProtectionLevel] as `HSM`. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority.SignHashAlgorithm algorithm = 2; + * @return int + */ + public function getAlgorithm() + { + return $this->readOneof(2); + } + + public function hasAlgorithm() + { + return $this->hasOneof(2); + } + + /** + * The algorithm to use for creating a managed Cloud KMS key for a for a + * simplified experience. All managed keys will be have their + * [ProtectionLevel][google.cloud.kms.v1.ProtectionLevel] as `HSM`. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority.SignHashAlgorithm algorithm = 2; + * @param int $var + * @return $this + */ + public function setAlgorithm($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority\SignHashAlgorithm::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * @return string + */ + public function getKeyVersion() + { + return $this->whichOneof("KeyVersion"); + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/SignHashAlgorithm.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/SignHashAlgorithm.php new file mode 100644 index 000000000000..1572ffc1a3d1 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/SignHashAlgorithm.php @@ -0,0 +1,111 @@ +google.cloud.security.privateca.v1.CertificateAuthority.SignHashAlgorithm + */ +class SignHashAlgorithm +{ + /** + * Not specified. + * + * Generated from protobuf enum SIGN_HASH_ALGORITHM_UNSPECIFIED = 0; + */ + const SIGN_HASH_ALGORITHM_UNSPECIFIED = 0; + /** + * maps to CryptoKeyVersionAlgorithm.RSA_SIGN_PSS_2048_SHA256 + * + * Generated from protobuf enum RSA_PSS_2048_SHA256 = 1; + */ + const RSA_PSS_2048_SHA256 = 1; + /** + * maps to CryptoKeyVersionAlgorithm. RSA_SIGN_PSS_3072_SHA256 + * + * Generated from protobuf enum RSA_PSS_3072_SHA256 = 2; + */ + const RSA_PSS_3072_SHA256 = 2; + /** + * maps to CryptoKeyVersionAlgorithm.RSA_SIGN_PSS_4096_SHA256 + * + * Generated from protobuf enum RSA_PSS_4096_SHA256 = 3; + */ + const RSA_PSS_4096_SHA256 = 3; + /** + * maps to CryptoKeyVersionAlgorithm.RSA_SIGN_PKCS1_2048_SHA256 + * + * Generated from protobuf enum RSA_PKCS1_2048_SHA256 = 6; + */ + const RSA_PKCS1_2048_SHA256 = 6; + /** + * maps to CryptoKeyVersionAlgorithm.RSA_SIGN_PKCS1_3072_SHA256 + * + * Generated from protobuf enum RSA_PKCS1_3072_SHA256 = 7; + */ + const RSA_PKCS1_3072_SHA256 = 7; + /** + * maps to CryptoKeyVersionAlgorithm.RSA_SIGN_PKCS1_4096_SHA256 + * + * Generated from protobuf enum RSA_PKCS1_4096_SHA256 = 8; + */ + const RSA_PKCS1_4096_SHA256 = 8; + /** + * maps to CryptoKeyVersionAlgorithm.EC_SIGN_P256_SHA256 + * + * Generated from protobuf enum EC_P256_SHA256 = 4; + */ + const EC_P256_SHA256 = 4; + /** + * maps to CryptoKeyVersionAlgorithm.EC_SIGN_P384_SHA384 + * + * Generated from protobuf enum EC_P384_SHA384 = 5; + */ + const EC_P384_SHA384 = 5; + + private static $valueToName = [ + self::SIGN_HASH_ALGORITHM_UNSPECIFIED => 'SIGN_HASH_ALGORITHM_UNSPECIFIED', + self::RSA_PSS_2048_SHA256 => 'RSA_PSS_2048_SHA256', + self::RSA_PSS_3072_SHA256 => 'RSA_PSS_3072_SHA256', + self::RSA_PSS_4096_SHA256 => 'RSA_PSS_4096_SHA256', + self::RSA_PKCS1_2048_SHA256 => 'RSA_PKCS1_2048_SHA256', + self::RSA_PKCS1_3072_SHA256 => 'RSA_PKCS1_3072_SHA256', + self::RSA_PKCS1_4096_SHA256 => 'RSA_PKCS1_4096_SHA256', + self::EC_P256_SHA256 => 'EC_P256_SHA256', + self::EC_P384_SHA384 => 'EC_P384_SHA384', + ]; + + 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/State.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/State.php new file mode 100644 index 000000000000..e3741fdbc95f --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/State.php @@ -0,0 +1,108 @@ +google.cloud.security.privateca.v1.CertificateAuthority.State + */ +class State +{ + /** + * Not specified. + * + * Generated from protobuf enum STATE_UNSPECIFIED = 0; + */ + const STATE_UNSPECIFIED = 0; + /** + * Certificates can be issued from this CA. CRLs will be generated for this + * CA. The CA will be part of the + * [CaPool][google.cloud.security.privateca.v1.CaPool]'s trust anchor, and + * will be used to issue certificates from the + * [CaPool][google.cloud.security.privateca.v1.CaPool]. + * + * Generated from protobuf enum ENABLED = 1; + */ + const ENABLED = 1; + /** + * Certificates cannot be issued from this CA. CRLs will still be generated. + * The CA will be part of the + * [CaPool][google.cloud.security.privateca.v1.CaPool]'s trust anchor, but + * will not be used to issue certificates from the + * [CaPool][google.cloud.security.privateca.v1.CaPool]. + * + * Generated from protobuf enum DISABLED = 2; + */ + const DISABLED = 2; + /** + * Certificates can be issued from this CA. CRLs will be generated for this + * CA. The CA will be part of the + * [CaPool][google.cloud.security.privateca.v1.CaPool]'s trust anchor, but + * will not be used to issue certificates from the + * [CaPool][google.cloud.security.privateca.v1.CaPool]. + * + * Generated from protobuf enum STAGED = 3; + */ + const STAGED = 3; + /** + * Certificates cannot be issued from this CA. CRLs will not be generated. + * The CA will not be part of the + * [CaPool][google.cloud.security.privateca.v1.CaPool]'s trust anchor, and + * will not be used to issue certificates from the + * [CaPool][google.cloud.security.privateca.v1.CaPool]. + * + * Generated from protobuf enum AWAITING_USER_ACTIVATION = 4; + */ + const AWAITING_USER_ACTIVATION = 4; + /** + * Certificates cannot be issued from this CA. CRLs will not be generated. + * The CA may still be recovered by calling + * [CertificateAuthorityService.UndeleteCertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthorityService.UndeleteCertificateAuthority] + * before + * [expire_time][google.cloud.security.privateca.v1.CertificateAuthority.expire_time]. + * The CA will not be part of the + * [CaPool][google.cloud.security.privateca.v1.CaPool]'s trust anchor, and + * will not be used to issue certificates from the + * [CaPool][google.cloud.security.privateca.v1.CaPool]. + * + * Generated from protobuf enum DELETED = 5; + */ + const DELETED = 5; + + private static $valueToName = [ + self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', + self::ENABLED => 'ENABLED', + self::DISABLED => 'DISABLED', + self::STAGED => 'STAGED', + self::AWAITING_USER_ACTIVATION => 'AWAITING_USER_ACTIVATION', + 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); + } +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/Type.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/Type.php new file mode 100644 index 000000000000..d9559ba8a1a7 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/Type.php @@ -0,0 +1,65 @@ +google.cloud.security.privateca.v1.CertificateAuthority.Type + */ +class Type +{ + /** + * Not specified. + * + * Generated from protobuf enum TYPE_UNSPECIFIED = 0; + */ + const TYPE_UNSPECIFIED = 0; + /** + * Self-signed CA. + * + * Generated from protobuf enum SELF_SIGNED = 1; + */ + const SELF_SIGNED = 1; + /** + * Subordinate CA. Could be issued by a Private CA + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * or an unmanaged CA. + * + * Generated from protobuf enum SUBORDINATE = 2; + */ + const SUBORDINATE = 2; + + private static $valueToName = [ + self::TYPE_UNSPECIFIED => 'TYPE_UNSPECIFIED', + self::SELF_SIGNED => 'SELF_SIGNED', + self::SUBORDINATE => 'SUBORDINATE', + ]; + + 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/UserDefinedAccessUrls.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/UserDefinedAccessUrls.php new file mode 100644 index 000000000000..5e5927f1b981 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/UserDefinedAccessUrls.php @@ -0,0 +1,142 @@ +google.cloud.security.privateca.v1.CertificateAuthority.UserDefinedAccessUrls + */ +class UserDefinedAccessUrls extends \Google\Protobuf\Internal\Message +{ + /** + * Optional. A list of URLs where the issuer CA certificate may be + * downloaded, which appears in the "Authority Information Access" extension + * in the certificate. If specified, the default [Cloud Storage + * URLs][google.cloud.security.privateca.v1.CertificateAuthority.AccessUrls.ca_certificate_access_url] + * will be omitted. + * + * Generated from protobuf field repeated string aia_issuing_certificate_urls = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + private $aia_issuing_certificate_urls; + /** + * Optional. A list of URLs where to obtain CRL information, i.e. + * the DistributionPoint.fullName described by + * https://tools.ietf.org/html/rfc5280#section-4.2.1.13. + * If specified, the default + * [Cloud Storage + * URLs][google.cloud.security.privateca.v1.CertificateAuthority.AccessUrls.crl_access_urls] + * will be omitted. + * + * Generated from protobuf field repeated string crl_access_urls = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + private $crl_access_urls; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string[] $aia_issuing_certificate_urls + * Optional. A list of URLs where the issuer CA certificate may be + * downloaded, which appears in the "Authority Information Access" extension + * in the certificate. If specified, the default [Cloud Storage + * URLs][google.cloud.security.privateca.v1.CertificateAuthority.AccessUrls.ca_certificate_access_url] + * will be omitted. + * @type string[] $crl_access_urls + * Optional. A list of URLs where to obtain CRL information, i.e. + * the DistributionPoint.fullName described by + * https://tools.ietf.org/html/rfc5280#section-4.2.1.13. + * If specified, the default + * [Cloud Storage + * URLs][google.cloud.security.privateca.v1.CertificateAuthority.AccessUrls.crl_access_urls] + * will be omitted. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * Optional. A list of URLs where the issuer CA certificate may be + * downloaded, which appears in the "Authority Information Access" extension + * in the certificate. If specified, the default [Cloud Storage + * URLs][google.cloud.security.privateca.v1.CertificateAuthority.AccessUrls.ca_certificate_access_url] + * will be omitted. + * + * Generated from protobuf field repeated string aia_issuing_certificate_urls = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @return RepeatedField + */ + public function getAiaIssuingCertificateUrls() + { + return $this->aia_issuing_certificate_urls; + } + + /** + * Optional. A list of URLs where the issuer CA certificate may be + * downloaded, which appears in the "Authority Information Access" extension + * in the certificate. If specified, the default [Cloud Storage + * URLs][google.cloud.security.privateca.v1.CertificateAuthority.AccessUrls.ca_certificate_access_url] + * will be omitted. + * + * Generated from protobuf field repeated string aia_issuing_certificate_urls = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @param string[] $var + * @return $this + */ + public function setAiaIssuingCertificateUrls($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->aia_issuing_certificate_urls = $arr; + + return $this; + } + + /** + * Optional. A list of URLs where to obtain CRL information, i.e. + * the DistributionPoint.fullName described by + * https://tools.ietf.org/html/rfc5280#section-4.2.1.13. + * If specified, the default + * [Cloud Storage + * URLs][google.cloud.security.privateca.v1.CertificateAuthority.AccessUrls.crl_access_urls] + * will be omitted. + * + * Generated from protobuf field repeated string crl_access_urls = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return RepeatedField + */ + public function getCrlAccessUrls() + { + return $this->crl_access_urls; + } + + /** + * Optional. A list of URLs where to obtain CRL information, i.e. + * the DistributionPoint.fullName described by + * https://tools.ietf.org/html/rfc5280#section-4.2.1.13. + * If specified, the default + * [Cloud Storage + * URLs][google.cloud.security.privateca.v1.CertificateAuthority.AccessUrls.crl_access_urls] + * will be omitted. + * + * Generated from protobuf field repeated string crl_access_urls = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @param string[] $var + * @return $this + */ + public function setCrlAccessUrls($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->crl_access_urls = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateConfig.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateConfig.php new file mode 100644 index 000000000000..2504069cb736 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateConfig.php @@ -0,0 +1,259 @@ +google.cloud.security.privateca.v1.CertificateConfig + */ +class CertificateConfig extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Specifies some of the values in a certificate that are related to + * the subject. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateConfig.SubjectConfig subject_config = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $subject_config = null; + /** + * Required. Describes how some of the technical X.509 fields in a certificate + * should be populated. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.X509Parameters x509_config = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $x509_config = null; + /** + * Optional. The public key that corresponds to this config. This is, for + * example, used when issuing + * [Certificates][google.cloud.security.privateca.v1.Certificate], but not + * when creating a self-signed + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * or + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * CSR. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.PublicKey public_key = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $public_key = null; + /** + * Optional. When specified this provides a custom SKI to be used in the + * certificate. This should only be used to maintain a SKI of an existing CA + * originally created outside CA service, which was not generated using method + * (1) described in RFC 5280 section 4.2.1.2. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateConfig.KeyId subject_key_id = 4 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $subject_key_id = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Security\PrivateCA\V1\CertificateConfig\SubjectConfig $subject_config + * Required. Specifies some of the values in a certificate that are related to + * the subject. + * @type \Google\Cloud\Security\PrivateCA\V1\X509Parameters $x509_config + * Required. Describes how some of the technical X.509 fields in a certificate + * should be populated. + * @type \Google\Cloud\Security\PrivateCA\V1\PublicKey $public_key + * Optional. The public key that corresponds to this config. This is, for + * example, used when issuing + * [Certificates][google.cloud.security.privateca.v1.Certificate], but not + * when creating a self-signed + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * or + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * CSR. + * @type \Google\Cloud\Security\PrivateCA\V1\CertificateConfig\KeyId $subject_key_id + * Optional. When specified this provides a custom SKI to be used in the + * certificate. This should only be used to maintain a SKI of an existing CA + * originally created outside CA service, which was not generated using method + * (1) described in RFC 5280 section 4.2.1.2. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * Required. Specifies some of the values in a certificate that are related to + * the subject. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateConfig.SubjectConfig subject_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Security\PrivateCA\V1\CertificateConfig\SubjectConfig|null + */ + public function getSubjectConfig() + { + return $this->subject_config; + } + + public function hasSubjectConfig() + { + return isset($this->subject_config); + } + + public function clearSubjectConfig() + { + unset($this->subject_config); + } + + /** + * Required. Specifies some of the values in a certificate that are related to + * the subject. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateConfig.SubjectConfig subject_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Security\PrivateCA\V1\CertificateConfig\SubjectConfig $var + * @return $this + */ + public function setSubjectConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CertificateConfig\SubjectConfig::class); + $this->subject_config = $var; + + return $this; + } + + /** + * Required. Describes how some of the technical X.509 fields in a certificate + * should be populated. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.X509Parameters x509_config = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Security\PrivateCA\V1\X509Parameters|null + */ + public function getX509Config() + { + return $this->x509_config; + } + + public function hasX509Config() + { + return isset($this->x509_config); + } + + public function clearX509Config() + { + unset($this->x509_config); + } + + /** + * Required. Describes how some of the technical X.509 fields in a certificate + * should be populated. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.X509Parameters x509_config = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Security\PrivateCA\V1\X509Parameters $var + * @return $this + */ + public function setX509Config($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\X509Parameters::class); + $this->x509_config = $var; + + return $this; + } + + /** + * Optional. The public key that corresponds to this config. This is, for + * example, used when issuing + * [Certificates][google.cloud.security.privateca.v1.Certificate], but not + * when creating a self-signed + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * or + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * CSR. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.PublicKey public_key = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\Security\PrivateCA\V1\PublicKey|null + */ + public function getPublicKey() + { + return $this->public_key; + } + + public function hasPublicKey() + { + return isset($this->public_key); + } + + public function clearPublicKey() + { + unset($this->public_key); + } + + /** + * Optional. The public key that corresponds to this config. This is, for + * example, used when issuing + * [Certificates][google.cloud.security.privateca.v1.Certificate], but not + * when creating a self-signed + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * or + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * CSR. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.PublicKey public_key = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\Security\PrivateCA\V1\PublicKey $var + * @return $this + */ + public function setPublicKey($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\PublicKey::class); + $this->public_key = $var; + + return $this; + } + + /** + * Optional. When specified this provides a custom SKI to be used in the + * certificate. This should only be used to maintain a SKI of an existing CA + * originally created outside CA service, which was not generated using method + * (1) described in RFC 5280 section 4.2.1.2. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateConfig.KeyId subject_key_id = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\Security\PrivateCA\V1\CertificateConfig\KeyId|null + */ + public function getSubjectKeyId() + { + return $this->subject_key_id; + } + + public function hasSubjectKeyId() + { + return isset($this->subject_key_id); + } + + public function clearSubjectKeyId() + { + unset($this->subject_key_id); + } + + /** + * Optional. When specified this provides a custom SKI to be used in the + * certificate. This should only be used to maintain a SKI of an existing CA + * originally created outside CA service, which was not generated using method + * (1) described in RFC 5280 section 4.2.1.2. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateConfig.KeyId subject_key_id = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\Security\PrivateCA\V1\CertificateConfig\KeyId $var + * @return $this + */ + public function setSubjectKeyId($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CertificateConfig\KeyId::class); + $this->subject_key_id = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateConfig/KeyId.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateConfig/KeyId.php new file mode 100644 index 000000000000..c8873de11789 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateConfig/KeyId.php @@ -0,0 +1,72 @@ +google.cloud.security.privateca.v1.CertificateConfig.KeyId + */ +class KeyId extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The value of this KeyId encoded in lowercase hexadecimal. This + * is most likely the 160 bit SHA-1 hash of the public key. + * + * Generated from protobuf field string key_id = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $key_id = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $key_id + * Required. The value of this KeyId encoded in lowercase hexadecimal. This + * is most likely the 160 bit SHA-1 hash of the public key. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * Required. The value of this KeyId encoded in lowercase hexadecimal. This + * is most likely the 160 bit SHA-1 hash of the public key. + * + * Generated from protobuf field string key_id = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getKeyId() + { + return $this->key_id; + } + + /** + * Required. The value of this KeyId encoded in lowercase hexadecimal. This + * is most likely the 160 bit SHA-1 hash of the public key. + * + * Generated from protobuf field string key_id = 1 [(.google.api.field_behavior) = REQUIRED]; + * @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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateConfig/SubjectConfig.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateConfig/SubjectConfig.php new file mode 100644 index 000000000000..30bba29d3256 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateConfig/SubjectConfig.php @@ -0,0 +1,126 @@ +google.cloud.security.privateca.v1.CertificateConfig.SubjectConfig + */ +class SubjectConfig extends \Google\Protobuf\Internal\Message +{ + /** + * Optional. Contains distinguished name fields such as the common name, + * location and organization. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.Subject subject = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $subject = null; + /** + * Optional. The subject alternative name fields. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.SubjectAltNames subject_alt_name = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $subject_alt_name = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Security\PrivateCA\V1\Subject $subject + * Optional. Contains distinguished name fields such as the common name, + * location and organization. + * @type \Google\Cloud\Security\PrivateCA\V1\SubjectAltNames $subject_alt_name + * Optional. The subject alternative name fields. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * Optional. Contains distinguished name fields such as the common name, + * location and organization. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.Subject subject = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\Security\PrivateCA\V1\Subject|null + */ + public function getSubject() + { + return $this->subject; + } + + public function hasSubject() + { + return isset($this->subject); + } + + public function clearSubject() + { + unset($this->subject); + } + + /** + * Optional. Contains distinguished name fields such as the common name, + * location and organization. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.Subject subject = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\Security\PrivateCA\V1\Subject $var + * @return $this + */ + public function setSubject($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\Subject::class); + $this->subject = $var; + + return $this; + } + + /** + * Optional. The subject alternative name fields. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.SubjectAltNames subject_alt_name = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\Security\PrivateCA\V1\SubjectAltNames|null + */ + public function getSubjectAltName() + { + return $this->subject_alt_name; + } + + public function hasSubjectAltName() + { + return isset($this->subject_alt_name); + } + + public function clearSubjectAltName() + { + unset($this->subject_alt_name); + } + + /** + * Optional. The subject alternative name fields. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.SubjectAltNames subject_alt_name = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\Security\PrivateCA\V1\SubjectAltNames $var + * @return $this + */ + public function setSubjectAltName($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\SubjectAltNames::class); + $this->subject_alt_name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateDescription.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateDescription.php new file mode 100644 index 000000000000..569224be347b --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateDescription.php @@ -0,0 +1,438 @@ +google.cloud.security.privateca.v1.CertificateDescription + */ +class CertificateDescription extends \Google\Protobuf\Internal\Message +{ + /** + * Describes some of the values in a certificate that are related to the + * subject and lifetime. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateDescription.SubjectDescription subject_description = 1; + */ + protected $subject_description = null; + /** + * Describes some of the technical X.509 fields in a certificate. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.X509Parameters x509_description = 2; + */ + protected $x509_description = null; + /** + * The public key that corresponds to an issued certificate. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.PublicKey public_key = 3; + */ + protected $public_key = null; + /** + * Provides a means of identifiying certificates that contain a particular + * public key, per https://tools.ietf.org/html/rfc5280#section-4.2.1.2. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateDescription.KeyId subject_key_id = 4; + */ + protected $subject_key_id = null; + /** + * Identifies the subject_key_id of the parent certificate, per + * https://tools.ietf.org/html/rfc5280#section-4.2.1.1 + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateDescription.KeyId authority_key_id = 5; + */ + protected $authority_key_id = null; + /** + * Describes a list of locations to obtain CRL information, i.e. + * the DistributionPoint.fullName described by + * https://tools.ietf.org/html/rfc5280#section-4.2.1.13 + * + * Generated from protobuf field repeated string crl_distribution_points = 6; + */ + private $crl_distribution_points; + /** + * Describes lists of issuer CA certificate URLs that appear in the + * "Authority Information Access" extension in the certificate. + * + * Generated from protobuf field repeated string aia_issuing_certificate_urls = 7; + */ + private $aia_issuing_certificate_urls; + /** + * The hash of the x.509 certificate. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateDescription.CertificateFingerprint cert_fingerprint = 8; + */ + protected $cert_fingerprint = null; + /** + * The hash of the pre-signed certificate, which will be signed by the CA. + * Corresponds to the TBS Certificate in + * https://tools.ietf.org/html/rfc5280#section-4.1.2. The field will always be + * populated. + * + * Generated from protobuf field string tbs_certificate_digest = 9; + */ + protected $tbs_certificate_digest = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Security\PrivateCA\V1\CertificateDescription\SubjectDescription $subject_description + * Describes some of the values in a certificate that are related to the + * subject and lifetime. + * @type \Google\Cloud\Security\PrivateCA\V1\X509Parameters $x509_description + * Describes some of the technical X.509 fields in a certificate. + * @type \Google\Cloud\Security\PrivateCA\V1\PublicKey $public_key + * The public key that corresponds to an issued certificate. + * @type \Google\Cloud\Security\PrivateCA\V1\CertificateDescription\KeyId $subject_key_id + * Provides a means of identifiying certificates that contain a particular + * public key, per https://tools.ietf.org/html/rfc5280#section-4.2.1.2. + * @type \Google\Cloud\Security\PrivateCA\V1\CertificateDescription\KeyId $authority_key_id + * Identifies the subject_key_id of the parent certificate, per + * https://tools.ietf.org/html/rfc5280#section-4.2.1.1 + * @type string[] $crl_distribution_points + * Describes a list of locations to obtain CRL information, i.e. + * the DistributionPoint.fullName described by + * https://tools.ietf.org/html/rfc5280#section-4.2.1.13 + * @type string[] $aia_issuing_certificate_urls + * Describes lists of issuer CA certificate URLs that appear in the + * "Authority Information Access" extension in the certificate. + * @type \Google\Cloud\Security\PrivateCA\V1\CertificateDescription\CertificateFingerprint $cert_fingerprint + * The hash of the x.509 certificate. + * @type string $tbs_certificate_digest + * The hash of the pre-signed certificate, which will be signed by the CA. + * Corresponds to the TBS Certificate in + * https://tools.ietf.org/html/rfc5280#section-4.1.2. The field will always be + * populated. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * Describes some of the values in a certificate that are related to the + * subject and lifetime. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateDescription.SubjectDescription subject_description = 1; + * @return \Google\Cloud\Security\PrivateCA\V1\CertificateDescription\SubjectDescription|null + */ + public function getSubjectDescription() + { + return $this->subject_description; + } + + public function hasSubjectDescription() + { + return isset($this->subject_description); + } + + public function clearSubjectDescription() + { + unset($this->subject_description); + } + + /** + * Describes some of the values in a certificate that are related to the + * subject and lifetime. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateDescription.SubjectDescription subject_description = 1; + * @param \Google\Cloud\Security\PrivateCA\V1\CertificateDescription\SubjectDescription $var + * @return $this + */ + public function setSubjectDescription($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CertificateDescription\SubjectDescription::class); + $this->subject_description = $var; + + return $this; + } + + /** + * Describes some of the technical X.509 fields in a certificate. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.X509Parameters x509_description = 2; + * @return \Google\Cloud\Security\PrivateCA\V1\X509Parameters|null + */ + public function getX509Description() + { + return $this->x509_description; + } + + public function hasX509Description() + { + return isset($this->x509_description); + } + + public function clearX509Description() + { + unset($this->x509_description); + } + + /** + * Describes some of the technical X.509 fields in a certificate. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.X509Parameters x509_description = 2; + * @param \Google\Cloud\Security\PrivateCA\V1\X509Parameters $var + * @return $this + */ + public function setX509Description($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\X509Parameters::class); + $this->x509_description = $var; + + return $this; + } + + /** + * The public key that corresponds to an issued certificate. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.PublicKey public_key = 3; + * @return \Google\Cloud\Security\PrivateCA\V1\PublicKey|null + */ + public function getPublicKey() + { + return $this->public_key; + } + + public function hasPublicKey() + { + return isset($this->public_key); + } + + public function clearPublicKey() + { + unset($this->public_key); + } + + /** + * The public key that corresponds to an issued certificate. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.PublicKey public_key = 3; + * @param \Google\Cloud\Security\PrivateCA\V1\PublicKey $var + * @return $this + */ + public function setPublicKey($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\PublicKey::class); + $this->public_key = $var; + + return $this; + } + + /** + * Provides a means of identifiying certificates that contain a particular + * public key, per https://tools.ietf.org/html/rfc5280#section-4.2.1.2. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateDescription.KeyId subject_key_id = 4; + * @return \Google\Cloud\Security\PrivateCA\V1\CertificateDescription\KeyId|null + */ + public function getSubjectKeyId() + { + return $this->subject_key_id; + } + + public function hasSubjectKeyId() + { + return isset($this->subject_key_id); + } + + public function clearSubjectKeyId() + { + unset($this->subject_key_id); + } + + /** + * Provides a means of identifiying certificates that contain a particular + * public key, per https://tools.ietf.org/html/rfc5280#section-4.2.1.2. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateDescription.KeyId subject_key_id = 4; + * @param \Google\Cloud\Security\PrivateCA\V1\CertificateDescription\KeyId $var + * @return $this + */ + public function setSubjectKeyId($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CertificateDescription\KeyId::class); + $this->subject_key_id = $var; + + return $this; + } + + /** + * Identifies the subject_key_id of the parent certificate, per + * https://tools.ietf.org/html/rfc5280#section-4.2.1.1 + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateDescription.KeyId authority_key_id = 5; + * @return \Google\Cloud\Security\PrivateCA\V1\CertificateDescription\KeyId|null + */ + public function getAuthorityKeyId() + { + return $this->authority_key_id; + } + + public function hasAuthorityKeyId() + { + return isset($this->authority_key_id); + } + + public function clearAuthorityKeyId() + { + unset($this->authority_key_id); + } + + /** + * Identifies the subject_key_id of the parent certificate, per + * https://tools.ietf.org/html/rfc5280#section-4.2.1.1 + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateDescription.KeyId authority_key_id = 5; + * @param \Google\Cloud\Security\PrivateCA\V1\CertificateDescription\KeyId $var + * @return $this + */ + public function setAuthorityKeyId($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CertificateDescription\KeyId::class); + $this->authority_key_id = $var; + + return $this; + } + + /** + * Describes a list of locations to obtain CRL information, i.e. + * the DistributionPoint.fullName described by + * https://tools.ietf.org/html/rfc5280#section-4.2.1.13 + * + * Generated from protobuf field repeated string crl_distribution_points = 6; + * @return RepeatedField + */ + public function getCrlDistributionPoints() + { + return $this->crl_distribution_points; + } + + /** + * Describes a list of locations to obtain CRL information, i.e. + * the DistributionPoint.fullName described by + * https://tools.ietf.org/html/rfc5280#section-4.2.1.13 + * + * Generated from protobuf field repeated string crl_distribution_points = 6; + * @param string[] $var + * @return $this + */ + public function setCrlDistributionPoints($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->crl_distribution_points = $arr; + + return $this; + } + + /** + * Describes lists of issuer CA certificate URLs that appear in the + * "Authority Information Access" extension in the certificate. + * + * Generated from protobuf field repeated string aia_issuing_certificate_urls = 7; + * @return RepeatedField + */ + public function getAiaIssuingCertificateUrls() + { + return $this->aia_issuing_certificate_urls; + } + + /** + * Describes lists of issuer CA certificate URLs that appear in the + * "Authority Information Access" extension in the certificate. + * + * Generated from protobuf field repeated string aia_issuing_certificate_urls = 7; + * @param string[] $var + * @return $this + */ + public function setAiaIssuingCertificateUrls($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->aia_issuing_certificate_urls = $arr; + + return $this; + } + + /** + * The hash of the x.509 certificate. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateDescription.CertificateFingerprint cert_fingerprint = 8; + * @return \Google\Cloud\Security\PrivateCA\V1\CertificateDescription\CertificateFingerprint|null + */ + public function getCertFingerprint() + { + return $this->cert_fingerprint; + } + + public function hasCertFingerprint() + { + return isset($this->cert_fingerprint); + } + + public function clearCertFingerprint() + { + unset($this->cert_fingerprint); + } + + /** + * The hash of the x.509 certificate. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateDescription.CertificateFingerprint cert_fingerprint = 8; + * @param \Google\Cloud\Security\PrivateCA\V1\CertificateDescription\CertificateFingerprint $var + * @return $this + */ + public function setCertFingerprint($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CertificateDescription\CertificateFingerprint::class); + $this->cert_fingerprint = $var; + + return $this; + } + + /** + * The hash of the pre-signed certificate, which will be signed by the CA. + * Corresponds to the TBS Certificate in + * https://tools.ietf.org/html/rfc5280#section-4.1.2. The field will always be + * populated. + * + * Generated from protobuf field string tbs_certificate_digest = 9; + * @return string + */ + public function getTbsCertificateDigest() + { + return $this->tbs_certificate_digest; + } + + /** + * The hash of the pre-signed certificate, which will be signed by the CA. + * Corresponds to the TBS Certificate in + * https://tools.ietf.org/html/rfc5280#section-4.1.2. The field will always be + * populated. + * + * Generated from protobuf field string tbs_certificate_digest = 9; + * @param string $var + * @return $this + */ + public function setTbsCertificateDigest($var) + { + GPBUtil::checkString($var, True); + $this->tbs_certificate_digest = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateDescription/CertificateFingerprint.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateDescription/CertificateFingerprint.php new file mode 100644 index 000000000000..0917921343d8 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateDescription/CertificateFingerprint.php @@ -0,0 +1,67 @@ +google.cloud.security.privateca.v1.CertificateDescription.CertificateFingerprint + */ +class CertificateFingerprint extends \Google\Protobuf\Internal\Message +{ + /** + * The SHA 256 hash, encoded in hexadecimal, of the DER x509 certificate. + * + * Generated from protobuf field string sha256_hash = 1; + */ + protected $sha256_hash = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $sha256_hash + * The SHA 256 hash, encoded in hexadecimal, of the DER x509 certificate. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * The SHA 256 hash, encoded in hexadecimal, of the DER x509 certificate. + * + * Generated from protobuf field string sha256_hash = 1; + * @return string + */ + public function getSha256Hash() + { + return $this->sha256_hash; + } + + /** + * The SHA 256 hash, encoded in hexadecimal, of the DER x509 certificate. + * + * Generated from protobuf field string sha256_hash = 1; + * @param string $var + * @return $this + */ + public function setSha256Hash($var) + { + GPBUtil::checkString($var, True); + $this->sha256_hash = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateDescription/KeyId.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateDescription/KeyId.php new file mode 100644 index 000000000000..6d1dce5a6e80 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateDescription/KeyId.php @@ -0,0 +1,72 @@ +google.cloud.security.privateca.v1.CertificateDescription.KeyId + */ +class KeyId extends \Google\Protobuf\Internal\Message +{ + /** + * Optional. The value of this KeyId encoded in lowercase hexadecimal. This + * is most likely the 160 bit SHA-1 hash of the public key. + * + * Generated from protobuf field string key_id = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $key_id = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $key_id + * Optional. The value of this KeyId encoded in lowercase hexadecimal. This + * is most likely the 160 bit SHA-1 hash of the public key. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * Optional. The value of this KeyId encoded in lowercase hexadecimal. This + * is most likely the 160 bit SHA-1 hash of the public key. + * + * Generated from protobuf field string key_id = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getKeyId() + { + return $this->key_id; + } + + /** + * Optional. The value of this KeyId encoded in lowercase hexadecimal. This + * is most likely the 160 bit SHA-1 hash of the public key. + * + * Generated from protobuf field string key_id = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateDescription/SubjectDescription.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateDescription/SubjectDescription.php new file mode 100644 index 000000000000..1dad6e22127c --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateDescription/SubjectDescription.php @@ -0,0 +1,304 @@ +google.cloud.security.privateca.v1.CertificateDescription.SubjectDescription + */ +class SubjectDescription extends \Google\Protobuf\Internal\Message +{ + /** + * Contains distinguished name fields such as the common name, location and + * / organization. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.Subject subject = 1; + */ + protected $subject = null; + /** + * The subject alternative name fields. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.SubjectAltNames subject_alt_name = 2; + */ + protected $subject_alt_name = null; + /** + * The serial number encoded in lowercase hexadecimal. + * + * Generated from protobuf field string hex_serial_number = 3; + */ + protected $hex_serial_number = ''; + /** + * For convenience, the actual lifetime of an issued certificate. + * + * Generated from protobuf field .google.protobuf.Duration lifetime = 4; + */ + protected $lifetime = null; + /** + * The time at which the certificate becomes valid. + * + * Generated from protobuf field .google.protobuf.Timestamp not_before_time = 5; + */ + protected $not_before_time = null; + /** + * The time after which the certificate is expired. + * Per RFC 5280, the validity period for a certificate is the period of time + * from not_before_time through not_after_time, inclusive. + * Corresponds to 'not_before_time' + 'lifetime' - 1 second. + * + * Generated from protobuf field .google.protobuf.Timestamp not_after_time = 6; + */ + protected $not_after_time = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Security\PrivateCA\V1\Subject $subject + * Contains distinguished name fields such as the common name, location and + * / organization. + * @type \Google\Cloud\Security\PrivateCA\V1\SubjectAltNames $subject_alt_name + * The subject alternative name fields. + * @type string $hex_serial_number + * The serial number encoded in lowercase hexadecimal. + * @type \Google\Protobuf\Duration $lifetime + * For convenience, the actual lifetime of an issued certificate. + * @type \Google\Protobuf\Timestamp $not_before_time + * The time at which the certificate becomes valid. + * @type \Google\Protobuf\Timestamp $not_after_time + * The time after which the certificate is expired. + * Per RFC 5280, the validity period for a certificate is the period of time + * from not_before_time through not_after_time, inclusive. + * Corresponds to 'not_before_time' + 'lifetime' - 1 second. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * Contains distinguished name fields such as the common name, location and + * / organization. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.Subject subject = 1; + * @return \Google\Cloud\Security\PrivateCA\V1\Subject|null + */ + public function getSubject() + { + return $this->subject; + } + + public function hasSubject() + { + return isset($this->subject); + } + + public function clearSubject() + { + unset($this->subject); + } + + /** + * Contains distinguished name fields such as the common name, location and + * / organization. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.Subject subject = 1; + * @param \Google\Cloud\Security\PrivateCA\V1\Subject $var + * @return $this + */ + public function setSubject($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\Subject::class); + $this->subject = $var; + + return $this; + } + + /** + * The subject alternative name fields. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.SubjectAltNames subject_alt_name = 2; + * @return \Google\Cloud\Security\PrivateCA\V1\SubjectAltNames|null + */ + public function getSubjectAltName() + { + return $this->subject_alt_name; + } + + public function hasSubjectAltName() + { + return isset($this->subject_alt_name); + } + + public function clearSubjectAltName() + { + unset($this->subject_alt_name); + } + + /** + * The subject alternative name fields. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.SubjectAltNames subject_alt_name = 2; + * @param \Google\Cloud\Security\PrivateCA\V1\SubjectAltNames $var + * @return $this + */ + public function setSubjectAltName($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\SubjectAltNames::class); + $this->subject_alt_name = $var; + + return $this; + } + + /** + * The serial number encoded in lowercase hexadecimal. + * + * Generated from protobuf field string hex_serial_number = 3; + * @return string + */ + public function getHexSerialNumber() + { + return $this->hex_serial_number; + } + + /** + * The serial number encoded in lowercase hexadecimal. + * + * Generated from protobuf field string hex_serial_number = 3; + * @param string $var + * @return $this + */ + public function setHexSerialNumber($var) + { + GPBUtil::checkString($var, True); + $this->hex_serial_number = $var; + + return $this; + } + + /** + * For convenience, the actual lifetime of an issued certificate. + * + * Generated from protobuf field .google.protobuf.Duration lifetime = 4; + * @return \Google\Protobuf\Duration|null + */ + public function getLifetime() + { + return $this->lifetime; + } + + public function hasLifetime() + { + return isset($this->lifetime); + } + + public function clearLifetime() + { + unset($this->lifetime); + } + + /** + * For convenience, the actual lifetime of an issued certificate. + * + * Generated from protobuf field .google.protobuf.Duration lifetime = 4; + * @param \Google\Protobuf\Duration $var + * @return $this + */ + public function setLifetime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); + $this->lifetime = $var; + + return $this; + } + + /** + * The time at which the certificate becomes valid. + * + * Generated from protobuf field .google.protobuf.Timestamp not_before_time = 5; + * @return \Google\Protobuf\Timestamp|null + */ + public function getNotBeforeTime() + { + return $this->not_before_time; + } + + public function hasNotBeforeTime() + { + return isset($this->not_before_time); + } + + public function clearNotBeforeTime() + { + unset($this->not_before_time); + } + + /** + * The time at which the certificate becomes valid. + * + * Generated from protobuf field .google.protobuf.Timestamp not_before_time = 5; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setNotBeforeTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->not_before_time = $var; + + return $this; + } + + /** + * The time after which the certificate is expired. + * Per RFC 5280, the validity period for a certificate is the period of time + * from not_before_time through not_after_time, inclusive. + * Corresponds to 'not_before_time' + 'lifetime' - 1 second. + * + * Generated from protobuf field .google.protobuf.Timestamp not_after_time = 6; + * @return \Google\Protobuf\Timestamp|null + */ + public function getNotAfterTime() + { + return $this->not_after_time; + } + + public function hasNotAfterTime() + { + return isset($this->not_after_time); + } + + public function clearNotAfterTime() + { + unset($this->not_after_time); + } + + /** + * The time after which the certificate is expired. + * Per RFC 5280, the validity period for a certificate is the period of time + * from not_before_time through not_after_time, inclusive. + * Corresponds to 'not_before_time' + 'lifetime' - 1 second. + * + * Generated from protobuf field .google.protobuf.Timestamp not_after_time = 6; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setNotAfterTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->not_after_time = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateExtensionConstraints.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateExtensionConstraints.php new file mode 100644 index 000000000000..27c29d4fa4ae --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateExtensionConstraints.php @@ -0,0 +1,122 @@ +google.cloud.security.privateca.v1.CertificateExtensionConstraints + */ +class CertificateExtensionConstraints extends \Google\Protobuf\Internal\Message +{ + /** + * Optional. A set of named X.509 extensions. Will be combined with + * [additional_extensions][google.cloud.security.privateca.v1.CertificateExtensionConstraints.additional_extensions] + * to determine the full set of X.509 extensions. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CertificateExtensionConstraints.KnownCertificateExtension known_extensions = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + private $known_extensions; + /** + * Optional. A set of [ObjectIds][google.cloud.security.privateca.v1.ObjectId] + * identifying custom X.509 extensions. Will be combined with + * [known_extensions][google.cloud.security.privateca.v1.CertificateExtensionConstraints.known_extensions] + * to determine the full set of X.509 extensions. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.ObjectId additional_extensions = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + private $additional_extensions; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int[] $known_extensions + * Optional. A set of named X.509 extensions. Will be combined with + * [additional_extensions][google.cloud.security.privateca.v1.CertificateExtensionConstraints.additional_extensions] + * to determine the full set of X.509 extensions. + * @type \Google\Cloud\Security\PrivateCA\V1\ObjectId[] $additional_extensions + * Optional. A set of [ObjectIds][google.cloud.security.privateca.v1.ObjectId] + * identifying custom X.509 extensions. Will be combined with + * [known_extensions][google.cloud.security.privateca.v1.CertificateExtensionConstraints.known_extensions] + * to determine the full set of X.509 extensions. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * Optional. A set of named X.509 extensions. Will be combined with + * [additional_extensions][google.cloud.security.privateca.v1.CertificateExtensionConstraints.additional_extensions] + * to determine the full set of X.509 extensions. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CertificateExtensionConstraints.KnownCertificateExtension known_extensions = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @return RepeatedField + */ + public function getKnownExtensions() + { + return $this->known_extensions; + } + + /** + * Optional. A set of named X.509 extensions. Will be combined with + * [additional_extensions][google.cloud.security.privateca.v1.CertificateExtensionConstraints.additional_extensions] + * to determine the full set of X.509 extensions. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CertificateExtensionConstraints.KnownCertificateExtension known_extensions = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @param int[] $var + * @return $this + */ + public function setKnownExtensions($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\Security\PrivateCA\V1\CertificateExtensionConstraints\KnownCertificateExtension::class); + $this->known_extensions = $arr; + + return $this; + } + + /** + * Optional. A set of [ObjectIds][google.cloud.security.privateca.v1.ObjectId] + * identifying custom X.509 extensions. Will be combined with + * [known_extensions][google.cloud.security.privateca.v1.CertificateExtensionConstraints.known_extensions] + * to determine the full set of X.509 extensions. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.ObjectId additional_extensions = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return RepeatedField<\Google\Cloud\Security\PrivateCA\V1\ObjectId> + */ + public function getAdditionalExtensions() + { + return $this->additional_extensions; + } + + /** + * Optional. A set of [ObjectIds][google.cloud.security.privateca.v1.ObjectId] + * identifying custom X.509 extensions. Will be combined with + * [known_extensions][google.cloud.security.privateca.v1.CertificateExtensionConstraints.known_extensions] + * to determine the full set of X.509 extensions. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.ObjectId additional_extensions = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\Security\PrivateCA\V1\ObjectId[] $var + * @return $this + */ + public function setAdditionalExtensions($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Security\PrivateCA\V1\ObjectId::class); + $this->additional_extensions = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateExtensionConstraints/KnownCertificateExtension.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateExtensionConstraints/KnownCertificateExtension.php new file mode 100644 index 000000000000..acd4be6ab29d --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateExtensionConstraints/KnownCertificateExtension.php @@ -0,0 +1,120 @@ +google.cloud.security.privateca.v1.CertificateExtensionConstraints.KnownCertificateExtension + */ +class KnownCertificateExtension +{ + /** + * Not specified. + * + * Generated from protobuf enum KNOWN_CERTIFICATE_EXTENSION_UNSPECIFIED = 0; + */ + const KNOWN_CERTIFICATE_EXTENSION_UNSPECIFIED = 0; + /** + * Refers to a certificate's Key Usage extension, as described in [RFC 5280 + * section 4.2.1.3](https://tools.ietf.org/html/rfc5280#section-4.2.1.3). + * This corresponds to the + * [KeyUsage.base_key_usage][google.cloud.security.privateca.v1.KeyUsage.base_key_usage] + * field. + * + * Generated from protobuf enum BASE_KEY_USAGE = 1; + */ + const BASE_KEY_USAGE = 1; + /** + * Refers to a certificate's Extended Key Usage extension, as described in + * [RFC 5280 + * section 4.2.1.12](https://tools.ietf.org/html/rfc5280#section-4.2.1.12). + * This corresponds to the + * [KeyUsage.extended_key_usage][google.cloud.security.privateca.v1.KeyUsage.extended_key_usage] + * message. + * + * Generated from protobuf enum EXTENDED_KEY_USAGE = 2; + */ + const EXTENDED_KEY_USAGE = 2; + /** + * Refers to a certificate's Basic Constraints extension, as described in + * [RFC 5280 + * section 4.2.1.9](https://tools.ietf.org/html/rfc5280#section-4.2.1.9). + * This corresponds to the + * [X509Parameters.ca_options][google.cloud.security.privateca.v1.X509Parameters.ca_options] + * field. + * + * Generated from protobuf enum CA_OPTIONS = 3; + */ + const CA_OPTIONS = 3; + /** + * Refers to a certificate's Policy object identifiers, as described in + * [RFC 5280 + * section 4.2.1.4](https://tools.ietf.org/html/rfc5280#section-4.2.1.4). + * This corresponds to the + * [X509Parameters.policy_ids][google.cloud.security.privateca.v1.X509Parameters.policy_ids] + * field. + * + * Generated from protobuf enum POLICY_IDS = 4; + */ + const POLICY_IDS = 4; + /** + * Refers to OCSP servers in a certificate's Authority Information Access + * extension, as described in + * [RFC 5280 + * section 4.2.2.1](https://tools.ietf.org/html/rfc5280#section-4.2.2.1), + * This corresponds to the + * [X509Parameters.aia_ocsp_servers][google.cloud.security.privateca.v1.X509Parameters.aia_ocsp_servers] + * field. + * + * Generated from protobuf enum AIA_OCSP_SERVERS = 5; + */ + const AIA_OCSP_SERVERS = 5; + /** + * Refers to Name Constraints extension as described in + * [RFC 5280 + * section 4.2.1.10](https://tools.ietf.org/html/rfc5280#section-4.2.1.10) + * + * Generated from protobuf enum NAME_CONSTRAINTS = 6; + */ + const NAME_CONSTRAINTS = 6; + + private static $valueToName = [ + self::KNOWN_CERTIFICATE_EXTENSION_UNSPECIFIED => 'KNOWN_CERTIFICATE_EXTENSION_UNSPECIFIED', + self::BASE_KEY_USAGE => 'BASE_KEY_USAGE', + self::EXTENDED_KEY_USAGE => 'EXTENDED_KEY_USAGE', + self::CA_OPTIONS => 'CA_OPTIONS', + self::POLICY_IDS => 'POLICY_IDS', + self::AIA_OCSP_SERVERS => 'AIA_OCSP_SERVERS', + self::NAME_CONSTRAINTS => 'NAME_CONSTRAINTS', + ]; + + 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateIdentityConstraints.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateIdentityConstraints.php new file mode 100644 index 000000000000..eef3861b4394 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateIdentityConstraints.php @@ -0,0 +1,216 @@ +google.cloud.security.privateca.v1.CertificateIdentityConstraints + */ +class CertificateIdentityConstraints extends \Google\Protobuf\Internal\Message +{ + /** + * Optional. A CEL expression that may be used to validate the resolved X.509 + * Subject and/or Subject Alternative Name before a certificate is signed. To + * see the full allowed syntax and some examples, see + * https://cloud.google.com/certificate-authority-service/docs/using-cel + * + * Generated from protobuf field .google.type.Expr cel_expression = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $cel_expression = null; + /** + * Required. If this is true, the + * [Subject][google.cloud.security.privateca.v1.Subject] field may be copied + * from a certificate request into the signed certificate. Otherwise, the + * requested [Subject][google.cloud.security.privateca.v1.Subject] will be + * discarded. + * + * Generated from protobuf field optional bool allow_subject_passthrough = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $allow_subject_passthrough = null; + /** + * Required. If this is true, the + * [SubjectAltNames][google.cloud.security.privateca.v1.SubjectAltNames] + * extension may be copied from a certificate request into the signed + * certificate. Otherwise, the requested + * [SubjectAltNames][google.cloud.security.privateca.v1.SubjectAltNames] will + * be discarded. + * + * Generated from protobuf field optional bool allow_subject_alt_names_passthrough = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $allow_subject_alt_names_passthrough = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Type\Expr $cel_expression + * Optional. A CEL expression that may be used to validate the resolved X.509 + * Subject and/or Subject Alternative Name before a certificate is signed. To + * see the full allowed syntax and some examples, see + * https://cloud.google.com/certificate-authority-service/docs/using-cel + * @type bool $allow_subject_passthrough + * Required. If this is true, the + * [Subject][google.cloud.security.privateca.v1.Subject] field may be copied + * from a certificate request into the signed certificate. Otherwise, the + * requested [Subject][google.cloud.security.privateca.v1.Subject] will be + * discarded. + * @type bool $allow_subject_alt_names_passthrough + * Required. If this is true, the + * [SubjectAltNames][google.cloud.security.privateca.v1.SubjectAltNames] + * extension may be copied from a certificate request into the signed + * certificate. Otherwise, the requested + * [SubjectAltNames][google.cloud.security.privateca.v1.SubjectAltNames] will + * be discarded. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * Optional. A CEL expression that may be used to validate the resolved X.509 + * Subject and/or Subject Alternative Name before a certificate is signed. To + * see the full allowed syntax and some examples, see + * https://cloud.google.com/certificate-authority-service/docs/using-cel + * + * Generated from protobuf field .google.type.Expr cel_expression = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Type\Expr|null + */ + public function getCelExpression() + { + return $this->cel_expression; + } + + public function hasCelExpression() + { + return isset($this->cel_expression); + } + + public function clearCelExpression() + { + unset($this->cel_expression); + } + + /** + * Optional. A CEL expression that may be used to validate the resolved X.509 + * Subject and/or Subject Alternative Name before a certificate is signed. To + * see the full allowed syntax and some examples, see + * https://cloud.google.com/certificate-authority-service/docs/using-cel + * + * Generated from protobuf field .google.type.Expr cel_expression = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Type\Expr $var + * @return $this + */ + public function setCelExpression($var) + { + GPBUtil::checkMessage($var, \Google\Type\Expr::class); + $this->cel_expression = $var; + + return $this; + } + + /** + * Required. If this is true, the + * [Subject][google.cloud.security.privateca.v1.Subject] field may be copied + * from a certificate request into the signed certificate. Otherwise, the + * requested [Subject][google.cloud.security.privateca.v1.Subject] will be + * discarded. + * + * Generated from protobuf field optional bool allow_subject_passthrough = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return bool + */ + public function getAllowSubjectPassthrough() + { + return isset($this->allow_subject_passthrough) ? $this->allow_subject_passthrough : false; + } + + public function hasAllowSubjectPassthrough() + { + return isset($this->allow_subject_passthrough); + } + + public function clearAllowSubjectPassthrough() + { + unset($this->allow_subject_passthrough); + } + + /** + * Required. If this is true, the + * [Subject][google.cloud.security.privateca.v1.Subject] field may be copied + * from a certificate request into the signed certificate. Otherwise, the + * requested [Subject][google.cloud.security.privateca.v1.Subject] will be + * discarded. + * + * Generated from protobuf field optional bool allow_subject_passthrough = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param bool $var + * @return $this + */ + public function setAllowSubjectPassthrough($var) + { + GPBUtil::checkBool($var); + $this->allow_subject_passthrough = $var; + + return $this; + } + + /** + * Required. If this is true, the + * [SubjectAltNames][google.cloud.security.privateca.v1.SubjectAltNames] + * extension may be copied from a certificate request into the signed + * certificate. Otherwise, the requested + * [SubjectAltNames][google.cloud.security.privateca.v1.SubjectAltNames] will + * be discarded. + * + * Generated from protobuf field optional bool allow_subject_alt_names_passthrough = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return bool + */ + public function getAllowSubjectAltNamesPassthrough() + { + return isset($this->allow_subject_alt_names_passthrough) ? $this->allow_subject_alt_names_passthrough : false; + } + + public function hasAllowSubjectAltNamesPassthrough() + { + return isset($this->allow_subject_alt_names_passthrough); + } + + public function clearAllowSubjectAltNamesPassthrough() + { + unset($this->allow_subject_alt_names_passthrough); + } + + /** + * Required. If this is true, the + * [SubjectAltNames][google.cloud.security.privateca.v1.SubjectAltNames] + * extension may be copied from a certificate request into the signed + * certificate. Otherwise, the requested + * [SubjectAltNames][google.cloud.security.privateca.v1.SubjectAltNames] will + * be discarded. + * + * Generated from protobuf field optional bool allow_subject_alt_names_passthrough = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param bool $var + * @return $this + */ + public function setAllowSubjectAltNamesPassthrough($var) + { + GPBUtil::checkBool($var); + $this->allow_subject_alt_names_passthrough = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateRevocationList.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateRevocationList.php new file mode 100644 index 000000000000..586fb81d765c --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateRevocationList.php @@ -0,0 +1,448 @@ +google.cloud.security.privateca.v1.CertificateRevocationList + */ +class CertificateRevocationList extends \Google\Protobuf\Internal\Message +{ + /** + * Identifier. The resource name for this + * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] + * in the format `projects/{@*}locations/{@*}caPools/*certificateAuthorities/{@*} + * certificateRevocationLists/*`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + */ + protected $name = ''; + /** + * Output only. The CRL sequence number that appears in pem_crl. + * + * Generated from protobuf field int64 sequence_number = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $sequence_number = 0; + /** + * Output only. The revoked serial numbers that appear in pem_crl. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CertificateRevocationList.RevokedCertificate revoked_certificates = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + private $revoked_certificates; + /** + * Output only. The PEM-encoded X.509 CRL. + * + * Generated from protobuf field string pem_crl = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $pem_crl = ''; + /** + * Output only. The location where 'pem_crl' can be accessed. + * + * Generated from protobuf field string access_url = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $access_url = ''; + /** + * Output only. The + * [State][google.cloud.security.privateca.v1.CertificateRevocationList.State] + * for this + * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList]. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateRevocationList.State state = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $state = 0; + /** + * Output only. The time at which this + * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] + * was created. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $create_time = null; + /** + * Output only. The time at which this + * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] + * was updated. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $update_time = null; + /** + * Output only. The revision ID of this + * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList]. + * A new revision is committed whenever a new CRL is published. The format is + * an 8-character hexadecimal string. + * + * Generated from protobuf field string revision_id = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $revision_id = ''; + /** + * Optional. Labels with user-defined metadata. + * + * Generated from protobuf field map labels = 10 [(.google.api.field_behavior) = OPTIONAL]; + */ + private $labels; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Identifier. The resource name for this + * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] + * in the format `projects/{@*}locations/{@*}caPools/*certificateAuthorities/{@*} + * certificateRevocationLists/*`. + * @type int|string $sequence_number + * Output only. The CRL sequence number that appears in pem_crl. + * @type \Google\Cloud\Security\PrivateCA\V1\CertificateRevocationList\RevokedCertificate[] $revoked_certificates + * Output only. The revoked serial numbers that appear in pem_crl. + * @type string $pem_crl + * Output only. The PEM-encoded X.509 CRL. + * @type string $access_url + * Output only. The location where 'pem_crl' can be accessed. + * @type int $state + * Output only. The + * [State][google.cloud.security.privateca.v1.CertificateRevocationList.State] + * for this + * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList]. + * @type \Google\Protobuf\Timestamp $create_time + * Output only. The time at which this + * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] + * was created. + * @type \Google\Protobuf\Timestamp $update_time + * Output only. The time at which this + * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] + * was updated. + * @type string $revision_id + * Output only. The revision ID of this + * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList]. + * A new revision is committed whenever a new CRL is published. The format is + * an 8-character hexadecimal string. + * @type array|\Google\Protobuf\Internal\MapField $labels + * Optional. Labels with user-defined metadata. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * Identifier. The resource name for this + * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] + * in the format `projects/{@*}locations/{@*}caPools/*certificateAuthorities/{@*} + * certificateRevocationLists/*`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Identifier. The resource name for this + * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] + * in the format `projects/{@*}locations/{@*}caPools/*certificateAuthorities/{@*} + * certificateRevocationLists/*`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Output only. The CRL sequence number that appears in pem_crl. + * + * Generated from protobuf field int64 sequence_number = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int|string + */ + public function getSequenceNumber() + { + return $this->sequence_number; + } + + /** + * Output only. The CRL sequence number that appears in pem_crl. + * + * Generated from protobuf field int64 sequence_number = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int|string $var + * @return $this + */ + public function setSequenceNumber($var) + { + GPBUtil::checkInt64($var); + $this->sequence_number = $var; + + return $this; + } + + /** + * Output only. The revoked serial numbers that appear in pem_crl. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CertificateRevocationList.RevokedCertificate revoked_certificates = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return RepeatedField<\Google\Cloud\Security\PrivateCA\V1\CertificateRevocationList\RevokedCertificate> + */ + public function getRevokedCertificates() + { + return $this->revoked_certificates; + } + + /** + * Output only. The revoked serial numbers that appear in pem_crl. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CertificateRevocationList.RevokedCertificate revoked_certificates = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Cloud\Security\PrivateCA\V1\CertificateRevocationList\RevokedCertificate[] $var + * @return $this + */ + public function setRevokedCertificates($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Security\PrivateCA\V1\CertificateRevocationList\RevokedCertificate::class); + $this->revoked_certificates = $arr; + + return $this; + } + + /** + * Output only. The PEM-encoded X.509 CRL. + * + * Generated from protobuf field string pem_crl = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getPemCrl() + { + return $this->pem_crl; + } + + /** + * Output only. The PEM-encoded X.509 CRL. + * + * Generated from protobuf field string pem_crl = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setPemCrl($var) + { + GPBUtil::checkString($var, True); + $this->pem_crl = $var; + + return $this; + } + + /** + * Output only. The location where 'pem_crl' can be accessed. + * + * Generated from protobuf field string access_url = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getAccessUrl() + { + return $this->access_url; + } + + /** + * Output only. The location where 'pem_crl' can be accessed. + * + * Generated from protobuf field string access_url = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setAccessUrl($var) + { + GPBUtil::checkString($var, True); + $this->access_url = $var; + + return $this; + } + + /** + * Output only. The + * [State][google.cloud.security.privateca.v1.CertificateRevocationList.State] + * for this + * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList]. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateRevocationList.State state = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getState() + { + return $this->state; + } + + /** + * Output only. The + * [State][google.cloud.security.privateca.v1.CertificateRevocationList.State] + * for this + * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList]. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateRevocationList.State state = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setState($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Security\PrivateCA\V1\CertificateRevocationList\State::class); + $this->state = $var; + + return $this; + } + + /** + * Output only. The time at which this + * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] + * was created. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 7 [(.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 + * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] + * was created. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 7 [(.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 + * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] + * was updated. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 8 [(.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 at which this + * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] + * was updated. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 8 [(.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 revision ID of this + * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList]. + * A new revision is committed whenever a new CRL is published. The format is + * an 8-character hexadecimal string. + * + * Generated from protobuf field string revision_id = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getRevisionId() + { + return $this->revision_id; + } + + /** + * Output only. The revision ID of this + * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList]. + * A new revision is committed whenever a new CRL is published. The format is + * an 8-character hexadecimal string. + * + * Generated from protobuf field string revision_id = 9 [(.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; + } + + /** + * Optional. Labels with user-defined metadata. + * + * Generated from protobuf field map labels = 10 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Protobuf\Internal\MapField + */ + public function getLabels() + { + return $this->labels; + } + + /** + * Optional. Labels with user-defined metadata. + * + * Generated from protobuf field map labels = 10 [(.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; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateRevocationList/RevokedCertificate.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateRevocationList/RevokedCertificate.php new file mode 100644 index 000000000000..4a20ce5962e2 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateRevocationList/RevokedCertificate.php @@ -0,0 +1,156 @@ +google.cloud.security.privateca.v1.CertificateRevocationList.RevokedCertificate + */ +class RevokedCertificate extends \Google\Protobuf\Internal\Message +{ + /** + * The resource name for the + * [Certificate][google.cloud.security.privateca.v1.Certificate] in the + * format `projects/{@*}locations/{@*}caPools/{@*}certificates/*`. + * + * Generated from protobuf field string certificate = 1 [(.google.api.resource_reference) = { + */ + protected $certificate = ''; + /** + * The serial number of the + * [Certificate][google.cloud.security.privateca.v1.Certificate]. + * + * Generated from protobuf field string hex_serial_number = 2; + */ + protected $hex_serial_number = ''; + /** + * The reason the + * [Certificate][google.cloud.security.privateca.v1.Certificate] was + * revoked. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.RevocationReason revocation_reason = 3; + */ + protected $revocation_reason = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $certificate + * The resource name for the + * [Certificate][google.cloud.security.privateca.v1.Certificate] in the + * format `projects/{@*}locations/{@*}caPools/{@*}certificates/*`. + * @type string $hex_serial_number + * The serial number of the + * [Certificate][google.cloud.security.privateca.v1.Certificate]. + * @type int $revocation_reason + * The reason the + * [Certificate][google.cloud.security.privateca.v1.Certificate] was + * revoked. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * The resource name for the + * [Certificate][google.cloud.security.privateca.v1.Certificate] in the + * format `projects/{@*}locations/{@*}caPools/{@*}certificates/*`. + * + * Generated from protobuf field string certificate = 1 [(.google.api.resource_reference) = { + * @return string + */ + public function getCertificate() + { + return $this->certificate; + } + + /** + * The resource name for the + * [Certificate][google.cloud.security.privateca.v1.Certificate] in the + * format `projects/{@*}locations/{@*}caPools/{@*}certificates/*`. + * + * Generated from protobuf field string certificate = 1 [(.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setCertificate($var) + { + GPBUtil::checkString($var, True); + $this->certificate = $var; + + return $this; + } + + /** + * The serial number of the + * [Certificate][google.cloud.security.privateca.v1.Certificate]. + * + * Generated from protobuf field string hex_serial_number = 2; + * @return string + */ + public function getHexSerialNumber() + { + return $this->hex_serial_number; + } + + /** + * The serial number of the + * [Certificate][google.cloud.security.privateca.v1.Certificate]. + * + * Generated from protobuf field string hex_serial_number = 2; + * @param string $var + * @return $this + */ + public function setHexSerialNumber($var) + { + GPBUtil::checkString($var, True); + $this->hex_serial_number = $var; + + return $this; + } + + /** + * The reason the + * [Certificate][google.cloud.security.privateca.v1.Certificate] was + * revoked. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.RevocationReason revocation_reason = 3; + * @return int + */ + public function getRevocationReason() + { + return $this->revocation_reason; + } + + /** + * The reason the + * [Certificate][google.cloud.security.privateca.v1.Certificate] was + * revoked. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.RevocationReason revocation_reason = 3; + * @param int $var + * @return $this + */ + public function setRevocationReason($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Security\PrivateCA\V1\RevocationReason::class); + $this->revocation_reason = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateRevocationList/State.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateRevocationList/State.php new file mode 100644 index 000000000000..f2b08643e5bf --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateRevocationList/State.php @@ -0,0 +1,67 @@ +google.cloud.security.privateca.v1.CertificateRevocationList.State + */ +class State +{ + /** + * Not specified. + * + * Generated from protobuf enum STATE_UNSPECIFIED = 0; + */ + const STATE_UNSPECIFIED = 0; + /** + * The + * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] + * is up to date. + * + * Generated from protobuf enum ACTIVE = 1; + */ + const ACTIVE = 1; + /** + * The + * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] + * is no longer current. + * + * Generated from protobuf enum SUPERSEDED = 2; + */ + const SUPERSEDED = 2; + + private static $valueToName = [ + self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', + self::ACTIVE => 'ACTIVE', + self::SUPERSEDED => 'SUPERSEDED', + ]; + + 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateTemplate.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateTemplate.php new file mode 100644 index 000000000000..168c0bcad1ef --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateTemplate.php @@ -0,0 +1,593 @@ +google.cloud.security.privateca.v1.CertificateTemplate + */ +class CertificateTemplate extends \Google\Protobuf\Internal\Message +{ + /** + * Identifier. The resource name for this + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * in the format `projects/{@*}locations/{@*}certificateTemplates/*`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + */ + protected $name = ''; + /** + * Optional. The maximum lifetime allowed for issued + * [Certificates][google.cloud.security.privateca.v1.Certificate] that use + * this template. If the issuing + * [CaPool][google.cloud.security.privateca.v1.CaPool] resource's + * [IssuancePolicy][google.cloud.security.privateca.v1.CaPool.IssuancePolicy] + * specifies a + * [maximum_lifetime][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.maximum_lifetime] + * the minimum of the two durations will be the maximum lifetime for issued + * [Certificates][google.cloud.security.privateca.v1.Certificate]. Note that + * if the issuing + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * expires before a + * [Certificate][google.cloud.security.privateca.v1.Certificate]'s requested + * maximum_lifetime, the effective lifetime will be explicitly truncated + * to match it. + * + * Generated from protobuf field .google.protobuf.Duration maximum_lifetime = 9 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $maximum_lifetime = null; + /** + * Optional. A set of X.509 values that will be applied to all issued + * certificates that use this template. If the certificate request includes + * conflicting values for the same properties, they will be overwritten by the + * values defined here. If the issuing + * [CaPool][google.cloud.security.privateca.v1.CaPool]'s + * [IssuancePolicy][google.cloud.security.privateca.v1.CaPool.IssuancePolicy] + * defines conflicting + * [baseline_values][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.baseline_values] + * for the same properties, the certificate issuance request will fail. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.X509Parameters predefined_values = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $predefined_values = null; + /** + * Optional. Describes constraints on identities that may be appear in + * [Certificates][google.cloud.security.privateca.v1.Certificate] issued using + * this template. If this is omitted, then this template will not add + * restrictions on a certificate's identity. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateIdentityConstraints identity_constraints = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $identity_constraints = null; + /** + * Optional. Describes the set of X.509 extensions that may appear in a + * [Certificate][google.cloud.security.privateca.v1.Certificate] issued using + * this + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate]. + * If a certificate request sets extensions that don't appear in the + * [passthrough_extensions][google.cloud.security.privateca.v1.CertificateTemplate.passthrough_extensions], + * those extensions will be dropped. If the issuing + * [CaPool][google.cloud.security.privateca.v1.CaPool]'s + * [IssuancePolicy][google.cloud.security.privateca.v1.CaPool.IssuancePolicy] + * defines + * [baseline_values][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.baseline_values] + * that don't appear here, the certificate issuance request will fail. If this + * is omitted, then this template will not add restrictions on a certificate's + * X.509 extensions. These constraints do not apply to X.509 extensions set in + * this + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate]'s + * [predefined_values][google.cloud.security.privateca.v1.CertificateTemplate.predefined_values]. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateExtensionConstraints passthrough_extensions = 4 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $passthrough_extensions = null; + /** + * Optional. A human-readable description of scenarios this template is + * intended for. + * + * Generated from protobuf field string description = 5 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $description = ''; + /** + * Output only. The time at which this + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * was created. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $create_time = null; + /** + * Output only. The time at which this + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * was updated. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $update_time = null; + /** + * Optional. Labels with user-defined metadata. + * + * Generated from protobuf field map labels = 8 [(.google.api.field_behavior) = OPTIONAL]; + */ + private $labels; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Identifier. The resource name for this + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * in the format `projects/{@*}locations/{@*}certificateTemplates/*`. + * @type \Google\Protobuf\Duration $maximum_lifetime + * Optional. The maximum lifetime allowed for issued + * [Certificates][google.cloud.security.privateca.v1.Certificate] that use + * this template. If the issuing + * [CaPool][google.cloud.security.privateca.v1.CaPool] resource's + * [IssuancePolicy][google.cloud.security.privateca.v1.CaPool.IssuancePolicy] + * specifies a + * [maximum_lifetime][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.maximum_lifetime] + * the minimum of the two durations will be the maximum lifetime for issued + * [Certificates][google.cloud.security.privateca.v1.Certificate]. Note that + * if the issuing + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * expires before a + * [Certificate][google.cloud.security.privateca.v1.Certificate]'s requested + * maximum_lifetime, the effective lifetime will be explicitly truncated + * to match it. + * @type \Google\Cloud\Security\PrivateCA\V1\X509Parameters $predefined_values + * Optional. A set of X.509 values that will be applied to all issued + * certificates that use this template. If the certificate request includes + * conflicting values for the same properties, they will be overwritten by the + * values defined here. If the issuing + * [CaPool][google.cloud.security.privateca.v1.CaPool]'s + * [IssuancePolicy][google.cloud.security.privateca.v1.CaPool.IssuancePolicy] + * defines conflicting + * [baseline_values][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.baseline_values] + * for the same properties, the certificate issuance request will fail. + * @type \Google\Cloud\Security\PrivateCA\V1\CertificateIdentityConstraints $identity_constraints + * Optional. Describes constraints on identities that may be appear in + * [Certificates][google.cloud.security.privateca.v1.Certificate] issued using + * this template. If this is omitted, then this template will not add + * restrictions on a certificate's identity. + * @type \Google\Cloud\Security\PrivateCA\V1\CertificateExtensionConstraints $passthrough_extensions + * Optional. Describes the set of X.509 extensions that may appear in a + * [Certificate][google.cloud.security.privateca.v1.Certificate] issued using + * this + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate]. + * If a certificate request sets extensions that don't appear in the + * [passthrough_extensions][google.cloud.security.privateca.v1.CertificateTemplate.passthrough_extensions], + * those extensions will be dropped. If the issuing + * [CaPool][google.cloud.security.privateca.v1.CaPool]'s + * [IssuancePolicy][google.cloud.security.privateca.v1.CaPool.IssuancePolicy] + * defines + * [baseline_values][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.baseline_values] + * that don't appear here, the certificate issuance request will fail. If this + * is omitted, then this template will not add restrictions on a certificate's + * X.509 extensions. These constraints do not apply to X.509 extensions set in + * this + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate]'s + * [predefined_values][google.cloud.security.privateca.v1.CertificateTemplate.predefined_values]. + * @type string $description + * Optional. A human-readable description of scenarios this template is + * intended for. + * @type \Google\Protobuf\Timestamp $create_time + * Output only. The time at which this + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * was created. + * @type \Google\Protobuf\Timestamp $update_time + * Output only. The time at which this + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * was updated. + * @type array|\Google\Protobuf\Internal\MapField $labels + * Optional. Labels with user-defined metadata. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * Identifier. The resource name for this + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * in the format `projects/{@*}locations/{@*}certificateTemplates/*`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Identifier. The resource name for this + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * in the format `projects/{@*}locations/{@*}certificateTemplates/*`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Optional. The maximum lifetime allowed for issued + * [Certificates][google.cloud.security.privateca.v1.Certificate] that use + * this template. If the issuing + * [CaPool][google.cloud.security.privateca.v1.CaPool] resource's + * [IssuancePolicy][google.cloud.security.privateca.v1.CaPool.IssuancePolicy] + * specifies a + * [maximum_lifetime][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.maximum_lifetime] + * the minimum of the two durations will be the maximum lifetime for issued + * [Certificates][google.cloud.security.privateca.v1.Certificate]. Note that + * if the issuing + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * expires before a + * [Certificate][google.cloud.security.privateca.v1.Certificate]'s requested + * maximum_lifetime, the effective lifetime will be explicitly truncated + * to match it. + * + * Generated from protobuf field .google.protobuf.Duration maximum_lifetime = 9 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Protobuf\Duration|null + */ + public function getMaximumLifetime() + { + return $this->maximum_lifetime; + } + + public function hasMaximumLifetime() + { + return isset($this->maximum_lifetime); + } + + public function clearMaximumLifetime() + { + unset($this->maximum_lifetime); + } + + /** + * Optional. The maximum lifetime allowed for issued + * [Certificates][google.cloud.security.privateca.v1.Certificate] that use + * this template. If the issuing + * [CaPool][google.cloud.security.privateca.v1.CaPool] resource's + * [IssuancePolicy][google.cloud.security.privateca.v1.CaPool.IssuancePolicy] + * specifies a + * [maximum_lifetime][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.maximum_lifetime] + * the minimum of the two durations will be the maximum lifetime for issued + * [Certificates][google.cloud.security.privateca.v1.Certificate]. Note that + * if the issuing + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * expires before a + * [Certificate][google.cloud.security.privateca.v1.Certificate]'s requested + * maximum_lifetime, the effective lifetime will be explicitly truncated + * to match it. + * + * Generated from protobuf field .google.protobuf.Duration maximum_lifetime = 9 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Protobuf\Duration $var + * @return $this + */ + public function setMaximumLifetime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); + $this->maximum_lifetime = $var; + + return $this; + } + + /** + * Optional. A set of X.509 values that will be applied to all issued + * certificates that use this template. If the certificate request includes + * conflicting values for the same properties, they will be overwritten by the + * values defined here. If the issuing + * [CaPool][google.cloud.security.privateca.v1.CaPool]'s + * [IssuancePolicy][google.cloud.security.privateca.v1.CaPool.IssuancePolicy] + * defines conflicting + * [baseline_values][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.baseline_values] + * for the same properties, the certificate issuance request will fail. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.X509Parameters predefined_values = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\Security\PrivateCA\V1\X509Parameters|null + */ + public function getPredefinedValues() + { + return $this->predefined_values; + } + + public function hasPredefinedValues() + { + return isset($this->predefined_values); + } + + public function clearPredefinedValues() + { + unset($this->predefined_values); + } + + /** + * Optional. A set of X.509 values that will be applied to all issued + * certificates that use this template. If the certificate request includes + * conflicting values for the same properties, they will be overwritten by the + * values defined here. If the issuing + * [CaPool][google.cloud.security.privateca.v1.CaPool]'s + * [IssuancePolicy][google.cloud.security.privateca.v1.CaPool.IssuancePolicy] + * defines conflicting + * [baseline_values][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.baseline_values] + * for the same properties, the certificate issuance request will fail. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.X509Parameters predefined_values = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\Security\PrivateCA\V1\X509Parameters $var + * @return $this + */ + public function setPredefinedValues($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\X509Parameters::class); + $this->predefined_values = $var; + + return $this; + } + + /** + * Optional. Describes constraints on identities that may be appear in + * [Certificates][google.cloud.security.privateca.v1.Certificate] issued using + * this template. If this is omitted, then this template will not add + * restrictions on a certificate's identity. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateIdentityConstraints identity_constraints = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\Security\PrivateCA\V1\CertificateIdentityConstraints|null + */ + public function getIdentityConstraints() + { + return $this->identity_constraints; + } + + public function hasIdentityConstraints() + { + return isset($this->identity_constraints); + } + + public function clearIdentityConstraints() + { + unset($this->identity_constraints); + } + + /** + * Optional. Describes constraints on identities that may be appear in + * [Certificates][google.cloud.security.privateca.v1.Certificate] issued using + * this template. If this is omitted, then this template will not add + * restrictions on a certificate's identity. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateIdentityConstraints identity_constraints = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\Security\PrivateCA\V1\CertificateIdentityConstraints $var + * @return $this + */ + public function setIdentityConstraints($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CertificateIdentityConstraints::class); + $this->identity_constraints = $var; + + return $this; + } + + /** + * Optional. Describes the set of X.509 extensions that may appear in a + * [Certificate][google.cloud.security.privateca.v1.Certificate] issued using + * this + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate]. + * If a certificate request sets extensions that don't appear in the + * [passthrough_extensions][google.cloud.security.privateca.v1.CertificateTemplate.passthrough_extensions], + * those extensions will be dropped. If the issuing + * [CaPool][google.cloud.security.privateca.v1.CaPool]'s + * [IssuancePolicy][google.cloud.security.privateca.v1.CaPool.IssuancePolicy] + * defines + * [baseline_values][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.baseline_values] + * that don't appear here, the certificate issuance request will fail. If this + * is omitted, then this template will not add restrictions on a certificate's + * X.509 extensions. These constraints do not apply to X.509 extensions set in + * this + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate]'s + * [predefined_values][google.cloud.security.privateca.v1.CertificateTemplate.predefined_values]. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateExtensionConstraints passthrough_extensions = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\Security\PrivateCA\V1\CertificateExtensionConstraints|null + */ + public function getPassthroughExtensions() + { + return $this->passthrough_extensions; + } + + public function hasPassthroughExtensions() + { + return isset($this->passthrough_extensions); + } + + public function clearPassthroughExtensions() + { + unset($this->passthrough_extensions); + } + + /** + * Optional. Describes the set of X.509 extensions that may appear in a + * [Certificate][google.cloud.security.privateca.v1.Certificate] issued using + * this + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate]. + * If a certificate request sets extensions that don't appear in the + * [passthrough_extensions][google.cloud.security.privateca.v1.CertificateTemplate.passthrough_extensions], + * those extensions will be dropped. If the issuing + * [CaPool][google.cloud.security.privateca.v1.CaPool]'s + * [IssuancePolicy][google.cloud.security.privateca.v1.CaPool.IssuancePolicy] + * defines + * [baseline_values][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.baseline_values] + * that don't appear here, the certificate issuance request will fail. If this + * is omitted, then this template will not add restrictions on a certificate's + * X.509 extensions. These constraints do not apply to X.509 extensions set in + * this + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate]'s + * [predefined_values][google.cloud.security.privateca.v1.CertificateTemplate.predefined_values]. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateExtensionConstraints passthrough_extensions = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\Security\PrivateCA\V1\CertificateExtensionConstraints $var + * @return $this + */ + public function setPassthroughExtensions($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CertificateExtensionConstraints::class); + $this->passthrough_extensions = $var; + + return $this; + } + + /** + * Optional. A human-readable description of scenarios this template is + * intended for. + * + * Generated from protobuf field string description = 5 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * Optional. A human-readable description of scenarios this template is + * intended for. + * + * Generated from protobuf field string description = 5 [(.google.api.field_behavior) = OPTIONAL]; + * @param string $var + * @return $this + */ + public function setDescription($var) + { + GPBUtil::checkString($var, True); + $this->description = $var; + + return $this; + } + + /** + * Output only. The time at which this + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * was created. + * + * 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. The time at which this + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * was created. + * + * 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. The time at which this + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * was updated. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 7 [(.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 at which this + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * was updated. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 7 [(.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. Labels with user-defined metadata. + * + * Generated from protobuf field map labels = 8 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Protobuf\Internal\MapField + */ + public function getLabels() + { + return $this->labels; + } + + /** + * Optional. Labels with user-defined metadata. + * + * Generated from protobuf field map labels = 8 [(.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; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CreateCaPoolRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CreateCaPoolRequest.php new file mode 100644 index 000000000000..977761d36040 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CreateCaPoolRequest.php @@ -0,0 +1,258 @@ +google.cloud.security.privateca.v1.CreateCaPoolRequest + */ +class CreateCaPoolRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the location associated with the + * [CaPool][google.cloud.security.privateca.v1.CaPool], in the format + * `projects/{@*}locations/*`. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. It must be unique within a location and match the regular + * expression `[a-zA-Z0-9_-]{1,63}` + * + * Generated from protobuf field string ca_pool_id = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $ca_pool_id = ''; + /** + * Required. A [CaPool][google.cloud.security.privateca.v1.CaPool] with + * initial field values. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool ca_pool = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $ca_pool = null; + /** + * Optional. An 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, (.google.api.field_info) = { + */ + protected $request_id = ''; + + /** + * @param string $parent Required. The resource name of the location associated with the + * [CaPool][google.cloud.security.privateca.v1.CaPool], in the format + * `projects/*/locations/*`. Please see + * {@see CertificateAuthorityServiceClient::locationName()} for help formatting this field. + * @param \Google\Cloud\Security\PrivateCA\V1\CaPool $caPool Required. A [CaPool][google.cloud.security.privateca.v1.CaPool] with + * initial field values. + * @param string $caPoolId Required. It must be unique within a location and match the regular + * expression `[a-zA-Z0-9_-]{1,63}` + * + * @return \Google\Cloud\Security\PrivateCA\V1\CreateCaPoolRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\Security\PrivateCA\V1\CaPool $caPool, string $caPoolId): self + { + return (new self()) + ->setParent($parent) + ->setCaPool($caPool) + ->setCaPoolId($caPoolId); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. The resource name of the location associated with the + * [CaPool][google.cloud.security.privateca.v1.CaPool], in the format + * `projects/{@*}locations/*`. + * @type string $ca_pool_id + * Required. It must be unique within a location and match the regular + * expression `[a-zA-Z0-9_-]{1,63}` + * @type \Google\Cloud\Security\PrivateCA\V1\CaPool $ca_pool + * Required. A [CaPool][google.cloud.security.privateca.v1.CaPool] with + * initial field values. + * @type string $request_id + * Optional. An 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\Security\Privateca\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the location associated with the + * [CaPool][google.cloud.security.privateca.v1.CaPool], 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 associated with the + * [CaPool][google.cloud.security.privateca.v1.CaPool], 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. It must be unique within a location and match the regular + * expression `[a-zA-Z0-9_-]{1,63}` + * + * Generated from protobuf field string ca_pool_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getCaPoolId() + { + return $this->ca_pool_id; + } + + /** + * Required. It must be unique within a location and match the regular + * expression `[a-zA-Z0-9_-]{1,63}` + * + * Generated from protobuf field string ca_pool_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setCaPoolId($var) + { + GPBUtil::checkString($var, True); + $this->ca_pool_id = $var; + + return $this; + } + + /** + * Required. A [CaPool][google.cloud.security.privateca.v1.CaPool] with + * initial field values. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool ca_pool = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Security\PrivateCA\V1\CaPool|null + */ + public function getCaPool() + { + return $this->ca_pool; + } + + public function hasCaPool() + { + return isset($this->ca_pool); + } + + public function clearCaPool() + { + unset($this->ca_pool); + } + + /** + * Required. A [CaPool][google.cloud.security.privateca.v1.CaPool] with + * initial field values. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool ca_pool = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Security\PrivateCA\V1\CaPool $var + * @return $this + */ + public function setCaPool($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CaPool::class); + $this->ca_pool = $var; + + return $this; + } + + /** + * Optional. An 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, (.google.api.field_info) = { + * @return string + */ + public function getRequestId() + { + return $this->request_id; + } + + /** + * Optional. An 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, (.google.api.field_info) = { + * @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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CreateCertificateAuthorityRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CreateCertificateAuthorityRequest.php new file mode 100644 index 000000000000..d8a521c6e17b --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CreateCertificateAuthorityRequest.php @@ -0,0 +1,268 @@ +google.cloud.security.privateca.v1.CreateCertificateAuthorityRequest + */ +class CreateCertificateAuthorityRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the + * [CaPool][google.cloud.security.privateca.v1.CaPool] associated with the + * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority], + * in the format `projects/{@*}locations/{@*}caPools/*`. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. It must be unique within a location and match the regular + * expression `[a-zA-Z0-9_-]{1,63}` + * + * Generated from protobuf field string certificate_authority_id = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $certificate_authority_id = ''; + /** + * Required. A + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * with initial field values. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority certificate_authority = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $certificate_authority = null; + /** + * Optional. An 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 resource name of the + * [CaPool][google.cloud.security.privateca.v1.CaPool] associated with the + * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority], + * in the format `projects/*/locations/*/caPools/*`. Please see + * {@see CertificateAuthorityServiceClient::caPoolName()} for help formatting this field. + * @param \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority $certificateAuthority Required. A + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * with initial field values. + * @param string $certificateAuthorityId Required. It must be unique within a location and match the regular + * expression `[a-zA-Z0-9_-]{1,63}` + * + * @return \Google\Cloud\Security\PrivateCA\V1\CreateCertificateAuthorityRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority $certificateAuthority, string $certificateAuthorityId): self + { + return (new self()) + ->setParent($parent) + ->setCertificateAuthority($certificateAuthority) + ->setCertificateAuthorityId($certificateAuthorityId); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. The resource name of the + * [CaPool][google.cloud.security.privateca.v1.CaPool] associated with the + * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority], + * in the format `projects/{@*}locations/{@*}caPools/*`. + * @type string $certificate_authority_id + * Required. It must be unique within a location and match the regular + * expression `[a-zA-Z0-9_-]{1,63}` + * @type \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority $certificate_authority + * Required. A + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * with initial field values. + * @type string $request_id + * Optional. An 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\Security\Privateca\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the + * [CaPool][google.cloud.security.privateca.v1.CaPool] associated with the + * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority], + * in the format `projects/{@*}locations/{@*}caPools/*`. + * + * 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 + * [CaPool][google.cloud.security.privateca.v1.CaPool] associated with the + * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority], + * in the format `projects/{@*}locations/{@*}caPools/*`. + * + * 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. It must be unique within a location and match the regular + * expression `[a-zA-Z0-9_-]{1,63}` + * + * Generated from protobuf field string certificate_authority_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getCertificateAuthorityId() + { + return $this->certificate_authority_id; + } + + /** + * Required. It must be unique within a location and match the regular + * expression `[a-zA-Z0-9_-]{1,63}` + * + * Generated from protobuf field string certificate_authority_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setCertificateAuthorityId($var) + { + GPBUtil::checkString($var, True); + $this->certificate_authority_id = $var; + + return $this; + } + + /** + * Required. A + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * with initial field values. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority certificate_authority = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority|null + */ + public function getCertificateAuthority() + { + return $this->certificate_authority; + } + + public function hasCertificateAuthority() + { + return isset($this->certificate_authority); + } + + public function clearCertificateAuthority() + { + unset($this->certificate_authority); + } + + /** + * Required. A + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * with initial field values. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority certificate_authority = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority $var + * @return $this + */ + public function setCertificateAuthority($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority::class); + $this->certificate_authority = $var; + + return $this; + } + + /** + * Optional. An 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 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CreateCertificateRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CreateCertificateRequest.php new file mode 100644 index 000000000000..52cedd280c8a --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CreateCertificateRequest.php @@ -0,0 +1,451 @@ +google.cloud.security.privateca.v1.CreateCertificateRequest + */ +class CreateCertificateRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the + * [CaPool][google.cloud.security.privateca.v1.CaPool] associated with the + * [Certificate][google.cloud.security.privateca.v1.Certificate], in the + * format `projects/{@*}locations/{@*}caPools/*`. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Optional. It must be unique within a location and match the regular + * expression `[a-zA-Z0-9_-]{1,63}`. This field is required when using a + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the Enterprise + * [CertificateAuthority.tier][google.cloud.security.privateca.v1.CertificateAuthority.tier], + * but is optional and its value is ignored otherwise. + * + * Generated from protobuf field string certificate_id = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $certificate_id = ''; + /** + * Required. A [Certificate][google.cloud.security.privateca.v1.Certificate] + * with initial field values. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.Certificate certificate = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $certificate = null; + /** + * Optional. An 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 = ''; + /** + * Optional. If this is true, no + * [Certificate][google.cloud.security.privateca.v1.Certificate] resource will + * be persisted regardless of the + * [CaPool][google.cloud.security.privateca.v1.CaPool]'s + * [tier][google.cloud.security.privateca.v1.CaPool.tier], and the returned + * [Certificate][google.cloud.security.privateca.v1.Certificate] will not + * contain the + * [pem_certificate][google.cloud.security.privateca.v1.Certificate.pem_certificate] + * field. + * + * Generated from protobuf field bool validate_only = 5 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $validate_only = false; + /** + * Optional. The resource ID of the + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * that should issue the certificate. This optional field will ignore the + * load-balancing scheme of the Pool and directly issue the certificate from + * the CA with the specified ID, contained in the same + * [CaPool][google.cloud.security.privateca.v1.CaPool] referenced by `parent`. + * Per-CA quota rules apply. If left empty, a + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * will be chosen from the [CaPool][google.cloud.security.privateca.v1.CaPool] + * by the service. For example, to issue a + * [Certificate][google.cloud.security.privateca.v1.Certificate] from a + * Certificate Authority with resource name + * "projects/my-project/locations/us-central1/caPools/my-pool/certificateAuthorities/my-ca", + * you can set the + * [parent][google.cloud.security.privateca.v1.CreateCertificateRequest.parent] + * to "projects/my-project/locations/us-central1/caPools/my-pool" and the + * [issuing_certificate_authority_id][google.cloud.security.privateca.v1.CreateCertificateRequest.issuing_certificate_authority_id] + * to "my-ca". + * + * Generated from protobuf field string issuing_certificate_authority_id = 6 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $issuing_certificate_authority_id = ''; + + /** + * @param string $parent Required. The resource name of the + * [CaPool][google.cloud.security.privateca.v1.CaPool] associated with the + * [Certificate][google.cloud.security.privateca.v1.Certificate], in the + * format `projects/*/locations/*/caPools/*`. Please see + * {@see CertificateAuthorityServiceClient::caPoolName()} for help formatting this field. + * @param \Google\Cloud\Security\PrivateCA\V1\Certificate $certificate Required. A [Certificate][google.cloud.security.privateca.v1.Certificate] + * with initial field values. + * @param string $certificateId Optional. It must be unique within a location and match the regular + * expression `[a-zA-Z0-9_-]{1,63}`. This field is required when using a + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the Enterprise + * [CertificateAuthority.tier][google.cloud.security.privateca.v1.CertificateAuthority.tier], + * but is optional and its value is ignored otherwise. + * + * @return \Google\Cloud\Security\PrivateCA\V1\CreateCertificateRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\Security\PrivateCA\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 resource name of the + * [CaPool][google.cloud.security.privateca.v1.CaPool] associated with the + * [Certificate][google.cloud.security.privateca.v1.Certificate], in the + * format `projects/{@*}locations/{@*}caPools/*`. + * @type string $certificate_id + * Optional. It must be unique within a location and match the regular + * expression `[a-zA-Z0-9_-]{1,63}`. This field is required when using a + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the Enterprise + * [CertificateAuthority.tier][google.cloud.security.privateca.v1.CertificateAuthority.tier], + * but is optional and its value is ignored otherwise. + * @type \Google\Cloud\Security\PrivateCA\V1\Certificate $certificate + * Required. A [Certificate][google.cloud.security.privateca.v1.Certificate] + * with initial field values. + * @type string $request_id + * Optional. An 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 bool $validate_only + * Optional. If this is true, no + * [Certificate][google.cloud.security.privateca.v1.Certificate] resource will + * be persisted regardless of the + * [CaPool][google.cloud.security.privateca.v1.CaPool]'s + * [tier][google.cloud.security.privateca.v1.CaPool.tier], and the returned + * [Certificate][google.cloud.security.privateca.v1.Certificate] will not + * contain the + * [pem_certificate][google.cloud.security.privateca.v1.Certificate.pem_certificate] + * field. + * @type string $issuing_certificate_authority_id + * Optional. The resource ID of the + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * that should issue the certificate. This optional field will ignore the + * load-balancing scheme of the Pool and directly issue the certificate from + * the CA with the specified ID, contained in the same + * [CaPool][google.cloud.security.privateca.v1.CaPool] referenced by `parent`. + * Per-CA quota rules apply. If left empty, a + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * will be chosen from the [CaPool][google.cloud.security.privateca.v1.CaPool] + * by the service. For example, to issue a + * [Certificate][google.cloud.security.privateca.v1.Certificate] from a + * Certificate Authority with resource name + * "projects/my-project/locations/us-central1/caPools/my-pool/certificateAuthorities/my-ca", + * you can set the + * [parent][google.cloud.security.privateca.v1.CreateCertificateRequest.parent] + * to "projects/my-project/locations/us-central1/caPools/my-pool" and the + * [issuing_certificate_authority_id][google.cloud.security.privateca.v1.CreateCertificateRequest.issuing_certificate_authority_id] + * to "my-ca". + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the + * [CaPool][google.cloud.security.privateca.v1.CaPool] associated with the + * [Certificate][google.cloud.security.privateca.v1.Certificate], in the + * format `projects/{@*}locations/{@*}caPools/*`. + * + * 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 + * [CaPool][google.cloud.security.privateca.v1.CaPool] associated with the + * [Certificate][google.cloud.security.privateca.v1.Certificate], in the + * format `projects/{@*}locations/{@*}caPools/*`. + * + * 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. It must be unique within a location and match the regular + * expression `[a-zA-Z0-9_-]{1,63}`. This field is required when using a + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the Enterprise + * [CertificateAuthority.tier][google.cloud.security.privateca.v1.CertificateAuthority.tier], + * but is optional and its value is ignored otherwise. + * + * Generated from protobuf field string certificate_id = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getCertificateId() + { + return $this->certificate_id; + } + + /** + * Optional. It must be unique within a location and match the regular + * expression `[a-zA-Z0-9_-]{1,63}`. This field is required when using a + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the Enterprise + * [CertificateAuthority.tier][google.cloud.security.privateca.v1.CertificateAuthority.tier], + * but is optional and its value is ignored otherwise. + * + * Generated from protobuf field string certificate_id = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @param string $var + * @return $this + */ + public function setCertificateId($var) + { + GPBUtil::checkString($var, True); + $this->certificate_id = $var; + + return $this; + } + + /** + * Required. A [Certificate][google.cloud.security.privateca.v1.Certificate] + * with initial field values. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.Certificate certificate = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Security\PrivateCA\V1\Certificate|null + */ + public function getCertificate() + { + return $this->certificate; + } + + public function hasCertificate() + { + return isset($this->certificate); + } + + public function clearCertificate() + { + unset($this->certificate); + } + + /** + * Required. A [Certificate][google.cloud.security.privateca.v1.Certificate] + * with initial field values. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.Certificate certificate = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Security\PrivateCA\V1\Certificate $var + * @return $this + */ + public function setCertificate($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\Certificate::class); + $this->certificate = $var; + + return $this; + } + + /** + * Optional. An 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 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; + } + + /** + * Optional. If this is true, no + * [Certificate][google.cloud.security.privateca.v1.Certificate] resource will + * be persisted regardless of the + * [CaPool][google.cloud.security.privateca.v1.CaPool]'s + * [tier][google.cloud.security.privateca.v1.CaPool.tier], and the returned + * [Certificate][google.cloud.security.privateca.v1.Certificate] will not + * contain the + * [pem_certificate][google.cloud.security.privateca.v1.Certificate.pem_certificate] + * field. + * + * Generated from protobuf field bool validate_only = 5 [(.google.api.field_behavior) = OPTIONAL]; + * @return bool + */ + public function getValidateOnly() + { + return $this->validate_only; + } + + /** + * Optional. If this is true, no + * [Certificate][google.cloud.security.privateca.v1.Certificate] resource will + * be persisted regardless of the + * [CaPool][google.cloud.security.privateca.v1.CaPool]'s + * [tier][google.cloud.security.privateca.v1.CaPool.tier], and the returned + * [Certificate][google.cloud.security.privateca.v1.Certificate] will not + * contain the + * [pem_certificate][google.cloud.security.privateca.v1.Certificate.pem_certificate] + * field. + * + * 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; + } + + /** + * Optional. The resource ID of the + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * that should issue the certificate. This optional field will ignore the + * load-balancing scheme of the Pool and directly issue the certificate from + * the CA with the specified ID, contained in the same + * [CaPool][google.cloud.security.privateca.v1.CaPool] referenced by `parent`. + * Per-CA quota rules apply. If left empty, a + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * will be chosen from the [CaPool][google.cloud.security.privateca.v1.CaPool] + * by the service. For example, to issue a + * [Certificate][google.cloud.security.privateca.v1.Certificate] from a + * Certificate Authority with resource name + * "projects/my-project/locations/us-central1/caPools/my-pool/certificateAuthorities/my-ca", + * you can set the + * [parent][google.cloud.security.privateca.v1.CreateCertificateRequest.parent] + * to "projects/my-project/locations/us-central1/caPools/my-pool" and the + * [issuing_certificate_authority_id][google.cloud.security.privateca.v1.CreateCertificateRequest.issuing_certificate_authority_id] + * to "my-ca". + * + * Generated from protobuf field string issuing_certificate_authority_id = 6 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getIssuingCertificateAuthorityId() + { + return $this->issuing_certificate_authority_id; + } + + /** + * Optional. The resource ID of the + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * that should issue the certificate. This optional field will ignore the + * load-balancing scheme of the Pool and directly issue the certificate from + * the CA with the specified ID, contained in the same + * [CaPool][google.cloud.security.privateca.v1.CaPool] referenced by `parent`. + * Per-CA quota rules apply. If left empty, a + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * will be chosen from the [CaPool][google.cloud.security.privateca.v1.CaPool] + * by the service. For example, to issue a + * [Certificate][google.cloud.security.privateca.v1.Certificate] from a + * Certificate Authority with resource name + * "projects/my-project/locations/us-central1/caPools/my-pool/certificateAuthorities/my-ca", + * you can set the + * [parent][google.cloud.security.privateca.v1.CreateCertificateRequest.parent] + * to "projects/my-project/locations/us-central1/caPools/my-pool" and the + * [issuing_certificate_authority_id][google.cloud.security.privateca.v1.CreateCertificateRequest.issuing_certificate_authority_id] + * to "my-ca". + * + * Generated from protobuf field string issuing_certificate_authority_id = 6 [(.google.api.field_behavior) = OPTIONAL]; + * @param string $var + * @return $this + */ + public function setIssuingCertificateAuthorityId($var) + { + GPBUtil::checkString($var, True); + $this->issuing_certificate_authority_id = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CreateCertificateTemplateRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CreateCertificateTemplateRequest.php new file mode 100644 index 000000000000..dec2eba9c145 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CreateCertificateTemplateRequest.php @@ -0,0 +1,263 @@ +google.cloud.security.privateca.v1.CreateCertificateTemplateRequest + */ +class CreateCertificateTemplateRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the location associated with the + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate], + * in the format `projects/{@*}locations/*`. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. It must be unique within a location and match the regular + * expression `[a-zA-Z0-9_-]{1,63}` + * + * Generated from protobuf field string certificate_template_id = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $certificate_template_id = ''; + /** + * Required. A + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * with initial field values. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateTemplate certificate_template = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $certificate_template = null; + /** + * Optional. An 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, (.google.api.field_info) = { + */ + protected $request_id = ''; + + /** + * @param string $parent Required. The resource name of the location associated with the + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate], + * in the format `projects/*/locations/*`. Please see + * {@see CertificateAuthorityServiceClient::locationName()} for help formatting this field. + * @param \Google\Cloud\Security\PrivateCA\V1\CertificateTemplate $certificateTemplate Required. A + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * with initial field values. + * @param string $certificateTemplateId Required. It must be unique within a location and match the regular + * expression `[a-zA-Z0-9_-]{1,63}` + * + * @return \Google\Cloud\Security\PrivateCA\V1\CreateCertificateTemplateRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\Security\PrivateCA\V1\CertificateTemplate $certificateTemplate, string $certificateTemplateId): self + { + return (new self()) + ->setParent($parent) + ->setCertificateTemplate($certificateTemplate) + ->setCertificateTemplateId($certificateTemplateId); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. The resource name of the location associated with the + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate], + * in the format `projects/{@*}locations/*`. + * @type string $certificate_template_id + * Required. It must be unique within a location and match the regular + * expression `[a-zA-Z0-9_-]{1,63}` + * @type \Google\Cloud\Security\PrivateCA\V1\CertificateTemplate $certificate_template + * Required. A + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * with initial field values. + * @type string $request_id + * Optional. An 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\Security\Privateca\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the location associated with the + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate], + * 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 associated with the + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate], + * 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. It must be unique within a location and match the regular + * expression `[a-zA-Z0-9_-]{1,63}` + * + * Generated from protobuf field string certificate_template_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getCertificateTemplateId() + { + return $this->certificate_template_id; + } + + /** + * Required. It must be unique within a location and match the regular + * expression `[a-zA-Z0-9_-]{1,63}` + * + * Generated from protobuf field string certificate_template_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setCertificateTemplateId($var) + { + GPBUtil::checkString($var, True); + $this->certificate_template_id = $var; + + return $this; + } + + /** + * Required. A + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * with initial field values. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateTemplate certificate_template = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Security\PrivateCA\V1\CertificateTemplate|null + */ + public function getCertificateTemplate() + { + return $this->certificate_template; + } + + public function hasCertificateTemplate() + { + return isset($this->certificate_template); + } + + public function clearCertificateTemplate() + { + unset($this->certificate_template); + } + + /** + * Required. A + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * with initial field values. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateTemplate certificate_template = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Security\PrivateCA\V1\CertificateTemplate $var + * @return $this + */ + public function setCertificateTemplate($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CertificateTemplate::class); + $this->certificate_template = $var; + + return $this; + } + + /** + * Optional. An 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, (.google.api.field_info) = { + * @return string + */ + public function getRequestId() + { + return $this->request_id; + } + + /** + * Optional. An 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, (.google.api.field_info) = { + * @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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/DeleteCaPoolRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/DeleteCaPoolRequest.php new file mode 100644 index 000000000000..d8c6a5c64212 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/DeleteCaPoolRequest.php @@ -0,0 +1,212 @@ +google.cloud.security.privateca.v1.DeleteCaPoolRequest + */ +class DeleteCaPoolRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name for this + * [CaPool][google.cloud.security.privateca.v1.CaPool] in the format + * `projects/{@*}locations/{@*}caPools/*`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * Optional. An 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { + */ + protected $request_id = ''; + /** + * Optional. This field allows this pool to be deleted even if it's being + * depended on by another resource. However, doing so may result in unintended + * and unrecoverable effects on any dependent resources since the pool will + * no longer be able to issue certificates. + * + * Generated from protobuf field bool ignore_dependent_resources = 4 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $ignore_dependent_resources = false; + + /** + * @param string $name Required. The resource name for this + * [CaPool][google.cloud.security.privateca.v1.CaPool] in the format + * `projects/*/locations/*/caPools/*`. Please see + * {@see CertificateAuthorityServiceClient::caPoolName()} for help formatting this field. + * + * @return \Google\Cloud\Security\PrivateCA\V1\DeleteCaPoolRequest + * + * @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 for this + * [CaPool][google.cloud.security.privateca.v1.CaPool] in the format + * `projects/{@*}locations/{@*}caPools/*`. + * @type string $request_id + * Optional. An 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 bool $ignore_dependent_resources + * Optional. This field allows this pool to be deleted even if it's being + * depended on by another resource. However, doing so may result in unintended + * and unrecoverable effects on any dependent resources since the pool will + * no longer be able to issue certificates. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name for this + * [CaPool][google.cloud.security.privateca.v1.CaPool] in the format + * `projects/{@*}locations/{@*}caPools/*`. + * + * 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 for this + * [CaPool][google.cloud.security.privateca.v1.CaPool] in the format + * `projects/{@*}locations/{@*}caPools/*`. + * + * 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 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { + * @return string + */ + public function getRequestId() + { + return $this->request_id; + } + + /** + * Optional. An 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { + * @param string $var + * @return $this + */ + public function setRequestId($var) + { + GPBUtil::checkString($var, True); + $this->request_id = $var; + + return $this; + } + + /** + * Optional. This field allows this pool to be deleted even if it's being + * depended on by another resource. However, doing so may result in unintended + * and unrecoverable effects on any dependent resources since the pool will + * no longer be able to issue certificates. + * + * Generated from protobuf field bool ignore_dependent_resources = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @return bool + */ + public function getIgnoreDependentResources() + { + return $this->ignore_dependent_resources; + } + + /** + * Optional. This field allows this pool to be deleted even if it's being + * depended on by another resource. However, doing so may result in unintended + * and unrecoverable effects on any dependent resources since the pool will + * no longer be able to issue certificates. + * + * Generated from protobuf field bool ignore_dependent_resources = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @param bool $var + * @return $this + */ + public function setIgnoreDependentResources($var) + { + GPBUtil::checkBool($var); + $this->ignore_dependent_resources = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/DeleteCertificateAuthorityRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/DeleteCertificateAuthorityRequest.php new file mode 100644 index 000000000000..70b330903526 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/DeleteCertificateAuthorityRequest.php @@ -0,0 +1,292 @@ +google.cloud.security.privateca.v1.DeleteCertificateAuthorityRequest + */ +class DeleteCertificateAuthorityRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name for this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * Optional. An 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { + */ + protected $request_id = ''; + /** + * Optional. This field allows the CA to be deleted even if the CA has + * active certs. Active certs include both unrevoked and unexpired certs. + * + * Generated from protobuf field bool ignore_active_certificates = 4 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $ignore_active_certificates = false; + /** + * Optional. If this flag is set, the Certificate Authority will be deleted as + * soon as possible without a 30-day grace period where undeletion would have + * been allowed. If you proceed, there will be no way to recover this CA. + * + * Generated from protobuf field bool skip_grace_period = 5 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $skip_grace_period = false; + /** + * Optional. This field allows this CA to be deleted even if it's being + * depended on by another resource. However, doing so may result in unintended + * and unrecoverable effects on any dependent resources since the CA will + * no longer be able to issue certificates. + * + * Generated from protobuf field bool ignore_dependent_resources = 6 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $ignore_dependent_resources = false; + + /** + * @param string $name Required. The resource name for this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the format `projects/*/locations/*/caPools/*/certificateAuthorities/*`. Please see + * {@see CertificateAuthorityServiceClient::certificateAuthorityName()} for help formatting this field. + * + * @return \Google\Cloud\Security\PrivateCA\V1\DeleteCertificateAuthorityRequest + * + * @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 for this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. + * @type string $request_id + * Optional. An 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 bool $ignore_active_certificates + * Optional. This field allows the CA to be deleted even if the CA has + * active certs. Active certs include both unrevoked and unexpired certs. + * @type bool $skip_grace_period + * Optional. If this flag is set, the Certificate Authority will be deleted as + * soon as possible without a 30-day grace period where undeletion would have + * been allowed. If you proceed, there will be no way to recover this CA. + * @type bool $ignore_dependent_resources + * Optional. This field allows this CA to be deleted even if it's being + * depended on by another resource. However, doing so may result in unintended + * and unrecoverable effects on any dependent resources since the CA will + * no longer be able to issue certificates. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name for this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. + * + * 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 for this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. + * + * 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 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { + * @return string + */ + public function getRequestId() + { + return $this->request_id; + } + + /** + * Optional. An 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { + * @param string $var + * @return $this + */ + public function setRequestId($var) + { + GPBUtil::checkString($var, True); + $this->request_id = $var; + + return $this; + } + + /** + * Optional. This field allows the CA to be deleted even if the CA has + * active certs. Active certs include both unrevoked and unexpired certs. + * + * Generated from protobuf field bool ignore_active_certificates = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @return bool + */ + public function getIgnoreActiveCertificates() + { + return $this->ignore_active_certificates; + } + + /** + * Optional. This field allows the CA to be deleted even if the CA has + * active certs. Active certs include both unrevoked and unexpired certs. + * + * Generated from protobuf field bool ignore_active_certificates = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @param bool $var + * @return $this + */ + public function setIgnoreActiveCertificates($var) + { + GPBUtil::checkBool($var); + $this->ignore_active_certificates = $var; + + return $this; + } + + /** + * Optional. If this flag is set, the Certificate Authority will be deleted as + * soon as possible without a 30-day grace period where undeletion would have + * been allowed. If you proceed, there will be no way to recover this CA. + * + * Generated from protobuf field bool skip_grace_period = 5 [(.google.api.field_behavior) = OPTIONAL]; + * @return bool + */ + public function getSkipGracePeriod() + { + return $this->skip_grace_period; + } + + /** + * Optional. If this flag is set, the Certificate Authority will be deleted as + * soon as possible without a 30-day grace period where undeletion would have + * been allowed. If you proceed, there will be no way to recover this CA. + * + * Generated from protobuf field bool skip_grace_period = 5 [(.google.api.field_behavior) = OPTIONAL]; + * @param bool $var + * @return $this + */ + public function setSkipGracePeriod($var) + { + GPBUtil::checkBool($var); + $this->skip_grace_period = $var; + + return $this; + } + + /** + * Optional. This field allows this CA to be deleted even if it's being + * depended on by another resource. However, doing so may result in unintended + * and unrecoverable effects on any dependent resources since the CA will + * no longer be able to issue certificates. + * + * Generated from protobuf field bool ignore_dependent_resources = 6 [(.google.api.field_behavior) = OPTIONAL]; + * @return bool + */ + public function getIgnoreDependentResources() + { + return $this->ignore_dependent_resources; + } + + /** + * Optional. This field allows this CA to be deleted even if it's being + * depended on by another resource. However, doing so may result in unintended + * and unrecoverable effects on any dependent resources since the CA will + * no longer be able to issue certificates. + * + * Generated from protobuf field bool ignore_dependent_resources = 6 [(.google.api.field_behavior) = OPTIONAL]; + * @param bool $var + * @return $this + */ + public function setIgnoreDependentResources($var) + { + GPBUtil::checkBool($var); + $this->ignore_dependent_resources = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/DeleteCertificateTemplateRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/DeleteCertificateTemplateRequest.php new file mode 100644 index 000000000000..a4a8c12ce4fe --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/DeleteCertificateTemplateRequest.php @@ -0,0 +1,166 @@ +google.cloud.security.privateca.v1.DeleteCertificateTemplateRequest + */ +class DeleteCertificateTemplateRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name for this + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * in the format `projects/{@*}locations/{@*}certificateTemplates/*`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * Optional. An 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { + */ + protected $request_id = ''; + + /** + * @param string $name Required. The resource name for this + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * in the format `projects/*/locations/*/certificateTemplates/*`. Please see + * {@see CertificateAuthorityServiceClient::certificateTemplateName()} for help formatting this field. + * + * @return \Google\Cloud\Security\PrivateCA\V1\DeleteCertificateTemplateRequest + * + * @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 for this + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * in the format `projects/{@*}locations/{@*}certificateTemplates/*`. + * @type string $request_id + * Optional. An 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\Security\Privateca\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name for this + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * in the format `projects/{@*}locations/{@*}certificateTemplates/*`. + * + * 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 for this + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * in the format `projects/{@*}locations/{@*}certificateTemplates/*`. + * + * 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 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { + * @return string + */ + public function getRequestId() + { + return $this->request_id; + } + + /** + * Optional. An 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { + * @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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/DisableCertificateAuthorityRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/DisableCertificateAuthorityRequest.php new file mode 100644 index 000000000000..68b4546f5bf0 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/DisableCertificateAuthorityRequest.php @@ -0,0 +1,212 @@ +google.cloud.security.privateca.v1.DisableCertificateAuthorityRequest + */ +class DisableCertificateAuthorityRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name for this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * Optional. An 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { + */ + protected $request_id = ''; + /** + * Optional. This field allows this CA to be disabled even if it's being + * depended on by another resource. However, doing so may result in unintended + * and unrecoverable effects on any dependent resources since the CA will + * no longer be able to issue certificates. + * + * Generated from protobuf field bool ignore_dependent_resources = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $ignore_dependent_resources = false; + + /** + * @param string $name Required. The resource name for this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the format `projects/*/locations/*/caPools/*/certificateAuthorities/*`. Please see + * {@see CertificateAuthorityServiceClient::certificateAuthorityName()} for help formatting this field. + * + * @return \Google\Cloud\Security\PrivateCA\V1\DisableCertificateAuthorityRequest + * + * @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 for this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. + * @type string $request_id + * Optional. An 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 bool $ignore_dependent_resources + * Optional. This field allows this CA to be disabled even if it's being + * depended on by another resource. However, doing so may result in unintended + * and unrecoverable effects on any dependent resources since the CA will + * no longer be able to issue certificates. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name for this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. + * + * 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 for this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. + * + * 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 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { + * @return string + */ + public function getRequestId() + { + return $this->request_id; + } + + /** + * Optional. An 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { + * @param string $var + * @return $this + */ + public function setRequestId($var) + { + GPBUtil::checkString($var, True); + $this->request_id = $var; + + return $this; + } + + /** + * Optional. This field allows this CA to be disabled even if it's being + * depended on by another resource. However, doing so may result in unintended + * and unrecoverable effects on any dependent resources since the CA will + * no longer be able to issue certificates. + * + * Generated from protobuf field bool ignore_dependent_resources = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return bool + */ + public function getIgnoreDependentResources() + { + return $this->ignore_dependent_resources; + } + + /** + * Optional. This field allows this CA to be disabled even if it's being + * depended on by another resource. However, doing so may result in unintended + * and unrecoverable effects on any dependent resources since the CA will + * no longer be able to issue certificates. + * + * Generated from protobuf field bool ignore_dependent_resources = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @param bool $var + * @return $this + */ + public function setIgnoreDependentResources($var) + { + GPBUtil::checkBool($var); + $this->ignore_dependent_resources = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/EnableCertificateAuthorityRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/EnableCertificateAuthorityRequest.php new file mode 100644 index 000000000000..6483e3e49371 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/EnableCertificateAuthorityRequest.php @@ -0,0 +1,166 @@ +google.cloud.security.privateca.v1.EnableCertificateAuthorityRequest + */ +class EnableCertificateAuthorityRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name for this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * Optional. An 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { + */ + protected $request_id = ''; + + /** + * @param string $name Required. The resource name for this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the format `projects/*/locations/*/caPools/*/certificateAuthorities/*`. Please see + * {@see CertificateAuthorityServiceClient::certificateAuthorityName()} for help formatting this field. + * + * @return \Google\Cloud\Security\PrivateCA\V1\EnableCertificateAuthorityRequest + * + * @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 for this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. + * @type string $request_id + * Optional. An 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\Security\Privateca\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name for this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. + * + * 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 for this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. + * + * 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 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { + * @return string + */ + public function getRequestId() + { + return $this->request_id; + } + + /** + * Optional. An 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { + * @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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/EncryptionSpec.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/EncryptionSpec.php new file mode 100644 index 000000000000..329f51897689 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/EncryptionSpec.php @@ -0,0 +1,71 @@ +google.cloud.security.privateca.v1.EncryptionSpec + */ +class EncryptionSpec extends \Google\Protobuf\Internal\Message +{ + /** + * The resource name for a Cloud KMS key in the format + * `projects/{@*}locations/{@*}keyRings/{@*}cryptoKeys/*`. + * + * Generated from protobuf field string cloud_kms_key = 1; + */ + protected $cloud_kms_key = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $cloud_kms_key + * The resource name for a Cloud KMS key in the format + * `projects/{@*}locations/{@*}keyRings/{@*}cryptoKeys/*`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * The resource name for a Cloud KMS key in the format + * `projects/{@*}locations/{@*}keyRings/{@*}cryptoKeys/*`. + * + * Generated from protobuf field string cloud_kms_key = 1; + * @return string + */ + public function getCloudKmsKey() + { + return $this->cloud_kms_key; + } + + /** + * The resource name for a Cloud KMS key in the format + * `projects/{@*}locations/{@*}keyRings/{@*}cryptoKeys/*`. + * + * Generated from protobuf field string cloud_kms_key = 1; + * @param string $var + * @return $this + */ + public function setCloudKmsKey($var) + { + GPBUtil::checkString($var, True); + $this->cloud_kms_key = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/FetchCaCertsRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/FetchCaCertsRequest.php new file mode 100644 index 000000000000..73a59a0ec28e --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/FetchCaCertsRequest.php @@ -0,0 +1,166 @@ +google.cloud.security.privateca.v1.FetchCaCertsRequest + */ +class FetchCaCertsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name for the + * [CaPool][google.cloud.security.privateca.v1.CaPool] in the format + * `projects/{@*}locations/{@*}caPools/*`. + * + * Generated from protobuf field string ca_pool = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $ca_pool = ''; + /** + * Optional. An 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 = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $request_id = ''; + + /** + * @param string $caPool Required. The resource name for the + * [CaPool][google.cloud.security.privateca.v1.CaPool] in the format + * `projects/*/locations/*/caPools/*`. Please see + * {@see CertificateAuthorityServiceClient::caPoolName()} for help formatting this field. + * + * @return \Google\Cloud\Security\PrivateCA\V1\FetchCaCertsRequest + * + * @experimental + */ + public static function build(string $caPool): self + { + return (new self()) + ->setCaPool($caPool); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $ca_pool + * Required. The resource name for the + * [CaPool][google.cloud.security.privateca.v1.CaPool] in the format + * `projects/{@*}locations/{@*}caPools/*`. + * @type string $request_id + * Optional. An 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\Security\Privateca\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name for the + * [CaPool][google.cloud.security.privateca.v1.CaPool] in the format + * `projects/{@*}locations/{@*}caPools/*`. + * + * 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. The resource name for the + * [CaPool][google.cloud.security.privateca.v1.CaPool] in the format + * `projects/{@*}locations/{@*}caPools/*`. + * + * 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; + } + + /** + * Optional. An 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 = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getRequestId() + { + return $this->request_id; + } + + /** + * Optional. An 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 = 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; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/FetchCaCertsResponse.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/FetchCaCertsResponse.php new file mode 100644 index 000000000000..58e56752f6d8 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/FetchCaCertsResponse.php @@ -0,0 +1,76 @@ +google.cloud.security.privateca.v1.FetchCaCertsResponse + */ +class FetchCaCertsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * The PEM encoded CA certificate chains of all certificate authorities in + * this [CaPool][google.cloud.security.privateca.v1.CaPool] in the ENABLED, + * DISABLED, or STAGED states. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.FetchCaCertsResponse.CertChain ca_certs = 1; + */ + private $ca_certs; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Security\PrivateCA\V1\FetchCaCertsResponse\CertChain[] $ca_certs + * The PEM encoded CA certificate chains of all certificate authorities in + * this [CaPool][google.cloud.security.privateca.v1.CaPool] in the ENABLED, + * DISABLED, or STAGED states. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * The PEM encoded CA certificate chains of all certificate authorities in + * this [CaPool][google.cloud.security.privateca.v1.CaPool] in the ENABLED, + * DISABLED, or STAGED states. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.FetchCaCertsResponse.CertChain ca_certs = 1; + * @return RepeatedField<\Google\Cloud\Security\PrivateCA\V1\FetchCaCertsResponse\CertChain> + */ + public function getCaCerts() + { + return $this->ca_certs; + } + + /** + * The PEM encoded CA certificate chains of all certificate authorities in + * this [CaPool][google.cloud.security.privateca.v1.CaPool] in the ENABLED, + * DISABLED, or STAGED states. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.FetchCaCertsResponse.CertChain ca_certs = 1; + * @param \Google\Cloud\Security\PrivateCA\V1\FetchCaCertsResponse\CertChain[] $var + * @return $this + */ + public function setCaCerts($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Security\PrivateCA\V1\FetchCaCertsResponse\CertChain::class); + $this->ca_certs = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/FetchCaCertsResponse/CertChain.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/FetchCaCertsResponse/CertChain.php new file mode 100644 index 000000000000..7575387f2789 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/FetchCaCertsResponse/CertChain.php @@ -0,0 +1,65 @@ +google.cloud.security.privateca.v1.FetchCaCertsResponse.CertChain + */ +class CertChain extends \Google\Protobuf\Internal\Message +{ + /** + * The certificates that form the CA chain, from leaf to root order. + * + * Generated from protobuf field repeated string certificates = 1; + */ + private $certificates; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string[] $certificates + * The certificates that form the CA chain, from leaf to root order. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * The certificates that form the CA chain, from leaf to root order. + * + * Generated from protobuf field repeated string certificates = 1; + * @return RepeatedField + */ + public function getCertificates() + { + return $this->certificates; + } + + /** + * The certificates that form the CA chain, from leaf to root order. + * + * Generated from protobuf field repeated string certificates = 1; + * @param string[] $var + * @return $this + */ + public function setCertificates($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->certificates = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/FetchCertificateAuthorityCsrRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/FetchCertificateAuthorityCsrRequest.php new file mode 100644 index 000000000000..c682733e7e1a --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/FetchCertificateAuthorityCsrRequest.php @@ -0,0 +1,92 @@ +google.cloud.security.privateca.v1.FetchCertificateAuthorityCsrRequest + */ +class FetchCertificateAuthorityCsrRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name for this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. + * + * 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 for this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the format `projects/*/locations/*/caPools/*/certificateAuthorities/*`. Please see + * {@see CertificateAuthorityServiceClient::certificateAuthorityName()} for help formatting this field. + * + * @return \Google\Cloud\Security\PrivateCA\V1\FetchCertificateAuthorityCsrRequest + * + * @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 for this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name for this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. + * + * 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 for this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. + * + * 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/FetchCertificateAuthorityCsrResponse.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/FetchCertificateAuthorityCsrResponse.php new file mode 100644 index 000000000000..cb7266b7a61e --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/FetchCertificateAuthorityCsrResponse.php @@ -0,0 +1,68 @@ +google.cloud.security.privateca.v1.FetchCertificateAuthorityCsrResponse + */ +class FetchCertificateAuthorityCsrResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. The PEM-encoded signed certificate signing request (CSR). + * + * Generated from protobuf field string pem_csr = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $pem_csr = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $pem_csr + * Output only. The PEM-encoded signed certificate signing request (CSR). + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Output only. The PEM-encoded signed certificate signing request (CSR). + * + * Generated from protobuf field string pem_csr = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getPemCsr() + { + return $this->pem_csr; + } + + /** + * Output only. The PEM-encoded signed certificate signing request (CSR). + * + * Generated from protobuf field string pem_csr = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setPemCsr($var) + { + GPBUtil::checkString($var, True); + $this->pem_csr = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/GetCaPoolRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/GetCaPoolRequest.php new file mode 100644 index 000000000000..97ee1d29b11b --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/GetCaPoolRequest.php @@ -0,0 +1,87 @@ +google.cloud.security.privateca.v1.GetCaPoolRequest + */ +class GetCaPoolRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The [name][google.cloud.security.privateca.v1.CaPool.name] of the + * [CaPool][google.cloud.security.privateca.v1.CaPool] 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][google.cloud.security.privateca.v1.CaPool.name] of the + * [CaPool][google.cloud.security.privateca.v1.CaPool] to get. Please see + * {@see CertificateAuthorityServiceClient::caPoolName()} for help formatting this field. + * + * @return \Google\Cloud\Security\PrivateCA\V1\GetCaPoolRequest + * + * @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][google.cloud.security.privateca.v1.CaPool.name] of the + * [CaPool][google.cloud.security.privateca.v1.CaPool] to get. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Required. The [name][google.cloud.security.privateca.v1.CaPool.name] of the + * [CaPool][google.cloud.security.privateca.v1.CaPool] 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][google.cloud.security.privateca.v1.CaPool.name] of the + * [CaPool][google.cloud.security.privateca.v1.CaPool] 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/GetCertificateAuthorityRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/GetCertificateAuthorityRequest.php new file mode 100644 index 000000000000..29ab94d196c6 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/GetCertificateAuthorityRequest.php @@ -0,0 +1,97 @@ +google.cloud.security.privateca.v1.GetCertificateAuthorityRequest + */ +class GetCertificateAuthorityRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The + * [name][google.cloud.security.privateca.v1.CertificateAuthority.name] of the + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * 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][google.cloud.security.privateca.v1.CertificateAuthority.name] of the + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * to get. Please see + * {@see CertificateAuthorityServiceClient::certificateAuthorityName()} for help formatting this field. + * + * @return \Google\Cloud\Security\PrivateCA\V1\GetCertificateAuthorityRequest + * + * @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][google.cloud.security.privateca.v1.CertificateAuthority.name] of the + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * to get. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Required. The + * [name][google.cloud.security.privateca.v1.CertificateAuthority.name] of the + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * 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][google.cloud.security.privateca.v1.CertificateAuthority.name] of the + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/GetCertificateRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/GetCertificateRequest.php new file mode 100644 index 000000000000..bd0b841c530c --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/GetCertificateRequest.php @@ -0,0 +1,92 @@ +google.cloud.security.privateca.v1.GetCertificateRequest + */ +class GetCertificateRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The [name][google.cloud.security.privateca.v1.Certificate.name] + * of the [Certificate][google.cloud.security.privateca.v1.Certificate] 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][google.cloud.security.privateca.v1.Certificate.name] + * of the [Certificate][google.cloud.security.privateca.v1.Certificate] to + * get. Please see + * {@see CertificateAuthorityServiceClient::certificateName()} for help formatting this field. + * + * @return \Google\Cloud\Security\PrivateCA\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. The [name][google.cloud.security.privateca.v1.Certificate.name] + * of the [Certificate][google.cloud.security.privateca.v1.Certificate] to + * get. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Required. The [name][google.cloud.security.privateca.v1.Certificate.name] + * of the [Certificate][google.cloud.security.privateca.v1.Certificate] 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][google.cloud.security.privateca.v1.Certificate.name] + * of the [Certificate][google.cloud.security.privateca.v1.Certificate] 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/GetCertificateRevocationListRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/GetCertificateRevocationListRequest.php new file mode 100644 index 000000000000..2d6bcc851616 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/GetCertificateRevocationListRequest.php @@ -0,0 +1,102 @@ +google.cloud.security.privateca.v1.GetCertificateRevocationListRequest + */ +class GetCertificateRevocationListRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The + * [name][google.cloud.security.privateca.v1.CertificateRevocationList.name] + * of the + * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] + * 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][google.cloud.security.privateca.v1.CertificateRevocationList.name] + * of the + * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] + * to get. Please see + * {@see CertificateAuthorityServiceClient::certificateRevocationListName()} for help formatting this field. + * + * @return \Google\Cloud\Security\PrivateCA\V1\GetCertificateRevocationListRequest + * + * @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][google.cloud.security.privateca.v1.CertificateRevocationList.name] + * of the + * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] + * to get. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Required. The + * [name][google.cloud.security.privateca.v1.CertificateRevocationList.name] + * of the + * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] + * 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][google.cloud.security.privateca.v1.CertificateRevocationList.name] + * of the + * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] + * 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/GetCertificateTemplateRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/GetCertificateTemplateRequest.php new file mode 100644 index 000000000000..b4214aa905a4 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/GetCertificateTemplateRequest.php @@ -0,0 +1,97 @@ +google.cloud.security.privateca.v1.GetCertificateTemplateRequest + */ +class GetCertificateTemplateRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The + * [name][google.cloud.security.privateca.v1.CertificateTemplate.name] of the + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * 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][google.cloud.security.privateca.v1.CertificateTemplate.name] of the + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * to get. Please see + * {@see CertificateAuthorityServiceClient::certificateTemplateName()} for help formatting this field. + * + * @return \Google\Cloud\Security\PrivateCA\V1\GetCertificateTemplateRequest + * + * @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][google.cloud.security.privateca.v1.CertificateTemplate.name] of the + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * to get. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Required. The + * [name][google.cloud.security.privateca.v1.CertificateTemplate.name] of the + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * 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][google.cloud.security.privateca.v1.CertificateTemplate.name] of the + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/KeyUsage.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/KeyUsage.php new file mode 100644 index 000000000000..7f432229f3cc --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/KeyUsage.php @@ -0,0 +1,164 @@ +google.cloud.security.privateca.v1.KeyUsage + */ +class KeyUsage extends \Google\Protobuf\Internal\Message +{ + /** + * Describes high-level ways in which a key may be used. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.KeyUsage.KeyUsageOptions base_key_usage = 1; + */ + protected $base_key_usage = null; + /** + * Detailed scenarios in which a key may be used. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.KeyUsage.ExtendedKeyUsageOptions extended_key_usage = 2; + */ + protected $extended_key_usage = null; + /** + * Used to describe extended key usages that are not listed in the + * [KeyUsage.ExtendedKeyUsageOptions][google.cloud.security.privateca.v1.KeyUsage.ExtendedKeyUsageOptions] + * message. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.ObjectId unknown_extended_key_usages = 3; + */ + private $unknown_extended_key_usages; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Security\PrivateCA\V1\KeyUsage\KeyUsageOptions $base_key_usage + * Describes high-level ways in which a key may be used. + * @type \Google\Cloud\Security\PrivateCA\V1\KeyUsage\ExtendedKeyUsageOptions $extended_key_usage + * Detailed scenarios in which a key may be used. + * @type \Google\Cloud\Security\PrivateCA\V1\ObjectId[] $unknown_extended_key_usages + * Used to describe extended key usages that are not listed in the + * [KeyUsage.ExtendedKeyUsageOptions][google.cloud.security.privateca.v1.KeyUsage.ExtendedKeyUsageOptions] + * message. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * Describes high-level ways in which a key may be used. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.KeyUsage.KeyUsageOptions base_key_usage = 1; + * @return \Google\Cloud\Security\PrivateCA\V1\KeyUsage\KeyUsageOptions|null + */ + public function getBaseKeyUsage() + { + return $this->base_key_usage; + } + + public function hasBaseKeyUsage() + { + return isset($this->base_key_usage); + } + + public function clearBaseKeyUsage() + { + unset($this->base_key_usage); + } + + /** + * Describes high-level ways in which a key may be used. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.KeyUsage.KeyUsageOptions base_key_usage = 1; + * @param \Google\Cloud\Security\PrivateCA\V1\KeyUsage\KeyUsageOptions $var + * @return $this + */ + public function setBaseKeyUsage($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\KeyUsage\KeyUsageOptions::class); + $this->base_key_usage = $var; + + return $this; + } + + /** + * Detailed scenarios in which a key may be used. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.KeyUsage.ExtendedKeyUsageOptions extended_key_usage = 2; + * @return \Google\Cloud\Security\PrivateCA\V1\KeyUsage\ExtendedKeyUsageOptions|null + */ + public function getExtendedKeyUsage() + { + return $this->extended_key_usage; + } + + public function hasExtendedKeyUsage() + { + return isset($this->extended_key_usage); + } + + public function clearExtendedKeyUsage() + { + unset($this->extended_key_usage); + } + + /** + * Detailed scenarios in which a key may be used. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.KeyUsage.ExtendedKeyUsageOptions extended_key_usage = 2; + * @param \Google\Cloud\Security\PrivateCA\V1\KeyUsage\ExtendedKeyUsageOptions $var + * @return $this + */ + public function setExtendedKeyUsage($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\KeyUsage\ExtendedKeyUsageOptions::class); + $this->extended_key_usage = $var; + + return $this; + } + + /** + * Used to describe extended key usages that are not listed in the + * [KeyUsage.ExtendedKeyUsageOptions][google.cloud.security.privateca.v1.KeyUsage.ExtendedKeyUsageOptions] + * message. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.ObjectId unknown_extended_key_usages = 3; + * @return RepeatedField<\Google\Cloud\Security\PrivateCA\V1\ObjectId> + */ + public function getUnknownExtendedKeyUsages() + { + return $this->unknown_extended_key_usages; + } + + /** + * Used to describe extended key usages that are not listed in the + * [KeyUsage.ExtendedKeyUsageOptions][google.cloud.security.privateca.v1.KeyUsage.ExtendedKeyUsageOptions] + * message. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.ObjectId unknown_extended_key_usages = 3; + * @param \Google\Cloud\Security\PrivateCA\V1\ObjectId[] $var + * @return $this + */ + public function setUnknownExtendedKeyUsages($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Security\PrivateCA\V1\ObjectId::class); + $this->unknown_extended_key_usages = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/KeyUsage/ExtendedKeyUsageOptions.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/KeyUsage/ExtendedKeyUsageOptions.php new file mode 100644 index 000000000000..112b38358bac --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/KeyUsage/ExtendedKeyUsageOptions.php @@ -0,0 +1,263 @@ +google.cloud.security.privateca.v1.KeyUsage.ExtendedKeyUsageOptions + */ +class ExtendedKeyUsageOptions extends \Google\Protobuf\Internal\Message +{ + /** + * Corresponds to OID 1.3.6.1.5.5.7.3.1. Officially described as "TLS WWW + * server authentication", though regularly used for non-WWW TLS. + * + * Generated from protobuf field bool server_auth = 1; + */ + protected $server_auth = false; + /** + * Corresponds to OID 1.3.6.1.5.5.7.3.2. Officially described as "TLS WWW + * client authentication", though regularly used for non-WWW TLS. + * + * Generated from protobuf field bool client_auth = 2; + */ + protected $client_auth = false; + /** + * Corresponds to OID 1.3.6.1.5.5.7.3.3. Officially described as "Signing of + * downloadable executable code client authentication". + * + * Generated from protobuf field bool code_signing = 3; + */ + protected $code_signing = false; + /** + * Corresponds to OID 1.3.6.1.5.5.7.3.4. Officially described as "Email + * protection". + * + * Generated from protobuf field bool email_protection = 4; + */ + protected $email_protection = false; + /** + * Corresponds to OID 1.3.6.1.5.5.7.3.8. Officially described as "Binding + * the hash of an object to a time". + * + * Generated from protobuf field bool time_stamping = 5; + */ + protected $time_stamping = false; + /** + * Corresponds to OID 1.3.6.1.5.5.7.3.9. Officially described as "Signing + * OCSP responses". + * + * Generated from protobuf field bool ocsp_signing = 6; + */ + protected $ocsp_signing = false; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type bool $server_auth + * Corresponds to OID 1.3.6.1.5.5.7.3.1. Officially described as "TLS WWW + * server authentication", though regularly used for non-WWW TLS. + * @type bool $client_auth + * Corresponds to OID 1.3.6.1.5.5.7.3.2. Officially described as "TLS WWW + * client authentication", though regularly used for non-WWW TLS. + * @type bool $code_signing + * Corresponds to OID 1.3.6.1.5.5.7.3.3. Officially described as "Signing of + * downloadable executable code client authentication". + * @type bool $email_protection + * Corresponds to OID 1.3.6.1.5.5.7.3.4. Officially described as "Email + * protection". + * @type bool $time_stamping + * Corresponds to OID 1.3.6.1.5.5.7.3.8. Officially described as "Binding + * the hash of an object to a time". + * @type bool $ocsp_signing + * Corresponds to OID 1.3.6.1.5.5.7.3.9. Officially described as "Signing + * OCSP responses". + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * Corresponds to OID 1.3.6.1.5.5.7.3.1. Officially described as "TLS WWW + * server authentication", though regularly used for non-WWW TLS. + * + * Generated from protobuf field bool server_auth = 1; + * @return bool + */ + public function getServerAuth() + { + return $this->server_auth; + } + + /** + * Corresponds to OID 1.3.6.1.5.5.7.3.1. Officially described as "TLS WWW + * server authentication", though regularly used for non-WWW TLS. + * + * Generated from protobuf field bool server_auth = 1; + * @param bool $var + * @return $this + */ + public function setServerAuth($var) + { + GPBUtil::checkBool($var); + $this->server_auth = $var; + + return $this; + } + + /** + * Corresponds to OID 1.3.6.1.5.5.7.3.2. Officially described as "TLS WWW + * client authentication", though regularly used for non-WWW TLS. + * + * Generated from protobuf field bool client_auth = 2; + * @return bool + */ + public function getClientAuth() + { + return $this->client_auth; + } + + /** + * Corresponds to OID 1.3.6.1.5.5.7.3.2. Officially described as "TLS WWW + * client authentication", though regularly used for non-WWW TLS. + * + * Generated from protobuf field bool client_auth = 2; + * @param bool $var + * @return $this + */ + public function setClientAuth($var) + { + GPBUtil::checkBool($var); + $this->client_auth = $var; + + return $this; + } + + /** + * Corresponds to OID 1.3.6.1.5.5.7.3.3. Officially described as "Signing of + * downloadable executable code client authentication". + * + * Generated from protobuf field bool code_signing = 3; + * @return bool + */ + public function getCodeSigning() + { + return $this->code_signing; + } + + /** + * Corresponds to OID 1.3.6.1.5.5.7.3.3. Officially described as "Signing of + * downloadable executable code client authentication". + * + * Generated from protobuf field bool code_signing = 3; + * @param bool $var + * @return $this + */ + public function setCodeSigning($var) + { + GPBUtil::checkBool($var); + $this->code_signing = $var; + + return $this; + } + + /** + * Corresponds to OID 1.3.6.1.5.5.7.3.4. Officially described as "Email + * protection". + * + * Generated from protobuf field bool email_protection = 4; + * @return bool + */ + public function getEmailProtection() + { + return $this->email_protection; + } + + /** + * Corresponds to OID 1.3.6.1.5.5.7.3.4. Officially described as "Email + * protection". + * + * Generated from protobuf field bool email_protection = 4; + * @param bool $var + * @return $this + */ + public function setEmailProtection($var) + { + GPBUtil::checkBool($var); + $this->email_protection = $var; + + return $this; + } + + /** + * Corresponds to OID 1.3.6.1.5.5.7.3.8. Officially described as "Binding + * the hash of an object to a time". + * + * Generated from protobuf field bool time_stamping = 5; + * @return bool + */ + public function getTimeStamping() + { + return $this->time_stamping; + } + + /** + * Corresponds to OID 1.3.6.1.5.5.7.3.8. Officially described as "Binding + * the hash of an object to a time". + * + * Generated from protobuf field bool time_stamping = 5; + * @param bool $var + * @return $this + */ + public function setTimeStamping($var) + { + GPBUtil::checkBool($var); + $this->time_stamping = $var; + + return $this; + } + + /** + * Corresponds to OID 1.3.6.1.5.5.7.3.9. Officially described as "Signing + * OCSP responses". + * + * Generated from protobuf field bool ocsp_signing = 6; + * @return bool + */ + public function getOcspSigning() + { + return $this->ocsp_signing; + } + + /** + * Corresponds to OID 1.3.6.1.5.5.7.3.9. Officially described as "Signing + * OCSP responses". + * + * Generated from protobuf field bool ocsp_signing = 6; + * @param bool $var + * @return $this + */ + public function setOcspSigning($var) + { + GPBUtil::checkBool($var); + $this->ocsp_signing = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/KeyUsage/KeyUsageOptions.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/KeyUsage/KeyUsageOptions.php new file mode 100644 index 000000000000..200c9acf6ba0 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/KeyUsage/KeyUsageOptions.php @@ -0,0 +1,345 @@ +google.cloud.security.privateca.v1.KeyUsage.KeyUsageOptions + */ +class KeyUsageOptions extends \Google\Protobuf\Internal\Message +{ + /** + * The key may be used for digital signatures. + * + * Generated from protobuf field bool digital_signature = 1; + */ + protected $digital_signature = false; + /** + * The key may be used for cryptographic commitments. Note that this may + * also be referred to as "non-repudiation". + * + * Generated from protobuf field bool content_commitment = 2; + */ + protected $content_commitment = false; + /** + * The key may be used to encipher other keys. + * + * Generated from protobuf field bool key_encipherment = 3; + */ + protected $key_encipherment = false; + /** + * The key may be used to encipher data. + * + * Generated from protobuf field bool data_encipherment = 4; + */ + protected $data_encipherment = false; + /** + * The key may be used in a key agreement protocol. + * + * Generated from protobuf field bool key_agreement = 5; + */ + protected $key_agreement = false; + /** + * The key may be used to sign certificates. + * + * Generated from protobuf field bool cert_sign = 6; + */ + protected $cert_sign = false; + /** + * The key may be used sign certificate revocation lists. + * + * Generated from protobuf field bool crl_sign = 7; + */ + protected $crl_sign = false; + /** + * The key may be used to encipher only. + * + * Generated from protobuf field bool encipher_only = 8; + */ + protected $encipher_only = false; + /** + * The key may be used to decipher only. + * + * Generated from protobuf field bool decipher_only = 9; + */ + protected $decipher_only = false; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type bool $digital_signature + * The key may be used for digital signatures. + * @type bool $content_commitment + * The key may be used for cryptographic commitments. Note that this may + * also be referred to as "non-repudiation". + * @type bool $key_encipherment + * The key may be used to encipher other keys. + * @type bool $data_encipherment + * The key may be used to encipher data. + * @type bool $key_agreement + * The key may be used in a key agreement protocol. + * @type bool $cert_sign + * The key may be used to sign certificates. + * @type bool $crl_sign + * The key may be used sign certificate revocation lists. + * @type bool $encipher_only + * The key may be used to encipher only. + * @type bool $decipher_only + * The key may be used to decipher only. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * The key may be used for digital signatures. + * + * Generated from protobuf field bool digital_signature = 1; + * @return bool + */ + public function getDigitalSignature() + { + return $this->digital_signature; + } + + /** + * The key may be used for digital signatures. + * + * Generated from protobuf field bool digital_signature = 1; + * @param bool $var + * @return $this + */ + public function setDigitalSignature($var) + { + GPBUtil::checkBool($var); + $this->digital_signature = $var; + + return $this; + } + + /** + * The key may be used for cryptographic commitments. Note that this may + * also be referred to as "non-repudiation". + * + * Generated from protobuf field bool content_commitment = 2; + * @return bool + */ + public function getContentCommitment() + { + return $this->content_commitment; + } + + /** + * The key may be used for cryptographic commitments. Note that this may + * also be referred to as "non-repudiation". + * + * Generated from protobuf field bool content_commitment = 2; + * @param bool $var + * @return $this + */ + public function setContentCommitment($var) + { + GPBUtil::checkBool($var); + $this->content_commitment = $var; + + return $this; + } + + /** + * The key may be used to encipher other keys. + * + * Generated from protobuf field bool key_encipherment = 3; + * @return bool + */ + public function getKeyEncipherment() + { + return $this->key_encipherment; + } + + /** + * The key may be used to encipher other keys. + * + * Generated from protobuf field bool key_encipherment = 3; + * @param bool $var + * @return $this + */ + public function setKeyEncipherment($var) + { + GPBUtil::checkBool($var); + $this->key_encipherment = $var; + + return $this; + } + + /** + * The key may be used to encipher data. + * + * Generated from protobuf field bool data_encipherment = 4; + * @return bool + */ + public function getDataEncipherment() + { + return $this->data_encipherment; + } + + /** + * The key may be used to encipher data. + * + * Generated from protobuf field bool data_encipherment = 4; + * @param bool $var + * @return $this + */ + public function setDataEncipherment($var) + { + GPBUtil::checkBool($var); + $this->data_encipherment = $var; + + return $this; + } + + /** + * The key may be used in a key agreement protocol. + * + * Generated from protobuf field bool key_agreement = 5; + * @return bool + */ + public function getKeyAgreement() + { + return $this->key_agreement; + } + + /** + * The key may be used in a key agreement protocol. + * + * Generated from protobuf field bool key_agreement = 5; + * @param bool $var + * @return $this + */ + public function setKeyAgreement($var) + { + GPBUtil::checkBool($var); + $this->key_agreement = $var; + + return $this; + } + + /** + * The key may be used to sign certificates. + * + * Generated from protobuf field bool cert_sign = 6; + * @return bool + */ + public function getCertSign() + { + return $this->cert_sign; + } + + /** + * The key may be used to sign certificates. + * + * Generated from protobuf field bool cert_sign = 6; + * @param bool $var + * @return $this + */ + public function setCertSign($var) + { + GPBUtil::checkBool($var); + $this->cert_sign = $var; + + return $this; + } + + /** + * The key may be used sign certificate revocation lists. + * + * Generated from protobuf field bool crl_sign = 7; + * @return bool + */ + public function getCrlSign() + { + return $this->crl_sign; + } + + /** + * The key may be used sign certificate revocation lists. + * + * Generated from protobuf field bool crl_sign = 7; + * @param bool $var + * @return $this + */ + public function setCrlSign($var) + { + GPBUtil::checkBool($var); + $this->crl_sign = $var; + + return $this; + } + + /** + * The key may be used to encipher only. + * + * Generated from protobuf field bool encipher_only = 8; + * @return bool + */ + public function getEncipherOnly() + { + return $this->encipher_only; + } + + /** + * The key may be used to encipher only. + * + * Generated from protobuf field bool encipher_only = 8; + * @param bool $var + * @return $this + */ + public function setEncipherOnly($var) + { + GPBUtil::checkBool($var); + $this->encipher_only = $var; + + return $this; + } + + /** + * The key may be used to decipher only. + * + * Generated from protobuf field bool decipher_only = 9; + * @return bool + */ + public function getDecipherOnly() + { + return $this->decipher_only; + } + + /** + * The key may be used to decipher only. + * + * Generated from protobuf field bool decipher_only = 9; + * @param bool $var + * @return $this + */ + public function setDecipherOnly($var) + { + GPBUtil::checkBool($var); + $this->decipher_only = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCaPoolsRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCaPoolsRequest.php new file mode 100644 index 000000000000..78a8d0f71091 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCaPoolsRequest.php @@ -0,0 +1,256 @@ +google.cloud.security.privateca.v1.ListCaPoolsRequest + */ +class ListCaPoolsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the location associated with the + * [CaPools][google.cloud.security.privateca.v1.CaPool], in the format + * `projects/{@*}locations/*`. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Optional. Limit on the number of + * [CaPools][google.cloud.security.privateca.v1.CaPool] to include in the + * response. Further [CaPools][google.cloud.security.privateca.v1.CaPool] can + * subsequently be obtained by including the + * [ListCaPoolsResponse.next_page_token][google.cloud.security.privateca.v1.ListCaPoolsResponse.next_page_token] + * in a subsequent request. If unspecified, the server will pick an + * appropriate default. + * + * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $page_size = 0; + /** + * Optional. Pagination token, returned earlier via + * [ListCaPoolsResponse.next_page_token][google.cloud.security.privateca.v1.ListCaPoolsResponse.next_page_token]. + * + * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $page_token = ''; + /** + * Optional. Only include resources that match the filter in the response. + * + * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $filter = ''; + /** + * Optional. Specify how the results should be sorted. + * + * 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 location associated with the + * [CaPools][google.cloud.security.privateca.v1.CaPool], in the format + * `projects/*/locations/*`. Please see + * {@see CertificateAuthorityServiceClient::locationName()} for help formatting this field. + * + * @return \Google\Cloud\Security\PrivateCA\V1\ListCaPoolsRequest + * + * @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 location associated with the + * [CaPools][google.cloud.security.privateca.v1.CaPool], in the format + * `projects/{@*}locations/*`. + * @type int $page_size + * Optional. Limit on the number of + * [CaPools][google.cloud.security.privateca.v1.CaPool] to include in the + * response. Further [CaPools][google.cloud.security.privateca.v1.CaPool] can + * subsequently be obtained by including the + * [ListCaPoolsResponse.next_page_token][google.cloud.security.privateca.v1.ListCaPoolsResponse.next_page_token] + * in a subsequent request. If unspecified, the server will pick an + * appropriate default. + * @type string $page_token + * Optional. Pagination token, returned earlier via + * [ListCaPoolsResponse.next_page_token][google.cloud.security.privateca.v1.ListCaPoolsResponse.next_page_token]. + * @type string $filter + * Optional. Only include resources that match the filter in the response. + * @type string $order_by + * Optional. Specify how the results should be sorted. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the location associated with the + * [CaPools][google.cloud.security.privateca.v1.CaPool], 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 associated with the + * [CaPools][google.cloud.security.privateca.v1.CaPool], 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. Limit on the number of + * [CaPools][google.cloud.security.privateca.v1.CaPool] to include in the + * response. Further [CaPools][google.cloud.security.privateca.v1.CaPool] can + * subsequently be obtained by including the + * [ListCaPoolsResponse.next_page_token][google.cloud.security.privateca.v1.ListCaPoolsResponse.next_page_token] + * in a subsequent request. If unspecified, the 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. Limit on the number of + * [CaPools][google.cloud.security.privateca.v1.CaPool] to include in the + * response. Further [CaPools][google.cloud.security.privateca.v1.CaPool] can + * subsequently be obtained by including the + * [ListCaPoolsResponse.next_page_token][google.cloud.security.privateca.v1.ListCaPoolsResponse.next_page_token] + * in a subsequent request. If unspecified, the 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. Pagination token, returned earlier via + * [ListCaPoolsResponse.next_page_token][google.cloud.security.privateca.v1.ListCaPoolsResponse.next_page_token]. + * + * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * Optional. Pagination token, returned earlier via + * [ListCaPoolsResponse.next_page_token][google.cloud.security.privateca.v1.ListCaPoolsResponse.next_page_token]. + * + * 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. Only include resources that match the filter in the response. + * + * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * Optional. Only include resources that match the filter in the response. + * + * 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. Specify how the results should be sorted. + * + * Generated from protobuf field string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getOrderBy() + { + return $this->order_by; + } + + /** + * Optional. Specify how the results should be sorted. + * + * 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCaPoolsResponse.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCaPoolsResponse.php new file mode 100644 index 000000000000..1c7373498b77 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCaPoolsResponse.php @@ -0,0 +1,144 @@ +google.cloud.security.privateca.v1.ListCaPoolsResponse + */ +class ListCaPoolsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * The list of [CaPools][google.cloud.security.privateca.v1.CaPool]. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CaPool ca_pools = 1; + */ + private $ca_pools; + /** + * A token to retrieve next page of results. Pass this value in + * [ListCertificateAuthoritiesRequest.page_token][google.cloud.security.privateca.v1.ListCertificateAuthoritiesRequest.page_token] + * to retrieve the next page of results. + * + * Generated from protobuf field string next_page_token = 2; + */ + protected $next_page_token = ''; + /** + * A list of locations (e.g. "us-west1") 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 \Google\Cloud\Security\PrivateCA\V1\CaPool[] $ca_pools + * The list of [CaPools][google.cloud.security.privateca.v1.CaPool]. + * @type string $next_page_token + * A token to retrieve next page of results. Pass this value in + * [ListCertificateAuthoritiesRequest.page_token][google.cloud.security.privateca.v1.ListCertificateAuthoritiesRequest.page_token] + * to retrieve the next page of results. + * @type string[] $unreachable + * A list of locations (e.g. "us-west1") that could not be reached. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * The list of [CaPools][google.cloud.security.privateca.v1.CaPool]. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CaPool ca_pools = 1; + * @return RepeatedField<\Google\Cloud\Security\PrivateCA\V1\CaPool> + */ + public function getCaPools() + { + return $this->ca_pools; + } + + /** + * The list of [CaPools][google.cloud.security.privateca.v1.CaPool]. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CaPool ca_pools = 1; + * @param \Google\Cloud\Security\PrivateCA\V1\CaPool[] $var + * @return $this + */ + public function setCaPools($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Security\PrivateCA\V1\CaPool::class); + $this->ca_pools = $arr; + + return $this; + } + + /** + * A token to retrieve next page of results. Pass this value in + * [ListCertificateAuthoritiesRequest.page_token][google.cloud.security.privateca.v1.ListCertificateAuthoritiesRequest.page_token] + * to retrieve 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 retrieve next page of results. Pass this value in + * [ListCertificateAuthoritiesRequest.page_token][google.cloud.security.privateca.v1.ListCertificateAuthoritiesRequest.page_token] + * to retrieve 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; + } + + /** + * A list of locations (e.g. "us-west1") that could not be reached. + * + * Generated from protobuf field repeated string unreachable = 3; + * @return RepeatedField + */ + public function getUnreachable() + { + return $this->unreachable; + } + + /** + * A list of locations (e.g. "us-west1") that could not be reached. + * + * Generated from protobuf field repeated string unreachable = 3; + * @param string[] $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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateAuthoritiesRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateAuthoritiesRequest.php new file mode 100644 index 000000000000..24fab0d845a8 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateAuthoritiesRequest.php @@ -0,0 +1,265 @@ +google.cloud.security.privateca.v1.ListCertificateAuthoritiesRequest + */ +class ListCertificateAuthoritiesRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the + * [CaPool][google.cloud.security.privateca.v1.CaPool] associated with the + * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority], + * in the format `projects/{@*}locations/{@*}caPools/*`. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Optional. Limit on the number of + * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority] + * to include in the response. Further + * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority] + * can subsequently be obtained by including the + * [ListCertificateAuthoritiesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateAuthoritiesResponse.next_page_token] + * in a subsequent request. If unspecified, the server will pick an + * appropriate default. + * + * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $page_size = 0; + /** + * Optional. Pagination token, returned earlier via + * [ListCertificateAuthoritiesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateAuthoritiesResponse.next_page_token]. + * + * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $page_token = ''; + /** + * Optional. Only include resources that match the filter in the response. + * + * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $filter = ''; + /** + * Optional. Specify how the results should be sorted. + * + * 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 + * [CaPool][google.cloud.security.privateca.v1.CaPool] associated with the + * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority], + * in the format `projects/*/locations/*/caPools/*`. Please see + * {@see CertificateAuthorityServiceClient::caPoolName()} for help formatting this field. + * + * @return \Google\Cloud\Security\PrivateCA\V1\ListCertificateAuthoritiesRequest + * + * @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 + * [CaPool][google.cloud.security.privateca.v1.CaPool] associated with the + * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority], + * in the format `projects/{@*}locations/{@*}caPools/*`. + * @type int $page_size + * Optional. Limit on the number of + * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority] + * to include in the response. Further + * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority] + * can subsequently be obtained by including the + * [ListCertificateAuthoritiesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateAuthoritiesResponse.next_page_token] + * in a subsequent request. If unspecified, the server will pick an + * appropriate default. + * @type string $page_token + * Optional. Pagination token, returned earlier via + * [ListCertificateAuthoritiesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateAuthoritiesResponse.next_page_token]. + * @type string $filter + * Optional. Only include resources that match the filter in the response. + * @type string $order_by + * Optional. Specify how the results should be sorted. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the + * [CaPool][google.cloud.security.privateca.v1.CaPool] associated with the + * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority], + * in the format `projects/{@*}locations/{@*}caPools/*`. + * + * 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 + * [CaPool][google.cloud.security.privateca.v1.CaPool] associated with the + * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority], + * in the format `projects/{@*}locations/{@*}caPools/*`. + * + * 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. Limit on the number of + * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority] + * to include in the response. Further + * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority] + * can subsequently be obtained by including the + * [ListCertificateAuthoritiesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateAuthoritiesResponse.next_page_token] + * in a subsequent request. If unspecified, the 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. Limit on the number of + * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority] + * to include in the response. Further + * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority] + * can subsequently be obtained by including the + * [ListCertificateAuthoritiesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateAuthoritiesResponse.next_page_token] + * in a subsequent request. If unspecified, the 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. Pagination token, returned earlier via + * [ListCertificateAuthoritiesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateAuthoritiesResponse.next_page_token]. + * + * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * Optional. Pagination token, returned earlier via + * [ListCertificateAuthoritiesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateAuthoritiesResponse.next_page_token]. + * + * 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. Only include resources that match the filter in the response. + * + * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * Optional. Only include resources that match the filter in the response. + * + * 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. Specify how the results should be sorted. + * + * Generated from protobuf field string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getOrderBy() + { + return $this->order_by; + } + + /** + * Optional. Specify how the results should be sorted. + * + * 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateAuthoritiesResponse.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateAuthoritiesResponse.php new file mode 100644 index 000000000000..36887d5ea9a3 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateAuthoritiesResponse.php @@ -0,0 +1,148 @@ +google.cloud.security.privateca.v1.ListCertificateAuthoritiesResponse + */ +class ListCertificateAuthoritiesResponse extends \Google\Protobuf\Internal\Message +{ + /** + * The list of + * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority]. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CertificateAuthority certificate_authorities = 1; + */ + private $certificate_authorities; + /** + * A token to retrieve next page of results. Pass this value in + * [ListCertificateAuthoritiesRequest.page_token][google.cloud.security.privateca.v1.ListCertificateAuthoritiesRequest.page_token] + * to retrieve the next page of results. + * + * Generated from protobuf field string next_page_token = 2; + */ + protected $next_page_token = ''; + /** + * A list of locations (e.g. "us-west1") 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 \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority[] $certificate_authorities + * The list of + * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority]. + * @type string $next_page_token + * A token to retrieve next page of results. Pass this value in + * [ListCertificateAuthoritiesRequest.page_token][google.cloud.security.privateca.v1.ListCertificateAuthoritiesRequest.page_token] + * to retrieve the next page of results. + * @type string[] $unreachable + * A list of locations (e.g. "us-west1") that could not be reached. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * The list of + * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority]. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CertificateAuthority certificate_authorities = 1; + * @return RepeatedField<\Google\Cloud\Security\PrivateCA\V1\CertificateAuthority> + */ + public function getCertificateAuthorities() + { + return $this->certificate_authorities; + } + + /** + * The list of + * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority]. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CertificateAuthority certificate_authorities = 1; + * @param \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority[] $var + * @return $this + */ + public function setCertificateAuthorities($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority::class); + $this->certificate_authorities = $arr; + + return $this; + } + + /** + * A token to retrieve next page of results. Pass this value in + * [ListCertificateAuthoritiesRequest.page_token][google.cloud.security.privateca.v1.ListCertificateAuthoritiesRequest.page_token] + * to retrieve 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 retrieve next page of results. Pass this value in + * [ListCertificateAuthoritiesRequest.page_token][google.cloud.security.privateca.v1.ListCertificateAuthoritiesRequest.page_token] + * to retrieve 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; + } + + /** + * A list of locations (e.g. "us-west1") that could not be reached. + * + * Generated from protobuf field repeated string unreachable = 3; + * @return RepeatedField + */ + public function getUnreachable() + { + return $this->unreachable; + } + + /** + * A list of locations (e.g. "us-west1") that could not be reached. + * + * Generated from protobuf field repeated string unreachable = 3; + * @param string[] $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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateRevocationListsRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateRevocationListsRequest.php new file mode 100644 index 000000000000..bb02c0cf5ce4 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateRevocationListsRequest.php @@ -0,0 +1,260 @@ +google.cloud.security.privateca.v1.ListCertificateRevocationListsRequest + */ +class ListCertificateRevocationListsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the location associated with the + * [CertificateRevocationLists][google.cloud.security.privateca.v1.CertificateRevocationList], + * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Optional. Limit on the number of + * [CertificateRevocationLists][google.cloud.security.privateca.v1.CertificateRevocationList] + * to include in the response. Further + * [CertificateRevocationLists][google.cloud.security.privateca.v1.CertificateRevocationList] + * can subsequently be obtained by including the + * [ListCertificateRevocationListsResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateRevocationListsResponse.next_page_token] + * in a subsequent request. If unspecified, the server will pick an + * appropriate default. + * + * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $page_size = 0; + /** + * Optional. Pagination token, returned earlier via + * [ListCertificateRevocationListsResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateRevocationListsResponse.next_page_token]. + * + * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $page_token = ''; + /** + * Optional. Only include resources that match the filter in the response. + * + * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $filter = ''; + /** + * Optional. Specify how the results should be sorted. + * + * 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 location associated with the + * [CertificateRevocationLists][google.cloud.security.privateca.v1.CertificateRevocationList], + * in the format `projects/*/locations/*/caPools/*/certificateAuthorities/*`. Please see + * {@see CertificateAuthorityServiceClient::certificateAuthorityName()} for help formatting this field. + * + * @return \Google\Cloud\Security\PrivateCA\V1\ListCertificateRevocationListsRequest + * + * @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 location associated with the + * [CertificateRevocationLists][google.cloud.security.privateca.v1.CertificateRevocationList], + * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. + * @type int $page_size + * Optional. Limit on the number of + * [CertificateRevocationLists][google.cloud.security.privateca.v1.CertificateRevocationList] + * to include in the response. Further + * [CertificateRevocationLists][google.cloud.security.privateca.v1.CertificateRevocationList] + * can subsequently be obtained by including the + * [ListCertificateRevocationListsResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateRevocationListsResponse.next_page_token] + * in a subsequent request. If unspecified, the server will pick an + * appropriate default. + * @type string $page_token + * Optional. Pagination token, returned earlier via + * [ListCertificateRevocationListsResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateRevocationListsResponse.next_page_token]. + * @type string $filter + * Optional. Only include resources that match the filter in the response. + * @type string $order_by + * Optional. Specify how the results should be sorted. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the location associated with the + * [CertificateRevocationLists][google.cloud.security.privateca.v1.CertificateRevocationList], + * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. + * + * 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 associated with the + * [CertificateRevocationLists][google.cloud.security.privateca.v1.CertificateRevocationList], + * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. + * + * 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. Limit on the number of + * [CertificateRevocationLists][google.cloud.security.privateca.v1.CertificateRevocationList] + * to include in the response. Further + * [CertificateRevocationLists][google.cloud.security.privateca.v1.CertificateRevocationList] + * can subsequently be obtained by including the + * [ListCertificateRevocationListsResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateRevocationListsResponse.next_page_token] + * in a subsequent request. If unspecified, the 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. Limit on the number of + * [CertificateRevocationLists][google.cloud.security.privateca.v1.CertificateRevocationList] + * to include in the response. Further + * [CertificateRevocationLists][google.cloud.security.privateca.v1.CertificateRevocationList] + * can subsequently be obtained by including the + * [ListCertificateRevocationListsResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateRevocationListsResponse.next_page_token] + * in a subsequent request. If unspecified, the 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. Pagination token, returned earlier via + * [ListCertificateRevocationListsResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateRevocationListsResponse.next_page_token]. + * + * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * Optional. Pagination token, returned earlier via + * [ListCertificateRevocationListsResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateRevocationListsResponse.next_page_token]. + * + * 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. Only include resources that match the filter in the response. + * + * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * Optional. Only include resources that match the filter in the response. + * + * 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. Specify how the results should be sorted. + * + * Generated from protobuf field string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getOrderBy() + { + return $this->order_by; + } + + /** + * Optional. Specify how the results should be sorted. + * + * 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateRevocationListsResponse.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateRevocationListsResponse.php new file mode 100644 index 000000000000..392efa937fe7 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateRevocationListsResponse.php @@ -0,0 +1,148 @@ +google.cloud.security.privateca.v1.ListCertificateRevocationListsResponse + */ +class ListCertificateRevocationListsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * The list of + * [CertificateRevocationLists][google.cloud.security.privateca.v1.CertificateRevocationList]. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CertificateRevocationList certificate_revocation_lists = 1; + */ + private $certificate_revocation_lists; + /** + * A token to retrieve next page of results. Pass this value in + * [ListCertificateRevocationListsRequest.page_token][google.cloud.security.privateca.v1.ListCertificateRevocationListsRequest.page_token] + * to retrieve the next page of results. + * + * Generated from protobuf field string next_page_token = 2; + */ + protected $next_page_token = ''; + /** + * A list of locations (e.g. "us-west1") 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 \Google\Cloud\Security\PrivateCA\V1\CertificateRevocationList[] $certificate_revocation_lists + * The list of + * [CertificateRevocationLists][google.cloud.security.privateca.v1.CertificateRevocationList]. + * @type string $next_page_token + * A token to retrieve next page of results. Pass this value in + * [ListCertificateRevocationListsRequest.page_token][google.cloud.security.privateca.v1.ListCertificateRevocationListsRequest.page_token] + * to retrieve the next page of results. + * @type string[] $unreachable + * A list of locations (e.g. "us-west1") that could not be reached. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * The list of + * [CertificateRevocationLists][google.cloud.security.privateca.v1.CertificateRevocationList]. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CertificateRevocationList certificate_revocation_lists = 1; + * @return RepeatedField<\Google\Cloud\Security\PrivateCA\V1\CertificateRevocationList> + */ + public function getCertificateRevocationLists() + { + return $this->certificate_revocation_lists; + } + + /** + * The list of + * [CertificateRevocationLists][google.cloud.security.privateca.v1.CertificateRevocationList]. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CertificateRevocationList certificate_revocation_lists = 1; + * @param \Google\Cloud\Security\PrivateCA\V1\CertificateRevocationList[] $var + * @return $this + */ + public function setCertificateRevocationLists($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Security\PrivateCA\V1\CertificateRevocationList::class); + $this->certificate_revocation_lists = $arr; + + return $this; + } + + /** + * A token to retrieve next page of results. Pass this value in + * [ListCertificateRevocationListsRequest.page_token][google.cloud.security.privateca.v1.ListCertificateRevocationListsRequest.page_token] + * to retrieve 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 retrieve next page of results. Pass this value in + * [ListCertificateRevocationListsRequest.page_token][google.cloud.security.privateca.v1.ListCertificateRevocationListsRequest.page_token] + * to retrieve 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; + } + + /** + * A list of locations (e.g. "us-west1") that could not be reached. + * + * Generated from protobuf field repeated string unreachable = 3; + * @return RepeatedField + */ + public function getUnreachable() + { + return $this->unreachable; + } + + /** + * A list of locations (e.g. "us-west1") that could not be reached. + * + * Generated from protobuf field repeated string unreachable = 3; + * @param string[] $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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateTemplatesRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateTemplatesRequest.php new file mode 100644 index 000000000000..cf391fa7dee6 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateTemplatesRequest.php @@ -0,0 +1,260 @@ +google.cloud.security.privateca.v1.ListCertificateTemplatesRequest + */ +class ListCertificateTemplatesRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the location associated with the + * [CertificateTemplates][google.cloud.security.privateca.v1.CertificateTemplate], + * in the format `projects/{@*}locations/*`. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Optional. Limit on the number of + * [CertificateTemplates][google.cloud.security.privateca.v1.CertificateTemplate] + * to include in the response. Further + * [CertificateTemplates][google.cloud.security.privateca.v1.CertificateTemplate] + * can subsequently be obtained by including the + * [ListCertificateTemplatesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateTemplatesResponse.next_page_token] + * in a subsequent request. If unspecified, the server will pick an + * appropriate default. + * + * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $page_size = 0; + /** + * Optional. Pagination token, returned earlier via + * [ListCertificateTemplatesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateTemplatesResponse.next_page_token]. + * + * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $page_token = ''; + /** + * Optional. Only include resources that match the filter in the response. + * + * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $filter = ''; + /** + * Optional. Specify how the results should be sorted. + * + * 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 location associated with the + * [CertificateTemplates][google.cloud.security.privateca.v1.CertificateTemplate], + * in the format `projects/*/locations/*`. Please see + * {@see CertificateAuthorityServiceClient::locationName()} for help formatting this field. + * + * @return \Google\Cloud\Security\PrivateCA\V1\ListCertificateTemplatesRequest + * + * @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 location associated with the + * [CertificateTemplates][google.cloud.security.privateca.v1.CertificateTemplate], + * in the format `projects/{@*}locations/*`. + * @type int $page_size + * Optional. Limit on the number of + * [CertificateTemplates][google.cloud.security.privateca.v1.CertificateTemplate] + * to include in the response. Further + * [CertificateTemplates][google.cloud.security.privateca.v1.CertificateTemplate] + * can subsequently be obtained by including the + * [ListCertificateTemplatesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateTemplatesResponse.next_page_token] + * in a subsequent request. If unspecified, the server will pick an + * appropriate default. + * @type string $page_token + * Optional. Pagination token, returned earlier via + * [ListCertificateTemplatesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateTemplatesResponse.next_page_token]. + * @type string $filter + * Optional. Only include resources that match the filter in the response. + * @type string $order_by + * Optional. Specify how the results should be sorted. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the location associated with the + * [CertificateTemplates][google.cloud.security.privateca.v1.CertificateTemplate], + * 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 associated with the + * [CertificateTemplates][google.cloud.security.privateca.v1.CertificateTemplate], + * 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. Limit on the number of + * [CertificateTemplates][google.cloud.security.privateca.v1.CertificateTemplate] + * to include in the response. Further + * [CertificateTemplates][google.cloud.security.privateca.v1.CertificateTemplate] + * can subsequently be obtained by including the + * [ListCertificateTemplatesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateTemplatesResponse.next_page_token] + * in a subsequent request. If unspecified, the 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. Limit on the number of + * [CertificateTemplates][google.cloud.security.privateca.v1.CertificateTemplate] + * to include in the response. Further + * [CertificateTemplates][google.cloud.security.privateca.v1.CertificateTemplate] + * can subsequently be obtained by including the + * [ListCertificateTemplatesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateTemplatesResponse.next_page_token] + * in a subsequent request. If unspecified, the 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. Pagination token, returned earlier via + * [ListCertificateTemplatesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateTemplatesResponse.next_page_token]. + * + * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * Optional. Pagination token, returned earlier via + * [ListCertificateTemplatesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateTemplatesResponse.next_page_token]. + * + * 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. Only include resources that match the filter in the response. + * + * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * Optional. Only include resources that match the filter in the response. + * + * 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. Specify how the results should be sorted. + * + * Generated from protobuf field string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getOrderBy() + { + return $this->order_by; + } + + /** + * Optional. Specify how the results should be sorted. + * + * 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateTemplatesResponse.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateTemplatesResponse.php new file mode 100644 index 000000000000..e3be4d853b47 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateTemplatesResponse.php @@ -0,0 +1,148 @@ +google.cloud.security.privateca.v1.ListCertificateTemplatesResponse + */ +class ListCertificateTemplatesResponse extends \Google\Protobuf\Internal\Message +{ + /** + * The list of + * [CertificateTemplates][google.cloud.security.privateca.v1.CertificateTemplate]. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CertificateTemplate certificate_templates = 1; + */ + private $certificate_templates; + /** + * A token to retrieve next page of results. Pass this value in + * [ListCertificateTemplatesRequest.page_token][google.cloud.security.privateca.v1.ListCertificateTemplatesRequest.page_token] + * to retrieve the next page of results. + * + * Generated from protobuf field string next_page_token = 2; + */ + protected $next_page_token = ''; + /** + * A list of locations (e.g. "us-west1") 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 \Google\Cloud\Security\PrivateCA\V1\CertificateTemplate[] $certificate_templates + * The list of + * [CertificateTemplates][google.cloud.security.privateca.v1.CertificateTemplate]. + * @type string $next_page_token + * A token to retrieve next page of results. Pass this value in + * [ListCertificateTemplatesRequest.page_token][google.cloud.security.privateca.v1.ListCertificateTemplatesRequest.page_token] + * to retrieve the next page of results. + * @type string[] $unreachable + * A list of locations (e.g. "us-west1") that could not be reached. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * The list of + * [CertificateTemplates][google.cloud.security.privateca.v1.CertificateTemplate]. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CertificateTemplate certificate_templates = 1; + * @return RepeatedField<\Google\Cloud\Security\PrivateCA\V1\CertificateTemplate> + */ + public function getCertificateTemplates() + { + return $this->certificate_templates; + } + + /** + * The list of + * [CertificateTemplates][google.cloud.security.privateca.v1.CertificateTemplate]. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CertificateTemplate certificate_templates = 1; + * @param \Google\Cloud\Security\PrivateCA\V1\CertificateTemplate[] $var + * @return $this + */ + public function setCertificateTemplates($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Security\PrivateCA\V1\CertificateTemplate::class); + $this->certificate_templates = $arr; + + return $this; + } + + /** + * A token to retrieve next page of results. Pass this value in + * [ListCertificateTemplatesRequest.page_token][google.cloud.security.privateca.v1.ListCertificateTemplatesRequest.page_token] + * to retrieve 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 retrieve next page of results. Pass this value in + * [ListCertificateTemplatesRequest.page_token][google.cloud.security.privateca.v1.ListCertificateTemplatesRequest.page_token] + * to retrieve 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; + } + + /** + * A list of locations (e.g. "us-west1") that could not be reached. + * + * Generated from protobuf field repeated string unreachable = 3; + * @return RepeatedField + */ + public function getUnreachable() + { + return $this->unreachable; + } + + /** + * A list of locations (e.g. "us-west1") that could not be reached. + * + * Generated from protobuf field repeated string unreachable = 3; + * @param string[] $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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificatesRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificatesRequest.php new file mode 100644 index 000000000000..9313f4111e6e --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificatesRequest.php @@ -0,0 +1,313 @@ +google.cloud.security.privateca.v1.ListCertificatesRequest + */ +class ListCertificatesRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the parent associated with the + * [Certificates][google.cloud.security.privateca.v1.Certificate], in the + * format `projects/{@*}locations/{@*}caPools/*`. The parent resource name can be + * in one of two forms: + * 1. **Specific CA Pool:** To list certificates within a single CA Pool: + * `projects/{@*}locations/{@*}caPools/*` + * 2. **All CA Pools in a Location:** To list certificates across *all* CA + * Pools in a given project and location, use the wildcard character (`-`) + * in place of the CA Pool ID. + * Example: `projects/{@*}locations/{@*}caPools/-` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Optional. Limit on the number of + * [Certificates][google.cloud.security.privateca.v1.Certificate] to include + * in the response. Further + * [Certificates][google.cloud.security.privateca.v1.Certificate] can + * subsequently be obtained by including the + * [ListCertificatesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificatesResponse.next_page_token] + * in a subsequent request. If unspecified, the server will pick an + * appropriate default. + * + * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $page_size = 0; + /** + * Optional. Pagination token, returned earlier via + * [ListCertificatesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificatesResponse.next_page_token]. + * + * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $page_token = ''; + /** + * Optional. Only include resources that match the filter in the response. For + * details on supported filters and syntax, see [Certificates Filtering + * documentation](https://cloud.google.com/certificate-authority-service/docs/sorting-filtering-certificates#filtering_support). + * + * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $filter = ''; + /** + * Optional. Specify how the results should be sorted. For details on + * supported fields and syntax, see [Certificates Sorting + * documentation](https://cloud.google.com/certificate-authority-service/docs/sorting-filtering-certificates#sorting_support). + * + * 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 parent associated with the + * [Certificates][google.cloud.security.privateca.v1.Certificate], in the + * format `projects/*/locations/*/caPools/*`. The parent resource name can be + * in one of two forms: + * + * 1. **Specific CA Pool:** To list certificates within a single CA Pool: + * `projects/*/locations/*/caPools/*` + * + * 2. **All CA Pools in a Location:** To list certificates across *all* CA + * Pools in a given project and location, use the wildcard character (`-`) + * in place of the CA Pool ID. + * Example: `projects/*/locations/*/caPools/-` + * Please see {@see CertificateAuthorityServiceClient::caPoolName()} for help formatting this field. + * + * @return \Google\Cloud\Security\PrivateCA\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 resource name of the parent associated with the + * [Certificates][google.cloud.security.privateca.v1.Certificate], in the + * format `projects/{@*}locations/{@*}caPools/*`. The parent resource name can be + * in one of two forms: + * 1. **Specific CA Pool:** To list certificates within a single CA Pool: + * `projects/{@*}locations/{@*}caPools/*` + * 2. **All CA Pools in a Location:** To list certificates across *all* CA + * Pools in a given project and location, use the wildcard character (`-`) + * in place of the CA Pool ID. + * Example: `projects/{@*}locations/{@*}caPools/-` + * @type int $page_size + * Optional. Limit on the number of + * [Certificates][google.cloud.security.privateca.v1.Certificate] to include + * in the response. Further + * [Certificates][google.cloud.security.privateca.v1.Certificate] can + * subsequently be obtained by including the + * [ListCertificatesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificatesResponse.next_page_token] + * in a subsequent request. If unspecified, the server will pick an + * appropriate default. + * @type string $page_token + * Optional. Pagination token, returned earlier via + * [ListCertificatesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificatesResponse.next_page_token]. + * @type string $filter + * Optional. Only include resources that match the filter in the response. For + * details on supported filters and syntax, see [Certificates Filtering + * documentation](https://cloud.google.com/certificate-authority-service/docs/sorting-filtering-certificates#filtering_support). + * @type string $order_by + * Optional. Specify how the results should be sorted. For details on + * supported fields and syntax, see [Certificates Sorting + * documentation](https://cloud.google.com/certificate-authority-service/docs/sorting-filtering-certificates#sorting_support). + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the parent associated with the + * [Certificates][google.cloud.security.privateca.v1.Certificate], in the + * format `projects/{@*}locations/{@*}caPools/*`. The parent resource name can be + * in one of two forms: + * 1. **Specific CA Pool:** To list certificates within a single CA Pool: + * `projects/{@*}locations/{@*}caPools/*` + * 2. **All CA Pools in a Location:** To list certificates across *all* CA + * Pools in a given project and location, use the wildcard character (`-`) + * in place of the CA Pool ID. + * Example: `projects/{@*}locations/{@*}caPools/-` + * + * 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 parent associated with the + * [Certificates][google.cloud.security.privateca.v1.Certificate], in the + * format `projects/{@*}locations/{@*}caPools/*`. The parent resource name can be + * in one of two forms: + * 1. **Specific CA Pool:** To list certificates within a single CA Pool: + * `projects/{@*}locations/{@*}caPools/*` + * 2. **All CA Pools in a Location:** To list certificates across *all* CA + * Pools in a given project and location, use the wildcard character (`-`) + * in place of the CA Pool ID. + * Example: `projects/{@*}locations/{@*}caPools/-` + * + * 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. Limit on the number of + * [Certificates][google.cloud.security.privateca.v1.Certificate] to include + * in the response. Further + * [Certificates][google.cloud.security.privateca.v1.Certificate] can + * subsequently be obtained by including the + * [ListCertificatesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificatesResponse.next_page_token] + * in a subsequent request. If unspecified, the 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. Limit on the number of + * [Certificates][google.cloud.security.privateca.v1.Certificate] to include + * in the response. Further + * [Certificates][google.cloud.security.privateca.v1.Certificate] can + * subsequently be obtained by including the + * [ListCertificatesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificatesResponse.next_page_token] + * in a subsequent request. If unspecified, the 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. Pagination token, returned earlier via + * [ListCertificatesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificatesResponse.next_page_token]. + * + * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * Optional. Pagination token, returned earlier via + * [ListCertificatesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificatesResponse.next_page_token]. + * + * 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. Only include resources that match the filter in the response. For + * details on supported filters and syntax, see [Certificates Filtering + * documentation](https://cloud.google.com/certificate-authority-service/docs/sorting-filtering-certificates#filtering_support). + * + * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * Optional. Only include resources that match the filter in the response. For + * details on supported filters and syntax, see [Certificates Filtering + * documentation](https://cloud.google.com/certificate-authority-service/docs/sorting-filtering-certificates#filtering_support). + * + * 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. Specify how the results should be sorted. For details on + * supported fields and syntax, see [Certificates Sorting + * documentation](https://cloud.google.com/certificate-authority-service/docs/sorting-filtering-certificates#sorting_support). + * + * Generated from protobuf field string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getOrderBy() + { + return $this->order_by; + } + + /** + * Optional. Specify how the results should be sorted. For details on + * supported fields and syntax, see [Certificates Sorting + * documentation](https://cloud.google.com/certificate-authority-service/docs/sorting-filtering-certificates#sorting_support). + * + * 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificatesResponse.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificatesResponse.php new file mode 100644 index 000000000000..4a640eb686d5 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificatesResponse.php @@ -0,0 +1,144 @@ +google.cloud.security.privateca.v1.ListCertificatesResponse + */ +class ListCertificatesResponse extends \Google\Protobuf\Internal\Message +{ + /** + * The list of [Certificates][google.cloud.security.privateca.v1.Certificate]. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.Certificate certificates = 1; + */ + private $certificates; + /** + * A token to retrieve next page of results. Pass this value in + * [ListCertificatesRequest.page_token][google.cloud.security.privateca.v1.ListCertificatesRequest.page_token] + * to retrieve the next page of results. + * + * Generated from protobuf field string next_page_token = 2; + */ + protected $next_page_token = ''; + /** + * A list of locations (e.g. "us-west1") 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 \Google\Cloud\Security\PrivateCA\V1\Certificate[] $certificates + * The list of [Certificates][google.cloud.security.privateca.v1.Certificate]. + * @type string $next_page_token + * A token to retrieve next page of results. Pass this value in + * [ListCertificatesRequest.page_token][google.cloud.security.privateca.v1.ListCertificatesRequest.page_token] + * to retrieve the next page of results. + * @type string[] $unreachable + * A list of locations (e.g. "us-west1") that could not be reached. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * The list of [Certificates][google.cloud.security.privateca.v1.Certificate]. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.Certificate certificates = 1; + * @return RepeatedField<\Google\Cloud\Security\PrivateCA\V1\Certificate> + */ + public function getCertificates() + { + return $this->certificates; + } + + /** + * The list of [Certificates][google.cloud.security.privateca.v1.Certificate]. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.Certificate certificates = 1; + * @param \Google\Cloud\Security\PrivateCA\V1\Certificate[] $var + * @return $this + */ + public function setCertificates($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Security\PrivateCA\V1\Certificate::class); + $this->certificates = $arr; + + return $this; + } + + /** + * A token to retrieve next page of results. Pass this value in + * [ListCertificatesRequest.page_token][google.cloud.security.privateca.v1.ListCertificatesRequest.page_token] + * to retrieve 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 retrieve next page of results. Pass this value in + * [ListCertificatesRequest.page_token][google.cloud.security.privateca.v1.ListCertificatesRequest.page_token] + * to retrieve 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; + } + + /** + * A list of locations (e.g. "us-west1") that could not be reached. + * + * Generated from protobuf field repeated string unreachable = 3; + * @return RepeatedField + */ + public function getUnreachable() + { + return $this->unreachable; + } + + /** + * A list of locations (e.g. "us-west1") that could not be reached. + * + * Generated from protobuf field repeated string unreachable = 3; + * @param string[] $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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ObjectId.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ObjectId.php new file mode 100644 index 000000000000..ae046007323f --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ObjectId.php @@ -0,0 +1,73 @@ +google.cloud.security.privateca.v1.ObjectId + */ +class ObjectId extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The parts of an OID path. The most significant parts of the path + * come first. + * + * Generated from protobuf field repeated int32 object_id_path = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + private $object_id_path; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int[] $object_id_path + * Required. The parts of an OID path. The most significant parts of the path + * come first. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * Required. The parts of an OID path. The most significant parts of the path + * come first. + * + * Generated from protobuf field repeated int32 object_id_path = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return RepeatedField + */ + public function getObjectIdPath() + { + return $this->object_id_path; + } + + /** + * Required. The parts of an OID path. The most significant parts of the path + * come first. + * + * Generated from protobuf field repeated int32 object_id_path = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param int[] $var + * @return $this + */ + public function setObjectIdPath($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::INT32); + $this->object_id_path = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/OperationMetadata.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/OperationMetadata.php new file mode 100644 index 000000000000..32771fd1adb3 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/OperationMetadata.php @@ -0,0 +1,311 @@ +google.cloud.security.privateca.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 + * [google.longrunning.Operation.error][google.longrunning.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 + * [google.longrunning.Operation.error][google.longrunning.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\Security\Privateca\V1\Service::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 + * [google.longrunning.Operation.error][google.longrunning.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 + * [google.longrunning.Operation.error][google.longrunning.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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/PublicKey.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/PublicKey.php new file mode 100644 index 000000000000..09b2adaed9a0 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/PublicKey.php @@ -0,0 +1,106 @@ +google.cloud.security.privateca.v1.PublicKey + */ +class PublicKey extends \Google\Protobuf\Internal\Message +{ + /** + * Required. A public key. The padding and encoding + * must match with the `KeyFormat` value specified for the `format` field. + * + * Generated from protobuf field bytes key = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $key = ''; + /** + * Required. The format of the public key. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.PublicKey.KeyFormat format = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $format = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $key + * Required. A public key. The padding and encoding + * must match with the `KeyFormat` value specified for the `format` field. + * @type int $format + * Required. The format of the public key. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * Required. A public key. The padding and encoding + * must match with the `KeyFormat` value specified for the `format` field. + * + * Generated from protobuf field bytes key = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getKey() + { + return $this->key; + } + + /** + * Required. A public key. The padding and encoding + * must match with the `KeyFormat` value specified for the `format` field. + * + * Generated from protobuf field bytes key = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setKey($var) + { + GPBUtil::checkString($var, False); + $this->key = $var; + + return $this; + } + + /** + * Required. The format of the public key. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.PublicKey.KeyFormat format = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return int + */ + public function getFormat() + { + return $this->format; + } + + /** + * Required. The format of the public key. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.PublicKey.KeyFormat format = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param int $var + * @return $this + */ + public function setFormat($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Security\PrivateCA\V1\PublicKey\KeyFormat::class); + $this->format = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/PublicKey/KeyFormat.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/PublicKey/KeyFormat.php new file mode 100644 index 000000000000..5057742c7900 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/PublicKey/KeyFormat.php @@ -0,0 +1,67 @@ +google.cloud.security.privateca.v1.PublicKey.KeyFormat + */ +class KeyFormat +{ + /** + * Default unspecified value. + * + * Generated from protobuf enum KEY_FORMAT_UNSPECIFIED = 0; + */ + const KEY_FORMAT_UNSPECIFIED = 0; + /** + * The key is PEM-encoded as defined in [RFC + * 7468](https://tools.ietf.org/html/rfc7468). It can be any of the + * following: a PEM-encoded PKCS#1/RFC 3447 RSAPublicKey + * structure, an RFC 5280 + * [SubjectPublicKeyInfo](https://tools.ietf.org/html/rfc5280#section-4.1) + * or a PEM-encoded X.509 certificate signing request (CSR). If a + * [SubjectPublicKeyInfo](https://tools.ietf.org/html/rfc5280#section-4.1) + * is specified, it can contain a A PEM-encoded PKCS#1/RFC 3447 RSAPublicKey + * or a NIST P-256/secp256r1/prime256v1 or P-384 key. If a CSR is specified, + * it will used solely for the purpose of extracting the public key. When + * generated by the service, it will always be an RFC 5280 + * [SubjectPublicKeyInfo](https://tools.ietf.org/html/rfc5280#section-4.1) + * structure containing an algorithm identifier and a key. + * + * Generated from protobuf enum PEM = 1; + */ + const PEM = 1; + + private static $valueToName = [ + self::KEY_FORMAT_UNSPECIFIED => 'KEY_FORMAT_UNSPECIFIED', + self::PEM => 'PEM', + ]; + + 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/RelativeDistinguishedName.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/RelativeDistinguishedName.php new file mode 100644 index 000000000000..737538b2d983 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/RelativeDistinguishedName.php @@ -0,0 +1,69 @@ +google.cloud.security.privateca.v1.RelativeDistinguishedName + */ +class RelativeDistinguishedName extends \Google\Protobuf\Internal\Message +{ + /** + * Attributes describes the attribute value assertions in the RDN. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.AttributeTypeAndValue attributes = 1; + */ + private $attributes; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Security\PrivateCA\V1\AttributeTypeAndValue[] $attributes + * Attributes describes the attribute value assertions in the RDN. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * Attributes describes the attribute value assertions in the RDN. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.AttributeTypeAndValue attributes = 1; + * @return RepeatedField<\Google\Cloud\Security\PrivateCA\V1\AttributeTypeAndValue> + */ + public function getAttributes() + { + return $this->attributes; + } + + /** + * Attributes describes the attribute value assertions in the RDN. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.AttributeTypeAndValue attributes = 1; + * @param \Google\Cloud\Security\PrivateCA\V1\AttributeTypeAndValue[] $var + * @return $this + */ + public function setAttributes($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Security\PrivateCA\V1\AttributeTypeAndValue::class); + $this->attributes = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/RevocationReason.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/RevocationReason.php new file mode 100644 index 000000000000..919eb2cb9c31 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/RevocationReason.php @@ -0,0 +1,122 @@ +google.cloud.security.privateca.v1.RevocationReason + */ +class RevocationReason +{ + /** + * Default unspecified value. This value does indicate that a + * [Certificate][google.cloud.security.privateca.v1.Certificate] has been + * revoked, but that a reason has not been recorded. + * + * Generated from protobuf enum REVOCATION_REASON_UNSPECIFIED = 0; + */ + const REVOCATION_REASON_UNSPECIFIED = 0; + /** + * Key material for this + * [Certificate][google.cloud.security.privateca.v1.Certificate] may have + * leaked. + * + * Generated from protobuf enum KEY_COMPROMISE = 1; + */ + const KEY_COMPROMISE = 1; + /** + * The key material for a certificate authority in the issuing path may have + * leaked. + * + * Generated from protobuf enum CERTIFICATE_AUTHORITY_COMPROMISE = 2; + */ + const CERTIFICATE_AUTHORITY_COMPROMISE = 2; + /** + * The subject or other attributes in this + * [Certificate][google.cloud.security.privateca.v1.Certificate] have changed. + * + * Generated from protobuf enum AFFILIATION_CHANGED = 3; + */ + const AFFILIATION_CHANGED = 3; + /** + * This [Certificate][google.cloud.security.privateca.v1.Certificate] has been + * superseded. + * + * Generated from protobuf enum SUPERSEDED = 4; + */ + const SUPERSEDED = 4; + /** + * This [Certificate][google.cloud.security.privateca.v1.Certificate] or + * entities in the issuing path have ceased to operate. + * + * Generated from protobuf enum CESSATION_OF_OPERATION = 5; + */ + const CESSATION_OF_OPERATION = 5; + /** + * This [Certificate][google.cloud.security.privateca.v1.Certificate] should + * not be considered valid, it is expected that it may become valid in the + * future. + * + * Generated from protobuf enum CERTIFICATE_HOLD = 6; + */ + const CERTIFICATE_HOLD = 6; + /** + * This [Certificate][google.cloud.security.privateca.v1.Certificate] no + * longer has permission to assert the listed attributes. + * + * Generated from protobuf enum PRIVILEGE_WITHDRAWN = 7; + */ + const PRIVILEGE_WITHDRAWN = 7; + /** + * The authority which determines appropriate attributes for a + * [Certificate][google.cloud.security.privateca.v1.Certificate] may have been + * compromised. + * + * Generated from protobuf enum ATTRIBUTE_AUTHORITY_COMPROMISE = 8; + */ + const ATTRIBUTE_AUTHORITY_COMPROMISE = 8; + + private static $valueToName = [ + self::REVOCATION_REASON_UNSPECIFIED => 'REVOCATION_REASON_UNSPECIFIED', + self::KEY_COMPROMISE => 'KEY_COMPROMISE', + self::CERTIFICATE_AUTHORITY_COMPROMISE => 'CERTIFICATE_AUTHORITY_COMPROMISE', + self::AFFILIATION_CHANGED => 'AFFILIATION_CHANGED', + self::SUPERSEDED => 'SUPERSEDED', + self::CESSATION_OF_OPERATION => 'CESSATION_OF_OPERATION', + self::CERTIFICATE_HOLD => 'CERTIFICATE_HOLD', + self::PRIVILEGE_WITHDRAWN => 'PRIVILEGE_WITHDRAWN', + self::ATTRIBUTE_AUTHORITY_COMPROMISE => 'ATTRIBUTE_AUTHORITY_COMPROMISE', + ]; + + 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/RevokeCertificateRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/RevokeCertificateRequest.php new file mode 100644 index 000000000000..a1c5dcb28f5e --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/RevokeCertificateRequest.php @@ -0,0 +1,208 @@ +google.cloud.security.privateca.v1.RevokeCertificateRequest + */ +class RevokeCertificateRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name for this + * [Certificate][google.cloud.security.privateca.v1.Certificate] in the format + * `projects/{@*}locations/{@*}caPools/{@*}certificates/*`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * Required. The + * [RevocationReason][google.cloud.security.privateca.v1.RevocationReason] for + * revoking this certificate. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.RevocationReason reason = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $reason = 0; + /** + * Optional. An 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $request_id = ''; + + /** + * @param string $name Required. The resource name for this + * [Certificate][google.cloud.security.privateca.v1.Certificate] in the format + * `projects/*/locations/*/caPools/*/certificates/*`. Please see + * {@see CertificateAuthorityServiceClient::certificateName()} for help formatting this field. + * + * @return \Google\Cloud\Security\PrivateCA\V1\RevokeCertificateRequest + * + * @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 for this + * [Certificate][google.cloud.security.privateca.v1.Certificate] in the format + * `projects/{@*}locations/{@*}caPools/{@*}certificates/*`. + * @type int $reason + * Required. The + * [RevocationReason][google.cloud.security.privateca.v1.RevocationReason] for + * revoking this certificate. + * @type string $request_id + * Optional. An 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\Security\Privateca\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name for this + * [Certificate][google.cloud.security.privateca.v1.Certificate] in the format + * `projects/{@*}locations/{@*}caPools/{@*}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. The resource name for this + * [Certificate][google.cloud.security.privateca.v1.Certificate] in the format + * `projects/{@*}locations/{@*}caPools/{@*}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; + } + + /** + * Required. The + * [RevocationReason][google.cloud.security.privateca.v1.RevocationReason] for + * revoking this certificate. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.RevocationReason reason = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return int + */ + public function getReason() + { + return $this->reason; + } + + /** + * Required. The + * [RevocationReason][google.cloud.security.privateca.v1.RevocationReason] for + * revoking this certificate. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.RevocationReason reason = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param int $var + * @return $this + */ + public function setReason($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Security\PrivateCA\V1\RevocationReason::class); + $this->reason = $var; + + return $this; + } + + /** + * Optional. An 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getRequestId() + { + return $this->request_id; + } + + /** + * Optional. An 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 = 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; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/Subject.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/Subject.php new file mode 100644 index 000000000000..abe915895acf --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/Subject.php @@ -0,0 +1,340 @@ +google.cloud.security.privateca.v1.Subject + */ +class Subject extends \Google\Protobuf\Internal\Message +{ + /** + * The "common name" of the subject. + * + * Generated from protobuf field string common_name = 1; + */ + protected $common_name = ''; + /** + * The country code of the subject. + * + * Generated from protobuf field string country_code = 2; + */ + protected $country_code = ''; + /** + * The organization of the subject. + * + * Generated from protobuf field string organization = 3; + */ + protected $organization = ''; + /** + * The organizational_unit of the subject. + * + * Generated from protobuf field string organizational_unit = 4; + */ + protected $organizational_unit = ''; + /** + * The locality or city of the subject. + * + * Generated from protobuf field string locality = 5; + */ + protected $locality = ''; + /** + * The province, territory, or regional state of the subject. + * + * Generated from protobuf field string province = 6; + */ + protected $province = ''; + /** + * The street address of the subject. + * + * Generated from protobuf field string street_address = 7; + */ + protected $street_address = ''; + /** + * The postal code of the subject. + * + * Generated from protobuf field string postal_code = 8; + */ + protected $postal_code = ''; + /** + * This field can be used in place of the named subject fields. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.RelativeDistinguishedName rdn_sequence = 9; + */ + private $rdn_sequence; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $common_name + * The "common name" of the subject. + * @type string $country_code + * The country code of the subject. + * @type string $organization + * The organization of the subject. + * @type string $organizational_unit + * The organizational_unit of the subject. + * @type string $locality + * The locality or city of the subject. + * @type string $province + * The province, territory, or regional state of the subject. + * @type string $street_address + * The street address of the subject. + * @type string $postal_code + * The postal code of the subject. + * @type \Google\Cloud\Security\PrivateCA\V1\RelativeDistinguishedName[] $rdn_sequence + * This field can be used in place of the named subject fields. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * The "common name" of the subject. + * + * Generated from protobuf field string common_name = 1; + * @return string + */ + public function getCommonName() + { + return $this->common_name; + } + + /** + * The "common name" of the subject. + * + * Generated from protobuf field string common_name = 1; + * @param string $var + * @return $this + */ + public function setCommonName($var) + { + GPBUtil::checkString($var, True); + $this->common_name = $var; + + return $this; + } + + /** + * The country code of the subject. + * + * Generated from protobuf field string country_code = 2; + * @return string + */ + public function getCountryCode() + { + return $this->country_code; + } + + /** + * The country code of the subject. + * + * Generated from protobuf field string country_code = 2; + * @param string $var + * @return $this + */ + public function setCountryCode($var) + { + GPBUtil::checkString($var, True); + $this->country_code = $var; + + return $this; + } + + /** + * The organization of the subject. + * + * Generated from protobuf field string organization = 3; + * @return string + */ + public function getOrganization() + { + return $this->organization; + } + + /** + * The organization of the subject. + * + * Generated from protobuf field string organization = 3; + * @param string $var + * @return $this + */ + public function setOrganization($var) + { + GPBUtil::checkString($var, True); + $this->organization = $var; + + return $this; + } + + /** + * The organizational_unit of the subject. + * + * Generated from protobuf field string organizational_unit = 4; + * @return string + */ + public function getOrganizationalUnit() + { + return $this->organizational_unit; + } + + /** + * The organizational_unit of the subject. + * + * Generated from protobuf field string organizational_unit = 4; + * @param string $var + * @return $this + */ + public function setOrganizationalUnit($var) + { + GPBUtil::checkString($var, True); + $this->organizational_unit = $var; + + return $this; + } + + /** + * The locality or city of the subject. + * + * Generated from protobuf field string locality = 5; + * @return string + */ + public function getLocality() + { + return $this->locality; + } + + /** + * The locality or city of the subject. + * + * Generated from protobuf field string locality = 5; + * @param string $var + * @return $this + */ + public function setLocality($var) + { + GPBUtil::checkString($var, True); + $this->locality = $var; + + return $this; + } + + /** + * The province, territory, or regional state of the subject. + * + * Generated from protobuf field string province = 6; + * @return string + */ + public function getProvince() + { + return $this->province; + } + + /** + * The province, territory, or regional state of the subject. + * + * Generated from protobuf field string province = 6; + * @param string $var + * @return $this + */ + public function setProvince($var) + { + GPBUtil::checkString($var, True); + $this->province = $var; + + return $this; + } + + /** + * The street address of the subject. + * + * Generated from protobuf field string street_address = 7; + * @return string + */ + public function getStreetAddress() + { + return $this->street_address; + } + + /** + * The street address of the subject. + * + * Generated from protobuf field string street_address = 7; + * @param string $var + * @return $this + */ + public function setStreetAddress($var) + { + GPBUtil::checkString($var, True); + $this->street_address = $var; + + return $this; + } + + /** + * The postal code of the subject. + * + * Generated from protobuf field string postal_code = 8; + * @return string + */ + public function getPostalCode() + { + return $this->postal_code; + } + + /** + * The postal code of the subject. + * + * Generated from protobuf field string postal_code = 8; + * @param string $var + * @return $this + */ + public function setPostalCode($var) + { + GPBUtil::checkString($var, True); + $this->postal_code = $var; + + return $this; + } + + /** + * This field can be used in place of the named subject fields. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.RelativeDistinguishedName rdn_sequence = 9; + * @return RepeatedField<\Google\Cloud\Security\PrivateCA\V1\RelativeDistinguishedName> + */ + public function getRdnSequence() + { + return $this->rdn_sequence; + } + + /** + * This field can be used in place of the named subject fields. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.RelativeDistinguishedName rdn_sequence = 9; + * @param \Google\Cloud\Security\PrivateCA\V1\RelativeDistinguishedName[] $var + * @return $this + */ + public function setRdnSequence($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Security\PrivateCA\V1\RelativeDistinguishedName::class); + $this->rdn_sequence = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/SubjectAltNames.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/SubjectAltNames.php new file mode 100644 index 000000000000..97042ad72bad --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/SubjectAltNames.php @@ -0,0 +1,214 @@ +google.cloud.security.privateca.v1.SubjectAltNames + */ +class SubjectAltNames extends \Google\Protobuf\Internal\Message +{ + /** + * Contains only valid, fully-qualified host names. + * + * Generated from protobuf field repeated string dns_names = 1; + */ + private $dns_names; + /** + * Contains only valid RFC 3986 URIs. + * + * Generated from protobuf field repeated string uris = 2; + */ + private $uris; + /** + * Contains only valid RFC 2822 E-mail addresses. + * + * Generated from protobuf field repeated string email_addresses = 3; + */ + private $email_addresses; + /** + * Contains only valid 32-bit IPv4 addresses or RFC 4291 IPv6 addresses. + * + * Generated from protobuf field repeated string ip_addresses = 4; + */ + private $ip_addresses; + /** + * Contains additional subject alternative name values. + * For each custom_san, the `value` field must contain an ASN.1 encoded + * UTF8String. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.X509Extension custom_sans = 5; + */ + private $custom_sans; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string[] $dns_names + * Contains only valid, fully-qualified host names. + * @type string[] $uris + * Contains only valid RFC 3986 URIs. + * @type string[] $email_addresses + * Contains only valid RFC 2822 E-mail addresses. + * @type string[] $ip_addresses + * Contains only valid 32-bit IPv4 addresses or RFC 4291 IPv6 addresses. + * @type \Google\Cloud\Security\PrivateCA\V1\X509Extension[] $custom_sans + * Contains additional subject alternative name values. + * For each custom_san, the `value` field must contain an ASN.1 encoded + * UTF8String. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * Contains only valid, fully-qualified host names. + * + * Generated from protobuf field repeated string dns_names = 1; + * @return RepeatedField + */ + public function getDnsNames() + { + return $this->dns_names; + } + + /** + * Contains only valid, fully-qualified host names. + * + * Generated from protobuf field repeated string dns_names = 1; + * @param string[] $var + * @return $this + */ + public function setDnsNames($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->dns_names = $arr; + + return $this; + } + + /** + * Contains only valid RFC 3986 URIs. + * + * Generated from protobuf field repeated string uris = 2; + * @return RepeatedField + */ + public function getUris() + { + return $this->uris; + } + + /** + * Contains only valid RFC 3986 URIs. + * + * Generated from protobuf field repeated string uris = 2; + * @param string[] $var + * @return $this + */ + public function setUris($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->uris = $arr; + + return $this; + } + + /** + * Contains only valid RFC 2822 E-mail addresses. + * + * Generated from protobuf field repeated string email_addresses = 3; + * @return RepeatedField + */ + public function getEmailAddresses() + { + return $this->email_addresses; + } + + /** + * Contains only valid RFC 2822 E-mail addresses. + * + * Generated from protobuf field repeated string email_addresses = 3; + * @param string[] $var + * @return $this + */ + public function setEmailAddresses($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->email_addresses = $arr; + + return $this; + } + + /** + * Contains only valid 32-bit IPv4 addresses or RFC 4291 IPv6 addresses. + * + * Generated from protobuf field repeated string ip_addresses = 4; + * @return RepeatedField + */ + public function getIpAddresses() + { + return $this->ip_addresses; + } + + /** + * Contains only valid 32-bit IPv4 addresses or RFC 4291 IPv6 addresses. + * + * Generated from protobuf field repeated string ip_addresses = 4; + * @param string[] $var + * @return $this + */ + public function setIpAddresses($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->ip_addresses = $arr; + + return $this; + } + + /** + * Contains additional subject alternative name values. + * For each custom_san, the `value` field must contain an ASN.1 encoded + * UTF8String. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.X509Extension custom_sans = 5; + * @return RepeatedField<\Google\Cloud\Security\PrivateCA\V1\X509Extension> + */ + public function getCustomSans() + { + return $this->custom_sans; + } + + /** + * Contains additional subject alternative name values. + * For each custom_san, the `value` field must contain an ASN.1 encoded + * UTF8String. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.X509Extension custom_sans = 5; + * @param \Google\Cloud\Security\PrivateCA\V1\X509Extension[] $var + * @return $this + */ + public function setCustomSans($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Security\PrivateCA\V1\X509Extension::class); + $this->custom_sans = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/SubjectRequestMode.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/SubjectRequestMode.php new file mode 100644 index 000000000000..5932c585535f --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/SubjectRequestMode.php @@ -0,0 +1,96 @@ +google.cloud.security.privateca.v1.SubjectRequestMode + */ +class SubjectRequestMode +{ + /** + * Not specified. + * + * Generated from protobuf enum SUBJECT_REQUEST_MODE_UNSPECIFIED = 0; + */ + const SUBJECT_REQUEST_MODE_UNSPECIFIED = 0; + /** + * The default mode used in most cases. Indicates that the certificate's + * [Subject][google.cloud.security.privateca.v1.Subject] and/or + * [SubjectAltNames][google.cloud.security.privateca.v1.SubjectAltNames] are + * specified in the certificate request. This mode requires the caller to have + * the `privateca.certificates.create` permission. + * + * Generated from protobuf enum DEFAULT = 1; + */ + const PBDEFAULT = 1; + /** + * A mode used to get an accurate representation of the Subject + * field's distinguished name. Indicates that the certificate's + * [Subject][google.cloud.security.privateca.v1.Subject] and/or + * [SubjectAltNames][google.cloud.security.privateca.v1.SubjectAltNames] are + * specified in the certificate request. When parsing a PEM CSR this mode will + * maintain the sequence of RDNs found in the CSR's subject field in the + * issued [Certificate][google.cloud.security.privateca.v1.Certificate]. This + * mode requires the caller to have the `privateca.certificates.create` + * permission. + * + * Generated from protobuf enum RDN_SEQUENCE = 3; + */ + const RDN_SEQUENCE = 3; + /** + * A mode reserved for special cases. Indicates that the certificate should + * have one SPIFFE + * [SubjectAltNames][google.cloud.security.privateca.v1.SubjectAltNames] set + * by the service based on the caller's identity. This mode will ignore any + * explicitly specified [Subject][google.cloud.security.privateca.v1.Subject] + * and/or + * [SubjectAltNames][google.cloud.security.privateca.v1.SubjectAltNames] in + * the certificate request. This mode requires the caller to have the + * `privateca.certificates.createForSelf` permission. + * + * Generated from protobuf enum REFLECTED_SPIFFE = 2; + */ + const REFLECTED_SPIFFE = 2; + + private static $valueToName = [ + self::SUBJECT_REQUEST_MODE_UNSPECIFIED => 'SUBJECT_REQUEST_MODE_UNSPECIFIED', + self::PBDEFAULT => 'DEFAULT', + self::RDN_SEQUENCE => 'RDN_SEQUENCE', + self::REFLECTED_SPIFFE => 'REFLECTED_SPIFFE', + ]; + + 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); + } +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/SubordinateConfig.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/SubordinateConfig.php new file mode 100644 index 000000000000..364e925c0b05 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/SubordinateConfig.php @@ -0,0 +1,135 @@ +google.cloud.security.privateca.v1.SubordinateConfig + */ +class SubordinateConfig extends \Google\Protobuf\Internal\Message +{ + protected $subordinate_config; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $certificate_authority + * Required. This can refer to a + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * that was used to create a subordinate + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. + * This field is used for information and usability purposes only. The + * resource name is in the format + * `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. + * @type \Google\Cloud\Security\PrivateCA\V1\SubordinateConfig\SubordinateConfigChain $pem_issuer_chain + * Required. Contains the PEM certificate chain for the issuers of this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority], + * but not pem certificate for this CA itself. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * Required. This can refer to a + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * that was used to create a subordinate + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. + * This field is used for information and usability purposes only. The + * resource name is in the format + * `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. + * + * Generated from protobuf field string certificate_authority = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getCertificateAuthority() + { + return $this->readOneof(1); + } + + public function hasCertificateAuthority() + { + return $this->hasOneof(1); + } + + /** + * Required. This can refer to a + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * that was used to create a subordinate + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. + * This field is used for information and usability purposes only. The + * resource name is in the format + * `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. + * + * Generated from protobuf field string certificate_authority = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setCertificateAuthority($var) + { + GPBUtil::checkString($var, True); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * Required. Contains the PEM certificate chain for the issuers of this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority], + * but not pem certificate for this CA itself. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.SubordinateConfig.SubordinateConfigChain pem_issuer_chain = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Security\PrivateCA\V1\SubordinateConfig\SubordinateConfigChain|null + */ + public function getPemIssuerChain() + { + return $this->readOneof(2); + } + + public function hasPemIssuerChain() + { + return $this->hasOneof(2); + } + + /** + * Required. Contains the PEM certificate chain for the issuers of this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority], + * but not pem certificate for this CA itself. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.SubordinateConfig.SubordinateConfigChain pem_issuer_chain = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Security\PrivateCA\V1\SubordinateConfig\SubordinateConfigChain $var + * @return $this + */ + public function setPemIssuerChain($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\SubordinateConfig\SubordinateConfigChain::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * @return string + */ + public function getSubordinateConfig() + { + return $this->whichOneof("subordinate_config"); + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/SubordinateConfig/SubordinateConfigChain.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/SubordinateConfig/SubordinateConfigChain.php new file mode 100644 index 000000000000..107fc5682746 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/SubordinateConfig/SubordinateConfigChain.php @@ -0,0 +1,68 @@ +google.cloud.security.privateca.v1.SubordinateConfig.SubordinateConfigChain + */ +class SubordinateConfigChain extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Expected to be in leaf-to-root order according to RFC 5246. + * + * Generated from protobuf field repeated string pem_certificates = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + private $pem_certificates; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string[] $pem_certificates + * Required. Expected to be in leaf-to-root order according to RFC 5246. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * Required. Expected to be in leaf-to-root order according to RFC 5246. + * + * Generated from protobuf field repeated string pem_certificates = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return RepeatedField + */ + public function getPemCertificates() + { + return $this->pem_certificates; + } + + /** + * Required. Expected to be in leaf-to-root order according to RFC 5246. + * + * Generated from protobuf field repeated string pem_certificates = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param string[] $var + * @return $this + */ + public function setPemCertificates($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->pem_certificates = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UndeleteCertificateAuthorityRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UndeleteCertificateAuthorityRequest.php new file mode 100644 index 000000000000..d168251dde62 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UndeleteCertificateAuthorityRequest.php @@ -0,0 +1,166 @@ +google.cloud.security.privateca.v1.UndeleteCertificateAuthorityRequest + */ +class UndeleteCertificateAuthorityRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name for this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * Optional. An 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { + */ + protected $request_id = ''; + + /** + * @param string $name Required. The resource name for this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the format `projects/*/locations/*/caPools/*/certificateAuthorities/*`. Please see + * {@see CertificateAuthorityServiceClient::certificateAuthorityName()} for help formatting this field. + * + * @return \Google\Cloud\Security\PrivateCA\V1\UndeleteCertificateAuthorityRequest + * + * @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 for this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. + * @type string $request_id + * Optional. An 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\Security\Privateca\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name for this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. + * + * 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 for this + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. + * + * 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 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { + * @return string + */ + public function getRequestId() + { + return $this->request_id; + } + + /** + * Optional. An 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { + * @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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UpdateCaPoolRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UpdateCaPoolRequest.php new file mode 100644 index 000000000000..0114b1f48dff --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UpdateCaPoolRequest.php @@ -0,0 +1,216 @@ +google.cloud.security.privateca.v1.UpdateCaPoolRequest + */ +class UpdateCaPoolRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. [CaPool][google.cloud.security.privateca.v1.CaPool] with updated + * values. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool ca_pool = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $ca_pool = null; + /** + * Required. A list of fields to be updated in this request. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $update_mask = null; + /** + * Optional. An 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 = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { + */ + protected $request_id = ''; + + /** + * @param \Google\Cloud\Security\PrivateCA\V1\CaPool $caPool Required. [CaPool][google.cloud.security.privateca.v1.CaPool] with updated + * values. + * @param \Google\Protobuf\FieldMask $updateMask Required. A list of fields to be updated in this request. + * + * @return \Google\Cloud\Security\PrivateCA\V1\UpdateCaPoolRequest + * + * @experimental + */ + public static function build(\Google\Cloud\Security\PrivateCA\V1\CaPool $caPool, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setCaPool($caPool) + ->setUpdateMask($updateMask); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Security\PrivateCA\V1\CaPool $ca_pool + * Required. [CaPool][google.cloud.security.privateca.v1.CaPool] with updated + * values. + * @type \Google\Protobuf\FieldMask $update_mask + * Required. A list of fields to be updated in this request. + * @type string $request_id + * Optional. An 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\Security\Privateca\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Required. [CaPool][google.cloud.security.privateca.v1.CaPool] with updated + * values. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool ca_pool = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Security\PrivateCA\V1\CaPool|null + */ + public function getCaPool() + { + return $this->ca_pool; + } + + public function hasCaPool() + { + return isset($this->ca_pool); + } + + public function clearCaPool() + { + unset($this->ca_pool); + } + + /** + * Required. [CaPool][google.cloud.security.privateca.v1.CaPool] with updated + * values. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool ca_pool = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Security\PrivateCA\V1\CaPool $var + * @return $this + */ + public function setCaPool($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CaPool::class); + $this->ca_pool = $var; + + return $this; + } + + /** + * Required. A list of fields to be updated in this request. + * + * 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. A list of fields to be updated in this request. + * + * 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; + } + + /** + * Optional. An 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 = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { + * @return string + */ + public function getRequestId() + { + return $this->request_id; + } + + /** + * Optional. An 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 = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { + * @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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UpdateCertificateAuthorityRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UpdateCertificateAuthorityRequest.php new file mode 100644 index 000000000000..5af30051cf4d --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UpdateCertificateAuthorityRequest.php @@ -0,0 +1,221 @@ +google.cloud.security.privateca.v1.UpdateCertificateAuthorityRequest + */ +class UpdateCertificateAuthorityRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * with updated values. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority certificate_authority = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $certificate_authority = null; + /** + * Required. A list of fields to be updated in this request. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $update_mask = null; + /** + * Optional. An 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 = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { + */ + protected $request_id = ''; + + /** + * @param \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority $certificateAuthority Required. + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * with updated values. + * @param \Google\Protobuf\FieldMask $updateMask Required. A list of fields to be updated in this request. + * + * @return \Google\Cloud\Security\PrivateCA\V1\UpdateCertificateAuthorityRequest + * + * @experimental + */ + public static function build(\Google\Cloud\Security\PrivateCA\V1\CertificateAuthority $certificateAuthority, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setCertificateAuthority($certificateAuthority) + ->setUpdateMask($updateMask); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority $certificate_authority + * Required. + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * with updated values. + * @type \Google\Protobuf\FieldMask $update_mask + * Required. A list of fields to be updated in this request. + * @type string $request_id + * Optional. An 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\Security\Privateca\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Required. + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * with updated values. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority certificate_authority = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority|null + */ + public function getCertificateAuthority() + { + return $this->certificate_authority; + } + + public function hasCertificateAuthority() + { + return isset($this->certificate_authority); + } + + public function clearCertificateAuthority() + { + unset($this->certificate_authority); + } + + /** + * Required. + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * with updated values. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority certificate_authority = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority $var + * @return $this + */ + public function setCertificateAuthority($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority::class); + $this->certificate_authority = $var; + + return $this; + } + + /** + * Required. A list of fields to be updated in this request. + * + * 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. A list of fields to be updated in this request. + * + * 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; + } + + /** + * Optional. An 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 = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { + * @return string + */ + public function getRequestId() + { + return $this->request_id; + } + + /** + * Optional. An 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 = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { + * @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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UpdateCertificateRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UpdateCertificateRequest.php new file mode 100644 index 000000000000..96118eec5794 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UpdateCertificateRequest.php @@ -0,0 +1,216 @@ +google.cloud.security.privateca.v1.UpdateCertificateRequest + */ +class UpdateCertificateRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. [Certificate][google.cloud.security.privateca.v1.Certificate] + * with updated values. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.Certificate certificate = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $certificate = null; + /** + * Required. A list of fields to be updated in this request. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $update_mask = null; + /** + * Optional. An 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $request_id = ''; + + /** + * @param \Google\Cloud\Security\PrivateCA\V1\Certificate $certificate Required. [Certificate][google.cloud.security.privateca.v1.Certificate] + * with updated values. + * @param \Google\Protobuf\FieldMask $updateMask Required. A list of fields to be updated in this request. + * + * @return \Google\Cloud\Security\PrivateCA\V1\UpdateCertificateRequest + * + * @experimental + */ + public static function build(\Google\Cloud\Security\PrivateCA\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\Security\PrivateCA\V1\Certificate $certificate + * Required. [Certificate][google.cloud.security.privateca.v1.Certificate] + * with updated values. + * @type \Google\Protobuf\FieldMask $update_mask + * Required. A list of fields to be updated in this request. + * @type string $request_id + * Optional. An 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\Security\Privateca\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Required. [Certificate][google.cloud.security.privateca.v1.Certificate] + * with updated values. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.Certificate certificate = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Security\PrivateCA\V1\Certificate|null + */ + public function getCertificate() + { + return $this->certificate; + } + + public function hasCertificate() + { + return isset($this->certificate); + } + + public function clearCertificate() + { + unset($this->certificate); + } + + /** + * Required. [Certificate][google.cloud.security.privateca.v1.Certificate] + * with updated values. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.Certificate certificate = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Security\PrivateCA\V1\Certificate $var + * @return $this + */ + public function setCertificate($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\Certificate::class); + $this->certificate = $var; + + return $this; + } + + /** + * Required. A list of fields to be updated in this request. + * + * 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. A list of fields to be updated in this request. + * + * 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; + } + + /** + * Optional. An 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getRequestId() + { + return $this->request_id; + } + + /** + * Optional. An 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 = 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; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UpdateCertificateRevocationListRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UpdateCertificateRevocationListRequest.php new file mode 100644 index 000000000000..efb8dcf26ca0 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UpdateCertificateRevocationListRequest.php @@ -0,0 +1,221 @@ +google.cloud.security.privateca.v1.UpdateCertificateRevocationListRequest + */ +class UpdateCertificateRevocationListRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. + * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] + * with updated values. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateRevocationList certificate_revocation_list = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $certificate_revocation_list = null; + /** + * Required. A list of fields to be updated in this request. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $update_mask = null; + /** + * Optional. An 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $request_id = ''; + + /** + * @param \Google\Cloud\Security\PrivateCA\V1\CertificateRevocationList $certificateRevocationList Required. + * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] + * with updated values. + * @param \Google\Protobuf\FieldMask $updateMask Required. A list of fields to be updated in this request. + * + * @return \Google\Cloud\Security\PrivateCA\V1\UpdateCertificateRevocationListRequest + * + * @experimental + */ + public static function build(\Google\Cloud\Security\PrivateCA\V1\CertificateRevocationList $certificateRevocationList, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setCertificateRevocationList($certificateRevocationList) + ->setUpdateMask($updateMask); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Security\PrivateCA\V1\CertificateRevocationList $certificate_revocation_list + * Required. + * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] + * with updated values. + * @type \Google\Protobuf\FieldMask $update_mask + * Required. A list of fields to be updated in this request. + * @type string $request_id + * Optional. An 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\Security\Privateca\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Required. + * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] + * with updated values. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateRevocationList certificate_revocation_list = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Security\PrivateCA\V1\CertificateRevocationList|null + */ + public function getCertificateRevocationList() + { + return $this->certificate_revocation_list; + } + + public function hasCertificateRevocationList() + { + return isset($this->certificate_revocation_list); + } + + public function clearCertificateRevocationList() + { + unset($this->certificate_revocation_list); + } + + /** + * Required. + * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] + * with updated values. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateRevocationList certificate_revocation_list = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Security\PrivateCA\V1\CertificateRevocationList $var + * @return $this + */ + public function setCertificateRevocationList($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CertificateRevocationList::class); + $this->certificate_revocation_list = $var; + + return $this; + } + + /** + * Required. A list of fields to be updated in this request. + * + * 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. A list of fields to be updated in this request. + * + * 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; + } + + /** + * Optional. An 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getRequestId() + { + return $this->request_id; + } + + /** + * Optional. An 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 = 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; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UpdateCertificateTemplateRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UpdateCertificateTemplateRequest.php new file mode 100644 index 000000000000..ce213554b5c9 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UpdateCertificateTemplateRequest.php @@ -0,0 +1,221 @@ +google.cloud.security.privateca.v1.UpdateCertificateTemplateRequest + */ +class UpdateCertificateTemplateRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * with updated values. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateTemplate certificate_template = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $certificate_template = null; + /** + * Required. A list of fields to be updated in this request. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $update_mask = null; + /** + * Optional. An 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 = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { + */ + protected $request_id = ''; + + /** + * @param \Google\Cloud\Security\PrivateCA\V1\CertificateTemplate $certificateTemplate Required. + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * with updated values. + * @param \Google\Protobuf\FieldMask $updateMask Required. A list of fields to be updated in this request. + * + * @return \Google\Cloud\Security\PrivateCA\V1\UpdateCertificateTemplateRequest + * + * @experimental + */ + public static function build(\Google\Cloud\Security\PrivateCA\V1\CertificateTemplate $certificateTemplate, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setCertificateTemplate($certificateTemplate) + ->setUpdateMask($updateMask); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Security\PrivateCA\V1\CertificateTemplate $certificate_template + * Required. + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * with updated values. + * @type \Google\Protobuf\FieldMask $update_mask + * Required. A list of fields to be updated in this request. + * @type string $request_id + * Optional. An 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\Security\Privateca\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Required. + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * with updated values. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateTemplate certificate_template = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Security\PrivateCA\V1\CertificateTemplate|null + */ + public function getCertificateTemplate() + { + return $this->certificate_template; + } + + public function hasCertificateTemplate() + { + return isset($this->certificate_template); + } + + public function clearCertificateTemplate() + { + unset($this->certificate_template); + } + + /** + * Required. + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * with updated values. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateTemplate certificate_template = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Security\PrivateCA\V1\CertificateTemplate $var + * @return $this + */ + public function setCertificateTemplate($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CertificateTemplate::class); + $this->certificate_template = $var; + + return $this; + } + + /** + * Required. A list of fields to be updated in this request. + * + * 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. A list of fields to be updated in this request. + * + * 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; + } + + /** + * Optional. An 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 = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { + * @return string + */ + public function getRequestId() + { + return $this->request_id; + } + + /** + * Optional. An 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 = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { + * @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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/X509Extension.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/X509Extension.php new file mode 100644 index 000000000000..c98cc052fe79 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/X509Extension.php @@ -0,0 +1,155 @@ +google.cloud.security.privateca.v1.X509Extension + */ +class X509Extension extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The OID for this X.509 extension. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.ObjectId object_id = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $object_id = null; + /** + * Optional. Indicates whether or not this extension is critical (i.e., if the + * client does not know how to handle this extension, the client should + * consider this to be an error). + * + * Generated from protobuf field bool critical = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $critical = false; + /** + * Required. The value of this X.509 extension. + * + * Generated from protobuf field bytes value = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $value = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Security\PrivateCA\V1\ObjectId $object_id + * Required. The OID for this X.509 extension. + * @type bool $critical + * Optional. Indicates whether or not this extension is critical (i.e., if the + * client does not know how to handle this extension, the client should + * consider this to be an error). + * @type string $value + * Required. The value of this X.509 extension. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * Required. The OID for this X.509 extension. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.ObjectId object_id = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Security\PrivateCA\V1\ObjectId|null + */ + public function getObjectId() + { + return $this->object_id; + } + + public function hasObjectId() + { + return isset($this->object_id); + } + + public function clearObjectId() + { + unset($this->object_id); + } + + /** + * Required. The OID for this X.509 extension. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.ObjectId object_id = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Security\PrivateCA\V1\ObjectId $var + * @return $this + */ + public function setObjectId($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\ObjectId::class); + $this->object_id = $var; + + return $this; + } + + /** + * Optional. Indicates whether or not this extension is critical (i.e., if the + * client does not know how to handle this extension, the client should + * consider this to be an error). + * + * Generated from protobuf field bool critical = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return bool + */ + public function getCritical() + { + return $this->critical; + } + + /** + * Optional. Indicates whether or not this extension is critical (i.e., if the + * client does not know how to handle this extension, the client should + * consider this to be an error). + * + * Generated from protobuf field bool critical = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @param bool $var + * @return $this + */ + public function setCritical($var) + { + GPBUtil::checkBool($var); + $this->critical = $var; + + return $this; + } + + /** + * Required. The value of this X.509 extension. + * + * Generated from protobuf field bytes value = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getValue() + { + return $this->value; + } + + /** + * Required. The value of this X.509 extension. + * + * Generated from protobuf field bytes value = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setValue($var) + { + GPBUtil::checkString($var, False); + $this->value = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/X509Parameters.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/X509Parameters.php new file mode 100644 index 000000000000..a8abd4b0a953 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/X509Parameters.php @@ -0,0 +1,302 @@ +google.cloud.security.privateca.v1.X509Parameters + */ +class X509Parameters extends \Google\Protobuf\Internal\Message +{ + /** + * Optional. Indicates the intended use for keys that correspond to a + * certificate. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.KeyUsage key_usage = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $key_usage = null; + /** + * Optional. Describes options in this + * [X509Parameters][google.cloud.security.privateca.v1.X509Parameters] that + * are relevant in a CA certificate. If not specified, a default basic + * constraints extension with `is_ca=false` will be added for leaf + * certificates. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.X509Parameters.CaOptions ca_options = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $ca_options = null; + /** + * Optional. Describes the X.509 certificate policy object identifiers, per + * https://tools.ietf.org/html/rfc5280#section-4.2.1.4. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.ObjectId policy_ids = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + private $policy_ids; + /** + * Optional. Describes Online Certificate Status Protocol (OCSP) endpoint + * addresses that appear in the "Authority Information Access" extension in + * the certificate. + * + * Generated from protobuf field repeated string aia_ocsp_servers = 4 [(.google.api.field_behavior) = OPTIONAL]; + */ + private $aia_ocsp_servers; + /** + * Optional. Describes the X.509 name constraints extension. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.X509Parameters.NameConstraints name_constraints = 6 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $name_constraints = null; + /** + * Optional. Describes custom X.509 extensions. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.X509Extension additional_extensions = 5 [(.google.api.field_behavior) = OPTIONAL]; + */ + private $additional_extensions; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Security\PrivateCA\V1\KeyUsage $key_usage + * Optional. Indicates the intended use for keys that correspond to a + * certificate. + * @type \Google\Cloud\Security\PrivateCA\V1\X509Parameters\CaOptions $ca_options + * Optional. Describes options in this + * [X509Parameters][google.cloud.security.privateca.v1.X509Parameters] that + * are relevant in a CA certificate. If not specified, a default basic + * constraints extension with `is_ca=false` will be added for leaf + * certificates. + * @type \Google\Cloud\Security\PrivateCA\V1\ObjectId[] $policy_ids + * Optional. Describes the X.509 certificate policy object identifiers, per + * https://tools.ietf.org/html/rfc5280#section-4.2.1.4. + * @type string[] $aia_ocsp_servers + * Optional. Describes Online Certificate Status Protocol (OCSP) endpoint + * addresses that appear in the "Authority Information Access" extension in + * the certificate. + * @type \Google\Cloud\Security\PrivateCA\V1\X509Parameters\NameConstraints $name_constraints + * Optional. Describes the X.509 name constraints extension. + * @type \Google\Cloud\Security\PrivateCA\V1\X509Extension[] $additional_extensions + * Optional. Describes custom X.509 extensions. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * Optional. Indicates the intended use for keys that correspond to a + * certificate. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.KeyUsage key_usage = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\Security\PrivateCA\V1\KeyUsage|null + */ + public function getKeyUsage() + { + return $this->key_usage; + } + + public function hasKeyUsage() + { + return isset($this->key_usage); + } + + public function clearKeyUsage() + { + unset($this->key_usage); + } + + /** + * Optional. Indicates the intended use for keys that correspond to a + * certificate. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.KeyUsage key_usage = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\Security\PrivateCA\V1\KeyUsage $var + * @return $this + */ + public function setKeyUsage($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\KeyUsage::class); + $this->key_usage = $var; + + return $this; + } + + /** + * Optional. Describes options in this + * [X509Parameters][google.cloud.security.privateca.v1.X509Parameters] that + * are relevant in a CA certificate. If not specified, a default basic + * constraints extension with `is_ca=false` will be added for leaf + * certificates. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.X509Parameters.CaOptions ca_options = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\Security\PrivateCA\V1\X509Parameters\CaOptions|null + */ + public function getCaOptions() + { + return $this->ca_options; + } + + public function hasCaOptions() + { + return isset($this->ca_options); + } + + public function clearCaOptions() + { + unset($this->ca_options); + } + + /** + * Optional. Describes options in this + * [X509Parameters][google.cloud.security.privateca.v1.X509Parameters] that + * are relevant in a CA certificate. If not specified, a default basic + * constraints extension with `is_ca=false` will be added for leaf + * certificates. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.X509Parameters.CaOptions ca_options = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\Security\PrivateCA\V1\X509Parameters\CaOptions $var + * @return $this + */ + public function setCaOptions($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\X509Parameters\CaOptions::class); + $this->ca_options = $var; + + return $this; + } + + /** + * Optional. Describes the X.509 certificate policy object identifiers, per + * https://tools.ietf.org/html/rfc5280#section-4.2.1.4. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.ObjectId policy_ids = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return RepeatedField<\Google\Cloud\Security\PrivateCA\V1\ObjectId> + */ + public function getPolicyIds() + { + return $this->policy_ids; + } + + /** + * Optional. Describes the X.509 certificate policy object identifiers, per + * https://tools.ietf.org/html/rfc5280#section-4.2.1.4. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.ObjectId policy_ids = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\Security\PrivateCA\V1\ObjectId[] $var + * @return $this + */ + public function setPolicyIds($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Security\PrivateCA\V1\ObjectId::class); + $this->policy_ids = $arr; + + return $this; + } + + /** + * Optional. Describes Online Certificate Status Protocol (OCSP) endpoint + * addresses that appear in the "Authority Information Access" extension in + * the certificate. + * + * Generated from protobuf field repeated string aia_ocsp_servers = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @return RepeatedField + */ + public function getAiaOcspServers() + { + return $this->aia_ocsp_servers; + } + + /** + * Optional. Describes Online Certificate Status Protocol (OCSP) endpoint + * addresses that appear in the "Authority Information Access" extension in + * the certificate. + * + * Generated from protobuf field repeated string aia_ocsp_servers = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @param string[] $var + * @return $this + */ + public function setAiaOcspServers($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->aia_ocsp_servers = $arr; + + return $this; + } + + /** + * Optional. Describes the X.509 name constraints extension. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.X509Parameters.NameConstraints name_constraints = 6 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\Security\PrivateCA\V1\X509Parameters\NameConstraints|null + */ + public function getNameConstraints() + { + return $this->name_constraints; + } + + public function hasNameConstraints() + { + return isset($this->name_constraints); + } + + public function clearNameConstraints() + { + unset($this->name_constraints); + } + + /** + * Optional. Describes the X.509 name constraints extension. + * + * Generated from protobuf field .google.cloud.security.privateca.v1.X509Parameters.NameConstraints name_constraints = 6 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\Security\PrivateCA\V1\X509Parameters\NameConstraints $var + * @return $this + */ + public function setNameConstraints($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\X509Parameters\NameConstraints::class); + $this->name_constraints = $var; + + return $this; + } + + /** + * Optional. Describes custom X.509 extensions. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.X509Extension additional_extensions = 5 [(.google.api.field_behavior) = OPTIONAL]; + * @return RepeatedField<\Google\Cloud\Security\PrivateCA\V1\X509Extension> + */ + public function getAdditionalExtensions() + { + return $this->additional_extensions; + } + + /** + * Optional. Describes custom X.509 extensions. + * + * Generated from protobuf field repeated .google.cloud.security.privateca.v1.X509Extension additional_extensions = 5 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\Security\PrivateCA\V1\X509Extension[] $var + * @return $this + */ + public function setAdditionalExtensions($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Security\PrivateCA\V1\X509Extension::class); + $this->additional_extensions = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/X509Parameters/CaOptions.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/X509Parameters/CaOptions.php new file mode 100644 index 000000000000..8fc67a2a4d60 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/X509Parameters/CaOptions.php @@ -0,0 +1,146 @@ +google.cloud.security.privateca.v1.X509Parameters.CaOptions + */ +class CaOptions extends \Google\Protobuf\Internal\Message +{ + /** + * Optional. Refers to the "CA" boolean field in the X.509 extension. + * When this value is missing, the basic constraints extension will be + * omitted from the certificate. + * + * Generated from protobuf field optional bool is_ca = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $is_ca = null; + /** + * Optional. Refers to the path length constraint field in the X.509 + * extension. For a CA certificate, this value describes the depth of + * subordinate CA certificates that are allowed. If this value is less than + * 0, the request will fail. If this value is missing, the max path length + * will be omitted from the certificate. + * + * Generated from protobuf field optional int32 max_issuer_path_length = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $max_issuer_path_length = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type bool $is_ca + * Optional. Refers to the "CA" boolean field in the X.509 extension. + * When this value is missing, the basic constraints extension will be + * omitted from the certificate. + * @type int $max_issuer_path_length + * Optional. Refers to the path length constraint field in the X.509 + * extension. For a CA certificate, this value describes the depth of + * subordinate CA certificates that are allowed. If this value is less than + * 0, the request will fail. If this value is missing, the max path length + * will be omitted from the certificate. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * Optional. Refers to the "CA" boolean field in the X.509 extension. + * When this value is missing, the basic constraints extension will be + * omitted from the certificate. + * + * Generated from protobuf field optional bool is_ca = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @return bool + */ + public function getIsCa() + { + return isset($this->is_ca) ? $this->is_ca : false; + } + + public function hasIsCa() + { + return isset($this->is_ca); + } + + public function clearIsCa() + { + unset($this->is_ca); + } + + /** + * Optional. Refers to the "CA" boolean field in the X.509 extension. + * When this value is missing, the basic constraints extension will be + * omitted from the certificate. + * + * Generated from protobuf field optional bool is_ca = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @param bool $var + * @return $this + */ + public function setIsCa($var) + { + GPBUtil::checkBool($var); + $this->is_ca = $var; + + return $this; + } + + /** + * Optional. Refers to the path length constraint field in the X.509 + * extension. For a CA certificate, this value describes the depth of + * subordinate CA certificates that are allowed. If this value is less than + * 0, the request will fail. If this value is missing, the max path length + * will be omitted from the certificate. + * + * Generated from protobuf field optional int32 max_issuer_path_length = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return int + */ + public function getMaxIssuerPathLength() + { + return isset($this->max_issuer_path_length) ? $this->max_issuer_path_length : 0; + } + + public function hasMaxIssuerPathLength() + { + return isset($this->max_issuer_path_length); + } + + public function clearMaxIssuerPathLength() + { + unset($this->max_issuer_path_length); + } + + /** + * Optional. Refers to the path length constraint field in the X.509 + * extension. For a CA certificate, this value describes the depth of + * subordinate CA certificates that are allowed. If this value is less than + * 0, the request will fail. If this value is missing, the max path length + * will be omitted from the certificate. + * + * Generated from protobuf field optional int32 max_issuer_path_length = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @param int $var + * @return $this + */ + public function setMaxIssuerPathLength($var) + { + GPBUtil::checkInt32($var); + $this->max_issuer_path_length = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/X509Parameters/NameConstraints.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/X509Parameters/NameConstraints.php new file mode 100644 index 000000000000..0c345c079fd1 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/X509Parameters/NameConstraints.php @@ -0,0 +1,436 @@ +google.cloud.security.privateca.v1.X509Parameters.NameConstraints + */ +class NameConstraints extends \Google\Protobuf\Internal\Message +{ + /** + * Indicates whether or not the name constraints are marked critical. + * + * Generated from protobuf field bool critical = 1; + */ + protected $critical = false; + /** + * Contains permitted DNS names. Any DNS name that can be + * constructed by simply adding zero or more labels to + * the left-hand side of the name satisfies the name constraint. + * For example, `example.com`, `www.example.com`, `www.sub.example.com` + * would satisfy `example.com` while `example1.com` does not. + * + * Generated from protobuf field repeated string permitted_dns_names = 2; + */ + private $permitted_dns_names; + /** + * Contains excluded DNS names. Any DNS name that can be + * constructed by simply adding zero or more labels to + * the left-hand side of the name satisfies the name constraint. + * For example, `example.com`, `www.example.com`, `www.sub.example.com` + * would satisfy `example.com` while `example1.com` does not. + * + * Generated from protobuf field repeated string excluded_dns_names = 3; + */ + private $excluded_dns_names; + /** + * Contains the permitted IP ranges. For IPv4 addresses, the ranges + * are expressed using CIDR notation as specified in RFC 4632. + * For IPv6 addresses, the ranges are expressed in similar encoding as IPv4 + * addresses. + * + * Generated from protobuf field repeated string permitted_ip_ranges = 4; + */ + private $permitted_ip_ranges; + /** + * Contains the excluded IP ranges. For IPv4 addresses, the ranges + * are expressed using CIDR notation as specified in RFC 4632. + * For IPv6 addresses, the ranges are expressed in similar encoding as IPv4 + * addresses. + * + * Generated from protobuf field repeated string excluded_ip_ranges = 5; + */ + private $excluded_ip_ranges; + /** + * Contains the permitted email addresses. The value can be a particular + * email address, a hostname to indicate all email addresses on that host or + * a domain with a leading period (e.g. `.example.com`) to indicate + * all email addresses in that domain. + * + * Generated from protobuf field repeated string permitted_email_addresses = 6; + */ + private $permitted_email_addresses; + /** + * Contains the excluded email addresses. The value can be a particular + * email address, a hostname to indicate all email addresses on that host or + * a domain with a leading period (e.g. `.example.com`) to indicate + * all email addresses in that domain. + * + * Generated from protobuf field repeated string excluded_email_addresses = 7; + */ + private $excluded_email_addresses; + /** + * Contains the permitted URIs that apply to the host part of the name. + * The value can be a hostname or a domain with a + * leading period (like `.example.com`) + * + * Generated from protobuf field repeated string permitted_uris = 8; + */ + private $permitted_uris; + /** + * Contains the excluded URIs that apply to the host part of the name. + * The value can be a hostname or a domain with a + * leading period (like `.example.com`) + * + * Generated from protobuf field repeated string excluded_uris = 9; + */ + private $excluded_uris; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type bool $critical + * Indicates whether or not the name constraints are marked critical. + * @type string[] $permitted_dns_names + * Contains permitted DNS names. Any DNS name that can be + * constructed by simply adding zero or more labels to + * the left-hand side of the name satisfies the name constraint. + * For example, `example.com`, `www.example.com`, `www.sub.example.com` + * would satisfy `example.com` while `example1.com` does not. + * @type string[] $excluded_dns_names + * Contains excluded DNS names. Any DNS name that can be + * constructed by simply adding zero or more labels to + * the left-hand side of the name satisfies the name constraint. + * For example, `example.com`, `www.example.com`, `www.sub.example.com` + * would satisfy `example.com` while `example1.com` does not. + * @type string[] $permitted_ip_ranges + * Contains the permitted IP ranges. For IPv4 addresses, the ranges + * are expressed using CIDR notation as specified in RFC 4632. + * For IPv6 addresses, the ranges are expressed in similar encoding as IPv4 + * addresses. + * @type string[] $excluded_ip_ranges + * Contains the excluded IP ranges. For IPv4 addresses, the ranges + * are expressed using CIDR notation as specified in RFC 4632. + * For IPv6 addresses, the ranges are expressed in similar encoding as IPv4 + * addresses. + * @type string[] $permitted_email_addresses + * Contains the permitted email addresses. The value can be a particular + * email address, a hostname to indicate all email addresses on that host or + * a domain with a leading period (e.g. `.example.com`) to indicate + * all email addresses in that domain. + * @type string[] $excluded_email_addresses + * Contains the excluded email addresses. The value can be a particular + * email address, a hostname to indicate all email addresses on that host or + * a domain with a leading period (e.g. `.example.com`) to indicate + * all email addresses in that domain. + * @type string[] $permitted_uris + * Contains the permitted URIs that apply to the host part of the name. + * The value can be a hostname or a domain with a + * leading period (like `.example.com`) + * @type string[] $excluded_uris + * Contains the excluded URIs that apply to the host part of the name. + * The value can be a hostname or a domain with a + * leading period (like `.example.com`) + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * Indicates whether or not the name constraints are marked critical. + * + * Generated from protobuf field bool critical = 1; + * @return bool + */ + public function getCritical() + { + return $this->critical; + } + + /** + * Indicates whether or not the name constraints are marked critical. + * + * Generated from protobuf field bool critical = 1; + * @param bool $var + * @return $this + */ + public function setCritical($var) + { + GPBUtil::checkBool($var); + $this->critical = $var; + + return $this; + } + + /** + * Contains permitted DNS names. Any DNS name that can be + * constructed by simply adding zero or more labels to + * the left-hand side of the name satisfies the name constraint. + * For example, `example.com`, `www.example.com`, `www.sub.example.com` + * would satisfy `example.com` while `example1.com` does not. + * + * Generated from protobuf field repeated string permitted_dns_names = 2; + * @return RepeatedField + */ + public function getPermittedDnsNames() + { + return $this->permitted_dns_names; + } + + /** + * Contains permitted DNS names. Any DNS name that can be + * constructed by simply adding zero or more labels to + * the left-hand side of the name satisfies the name constraint. + * For example, `example.com`, `www.example.com`, `www.sub.example.com` + * would satisfy `example.com` while `example1.com` does not. + * + * Generated from protobuf field repeated string permitted_dns_names = 2; + * @param string[] $var + * @return $this + */ + public function setPermittedDnsNames($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->permitted_dns_names = $arr; + + return $this; + } + + /** + * Contains excluded DNS names. Any DNS name that can be + * constructed by simply adding zero or more labels to + * the left-hand side of the name satisfies the name constraint. + * For example, `example.com`, `www.example.com`, `www.sub.example.com` + * would satisfy `example.com` while `example1.com` does not. + * + * Generated from protobuf field repeated string excluded_dns_names = 3; + * @return RepeatedField + */ + public function getExcludedDnsNames() + { + return $this->excluded_dns_names; + } + + /** + * Contains excluded DNS names. Any DNS name that can be + * constructed by simply adding zero or more labels to + * the left-hand side of the name satisfies the name constraint. + * For example, `example.com`, `www.example.com`, `www.sub.example.com` + * would satisfy `example.com` while `example1.com` does not. + * + * Generated from protobuf field repeated string excluded_dns_names = 3; + * @param string[] $var + * @return $this + */ + public function setExcludedDnsNames($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->excluded_dns_names = $arr; + + return $this; + } + + /** + * Contains the permitted IP ranges. For IPv4 addresses, the ranges + * are expressed using CIDR notation as specified in RFC 4632. + * For IPv6 addresses, the ranges are expressed in similar encoding as IPv4 + * addresses. + * + * Generated from protobuf field repeated string permitted_ip_ranges = 4; + * @return RepeatedField + */ + public function getPermittedIpRanges() + { + return $this->permitted_ip_ranges; + } + + /** + * Contains the permitted IP ranges. For IPv4 addresses, the ranges + * are expressed using CIDR notation as specified in RFC 4632. + * For IPv6 addresses, the ranges are expressed in similar encoding as IPv4 + * addresses. + * + * Generated from protobuf field repeated string permitted_ip_ranges = 4; + * @param string[] $var + * @return $this + */ + public function setPermittedIpRanges($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->permitted_ip_ranges = $arr; + + return $this; + } + + /** + * Contains the excluded IP ranges. For IPv4 addresses, the ranges + * are expressed using CIDR notation as specified in RFC 4632. + * For IPv6 addresses, the ranges are expressed in similar encoding as IPv4 + * addresses. + * + * Generated from protobuf field repeated string excluded_ip_ranges = 5; + * @return RepeatedField + */ + public function getExcludedIpRanges() + { + return $this->excluded_ip_ranges; + } + + /** + * Contains the excluded IP ranges. For IPv4 addresses, the ranges + * are expressed using CIDR notation as specified in RFC 4632. + * For IPv6 addresses, the ranges are expressed in similar encoding as IPv4 + * addresses. + * + * Generated from protobuf field repeated string excluded_ip_ranges = 5; + * @param string[] $var + * @return $this + */ + public function setExcludedIpRanges($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->excluded_ip_ranges = $arr; + + return $this; + } + + /** + * Contains the permitted email addresses. The value can be a particular + * email address, a hostname to indicate all email addresses on that host or + * a domain with a leading period (e.g. `.example.com`) to indicate + * all email addresses in that domain. + * + * Generated from protobuf field repeated string permitted_email_addresses = 6; + * @return RepeatedField + */ + public function getPermittedEmailAddresses() + { + return $this->permitted_email_addresses; + } + + /** + * Contains the permitted email addresses. The value can be a particular + * email address, a hostname to indicate all email addresses on that host or + * a domain with a leading period (e.g. `.example.com`) to indicate + * all email addresses in that domain. + * + * Generated from protobuf field repeated string permitted_email_addresses = 6; + * @param string[] $var + * @return $this + */ + public function setPermittedEmailAddresses($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->permitted_email_addresses = $arr; + + return $this; + } + + /** + * Contains the excluded email addresses. The value can be a particular + * email address, a hostname to indicate all email addresses on that host or + * a domain with a leading period (e.g. `.example.com`) to indicate + * all email addresses in that domain. + * + * Generated from protobuf field repeated string excluded_email_addresses = 7; + * @return RepeatedField + */ + public function getExcludedEmailAddresses() + { + return $this->excluded_email_addresses; + } + + /** + * Contains the excluded email addresses. The value can be a particular + * email address, a hostname to indicate all email addresses on that host or + * a domain with a leading period (e.g. `.example.com`) to indicate + * all email addresses in that domain. + * + * Generated from protobuf field repeated string excluded_email_addresses = 7; + * @param string[] $var + * @return $this + */ + public function setExcludedEmailAddresses($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->excluded_email_addresses = $arr; + + return $this; + } + + /** + * Contains the permitted URIs that apply to the host part of the name. + * The value can be a hostname or a domain with a + * leading period (like `.example.com`) + * + * Generated from protobuf field repeated string permitted_uris = 8; + * @return RepeatedField + */ + public function getPermittedUris() + { + return $this->permitted_uris; + } + + /** + * Contains the permitted URIs that apply to the host part of the name. + * The value can be a hostname or a domain with a + * leading period (like `.example.com`) + * + * Generated from protobuf field repeated string permitted_uris = 8; + * @param string[] $var + * @return $this + */ + public function setPermittedUris($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->permitted_uris = $arr; + + return $this; + } + + /** + * Contains the excluded URIs that apply to the host part of the name. + * The value can be a hostname or a domain with a + * leading period (like `.example.com`) + * + * Generated from protobuf field repeated string excluded_uris = 9; + * @return RepeatedField + */ + public function getExcludedUris() + { + return $this->excluded_uris; + } + + /** + * Contains the excluded URIs that apply to the host part of the name. + * The value can be a hostname or a domain with a + * leading period (like `.example.com`) + * + * Generated from protobuf field repeated string excluded_uris = 9; + * @param string[] $var + * @return $this + */ + public function setExcludedUris($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->excluded_uris = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/activate_certificate_authority.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/activate_certificate_authority.php new file mode 100644 index 000000000000..bbe081a50003 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/activate_certificate_authority.php @@ -0,0 +1,128 @@ +setCertificateAuthority($formattedSubordinateConfigCertificateAuthority); + $request = (new ActivateCertificateAuthorityRequest()) + ->setName($formattedName) + ->setPemCaCertificate($pemCaCertificate) + ->setSubordinateConfig($subordinateConfig); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $certificateAuthorityServiceClient->activateCertificateAuthority($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var CertificateAuthority $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 = CertificateAuthorityServiceClient::certificateAuthorityName( + '[PROJECT]', + '[LOCATION]', + '[CA_POOL]', + '[CERTIFICATE_AUTHORITY]' + ); + $pemCaCertificate = '[PEM_CA_CERTIFICATE]'; + $formattedSubordinateConfigCertificateAuthority = CertificateAuthorityServiceClient::certificateAuthorityName( + '[PROJECT]', + '[LOCATION]', + '[CA_POOL]', + '[CERTIFICATE_AUTHORITY]' + ); + + activate_certificate_authority_sample( + $formattedName, + $pemCaCertificate, + $formattedSubordinateConfigCertificateAuthority + ); +} +// [END privateca_v1_generated_CertificateAuthorityService_ActivateCertificateAuthority_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/create_ca_pool.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/create_ca_pool.php new file mode 100644 index 000000000000..4f9f6a31dfa8 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/create_ca_pool.php @@ -0,0 +1,97 @@ +setTier($caPoolTier); + $request = (new CreateCaPoolRequest()) + ->setParent($formattedParent) + ->setCaPoolId($caPoolId) + ->setCaPool($caPool); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $certificateAuthorityServiceClient->createCaPool($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var CaPool $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 = CertificateAuthorityServiceClient::locationName('[PROJECT]', '[LOCATION]'); + $caPoolId = '[CA_POOL_ID]'; + $caPoolTier = Tier::TIER_UNSPECIFIED; + + create_ca_pool_sample($formattedParent, $caPoolId, $caPoolTier); +} +// [END privateca_v1_generated_CertificateAuthorityService_CreateCaPool_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/create_certificate.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/create_certificate.php new file mode 100644 index 000000000000..88eebe7166b1 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/create_certificate.php @@ -0,0 +1,85 @@ +setLifetime($certificateLifetime); + $request = (new CreateCertificateRequest()) + ->setParent($formattedParent) + ->setCertificate($certificate); + + // Call the API and handle any network failures. + try { + /** @var Certificate $response */ + $response = $certificateAuthorityServiceClient->createCertificate($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 = CertificateAuthorityServiceClient::caPoolName( + '[PROJECT]', + '[LOCATION]', + '[CA_POOL]' + ); + + create_certificate_sample($formattedParent); +} +// [END privateca_v1_generated_CertificateAuthorityService_CreateCertificate_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/create_certificate_authority.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/create_certificate_authority.php new file mode 100644 index 000000000000..22be6b3dbb58 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/create_certificate_authority.php @@ -0,0 +1,127 @@ +setSubjectConfig($certificateAuthorityConfigSubjectConfig) + ->setX509Config($certificateAuthorityConfigX509Config); + $certificateAuthorityLifetime = new Duration(); + $certificateAuthorityKeySpec = new KeyVersionSpec(); + $certificateAuthority = (new CertificateAuthority()) + ->setType($certificateAuthorityType) + ->setConfig($certificateAuthorityConfig) + ->setLifetime($certificateAuthorityLifetime) + ->setKeySpec($certificateAuthorityKeySpec); + $request = (new CreateCertificateAuthorityRequest()) + ->setParent($formattedParent) + ->setCertificateAuthorityId($certificateAuthorityId) + ->setCertificateAuthority($certificateAuthority); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $certificateAuthorityServiceClient->createCertificateAuthority($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var CertificateAuthority $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 = CertificateAuthorityServiceClient::caPoolName( + '[PROJECT]', + '[LOCATION]', + '[CA_POOL]' + ); + $certificateAuthorityId = '[CERTIFICATE_AUTHORITY_ID]'; + $certificateAuthorityType = Type::TYPE_UNSPECIFIED; + + create_certificate_authority_sample( + $formattedParent, + $certificateAuthorityId, + $certificateAuthorityType + ); +} +// [END privateca_v1_generated_CertificateAuthorityService_CreateCertificateAuthority_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/create_certificate_template.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/create_certificate_template.php new file mode 100644 index 000000000000..a4199c133d95 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/create_certificate_template.php @@ -0,0 +1,95 @@ +setParent($formattedParent) + ->setCertificateTemplateId($certificateTemplateId) + ->setCertificateTemplate($certificateTemplate); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $certificateAuthorityServiceClient->createCertificateTemplate($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var CertificateTemplate $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 = CertificateAuthorityServiceClient::locationName('[PROJECT]', '[LOCATION]'); + $certificateTemplateId = '[CERTIFICATE_TEMPLATE_ID]'; + + create_certificate_template_sample($formattedParent, $certificateTemplateId); +} +// [END privateca_v1_generated_CertificateAuthorityService_CreateCertificateTemplate_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/delete_ca_pool.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/delete_ca_pool.php new file mode 100644 index 000000000000..5d64cb64a4a2 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/delete_ca_pool.php @@ -0,0 +1,86 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $certificateAuthorityServiceClient->deleteCaPool($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 = CertificateAuthorityServiceClient::caPoolName( + '[PROJECT]', + '[LOCATION]', + '[CA_POOL]' + ); + + delete_ca_pool_sample($formattedName); +} +// [END privateca_v1_generated_CertificateAuthorityService_DeleteCaPool_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/delete_certificate_authority.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/delete_certificate_authority.php new file mode 100644 index 000000000000..c36222e28a75 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/delete_certificate_authority.php @@ -0,0 +1,91 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $certificateAuthorityServiceClient->deleteCertificateAuthority($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var CertificateAuthority $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 = CertificateAuthorityServiceClient::certificateAuthorityName( + '[PROJECT]', + '[LOCATION]', + '[CA_POOL]', + '[CERTIFICATE_AUTHORITY]' + ); + + delete_certificate_authority_sample($formattedName); +} +// [END privateca_v1_generated_CertificateAuthorityService_DeleteCertificateAuthority_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/delete_certificate_template.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/delete_certificate_template.php new file mode 100644 index 000000000000..66874aad02dc --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/delete_certificate_template.php @@ -0,0 +1,87 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $certificateAuthorityServiceClient->deleteCertificateTemplate($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 = CertificateAuthorityServiceClient::certificateTemplateName( + '[PROJECT]', + '[LOCATION]', + '[CERTIFICATE_TEMPLATE]' + ); + + delete_certificate_template_sample($formattedName); +} +// [END privateca_v1_generated_CertificateAuthorityService_DeleteCertificateTemplate_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/disable_certificate_authority.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/disable_certificate_authority.php new file mode 100644 index 000000000000..630c57d7917d --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/disable_certificate_authority.php @@ -0,0 +1,91 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $certificateAuthorityServiceClient->disableCertificateAuthority($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var CertificateAuthority $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 = CertificateAuthorityServiceClient::certificateAuthorityName( + '[PROJECT]', + '[LOCATION]', + '[CA_POOL]', + '[CERTIFICATE_AUTHORITY]' + ); + + disable_certificate_authority_sample($formattedName); +} +// [END privateca_v1_generated_CertificateAuthorityService_DisableCertificateAuthority_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/enable_certificate_authority.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/enable_certificate_authority.php new file mode 100644 index 000000000000..6b04124f2d7d --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/enable_certificate_authority.php @@ -0,0 +1,91 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $certificateAuthorityServiceClient->enableCertificateAuthority($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var CertificateAuthority $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 = CertificateAuthorityServiceClient::certificateAuthorityName( + '[PROJECT]', + '[LOCATION]', + '[CA_POOL]', + '[CERTIFICATE_AUTHORITY]' + ); + + enable_certificate_authority_sample($formattedName); +} +// [END privateca_v1_generated_CertificateAuthorityService_EnableCertificateAuthority_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/fetch_ca_certs.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/fetch_ca_certs.php new file mode 100644 index 000000000000..148de8af991d --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/fetch_ca_certs.php @@ -0,0 +1,80 @@ +setCaPool($formattedCaPool); + + // Call the API and handle any network failures. + try { + /** @var FetchCaCertsResponse $response */ + $response = $certificateAuthorityServiceClient->fetchCaCerts($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 +{ + $formattedCaPool = CertificateAuthorityServiceClient::caPoolName( + '[PROJECT]', + '[LOCATION]', + '[CA_POOL]' + ); + + fetch_ca_certs_sample($formattedCaPool); +} +// [END privateca_v1_generated_CertificateAuthorityService_FetchCaCerts_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/fetch_certificate_authority_csr.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/fetch_certificate_authority_csr.php new file mode 100644 index 000000000000..c864a03ebab3 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/fetch_certificate_authority_csr.php @@ -0,0 +1,88 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var FetchCertificateAuthorityCsrResponse $response */ + $response = $certificateAuthorityServiceClient->fetchCertificateAuthorityCsr($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 = CertificateAuthorityServiceClient::certificateAuthorityName( + '[PROJECT]', + '[LOCATION]', + '[CA_POOL]', + '[CERTIFICATE_AUTHORITY]' + ); + + fetch_certificate_authority_csr_sample($formattedName); +} +// [END privateca_v1_generated_CertificateAuthorityService_FetchCertificateAuthorityCsr_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_ca_pool.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_ca_pool.php new file mode 100644 index 000000000000..d3dfe53a73b8 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_ca_pool.php @@ -0,0 +1,76 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var CaPool $response */ + $response = $certificateAuthorityServiceClient->getCaPool($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 = CertificateAuthorityServiceClient::caPoolName( + '[PROJECT]', + '[LOCATION]', + '[CA_POOL]' + ); + + get_ca_pool_sample($formattedName); +} +// [END privateca_v1_generated_CertificateAuthorityService_GetCaPool_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_certificate.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_certificate.php new file mode 100644 index 000000000000..0065f8f3dbf2 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_certificate.php @@ -0,0 +1,78 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var Certificate $response */ + $response = $certificateAuthorityServiceClient->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 = CertificateAuthorityServiceClient::certificateName( + '[PROJECT]', + '[LOCATION]', + '[CA_POOL]', + '[CERTIFICATE]' + ); + + get_certificate_sample($formattedName); +} +// [END privateca_v1_generated_CertificateAuthorityService_GetCertificate_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_certificate_authority.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_certificate_authority.php new file mode 100644 index 000000000000..cadbdad5326d --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_certificate_authority.php @@ -0,0 +1,80 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var CertificateAuthority $response */ + $response = $certificateAuthorityServiceClient->getCertificateAuthority($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 = CertificateAuthorityServiceClient::certificateAuthorityName( + '[PROJECT]', + '[LOCATION]', + '[CA_POOL]', + '[CERTIFICATE_AUTHORITY]' + ); + + get_certificate_authority_sample($formattedName); +} +// [END privateca_v1_generated_CertificateAuthorityService_GetCertificateAuthority_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_certificate_revocation_list.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_certificate_revocation_list.php new file mode 100644 index 000000000000..8594ccb9e376 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_certificate_revocation_list.php @@ -0,0 +1,82 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var CertificateRevocationList $response */ + $response = $certificateAuthorityServiceClient->getCertificateRevocationList($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 = CertificateAuthorityServiceClient::certificateRevocationListName( + '[PROJECT]', + '[LOCATION]', + '[CA_POOL]', + '[CERTIFICATE_AUTHORITY]', + '[CERTIFICATE_REVOCATION_LIST]' + ); + + get_certificate_revocation_list_sample($formattedName); +} +// [END privateca_v1_generated_CertificateAuthorityService_GetCertificateRevocationList_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_certificate_template.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_certificate_template.php new file mode 100644 index 000000000000..ca69b6075b2f --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_certificate_template.php @@ -0,0 +1,79 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var CertificateTemplate $response */ + $response = $certificateAuthorityServiceClient->getCertificateTemplate($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 = CertificateAuthorityServiceClient::certificateTemplateName( + '[PROJECT]', + '[LOCATION]', + '[CERTIFICATE_TEMPLATE]' + ); + + get_certificate_template_sample($formattedName); +} +// [END privateca_v1_generated_CertificateAuthorityService_GetCertificateTemplate_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_iam_policy.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_iam_policy.php new file mode 100644 index 000000000000..a351034ccfea --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_iam_policy.php @@ -0,0 +1,72 @@ +setResource($resource); + + // Call the API and handle any network failures. + try { + /** @var Policy $response */ + $response = $certificateAuthorityServiceClient->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 privateca_v1_generated_CertificateAuthorityService_GetIamPolicy_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_location.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_location.php new file mode 100644 index 000000000000..859895c3c110 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_location.php @@ -0,0 +1,57 @@ +getLocation($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} +// [END privateca_v1_generated_CertificateAuthorityService_GetLocation_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_ca_pools.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_ca_pools.php new file mode 100644 index 000000000000..f25f9de28afe --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_ca_pools.php @@ -0,0 +1,78 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $certificateAuthorityServiceClient->listCaPools($request); + + /** @var CaPool $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 = CertificateAuthorityServiceClient::locationName('[PROJECT]', '[LOCATION]'); + + list_ca_pools_sample($formattedParent); +} +// [END privateca_v1_generated_CertificateAuthorityService_ListCaPools_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_certificate_authorities.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_certificate_authorities.php new file mode 100644 index 000000000000..f65b8809fcb6 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_certificate_authorities.php @@ -0,0 +1,84 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $certificateAuthorityServiceClient->listCertificateAuthorities($request); + + /** @var CertificateAuthority $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 = CertificateAuthorityServiceClient::caPoolName( + '[PROJECT]', + '[LOCATION]', + '[CA_POOL]' + ); + + list_certificate_authorities_sample($formattedParent); +} +// [END privateca_v1_generated_CertificateAuthorityService_ListCertificateAuthorities_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_certificate_revocation_lists.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_certificate_revocation_lists.php new file mode 100644 index 000000000000..a827a487d673 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_certificate_revocation_lists.php @@ -0,0 +1,84 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $certificateAuthorityServiceClient->listCertificateRevocationLists($request); + + /** @var CertificateRevocationList $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 = CertificateAuthorityServiceClient::certificateAuthorityName( + '[PROJECT]', + '[LOCATION]', + '[CA_POOL]', + '[CERTIFICATE_AUTHORITY]' + ); + + list_certificate_revocation_lists_sample($formattedParent); +} +// [END privateca_v1_generated_CertificateAuthorityService_ListCertificateRevocationLists_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_certificate_templates.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_certificate_templates.php new file mode 100644 index 000000000000..0a0c98aff194 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_certificate_templates.php @@ -0,0 +1,79 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $certificateAuthorityServiceClient->listCertificateTemplates($request); + + /** @var CertificateTemplate $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 = CertificateAuthorityServiceClient::locationName('[PROJECT]', '[LOCATION]'); + + list_certificate_templates_sample($formattedParent); +} +// [END privateca_v1_generated_CertificateAuthorityService_ListCertificateTemplates_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_certificates.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_certificates.php new file mode 100644 index 000000000000..9b665e39ff7f --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_certificates.php @@ -0,0 +1,91 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $certificateAuthorityServiceClient->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 = CertificateAuthorityServiceClient::caPoolName( + '[PROJECT]', + '[LOCATION]', + '[CA_POOL]' + ); + + list_certificates_sample($formattedParent); +} +// [END privateca_v1_generated_CertificateAuthorityService_ListCertificates_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_locations.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_locations.php new file mode 100644 index 000000000000..1c37b5ee6144 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_locations.php @@ -0,0 +1,77 @@ +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 privateca_v1_generated_CertificateAuthorityService_ListLocations_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/revoke_certificate.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/revoke_certificate.php new file mode 100644 index 000000000000..ecc9084de793 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/revoke_certificate.php @@ -0,0 +1,84 @@ +setName($formattedName) + ->setReason($reason); + + // Call the API and handle any network failures. + try { + /** @var Certificate $response */ + $response = $certificateAuthorityServiceClient->revokeCertificate($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 = CertificateAuthorityServiceClient::certificateName( + '[PROJECT]', + '[LOCATION]', + '[CA_POOL]', + '[CERTIFICATE]' + ); + $reason = RevocationReason::REVOCATION_REASON_UNSPECIFIED; + + revoke_certificate_sample($formattedName, $reason); +} +// [END privateca_v1_generated_CertificateAuthorityService_RevokeCertificate_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/set_iam_policy.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/set_iam_policy.php new file mode 100644 index 000000000000..2146e5d72607 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/set_iam_policy.php @@ -0,0 +1,77 @@ +setResource($resource) + ->setPolicy($policy); + + // Call the API and handle any network failures. + try { + /** @var Policy $response */ + $response = $certificateAuthorityServiceClient->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 privateca_v1_generated_CertificateAuthorityService_SetIamPolicy_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/test_iam_permissions.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/test_iam_permissions.php new file mode 100644 index 000000000000..0704d9f1d8f5 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/test_iam_permissions.php @@ -0,0 +1,84 @@ +setResource($resource) + ->setPermissions($permissions); + + // Call the API and handle any network failures. + try { + /** @var TestIamPermissionsResponse $response */ + $response = $certificateAuthorityServiceClient->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 privateca_v1_generated_CertificateAuthorityService_TestIamPermissions_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/undelete_certificate_authority.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/undelete_certificate_authority.php new file mode 100644 index 000000000000..62414a8d9e43 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/undelete_certificate_authority.php @@ -0,0 +1,92 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $certificateAuthorityServiceClient->undeleteCertificateAuthority($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var CertificateAuthority $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 = CertificateAuthorityServiceClient::certificateAuthorityName( + '[PROJECT]', + '[LOCATION]', + '[CA_POOL]', + '[CERTIFICATE_AUTHORITY]' + ); + + undelete_certificate_authority_sample($formattedName); +} +// [END privateca_v1_generated_CertificateAuthorityService_UndeleteCertificateAuthority_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/update_ca_pool.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/update_ca_pool.php new file mode 100644 index 000000000000..79adc4935636 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/update_ca_pool.php @@ -0,0 +1,90 @@ +setTier($caPoolTier); + $updateMask = new FieldMask(); + $request = (new UpdateCaPoolRequest()) + ->setCaPool($caPool) + ->setUpdateMask($updateMask); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $certificateAuthorityServiceClient->updateCaPool($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var CaPool $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 +{ + $caPoolTier = Tier::TIER_UNSPECIFIED; + + update_ca_pool_sample($caPoolTier); +} +// [END privateca_v1_generated_CertificateAuthorityService_UpdateCaPool_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/update_certificate.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/update_certificate.php new file mode 100644 index 000000000000..f6ca1bdab733 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/update_certificate.php @@ -0,0 +1,67 @@ +setLifetime($certificateLifetime); + $updateMask = new FieldMask(); + $request = (new UpdateCertificateRequest()) + ->setCertificate($certificate) + ->setUpdateMask($updateMask); + + // Call the API and handle any network failures. + try { + /** @var Certificate $response */ + $response = $certificateAuthorityServiceClient->updateCertificate($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} +// [END privateca_v1_generated_CertificateAuthorityService_UpdateCertificate_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/update_certificate_authority.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/update_certificate_authority.php new file mode 100644 index 000000000000..3a7b6d267304 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/update_certificate_authority.php @@ -0,0 +1,107 @@ +setSubjectConfig($certificateAuthorityConfigSubjectConfig) + ->setX509Config($certificateAuthorityConfigX509Config); + $certificateAuthorityLifetime = new Duration(); + $certificateAuthorityKeySpec = new KeyVersionSpec(); + $certificateAuthority = (new CertificateAuthority()) + ->setType($certificateAuthorityType) + ->setConfig($certificateAuthorityConfig) + ->setLifetime($certificateAuthorityLifetime) + ->setKeySpec($certificateAuthorityKeySpec); + $updateMask = new FieldMask(); + $request = (new UpdateCertificateAuthorityRequest()) + ->setCertificateAuthority($certificateAuthority) + ->setUpdateMask($updateMask); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $certificateAuthorityServiceClient->updateCertificateAuthority($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var CertificateAuthority $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 +{ + $certificateAuthorityType = Type::TYPE_UNSPECIFIED; + + update_certificate_authority_sample($certificateAuthorityType); +} +// [END privateca_v1_generated_CertificateAuthorityService_UpdateCertificateAuthority_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/update_certificate_revocation_list.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/update_certificate_revocation_list.php new file mode 100644 index 000000000000..a9b831f1acd5 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/update_certificate_revocation_list.php @@ -0,0 +1,75 @@ +setCertificateRevocationList($certificateRevocationList) + ->setUpdateMask($updateMask); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $certificateAuthorityServiceClient->updateCertificateRevocationList($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var CertificateRevocationList $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 privateca_v1_generated_CertificateAuthorityService_UpdateCertificateRevocationList_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/update_certificate_template.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/update_certificate_template.php new file mode 100644 index 000000000000..6159afbf8fda --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/update_certificate_template.php @@ -0,0 +1,75 @@ +setCertificateTemplate($certificateTemplate) + ->setUpdateMask($updateMask); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $certificateAuthorityServiceClient->updateCertificateTemplate($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var CertificateTemplate $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 privateca_v1_generated_CertificateAuthorityService_UpdateCertificateTemplate_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/src/V1/Client/CertificateAuthorityServiceClient.php b/owl-bot-staging/SecurityPrivateCa/v1/src/V1/Client/CertificateAuthorityServiceClient.php new file mode 100644 index 000000000000..ab68b4660fb5 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/src/V1/Client/CertificateAuthorityServiceClient.php @@ -0,0 +1,1458 @@ + activateCertificateAuthorityAsync(ActivateCertificateAuthorityRequest $request, array $optionalArgs = []) + * @method PromiseInterface createCaPoolAsync(CreateCaPoolRequest $request, array $optionalArgs = []) + * @method PromiseInterface createCertificateAsync(CreateCertificateRequest $request, array $optionalArgs = []) + * @method PromiseInterface createCertificateAuthorityAsync(CreateCertificateAuthorityRequest $request, array $optionalArgs = []) + * @method PromiseInterface createCertificateTemplateAsync(CreateCertificateTemplateRequest $request, array $optionalArgs = []) + * @method PromiseInterface deleteCaPoolAsync(DeleteCaPoolRequest $request, array $optionalArgs = []) + * @method PromiseInterface deleteCertificateAuthorityAsync(DeleteCertificateAuthorityRequest $request, array $optionalArgs = []) + * @method PromiseInterface deleteCertificateTemplateAsync(DeleteCertificateTemplateRequest $request, array $optionalArgs = []) + * @method PromiseInterface disableCertificateAuthorityAsync(DisableCertificateAuthorityRequest $request, array $optionalArgs = []) + * @method PromiseInterface enableCertificateAuthorityAsync(EnableCertificateAuthorityRequest $request, array $optionalArgs = []) + * @method PromiseInterface fetchCaCertsAsync(FetchCaCertsRequest $request, array $optionalArgs = []) + * @method PromiseInterface fetchCertificateAuthorityCsrAsync(FetchCertificateAuthorityCsrRequest $request, array $optionalArgs = []) + * @method PromiseInterface getCaPoolAsync(GetCaPoolRequest $request, array $optionalArgs = []) + * @method PromiseInterface getCertificateAsync(GetCertificateRequest $request, array $optionalArgs = []) + * @method PromiseInterface getCertificateAuthorityAsync(GetCertificateAuthorityRequest $request, array $optionalArgs = []) + * @method PromiseInterface getCertificateRevocationListAsync(GetCertificateRevocationListRequest $request, array $optionalArgs = []) + * @method PromiseInterface getCertificateTemplateAsync(GetCertificateTemplateRequest $request, array $optionalArgs = []) + * @method PromiseInterface listCaPoolsAsync(ListCaPoolsRequest $request, array $optionalArgs = []) + * @method PromiseInterface listCertificateAuthoritiesAsync(ListCertificateAuthoritiesRequest $request, array $optionalArgs = []) + * @method PromiseInterface listCertificateRevocationListsAsync(ListCertificateRevocationListsRequest $request, array $optionalArgs = []) + * @method PromiseInterface listCertificateTemplatesAsync(ListCertificateTemplatesRequest $request, array $optionalArgs = []) + * @method PromiseInterface listCertificatesAsync(ListCertificatesRequest $request, array $optionalArgs = []) + * @method PromiseInterface revokeCertificateAsync(RevokeCertificateRequest $request, array $optionalArgs = []) + * @method PromiseInterface undeleteCertificateAuthorityAsync(UndeleteCertificateAuthorityRequest $request, array $optionalArgs = []) + * @method PromiseInterface updateCaPoolAsync(UpdateCaPoolRequest $request, array $optionalArgs = []) + * @method PromiseInterface updateCertificateAsync(UpdateCertificateRequest $request, array $optionalArgs = []) + * @method PromiseInterface updateCertificateAuthorityAsync(UpdateCertificateAuthorityRequest $request, array $optionalArgs = []) + * @method PromiseInterface updateCertificateRevocationListAsync(UpdateCertificateRevocationListRequest $request, array $optionalArgs = []) + * @method PromiseInterface updateCertificateTemplateAsync(UpdateCertificateTemplateRequest $request, array $optionalArgs = []) + * @method PromiseInterface getLocationAsync(GetLocationRequest $request, array $optionalArgs = []) + * @method PromiseInterface listLocationsAsync(ListLocationsRequest $request, array $optionalArgs = []) + * @method PromiseInterface getIamPolicyAsync(GetIamPolicyRequest $request, array $optionalArgs = []) + * @method PromiseInterface setIamPolicyAsync(SetIamPolicyRequest $request, array $optionalArgs = []) + * @method PromiseInterface testIamPermissionsAsync(TestIamPermissionsRequest $request, array $optionalArgs = []) + */ +final class CertificateAuthorityServiceClient +{ + use GapicClientTrait; + use ResourceHelperTrait; + + /** The name of the service. */ + private const SERVICE_NAME = 'google.cloud.security.privateca.v1.CertificateAuthorityService'; + + /** + * The default address of the service. + * + * @deprecated SERVICE_ADDRESS_TEMPLATE should be used instead. + */ + private const SERVICE_ADDRESS = 'privateca.googleapis.com'; + + /** The address template of the service. */ + private const SERVICE_ADDRESS_TEMPLATE = 'privateca.UNIVERSE_DOMAIN'; + + /** The default port of the service. */ + private const DEFAULT_SERVICE_PORT = 443; + + /** The name of the code generator, to be included in the agent header. */ + private const CODEGEN_NAME = 'gapic'; + + /** The default scopes required by the service. */ + public static $serviceScopes = [ + 'https://www.googleapis.com/auth/cloud-platform', + ]; + + private $operationsClient; + + private static function getClientDefaults() + { + return [ + 'serviceName' => self::SERVICE_NAME, + 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, + 'clientConfig' => __DIR__ . '/../resources/certificate_authority_service_client_config.json', + 'descriptorsConfigPath' => __DIR__ . '/../resources/certificate_authority_service_descriptor_config.php', + 'gcpApiConfigPath' => __DIR__ . '/../resources/certificate_authority_service_grpc_config.json', + 'credentialsConfig' => [ + 'defaultScopes' => self::$serviceScopes, + ], + 'transportConfig' => [ + 'rest' => [ + 'restClientConfigPath' => __DIR__ . '/../resources/certificate_authority_service_rest_client_config.php', + ], + ], + ]; + } + + /** + * 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 = $this->descriptors[$methodName]['longRunning'] ?? []; + $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); + $operation->reload(); + return $operation; + } + + /** + * Create the default operation client for the service. + * + * @param array $options ClientOptions for the client. + * + * @return OperationsClient + */ + private function createOperationsClient(array $options) + { + // Unset client-specific configuration options + unset($options['serviceName'], $options['clientConfig'], $options['descriptorsConfigPath']); + + if (isset($options['operationsClient'])) { + return $options['operationsClient']; + } + + return new OperationsClient($options); + } + + /** + * 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(string $project, string $location, string $caPool): string + { + return self::getPathTemplate('caPool')->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 $caPool + * @param string $certificate + * + * @return string The formatted certificate resource. + */ + public static function certificateName(string $project, string $location, string $caPool, string $certificate): string + { + return self::getPathTemplate('certificate')->render([ + 'project' => $project, + 'location' => $location, + 'ca_pool' => $caPool, + 'certificate' => $certificate, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * certificate_authority resource. + * + * @param string $project + * @param string $location + * @param string $caPool + * @param string $certificateAuthority + * + * @return string The formatted certificate_authority resource. + */ + public static function certificateAuthorityName(string $project, string $location, string $caPool, string $certificateAuthority): string + { + return self::getPathTemplate('certificateAuthority')->render([ + 'project' => $project, + 'location' => $location, + 'ca_pool' => $caPool, + 'certificate_authority' => $certificateAuthority, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * certificate_revocation_list resource. + * + * @param string $project + * @param string $location + * @param string $caPool + * @param string $certificateAuthority + * @param string $certificateRevocationList + * + * @return string The formatted certificate_revocation_list resource. + */ + public static function certificateRevocationListName(string $project, string $location, string $caPool, string $certificateAuthority, string $certificateRevocationList): string + { + return self::getPathTemplate('certificateRevocationList')->render([ + 'project' => $project, + 'location' => $location, + 'ca_pool' => $caPool, + 'certificate_authority' => $certificateAuthority, + 'certificate_revocation_list' => $certificateRevocationList, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * certificate_template resource. + * + * @param string $project + * @param string $location + * @param string $certificateTemplate + * + * @return string The formatted certificate_template resource. + */ + public static function certificateTemplateName(string $project, string $location, string $certificateTemplate): string + { + return self::getPathTemplate('certificateTemplate')->render([ + 'project' => $project, + 'location' => $location, + 'certificate_template' => $certificateTemplate, + ]); + } + + /** + * 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(string $project, string $location): string + { + return self::getPathTemplate('location')->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}/caPools/{ca_pool}/certificates/{certificate} + * - certificateAuthority: projects/{project}/locations/{location}/caPools/{ca_pool}/certificateAuthorities/{certificate_authority} + * - certificateRevocationList: projects/{project}/locations/{location}/caPools/{ca_pool}/certificateAuthorities/{certificate_authority}/certificateRevocationLists/{certificate_revocation_list} + * - certificateTemplate: projects/{project}/locations/{location}/certificateTemplates/{certificate_template} + * - 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(string $formattedName, ?string $template = null): array + { + return self::parseFormattedName($formattedName, $template); + } + + /** + * Constructor. + * + * @param array|ClientOptions $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 'privateca.googleapis.com:443'. + * @type FetchAuthTokenInterface|CredentialsWrapper $credentials + * This option should only be used with a pre-constructed + * {@see FetchAuthTokenInterface} or {@see CredentialsWrapper} object. Note that + * when one of these objects are provided, any settings in $credentialsConfig will + * be ignored. + * **Important**: If you are providing a path to a credentials file, or a decoded + * credentials file as a PHP array, this usage is now DEPRECATED. Providing an + * unvalidated credential configuration to Google APIs can compromise the security + * of your systems and data. It is recommended to create the credentials explicitly + * ``` + * use Google\Auth\Credentials\ServiceAccountCredentials; + * use Google\Cloud\Security\PrivateCA\V1\CertificateAuthorityServiceClient; + * $creds = new ServiceAccountCredentials($scopes, $json); + * $options = new CertificateAuthorityServiceClient(['credentials' => $creds]); + * ``` + * {@see + * https://cloud.google.com/docs/authentication/external/externally-sourced-credentials} + * @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. + * @type false|LoggerInterface $logger + * A PSR-3 compliant logger. If set to false, logging is disabled, ignoring the + * 'GOOGLE_SDK_PHP_LOGGING' environment flag + * @type string $universeDomain + * The service domain for the client. Defaults to 'googleapis.com'. + * } + * + * @throws ValidationException + */ + public function __construct(array|ClientOptions $options = []) + { + $clientOptions = $this->buildClientOptions($options); + $this->setClientOptions($clientOptions); + $this->operationsClient = $this->createOperationsClient($clientOptions); + } + + /** Handles execution of the async variants for each documented method. */ + public function __call($method, $args) + { + if (substr($method, -5) !== 'Async') { + trigger_error('Call to undefined method ' . __CLASS__ . "::$method()", E_USER_ERROR); + } + + array_unshift($args, substr($method, 0, -5)); + return call_user_func_array([$this, 'startAsyncCall'], $args); + } + + /** + * Activate a + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * that is in state + * [AWAITING_USER_ACTIVATION][google.cloud.security.privateca.v1.CertificateAuthority.State.AWAITING_USER_ACTIVATION] + * and is of type + * [SUBORDINATE][google.cloud.security.privateca.v1.CertificateAuthority.Type.SUBORDINATE]. + * After the parent Certificate Authority signs a certificate signing request + * from + * [FetchCertificateAuthorityCsr][google.cloud.security.privateca.v1.CertificateAuthorityService.FetchCertificateAuthorityCsr], + * this method can complete the activation process. + * + * The async variant is + * {@see CertificateAuthorityServiceClient::activateCertificateAuthorityAsync()} . + * + * @example samples/V1/CertificateAuthorityServiceClient/activate_certificate_authority.php + * + * @param ActivateCertificateAuthorityRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function activateCertificateAuthority(ActivateCertificateAuthorityRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('ActivateCertificateAuthority', $request, $callOptions)->wait(); + } + + /** + * Create a [CaPool][google.cloud.security.privateca.v1.CaPool]. + * + * The async variant is + * {@see CertificateAuthorityServiceClient::createCaPoolAsync()} . + * + * @example samples/V1/CertificateAuthorityServiceClient/create_ca_pool.php + * + * @param CreateCaPoolRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function createCaPool(CreateCaPoolRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('CreateCaPool', $request, $callOptions)->wait(); + } + + /** + * Create a new [Certificate][google.cloud.security.privateca.v1.Certificate] + * in a given Project, Location from a particular + * [CaPool][google.cloud.security.privateca.v1.CaPool]. + * + * The async variant is + * {@see CertificateAuthorityServiceClient::createCertificateAsync()} . + * + * @example samples/V1/CertificateAuthorityServiceClient/create_certificate.php + * + * @param CreateCertificateRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Certificate + * + * @throws ApiException Thrown if the API call fails. + */ + public function createCertificate(CreateCertificateRequest $request, array $callOptions = []): Certificate + { + return $this->startApiCall('CreateCertificate', $request, $callOptions)->wait(); + } + + /** + * Create a new + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * in a given Project and Location. + * + * The async variant is + * {@see CertificateAuthorityServiceClient::createCertificateAuthorityAsync()} . + * + * @example samples/V1/CertificateAuthorityServiceClient/create_certificate_authority.php + * + * @param CreateCertificateAuthorityRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function createCertificateAuthority(CreateCertificateAuthorityRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('CreateCertificateAuthority', $request, $callOptions)->wait(); + } + + /** + * Create a new + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] + * in a given Project and Location. + * + * The async variant is + * {@see CertificateAuthorityServiceClient::createCertificateTemplateAsync()} . + * + * @example samples/V1/CertificateAuthorityServiceClient/create_certificate_template.php + * + * @param CreateCertificateTemplateRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function createCertificateTemplate(CreateCertificateTemplateRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('CreateCertificateTemplate', $request, $callOptions)->wait(); + } + + /** + * Delete a [CaPool][google.cloud.security.privateca.v1.CaPool]. + * + * The async variant is + * {@see CertificateAuthorityServiceClient::deleteCaPoolAsync()} . + * + * @example samples/V1/CertificateAuthorityServiceClient/delete_ca_pool.php + * + * @param DeleteCaPoolRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function deleteCaPool(DeleteCaPoolRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('DeleteCaPool', $request, $callOptions)->wait(); + } + + /** + * Delete a + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. + * + * The async variant is + * {@see CertificateAuthorityServiceClient::deleteCertificateAuthorityAsync()} . + * + * @example samples/V1/CertificateAuthorityServiceClient/delete_certificate_authority.php + * + * @param DeleteCertificateAuthorityRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function deleteCertificateAuthority(DeleteCertificateAuthorityRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('DeleteCertificateAuthority', $request, $callOptions)->wait(); + } + + /** + * DeleteCertificateTemplate deletes a + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate]. + * + * The async variant is + * {@see CertificateAuthorityServiceClient::deleteCertificateTemplateAsync()} . + * + * @example samples/V1/CertificateAuthorityServiceClient/delete_certificate_template.php + * + * @param DeleteCertificateTemplateRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function deleteCertificateTemplate(DeleteCertificateTemplateRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('DeleteCertificateTemplate', $request, $callOptions)->wait(); + } + + /** + * Disable a + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. + * + * The async variant is + * {@see CertificateAuthorityServiceClient::disableCertificateAuthorityAsync()} . + * + * @example samples/V1/CertificateAuthorityServiceClient/disable_certificate_authority.php + * + * @param DisableCertificateAuthorityRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function disableCertificateAuthority(DisableCertificateAuthorityRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('DisableCertificateAuthority', $request, $callOptions)->wait(); + } + + /** + * Enable a + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. + * + * The async variant is + * {@see CertificateAuthorityServiceClient::enableCertificateAuthorityAsync()} . + * + * @example samples/V1/CertificateAuthorityServiceClient/enable_certificate_authority.php + * + * @param EnableCertificateAuthorityRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function enableCertificateAuthority(EnableCertificateAuthorityRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('EnableCertificateAuthority', $request, $callOptions)->wait(); + } + + /** + * FetchCaCerts returns the current trust anchor for the + * [CaPool][google.cloud.security.privateca.v1.CaPool]. This will include CA + * certificate chains for all certificate authorities in the ENABLED, + * DISABLED, or STAGED states. + * + * The async variant is + * {@see CertificateAuthorityServiceClient::fetchCaCertsAsync()} . + * + * @example samples/V1/CertificateAuthorityServiceClient/fetch_ca_certs.php + * + * @param FetchCaCertsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 FetchCaCertsResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function fetchCaCerts(FetchCaCertsRequest $request, array $callOptions = []): FetchCaCertsResponse + { + return $this->startApiCall('FetchCaCerts', $request, $callOptions)->wait(); + } + + /** + * Fetch a certificate signing request (CSR) from a + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * that is in state + * [AWAITING_USER_ACTIVATION][google.cloud.security.privateca.v1.CertificateAuthority.State.AWAITING_USER_ACTIVATION] + * and is of type + * [SUBORDINATE][google.cloud.security.privateca.v1.CertificateAuthority.Type.SUBORDINATE]. + * The CSR must then be signed by the desired parent Certificate Authority, + * which could be another + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * resource, or could be an on-prem certificate authority. See also + * [ActivateCertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthorityService.ActivateCertificateAuthority]. + * + * The async variant is + * {@see CertificateAuthorityServiceClient::fetchCertificateAuthorityCsrAsync()} . + * + * @example samples/V1/CertificateAuthorityServiceClient/fetch_certificate_authority_csr.php + * + * @param FetchCertificateAuthorityCsrRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 FetchCertificateAuthorityCsrResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function fetchCertificateAuthorityCsr(FetchCertificateAuthorityCsrRequest $request, array $callOptions = []): FetchCertificateAuthorityCsrResponse + { + return $this->startApiCall('FetchCertificateAuthorityCsr', $request, $callOptions)->wait(); + } + + /** + * Returns a [CaPool][google.cloud.security.privateca.v1.CaPool]. + * + * The async variant is {@see CertificateAuthorityServiceClient::getCaPoolAsync()} + * . + * + * @example samples/V1/CertificateAuthorityServiceClient/get_ca_pool.php + * + * @param GetCaPoolRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 CaPool + * + * @throws ApiException Thrown if the API call fails. + */ + public function getCaPool(GetCaPoolRequest $request, array $callOptions = []): CaPool + { + return $this->startApiCall('GetCaPool', $request, $callOptions)->wait(); + } + + /** + * Returns a [Certificate][google.cloud.security.privateca.v1.Certificate]. + * + * The async variant is + * {@see CertificateAuthorityServiceClient::getCertificateAsync()} . + * + * @example samples/V1/CertificateAuthorityServiceClient/get_certificate.php + * + * @param GetCertificateRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Certificate + * + * @throws ApiException Thrown if the API call fails. + */ + public function getCertificate(GetCertificateRequest $request, array $callOptions = []): Certificate + { + return $this->startApiCall('GetCertificate', $request, $callOptions)->wait(); + } + + /** + * Returns a + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. + * + * The async variant is + * {@see CertificateAuthorityServiceClient::getCertificateAuthorityAsync()} . + * + * @example samples/V1/CertificateAuthorityServiceClient/get_certificate_authority.php + * + * @param GetCertificateAuthorityRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 CertificateAuthority + * + * @throws ApiException Thrown if the API call fails. + */ + public function getCertificateAuthority(GetCertificateAuthorityRequest $request, array $callOptions = []): CertificateAuthority + { + return $this->startApiCall('GetCertificateAuthority', $request, $callOptions)->wait(); + } + + /** + * Returns a + * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList]. + * + * The async variant is + * {@see CertificateAuthorityServiceClient::getCertificateRevocationListAsync()} . + * + * @example samples/V1/CertificateAuthorityServiceClient/get_certificate_revocation_list.php + * + * @param GetCertificateRevocationListRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 CertificateRevocationList + * + * @throws ApiException Thrown if the API call fails. + */ + public function getCertificateRevocationList(GetCertificateRevocationListRequest $request, array $callOptions = []): CertificateRevocationList + { + return $this->startApiCall('GetCertificateRevocationList', $request, $callOptions)->wait(); + } + + /** + * Returns a + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate]. + * + * The async variant is + * {@see CertificateAuthorityServiceClient::getCertificateTemplateAsync()} . + * + * @example samples/V1/CertificateAuthorityServiceClient/get_certificate_template.php + * + * @param GetCertificateTemplateRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 CertificateTemplate + * + * @throws ApiException Thrown if the API call fails. + */ + public function getCertificateTemplate(GetCertificateTemplateRequest $request, array $callOptions = []): CertificateTemplate + { + return $this->startApiCall('GetCertificateTemplate', $request, $callOptions)->wait(); + } + + /** + * Lists [CaPools][google.cloud.security.privateca.v1.CaPool]. + * + * The async variant is + * {@see CertificateAuthorityServiceClient::listCaPoolsAsync()} . + * + * @example samples/V1/CertificateAuthorityServiceClient/list_ca_pools.php + * + * @param ListCaPoolsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listCaPools(ListCaPoolsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListCaPools', $request, $callOptions); + } + + /** + * Lists + * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority]. + * + * The async variant is + * {@see CertificateAuthorityServiceClient::listCertificateAuthoritiesAsync()} . + * + * @example samples/V1/CertificateAuthorityServiceClient/list_certificate_authorities.php + * + * @param ListCertificateAuthoritiesRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listCertificateAuthorities(ListCertificateAuthoritiesRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListCertificateAuthorities', $request, $callOptions); + } + + /** + * Lists + * [CertificateRevocationLists][google.cloud.security.privateca.v1.CertificateRevocationList]. + * + * The async variant is + * {@see CertificateAuthorityServiceClient::listCertificateRevocationListsAsync()} + * . + * + * @example samples/V1/CertificateAuthorityServiceClient/list_certificate_revocation_lists.php + * + * @param ListCertificateRevocationListsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listCertificateRevocationLists(ListCertificateRevocationListsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListCertificateRevocationLists', $request, $callOptions); + } + + /** + * Lists + * [CertificateTemplates][google.cloud.security.privateca.v1.CertificateTemplate]. + * + * The async variant is + * {@see CertificateAuthorityServiceClient::listCertificateTemplatesAsync()} . + * + * @example samples/V1/CertificateAuthorityServiceClient/list_certificate_templates.php + * + * @param ListCertificateTemplatesRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listCertificateTemplates(ListCertificateTemplatesRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListCertificateTemplates', $request, $callOptions); + } + + /** + * Lists [Certificates][google.cloud.security.privateca.v1.Certificate]. + * + * The async variant is + * {@see CertificateAuthorityServiceClient::listCertificatesAsync()} . + * + * @example samples/V1/CertificateAuthorityServiceClient/list_certificates.php + * + * @param ListCertificatesRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listCertificates(ListCertificatesRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListCertificates', $request, $callOptions); + } + + /** + * Revoke a [Certificate][google.cloud.security.privateca.v1.Certificate]. + * + * The async variant is + * {@see CertificateAuthorityServiceClient::revokeCertificateAsync()} . + * + * @example samples/V1/CertificateAuthorityServiceClient/revoke_certificate.php + * + * @param RevokeCertificateRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Certificate + * + * @throws ApiException Thrown if the API call fails. + */ + public function revokeCertificate(RevokeCertificateRequest $request, array $callOptions = []): Certificate + { + return $this->startApiCall('RevokeCertificate', $request, $callOptions)->wait(); + } + + /** + * Undelete a + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] + * that has been deleted. + * + * The async variant is + * {@see CertificateAuthorityServiceClient::undeleteCertificateAuthorityAsync()} . + * + * @example samples/V1/CertificateAuthorityServiceClient/undelete_certificate_authority.php + * + * @param UndeleteCertificateAuthorityRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function undeleteCertificateAuthority(UndeleteCertificateAuthorityRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('UndeleteCertificateAuthority', $request, $callOptions)->wait(); + } + + /** + * Update a [CaPool][google.cloud.security.privateca.v1.CaPool]. + * + * The async variant is + * {@see CertificateAuthorityServiceClient::updateCaPoolAsync()} . + * + * @example samples/V1/CertificateAuthorityServiceClient/update_ca_pool.php + * + * @param UpdateCaPoolRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateCaPool(UpdateCaPoolRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('UpdateCaPool', $request, $callOptions)->wait(); + } + + /** + * Update a [Certificate][google.cloud.security.privateca.v1.Certificate]. + * Currently, the only field you can update is the + * [labels][google.cloud.security.privateca.v1.Certificate.labels] field. + * + * The async variant is + * {@see CertificateAuthorityServiceClient::updateCertificateAsync()} . + * + * @example samples/V1/CertificateAuthorityServiceClient/update_certificate.php + * + * @param UpdateCertificateRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Certificate + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateCertificate(UpdateCertificateRequest $request, array $callOptions = []): Certificate + { + return $this->startApiCall('UpdateCertificate', $request, $callOptions)->wait(); + } + + /** + * Update a + * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. + * + * The async variant is + * {@see CertificateAuthorityServiceClient::updateCertificateAuthorityAsync()} . + * + * @example samples/V1/CertificateAuthorityServiceClient/update_certificate_authority.php + * + * @param UpdateCertificateAuthorityRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateCertificateAuthority(UpdateCertificateAuthorityRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('UpdateCertificateAuthority', $request, $callOptions)->wait(); + } + + /** + * Update a + * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList]. + * + * The async variant is + * {@see CertificateAuthorityServiceClient::updateCertificateRevocationListAsync()} + * . + * + * @example samples/V1/CertificateAuthorityServiceClient/update_certificate_revocation_list.php + * + * @param UpdateCertificateRevocationListRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateCertificateRevocationList(UpdateCertificateRevocationListRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('UpdateCertificateRevocationList', $request, $callOptions)->wait(); + } + + /** + * Update a + * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate]. + * + * The async variant is + * {@see CertificateAuthorityServiceClient::updateCertificateTemplateAsync()} . + * + * @example samples/V1/CertificateAuthorityServiceClient/update_certificate_template.php + * + * @param UpdateCertificateTemplateRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateCertificateTemplate(UpdateCertificateTemplateRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('UpdateCertificateTemplate', $request, $callOptions)->wait(); + } + + /** + * Gets information about a location. + * + * The async variant is + * {@see CertificateAuthorityServiceClient::getLocationAsync()} . + * + * @example samples/V1/CertificateAuthorityServiceClient/get_location.php + * + * @param GetLocationRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Location + * + * @throws ApiException Thrown if the API call fails. + */ + public function getLocation(GetLocationRequest $request, array $callOptions = []): Location + { + return $this->startApiCall('GetLocation', $request, $callOptions)->wait(); + } + + /** + * Lists information about the supported locations for this service. + * + * This method lists locations based on the resource scope provided in + * the [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: * + * **Global locations**: If `name` is empty, the method lists the + * public locations available to all projects. * **Project-specific + * locations**: If `name` follows the format + * `projects/{project}`, the method lists locations visible to that + * specific project. This includes public, private, or other + * project-specific locations enabled for the project. + * + * For gRPC and client library implementations, the resource name is + * passed as the `name` field. For direct service calls, the resource + * name is + * incorporated into the request path based on the specific service + * implementation and version. + * + * The async variant is + * {@see CertificateAuthorityServiceClient::listLocationsAsync()} . + * + * @example samples/V1/CertificateAuthorityServiceClient/list_locations.php + * + * @param ListLocationsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listLocations(ListLocationsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListLocations', $request, $callOptions); + } + + /** + * Gets the access control policy for a resource. Returns an empty policy + * if the resource exists and does not have a policy set. + * + * The async variant is + * {@see CertificateAuthorityServiceClient::getIamPolicyAsync()} . + * + * @example samples/V1/CertificateAuthorityServiceClient/get_iam_policy.php + * + * @param GetIamPolicyRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Policy + * + * @throws ApiException Thrown if the API call fails. + */ + public function getIamPolicy(GetIamPolicyRequest $request, array $callOptions = []): Policy + { + return $this->startApiCall('GetIamPolicy', $request, $callOptions)->wait(); + } + + /** + * Sets the access control policy on the specified resource. Replaces + * any existing policy. + * + * Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` + * errors. + * + * The async variant is + * {@see CertificateAuthorityServiceClient::setIamPolicyAsync()} . + * + * @example samples/V1/CertificateAuthorityServiceClient/set_iam_policy.php + * + * @param SetIamPolicyRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Policy + * + * @throws ApiException Thrown if the API call fails. + */ + public function setIamPolicy(SetIamPolicyRequest $request, array $callOptions = []): Policy + { + return $this->startApiCall('SetIamPolicy', $request, $callOptions)->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. + * + * The async variant is + * {@see CertificateAuthorityServiceClient::testIamPermissionsAsync()} . + * + * @example samples/V1/CertificateAuthorityServiceClient/test_iam_permissions.php + * + * @param TestIamPermissionsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 TestIamPermissionsResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function testIamPermissions(TestIamPermissionsRequest $request, array $callOptions = []): TestIamPermissionsResponse + { + return $this->startApiCall('TestIamPermissions', $request, $callOptions)->wait(); + } +} diff --git a/owl-bot-staging/SecurityPrivateCa/v1/src/V1/gapic_metadata.json b/owl-bot-staging/SecurityPrivateCa/v1/src/V1/gapic_metadata.json new file mode 100644 index 000000000000..b7ecefd419d9 --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/src/V1/gapic_metadata.json @@ -0,0 +1,188 @@ +{ + "schema": "1.0", + "comment": "This file maps proto services\/RPCs to the corresponding library clients\/methods", + "language": "php", + "protoPackage": "google.cloud.security.privateca.v1", + "libraryPackage": "Google\\Cloud\\Security\\PrivateCA\\V1", + "services": { + "CertificateAuthorityService": { + "clients": { + "grpc": { + "libraryClient": "CertificateAuthorityServiceGapicClient", + "rpcs": { + "ActivateCertificateAuthority": { + "methods": [ + "activateCertificateAuthority" + ] + }, + "CreateCaPool": { + "methods": [ + "createCaPool" + ] + }, + "CreateCertificate": { + "methods": [ + "createCertificate" + ] + }, + "CreateCertificateAuthority": { + "methods": [ + "createCertificateAuthority" + ] + }, + "CreateCertificateTemplate": { + "methods": [ + "createCertificateTemplate" + ] + }, + "DeleteCaPool": { + "methods": [ + "deleteCaPool" + ] + }, + "DeleteCertificateAuthority": { + "methods": [ + "deleteCertificateAuthority" + ] + }, + "DeleteCertificateTemplate": { + "methods": [ + "deleteCertificateTemplate" + ] + }, + "DisableCertificateAuthority": { + "methods": [ + "disableCertificateAuthority" + ] + }, + "EnableCertificateAuthority": { + "methods": [ + "enableCertificateAuthority" + ] + }, + "FetchCaCerts": { + "methods": [ + "fetchCaCerts" + ] + }, + "FetchCertificateAuthorityCsr": { + "methods": [ + "fetchCertificateAuthorityCsr" + ] + }, + "GetCaPool": { + "methods": [ + "getCaPool" + ] + }, + "GetCertificate": { + "methods": [ + "getCertificate" + ] + }, + "GetCertificateAuthority": { + "methods": [ + "getCertificateAuthority" + ] + }, + "GetCertificateRevocationList": { + "methods": [ + "getCertificateRevocationList" + ] + }, + "GetCertificateTemplate": { + "methods": [ + "getCertificateTemplate" + ] + }, + "ListCaPools": { + "methods": [ + "listCaPools" + ] + }, + "ListCertificateAuthorities": { + "methods": [ + "listCertificateAuthorities" + ] + }, + "ListCertificateRevocationLists": { + "methods": [ + "listCertificateRevocationLists" + ] + }, + "ListCertificateTemplates": { + "methods": [ + "listCertificateTemplates" + ] + }, + "ListCertificates": { + "methods": [ + "listCertificates" + ] + }, + "RevokeCertificate": { + "methods": [ + "revokeCertificate" + ] + }, + "UndeleteCertificateAuthority": { + "methods": [ + "undeleteCertificateAuthority" + ] + }, + "UpdateCaPool": { + "methods": [ + "updateCaPool" + ] + }, + "UpdateCertificate": { + "methods": [ + "updateCertificate" + ] + }, + "UpdateCertificateAuthority": { + "methods": [ + "updateCertificateAuthority" + ] + }, + "UpdateCertificateRevocationList": { + "methods": [ + "updateCertificateRevocationList" + ] + }, + "UpdateCertificateTemplate": { + "methods": [ + "updateCertificateTemplate" + ] + }, + "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/SecurityPrivateCa/v1/src/V1/resources/certificate_authority_service_client_config.json b/owl-bot-staging/SecurityPrivateCa/v1/src/V1/resources/certificate_authority_service_client_config.json new file mode 100644 index 000000000000..7d91cf3d1dba --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/src/V1/resources/certificate_authority_service_client_config.json @@ -0,0 +1,206 @@ +{ + "interfaces": { + "google.cloud.security.privateca.v1.CertificateAuthorityService": { + "retry_codes": { + "no_retry_codes": [], + "retry_policy_1_codes": [ + "UNKNOWN", + "UNAVAILABLE", + "DEADLINE_EXCEEDED" + ] + }, + "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": 100, + "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": { + "ActivateCertificateAuthority": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "CreateCaPool": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "CreateCertificate": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "CreateCertificateAuthority": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "CreateCertificateTemplate": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "DeleteCaPool": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "DeleteCertificateAuthority": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "DeleteCertificateTemplate": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "DisableCertificateAuthority": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "EnableCertificateAuthority": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "FetchCaCerts": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "FetchCertificateAuthorityCsr": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "GetCaPool": { + "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" + }, + "GetCertificateAuthority": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "GetCertificateRevocationList": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "GetCertificateTemplate": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ListCaPools": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ListCertificateAuthorities": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ListCertificateRevocationLists": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ListCertificateTemplates": { + "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" + }, + "RevokeCertificate": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "UndeleteCertificateAuthority": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "UpdateCaPool": { + "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" + }, + "UpdateCertificateAuthority": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "UpdateCertificateRevocationList": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "UpdateCertificateTemplate": { + "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" + }, + "GetIamPolicy": { + "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" + } + } + } + } +} diff --git a/owl-bot-staging/SecurityPrivateCa/v1/src/V1/resources/certificate_authority_service_descriptor_config.php b/owl-bot-staging/SecurityPrivateCa/v1/src/V1/resources/certificate_authority_service_descriptor_config.php new file mode 100644 index 000000000000..3d8570152f5b --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/src/V1/resources/certificate_authority_service_descriptor_config.php @@ -0,0 +1,600 @@ + [ + 'google.cloud.security.privateca.v1.CertificateAuthorityService' => [ + 'ActivateCertificateAuthority' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\Security\PrivateCA\V1\CertificateAuthority', + 'metadataReturnType' => '\Google\Cloud\Security\PrivateCA\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'CreateCaPool' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\Security\PrivateCA\V1\CaPool', + 'metadataReturnType' => '\Google\Cloud\Security\PrivateCA\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateCertificateAuthority' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\Security\PrivateCA\V1\CertificateAuthority', + 'metadataReturnType' => '\Google\Cloud\Security\PrivateCA\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateCertificateTemplate' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\Security\PrivateCA\V1\CertificateTemplate', + 'metadataReturnType' => '\Google\Cloud\Security\PrivateCA\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'DeleteCaPool' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Protobuf\GPBEmpty', + 'metadataReturnType' => '\Google\Cloud\Security\PrivateCA\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'DeleteCertificateAuthority' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\Security\PrivateCA\V1\CertificateAuthority', + 'metadataReturnType' => '\Google\Cloud\Security\PrivateCA\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'DeleteCertificateTemplate' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Protobuf\GPBEmpty', + 'metadataReturnType' => '\Google\Cloud\Security\PrivateCA\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'DisableCertificateAuthority' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\Security\PrivateCA\V1\CertificateAuthority', + 'metadataReturnType' => '\Google\Cloud\Security\PrivateCA\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'EnableCertificateAuthority' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\Security\PrivateCA\V1\CertificateAuthority', + 'metadataReturnType' => '\Google\Cloud\Security\PrivateCA\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'UndeleteCertificateAuthority' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\Security\PrivateCA\V1\CertificateAuthority', + 'metadataReturnType' => '\Google\Cloud\Security\PrivateCA\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'UpdateCaPool' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\Security\PrivateCA\V1\CaPool', + 'metadataReturnType' => '\Google\Cloud\Security\PrivateCA\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'ca_pool.name', + 'fieldAccessors' => [ + 'getCaPool', + 'getName', + ], + ], + ], + ], + 'UpdateCertificateAuthority' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\Security\PrivateCA\V1\CertificateAuthority', + 'metadataReturnType' => '\Google\Cloud\Security\PrivateCA\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'certificate_authority.name', + 'fieldAccessors' => [ + 'getCertificateAuthority', + 'getName', + ], + ], + ], + ], + 'UpdateCertificateRevocationList' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\Security\PrivateCA\V1\CertificateRevocationList', + 'metadataReturnType' => '\Google\Cloud\Security\PrivateCA\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'certificate_revocation_list.name', + 'fieldAccessors' => [ + 'getCertificateRevocationList', + 'getName', + ], + ], + ], + ], + 'UpdateCertificateTemplate' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\Security\PrivateCA\V1\CertificateTemplate', + 'metadataReturnType' => '\Google\Cloud\Security\PrivateCA\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'certificate_template.name', + 'fieldAccessors' => [ + 'getCertificateTemplate', + 'getName', + ], + ], + ], + ], + 'CreateCertificate' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Security\PrivateCA\V1\Certificate', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'FetchCaCerts' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Security\PrivateCA\V1\FetchCaCertsResponse', + 'headerParams' => [ + [ + 'keyName' => 'ca_pool', + 'fieldAccessors' => [ + 'getCaPool', + ], + ], + ], + ], + 'FetchCertificateAuthorityCsr' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Security\PrivateCA\V1\FetchCertificateAuthorityCsrResponse', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetCaPool' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Security\PrivateCA\V1\CaPool', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetCertificate' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Security\PrivateCA\V1\Certificate', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetCertificateAuthority' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Security\PrivateCA\V1\CertificateAuthority', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetCertificateRevocationList' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Security\PrivateCA\V1\CertificateRevocationList', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetCertificateTemplate' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Security\PrivateCA\V1\CertificateTemplate', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'ListCaPools' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getCaPools', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\Security\PrivateCA\V1\ListCaPoolsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListCertificateAuthorities' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getCertificateAuthorities', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\Security\PrivateCA\V1\ListCertificateAuthoritiesResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListCertificateRevocationLists' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getCertificateRevocationLists', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\Security\PrivateCA\V1\ListCertificateRevocationListsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListCertificateTemplates' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getCertificateTemplates', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\Security\PrivateCA\V1\ListCertificateTemplatesResponse', + '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\Security\PrivateCA\V1\ListCertificatesResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'RevokeCertificate' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Security\PrivateCA\V1\Certificate', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'UpdateCertificate' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Security\PrivateCA\V1\Certificate', + 'headerParams' => [ + [ + 'keyName' => 'certificate.name', + 'fieldAccessors' => [ + 'getCertificate', + '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' => [ + 'caPool' => 'projects/{project}/locations/{location}/caPools/{ca_pool}', + 'certificate' => 'projects/{project}/locations/{location}/caPools/{ca_pool}/certificates/{certificate}', + 'certificateAuthority' => 'projects/{project}/locations/{location}/caPools/{ca_pool}/certificateAuthorities/{certificate_authority}', + 'certificateRevocationList' => 'projects/{project}/locations/{location}/caPools/{ca_pool}/certificateAuthorities/{certificate_authority}/certificateRevocationLists/{certificate_revocation_list}', + 'certificateTemplate' => 'projects/{project}/locations/{location}/certificateTemplates/{certificate_template}', + 'location' => 'projects/{project}/locations/{location}', + ], + ], + ], +]; diff --git a/owl-bot-staging/SecurityPrivateCa/v1/src/V1/resources/certificate_authority_service_rest_client_config.php b/owl-bot-staging/SecurityPrivateCa/v1/src/V1/resources/certificate_authority_service_rest_client_config.php new file mode 100644 index 000000000000..ede260daa50a --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/src/V1/resources/certificate_authority_service_rest_client_config.php @@ -0,0 +1,534 @@ + [ + '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.cloud.security.privateca.v1.CertificateAuthorityService' => [ + 'ActivateCertificateAuthority' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/caPools/*/certificateAuthorities/*}:activate', + 'body' => '*', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'CreateCaPool' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/caPools', + 'body' => 'ca_pool', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + 'queryParams' => [ + 'ca_pool_id', + ], + ], + 'CreateCertificate' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*/caPools/*}/certificates', + 'body' => 'certificate', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'CreateCertificateAuthority' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*/caPools/*}/certificateAuthorities', + 'body' => 'certificate_authority', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + 'queryParams' => [ + 'certificate_authority_id', + ], + ], + 'CreateCertificateTemplate' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/certificateTemplates', + 'body' => 'certificate_template', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + 'queryParams' => [ + 'certificate_template_id', + ], + ], + 'DeleteCaPool' => [ + 'method' => 'delete', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/caPools/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'DeleteCertificateAuthority' => [ + 'method' => 'delete', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/caPools/*/certificateAuthorities/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'DeleteCertificateTemplate' => [ + 'method' => 'delete', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/certificateTemplates/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'DisableCertificateAuthority' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/caPools/*/certificateAuthorities/*}:disable', + 'body' => '*', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'EnableCertificateAuthority' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/caPools/*/certificateAuthorities/*}:enable', + 'body' => '*', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'FetchCaCerts' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{ca_pool=projects/*/locations/*/caPools/*}:fetchCaCerts', + 'body' => '*', + 'placeholders' => [ + 'ca_pool' => [ + 'getters' => [ + 'getCaPool', + ], + ], + ], + ], + 'FetchCertificateAuthorityCsr' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/caPools/*/certificateAuthorities/*}:fetch', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetCaPool' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/caPools/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetCertificate' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/caPools/*/certificates/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetCertificateAuthority' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/caPools/*/certificateAuthorities/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetCertificateRevocationList' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/caPools/*/certificateAuthorities/*/certificateRevocationLists/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetCertificateTemplate' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/certificateTemplates/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'ListCaPools' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/caPools', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListCertificateAuthorities' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*/caPools/*}/certificateAuthorities', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListCertificateRevocationLists' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*/caPools/*/certificateAuthorities/*}/certificateRevocationLists', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListCertificateTemplates' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/certificateTemplates', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListCertificates' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*/caPools/*}/certificates', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'RevokeCertificate' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/caPools/*/certificates/*}:revoke', + 'body' => '*', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'UndeleteCertificateAuthority' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/caPools/*/certificateAuthorities/*}:undelete', + 'body' => '*', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'UpdateCaPool' => [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{ca_pool.name=projects/*/locations/*/caPools/*}', + 'body' => 'ca_pool', + 'placeholders' => [ + 'ca_pool.name' => [ + 'getters' => [ + 'getCaPool', + 'getName', + ], + ], + ], + 'queryParams' => [ + 'update_mask', + ], + ], + 'UpdateCertificate' => [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{certificate.name=projects/*/locations/*/caPools/*/certificates/*}', + 'body' => 'certificate', + 'placeholders' => [ + 'certificate.name' => [ + 'getters' => [ + 'getCertificate', + 'getName', + ], + ], + ], + 'queryParams' => [ + 'update_mask', + ], + ], + 'UpdateCertificateAuthority' => [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{certificate_authority.name=projects/*/locations/*/caPools/*/certificateAuthorities/*}', + 'body' => 'certificate_authority', + 'placeholders' => [ + 'certificate_authority.name' => [ + 'getters' => [ + 'getCertificateAuthority', + 'getName', + ], + ], + ], + 'queryParams' => [ + 'update_mask', + ], + ], + 'UpdateCertificateRevocationList' => [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{certificate_revocation_list.name=projects/*/locations/*/caPools/*/certificateAuthorities/*/certificateRevocationLists/*}', + 'body' => 'certificate_revocation_list', + 'placeholders' => [ + 'certificate_revocation_list.name' => [ + 'getters' => [ + 'getCertificateRevocationList', + 'getName', + ], + ], + ], + 'queryParams' => [ + 'update_mask', + ], + ], + 'UpdateCertificateTemplate' => [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{certificate_template.name=projects/*/locations/*/certificateTemplates/*}', + 'body' => 'certificate_template', + 'placeholders' => [ + 'certificate_template.name' => [ + 'getters' => [ + 'getCertificateTemplate', + 'getName', + ], + ], + ], + 'queryParams' => [ + 'update_mask', + ], + ], + ], + 'google.iam.v1.IAMPolicy' => [ + 'GetIamPolicy' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{resource=projects/*/locations/*/caPools/*}:getIamPolicy', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v1/{resource=projects/*/locations/*/certificateTemplates/*}:getIamPolicy', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v1/{resource=projects/*/locations/*/caPools/*/certificateAuthorities/*/certificateRevocationLists/*}:getIamPolicy', + ], + ], + 'placeholders' => [ + 'resource' => [ + 'getters' => [ + 'getResource', + ], + ], + ], + ], + 'SetIamPolicy' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{resource=projects/*/locations/*/caPools/*}:setIamPolicy', + 'body' => '*', + 'additionalBindings' => [ + [ + 'method' => 'post', + 'uriTemplate' => '/v1/{resource=projects/*/locations/*/certificateTemplates/*}:setIamPolicy', + 'body' => '*', + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v1/{resource=projects/*/locations/*/caPools/*/certificateAuthorities/*/certificateRevocationLists/*}:setIamPolicy', + 'body' => '*', + ], + ], + 'placeholders' => [ + 'resource' => [ + 'getters' => [ + 'getResource', + ], + ], + ], + ], + 'TestIamPermissions' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{resource=projects/*/locations/*/caPools/*}:testIamPermissions', + 'body' => '*', + 'additionalBindings' => [ + [ + 'method' => 'post', + 'uriTemplate' => '/v1/{resource=projects/*/locations/*/certificateTemplates/*}:testIamPermissions', + 'body' => '*', + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v1/{resource=projects/*/locations/*/caPools/*/certificateAuthorities/*/certificateRevocationLists/*}: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/SecurityPrivateCa/v1/tests/Unit/V1/Client/CertificateAuthorityServiceClientTest.php b/owl-bot-staging/SecurityPrivateCa/v1/tests/Unit/V1/Client/CertificateAuthorityServiceClientTest.php new file mode 100644 index 000000000000..9f95ea94dbeb --- /dev/null +++ b/owl-bot-staging/SecurityPrivateCa/v1/tests/Unit/V1/Client/CertificateAuthorityServiceClientTest.php @@ -0,0 +1,3513 @@ +getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); + } + + /** @return CertificateAuthorityServiceClient */ + private function createClient(array $options = []) + { + $options += [ + 'credentials' => $this->createCredentials(), + ]; + return new CertificateAuthorityServiceClient($options); + } + + /** @test */ + public function activateCertificateAuthorityTest() + { + $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/activateCertificateAuthorityTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name2 = 'name2-1052831874'; + $gcsBucket = 'gcsBucket-1720393710'; + $satisfiesPzs = false; + $satisfiesPzi = false; + $expectedResponse = new CertificateAuthority(); + $expectedResponse->setName($name2); + $expectedResponse->setGcsBucket($gcsBucket); + $expectedResponse->setSatisfiesPzs($satisfiesPzs); + $expectedResponse->setSatisfiesPzi($satisfiesPzi); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/activateCertificateAuthorityTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedName = $gapicClient->certificateAuthorityName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]'); + $pemCaCertificate = 'pemCaCertificate1041594685'; + $subordinateConfig = new SubordinateConfig(); + $subordinateConfigCertificateAuthority = $gapicClient->certificateAuthorityName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]'); + $subordinateConfig->setCertificateAuthority($subordinateConfigCertificateAuthority); + $request = (new ActivateCertificateAuthorityRequest()) + ->setName($formattedName) + ->setPemCaCertificate($pemCaCertificate) + ->setSubordinateConfig($subordinateConfig); + $response = $gapicClient->activateCertificateAuthority($request); + $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.security.privateca.v1.CertificateAuthorityService/ActivateCertificateAuthority', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $actualValue = $actualApiRequestObject->getPemCaCertificate(); + $this->assertProtobufEquals($pemCaCertificate, $actualValue); + $actualValue = $actualApiRequestObject->getSubordinateConfig(); + $this->assertProtobufEquals($subordinateConfig, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/activateCertificateAuthorityTest'); + $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 activateCertificateAuthorityExceptionTest() + { + $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/activateCertificateAuthorityTest'); + $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->certificateAuthorityName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]'); + $pemCaCertificate = 'pemCaCertificate1041594685'; + $subordinateConfig = new SubordinateConfig(); + $subordinateConfigCertificateAuthority = $gapicClient->certificateAuthorityName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]'); + $subordinateConfig->setCertificateAuthority($subordinateConfigCertificateAuthority); + $request = (new ActivateCertificateAuthorityRequest()) + ->setName($formattedName) + ->setPemCaCertificate($pemCaCertificate) + ->setSubordinateConfig($subordinateConfig); + $response = $gapicClient->activateCertificateAuthority($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/activateCertificateAuthorityTest'); + 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 createCaPoolTest() + { + $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/createCaPoolTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $expectedResponse = new CaPool(); + $expectedResponse->setName($name); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/createCaPoolTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); + $caPoolId = 'caPoolId458688829'; + $caPool = new CaPool(); + $caPoolTier = Tier::TIER_UNSPECIFIED; + $caPool->setTier($caPoolTier); + $request = (new CreateCaPoolRequest()) + ->setParent($formattedParent) + ->setCaPoolId($caPoolId) + ->setCaPool($caPool); + $response = $gapicClient->createCaPool($request); + $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.security.privateca.v1.CertificateAuthorityService/CreateCaPool', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualApiRequestObject->getCaPoolId(); + $this->assertProtobufEquals($caPoolId, $actualValue); + $actualValue = $actualApiRequestObject->getCaPool(); + $this->assertProtobufEquals($caPool, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createCaPoolTest'); + $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 createCaPoolExceptionTest() + { + $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/createCaPoolTest'); + $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]'); + $caPoolId = 'caPoolId458688829'; + $caPool = new CaPool(); + $caPoolTier = Tier::TIER_UNSPECIFIED; + $caPool->setTier($caPoolTier); + $request = (new CreateCaPoolRequest()) + ->setParent($formattedParent) + ->setCaPoolId($caPoolId) + ->setCaPool($caPool); + $response = $gapicClient->createCaPool($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createCaPoolTest'); + 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 createCertificateTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $pemCsr = 'pemCsr-683665829'; + $issuerCertificateAuthority = 'issuerCertificateAuthority-750099051'; + $certificateTemplate = 'certificateTemplate2049676834'; + $pemCertificate = 'pemCertificate1234463984'; + $expectedResponse = new Certificate(); + $expectedResponse->setName($name); + $expectedResponse->setPemCsr($pemCsr); + $expectedResponse->setIssuerCertificateAuthority($issuerCertificateAuthority); + $expectedResponse->setCertificateTemplate($certificateTemplate); + $expectedResponse->setPemCertificate($pemCertificate); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->caPoolName('[PROJECT]', '[LOCATION]', '[CA_POOL]'); + $certificate = new Certificate(); + $certificateLifetime = new Duration(); + $certificate->setLifetime($certificateLifetime); + $request = (new CreateCertificateRequest()) + ->setParent($formattedParent) + ->setCertificate($certificate); + $response = $gapicClient->createCertificate($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.security.privateca.v1.CertificateAuthorityService/CreateCertificate', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getCertificate(); + $this->assertProtobufEquals($certificate, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createCertificateExceptionTest() + { + $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->caPoolName('[PROJECT]', '[LOCATION]', '[CA_POOL]'); + $certificate = new Certificate(); + $certificateLifetime = new Duration(); + $certificate->setLifetime($certificateLifetime); + $request = (new CreateCertificateRequest()) + ->setParent($formattedParent) + ->setCertificate($certificate); + try { + $gapicClient->createCertificate($request); + // 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 createCertificateAuthorityTest() + { + $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/createCertificateAuthorityTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $gcsBucket = 'gcsBucket-1720393710'; + $satisfiesPzs = false; + $satisfiesPzi = false; + $expectedResponse = new CertificateAuthority(); + $expectedResponse->setName($name); + $expectedResponse->setGcsBucket($gcsBucket); + $expectedResponse->setSatisfiesPzs($satisfiesPzs); + $expectedResponse->setSatisfiesPzi($satisfiesPzi); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/createCertificateAuthorityTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedParent = $gapicClient->caPoolName('[PROJECT]', '[LOCATION]', '[CA_POOL]'); + $certificateAuthorityId = 'certificateAuthorityId561919295'; + $certificateAuthority = new CertificateAuthority(); + $certificateAuthorityType = Type::TYPE_UNSPECIFIED; + $certificateAuthority->setType($certificateAuthorityType); + $certificateAuthorityConfig = new CertificateConfig(); + $configSubjectConfig = new SubjectConfig(); + $certificateAuthorityConfig->setSubjectConfig($configSubjectConfig); + $configX509Config = new X509Parameters(); + $certificateAuthorityConfig->setX509Config($configX509Config); + $certificateAuthority->setConfig($certificateAuthorityConfig); + $certificateAuthorityLifetime = new Duration(); + $certificateAuthority->setLifetime($certificateAuthorityLifetime); + $certificateAuthorityKeySpec = new KeyVersionSpec(); + $certificateAuthority->setKeySpec($certificateAuthorityKeySpec); + $request = (new CreateCertificateAuthorityRequest()) + ->setParent($formattedParent) + ->setCertificateAuthorityId($certificateAuthorityId) + ->setCertificateAuthority($certificateAuthority); + $response = $gapicClient->createCertificateAuthority($request); + $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.security.privateca.v1.CertificateAuthorityService/CreateCertificateAuthority', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualApiRequestObject->getCertificateAuthorityId(); + $this->assertProtobufEquals($certificateAuthorityId, $actualValue); + $actualValue = $actualApiRequestObject->getCertificateAuthority(); + $this->assertProtobufEquals($certificateAuthority, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createCertificateAuthorityTest'); + $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 createCertificateAuthorityExceptionTest() + { + $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/createCertificateAuthorityTest'); + $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->caPoolName('[PROJECT]', '[LOCATION]', '[CA_POOL]'); + $certificateAuthorityId = 'certificateAuthorityId561919295'; + $certificateAuthority = new CertificateAuthority(); + $certificateAuthorityType = Type::TYPE_UNSPECIFIED; + $certificateAuthority->setType($certificateAuthorityType); + $certificateAuthorityConfig = new CertificateConfig(); + $configSubjectConfig = new SubjectConfig(); + $certificateAuthorityConfig->setSubjectConfig($configSubjectConfig); + $configX509Config = new X509Parameters(); + $certificateAuthorityConfig->setX509Config($configX509Config); + $certificateAuthority->setConfig($certificateAuthorityConfig); + $certificateAuthorityLifetime = new Duration(); + $certificateAuthority->setLifetime($certificateAuthorityLifetime); + $certificateAuthorityKeySpec = new KeyVersionSpec(); + $certificateAuthority->setKeySpec($certificateAuthorityKeySpec); + $request = (new CreateCertificateAuthorityRequest()) + ->setParent($formattedParent) + ->setCertificateAuthorityId($certificateAuthorityId) + ->setCertificateAuthority($certificateAuthority); + $response = $gapicClient->createCertificateAuthority($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createCertificateAuthorityTest'); + 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 createCertificateTemplateTest() + { + $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/createCertificateTemplateTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $description = 'description-1724546052'; + $expectedResponse = new CertificateTemplate(); + $expectedResponse->setName($name); + $expectedResponse->setDescription($description); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/createCertificateTemplateTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); + $certificateTemplateId = 'certificateTemplateId372609112'; + $certificateTemplate = new CertificateTemplate(); + $request = (new CreateCertificateTemplateRequest()) + ->setParent($formattedParent) + ->setCertificateTemplateId($certificateTemplateId) + ->setCertificateTemplate($certificateTemplate); + $response = $gapicClient->createCertificateTemplate($request); + $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.security.privateca.v1.CertificateAuthorityService/CreateCertificateTemplate', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualApiRequestObject->getCertificateTemplateId(); + $this->assertProtobufEquals($certificateTemplateId, $actualValue); + $actualValue = $actualApiRequestObject->getCertificateTemplate(); + $this->assertProtobufEquals($certificateTemplate, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createCertificateTemplateTest'); + $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 createCertificateTemplateExceptionTest() + { + $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/createCertificateTemplateTest'); + $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]'); + $certificateTemplateId = 'certificateTemplateId372609112'; + $certificateTemplate = new CertificateTemplate(); + $request = (new CreateCertificateTemplateRequest()) + ->setParent($formattedParent) + ->setCertificateTemplateId($certificateTemplateId) + ->setCertificateTemplate($certificateTemplate); + $response = $gapicClient->createCertificateTemplate($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createCertificateTemplateTest'); + 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 deleteCaPoolTest() + { + $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/deleteCaPoolTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $expectedResponse = new GPBEmpty(); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/deleteCaPoolTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedName = $gapicClient->caPoolName('[PROJECT]', '[LOCATION]', '[CA_POOL]'); + $request = (new DeleteCaPoolRequest()) + ->setName($formattedName); + $response = $gapicClient->deleteCaPool($request); + $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.security.privateca.v1.CertificateAuthorityService/DeleteCaPool', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/deleteCaPoolTest'); + $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 deleteCaPoolExceptionTest() + { + $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/deleteCaPoolTest'); + $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->caPoolName('[PROJECT]', '[LOCATION]', '[CA_POOL]'); + $request = (new DeleteCaPoolRequest()) + ->setName($formattedName); + $response = $gapicClient->deleteCaPool($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/deleteCaPoolTest'); + 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 deleteCertificateAuthorityTest() + { + $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/deleteCertificateAuthorityTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name2 = 'name2-1052831874'; + $gcsBucket = 'gcsBucket-1720393710'; + $satisfiesPzs = false; + $satisfiesPzi = false; + $expectedResponse = new CertificateAuthority(); + $expectedResponse->setName($name2); + $expectedResponse->setGcsBucket($gcsBucket); + $expectedResponse->setSatisfiesPzs($satisfiesPzs); + $expectedResponse->setSatisfiesPzi($satisfiesPzi); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/deleteCertificateAuthorityTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedName = $gapicClient->certificateAuthorityName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]'); + $request = (new DeleteCertificateAuthorityRequest()) + ->setName($formattedName); + $response = $gapicClient->deleteCertificateAuthority($request); + $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.security.privateca.v1.CertificateAuthorityService/DeleteCertificateAuthority', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/deleteCertificateAuthorityTest'); + $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 deleteCertificateAuthorityExceptionTest() + { + $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/deleteCertificateAuthorityTest'); + $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->certificateAuthorityName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]'); + $request = (new DeleteCertificateAuthorityRequest()) + ->setName($formattedName); + $response = $gapicClient->deleteCertificateAuthority($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/deleteCertificateAuthorityTest'); + 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 deleteCertificateTemplateTest() + { + $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/deleteCertificateTemplateTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $expectedResponse = new GPBEmpty(); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/deleteCertificateTemplateTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedName = $gapicClient->certificateTemplateName('[PROJECT]', '[LOCATION]', '[CERTIFICATE_TEMPLATE]'); + $request = (new DeleteCertificateTemplateRequest()) + ->setName($formattedName); + $response = $gapicClient->deleteCertificateTemplate($request); + $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.security.privateca.v1.CertificateAuthorityService/DeleteCertificateTemplate', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/deleteCertificateTemplateTest'); + $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 deleteCertificateTemplateExceptionTest() + { + $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/deleteCertificateTemplateTest'); + $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->certificateTemplateName('[PROJECT]', '[LOCATION]', '[CERTIFICATE_TEMPLATE]'); + $request = (new DeleteCertificateTemplateRequest()) + ->setName($formattedName); + $response = $gapicClient->deleteCertificateTemplate($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/deleteCertificateTemplateTest'); + 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 disableCertificateAuthorityTest() + { + $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/disableCertificateAuthorityTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name2 = 'name2-1052831874'; + $gcsBucket = 'gcsBucket-1720393710'; + $satisfiesPzs = false; + $satisfiesPzi = false; + $expectedResponse = new CertificateAuthority(); + $expectedResponse->setName($name2); + $expectedResponse->setGcsBucket($gcsBucket); + $expectedResponse->setSatisfiesPzs($satisfiesPzs); + $expectedResponse->setSatisfiesPzi($satisfiesPzi); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/disableCertificateAuthorityTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedName = $gapicClient->certificateAuthorityName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]'); + $request = (new DisableCertificateAuthorityRequest()) + ->setName($formattedName); + $response = $gapicClient->disableCertificateAuthority($request); + $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.security.privateca.v1.CertificateAuthorityService/DisableCertificateAuthority', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/disableCertificateAuthorityTest'); + $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 disableCertificateAuthorityExceptionTest() + { + $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/disableCertificateAuthorityTest'); + $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->certificateAuthorityName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]'); + $request = (new DisableCertificateAuthorityRequest()) + ->setName($formattedName); + $response = $gapicClient->disableCertificateAuthority($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/disableCertificateAuthorityTest'); + 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 enableCertificateAuthorityTest() + { + $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/enableCertificateAuthorityTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name2 = 'name2-1052831874'; + $gcsBucket = 'gcsBucket-1720393710'; + $satisfiesPzs = false; + $satisfiesPzi = false; + $expectedResponse = new CertificateAuthority(); + $expectedResponse->setName($name2); + $expectedResponse->setGcsBucket($gcsBucket); + $expectedResponse->setSatisfiesPzs($satisfiesPzs); + $expectedResponse->setSatisfiesPzi($satisfiesPzi); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/enableCertificateAuthorityTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedName = $gapicClient->certificateAuthorityName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]'); + $request = (new EnableCertificateAuthorityRequest()) + ->setName($formattedName); + $response = $gapicClient->enableCertificateAuthority($request); + $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.security.privateca.v1.CertificateAuthorityService/EnableCertificateAuthority', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/enableCertificateAuthorityTest'); + $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 enableCertificateAuthorityExceptionTest() + { + $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/enableCertificateAuthorityTest'); + $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->certificateAuthorityName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]'); + $request = (new EnableCertificateAuthorityRequest()) + ->setName($formattedName); + $response = $gapicClient->enableCertificateAuthority($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/enableCertificateAuthorityTest'); + 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 fetchCaCertsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new FetchCaCertsResponse(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedCaPool = $gapicClient->caPoolName('[PROJECT]', '[LOCATION]', '[CA_POOL]'); + $request = (new FetchCaCertsRequest()) + ->setCaPool($formattedCaPool); + $response = $gapicClient->fetchCaCerts($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.security.privateca.v1.CertificateAuthorityService/FetchCaCerts', $actualFuncCall); + $actualValue = $actualRequestObject->getCaPool(); + $this->assertProtobufEquals($formattedCaPool, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function fetchCaCertsExceptionTest() + { + $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 + $formattedCaPool = $gapicClient->caPoolName('[PROJECT]', '[LOCATION]', '[CA_POOL]'); + $request = (new FetchCaCertsRequest()) + ->setCaPool($formattedCaPool); + try { + $gapicClient->fetchCaCerts($request); + // 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 fetchCertificateAuthorityCsrTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $pemCsr = 'pemCsr-683665829'; + $expectedResponse = new FetchCertificateAuthorityCsrResponse(); + $expectedResponse->setPemCsr($pemCsr); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->certificateAuthorityName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]'); + $request = (new FetchCertificateAuthorityCsrRequest()) + ->setName($formattedName); + $response = $gapicClient->fetchCertificateAuthorityCsr($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.security.privateca.v1.CertificateAuthorityService/FetchCertificateAuthorityCsr', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function fetchCertificateAuthorityCsrExceptionTest() + { + $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->certificateAuthorityName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]'); + $request = (new FetchCertificateAuthorityCsrRequest()) + ->setName($formattedName); + try { + $gapicClient->fetchCertificateAuthorityCsr($request); + // 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 getCaPoolTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $expectedResponse = new CaPool(); + $expectedResponse->setName($name2); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->caPoolName('[PROJECT]', '[LOCATION]', '[CA_POOL]'); + $request = (new GetCaPoolRequest()) + ->setName($formattedName); + $response = $gapicClient->getCaPool($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.security.privateca.v1.CertificateAuthorityService/GetCaPool', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getCaPoolExceptionTest() + { + $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->caPoolName('[PROJECT]', '[LOCATION]', '[CA_POOL]'); + $request = (new GetCaPoolRequest()) + ->setName($formattedName); + try { + $gapicClient->getCaPool($request); + // 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 getCertificateTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $pemCsr = 'pemCsr-683665829'; + $issuerCertificateAuthority = 'issuerCertificateAuthority-750099051'; + $certificateTemplate = 'certificateTemplate2049676834'; + $pemCertificate = 'pemCertificate1234463984'; + $expectedResponse = new Certificate(); + $expectedResponse->setName($name2); + $expectedResponse->setPemCsr($pemCsr); + $expectedResponse->setIssuerCertificateAuthority($issuerCertificateAuthority); + $expectedResponse->setCertificateTemplate($certificateTemplate); + $expectedResponse->setPemCertificate($pemCertificate); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->certificateName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE]'); + $request = (new GetCertificateRequest()) + ->setName($formattedName); + $response = $gapicClient->getCertificate($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.security.privateca.v1.CertificateAuthorityService/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]', '[CA_POOL]', '[CERTIFICATE]'); + $request = (new GetCertificateRequest()) + ->setName($formattedName); + try { + $gapicClient->getCertificate($request); + // 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 getCertificateAuthorityTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $gcsBucket = 'gcsBucket-1720393710'; + $satisfiesPzs = false; + $satisfiesPzi = false; + $expectedResponse = new CertificateAuthority(); + $expectedResponse->setName($name2); + $expectedResponse->setGcsBucket($gcsBucket); + $expectedResponse->setSatisfiesPzs($satisfiesPzs); + $expectedResponse->setSatisfiesPzi($satisfiesPzi); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->certificateAuthorityName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]'); + $request = (new GetCertificateAuthorityRequest()) + ->setName($formattedName); + $response = $gapicClient->getCertificateAuthority($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.security.privateca.v1.CertificateAuthorityService/GetCertificateAuthority', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getCertificateAuthorityExceptionTest() + { + $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->certificateAuthorityName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]'); + $request = (new GetCertificateAuthorityRequest()) + ->setName($formattedName); + try { + $gapicClient->getCertificateAuthority($request); + // 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 getCertificateRevocationListTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $sequenceNumber = 1309190777; + $pemCrl = 'pemCrl-683665866'; + $accessUrl = 'accessUrl-1141680108'; + $revisionId = 'revisionId513861631'; + $expectedResponse = new CertificateRevocationList(); + $expectedResponse->setName($name2); + $expectedResponse->setSequenceNumber($sequenceNumber); + $expectedResponse->setPemCrl($pemCrl); + $expectedResponse->setAccessUrl($accessUrl); + $expectedResponse->setRevisionId($revisionId); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->certificateRevocationListName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]', '[CERTIFICATE_REVOCATION_LIST]'); + $request = (new GetCertificateRevocationListRequest()) + ->setName($formattedName); + $response = $gapicClient->getCertificateRevocationList($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.security.privateca.v1.CertificateAuthorityService/GetCertificateRevocationList', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getCertificateRevocationListExceptionTest() + { + $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->certificateRevocationListName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]', '[CERTIFICATE_REVOCATION_LIST]'); + $request = (new GetCertificateRevocationListRequest()) + ->setName($formattedName); + try { + $gapicClient->getCertificateRevocationList($request); + // 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 getCertificateTemplateTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $description = 'description-1724546052'; + $expectedResponse = new CertificateTemplate(); + $expectedResponse->setName($name2); + $expectedResponse->setDescription($description); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->certificateTemplateName('[PROJECT]', '[LOCATION]', '[CERTIFICATE_TEMPLATE]'); + $request = (new GetCertificateTemplateRequest()) + ->setName($formattedName); + $response = $gapicClient->getCertificateTemplate($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.security.privateca.v1.CertificateAuthorityService/GetCertificateTemplate', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getCertificateTemplateExceptionTest() + { + $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->certificateTemplateName('[PROJECT]', '[LOCATION]', '[CERTIFICATE_TEMPLATE]'); + $request = (new GetCertificateTemplateRequest()) + ->setName($formattedName); + try { + $gapicClient->getCertificateTemplate($request); + // 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 listCaPoolsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $caPoolsElement = new CaPool(); + $caPools = [ + $caPoolsElement, + ]; + $expectedResponse = new ListCaPoolsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setCaPools($caPools); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); + $request = (new ListCaPoolsRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listCaPools($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getCaPools()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.security.privateca.v1.CertificateAuthorityService/ListCaPools', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listCaPoolsExceptionTest() + { + $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]'); + $request = (new ListCaPoolsRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listCaPools($request); + // 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 listCertificateAuthoritiesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $certificateAuthoritiesElement = new CertificateAuthority(); + $certificateAuthorities = [ + $certificateAuthoritiesElement, + ]; + $expectedResponse = new ListCertificateAuthoritiesResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setCertificateAuthorities($certificateAuthorities); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->caPoolName('[PROJECT]', '[LOCATION]', '[CA_POOL]'); + $request = (new ListCertificateAuthoritiesRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listCertificateAuthorities($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getCertificateAuthorities()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.security.privateca.v1.CertificateAuthorityService/ListCertificateAuthorities', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listCertificateAuthoritiesExceptionTest() + { + $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->caPoolName('[PROJECT]', '[LOCATION]', '[CA_POOL]'); + $request = (new ListCertificateAuthoritiesRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listCertificateAuthorities($request); + // 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 listCertificateRevocationListsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $certificateRevocationListsElement = new CertificateRevocationList(); + $certificateRevocationLists = [ + $certificateRevocationListsElement, + ]; + $expectedResponse = new ListCertificateRevocationListsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setCertificateRevocationLists($certificateRevocationLists); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->certificateAuthorityName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]'); + $request = (new ListCertificateRevocationListsRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listCertificateRevocationLists($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getCertificateRevocationLists()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.security.privateca.v1.CertificateAuthorityService/ListCertificateRevocationLists', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listCertificateRevocationListsExceptionTest() + { + $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->certificateAuthorityName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]'); + $request = (new ListCertificateRevocationListsRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listCertificateRevocationLists($request); + // 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 listCertificateTemplatesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $certificateTemplatesElement = new CertificateTemplate(); + $certificateTemplates = [ + $certificateTemplatesElement, + ]; + $expectedResponse = new ListCertificateTemplatesResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setCertificateTemplates($certificateTemplates); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); + $request = (new ListCertificateTemplatesRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listCertificateTemplates($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getCertificateTemplates()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.security.privateca.v1.CertificateAuthorityService/ListCertificateTemplates', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listCertificateTemplatesExceptionTest() + { + $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]'); + $request = (new ListCertificateTemplatesRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listCertificateTemplates($request); + // 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->caPoolName('[PROJECT]', '[LOCATION]', '[CA_POOL]'); + $request = (new ListCertificatesRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listCertificates($request); + $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.security.privateca.v1.CertificateAuthorityService/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->caPoolName('[PROJECT]', '[LOCATION]', '[CA_POOL]'); + $request = (new ListCertificatesRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listCertificates($request); + // 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 revokeCertificateTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $pemCsr = 'pemCsr-683665829'; + $issuerCertificateAuthority = 'issuerCertificateAuthority-750099051'; + $certificateTemplate = 'certificateTemplate2049676834'; + $pemCertificate = 'pemCertificate1234463984'; + $expectedResponse = new Certificate(); + $expectedResponse->setName($name2); + $expectedResponse->setPemCsr($pemCsr); + $expectedResponse->setIssuerCertificateAuthority($issuerCertificateAuthority); + $expectedResponse->setCertificateTemplate($certificateTemplate); + $expectedResponse->setPemCertificate($pemCertificate); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->certificateName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE]'); + $reason = RevocationReason::REVOCATION_REASON_UNSPECIFIED; + $request = (new RevokeCertificateRequest()) + ->setName($formattedName) + ->setReason($reason); + $response = $gapicClient->revokeCertificate($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.security.privateca.v1.CertificateAuthorityService/RevokeCertificate', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $actualValue = $actualRequestObject->getReason(); + $this->assertProtobufEquals($reason, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function revokeCertificateExceptionTest() + { + $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]', '[CA_POOL]', '[CERTIFICATE]'); + $reason = RevocationReason::REVOCATION_REASON_UNSPECIFIED; + $request = (new RevokeCertificateRequest()) + ->setName($formattedName) + ->setReason($reason); + try { + $gapicClient->revokeCertificate($request); + // 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 undeleteCertificateAuthorityTest() + { + $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/undeleteCertificateAuthorityTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name2 = 'name2-1052831874'; + $gcsBucket = 'gcsBucket-1720393710'; + $satisfiesPzs = false; + $satisfiesPzi = false; + $expectedResponse = new CertificateAuthority(); + $expectedResponse->setName($name2); + $expectedResponse->setGcsBucket($gcsBucket); + $expectedResponse->setSatisfiesPzs($satisfiesPzs); + $expectedResponse->setSatisfiesPzi($satisfiesPzi); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/undeleteCertificateAuthorityTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedName = $gapicClient->certificateAuthorityName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]'); + $request = (new UndeleteCertificateAuthorityRequest()) + ->setName($formattedName); + $response = $gapicClient->undeleteCertificateAuthority($request); + $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.security.privateca.v1.CertificateAuthorityService/UndeleteCertificateAuthority', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/undeleteCertificateAuthorityTest'); + $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 undeleteCertificateAuthorityExceptionTest() + { + $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/undeleteCertificateAuthorityTest'); + $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->certificateAuthorityName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]'); + $request = (new UndeleteCertificateAuthorityRequest()) + ->setName($formattedName); + $response = $gapicClient->undeleteCertificateAuthority($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/undeleteCertificateAuthorityTest'); + 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 updateCaPoolTest() + { + $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/updateCaPoolTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $expectedResponse = new CaPool(); + $expectedResponse->setName($name); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/updateCaPoolTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $caPool = new CaPool(); + $caPoolTier = Tier::TIER_UNSPECIFIED; + $caPool->setTier($caPoolTier); + $updateMask = new FieldMask(); + $request = (new UpdateCaPoolRequest()) + ->setCaPool($caPool) + ->setUpdateMask($updateMask); + $response = $gapicClient->updateCaPool($request); + $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.security.privateca.v1.CertificateAuthorityService/UpdateCaPool', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getCaPool(); + $this->assertProtobufEquals($caPool, $actualValue); + $actualValue = $actualApiRequestObject->getUpdateMask(); + $this->assertProtobufEquals($updateMask, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updateCaPoolTest'); + $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 updateCaPoolExceptionTest() + { + $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/updateCaPoolTest'); + $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 + $caPool = new CaPool(); + $caPoolTier = Tier::TIER_UNSPECIFIED; + $caPool->setTier($caPoolTier); + $updateMask = new FieldMask(); + $request = (new UpdateCaPoolRequest()) + ->setCaPool($caPool) + ->setUpdateMask($updateMask); + $response = $gapicClient->updateCaPool($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updateCaPoolTest'); + 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 updateCertificateTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $pemCsr = 'pemCsr-683665829'; + $issuerCertificateAuthority = 'issuerCertificateAuthority-750099051'; + $certificateTemplate = 'certificateTemplate2049676834'; + $pemCertificate = 'pemCertificate1234463984'; + $expectedResponse = new Certificate(); + $expectedResponse->setName($name); + $expectedResponse->setPemCsr($pemCsr); + $expectedResponse->setIssuerCertificateAuthority($issuerCertificateAuthority); + $expectedResponse->setCertificateTemplate($certificateTemplate); + $expectedResponse->setPemCertificate($pemCertificate); + $transport->addResponse($expectedResponse); + // Mock request + $certificate = new Certificate(); + $certificateLifetime = new Duration(); + $certificate->setLifetime($certificateLifetime); + $updateMask = new FieldMask(); + $request = (new UpdateCertificateRequest()) + ->setCertificate($certificate) + ->setUpdateMask($updateMask); + $response = $gapicClient->updateCertificate($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.security.privateca.v1.CertificateAuthorityService/UpdateCertificate', $actualFuncCall); + $actualValue = $actualRequestObject->getCertificate(); + $this->assertProtobufEquals($certificate, $actualValue); + $actualValue = $actualRequestObject->getUpdateMask(); + $this->assertProtobufEquals($updateMask, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateCertificateExceptionTest() + { + $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 + $certificate = new Certificate(); + $certificateLifetime = new Duration(); + $certificate->setLifetime($certificateLifetime); + $updateMask = new FieldMask(); + $request = (new UpdateCertificateRequest()) + ->setCertificate($certificate) + ->setUpdateMask($updateMask); + try { + $gapicClient->updateCertificate($request); + // 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 updateCertificateAuthorityTest() + { + $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/updateCertificateAuthorityTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $gcsBucket = 'gcsBucket-1720393710'; + $satisfiesPzs = false; + $satisfiesPzi = false; + $expectedResponse = new CertificateAuthority(); + $expectedResponse->setName($name); + $expectedResponse->setGcsBucket($gcsBucket); + $expectedResponse->setSatisfiesPzs($satisfiesPzs); + $expectedResponse->setSatisfiesPzi($satisfiesPzi); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/updateCertificateAuthorityTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $certificateAuthority = new CertificateAuthority(); + $certificateAuthorityType = Type::TYPE_UNSPECIFIED; + $certificateAuthority->setType($certificateAuthorityType); + $certificateAuthorityConfig = new CertificateConfig(); + $configSubjectConfig = new SubjectConfig(); + $certificateAuthorityConfig->setSubjectConfig($configSubjectConfig); + $configX509Config = new X509Parameters(); + $certificateAuthorityConfig->setX509Config($configX509Config); + $certificateAuthority->setConfig($certificateAuthorityConfig); + $certificateAuthorityLifetime = new Duration(); + $certificateAuthority->setLifetime($certificateAuthorityLifetime); + $certificateAuthorityKeySpec = new KeyVersionSpec(); + $certificateAuthority->setKeySpec($certificateAuthorityKeySpec); + $updateMask = new FieldMask(); + $request = (new UpdateCertificateAuthorityRequest()) + ->setCertificateAuthority($certificateAuthority) + ->setUpdateMask($updateMask); + $response = $gapicClient->updateCertificateAuthority($request); + $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.security.privateca.v1.CertificateAuthorityService/UpdateCertificateAuthority', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getCertificateAuthority(); + $this->assertProtobufEquals($certificateAuthority, $actualValue); + $actualValue = $actualApiRequestObject->getUpdateMask(); + $this->assertProtobufEquals($updateMask, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updateCertificateAuthorityTest'); + $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 updateCertificateAuthorityExceptionTest() + { + $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/updateCertificateAuthorityTest'); + $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 + $certificateAuthority = new CertificateAuthority(); + $certificateAuthorityType = Type::TYPE_UNSPECIFIED; + $certificateAuthority->setType($certificateAuthorityType); + $certificateAuthorityConfig = new CertificateConfig(); + $configSubjectConfig = new SubjectConfig(); + $certificateAuthorityConfig->setSubjectConfig($configSubjectConfig); + $configX509Config = new X509Parameters(); + $certificateAuthorityConfig->setX509Config($configX509Config); + $certificateAuthority->setConfig($certificateAuthorityConfig); + $certificateAuthorityLifetime = new Duration(); + $certificateAuthority->setLifetime($certificateAuthorityLifetime); + $certificateAuthorityKeySpec = new KeyVersionSpec(); + $certificateAuthority->setKeySpec($certificateAuthorityKeySpec); + $updateMask = new FieldMask(); + $request = (new UpdateCertificateAuthorityRequest()) + ->setCertificateAuthority($certificateAuthority) + ->setUpdateMask($updateMask); + $response = $gapicClient->updateCertificateAuthority($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updateCertificateAuthorityTest'); + 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 updateCertificateRevocationListTest() + { + $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/updateCertificateRevocationListTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $sequenceNumber = 1309190777; + $pemCrl = 'pemCrl-683665866'; + $accessUrl = 'accessUrl-1141680108'; + $revisionId = 'revisionId513861631'; + $expectedResponse = new CertificateRevocationList(); + $expectedResponse->setName($name); + $expectedResponse->setSequenceNumber($sequenceNumber); + $expectedResponse->setPemCrl($pemCrl); + $expectedResponse->setAccessUrl($accessUrl); + $expectedResponse->setRevisionId($revisionId); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/updateCertificateRevocationListTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $certificateRevocationList = new CertificateRevocationList(); + $updateMask = new FieldMask(); + $request = (new UpdateCertificateRevocationListRequest()) + ->setCertificateRevocationList($certificateRevocationList) + ->setUpdateMask($updateMask); + $response = $gapicClient->updateCertificateRevocationList($request); + $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.security.privateca.v1.CertificateAuthorityService/UpdateCertificateRevocationList', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getCertificateRevocationList(); + $this->assertProtobufEquals($certificateRevocationList, $actualValue); + $actualValue = $actualApiRequestObject->getUpdateMask(); + $this->assertProtobufEquals($updateMask, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updateCertificateRevocationListTest'); + $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 updateCertificateRevocationListExceptionTest() + { + $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/updateCertificateRevocationListTest'); + $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 + $certificateRevocationList = new CertificateRevocationList(); + $updateMask = new FieldMask(); + $request = (new UpdateCertificateRevocationListRequest()) + ->setCertificateRevocationList($certificateRevocationList) + ->setUpdateMask($updateMask); + $response = $gapicClient->updateCertificateRevocationList($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updateCertificateRevocationListTest'); + 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 updateCertificateTemplateTest() + { + $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/updateCertificateTemplateTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $description = 'description-1724546052'; + $expectedResponse = new CertificateTemplate(); + $expectedResponse->setName($name); + $expectedResponse->setDescription($description); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/updateCertificateTemplateTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $certificateTemplate = new CertificateTemplate(); + $updateMask = new FieldMask(); + $request = (new UpdateCertificateTemplateRequest()) + ->setCertificateTemplate($certificateTemplate) + ->setUpdateMask($updateMask); + $response = $gapicClient->updateCertificateTemplate($request); + $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.security.privateca.v1.CertificateAuthorityService/UpdateCertificateTemplate', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getCertificateTemplate(); + $this->assertProtobufEquals($certificateTemplate, $actualValue); + $actualValue = $actualApiRequestObject->getUpdateMask(); + $this->assertProtobufEquals($updateMask, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updateCertificateTemplateTest'); + $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 updateCertificateTemplateExceptionTest() + { + $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/updateCertificateTemplateTest'); + $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 + $certificateTemplate = new CertificateTemplate(); + $updateMask = new FieldMask(); + $request = (new UpdateCertificateTemplateRequest()) + ->setCertificateTemplate($certificateTemplate) + ->setUpdateMask($updateMask); + $response = $gapicClient->updateCertificateTemplate($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updateCertificateTemplateTest'); + 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); + $request = new GetLocationRequest(); + $response = $gapicClient->getLocation($request); + $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); + $request = new GetLocationRequest(); + try { + $gapicClient->getLocation($request); + // 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); + $request = new ListLocationsRequest(); + $response = $gapicClient->listLocations($request); + $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); + $request = new ListLocationsRequest(); + try { + $gapicClient->listLocations($request); + // 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'; + $request = (new GetIamPolicyRequest()) + ->setResource($resource); + $response = $gapicClient->getIamPolicy($request); + $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'; + $request = (new GetIamPolicyRequest()) + ->setResource($resource); + try { + $gapicClient->getIamPolicy($request); + // 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(); + $request = (new SetIamPolicyRequest()) + ->setResource($resource) + ->setPolicy($policy); + $response = $gapicClient->setIamPolicy($request); + $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(); + $request = (new SetIamPolicyRequest()) + ->setResource($resource) + ->setPolicy($policy); + try { + $gapicClient->setIamPolicy($request); + // 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 = []; + $request = (new TestIamPermissionsRequest()) + ->setResource($resource) + ->setPermissions($permissions); + $response = $gapicClient->testIamPermissions($request); + $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 = []; + $request = (new TestIamPermissionsRequest()) + ->setResource($resource) + ->setPermissions($permissions); + try { + $gapicClient->testIamPermissions($request); + // 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 activateCertificateAuthorityAsyncTest() + { + $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/activateCertificateAuthorityTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name2 = 'name2-1052831874'; + $gcsBucket = 'gcsBucket-1720393710'; + $satisfiesPzs = false; + $satisfiesPzi = false; + $expectedResponse = new CertificateAuthority(); + $expectedResponse->setName($name2); + $expectedResponse->setGcsBucket($gcsBucket); + $expectedResponse->setSatisfiesPzs($satisfiesPzs); + $expectedResponse->setSatisfiesPzi($satisfiesPzi); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/activateCertificateAuthorityTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedName = $gapicClient->certificateAuthorityName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]'); + $pemCaCertificate = 'pemCaCertificate1041594685'; + $subordinateConfig = new SubordinateConfig(); + $subordinateConfigCertificateAuthority = $gapicClient->certificateAuthorityName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]'); + $subordinateConfig->setCertificateAuthority($subordinateConfigCertificateAuthority); + $request = (new ActivateCertificateAuthorityRequest()) + ->setName($formattedName) + ->setPemCaCertificate($pemCaCertificate) + ->setSubordinateConfig($subordinateConfig); + $response = $gapicClient->activateCertificateAuthorityAsync($request)->wait(); + $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.security.privateca.v1.CertificateAuthorityService/ActivateCertificateAuthority', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $actualValue = $actualApiRequestObject->getPemCaCertificate(); + $this->assertProtobufEquals($pemCaCertificate, $actualValue); + $actualValue = $actualApiRequestObject->getSubordinateConfig(); + $this->assertProtobufEquals($subordinateConfig, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/activateCertificateAuthorityTest'); + $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()); + } +} diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/GPBMetadata/Google/Api/Servicemanagement/V1/Resources.php b/owl-bot-staging/ServiceManagement/v1/proto/src/GPBMetadata/Google/Api/Servicemanagement/V1/Resources.php new file mode 100644 index 000000000000..ed8e9e4a6998 --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/proto/src/GPBMetadata/Google/Api/Servicemanagement/V1/Resources.php @@ -0,0 +1,27 @@ +internalAddGeneratedFile( + "\x0A\xD5\x11\x0A/google/api/servicemanagement/v1/resources.proto\x12\x1Fgoogle.api.servicemanagement.v1\x1A\x1Fgoogle/api/field_behavior.proto\x1A\x1Fgoogle/protobuf/timestamp.proto\"C\x0A\x0EManagedService\x12\x14\x0A\x0Cservice_name\x18\x02 \x01(\x09\x12\x1B\x0A\x13producer_project_id\x18\x03 \x01(\x09\"\x91\x03\x0A\x11OperationMetadata\x12\x16\x0A\x0Eresource_names\x18\x01 \x03(\x09\x12F\x0A\x05steps\x18\x02 \x03(\x0B27.google.api.servicemanagement.v1.OperationMetadata.Step\x12\x1B\x0A\x13progress_percentage\x18\x03 \x01(\x05\x12.\x0A\x0Astart_time\x18\x04 \x01(\x0B2\x1A.google.protobuf.Timestamp\x1Af\x0A\x04Step\x12\x13\x0A\x0Bdescription\x18\x02 \x01(\x09\x12I\x0A\x06status\x18\x04 \x01(\x0E29.google.api.servicemanagement.v1.OperationMetadata.Status\"g\x0A\x06Status\x12\x16\x0A\x12STATUS_UNSPECIFIED\x10\x00\x12\x08\x0A\x04DONE\x10\x01\x12\x0F\x0A\x0BNOT_STARTED\x10\x02\x12\x0F\x0A\x0BIN_PROGRESS\x10\x03\x12\x0A\x0A\x06FAILED\x10\x04\x12\x0D\x0A\x09CANCELLED\x10\x05\"\x8F\x01\x0A\x0ADiagnostic\x12\x10\x0A\x08location\x18\x01 \x01(\x09\x12>\x0A\x04kind\x18\x02 \x01(\x0E20.google.api.servicemanagement.v1.Diagnostic.Kind\x12\x0F\x0A\x07message\x18\x03 \x01(\x09\"\x1E\x0A\x04Kind\x12\x0B\x0A\x07WARNING\x10\x00\x12\x09\x0A\x05ERROR\x10\x01\"V\x0A\x0CConfigSource\x12\x0A\x0A\x02id\x18\x05 \x01(\x09\x12:\x0A\x05files\x18\x02 \x03(\x0B2+.google.api.servicemanagement.v1.ConfigFile\"\x95\x02\x0A\x0AConfigFile\x12\x11\x0A\x09file_path\x18\x01 \x01(\x09\x12\x15\x0A\x0Dfile_contents\x18\x03 \x01(\x0C\x12G\x0A\x09file_type\x18\x04 \x01(\x0E24.google.api.servicemanagement.v1.ConfigFile.FileType\"\x93\x01\x0A\x08FileType\x12\x19\x0A\x15FILE_TYPE_UNSPECIFIED\x10\x00\x12\x17\x0A\x13SERVICE_CONFIG_YAML\x10\x01\x12\x11\x0A\x0DOPEN_API_JSON\x10\x02\x12\x11\x0A\x0DOPEN_API_YAML\x10\x03\x12\x1D\x0A\x19FILE_DESCRIPTOR_SET_PROTO\x10\x04\x12\x0E\x0A\x0APROTO_FILE\x10\x06\"\x19\x0A\x09ConfigRef\x12\x0C\x0A\x04name\x18\x01 \x01(\x09\"@\x0A\x0CChangeReport\x120\x0A\x0Econfig_changes\x18\x01 \x03(\x0B2\x18.google.api.ConfigChange\"\xF9\x05\x0A\x07Rollout\x12\x17\x0A\x0Arollout_id\x18\x01 \x01(\x09B\x03\xE0A\x01\x12/\x0A\x0Bcreate_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.Timestamp\x12\x12\x0A\x0Acreated_by\x18\x03 \x01(\x09\x12F\x0A\x06status\x18\x04 \x01(\x0E26.google.api.servicemanagement.v1.Rollout.RolloutStatus\x12c\x0A\x18traffic_percent_strategy\x18\x05 \x01(\x0B2?.google.api.servicemanagement.v1.Rollout.TrafficPercentStrategyH\x00\x12b\x0A\x17delete_service_strategy\x18\xC8\x01 \x01(\x0B2>.google.api.servicemanagement.v1.Rollout.DeleteServiceStrategyH\x00\x12\x14\x0A\x0Cservice_name\x18\x08 \x01(\x09\x1A\xB3\x01\x0A\x16TrafficPercentStrategy\x12e\x0A\x0Bpercentages\x18\x01 \x03(\x0B2P.google.api.servicemanagement.v1.Rollout.TrafficPercentStrategy.PercentagesEntry\x1A2\x0A\x10PercentagesEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12\x0D\x0A\x05value\x18\x02 \x01(\x01:\x028\x01\x1A\x17\x0A\x15DeleteServiceStrategy\"\x8D\x01\x0A\x0DRolloutStatus\x12\x1E\x0A\x1AROLLOUT_STATUS_UNSPECIFIED\x10\x00\x12\x0F\x0A\x0BIN_PROGRESS\x10\x01\x12\x0B\x0A\x07SUCCESS\x10\x02\x12\x0D\x0A\x09CANCELLED\x10\x03\x12\x0A\x0A\x06FAILED\x10\x04\x12\x0B\x0A\x07PENDING\x10\x05\x12\x16\x0A\x12FAILED_ROLLED_BACK\x10\x06B\x0A\x0A\x08strategyB\x82\x02\x0A#com.google.api.servicemanagement.v1B\x0EResourcesProtoP\x01ZScloud.google.com/go/servicemanagement/apiv1/servicemanagementpb;servicemanagementpb\xA2\x02\x04GASM\xAA\x02!Google.Cloud.ServiceManagement.V1\xCA\x02!Google\\Cloud\\ServiceManagement\\V1\xEA\x02\$Google::Cloud::ServiceManagement::V1b\x06proto3" + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/GPBMetadata/Google/Api/Servicemanagement/V1/Servicemanager.php b/owl-bot-staging/ServiceManagement/v1/proto/src/GPBMetadata/Google/Api/Servicemanagement/V1/Servicemanager.php new file mode 100644 index 000000000000..b20a66c1e099 --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/proto/src/GPBMetadata/Google/Api/Servicemanagement/V1/Servicemanager.php @@ -0,0 +1,32 @@ +internalAddGeneratedFile( + "\x0A\xC6.\x0A4google/api/servicemanagement/v1/servicemanager.proto\x12\x1Fgoogle.api.servicemanagement.v1\x1A\x17google/api/client.proto\x1A\x1Fgoogle/api/field_behavior.proto\x1A\x18google/api/service.proto\x1A/google/api/servicemanagement/v1/resources.proto\x1A#google/longrunning/operations.proto\x1A\x19google/protobuf/any.proto\x1A\x1Bgoogle/protobuf/empty.proto\"r\x0A\x13ListServicesRequest\x12\x1B\x0A\x13producer_project_id\x18\x01 \x01(\x09\x12\x11\x0A\x09page_size\x18\x05 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x06 \x01(\x09\x12\x17\x0A\x0Bconsumer_id\x18\x07 \x01(\x09B\x02\x18\x01\"r\x0A\x14ListServicesResponse\x12A\x0A\x08services\x18\x01 \x03(\x0B2/.google.api.servicemanagement.v1.ManagedService\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\".\x0A\x11GetServiceRequest\x12\x19\x0A\x0Cservice_name\x18\x01 \x01(\x09B\x03\xE0A\x02\"]\x0A\x14CreateServiceRequest\x12E\x0A\x07service\x18\x01 \x01(\x0B2/.google.api.servicemanagement.v1.ManagedServiceB\x03\xE0A\x02\"1\x0A\x14DeleteServiceRequest\x12\x19\x0A\x0Cservice_name\x18\x01 \x01(\x09B\x03\xE0A\x02\"3\x0A\x16UndeleteServiceRequest\x12\x19\x0A\x0Cservice_name\x18\x01 \x01(\x09B\x03\xE0A\x02\"[\x0A\x17UndeleteServiceResponse\x12@\x0A\x07service\x18\x01 \x01(\x0B2/.google.api.servicemanagement.v1.ManagedService\"\xC2\x01\x0A\x17GetServiceConfigRequest\x12\x19\x0A\x0Cservice_name\x18\x01 \x01(\x09B\x03\xE0A\x02\x12\x16\x0A\x09config_id\x18\x02 \x01(\x09B\x03\xE0A\x02\x12Q\x0A\x04view\x18\x03 \x01(\x0E2C.google.api.servicemanagement.v1.GetServiceConfigRequest.ConfigView\"!\x0A\x0AConfigView\x12\x09\x0A\x05BASIC\x10\x00\x12\x08\x0A\x04FULL\x10\x01\"]\x0A\x19ListServiceConfigsRequest\x12\x19\x0A\x0Cservice_name\x18\x01 \x01(\x09B\x03\xE0A\x02\x12\x12\x0A\x0Apage_token\x18\x02 \x01(\x09\x12\x11\x0A\x09page_size\x18\x03 \x01(\x05\"c\x0A\x1AListServiceConfigsResponse\x12,\x0A\x0Fservice_configs\x18\x01 \x03(\x0B2\x13.google.api.Service\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\"i\x0A\x1ACreateServiceConfigRequest\x12\x19\x0A\x0Cservice_name\x18\x01 \x01(\x09B\x03\xE0A\x02\x120\x0A\x0Eservice_config\x18\x02 \x01(\x0B2\x13.google.api.ServiceB\x03\xE0A\x02\"\x9D\x01\x0A\x19SubmitConfigSourceRequest\x12\x19\x0A\x0Cservice_name\x18\x01 \x01(\x09B\x03\xE0A\x02\x12I\x0A\x0Dconfig_source\x18\x02 \x01(\x0B2-.google.api.servicemanagement.v1.ConfigSourceB\x03\xE0A\x02\x12\x1A\x0A\x0Dvalidate_only\x18\x03 \x01(\x08B\x03\xE0A\x01\"I\x0A\x1ASubmitConfigSourceResponse\x12+\x0A\x0Eservice_config\x18\x01 \x01(\x0B2\x13.google.api.Service\"x\x0A\x1BCreateServiceRolloutRequest\x12\x19\x0A\x0Cservice_name\x18\x01 \x01(\x09B\x03\xE0A\x02\x12>\x0A\x07rollout\x18\x02 \x01(\x0B2(.google.api.servicemanagement.v1.RolloutB\x03\xE0A\x02\"s\x0A\x1AListServiceRolloutsRequest\x12\x19\x0A\x0Cservice_name\x18\x01 \x01(\x09B\x03\xE0A\x02\x12\x12\x0A\x0Apage_token\x18\x02 \x01(\x09\x12\x11\x0A\x09page_size\x18\x03 \x01(\x05\x12\x13\x0A\x06filter\x18\x04 \x01(\x09B\x03\xE0A\x02\"r\x0A\x1BListServiceRolloutsResponse\x12:\x0A\x08rollouts\x18\x01 \x03(\x0B2(.google.api.servicemanagement.v1.Rollout\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\"N\x0A\x18GetServiceRolloutRequest\x12\x19\x0A\x0Cservice_name\x18\x01 \x01(\x09B\x03\xE0A\x02\x12\x17\x0A\x0Arollout_id\x18\x02 \x01(\x09B\x03\xE0A\x02\"\x17\x0A\x15EnableServiceResponse\"{\x0A\x1BGenerateConfigReportRequest\x12-\x0A\x0Anew_config\x18\x01 \x01(\x0B2\x14.google.protobuf.AnyB\x03\xE0A\x02\x12-\x0A\x0Aold_config\x18\x02 \x01(\x0B2\x14.google.protobuf.AnyB\x03\xE0A\x01\"\xC9\x01\x0A\x1CGenerateConfigReportResponse\x12\x14\x0A\x0Cservice_name\x18\x01 \x01(\x09\x12\x0A\x0A\x02id\x18\x02 \x01(\x09\x12E\x0A\x0Echange_reports\x18\x03 \x03(\x0B2-.google.api.servicemanagement.v1.ChangeReport\x12@\x0A\x0Bdiagnostics\x18\x04 \x03(\x0B2+.google.api.servicemanagement.v1.Diagnostic2\xC8\x19\x0A\x0EServiceManager\x12\xB3\x01\x0A\x0CListServices\x124.google.api.servicemanagement.v1.ListServicesRequest\x1A5.google.api.servicemanagement.v1.ListServicesResponse\"6\xDAA\x1Fproducer_project_id,consumer_id\x82\xD3\xE4\x93\x02\x0E\x12\x0C/v1/services\x12\xA5\x01\x0A\x0AGetService\x122.google.api.servicemanagement.v1.GetServiceRequest\x1A/.google.api.servicemanagement.v1.ManagedService\"2\xDAA\x0Cservice_name\x82\xD3\xE4\x93\x02\x1D\x12\x1B/v1/services/{service_name}\x12\xF5\x01\x0A\x0DCreateService\x125.google.api.servicemanagement.v1.CreateServiceRequest\x1A\x1D.google.longrunning.Operation\"\x8D\x01\xCAAc\x0A.google.api.servicemanagement.v1.ManagedService\x121google.api.servicemanagement.v1.OperationMetadata\xDAA\x07service\x82\xD3\xE4\x93\x02\x17\"\x0C/v1/services:\x07service\x12\xE6\x01\x0A\x0DDeleteService\x125.google.api.servicemanagement.v1.DeleteServiceRequest\x1A\x1D.google.longrunning.Operation\"\x7F\xCAAJ\x0A\x15google.protobuf.Empty\x121google.api.servicemanagement.v1.OperationMetadata\xDAA\x0Cservice_name\x82\xD3\xE4\x93\x02\x1D*\x1B/v1/services/{service_name}\x12\x96\x02\x0A\x0FUndeleteService\x127.google.api.servicemanagement.v1.UndeleteServiceRequest\x1A\x1D.google.longrunning.Operation\"\xAA\x01\xCAAl\x0A7google.api.servicemanagement.v1.UndeleteServiceResponse\x121google.api.servicemanagement.v1.OperationMetadata\xDAA\x0Cservice_name\x82\xD3\xE4\x93\x02&\"\$/v1/services/{service_name}:undelete\x12\xC9\x01\x0A\x12ListServiceConfigs\x12:.google.api.servicemanagement.v1.ListServiceConfigsRequest\x1A;.google.api.servicemanagement.v1.ListServiceConfigsResponse\":\xDAA\x0Cservice_name\x82\xD3\xE4\x93\x02%\x12#/v1/services/{service_name}/configs\x12\xDE\x01\x0A\x10GetServiceConfig\x128.google.api.servicemanagement.v1.GetServiceConfigRequest\x1A\x13.google.api.Service\"{\xDAA\x1Bservice_name,config_id,view\x82\xD3\xE4\x93\x02W\x12//v1/services/{service_name}/configs/{config_id}Z\$\x12\"/v1/services/{service_name}/config\x12\xC2\x01\x0A\x13CreateServiceConfig\x12;.google.api.servicemanagement.v1.CreateServiceConfigRequest\x1A\x13.google.api.Service\"Y\xDAA\x1Bservice_name,service_config\x82\xD3\xE4\x93\x025\"#/v1/services/{service_name}/configs:\x0Eservice_config\x12\xC4\x02\x0A\x12SubmitConfigSource\x12:.google.api.servicemanagement.v1.SubmitConfigSourceRequest\x1A\x1D.google.longrunning.Operation\"\xD2\x01\xCAAo\x0A:google.api.servicemanagement.v1.SubmitConfigSourceResponse\x121google.api.servicemanagement.v1.OperationMetadata\xDAA(service_name,config_source,validate_only\x82\xD3\xE4\x93\x02/\"*/v1/services/{service_name}/configs:submit:\x01*\x12\xD4\x01\x0A\x13ListServiceRollouts\x12;.google.api.servicemanagement.v1.ListServiceRolloutsRequest\x1A<.google.api.servicemanagement.v1.ListServiceRolloutsResponse\"B\xDAA\x13service_name,filter\x82\xD3\xE4\x93\x02&\x12\$/v1/services/{service_name}/rollouts\x12\xCD\x01\x0A\x11GetServiceRollout\x129.google.api.servicemanagement.v1.GetServiceRolloutRequest\x1A(.google.api.servicemanagement.v1.Rollout\"S\xDAA\x17service_name,rollout_id\x82\xD3\xE4\x93\x023\x121/v1/services/{service_name}/rollouts/{rollout_id}\x12\xA1\x02\x0A\x14CreateServiceRollout\x12<.google.api.servicemanagement.v1.CreateServiceRolloutRequest\x1A\x1D.google.longrunning.Operation\"\xAB\x01\xCAA\\\x0A'google.api.servicemanagement.v1.Rollout\x121google.api.servicemanagement.v1.OperationMetadata\xDAA\x14service_name,rollout\x82\xD3\xE4\x93\x02/\"\$/v1/services/{service_name}/rollouts:\x07rollout\x12\xD9\x01\x0A\x14GenerateConfigReport\x12<.google.api.servicemanagement.v1.GenerateConfigReportRequest\x1A=.google.api.servicemanagement.v1.GenerateConfigReportResponse\"D\xDAA\x15new_config,old_config\x82\xD3\xE4\x93\x02&\"!/v1/services:generateConfigReport:\x01*\x1A\xFD\x01\xCAA servicemanagement.googleapis.com\xD2A\xD6\x01https://www.googleapis.com/auth/cloud-platform,https://www.googleapis.com/auth/cloud-platform.read-only,https://www.googleapis.com/auth/service.management,https://www.googleapis.com/auth/service.management.readonlyB\x87\x02\x0A#com.google.api.servicemanagement.v1B\x13ServiceManagerProtoP\x01ZScloud.google.com/go/servicemanagement/apiv1/servicemanagementpb;servicemanagementpb\xA2\x02\x04GASM\xAA\x02!Google.Cloud.ServiceManagement.V1\xCA\x02!Google\\Cloud\\ServiceManagement\\V1\xEA\x02\$Google::Cloud::ServiceManagement::V1b\x06proto3" + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ChangeReport.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ChangeReport.php new file mode 100644 index 000000000000..b0ebbfc0c19a --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ChangeReport.php @@ -0,0 +1,85 @@ +google.api.servicemanagement.v1.ChangeReport + */ +class ChangeReport extends \Google\Protobuf\Internal\Message +{ + /** + * List of changes between two service configurations. + * The changes will be alphabetically sorted based on the identifier + * of each change. + * A ConfigChange identifier is a dot separated path to the configuration. + * Example: visibility.rules[selector='LibraryService.CreateBook'].restriction + * + * Generated from protobuf field repeated .google.api.ConfigChange config_changes = 1; + */ + private $config_changes; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Api\ConfigChange[] $config_changes + * List of changes between two service configurations. + * The changes will be alphabetically sorted based on the identifier + * of each change. + * A ConfigChange identifier is a dot separated path to the configuration. + * Example: visibility.rules[selector='LibraryService.CreateBook'].restriction + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Api\Servicemanagement\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * List of changes between two service configurations. + * The changes will be alphabetically sorted based on the identifier + * of each change. + * A ConfigChange identifier is a dot separated path to the configuration. + * Example: visibility.rules[selector='LibraryService.CreateBook'].restriction + * + * Generated from protobuf field repeated .google.api.ConfigChange config_changes = 1; + * @return RepeatedField<\Google\Api\ConfigChange> + */ + public function getConfigChanges() + { + return $this->config_changes; + } + + /** + * List of changes between two service configurations. + * The changes will be alphabetically sorted based on the identifier + * of each change. + * A ConfigChange identifier is a dot separated path to the configuration. + * Example: visibility.rules[selector='LibraryService.CreateBook'].restriction + * + * Generated from protobuf field repeated .google.api.ConfigChange config_changes = 1; + * @param \Google\Api\ConfigChange[] $var + * @return $this + */ + public function setConfigChanges($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Api\ConfigChange::class); + $this->config_changes = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ConfigFile.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ConfigFile.php new file mode 100644 index 000000000000..2d558c9d1844 --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ConfigFile.php @@ -0,0 +1,135 @@ +google.api.servicemanagement.v1.ConfigFile + */ +class ConfigFile extends \Google\Protobuf\Internal\Message +{ + /** + * The file name of the configuration file (full or relative path). + * + * Generated from protobuf field string file_path = 1; + */ + protected $file_path = ''; + /** + * The bytes that constitute the file. + * + * Generated from protobuf field bytes file_contents = 3; + */ + protected $file_contents = ''; + /** + * The type of configuration file this represents. + * + * Generated from protobuf field .google.api.servicemanagement.v1.ConfigFile.FileType file_type = 4; + */ + protected $file_type = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $file_path + * The file name of the configuration file (full or relative path). + * @type string $file_contents + * The bytes that constitute the file. + * @type int $file_type + * The type of configuration file this represents. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Api\Servicemanagement\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * The file name of the configuration file (full or relative path). + * + * Generated from protobuf field string file_path = 1; + * @return string + */ + public function getFilePath() + { + return $this->file_path; + } + + /** + * The file name of the configuration file (full or relative path). + * + * Generated from protobuf field string file_path = 1; + * @param string $var + * @return $this + */ + public function setFilePath($var) + { + GPBUtil::checkString($var, True); + $this->file_path = $var; + + return $this; + } + + /** + * The bytes that constitute the file. + * + * Generated from protobuf field bytes file_contents = 3; + * @return string + */ + public function getFileContents() + { + return $this->file_contents; + } + + /** + * The bytes that constitute the file. + * + * Generated from protobuf field bytes file_contents = 3; + * @param string $var + * @return $this + */ + public function setFileContents($var) + { + GPBUtil::checkString($var, False); + $this->file_contents = $var; + + return $this; + } + + /** + * The type of configuration file this represents. + * + * Generated from protobuf field .google.api.servicemanagement.v1.ConfigFile.FileType file_type = 4; + * @return int + */ + public function getFileType() + { + return $this->file_type; + } + + /** + * The type of configuration file this represents. + * + * Generated from protobuf field .google.api.servicemanagement.v1.ConfigFile.FileType file_type = 4; + * @param int $var + * @return $this + */ + public function setFileType($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\ServiceManagement\V1\ConfigFile\FileType::class); + $this->file_type = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ConfigFile/FileType.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ConfigFile/FileType.php new file mode 100644 index 000000000000..b74e194525ef --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ConfigFile/FileType.php @@ -0,0 +1,88 @@ +google.api.servicemanagement.v1.ConfigFile.FileType + */ +class FileType +{ + /** + * Unknown file type. + * + * Generated from protobuf enum FILE_TYPE_UNSPECIFIED = 0; + */ + const FILE_TYPE_UNSPECIFIED = 0; + /** + * YAML-specification of service. + * + * Generated from protobuf enum SERVICE_CONFIG_YAML = 1; + */ + const SERVICE_CONFIG_YAML = 1; + /** + * OpenAPI specification, serialized in JSON. + * + * Generated from protobuf enum OPEN_API_JSON = 2; + */ + const OPEN_API_JSON = 2; + /** + * OpenAPI specification, serialized in YAML. + * + * Generated from protobuf enum OPEN_API_YAML = 3; + */ + const OPEN_API_YAML = 3; + /** + * FileDescriptorSet, generated by protoc. + * To generate, use protoc with imports and source info included. + * For an example test.proto file, the following command would put the value + * in a new file named out.pb. + * $protoc --include_imports --include_source_info test.proto -o out.pb + * + * Generated from protobuf enum FILE_DESCRIPTOR_SET_PROTO = 4; + */ + const FILE_DESCRIPTOR_SET_PROTO = 4; + /** + * Uncompiled Proto file. Used for storage and display purposes only, + * currently server-side compilation is not supported. Should match the + * inputs to 'protoc' command used to generated FILE_DESCRIPTOR_SET_PROTO. A + * file of this type can only be included if at least one file of type + * FILE_DESCRIPTOR_SET_PROTO is included. + * + * Generated from protobuf enum PROTO_FILE = 6; + */ + const PROTO_FILE = 6; + + private static $valueToName = [ + self::FILE_TYPE_UNSPECIFIED => 'FILE_TYPE_UNSPECIFIED', + self::SERVICE_CONFIG_YAML => 'SERVICE_CONFIG_YAML', + self::OPEN_API_JSON => 'OPEN_API_JSON', + self::OPEN_API_YAML => 'OPEN_API_YAML', + self::FILE_DESCRIPTOR_SET_PROTO => 'FILE_DESCRIPTOR_SET_PROTO', + self::PROTO_FILE => 'PROTO_FILE', + ]; + + 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/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ConfigRef.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ConfigRef.php new file mode 100644 index 000000000000..9b311d9c1bf1 --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ConfigRef.php @@ -0,0 +1,71 @@ +google.api.servicemanagement.v1.ConfigRef + */ +class ConfigRef extends \Google\Protobuf\Internal\Message +{ + /** + * Resource name of a service config. It must have the following + * format: "services/{service name}/configs/{config id}". + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Resource name of a service config. It must have the following + * format: "services/{service name}/configs/{config id}". + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Api\Servicemanagement\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * Resource name of a service config. It must have the following + * format: "services/{service name}/configs/{config id}". + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Resource name of a service config. It must have the following + * format: "services/{service name}/configs/{config id}". + * + * 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; + } + +} + diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ConfigSource.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ConfigSource.php new file mode 100644 index 000000000000..dfedb93e6ceb --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ConfigSource.php @@ -0,0 +1,114 @@ +google.api.servicemanagement.v1.ConfigSource + */ +class ConfigSource extends \Google\Protobuf\Internal\Message +{ + /** + * A unique ID for a specific instance of this message, typically assigned + * by the client for tracking purpose. If empty, the server may choose to + * generate one instead. + * + * Generated from protobuf field string id = 5; + */ + protected $id = ''; + /** + * Set of source configuration files that are used to generate a service + * configuration (`google.api.Service`). + * + * Generated from protobuf field repeated .google.api.servicemanagement.v1.ConfigFile files = 2; + */ + private $files; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $id + * A unique ID for a specific instance of this message, typically assigned + * by the client for tracking purpose. If empty, the server may choose to + * generate one instead. + * @type \Google\Cloud\ServiceManagement\V1\ConfigFile[] $files + * Set of source configuration files that are used to generate a service + * configuration (`google.api.Service`). + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Api\Servicemanagement\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * A unique ID for a specific instance of this message, typically assigned + * by the client for tracking purpose. If empty, the server may choose to + * generate one instead. + * + * Generated from protobuf field string id = 5; + * @return string + */ + public function getId() + { + return $this->id; + } + + /** + * A unique ID for a specific instance of this message, typically assigned + * by the client for tracking purpose. If empty, the server may choose to + * generate one instead. + * + * 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; + } + + /** + * Set of source configuration files that are used to generate a service + * configuration (`google.api.Service`). + * + * Generated from protobuf field repeated .google.api.servicemanagement.v1.ConfigFile files = 2; + * @return RepeatedField<\Google\Cloud\ServiceManagement\V1\ConfigFile> + */ + public function getFiles() + { + return $this->files; + } + + /** + * Set of source configuration files that are used to generate a service + * configuration (`google.api.Service`). + * + * Generated from protobuf field repeated .google.api.servicemanagement.v1.ConfigFile files = 2; + * @param \Google\Cloud\ServiceManagement\V1\ConfigFile[] $var + * @return $this + */ + public function setFiles($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\ServiceManagement\V1\ConfigFile::class); + $this->files = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/CreateServiceConfigRequest.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/CreateServiceConfigRequest.php new file mode 100644 index 000000000000..da1e6bd4ac95 --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/CreateServiceConfigRequest.php @@ -0,0 +1,136 @@ +google.api.servicemanagement.v1.CreateServiceConfigRequest + */ +class CreateServiceConfigRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * + * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $service_name = ''; + /** + * Required. The service configuration resource. + * + * Generated from protobuf field .google.api.Service service_config = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $service_config = null; + + /** + * @param string $serviceName Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * @param \Google\Api\Service $serviceConfig Required. The service configuration resource. + * + * @return \Google\Cloud\ServiceManagement\V1\CreateServiceConfigRequest + * + * @experimental + */ + public static function build(string $serviceName, \Google\Api\Service $serviceConfig): self + { + return (new self()) + ->setServiceName($serviceName) + ->setServiceConfig($serviceConfig); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $service_name + * Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * @type \Google\Api\Service $service_config + * Required. The service configuration resource. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Api\Servicemanagement\V1\Servicemanager::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * + * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getServiceName() + { + return $this->service_name; + } + + /** + * Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * + * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setServiceName($var) + { + GPBUtil::checkString($var, True); + $this->service_name = $var; + + return $this; + } + + /** + * Required. The service configuration resource. + * + * Generated from protobuf field .google.api.Service service_config = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Api\Service|null + */ + public function getServiceConfig() + { + return $this->service_config; + } + + public function hasServiceConfig() + { + return isset($this->service_config); + } + + public function clearServiceConfig() + { + unset($this->service_config); + } + + /** + * Required. The service configuration resource. + * + * Generated from protobuf field .google.api.Service service_config = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Api\Service $var + * @return $this + */ + public function setServiceConfig($var) + { + GPBUtil::checkMessage($var, \Google\Api\Service::class); + $this->service_config = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/CreateServiceRequest.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/CreateServiceRequest.php new file mode 100644 index 000000000000..056fb0ea7c2a --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/CreateServiceRequest.php @@ -0,0 +1,90 @@ +google.api.servicemanagement.v1.CreateServiceRequest + */ +class CreateServiceRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Initial values for the service resource. + * + * Generated from protobuf field .google.api.servicemanagement.v1.ManagedService service = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $service = null; + + /** + * @param \Google\Cloud\ServiceManagement\V1\ManagedService $service Required. Initial values for the service resource. + * + * @return \Google\Cloud\ServiceManagement\V1\CreateServiceRequest + * + * @experimental + */ + public static function build(\Google\Cloud\ServiceManagement\V1\ManagedService $service): self + { + return (new self()) + ->setService($service); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\ServiceManagement\V1\ManagedService $service + * Required. Initial values for the service resource. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Api\Servicemanagement\V1\Servicemanager::initOnce(); + parent::__construct($data); + } + + /** + * Required. Initial values for the service resource. + * + * Generated from protobuf field .google.api.servicemanagement.v1.ManagedService service = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\ServiceManagement\V1\ManagedService|null + */ + public function getService() + { + return $this->service; + } + + public function hasService() + { + return isset($this->service); + } + + public function clearService() + { + unset($this->service); + } + + /** + * Required. Initial values for the service resource. + * + * Generated from protobuf field .google.api.servicemanagement.v1.ManagedService service = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\ServiceManagement\V1\ManagedService $var + * @return $this + */ + public function setService($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\ServiceManagement\V1\ManagedService::class); + $this->service = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/CreateServiceRolloutRequest.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/CreateServiceRolloutRequest.php new file mode 100644 index 000000000000..6b0e1aa82d88 --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/CreateServiceRolloutRequest.php @@ -0,0 +1,136 @@ +google.api.servicemanagement.v1.CreateServiceRolloutRequest + */ +class CreateServiceRolloutRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * + * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $service_name = ''; + /** + * Required. The rollout resource. The `service_name` field is output only. + * + * Generated from protobuf field .google.api.servicemanagement.v1.Rollout rollout = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $rollout = null; + + /** + * @param string $serviceName Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * @param \Google\Cloud\ServiceManagement\V1\Rollout $rollout Required. The rollout resource. The `service_name` field is output only. + * + * @return \Google\Cloud\ServiceManagement\V1\CreateServiceRolloutRequest + * + * @experimental + */ + public static function build(string $serviceName, \Google\Cloud\ServiceManagement\V1\Rollout $rollout): self + { + return (new self()) + ->setServiceName($serviceName) + ->setRollout($rollout); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $service_name + * Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * @type \Google\Cloud\ServiceManagement\V1\Rollout $rollout + * Required. The rollout resource. The `service_name` field is output only. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Api\Servicemanagement\V1\Servicemanager::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * + * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getServiceName() + { + return $this->service_name; + } + + /** + * Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * + * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setServiceName($var) + { + GPBUtil::checkString($var, True); + $this->service_name = $var; + + return $this; + } + + /** + * Required. The rollout resource. The `service_name` field is output only. + * + * Generated from protobuf field .google.api.servicemanagement.v1.Rollout rollout = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\ServiceManagement\V1\Rollout|null + */ + public function getRollout() + { + return $this->rollout; + } + + public function hasRollout() + { + return isset($this->rollout); + } + + public function clearRollout() + { + unset($this->rollout); + } + + /** + * Required. The rollout resource. The `service_name` field is output only. + * + * Generated from protobuf field .google.api.servicemanagement.v1.Rollout rollout = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\ServiceManagement\V1\Rollout $var + * @return $this + */ + public function setRollout($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\ServiceManagement\V1\Rollout::class); + $this->rollout = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/DeleteServiceRequest.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/DeleteServiceRequest.php new file mode 100644 index 000000000000..7ba4f70e3f0f --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/DeleteServiceRequest.php @@ -0,0 +1,90 @@ +google.api.servicemanagement.v1.DeleteServiceRequest + */ +class DeleteServiceRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * + * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $service_name = ''; + + /** + * @param string $serviceName Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * + * @return \Google\Cloud\ServiceManagement\V1\DeleteServiceRequest + * + * @experimental + */ + public static function build(string $serviceName): self + { + return (new self()) + ->setServiceName($serviceName); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $service_name + * Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Api\Servicemanagement\V1\Servicemanager::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * + * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getServiceName() + { + return $this->service_name; + } + + /** + * Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * + * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setServiceName($var) + { + GPBUtil::checkString($var, True); + $this->service_name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Diagnostic.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Diagnostic.php new file mode 100644 index 000000000000..95491e9167af --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Diagnostic.php @@ -0,0 +1,135 @@ +google.api.servicemanagement.v1.Diagnostic + */ +class Diagnostic extends \Google\Protobuf\Internal\Message +{ + /** + * File name and line number of the error or warning. + * + * Generated from protobuf field string location = 1; + */ + protected $location = ''; + /** + * The kind of diagnostic information provided. + * + * Generated from protobuf field .google.api.servicemanagement.v1.Diagnostic.Kind kind = 2; + */ + protected $kind = 0; + /** + * Message describing the error or warning. + * + * Generated from protobuf field string message = 3; + */ + protected $message = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $location + * File name and line number of the error or warning. + * @type int $kind + * The kind of diagnostic information provided. + * @type string $message + * Message describing the error or warning. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Api\Servicemanagement\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * File name and line number of the error or warning. + * + * Generated from protobuf field string location = 1; + * @return string + */ + public function getLocation() + { + return $this->location; + } + + /** + * File name and line number of the error or warning. + * + * 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 kind of diagnostic information provided. + * + * Generated from protobuf field .google.api.servicemanagement.v1.Diagnostic.Kind kind = 2; + * @return int + */ + public function getKind() + { + return $this->kind; + } + + /** + * The kind of diagnostic information provided. + * + * Generated from protobuf field .google.api.servicemanagement.v1.Diagnostic.Kind kind = 2; + * @param int $var + * @return $this + */ + public function setKind($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\ServiceManagement\V1\Diagnostic\Kind::class); + $this->kind = $var; + + return $this; + } + + /** + * Message describing the error or warning. + * + * Generated from protobuf field string message = 3; + * @return string + */ + public function getMessage() + { + return $this->message; + } + + /** + * Message describing the error or warning. + * + * Generated from protobuf field string message = 3; + * @param string $var + * @return $this + */ + public function setMessage($var) + { + GPBUtil::checkString($var, True); + $this->message = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Diagnostic/Kind.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Diagnostic/Kind.php new file mode 100644 index 000000000000..731e0996f661 --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Diagnostic/Kind.php @@ -0,0 +1,54 @@ +google.api.servicemanagement.v1.Diagnostic.Kind + */ +class Kind +{ + /** + * Warnings and errors + * + * Generated from protobuf enum WARNING = 0; + */ + const WARNING = 0; + /** + * Only errors + * + * Generated from protobuf enum ERROR = 1; + */ + const ERROR = 1; + + private static $valueToName = [ + self::WARNING => 'WARNING', + 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); + } +} + diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/EnableServiceResponse.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/EnableServiceResponse.php new file mode 100644 index 000000000000..e5727a714c09 --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/EnableServiceResponse.php @@ -0,0 +1,33 @@ +google.api.servicemanagement.v1.EnableServiceResponse + */ +class EnableServiceResponse extends \Google\Protobuf\Internal\Message +{ + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Api\Servicemanagement\V1\Servicemanager::initOnce(); + parent::__construct($data); + } + +} + diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GenerateConfigReportRequest.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GenerateConfigReportRequest.php new file mode 100644 index 000000000000..22bd179831be --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GenerateConfigReportRequest.php @@ -0,0 +1,176 @@ +google.api.servicemanagement.v1.GenerateConfigReportRequest + */ +class GenerateConfigReportRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Service configuration for which we want to generate the report. + * For this version of API, the supported types are + * [google.api.servicemanagement.v1.ConfigRef][google.api.servicemanagement.v1.ConfigRef], + * [google.api.servicemanagement.v1.ConfigSource][google.api.servicemanagement.v1.ConfigSource], + * and [google.api.Service][google.api.Service] + * + * Generated from protobuf field .google.protobuf.Any new_config = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $new_config = null; + /** + * Optional. Service configuration against which the comparison will be done. + * For this version of API, the supported types are + * [google.api.servicemanagement.v1.ConfigRef][google.api.servicemanagement.v1.ConfigRef], + * [google.api.servicemanagement.v1.ConfigSource][google.api.servicemanagement.v1.ConfigSource], + * and [google.api.Service][google.api.Service] + * + * Generated from protobuf field .google.protobuf.Any old_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $old_config = null; + + /** + * @param \Google\Protobuf\Any $newConfig Required. Service configuration for which we want to generate the report. + * For this version of API, the supported types are + * [google.api.servicemanagement.v1.ConfigRef][google.api.servicemanagement.v1.ConfigRef], + * [google.api.servicemanagement.v1.ConfigSource][google.api.servicemanagement.v1.ConfigSource], + * and [google.api.Service][google.api.Service] + * @param \Google\Protobuf\Any $oldConfig Optional. Service configuration against which the comparison will be done. + * For this version of API, the supported types are + * [google.api.servicemanagement.v1.ConfigRef][google.api.servicemanagement.v1.ConfigRef], + * [google.api.servicemanagement.v1.ConfigSource][google.api.servicemanagement.v1.ConfigSource], + * and [google.api.Service][google.api.Service] + * + * @return \Google\Cloud\ServiceManagement\V1\GenerateConfigReportRequest + * + * @experimental + */ + public static function build(\Google\Protobuf\Any $newConfig, \Google\Protobuf\Any $oldConfig): self + { + return (new self()) + ->setNewConfig($newConfig) + ->setOldConfig($oldConfig); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Protobuf\Any $new_config + * Required. Service configuration for which we want to generate the report. + * For this version of API, the supported types are + * [google.api.servicemanagement.v1.ConfigRef][google.api.servicemanagement.v1.ConfigRef], + * [google.api.servicemanagement.v1.ConfigSource][google.api.servicemanagement.v1.ConfigSource], + * and [google.api.Service][google.api.Service] + * @type \Google\Protobuf\Any $old_config + * Optional. Service configuration against which the comparison will be done. + * For this version of API, the supported types are + * [google.api.servicemanagement.v1.ConfigRef][google.api.servicemanagement.v1.ConfigRef], + * [google.api.servicemanagement.v1.ConfigSource][google.api.servicemanagement.v1.ConfigSource], + * and [google.api.Service][google.api.Service] + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Api\Servicemanagement\V1\Servicemanager::initOnce(); + parent::__construct($data); + } + + /** + * Required. Service configuration for which we want to generate the report. + * For this version of API, the supported types are + * [google.api.servicemanagement.v1.ConfigRef][google.api.servicemanagement.v1.ConfigRef], + * [google.api.servicemanagement.v1.ConfigSource][google.api.servicemanagement.v1.ConfigSource], + * and [google.api.Service][google.api.Service] + * + * Generated from protobuf field .google.protobuf.Any new_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Protobuf\Any|null + */ + public function getNewConfig() + { + return $this->new_config; + } + + public function hasNewConfig() + { + return isset($this->new_config); + } + + public function clearNewConfig() + { + unset($this->new_config); + } + + /** + * Required. Service configuration for which we want to generate the report. + * For this version of API, the supported types are + * [google.api.servicemanagement.v1.ConfigRef][google.api.servicemanagement.v1.ConfigRef], + * [google.api.servicemanagement.v1.ConfigSource][google.api.servicemanagement.v1.ConfigSource], + * and [google.api.Service][google.api.Service] + * + * Generated from protobuf field .google.protobuf.Any new_config = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Protobuf\Any $var + * @return $this + */ + public function setNewConfig($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Any::class); + $this->new_config = $var; + + return $this; + } + + /** + * Optional. Service configuration against which the comparison will be done. + * For this version of API, the supported types are + * [google.api.servicemanagement.v1.ConfigRef][google.api.servicemanagement.v1.ConfigRef], + * [google.api.servicemanagement.v1.ConfigSource][google.api.servicemanagement.v1.ConfigSource], + * and [google.api.Service][google.api.Service] + * + * Generated from protobuf field .google.protobuf.Any old_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Protobuf\Any|null + */ + public function getOldConfig() + { + return $this->old_config; + } + + public function hasOldConfig() + { + return isset($this->old_config); + } + + public function clearOldConfig() + { + unset($this->old_config); + } + + /** + * Optional. Service configuration against which the comparison will be done. + * For this version of API, the supported types are + * [google.api.servicemanagement.v1.ConfigRef][google.api.servicemanagement.v1.ConfigRef], + * [google.api.servicemanagement.v1.ConfigSource][google.api.servicemanagement.v1.ConfigSource], + * and [google.api.Service][google.api.Service] + * + * Generated from protobuf field .google.protobuf.Any old_config = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Protobuf\Any $var + * @return $this + */ + public function setOldConfig($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Any::class); + $this->old_config = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GenerateConfigReportResponse.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GenerateConfigReportResponse.php new file mode 100644 index 000000000000..f9b8439d72bc --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GenerateConfigReportResponse.php @@ -0,0 +1,181 @@ +google.api.servicemanagement.v1.GenerateConfigReportResponse + */ +class GenerateConfigReportResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Name of the service this report belongs to. + * + * Generated from protobuf field string service_name = 1; + */ + protected $service_name = ''; + /** + * ID of the service configuration this report belongs to. + * + * Generated from protobuf field string id = 2; + */ + protected $id = ''; + /** + * list of ChangeReport, each corresponding to comparison between two + * service configurations. + * + * Generated from protobuf field repeated .google.api.servicemanagement.v1.ChangeReport change_reports = 3; + */ + private $change_reports; + /** + * Errors / Linter warnings associated with the service definition this + * report + * belongs to. + * + * Generated from protobuf field repeated .google.api.servicemanagement.v1.Diagnostic diagnostics = 4; + */ + private $diagnostics; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $service_name + * Name of the service this report belongs to. + * @type string $id + * ID of the service configuration this report belongs to. + * @type \Google\Cloud\ServiceManagement\V1\ChangeReport[] $change_reports + * list of ChangeReport, each corresponding to comparison between two + * service configurations. + * @type \Google\Cloud\ServiceManagement\V1\Diagnostic[] $diagnostics + * Errors / Linter warnings associated with the service definition this + * report + * belongs to. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Api\Servicemanagement\V1\Servicemanager::initOnce(); + parent::__construct($data); + } + + /** + * Name of the service this report belongs to. + * + * Generated from protobuf field string service_name = 1; + * @return string + */ + public function getServiceName() + { + return $this->service_name; + } + + /** + * Name of the service this report belongs to. + * + * Generated from protobuf field string service_name = 1; + * @param string $var + * @return $this + */ + public function setServiceName($var) + { + GPBUtil::checkString($var, True); + $this->service_name = $var; + + return $this; + } + + /** + * ID of the service configuration this report belongs to. + * + * Generated from protobuf field string id = 2; + * @return string + */ + public function getId() + { + return $this->id; + } + + /** + * ID of the service configuration this report belongs to. + * + * Generated from protobuf field string id = 2; + * @param string $var + * @return $this + */ + public function setId($var) + { + GPBUtil::checkString($var, True); + $this->id = $var; + + return $this; + } + + /** + * list of ChangeReport, each corresponding to comparison between two + * service configurations. + * + * Generated from protobuf field repeated .google.api.servicemanagement.v1.ChangeReport change_reports = 3; + * @return RepeatedField<\Google\Cloud\ServiceManagement\V1\ChangeReport> + */ + public function getChangeReports() + { + return $this->change_reports; + } + + /** + * list of ChangeReport, each corresponding to comparison between two + * service configurations. + * + * Generated from protobuf field repeated .google.api.servicemanagement.v1.ChangeReport change_reports = 3; + * @param \Google\Cloud\ServiceManagement\V1\ChangeReport[] $var + * @return $this + */ + public function setChangeReports($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\ServiceManagement\V1\ChangeReport::class); + $this->change_reports = $arr; + + return $this; + } + + /** + * Errors / Linter warnings associated with the service definition this + * report + * belongs to. + * + * Generated from protobuf field repeated .google.api.servicemanagement.v1.Diagnostic diagnostics = 4; + * @return RepeatedField<\Google\Cloud\ServiceManagement\V1\Diagnostic> + */ + public function getDiagnostics() + { + return $this->diagnostics; + } + + /** + * Errors / Linter warnings associated with the service definition this + * report + * belongs to. + * + * Generated from protobuf field repeated .google.api.servicemanagement.v1.Diagnostic diagnostics = 4; + * @param \Google\Cloud\ServiceManagement\V1\Diagnostic[] $var + * @return $this + */ + public function setDiagnostics($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\ServiceManagement\V1\Diagnostic::class); + $this->diagnostics = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GetServiceConfigRequest.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GetServiceConfigRequest.php new file mode 100644 index 000000000000..8cfb83bc796d --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GetServiceConfigRequest.php @@ -0,0 +1,179 @@ +google.api.servicemanagement.v1.GetServiceConfigRequest + */ +class GetServiceConfigRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * + * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $service_name = ''; + /** + * Required. The id of the service configuration resource. + * This field must be specified for the server to return all fields, including + * `SourceInfo`. + * + * Generated from protobuf field string config_id = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $config_id = ''; + /** + * Specifies which parts of the Service Config should be returned in the + * response. + * + * Generated from protobuf field .google.api.servicemanagement.v1.GetServiceConfigRequest.ConfigView view = 3; + */ + protected $view = 0; + + /** + * @param string $serviceName Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * @param string $configId Required. The id of the service configuration resource. + * + * This field must be specified for the server to return all fields, including + * `SourceInfo`. + * @param int $view Specifies which parts of the Service Config should be returned in the + * response. + * For allowed values, use constants defined on {@see \Google\Cloud\ServiceManagement\V1\GetServiceConfigRequest\ConfigView} + * + * @return \Google\Cloud\ServiceManagement\V1\GetServiceConfigRequest + * + * @experimental + */ + public static function build(string $serviceName, string $configId, int $view): self + { + return (new self()) + ->setServiceName($serviceName) + ->setConfigId($configId) + ->setView($view); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $service_name + * Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * @type string $config_id + * Required. The id of the service configuration resource. + * This field must be specified for the server to return all fields, including + * `SourceInfo`. + * @type int $view + * Specifies which parts of the Service Config should be returned in the + * response. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Api\Servicemanagement\V1\Servicemanager::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * + * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getServiceName() + { + return $this->service_name; + } + + /** + * Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * + * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setServiceName($var) + { + GPBUtil::checkString($var, True); + $this->service_name = $var; + + return $this; + } + + /** + * Required. The id of the service configuration resource. + * This field must be specified for the server to return all fields, including + * `SourceInfo`. + * + * Generated from protobuf field string config_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getConfigId() + { + return $this->config_id; + } + + /** + * Required. The id of the service configuration resource. + * This field must be specified for the server to return all fields, including + * `SourceInfo`. + * + * Generated from protobuf field string config_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setConfigId($var) + { + GPBUtil::checkString($var, True); + $this->config_id = $var; + + return $this; + } + + /** + * Specifies which parts of the Service Config should be returned in the + * response. + * + * Generated from protobuf field .google.api.servicemanagement.v1.GetServiceConfigRequest.ConfigView view = 3; + * @return int + */ + public function getView() + { + return $this->view; + } + + /** + * Specifies which parts of the Service Config should be returned in the + * response. + * + * Generated from protobuf field .google.api.servicemanagement.v1.GetServiceConfigRequest.ConfigView view = 3; + * @param int $var + * @return $this + */ + public function setView($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\ServiceManagement\V1\GetServiceConfigRequest\ConfigView::class); + $this->view = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GetServiceConfigRequest/ConfigView.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GetServiceConfigRequest/ConfigView.php new file mode 100644 index 000000000000..c79893bdeb0e --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GetServiceConfigRequest/ConfigView.php @@ -0,0 +1,55 @@ +google.api.servicemanagement.v1.GetServiceConfigRequest.ConfigView + */ +class ConfigView +{ + /** + * Server response includes all fields except SourceInfo. + * + * Generated from protobuf enum BASIC = 0; + */ + const BASIC = 0; + /** + * Server response includes all fields including SourceInfo. + * SourceFiles are of type 'google.api.servicemanagement.v1.ConfigFile' + * and are only available for configs created using the + * SubmitConfigSource method. + * + * Generated from protobuf enum FULL = 1; + */ + const FULL = 1; + + private static $valueToName = [ + self::BASIC => 'BASIC', + self::FULL => 'FULL', + ]; + + 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/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GetServiceRequest.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GetServiceRequest.php new file mode 100644 index 000000000000..3b1510cda0bb --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GetServiceRequest.php @@ -0,0 +1,85 @@ +google.api.servicemanagement.v1.GetServiceRequest + */ +class GetServiceRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the service. See the `ServiceManager` overview for + * naming requirements. For example: `example.googleapis.com`. + * + * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $service_name = ''; + + /** + * @param string $serviceName Required. The name of the service. See the `ServiceManager` overview for + * naming requirements. For example: `example.googleapis.com`. + * + * @return \Google\Cloud\ServiceManagement\V1\GetServiceRequest + * + * @experimental + */ + public static function build(string $serviceName): self + { + return (new self()) + ->setServiceName($serviceName); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $service_name + * Required. The name of the service. See the `ServiceManager` overview for + * naming requirements. For example: `example.googleapis.com`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Api\Servicemanagement\V1\Servicemanager::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the service. See the `ServiceManager` overview for + * naming requirements. For example: `example.googleapis.com`. + * + * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getServiceName() + { + return $this->service_name; + } + + /** + * Required. The name of the service. See the `ServiceManager` overview for + * naming requirements. For example: `example.googleapis.com`. + * + * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setServiceName($var) + { + GPBUtil::checkString($var, True); + $this->service_name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GetServiceRolloutRequest.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GetServiceRolloutRequest.php new file mode 100644 index 000000000000..42ce21668e8b --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GetServiceRolloutRequest.php @@ -0,0 +1,126 @@ +google.api.servicemanagement.v1.GetServiceRolloutRequest + */ +class GetServiceRolloutRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * + * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $service_name = ''; + /** + * Required. The id of the rollout resource. + * + * Generated from protobuf field string rollout_id = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $rollout_id = ''; + + /** + * @param string $serviceName Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * @param string $rolloutId Required. The id of the rollout resource. + * + * @return \Google\Cloud\ServiceManagement\V1\GetServiceRolloutRequest + * + * @experimental + */ + public static function build(string $serviceName, string $rolloutId): self + { + return (new self()) + ->setServiceName($serviceName) + ->setRolloutId($rolloutId); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $service_name + * Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * @type string $rollout_id + * Required. The id of the rollout resource. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Api\Servicemanagement\V1\Servicemanager::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * + * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getServiceName() + { + return $this->service_name; + } + + /** + * Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * + * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setServiceName($var) + { + GPBUtil::checkString($var, True); + $this->service_name = $var; + + return $this; + } + + /** + * Required. The id of the rollout resource. + * + * Generated from protobuf field string rollout_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getRolloutId() + { + return $this->rollout_id; + } + + /** + * Required. The id of the rollout resource. + * + * Generated from protobuf field string rollout_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setRolloutId($var) + { + GPBUtil::checkString($var, True); + $this->rollout_id = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServiceConfigsRequest.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServiceConfigsRequest.php new file mode 100644 index 000000000000..cbce1951eaac --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServiceConfigsRequest.php @@ -0,0 +1,162 @@ +google.api.servicemanagement.v1.ListServiceConfigsRequest + */ +class ListServiceConfigsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * + * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $service_name = ''; + /** + * The token of the page to retrieve. + * + * Generated from protobuf field string page_token = 2; + */ + protected $page_token = ''; + /** + * The max number of items to include in the response list. Page size is 50 + * if not specified. Maximum value is 100. + * + * Generated from protobuf field int32 page_size = 3; + */ + protected $page_size = 0; + + /** + * @param string $serviceName Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * + * @return \Google\Cloud\ServiceManagement\V1\ListServiceConfigsRequest + * + * @experimental + */ + public static function build(string $serviceName): self + { + return (new self()) + ->setServiceName($serviceName); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $service_name + * Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * @type string $page_token + * The token of the page to retrieve. + * @type int $page_size + * The max number of items to include in the response list. Page size is 50 + * if not specified. Maximum value is 100. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Api\Servicemanagement\V1\Servicemanager::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * + * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getServiceName() + { + return $this->service_name; + } + + /** + * Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * + * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setServiceName($var) + { + GPBUtil::checkString($var, True); + $this->service_name = $var; + + return $this; + } + + /** + * The token of the page to retrieve. + * + * Generated from protobuf field string page_token = 2; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * The token of the page to retrieve. + * + * Generated from protobuf field string page_token = 2; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + + /** + * The max number of items to include in the response list. Page size is 50 + * if not specified. Maximum value is 100. + * + * Generated from protobuf field int32 page_size = 3; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The max number of items to include in the response list. Page size is 50 + * if not specified. Maximum value is 100. + * + * 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; + } + +} + diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServiceConfigsResponse.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServiceConfigsResponse.php new file mode 100644 index 000000000000..b26fc9f7284a --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServiceConfigsResponse.php @@ -0,0 +1,101 @@ +google.api.servicemanagement.v1.ListServiceConfigsResponse + */ +class ListServiceConfigsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * The list of service configuration resources. + * + * Generated from protobuf field repeated .google.api.Service service_configs = 1; + */ + private $service_configs; + /** + * The token of 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 \Google\Api\Service[] $service_configs + * The list of service configuration resources. + * @type string $next_page_token + * The token of the next page of results. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Api\Servicemanagement\V1\Servicemanager::initOnce(); + parent::__construct($data); + } + + /** + * The list of service configuration resources. + * + * Generated from protobuf field repeated .google.api.Service service_configs = 1; + * @return RepeatedField<\Google\Api\Service> + */ + public function getServiceConfigs() + { + return $this->service_configs; + } + + /** + * The list of service configuration resources. + * + * Generated from protobuf field repeated .google.api.Service service_configs = 1; + * @param \Google\Api\Service[] $var + * @return $this + */ + public function setServiceConfigs($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Api\Service::class); + $this->service_configs = $arr; + + return $this; + } + + /** + * The token of 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 token of 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/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServiceRolloutsRequest.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServiceRolloutsRequest.php new file mode 100644 index 000000000000..7feecf9a34b9 --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServiceRolloutsRequest.php @@ -0,0 +1,235 @@ +google.api.servicemanagement.v1.ListServiceRolloutsRequest + */ +class ListServiceRolloutsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * + * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $service_name = ''; + /** + * The token of the page to retrieve. + * + * Generated from protobuf field string page_token = 2; + */ + protected $page_token = ''; + /** + * The max number of items to include in the response list. Page size is 50 + * if not specified. Maximum value is 100. + * + * Generated from protobuf field int32 page_size = 3; + */ + protected $page_size = 0; + /** + * Required. Use `filter` to return subset of rollouts. + * The following filters are supported: + * -- By [status] + * [google.api.servicemanagement.v1.Rollout.RolloutStatus]. For example, + * `filter='status=SUCCESS'` + * -- By [strategy] + * [google.api.servicemanagement.v1.Rollout.strategy]. For example, + * `filter='strategy=TrafficPercentStrategy'` + * + * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $filter = ''; + + /** + * @param string $serviceName Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * @param string $filter Required. Use `filter` to return subset of rollouts. + * The following filters are supported: + * + * -- By [status] + * [google.api.servicemanagement.v1.Rollout.RolloutStatus]. For example, + * `filter='status=SUCCESS'` + * + * -- By [strategy] + * [google.api.servicemanagement.v1.Rollout.strategy]. For example, + * `filter='strategy=TrafficPercentStrategy'` + * + * @return \Google\Cloud\ServiceManagement\V1\ListServiceRolloutsRequest + * + * @experimental + */ + public static function build(string $serviceName, string $filter): self + { + return (new self()) + ->setServiceName($serviceName) + ->setFilter($filter); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $service_name + * Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * @type string $page_token + * The token of the page to retrieve. + * @type int $page_size + * The max number of items to include in the response list. Page size is 50 + * if not specified. Maximum value is 100. + * @type string $filter + * Required. Use `filter` to return subset of rollouts. + * The following filters are supported: + * -- By [status] + * [google.api.servicemanagement.v1.Rollout.RolloutStatus]. For example, + * `filter='status=SUCCESS'` + * -- By [strategy] + * [google.api.servicemanagement.v1.Rollout.strategy]. For example, + * `filter='strategy=TrafficPercentStrategy'` + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Api\Servicemanagement\V1\Servicemanager::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * + * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getServiceName() + { + return $this->service_name; + } + + /** + * Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * + * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setServiceName($var) + { + GPBUtil::checkString($var, True); + $this->service_name = $var; + + return $this; + } + + /** + * The token of the page to retrieve. + * + * Generated from protobuf field string page_token = 2; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * The token of the page to retrieve. + * + * Generated from protobuf field string page_token = 2; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + + /** + * The max number of items to include in the response list. Page size is 50 + * if not specified. Maximum value is 100. + * + * Generated from protobuf field int32 page_size = 3; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The max number of items to include in the response list. Page size is 50 + * if not specified. Maximum value is 100. + * + * 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; + } + + /** + * Required. Use `filter` to return subset of rollouts. + * The following filters are supported: + * -- By [status] + * [google.api.servicemanagement.v1.Rollout.RolloutStatus]. For example, + * `filter='status=SUCCESS'` + * -- By [strategy] + * [google.api.servicemanagement.v1.Rollout.strategy]. For example, + * `filter='strategy=TrafficPercentStrategy'` + * + * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * Required. Use `filter` to return subset of rollouts. + * The following filters are supported: + * -- By [status] + * [google.api.servicemanagement.v1.Rollout.RolloutStatus]. For example, + * `filter='status=SUCCESS'` + * -- By [strategy] + * [google.api.servicemanagement.v1.Rollout.strategy]. For example, + * `filter='strategy=TrafficPercentStrategy'` + * + * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkString($var, True); + $this->filter = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServiceRolloutsResponse.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServiceRolloutsResponse.php new file mode 100644 index 000000000000..3372213c1ab7 --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServiceRolloutsResponse.php @@ -0,0 +1,101 @@ +google.api.servicemanagement.v1.ListServiceRolloutsResponse + */ +class ListServiceRolloutsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * The list of rollout resources. + * + * Generated from protobuf field repeated .google.api.servicemanagement.v1.Rollout rollouts = 1; + */ + private $rollouts; + /** + * The token of 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 \Google\Cloud\ServiceManagement\V1\Rollout[] $rollouts + * The list of rollout resources. + * @type string $next_page_token + * The token of the next page of results. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Api\Servicemanagement\V1\Servicemanager::initOnce(); + parent::__construct($data); + } + + /** + * The list of rollout resources. + * + * Generated from protobuf field repeated .google.api.servicemanagement.v1.Rollout rollouts = 1; + * @return RepeatedField<\Google\Cloud\ServiceManagement\V1\Rollout> + */ + public function getRollouts() + { + return $this->rollouts; + } + + /** + * The list of rollout resources. + * + * Generated from protobuf field repeated .google.api.servicemanagement.v1.Rollout rollouts = 1; + * @param \Google\Cloud\ServiceManagement\V1\Rollout[] $var + * @return $this + */ + public function setRollouts($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\ServiceManagement\V1\Rollout::class); + $this->rollouts = $arr; + + return $this; + } + + /** + * The token of 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 token of 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/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServicesRequest.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServicesRequest.php new file mode 100644 index 000000000000..68fba0f9cde6 --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServicesRequest.php @@ -0,0 +1,215 @@ +google.api.servicemanagement.v1.ListServicesRequest + */ +class ListServicesRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Include services produced by the specified project. + * + * Generated from protobuf field string producer_project_id = 1; + */ + protected $producer_project_id = ''; + /** + * The max number of items to include in the response list. Page size is 50 + * if not specified. Maximum value is 500. + * + * Generated from protobuf field int32 page_size = 5; + */ + protected $page_size = 0; + /** + * Token identifying which result to start with; returned by a previous list + * call. + * + * Generated from protobuf field string page_token = 6; + */ + protected $page_token = ''; + /** + * Include services consumed by the specified consumer. + * The Google Service Management implementation accepts the following + * forms: + * - project: + * + * Generated from protobuf field string consumer_id = 7 [deprecated = true]; + * @deprecated + */ + protected $consumer_id = ''; + + /** + * @param string $producerProjectId Include services produced by the specified project. + * @param string $consumerId Include services consumed by the specified consumer. + * + * The Google Service Management implementation accepts the following + * forms: + * - project: + * + * @return \Google\Cloud\ServiceManagement\V1\ListServicesRequest + * + * @experimental + */ + public static function build(string $producerProjectId, string $consumerId): self + { + return (new self()) + ->setProducerProjectId($producerProjectId) + ->setConsumerId($consumerId); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $producer_project_id + * Include services produced by the specified project. + * @type int $page_size + * The max number of items to include in the response list. Page size is 50 + * if not specified. Maximum value is 500. + * @type string $page_token + * Token identifying which result to start with; returned by a previous list + * call. + * @type string $consumer_id + * Include services consumed by the specified consumer. + * The Google Service Management implementation accepts the following + * forms: + * - project: + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Api\Servicemanagement\V1\Servicemanager::initOnce(); + parent::__construct($data); + } + + /** + * Include services produced by the specified project. + * + * Generated from protobuf field string producer_project_id = 1; + * @return string + */ + public function getProducerProjectId() + { + return $this->producer_project_id; + } + + /** + * Include services produced by the specified project. + * + * Generated from protobuf field string producer_project_id = 1; + * @param string $var + * @return $this + */ + public function setProducerProjectId($var) + { + GPBUtil::checkString($var, True); + $this->producer_project_id = $var; + + return $this; + } + + /** + * The max number of items to include in the response list. Page size is 50 + * if not specified. Maximum value is 500. + * + * Generated from protobuf field int32 page_size = 5; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The max number of items to include in the response list. Page size is 50 + * if not specified. Maximum value is 500. + * + * Generated from protobuf field int32 page_size = 5; + * @param int $var + * @return $this + */ + public function setPageSize($var) + { + GPBUtil::checkInt32($var); + $this->page_size = $var; + + return $this; + } + + /** + * Token identifying which result to start with; returned by a previous list + * call. + * + * Generated from protobuf field string page_token = 6; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * Token identifying which result to start with; returned by a previous list + * call. + * + * Generated from protobuf field string page_token = 6; + * @param string $var + * @return $this + */ + public function setPageToken($var) + { + GPBUtil::checkString($var, True); + $this->page_token = $var; + + return $this; + } + + /** + * Include services consumed by the specified consumer. + * The Google Service Management implementation accepts the following + * forms: + * - project: + * + * Generated from protobuf field string consumer_id = 7 [deprecated = true]; + * @return string + * @deprecated + */ + public function getConsumerId() + { + if ($this->consumer_id !== '') { + @trigger_error('consumer_id is deprecated.', E_USER_DEPRECATED); + } + return $this->consumer_id; + } + + /** + * Include services consumed by the specified consumer. + * The Google Service Management implementation accepts the following + * forms: + * - project: + * + * Generated from protobuf field string consumer_id = 7 [deprecated = true]; + * @param string $var + * @return $this + * @deprecated + */ + public function setConsumerId($var) + { + @trigger_error('consumer_id is deprecated.', E_USER_DEPRECATED); + GPBUtil::checkString($var, True); + $this->consumer_id = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServicesResponse.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServicesResponse.php new file mode 100644 index 000000000000..ea93c6d6a7bc --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServicesResponse.php @@ -0,0 +1,101 @@ +google.api.servicemanagement.v1.ListServicesResponse + */ +class ListServicesResponse extends \Google\Protobuf\Internal\Message +{ + /** + * The returned services will only have the name field set. + * + * Generated from protobuf field repeated .google.api.servicemanagement.v1.ManagedService services = 1; + */ + private $services; + /** + * Token that can be passed to `ListServices` to resume a paginated query. + * + * 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 \Google\Cloud\ServiceManagement\V1\ManagedService[] $services + * The returned services will only have the name field set. + * @type string $next_page_token + * Token that can be passed to `ListServices` to resume a paginated query. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Api\Servicemanagement\V1\Servicemanager::initOnce(); + parent::__construct($data); + } + + /** + * The returned services will only have the name field set. + * + * Generated from protobuf field repeated .google.api.servicemanagement.v1.ManagedService services = 1; + * @return RepeatedField<\Google\Cloud\ServiceManagement\V1\ManagedService> + */ + public function getServices() + { + return $this->services; + } + + /** + * The returned services will only have the name field set. + * + * Generated from protobuf field repeated .google.api.servicemanagement.v1.ManagedService services = 1; + * @param \Google\Cloud\ServiceManagement\V1\ManagedService[] $var + * @return $this + */ + public function setServices($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\ServiceManagement\V1\ManagedService::class); + $this->services = $arr; + + return $this; + } + + /** + * Token that can be passed to `ListServices` to resume a paginated query. + * + * Generated from protobuf field string next_page_token = 2; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * Token that can be passed to `ListServices` to resume a paginated query. + * + * 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/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ManagedService.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ManagedService.php new file mode 100644 index 000000000000..b31101bae384 --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ManagedService.php @@ -0,0 +1,110 @@ +google.api.servicemanagement.v1.ManagedService + */ +class ManagedService extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the service. See the + * [overview](https://cloud.google.com/service-infrastructure/docs/overview) + * for naming requirements. + * + * Generated from protobuf field string service_name = 2; + */ + protected $service_name = ''; + /** + * ID of the project that produces and owns this service. + * + * Generated from protobuf field string producer_project_id = 3; + */ + protected $producer_project_id = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $service_name + * The name of the service. See the + * [overview](https://cloud.google.com/service-infrastructure/docs/overview) + * for naming requirements. + * @type string $producer_project_id + * ID of the project that produces and owns this service. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Api\Servicemanagement\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * The name of the service. See the + * [overview](https://cloud.google.com/service-infrastructure/docs/overview) + * for naming requirements. + * + * Generated from protobuf field string service_name = 2; + * @return string + */ + public function getServiceName() + { + return $this->service_name; + } + + /** + * The name of the service. See the + * [overview](https://cloud.google.com/service-infrastructure/docs/overview) + * for naming requirements. + * + * Generated from protobuf field string service_name = 2; + * @param string $var + * @return $this + */ + public function setServiceName($var) + { + GPBUtil::checkString($var, True); + $this->service_name = $var; + + return $this; + } + + /** + * ID of the project that produces and owns this service. + * + * Generated from protobuf field string producer_project_id = 3; + * @return string + */ + public function getProducerProjectId() + { + return $this->producer_project_id; + } + + /** + * ID of the project that produces and owns this service. + * + * Generated from protobuf field string producer_project_id = 3; + * @param string $var + * @return $this + */ + public function setProducerProjectId($var) + { + GPBUtil::checkString($var, True); + $this->producer_project_id = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/OperationMetadata.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/OperationMetadata.php new file mode 100644 index 000000000000..8c8bc1bc1be9 --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/OperationMetadata.php @@ -0,0 +1,183 @@ +google.api.servicemanagement.v1.OperationMetadata + */ +class OperationMetadata extends \Google\Protobuf\Internal\Message +{ + /** + * The full name of the resources that this operation is directly + * associated with. + * + * Generated from protobuf field repeated string resource_names = 1; + */ + private $resource_names; + /** + * Detailed status information for each step. The order is undetermined. + * + * Generated from protobuf field repeated .google.api.servicemanagement.v1.OperationMetadata.Step steps = 2; + */ + private $steps; + /** + * Percentage of completion of this operation, ranging from 0 to 100. + * + * Generated from protobuf field int32 progress_percentage = 3; + */ + protected $progress_percentage = 0; + /** + * The start time of the operation. + * + * Generated from protobuf field .google.protobuf.Timestamp start_time = 4; + */ + protected $start_time = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string[] $resource_names + * The full name of the resources that this operation is directly + * associated with. + * @type \Google\Cloud\ServiceManagement\V1\OperationMetadata\Step[] $steps + * Detailed status information for each step. The order is undetermined. + * @type int $progress_percentage + * Percentage of completion of this operation, ranging from 0 to 100. + * @type \Google\Protobuf\Timestamp $start_time + * The start time of the operation. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Api\Servicemanagement\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * The full name of the resources that this operation is directly + * associated with. + * + * Generated from protobuf field repeated string resource_names = 1; + * @return RepeatedField + */ + public function getResourceNames() + { + return $this->resource_names; + } + + /** + * The full name of the resources that this operation is directly + * associated with. + * + * Generated from protobuf field repeated string resource_names = 1; + * @param string[] $var + * @return $this + */ + public function setResourceNames($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->resource_names = $arr; + + return $this; + } + + /** + * Detailed status information for each step. The order is undetermined. + * + * Generated from protobuf field repeated .google.api.servicemanagement.v1.OperationMetadata.Step steps = 2; + * @return RepeatedField<\Google\Cloud\ServiceManagement\V1\OperationMetadata\Step> + */ + public function getSteps() + { + return $this->steps; + } + + /** + * Detailed status information for each step. The order is undetermined. + * + * Generated from protobuf field repeated .google.api.servicemanagement.v1.OperationMetadata.Step steps = 2; + * @param \Google\Cloud\ServiceManagement\V1\OperationMetadata\Step[] $var + * @return $this + */ + public function setSteps($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\ServiceManagement\V1\OperationMetadata\Step::class); + $this->steps = $arr; + + return $this; + } + + /** + * Percentage of completion of this operation, ranging from 0 to 100. + * + * Generated from protobuf field int32 progress_percentage = 3; + * @return int + */ + public function getProgressPercentage() + { + return $this->progress_percentage; + } + + /** + * Percentage of completion of this operation, ranging from 0 to 100. + * + * Generated from protobuf field int32 progress_percentage = 3; + * @param int $var + * @return $this + */ + public function setProgressPercentage($var) + { + GPBUtil::checkInt32($var); + $this->progress_percentage = $var; + + return $this; + } + + /** + * The start time of the operation. + * + * 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 time of the operation. + * + * 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; + } + +} + diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/OperationMetadata/Status.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/OperationMetadata/Status.php new file mode 100644 index 000000000000..9a84bb364388 --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/OperationMetadata/Status.php @@ -0,0 +1,83 @@ +google.api.servicemanagement.v1.OperationMetadata.Status + */ +class Status +{ + /** + * Unspecifed code. + * + * Generated from protobuf enum STATUS_UNSPECIFIED = 0; + */ + const STATUS_UNSPECIFIED = 0; + /** + * The operation or step has completed without errors. + * + * Generated from protobuf enum DONE = 1; + */ + const DONE = 1; + /** + * The operation or step has not started yet. + * + * Generated from protobuf enum NOT_STARTED = 2; + */ + const NOT_STARTED = 2; + /** + * The operation or step is in progress. + * + * Generated from protobuf enum IN_PROGRESS = 3; + */ + const IN_PROGRESS = 3; + /** + * The operation or step has completed with errors. If the operation is + * rollbackable, the rollback completed with errors too. + * + * Generated from protobuf enum FAILED = 4; + */ + const FAILED = 4; + /** + * The operation or step has completed with cancellation. + * + * Generated from protobuf enum CANCELLED = 5; + */ + const CANCELLED = 5; + + private static $valueToName = [ + self::STATUS_UNSPECIFIED => 'STATUS_UNSPECIFIED', + self::DONE => 'DONE', + self::NOT_STARTED => 'NOT_STARTED', + self::IN_PROGRESS => 'IN_PROGRESS', + self::FAILED => 'FAILED', + 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); + } +} + diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/OperationMetadata/Step.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/OperationMetadata/Step.php new file mode 100644 index 000000000000..695727dfdb86 --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/OperationMetadata/Step.php @@ -0,0 +1,101 @@ +google.api.servicemanagement.v1.OperationMetadata.Step + */ +class Step extends \Google\Protobuf\Internal\Message +{ + /** + * The short description of the step. + * + * Generated from protobuf field string description = 2; + */ + protected $description = ''; + /** + * The status code. + * + * Generated from protobuf field .google.api.servicemanagement.v1.OperationMetadata.Status status = 4; + */ + protected $status = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $description + * The short description of the step. + * @type int $status + * The status code. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Api\Servicemanagement\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * The short description of the step. + * + * Generated from protobuf field string description = 2; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * The short description of the step. + * + * 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; + } + + /** + * The status code. + * + * Generated from protobuf field .google.api.servicemanagement.v1.OperationMetadata.Status status = 4; + * @return int + */ + public function getStatus() + { + return $this->status; + } + + /** + * The status code. + * + * Generated from protobuf field .google.api.servicemanagement.v1.OperationMetadata.Status status = 4; + * @param int $var + * @return $this + */ + public function setStatus($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\ServiceManagement\V1\OperationMetadata\Status::class); + $this->status = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Rollout.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Rollout.php new file mode 100644 index 000000000000..f4fc4a99bd85 --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Rollout.php @@ -0,0 +1,332 @@ +google.api.servicemanagement.v1.Rollout + */ +class Rollout extends \Google\Protobuf\Internal\Message +{ + /** + * Optional. Unique identifier of this Rollout. Must be no longer than 63 + * characters and only lower case letters, digits, '.', '_' and '-' are + * allowed. + * If not specified by client, the server will generate one. The generated id + * will have the form of , where "date" is the create + * date in ISO 8601 format. "revision number" is a monotonically increasing + * positive number that is reset every day for each service. + * An example of the generated rollout_id is '2016-02-16r1' + * + * Generated from protobuf field string rollout_id = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $rollout_id = ''; + /** + * Creation time of the rollout. Readonly. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 2; + */ + protected $create_time = null; + /** + * The user who created the Rollout. Readonly. + * + * Generated from protobuf field string created_by = 3; + */ + protected $created_by = ''; + /** + * The status of this rollout. Readonly. In case of a failed rollout, + * the system will automatically rollback to the current Rollout + * version. Readonly. + * + * Generated from protobuf field .google.api.servicemanagement.v1.Rollout.RolloutStatus status = 4; + */ + protected $status = 0; + /** + * The name of the service associated with this Rollout. + * + * Generated from protobuf field string service_name = 8; + */ + protected $service_name = ''; + protected $strategy; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $rollout_id + * Optional. Unique identifier of this Rollout. Must be no longer than 63 + * characters and only lower case letters, digits, '.', '_' and '-' are + * allowed. + * If not specified by client, the server will generate one. The generated id + * will have the form of , where "date" is the create + * date in ISO 8601 format. "revision number" is a monotonically increasing + * positive number that is reset every day for each service. + * An example of the generated rollout_id is '2016-02-16r1' + * @type \Google\Protobuf\Timestamp $create_time + * Creation time of the rollout. Readonly. + * @type string $created_by + * The user who created the Rollout. Readonly. + * @type int $status + * The status of this rollout. Readonly. In case of a failed rollout, + * the system will automatically rollback to the current Rollout + * version. Readonly. + * @type \Google\Cloud\ServiceManagement\V1\Rollout\TrafficPercentStrategy $traffic_percent_strategy + * Google Service Control selects service configurations based on + * traffic percentage. + * @type \Google\Cloud\ServiceManagement\V1\Rollout\DeleteServiceStrategy $delete_service_strategy + * The strategy associated with a rollout to delete a `ManagedService`. + * Readonly. + * @type string $service_name + * The name of the service associated with this Rollout. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Api\Servicemanagement\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * Optional. Unique identifier of this Rollout. Must be no longer than 63 + * characters and only lower case letters, digits, '.', '_' and '-' are + * allowed. + * If not specified by client, the server will generate one. The generated id + * will have the form of , where "date" is the create + * date in ISO 8601 format. "revision number" is a monotonically increasing + * positive number that is reset every day for each service. + * An example of the generated rollout_id is '2016-02-16r1' + * + * Generated from protobuf field string rollout_id = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getRolloutId() + { + return $this->rollout_id; + } + + /** + * Optional. Unique identifier of this Rollout. Must be no longer than 63 + * characters and only lower case letters, digits, '.', '_' and '-' are + * allowed. + * If not specified by client, the server will generate one. The generated id + * will have the form of , where "date" is the create + * date in ISO 8601 format. "revision number" is a monotonically increasing + * positive number that is reset every day for each service. + * An example of the generated rollout_id is '2016-02-16r1' + * + * Generated from protobuf field string rollout_id = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @param string $var + * @return $this + */ + public function setRolloutId($var) + { + GPBUtil::checkString($var, True); + $this->rollout_id = $var; + + return $this; + } + + /** + * Creation time of the rollout. Readonly. + * + * 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); + } + + /** + * Creation time of the rollout. Readonly. + * + * 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; + } + + /** + * The user who created the Rollout. Readonly. + * + * Generated from protobuf field string created_by = 3; + * @return string + */ + public function getCreatedBy() + { + return $this->created_by; + } + + /** + * The user who created the Rollout. Readonly. + * + * Generated from protobuf field string created_by = 3; + * @param string $var + * @return $this + */ + public function setCreatedBy($var) + { + GPBUtil::checkString($var, True); + $this->created_by = $var; + + return $this; + } + + /** + * The status of this rollout. Readonly. In case of a failed rollout, + * the system will automatically rollback to the current Rollout + * version. Readonly. + * + * Generated from protobuf field .google.api.servicemanagement.v1.Rollout.RolloutStatus status = 4; + * @return int + */ + public function getStatus() + { + return $this->status; + } + + /** + * The status of this rollout. Readonly. In case of a failed rollout, + * the system will automatically rollback to the current Rollout + * version. Readonly. + * + * Generated from protobuf field .google.api.servicemanagement.v1.Rollout.RolloutStatus status = 4; + * @param int $var + * @return $this + */ + public function setStatus($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\ServiceManagement\V1\Rollout\RolloutStatus::class); + $this->status = $var; + + return $this; + } + + /** + * Google Service Control selects service configurations based on + * traffic percentage. + * + * Generated from protobuf field .google.api.servicemanagement.v1.Rollout.TrafficPercentStrategy traffic_percent_strategy = 5; + * @return \Google\Cloud\ServiceManagement\V1\Rollout\TrafficPercentStrategy|null + */ + public function getTrafficPercentStrategy() + { + return $this->readOneof(5); + } + + public function hasTrafficPercentStrategy() + { + return $this->hasOneof(5); + } + + /** + * Google Service Control selects service configurations based on + * traffic percentage. + * + * Generated from protobuf field .google.api.servicemanagement.v1.Rollout.TrafficPercentStrategy traffic_percent_strategy = 5; + * @param \Google\Cloud\ServiceManagement\V1\Rollout\TrafficPercentStrategy $var + * @return $this + */ + public function setTrafficPercentStrategy($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\ServiceManagement\V1\Rollout\TrafficPercentStrategy::class); + $this->writeOneof(5, $var); + + return $this; + } + + /** + * The strategy associated with a rollout to delete a `ManagedService`. + * Readonly. + * + * Generated from protobuf field .google.api.servicemanagement.v1.Rollout.DeleteServiceStrategy delete_service_strategy = 200; + * @return \Google\Cloud\ServiceManagement\V1\Rollout\DeleteServiceStrategy|null + */ + public function getDeleteServiceStrategy() + { + return $this->readOneof(200); + } + + public function hasDeleteServiceStrategy() + { + return $this->hasOneof(200); + } + + /** + * The strategy associated with a rollout to delete a `ManagedService`. + * Readonly. + * + * Generated from protobuf field .google.api.servicemanagement.v1.Rollout.DeleteServiceStrategy delete_service_strategy = 200; + * @param \Google\Cloud\ServiceManagement\V1\Rollout\DeleteServiceStrategy $var + * @return $this + */ + public function setDeleteServiceStrategy($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\ServiceManagement\V1\Rollout\DeleteServiceStrategy::class); + $this->writeOneof(200, $var); + + return $this; + } + + /** + * The name of the service associated with this Rollout. + * + * Generated from protobuf field string service_name = 8; + * @return string + */ + public function getServiceName() + { + return $this->service_name; + } + + /** + * The name of the service associated with this Rollout. + * + * Generated from protobuf field string service_name = 8; + * @param string $var + * @return $this + */ + public function setServiceName($var) + { + GPBUtil::checkString($var, True); + $this->service_name = $var; + + return $this; + } + + /** + * @return string + */ + public function getStrategy() + { + return $this->whichOneof("strategy"); + } + +} + diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Rollout/DeleteServiceStrategy.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Rollout/DeleteServiceStrategy.php new file mode 100644 index 000000000000..e99cb79827d8 --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Rollout/DeleteServiceStrategy.php @@ -0,0 +1,34 @@ +google.api.servicemanagement.v1.Rollout.DeleteServiceStrategy + */ +class DeleteServiceStrategy extends \Google\Protobuf\Internal\Message +{ + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Api\Servicemanagement\V1\Resources::initOnce(); + parent::__construct($data); + } + +} + diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Rollout/RolloutStatus.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Rollout/RolloutStatus.php new file mode 100644 index 000000000000..66c23dce9241 --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Rollout/RolloutStatus.php @@ -0,0 +1,91 @@ +google.api.servicemanagement.v1.Rollout.RolloutStatus + */ +class RolloutStatus +{ + /** + * No status specified. + * + * Generated from protobuf enum ROLLOUT_STATUS_UNSPECIFIED = 0; + */ + const ROLLOUT_STATUS_UNSPECIFIED = 0; + /** + * The Rollout is in progress. + * + * Generated from protobuf enum IN_PROGRESS = 1; + */ + const IN_PROGRESS = 1; + /** + * The Rollout has completed successfully. + * + * Generated from protobuf enum SUCCESS = 2; + */ + const SUCCESS = 2; + /** + * The Rollout has been cancelled. This can happen if you have overlapping + * Rollout pushes, and the previous ones will be cancelled. + * + * Generated from protobuf enum CANCELLED = 3; + */ + const CANCELLED = 3; + /** + * The Rollout has failed and the rollback attempt has failed too. + * + * Generated from protobuf enum FAILED = 4; + */ + const FAILED = 4; + /** + * The Rollout has not started yet and is pending for execution. + * + * Generated from protobuf enum PENDING = 5; + */ + const PENDING = 5; + /** + * The Rollout has failed and rolled back to the previous successful + * Rollout. + * + * Generated from protobuf enum FAILED_ROLLED_BACK = 6; + */ + const FAILED_ROLLED_BACK = 6; + + private static $valueToName = [ + self::ROLLOUT_STATUS_UNSPECIFIED => 'ROLLOUT_STATUS_UNSPECIFIED', + self::IN_PROGRESS => 'IN_PROGRESS', + self::SUCCESS => 'SUCCESS', + self::CANCELLED => 'CANCELLED', + self::FAILED => 'FAILED', + self::PENDING => 'PENDING', + self::FAILED_ROLLED_BACK => 'FAILED_ROLLED_BACK', + ]; + + 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/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Rollout/TrafficPercentStrategy.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Rollout/TrafficPercentStrategy.php new file mode 100644 index 000000000000..200fc2c0bd71 --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Rollout/TrafficPercentStrategy.php @@ -0,0 +1,100 @@ +google.api.servicemanagement.v1.Rollout.TrafficPercentStrategy + */ +class TrafficPercentStrategy extends \Google\Protobuf\Internal\Message +{ + /** + * Maps service configuration IDs to their corresponding traffic percentage. + * Key is the service configuration ID, Value is the traffic percentage + * which must be greater than 0.0 and the sum must equal to 100.0. + * + * Generated from protobuf field map percentages = 1; + */ + private $percentages; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array|\Google\Protobuf\Internal\MapField $percentages + * Maps service configuration IDs to their corresponding traffic percentage. + * Key is the service configuration ID, Value is the traffic percentage + * which must be greater than 0.0 and the sum must equal to 100.0. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Api\Servicemanagement\V1\Resources::initOnce(); + parent::__construct($data); + } + + /** + * Maps service configuration IDs to their corresponding traffic percentage. + * Key is the service configuration ID, Value is the traffic percentage + * which must be greater than 0.0 and the sum must equal to 100.0. + * + * Generated from protobuf field map percentages = 1; + * @return \Google\Protobuf\Internal\MapField + */ + public function getPercentages() + { + return $this->percentages; + } + + /** + * Maps service configuration IDs to their corresponding traffic percentage. + * Key is the service configuration ID, Value is the traffic percentage + * which must be greater than 0.0 and the sum must equal to 100.0. + * + * Generated from protobuf field map percentages = 1; + * @param array|\Google\Protobuf\Internal\MapField $var + * @return $this + */ + public function setPercentages($var) + { + $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::DOUBLE); + $this->percentages = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/SubmitConfigSourceRequest.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/SubmitConfigSourceRequest.php new file mode 100644 index 000000000000..33c7dbcdefae --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/SubmitConfigSourceRequest.php @@ -0,0 +1,182 @@ +google.api.servicemanagement.v1.SubmitConfigSourceRequest + */ +class SubmitConfigSourceRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * + * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $service_name = ''; + /** + * Required. The source configuration for the service. + * + * Generated from protobuf field .google.api.servicemanagement.v1.ConfigSource config_source = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $config_source = null; + /** + * Optional. If set, this will result in the generation of a + * `google.api.Service` configuration based on the `ConfigSource` provided, + * but the generated config and the sources will NOT be persisted. + * + * Generated from protobuf field bool validate_only = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $validate_only = false; + + /** + * @param string $serviceName Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * @param \Google\Cloud\ServiceManagement\V1\ConfigSource $configSource Required. The source configuration for the service. + * @param bool $validateOnly Optional. If set, this will result in the generation of a + * `google.api.Service` configuration based on the `ConfigSource` provided, + * but the generated config and the sources will NOT be persisted. + * + * @return \Google\Cloud\ServiceManagement\V1\SubmitConfigSourceRequest + * + * @experimental + */ + public static function build(string $serviceName, \Google\Cloud\ServiceManagement\V1\ConfigSource $configSource, bool $validateOnly): self + { + return (new self()) + ->setServiceName($serviceName) + ->setConfigSource($configSource) + ->setValidateOnly($validateOnly); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $service_name + * Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * @type \Google\Cloud\ServiceManagement\V1\ConfigSource $config_source + * Required. The source configuration for the service. + * @type bool $validate_only + * Optional. If set, this will result in the generation of a + * `google.api.Service` configuration based on the `ConfigSource` provided, + * but the generated config and the sources will NOT be persisted. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Api\Servicemanagement\V1\Servicemanager::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * + * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getServiceName() + { + return $this->service_name; + } + + /** + * Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * + * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setServiceName($var) + { + GPBUtil::checkString($var, True); + $this->service_name = $var; + + return $this; + } + + /** + * Required. The source configuration for the service. + * + * Generated from protobuf field .google.api.servicemanagement.v1.ConfigSource config_source = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\ServiceManagement\V1\ConfigSource|null + */ + public function getConfigSource() + { + return $this->config_source; + } + + public function hasConfigSource() + { + return isset($this->config_source); + } + + public function clearConfigSource() + { + unset($this->config_source); + } + + /** + * Required. The source configuration for the service. + * + * Generated from protobuf field .google.api.servicemanagement.v1.ConfigSource config_source = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\ServiceManagement\V1\ConfigSource $var + * @return $this + */ + public function setConfigSource($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\ServiceManagement\V1\ConfigSource::class); + $this->config_source = $var; + + return $this; + } + + /** + * Optional. If set, this will result in the generation of a + * `google.api.Service` configuration based on the `ConfigSource` provided, + * but the generated config and the sources will NOT be persisted. + * + * 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, this will result in the generation of a + * `google.api.Service` configuration based on the `ConfigSource` provided, + * but the generated config and the sources will NOT be persisted. + * + * 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/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/SubmitConfigSourceResponse.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/SubmitConfigSourceResponse.php new file mode 100644 index 000000000000..92bd4f1d3637 --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/SubmitConfigSourceResponse.php @@ -0,0 +1,77 @@ +google.api.servicemanagement.v1.SubmitConfigSourceResponse + */ +class SubmitConfigSourceResponse extends \Google\Protobuf\Internal\Message +{ + /** + * The generated service configuration. + * + * Generated from protobuf field .google.api.Service service_config = 1; + */ + protected $service_config = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Api\Service $service_config + * The generated service configuration. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Api\Servicemanagement\V1\Servicemanager::initOnce(); + parent::__construct($data); + } + + /** + * The generated service configuration. + * + * Generated from protobuf field .google.api.Service service_config = 1; + * @return \Google\Api\Service|null + */ + public function getServiceConfig() + { + return $this->service_config; + } + + public function hasServiceConfig() + { + return isset($this->service_config); + } + + public function clearServiceConfig() + { + unset($this->service_config); + } + + /** + * The generated service configuration. + * + * Generated from protobuf field .google.api.Service service_config = 1; + * @param \Google\Api\Service $var + * @return $this + */ + public function setServiceConfig($var) + { + GPBUtil::checkMessage($var, \Google\Api\Service::class); + $this->service_config = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/UndeleteServiceRequest.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/UndeleteServiceRequest.php new file mode 100644 index 000000000000..3db84cbf537a --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/UndeleteServiceRequest.php @@ -0,0 +1,90 @@ +google.api.servicemanagement.v1.UndeleteServiceRequest + */ +class UndeleteServiceRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * + * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $service_name = ''; + + /** + * @param string $serviceName Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * + * @return \Google\Cloud\ServiceManagement\V1\UndeleteServiceRequest + * + * @experimental + */ + public static function build(string $serviceName): self + { + return (new self()) + ->setServiceName($serviceName); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $service_name + * Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Api\Servicemanagement\V1\Servicemanager::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * + * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getServiceName() + { + return $this->service_name; + } + + /** + * Required. The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + * + * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setServiceName($var) + { + GPBUtil::checkString($var, True); + $this->service_name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/UndeleteServiceResponse.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/UndeleteServiceResponse.php new file mode 100644 index 000000000000..3062350a4ed8 --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/UndeleteServiceResponse.php @@ -0,0 +1,77 @@ +google.api.servicemanagement.v1.UndeleteServiceResponse + */ +class UndeleteServiceResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Revived service resource. + * + * Generated from protobuf field .google.api.servicemanagement.v1.ManagedService service = 1; + */ + protected $service = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\ServiceManagement\V1\ManagedService $service + * Revived service resource. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Api\Servicemanagement\V1\Servicemanager::initOnce(); + parent::__construct($data); + } + + /** + * Revived service resource. + * + * Generated from protobuf field .google.api.servicemanagement.v1.ManagedService service = 1; + * @return \Google\Cloud\ServiceManagement\V1\ManagedService|null + */ + public function getService() + { + return $this->service; + } + + public function hasService() + { + return isset($this->service); + } + + public function clearService() + { + unset($this->service); + } + + /** + * Revived service resource. + * + * Generated from protobuf field .google.api.servicemanagement.v1.ManagedService service = 1; + * @param \Google\Cloud\ServiceManagement\V1\ManagedService $var + * @return $this + */ + public function setService($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\ServiceManagement\V1\ManagedService::class); + $this->service = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/create_service.php b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/create_service.php new file mode 100644 index 000000000000..df7d257431cc --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/create_service.php @@ -0,0 +1,81 @@ + + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function create_service_sample(): void +{ + // Create a client. + $serviceManagerClient = new ServiceManagerClient(); + + // Prepare the request message. + $service = new ManagedService(); + $request = (new CreateServiceRequest()) + ->setService($service); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $serviceManagerClient->createService($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var ManagedService $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 servicemanagement_v1_generated_ServiceManager_CreateService_sync] diff --git a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/create_service_config.php b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/create_service_config.php new file mode 100644 index 000000000000..317eb97b1af6 --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/create_service_config.php @@ -0,0 +1,81 @@ +setServiceName($serviceName) + ->setServiceConfig($serviceConfig); + + // Call the API and handle any network failures. + try { + /** @var Service $response */ + $response = $serviceManagerClient->createServiceConfig($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 +{ + $serviceName = '[SERVICE_NAME]'; + + create_service_config_sample($serviceName); +} +// [END servicemanagement_v1_generated_ServiceManager_CreateServiceConfig_sync] diff --git a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/create_service_rollout.php b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/create_service_rollout.php new file mode 100644 index 000000000000..4a5ca5f55829 --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/create_service_rollout.php @@ -0,0 +1,99 @@ + + * + * @param string $serviceName The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + */ +function create_service_rollout_sample(string $serviceName): void +{ + // Create a client. + $serviceManagerClient = new ServiceManagerClient(); + + // Prepare the request message. + $rollout = new Rollout(); + $request = (new CreateServiceRolloutRequest()) + ->setServiceName($serviceName) + ->setRollout($rollout); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $serviceManagerClient->createServiceRollout($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var Rollout $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 +{ + $serviceName = '[SERVICE_NAME]'; + + create_service_rollout_sample($serviceName); +} +// [END servicemanagement_v1_generated_ServiceManager_CreateServiceRollout_sync] diff --git a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/delete_service.php b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/delete_service.php new file mode 100644 index 000000000000..c47fe9bb41bd --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/delete_service.php @@ -0,0 +1,88 @@ + + * + * @param string $serviceName The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + */ +function delete_service_sample(string $serviceName): void +{ + // Create a client. + $serviceManagerClient = new ServiceManagerClient(); + + // Prepare the request message. + $request = (new DeleteServiceRequest()) + ->setServiceName($serviceName); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $serviceManagerClient->deleteService($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 +{ + $serviceName = '[SERVICE_NAME]'; + + delete_service_sample($serviceName); +} +// [END servicemanagement_v1_generated_ServiceManager_DeleteService_sync] diff --git a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/generate_config_report.php b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/generate_config_report.php new file mode 100644 index 000000000000..be4f1ff3e5c1 --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/generate_config_report.php @@ -0,0 +1,70 @@ +setNewConfig($newConfig); + + // Call the API and handle any network failures. + try { + /** @var GenerateConfigReportResponse $response */ + $response = $serviceManagerClient->generateConfigReport($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} +// [END servicemanagement_v1_generated_ServiceManager_GenerateConfigReport_sync] diff --git a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/get_iam_policy.php b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/get_iam_policy.php new file mode 100644 index 000000000000..2f64048d9e30 --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/get_iam_policy.php @@ -0,0 +1,72 @@ +setResource($resource); + + // Call the API and handle any network failures. + try { + /** @var Policy $response */ + $response = $serviceManagerClient->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 servicemanagement_v1_generated_ServiceManager_GetIamPolicy_sync] diff --git a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/get_service.php b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/get_service.php new file mode 100644 index 000000000000..e0674df1d8d3 --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/get_service.php @@ -0,0 +1,72 @@ +setServiceName($serviceName); + + // Call the API and handle any network failures. + try { + /** @var ManagedService $response */ + $response = $serviceManagerClient->getService($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 +{ + $serviceName = '[SERVICE_NAME]'; + + get_service_sample($serviceName); +} +// [END servicemanagement_v1_generated_ServiceManager_GetService_sync] diff --git a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/get_service_config.php b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/get_service_config.php new file mode 100644 index 000000000000..5199d5758add --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/get_service_config.php @@ -0,0 +1,78 @@ +setServiceName($serviceName) + ->setConfigId($configId); + + // Call the API and handle any network failures. + try { + /** @var Service $response */ + $response = $serviceManagerClient->getServiceConfig($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 +{ + $serviceName = '[SERVICE_NAME]'; + $configId = '[CONFIG_ID]'; + + get_service_config_sample($serviceName, $configId); +} +// [END servicemanagement_v1_generated_ServiceManager_GetServiceConfig_sync] diff --git a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/get_service_rollout.php b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/get_service_rollout.php new file mode 100644 index 000000000000..306dbb817d53 --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/get_service_rollout.php @@ -0,0 +1,76 @@ +setServiceName($serviceName) + ->setRolloutId($rolloutId); + + // Call the API and handle any network failures. + try { + /** @var Rollout $response */ + $response = $serviceManagerClient->getServiceRollout($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 +{ + $serviceName = '[SERVICE_NAME]'; + $rolloutId = '[ROLLOUT_ID]'; + + get_service_rollout_sample($serviceName, $rolloutId); +} +// [END servicemanagement_v1_generated_ServiceManager_GetServiceRollout_sync] diff --git a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/list_service_configs.php b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/list_service_configs.php new file mode 100644 index 000000000000..b3d94fe588cd --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/list_service_configs.php @@ -0,0 +1,78 @@ +setServiceName($serviceName); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $serviceManagerClient->listServiceConfigs($request); + + /** @var Service $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 +{ + $serviceName = '[SERVICE_NAME]'; + + list_service_configs_sample($serviceName); +} +// [END servicemanagement_v1_generated_ServiceManager_ListServiceConfigs_sync] diff --git a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/list_service_rollouts.php b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/list_service_rollouts.php new file mode 100644 index 000000000000..1d46ced4f5fc --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/list_service_rollouts.php @@ -0,0 +1,90 @@ +setServiceName($serviceName) + ->setFilter($filter); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $serviceManagerClient->listServiceRollouts($request); + + /** @var Rollout $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 +{ + $serviceName = '[SERVICE_NAME]'; + $filter = '[FILTER]'; + + list_service_rollouts_sample($serviceName, $filter); +} +// [END servicemanagement_v1_generated_ServiceManager_ListServiceRollouts_sync] diff --git a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/list_services.php b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/list_services.php new file mode 100644 index 000000000000..ccea027535d2 --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/list_services.php @@ -0,0 +1,66 @@ +listServices($request); + + /** @var ManagedService $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 servicemanagement_v1_generated_ServiceManager_ListServices_sync] diff --git a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/set_iam_policy.php b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/set_iam_policy.php new file mode 100644 index 000000000000..7f22549ebd66 --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/set_iam_policy.php @@ -0,0 +1,77 @@ +setResource($resource) + ->setPolicy($policy); + + // Call the API and handle any network failures. + try { + /** @var Policy $response */ + $response = $serviceManagerClient->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 servicemanagement_v1_generated_ServiceManager_SetIamPolicy_sync] diff --git a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/submit_config_source.php b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/submit_config_source.php new file mode 100644 index 000000000000..f7bc8a36cc42 --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/submit_config_source.php @@ -0,0 +1,100 @@ + + * + * @param string $serviceName The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + */ +function submit_config_source_sample(string $serviceName): void +{ + // Create a client. + $serviceManagerClient = new ServiceManagerClient(); + + // Prepare the request message. + $configSource = new ConfigSource(); + $request = (new SubmitConfigSourceRequest()) + ->setServiceName($serviceName) + ->setConfigSource($configSource); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $serviceManagerClient->submitConfigSource($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var SubmitConfigSourceResponse $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 +{ + $serviceName = '[SERVICE_NAME]'; + + submit_config_source_sample($serviceName); +} +// [END servicemanagement_v1_generated_ServiceManager_SubmitConfigSource_sync] diff --git a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/test_iam_permissions.php b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/test_iam_permissions.php new file mode 100644 index 000000000000..311f3a94380e --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/test_iam_permissions.php @@ -0,0 +1,84 @@ +setResource($resource) + ->setPermissions($permissions); + + // Call the API and handle any network failures. + try { + /** @var TestIamPermissionsResponse $response */ + $response = $serviceManagerClient->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 servicemanagement_v1_generated_ServiceManager_TestIamPermissions_sync] diff --git a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/undelete_service.php b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/undelete_service.php new file mode 100644 index 000000000000..f3c4b43f8825 --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/undelete_service.php @@ -0,0 +1,89 @@ + + * + * @param string $serviceName The name of the service. See the + * [overview](https://cloud.google.com/service-management/overview) for naming + * requirements. For example: `example.googleapis.com`. + */ +function undelete_service_sample(string $serviceName): void +{ + // Create a client. + $serviceManagerClient = new ServiceManagerClient(); + + // Prepare the request message. + $request = (new UndeleteServiceRequest()) + ->setServiceName($serviceName); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $serviceManagerClient->undeleteService($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var UndeleteServiceResponse $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 +{ + $serviceName = '[SERVICE_NAME]'; + + undelete_service_sample($serviceName); +} +// [END servicemanagement_v1_generated_ServiceManager_UndeleteService_sync] diff --git a/owl-bot-staging/ServiceManagement/v1/src/V1/Client/ServiceManagerClient.php b/owl-bot-staging/ServiceManagement/v1/src/V1/Client/ServiceManagerClient.php new file mode 100644 index 000000000000..91d0b60eb5aa --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/src/V1/Client/ServiceManagerClient.php @@ -0,0 +1,775 @@ + createServiceAsync(CreateServiceRequest $request, array $optionalArgs = []) + * @method PromiseInterface createServiceConfigAsync(CreateServiceConfigRequest $request, array $optionalArgs = []) + * @method PromiseInterface createServiceRolloutAsync(CreateServiceRolloutRequest $request, array $optionalArgs = []) + * @method PromiseInterface deleteServiceAsync(DeleteServiceRequest $request, array $optionalArgs = []) + * @method PromiseInterface generateConfigReportAsync(GenerateConfigReportRequest $request, array $optionalArgs = []) + * @method PromiseInterface getServiceAsync(GetServiceRequest $request, array $optionalArgs = []) + * @method PromiseInterface getServiceConfigAsync(GetServiceConfigRequest $request, array $optionalArgs = []) + * @method PromiseInterface getServiceRolloutAsync(GetServiceRolloutRequest $request, array $optionalArgs = []) + * @method PromiseInterface listServiceConfigsAsync(ListServiceConfigsRequest $request, array $optionalArgs = []) + * @method PromiseInterface listServiceRolloutsAsync(ListServiceRolloutsRequest $request, array $optionalArgs = []) + * @method PromiseInterface listServicesAsync(ListServicesRequest $request, array $optionalArgs = []) + * @method PromiseInterface submitConfigSourceAsync(SubmitConfigSourceRequest $request, array $optionalArgs = []) + * @method PromiseInterface undeleteServiceAsync(UndeleteServiceRequest $request, array $optionalArgs = []) + * @method PromiseInterface getIamPolicyAsync(GetIamPolicyRequest $request, array $optionalArgs = []) + * @method PromiseInterface setIamPolicyAsync(SetIamPolicyRequest $request, array $optionalArgs = []) + * @method PromiseInterface testIamPermissionsAsync(TestIamPermissionsRequest $request, array $optionalArgs = []) + */ +final class ServiceManagerClient +{ + use GapicClientTrait; + + /** The name of the service. */ + private const SERVICE_NAME = 'google.api.servicemanagement.v1.ServiceManager'; + + /** + * The default address of the service. + * + * @deprecated SERVICE_ADDRESS_TEMPLATE should be used instead. + */ + private const SERVICE_ADDRESS = 'servicemanagement.googleapis.com'; + + /** The address template of the service. */ + private const SERVICE_ADDRESS_TEMPLATE = 'servicemanagement.UNIVERSE_DOMAIN'; + + /** The default port of the service. */ + private const DEFAULT_SERVICE_PORT = 443; + + /** The name of the code generator, to be included in the agent header. */ + private 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', + 'https://www.googleapis.com/auth/service.management', + 'https://www.googleapis.com/auth/service.management.readonly', + ]; + + private $operationsClient; + + private static function getClientDefaults() + { + return [ + 'serviceName' => self::SERVICE_NAME, + 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, + 'clientConfig' => __DIR__ . '/../resources/service_manager_client_config.json', + 'descriptorsConfigPath' => __DIR__ . '/../resources/service_manager_descriptor_config.php', + 'gcpApiConfigPath' => __DIR__ . '/../resources/service_manager_grpc_config.json', + 'credentialsConfig' => [ + 'defaultScopes' => self::$serviceScopes, + ], + 'transportConfig' => [ + 'rest' => [ + 'restClientConfigPath' => __DIR__ . '/../resources/service_manager_rest_client_config.php', + ], + ], + ]; + } + + /** + * 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 = $this->descriptors[$methodName]['longRunning'] ?? []; + $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); + $operation->reload(); + return $operation; + } + + /** + * Create the default operation client for the service. + * + * @param array $options ClientOptions for the client. + * + * @return OperationsClient + */ + private function createOperationsClient(array $options) + { + // Unset client-specific configuration options + unset($options['serviceName'], $options['clientConfig'], $options['descriptorsConfigPath']); + + if (isset($options['operationsClient'])) { + return $options['operationsClient']; + } + + return new OperationsClient($options); + } + + /** + * Constructor. + * + * @param array|ClientOptions $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 'servicemanagement.googleapis.com:443'. + * @type FetchAuthTokenInterface|CredentialsWrapper $credentials + * This option should only be used with a pre-constructed + * {@see FetchAuthTokenInterface} or {@see CredentialsWrapper} object. Note that + * when one of these objects are provided, any settings in $credentialsConfig will + * be ignored. + * **Important**: If you are providing a path to a credentials file, or a decoded + * credentials file as a PHP array, this usage is now DEPRECATED. Providing an + * unvalidated credential configuration to Google APIs can compromise the security + * of your systems and data. It is recommended to create the credentials explicitly + * ``` + * use Google\Auth\Credentials\ServiceAccountCredentials; + * use Google\Cloud\ServiceManagement\V1\ServiceManagerClient; + * $creds = new ServiceAccountCredentials($scopes, $json); + * $options = new ServiceManagerClient(['credentials' => $creds]); + * ``` + * {@see + * https://cloud.google.com/docs/authentication/external/externally-sourced-credentials} + * @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. + * @type false|LoggerInterface $logger + * A PSR-3 compliant logger. If set to false, logging is disabled, ignoring the + * 'GOOGLE_SDK_PHP_LOGGING' environment flag + * @type string $universeDomain + * The service domain for the client. Defaults to 'googleapis.com'. + * } + * + * @throws ValidationException + */ + public function __construct(array|ClientOptions $options = []) + { + $clientOptions = $this->buildClientOptions($options); + $this->setClientOptions($clientOptions); + $this->operationsClient = $this->createOperationsClient($clientOptions); + } + + /** Handles execution of the async variants for each documented method. */ + public function __call($method, $args) + { + if (substr($method, -5) !== 'Async') { + trigger_error('Call to undefined method ' . __CLASS__ . "::$method()", E_USER_ERROR); + } + + array_unshift($args, substr($method, 0, -5)); + return call_user_func_array([$this, 'startAsyncCall'], $args); + } + + /** + * Creates a new managed service. + * + * A managed service is immutable, and is subject to mandatory 30-day + * data retention. You cannot move a service or recreate it within 30 days + * after deletion. + * + * One producer project can own no more than 500 services. For security and + * reliability purposes, a production service should be hosted in a + * dedicated producer project. + * + * Operation + * + * The async variant is {@see ServiceManagerClient::createServiceAsync()} . + * + * @example samples/V1/ServiceManagerClient/create_service.php + * + * @param CreateServiceRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function createService(CreateServiceRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('CreateService', $request, $callOptions)->wait(); + } + + /** + * Creates a new service configuration (version) for a managed service. + * This method only stores the service configuration. To roll out the service + * configuration to backend systems please call + * [CreateServiceRollout][google.api.servicemanagement.v1.ServiceManager.CreateServiceRollout]. + * + * Only the 100 most recent service configurations and ones referenced by + * existing rollouts are kept for each service. The rest will be deleted + * eventually. + * + * The async variant is {@see ServiceManagerClient::createServiceConfigAsync()} . + * + * @example samples/V1/ServiceManagerClient/create_service_config.php + * + * @param CreateServiceConfigRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Service + * + * @throws ApiException Thrown if the API call fails. + */ + public function createServiceConfig(CreateServiceConfigRequest $request, array $callOptions = []): Service + { + return $this->startApiCall('CreateServiceConfig', $request, $callOptions)->wait(); + } + + /** + * Creates a new service configuration rollout. Based on rollout, the + * Google Service Management will roll out the service configurations to + * different backend services. For example, the logging configuration will be + * pushed to Google Cloud Logging. + * + * Please note that any previous pending and running Rollouts and associated + * Operations will be automatically cancelled so that the latest Rollout will + * not be blocked by previous Rollouts. + * + * Only the 100 most recent (in any state) and the last 10 successful (if not + * already part of the set of 100 most recent) rollouts are kept for each + * service. The rest will be deleted eventually. + * + * Operation + * + * The async variant is {@see ServiceManagerClient::createServiceRolloutAsync()} . + * + * @example samples/V1/ServiceManagerClient/create_service_rollout.php + * + * @param CreateServiceRolloutRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function createServiceRollout(CreateServiceRolloutRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('CreateServiceRollout', $request, $callOptions)->wait(); + } + + /** + * Deletes a managed service. This method will change the service to the + * `Soft-Delete` state for 30 days. Within this period, service producers may + * call + * [UndeleteService][google.api.servicemanagement.v1.ServiceManager.UndeleteService] + * to restore the service. After 30 days, the service will be permanently + * deleted. + * + * Operation + * + * The async variant is {@see ServiceManagerClient::deleteServiceAsync()} . + * + * @example samples/V1/ServiceManagerClient/delete_service.php + * + * @param DeleteServiceRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function deleteService(DeleteServiceRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('DeleteService', $request, $callOptions)->wait(); + } + + /** + * Generates and returns a report (errors, warnings and changes from + * existing configurations) associated with + * GenerateConfigReportRequest.new_value + * + * If GenerateConfigReportRequest.old_value is specified, + * GenerateConfigReportRequest will contain a single ChangeReport based on the + * comparison between GenerateConfigReportRequest.new_value and + * GenerateConfigReportRequest.old_value. + * If GenerateConfigReportRequest.old_value is not specified, this method + * will compare GenerateConfigReportRequest.new_value with the last pushed + * service configuration. + * + * The async variant is {@see ServiceManagerClient::generateConfigReportAsync()} . + * + * @example samples/V1/ServiceManagerClient/generate_config_report.php + * + * @param GenerateConfigReportRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 GenerateConfigReportResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function generateConfigReport(GenerateConfigReportRequest $request, array $callOptions = []): GenerateConfigReportResponse + { + return $this->startApiCall('GenerateConfigReport', $request, $callOptions)->wait(); + } + + /** + * Gets a managed service. Authentication is required unless the service is + * public. + * + * The async variant is {@see ServiceManagerClient::getServiceAsync()} . + * + * @example samples/V1/ServiceManagerClient/get_service.php + * + * @param GetServiceRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 ManagedService + * + * @throws ApiException Thrown if the API call fails. + */ + public function getService(GetServiceRequest $request, array $callOptions = []): ManagedService + { + return $this->startApiCall('GetService', $request, $callOptions)->wait(); + } + + /** + * Gets a service configuration (version) for a managed service. + * + * The async variant is {@see ServiceManagerClient::getServiceConfigAsync()} . + * + * @example samples/V1/ServiceManagerClient/get_service_config.php + * + * @param GetServiceConfigRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Service + * + * @throws ApiException Thrown if the API call fails. + */ + public function getServiceConfig(GetServiceConfigRequest $request, array $callOptions = []): Service + { + return $this->startApiCall('GetServiceConfig', $request, $callOptions)->wait(); + } + + /** + * Gets a service configuration + * [rollout][google.api.servicemanagement.v1.Rollout]. + * + * The async variant is {@see ServiceManagerClient::getServiceRolloutAsync()} . + * + * @example samples/V1/ServiceManagerClient/get_service_rollout.php + * + * @param GetServiceRolloutRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Rollout + * + * @throws ApiException Thrown if the API call fails. + */ + public function getServiceRollout(GetServiceRolloutRequest $request, array $callOptions = []): Rollout + { + return $this->startApiCall('GetServiceRollout', $request, $callOptions)->wait(); + } + + /** + * Lists the history of the service configuration for a managed service, + * from the newest to the oldest. + * + * The async variant is {@see ServiceManagerClient::listServiceConfigsAsync()} . + * + * @example samples/V1/ServiceManagerClient/list_service_configs.php + * + * @param ListServiceConfigsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listServiceConfigs(ListServiceConfigsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListServiceConfigs', $request, $callOptions); + } + + /** + * Lists the history of the service configuration rollouts for a managed + * service, from the newest to the oldest. + * + * The async variant is {@see ServiceManagerClient::listServiceRolloutsAsync()} . + * + * @example samples/V1/ServiceManagerClient/list_service_rollouts.php + * + * @param ListServiceRolloutsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listServiceRollouts(ListServiceRolloutsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListServiceRollouts', $request, $callOptions); + } + + /** + * Lists managed services. + * + * Returns all public services. For authenticated users, also returns all + * services the calling user has "servicemanagement.services.get" permission + * for. + * + * The async variant is {@see ServiceManagerClient::listServicesAsync()} . + * + * @example samples/V1/ServiceManagerClient/list_services.php + * + * @param ListServicesRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listServices(ListServicesRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListServices', $request, $callOptions); + } + + /** + * Creates a new service configuration (version) for a managed service based + * on + * user-supplied configuration source files (for example: OpenAPI + * Specification). This method stores the source configurations as well as the + * generated service configuration. To rollout the service configuration to + * other services, + * please call + * [CreateServiceRollout][google.api.servicemanagement.v1.ServiceManager.CreateServiceRollout]. + * + * Only the 100 most recent configuration sources and ones referenced by + * existing service configurtions are kept for each service. The rest will be + * deleted eventually. + * + * Operation + * + * The async variant is {@see ServiceManagerClient::submitConfigSourceAsync()} . + * + * @example samples/V1/ServiceManagerClient/submit_config_source.php + * + * @param SubmitConfigSourceRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function submitConfigSource(SubmitConfigSourceRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('SubmitConfigSource', $request, $callOptions)->wait(); + } + + /** + * Revives a previously deleted managed service. The method restores the + * service using the configuration at the time the service was deleted. + * The target service must exist and must have been deleted within the + * last 30 days. + * + * Operation + * + * The async variant is {@see ServiceManagerClient::undeleteServiceAsync()} . + * + * @example samples/V1/ServiceManagerClient/undelete_service.php + * + * @param UndeleteServiceRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function undeleteService(UndeleteServiceRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('UndeleteService', $request, $callOptions)->wait(); + } + + /** + * Gets the access control policy for a resource. Returns an empty policy + * if the resource exists and does not have a policy set. + * + * The async variant is {@see ServiceManagerClient::getIamPolicyAsync()} . + * + * @example samples/V1/ServiceManagerClient/get_iam_policy.php + * + * @param GetIamPolicyRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Policy + * + * @throws ApiException Thrown if the API call fails. + */ + public function getIamPolicy(GetIamPolicyRequest $request, array $callOptions = []): Policy + { + return $this->startApiCall('GetIamPolicy', $request, $callOptions)->wait(); + } + + /** + * Sets the access control policy on the specified resource. Replaces + * any existing policy. + * + * Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` + * errors. + * + * The async variant is {@see ServiceManagerClient::setIamPolicyAsync()} . + * + * @example samples/V1/ServiceManagerClient/set_iam_policy.php + * + * @param SetIamPolicyRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Policy + * + * @throws ApiException Thrown if the API call fails. + */ + public function setIamPolicy(SetIamPolicyRequest $request, array $callOptions = []): Policy + { + return $this->startApiCall('SetIamPolicy', $request, $callOptions)->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. + * + * The async variant is {@see ServiceManagerClient::testIamPermissionsAsync()} . + * + * @example samples/V1/ServiceManagerClient/test_iam_permissions.php + * + * @param TestIamPermissionsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 TestIamPermissionsResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function testIamPermissions(TestIamPermissionsRequest $request, array $callOptions = []): TestIamPermissionsResponse + { + return $this->startApiCall('TestIamPermissions', $request, $callOptions)->wait(); + } +} diff --git a/owl-bot-staging/ServiceManagement/v1/src/V1/gapic_metadata.json b/owl-bot-staging/ServiceManagement/v1/src/V1/gapic_metadata.json new file mode 100644 index 000000000000..a49b2d300c46 --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/src/V1/gapic_metadata.json @@ -0,0 +1,98 @@ +{ + "schema": "1.0", + "comment": "This file maps proto services\/RPCs to the corresponding library clients\/methods", + "language": "php", + "protoPackage": "google.api.servicemanagement.v1", + "libraryPackage": "Google\\Cloud\\ServiceManagement\\V1", + "services": { + "ServiceManager": { + "clients": { + "grpc": { + "libraryClient": "ServiceManagerGapicClient", + "rpcs": { + "CreateService": { + "methods": [ + "createService" + ] + }, + "CreateServiceConfig": { + "methods": [ + "createServiceConfig" + ] + }, + "CreateServiceRollout": { + "methods": [ + "createServiceRollout" + ] + }, + "DeleteService": { + "methods": [ + "deleteService" + ] + }, + "GenerateConfigReport": { + "methods": [ + "generateConfigReport" + ] + }, + "GetService": { + "methods": [ + "getService" + ] + }, + "GetServiceConfig": { + "methods": [ + "getServiceConfig" + ] + }, + "GetServiceRollout": { + "methods": [ + "getServiceRollout" + ] + }, + "ListServiceConfigs": { + "methods": [ + "listServiceConfigs" + ] + }, + "ListServiceRollouts": { + "methods": [ + "listServiceRollouts" + ] + }, + "ListServices": { + "methods": [ + "listServices" + ] + }, + "SubmitConfigSource": { + "methods": [ + "submitConfigSource" + ] + }, + "UndeleteService": { + "methods": [ + "undeleteService" + ] + }, + "GetIamPolicy": { + "methods": [ + "getIamPolicy" + ] + }, + "SetIamPolicy": { + "methods": [ + "setIamPolicy" + ] + }, + "TestIamPermissions": { + "methods": [ + "testIamPermissions" + ] + } + } + } + } + } + } +} \ No newline at end of file diff --git a/owl-bot-staging/ServiceManagement/v1/src/V1/resources/service_manager_client_config.json b/owl-bot-staging/ServiceManagement/v1/src/V1/resources/service_manager_client_config.json new file mode 100644 index 000000000000..50c8109082f2 --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/src/V1/resources/service_manager_client_config.json @@ -0,0 +1,112 @@ +{ + "interfaces": { + "google.api.servicemanagement.v1.ServiceManager": { + "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": { + "CreateService": { + "timeout_millis": 10000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + }, + "CreateServiceConfig": { + "timeout_millis": 10000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + }, + "CreateServiceRollout": { + "timeout_millis": 10000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + }, + "DeleteService": { + "timeout_millis": 10000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + }, + "GenerateConfigReport": { + "timeout_millis": 10000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + }, + "GetService": { + "timeout_millis": 10000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + }, + "GetServiceConfig": { + "timeout_millis": 10000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + }, + "GetServiceRollout": { + "timeout_millis": 10000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + }, + "ListServiceConfigs": { + "timeout_millis": 10000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + }, + "ListServiceRollouts": { + "timeout_millis": 10000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + }, + "ListServices": { + "timeout_millis": 10000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + }, + "SubmitConfigSource": { + "timeout_millis": 10000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + }, + "UndeleteService": { + "timeout_millis": 10000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + }, + "GetIamPolicy": { + "timeout_millis": 10000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + }, + "SetIamPolicy": { + "timeout_millis": 10000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + }, + "TestIamPermissions": { + "timeout_millis": 10000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + } + } + } + } +} diff --git a/owl-bot-staging/ServiceManagement/v1/src/V1/resources/service_manager_descriptor_config.php b/owl-bot-staging/ServiceManagement/v1/src/V1/resources/service_manager_descriptor_config.php new file mode 100644 index 000000000000..76ccc9a45e6b --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/src/V1/resources/service_manager_descriptor_config.php @@ -0,0 +1,270 @@ + [ + 'google.api.servicemanagement.v1.ServiceManager' => [ + 'CreateService' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\ServiceManagement\V1\ManagedService', + 'metadataReturnType' => '\Google\Cloud\ServiceManagement\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + ], + 'CreateServiceRollout' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\ServiceManagement\V1\Rollout', + 'metadataReturnType' => '\Google\Cloud\ServiceManagement\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'service_name', + 'fieldAccessors' => [ + 'getServiceName', + ], + ], + ], + ], + 'DeleteService' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Protobuf\GPBEmpty', + 'metadataReturnType' => '\Google\Cloud\ServiceManagement\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'service_name', + 'fieldAccessors' => [ + 'getServiceName', + ], + ], + ], + ], + 'SubmitConfigSource' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\ServiceManagement\V1\SubmitConfigSourceResponse', + 'metadataReturnType' => '\Google\Cloud\ServiceManagement\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'service_name', + 'fieldAccessors' => [ + 'getServiceName', + ], + ], + ], + ], + 'UndeleteService' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\ServiceManagement\V1\UndeleteServiceResponse', + 'metadataReturnType' => '\Google\Cloud\ServiceManagement\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'service_name', + 'fieldAccessors' => [ + 'getServiceName', + ], + ], + ], + ], + 'CreateServiceConfig' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Api\Service', + 'headerParams' => [ + [ + 'keyName' => 'service_name', + 'fieldAccessors' => [ + 'getServiceName', + ], + ], + ], + ], + 'GenerateConfigReport' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\ServiceManagement\V1\GenerateConfigReportResponse', + ], + 'GetService' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\ServiceManagement\V1\ManagedService', + 'headerParams' => [ + [ + 'keyName' => 'service_name', + 'fieldAccessors' => [ + 'getServiceName', + ], + ], + ], + ], + 'GetServiceConfig' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Api\Service', + 'headerParams' => [ + [ + 'keyName' => 'service_name', + 'fieldAccessors' => [ + 'getServiceName', + ], + ], + [ + 'keyName' => 'config_id', + 'fieldAccessors' => [ + 'getConfigId', + ], + ], + ], + ], + 'GetServiceRollout' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\ServiceManagement\V1\Rollout', + 'headerParams' => [ + [ + 'keyName' => 'service_name', + 'fieldAccessors' => [ + 'getServiceName', + ], + ], + [ + 'keyName' => 'rollout_id', + 'fieldAccessors' => [ + 'getRolloutId', + ], + ], + ], + ], + 'ListServiceConfigs' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getServiceConfigs', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\ServiceManagement\V1\ListServiceConfigsResponse', + 'headerParams' => [ + [ + 'keyName' => 'service_name', + 'fieldAccessors' => [ + 'getServiceName', + ], + ], + ], + ], + 'ListServiceRollouts' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getRollouts', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\ServiceManagement\V1\ListServiceRolloutsResponse', + 'headerParams' => [ + [ + 'keyName' => 'service_name', + 'fieldAccessors' => [ + 'getServiceName', + ], + ], + ], + ], + 'ListServices' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getServices', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\ServiceManagement\V1\ListServicesResponse', + ], + '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', + ], + ], + ], +]; diff --git a/owl-bot-staging/ServiceManagement/v1/src/V1/resources/service_manager_rest_client_config.php b/owl-bot-staging/ServiceManagement/v1/src/V1/resources/service_manager_rest_client_config.php new file mode 100644 index 000000000000..2265223866be --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/src/V1/resources/service_manager_rest_client_config.php @@ -0,0 +1,240 @@ + [ + 'google.api.servicemanagement.v1.ServiceManager' => [ + 'CreateService' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/services', + 'body' => 'service', + ], + 'CreateServiceConfig' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/services/{service_name}/configs', + 'body' => 'service_config', + 'placeholders' => [ + 'service_name' => [ + 'getters' => [ + 'getServiceName', + ], + ], + ], + ], + 'CreateServiceRollout' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/services/{service_name}/rollouts', + 'body' => 'rollout', + 'placeholders' => [ + 'service_name' => [ + 'getters' => [ + 'getServiceName', + ], + ], + ], + ], + 'DeleteService' => [ + 'method' => 'delete', + 'uriTemplate' => '/v1/services/{service_name}', + 'placeholders' => [ + 'service_name' => [ + 'getters' => [ + 'getServiceName', + ], + ], + ], + ], + 'GenerateConfigReport' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/services:generateConfigReport', + 'body' => '*', + ], + 'GetService' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/services/{service_name}', + 'placeholders' => [ + 'service_name' => [ + 'getters' => [ + 'getServiceName', + ], + ], + ], + ], + 'GetServiceConfig' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/services/{service_name}/configs/{config_id}', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v1/services/{service_name}/config', + ], + ], + 'placeholders' => [ + 'config_id' => [ + 'getters' => [ + 'getConfigId', + ], + ], + 'service_name' => [ + 'getters' => [ + 'getServiceName', + ], + ], + ], + ], + 'GetServiceRollout' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/services/{service_name}/rollouts/{rollout_id}', + 'placeholders' => [ + 'rollout_id' => [ + 'getters' => [ + 'getRolloutId', + ], + ], + 'service_name' => [ + 'getters' => [ + 'getServiceName', + ], + ], + ], + ], + 'ListServiceConfigs' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/services/{service_name}/configs', + 'placeholders' => [ + 'service_name' => [ + 'getters' => [ + 'getServiceName', + ], + ], + ], + ], + 'ListServiceRollouts' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/services/{service_name}/rollouts', + 'placeholders' => [ + 'service_name' => [ + 'getters' => [ + 'getServiceName', + ], + ], + ], + 'queryParams' => [ + 'filter', + ], + ], + 'ListServices' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/services', + ], + 'SubmitConfigSource' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/services/{service_name}/configs:submit', + 'body' => '*', + 'placeholders' => [ + 'service_name' => [ + 'getters' => [ + 'getServiceName', + ], + ], + ], + ], + 'UndeleteService' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/services/{service_name}:undelete', + 'placeholders' => [ + 'service_name' => [ + 'getters' => [ + 'getServiceName', + ], + ], + ], + ], + ], + 'google.iam.v1.IAMPolicy' => [ + 'GetIamPolicy' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{resource=services/*}:getIamPolicy', + 'body' => '*', + 'additionalBindings' => [ + [ + 'method' => 'post', + 'uriTemplate' => '/v1/{resource=services/*/consumers/*}:getIamPolicy', + 'body' => '*', + ], + ], + 'placeholders' => [ + 'resource' => [ + 'getters' => [ + 'getResource', + ], + ], + ], + ], + 'SetIamPolicy' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{resource=services/*}:setIamPolicy', + 'body' => '*', + 'additionalBindings' => [ + [ + 'method' => 'post', + 'uriTemplate' => '/v1/{resource=services/*/consumers/*}:setIamPolicy', + 'body' => '*', + ], + ], + 'placeholders' => [ + 'resource' => [ + 'getters' => [ + 'getResource', + ], + ], + ], + ], + 'TestIamPermissions' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{resource=services/*}:testIamPermissions', + 'body' => '*', + 'additionalBindings' => [ + [ + 'method' => 'post', + 'uriTemplate' => '/v1/{resource=services/*/consumers/*}:testIamPermissions', + 'body' => '*', + ], + ], + 'placeholders' => [ + 'resource' => [ + 'getters' => [ + 'getResource', + ], + ], + ], + ], + ], + 'google.longrunning.Operations' => [ + 'ListOperations' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/operations', + ], + ], + ], + 'numericEnums' => true, +]; diff --git a/owl-bot-staging/ServiceManagement/v1/tests/Unit/V1/Client/ServiceManagerClientTest.php b/owl-bot-staging/ServiceManagement/v1/tests/Unit/V1/Client/ServiceManagerClientTest.php new file mode 100644 index 000000000000..87e7797273e9 --- /dev/null +++ b/owl-bot-staging/ServiceManagement/v1/tests/Unit/V1/Client/ServiceManagerClientTest.php @@ -0,0 +1,1566 @@ +getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); + } + + /** @return ServiceManagerClient */ + private function createClient(array $options = []) + { + $options += [ + 'credentials' => $this->createCredentials(), + ]; + return new ServiceManagerClient($options); + } + + /** @test */ + public function createServiceTest() + { + $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/createServiceTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $serviceName = 'serviceName359880149'; + $producerProjectId = 'producerProjectId1450187470'; + $expectedResponse = new ManagedService(); + $expectedResponse->setServiceName($serviceName); + $expectedResponse->setProducerProjectId($producerProjectId); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/createServiceTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $service = new ManagedService(); + $request = (new CreateServiceRequest()) + ->setService($service); + $response = $gapicClient->createService($request); + $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.servicemanagement.v1.ServiceManager/CreateService', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getService(); + $this->assertProtobufEquals($service, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createServiceTest'); + $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 createServiceExceptionTest() + { + $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/createServiceTest'); + $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 + $service = new ManagedService(); + $request = (new CreateServiceRequest()) + ->setService($service); + $response = $gapicClient->createService($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createServiceTest'); + 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 createServiceConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $title = 'title110371416'; + $producerProjectId = 'producerProjectId1450187470'; + $id = 'id3355'; + $expectedResponse = new Service(); + $expectedResponse->setName($name); + $expectedResponse->setTitle($title); + $expectedResponse->setProducerProjectId($producerProjectId); + $expectedResponse->setId($id); + $transport->addResponse($expectedResponse); + // Mock request + $serviceName = 'serviceName359880149'; + $serviceConfig = new Service(); + $request = (new CreateServiceConfigRequest()) + ->setServiceName($serviceName) + ->setServiceConfig($serviceConfig); + $response = $gapicClient->createServiceConfig($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.api.servicemanagement.v1.ServiceManager/CreateServiceConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getServiceName(); + $this->assertProtobufEquals($serviceName, $actualValue); + $actualValue = $actualRequestObject->getServiceConfig(); + $this->assertProtobufEquals($serviceConfig, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createServiceConfigExceptionTest() + { + $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 + $serviceName = 'serviceName359880149'; + $serviceConfig = new Service(); + $request = (new CreateServiceConfigRequest()) + ->setServiceName($serviceName) + ->setServiceConfig($serviceConfig); + try { + $gapicClient->createServiceConfig($request); + // 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 createServiceRolloutTest() + { + $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/createServiceRolloutTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $rolloutId = 'rolloutId-91142551'; + $createdBy = 'createdBy1369680142'; + $serviceName2 = 'serviceName2-2047524792'; + $expectedResponse = new Rollout(); + $expectedResponse->setRolloutId($rolloutId); + $expectedResponse->setCreatedBy($createdBy); + $expectedResponse->setServiceName($serviceName2); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/createServiceRolloutTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $serviceName = 'serviceName359880149'; + $rollout = new Rollout(); + $request = (new CreateServiceRolloutRequest()) + ->setServiceName($serviceName) + ->setRollout($rollout); + $response = $gapicClient->createServiceRollout($request); + $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.servicemanagement.v1.ServiceManager/CreateServiceRollout', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getServiceName(); + $this->assertProtobufEquals($serviceName, $actualValue); + $actualValue = $actualApiRequestObject->getRollout(); + $this->assertProtobufEquals($rollout, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createServiceRolloutTest'); + $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 createServiceRolloutExceptionTest() + { + $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/createServiceRolloutTest'); + $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 + $serviceName = 'serviceName359880149'; + $rollout = new Rollout(); + $request = (new CreateServiceRolloutRequest()) + ->setServiceName($serviceName) + ->setRollout($rollout); + $response = $gapicClient->createServiceRollout($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createServiceRolloutTest'); + 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 deleteServiceTest() + { + $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/deleteServiceTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $expectedResponse = new GPBEmpty(); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/deleteServiceTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $serviceName = 'serviceName359880149'; + $request = (new DeleteServiceRequest()) + ->setServiceName($serviceName); + $response = $gapicClient->deleteService($request); + $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.servicemanagement.v1.ServiceManager/DeleteService', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getServiceName(); + $this->assertProtobufEquals($serviceName, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/deleteServiceTest'); + $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 deleteServiceExceptionTest() + { + $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/deleteServiceTest'); + $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 + $serviceName = 'serviceName359880149'; + $request = (new DeleteServiceRequest()) + ->setServiceName($serviceName); + $response = $gapicClient->deleteService($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/deleteServiceTest'); + 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 generateConfigReportTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $serviceName = 'serviceName359880149'; + $id = 'id3355'; + $expectedResponse = new GenerateConfigReportResponse(); + $expectedResponse->setServiceName($serviceName); + $expectedResponse->setId($id); + $transport->addResponse($expectedResponse); + // Mock request + $newConfig = new Any(); + $request = (new GenerateConfigReportRequest()) + ->setNewConfig($newConfig); + $response = $gapicClient->generateConfigReport($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.api.servicemanagement.v1.ServiceManager/GenerateConfigReport', $actualFuncCall); + $actualValue = $actualRequestObject->getNewConfig(); + $this->assertProtobufEquals($newConfig, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function generateConfigReportExceptionTest() + { + $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 + $newConfig = new Any(); + $request = (new GenerateConfigReportRequest()) + ->setNewConfig($newConfig); + try { + $gapicClient->generateConfigReport($request); + // 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 getServiceTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $serviceName2 = 'serviceName2-2047524792'; + $producerProjectId = 'producerProjectId1450187470'; + $expectedResponse = new ManagedService(); + $expectedResponse->setServiceName($serviceName2); + $expectedResponse->setProducerProjectId($producerProjectId); + $transport->addResponse($expectedResponse); + // Mock request + $serviceName = 'serviceName359880149'; + $request = (new GetServiceRequest()) + ->setServiceName($serviceName); + $response = $gapicClient->getService($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.api.servicemanagement.v1.ServiceManager/GetService', $actualFuncCall); + $actualValue = $actualRequestObject->getServiceName(); + $this->assertProtobufEquals($serviceName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getServiceExceptionTest() + { + $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 + $serviceName = 'serviceName359880149'; + $request = (new GetServiceRequest()) + ->setServiceName($serviceName); + try { + $gapicClient->getService($request); + // 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 getServiceConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $title = 'title110371416'; + $producerProjectId = 'producerProjectId1450187470'; + $id = 'id3355'; + $expectedResponse = new Service(); + $expectedResponse->setName($name); + $expectedResponse->setTitle($title); + $expectedResponse->setProducerProjectId($producerProjectId); + $expectedResponse->setId($id); + $transport->addResponse($expectedResponse); + // Mock request + $serviceName = 'serviceName359880149'; + $configId = 'configId-804450504'; + $request = (new GetServiceConfigRequest()) + ->setServiceName($serviceName) + ->setConfigId($configId); + $response = $gapicClient->getServiceConfig($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.api.servicemanagement.v1.ServiceManager/GetServiceConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getServiceName(); + $this->assertProtobufEquals($serviceName, $actualValue); + $actualValue = $actualRequestObject->getConfigId(); + $this->assertProtobufEquals($configId, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getServiceConfigExceptionTest() + { + $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 + $serviceName = 'serviceName359880149'; + $configId = 'configId-804450504'; + $request = (new GetServiceConfigRequest()) + ->setServiceName($serviceName) + ->setConfigId($configId); + try { + $gapicClient->getServiceConfig($request); + // 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 getServiceRolloutTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $rolloutId2 = 'rolloutId2-1688642596'; + $createdBy = 'createdBy1369680142'; + $serviceName2 = 'serviceName2-2047524792'; + $expectedResponse = new Rollout(); + $expectedResponse->setRolloutId($rolloutId2); + $expectedResponse->setCreatedBy($createdBy); + $expectedResponse->setServiceName($serviceName2); + $transport->addResponse($expectedResponse); + // Mock request + $serviceName = 'serviceName359880149'; + $rolloutId = 'rolloutId-91142551'; + $request = (new GetServiceRolloutRequest()) + ->setServiceName($serviceName) + ->setRolloutId($rolloutId); + $response = $gapicClient->getServiceRollout($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.api.servicemanagement.v1.ServiceManager/GetServiceRollout', $actualFuncCall); + $actualValue = $actualRequestObject->getServiceName(); + $this->assertProtobufEquals($serviceName, $actualValue); + $actualValue = $actualRequestObject->getRolloutId(); + $this->assertProtobufEquals($rolloutId, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getServiceRolloutExceptionTest() + { + $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 + $serviceName = 'serviceName359880149'; + $rolloutId = 'rolloutId-91142551'; + $request = (new GetServiceRolloutRequest()) + ->setServiceName($serviceName) + ->setRolloutId($rolloutId); + try { + $gapicClient->getServiceRollout($request); + // 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 listServiceConfigsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $serviceConfigsElement = new Service(); + $serviceConfigs = [ + $serviceConfigsElement, + ]; + $expectedResponse = new ListServiceConfigsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setServiceConfigs($serviceConfigs); + $transport->addResponse($expectedResponse); + // Mock request + $serviceName = 'serviceName359880149'; + $request = (new ListServiceConfigsRequest()) + ->setServiceName($serviceName); + $response = $gapicClient->listServiceConfigs($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getServiceConfigs()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.api.servicemanagement.v1.ServiceManager/ListServiceConfigs', $actualFuncCall); + $actualValue = $actualRequestObject->getServiceName(); + $this->assertProtobufEquals($serviceName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listServiceConfigsExceptionTest() + { + $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 + $serviceName = 'serviceName359880149'; + $request = (new ListServiceConfigsRequest()) + ->setServiceName($serviceName); + try { + $gapicClient->listServiceConfigs($request); + // 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 listServiceRolloutsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $rolloutsElement = new Rollout(); + $rollouts = [ + $rolloutsElement, + ]; + $expectedResponse = new ListServiceRolloutsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setRollouts($rollouts); + $transport->addResponse($expectedResponse); + // Mock request + $serviceName = 'serviceName359880149'; + $filter = 'filter-1274492040'; + $request = (new ListServiceRolloutsRequest()) + ->setServiceName($serviceName) + ->setFilter($filter); + $response = $gapicClient->listServiceRollouts($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getRollouts()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.api.servicemanagement.v1.ServiceManager/ListServiceRollouts', $actualFuncCall); + $actualValue = $actualRequestObject->getServiceName(); + $this->assertProtobufEquals($serviceName, $actualValue); + $actualValue = $actualRequestObject->getFilter(); + $this->assertProtobufEquals($filter, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listServiceRolloutsExceptionTest() + { + $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 + $serviceName = 'serviceName359880149'; + $filter = 'filter-1274492040'; + $request = (new ListServiceRolloutsRequest()) + ->setServiceName($serviceName) + ->setFilter($filter); + try { + $gapicClient->listServiceRollouts($request); + // 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 listServicesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $servicesElement = new ManagedService(); + $services = [ + $servicesElement, + ]; + $expectedResponse = new ListServicesResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setServices($services); + $transport->addResponse($expectedResponse); + $request = new ListServicesRequest(); + $response = $gapicClient->listServices($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getServices()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.api.servicemanagement.v1.ServiceManager/ListServices', $actualFuncCall); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listServicesExceptionTest() + { + $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); + $request = new ListServicesRequest(); + try { + $gapicClient->listServices($request); + // 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 submitConfigSourceTest() + { + $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/submitConfigSourceTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $expectedResponse = new SubmitConfigSourceResponse(); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/submitConfigSourceTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $serviceName = 'serviceName359880149'; + $configSource = new ConfigSource(); + $request = (new SubmitConfigSourceRequest()) + ->setServiceName($serviceName) + ->setConfigSource($configSource); + $response = $gapicClient->submitConfigSource($request); + $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.servicemanagement.v1.ServiceManager/SubmitConfigSource', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getServiceName(); + $this->assertProtobufEquals($serviceName, $actualValue); + $actualValue = $actualApiRequestObject->getConfigSource(); + $this->assertProtobufEquals($configSource, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/submitConfigSourceTest'); + $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 submitConfigSourceExceptionTest() + { + $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/submitConfigSourceTest'); + $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 + $serviceName = 'serviceName359880149'; + $configSource = new ConfigSource(); + $request = (new SubmitConfigSourceRequest()) + ->setServiceName($serviceName) + ->setConfigSource($configSource); + $response = $gapicClient->submitConfigSource($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/submitConfigSourceTest'); + 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 undeleteServiceTest() + { + $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/undeleteServiceTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $expectedResponse = new UndeleteServiceResponse(); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/undeleteServiceTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $serviceName = 'serviceName359880149'; + $request = (new UndeleteServiceRequest()) + ->setServiceName($serviceName); + $response = $gapicClient->undeleteService($request); + $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.servicemanagement.v1.ServiceManager/UndeleteService', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getServiceName(); + $this->assertProtobufEquals($serviceName, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/undeleteServiceTest'); + $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 undeleteServiceExceptionTest() + { + $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/undeleteServiceTest'); + $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 + $serviceName = 'serviceName359880149'; + $request = (new UndeleteServiceRequest()) + ->setServiceName($serviceName); + $response = $gapicClient->undeleteService($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/undeleteServiceTest'); + 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'; + $request = (new GetIamPolicyRequest()) + ->setResource($resource); + $response = $gapicClient->getIamPolicy($request); + $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'; + $request = (new GetIamPolicyRequest()) + ->setResource($resource); + try { + $gapicClient->getIamPolicy($request); + // 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(); + $request = (new SetIamPolicyRequest()) + ->setResource($resource) + ->setPolicy($policy); + $response = $gapicClient->setIamPolicy($request); + $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(); + $request = (new SetIamPolicyRequest()) + ->setResource($resource) + ->setPolicy($policy); + try { + $gapicClient->setIamPolicy($request); + // 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 = []; + $request = (new TestIamPermissionsRequest()) + ->setResource($resource) + ->setPermissions($permissions); + $response = $gapicClient->testIamPermissions($request); + $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 = []; + $request = (new TestIamPermissionsRequest()) + ->setResource($resource) + ->setPermissions($permissions); + try { + $gapicClient->testIamPermissions($request); + // 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 createServiceAsyncTest() + { + $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/createServiceTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $serviceName = 'serviceName359880149'; + $producerProjectId = 'producerProjectId1450187470'; + $expectedResponse = new ManagedService(); + $expectedResponse->setServiceName($serviceName); + $expectedResponse->setProducerProjectId($producerProjectId); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/createServiceTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $service = new ManagedService(); + $request = (new CreateServiceRequest()) + ->setService($service); + $response = $gapicClient->createServiceAsync($request)->wait(); + $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.servicemanagement.v1.ServiceManager/CreateService', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getService(); + $this->assertProtobufEquals($service, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createServiceTest'); + $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()); + } +} diff --git a/owl-bot-staging/Speech/v2/proto/src/GPBMetadata/Google/Cloud/Speech/V2/CloudSpeech.php b/owl-bot-staging/Speech/v2/proto/src/GPBMetadata/Google/Cloud/Speech/V2/CloudSpeech.php new file mode 100644 index 000000000000..4d6500ad185b --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/GPBMetadata/Google/Cloud/Speech/V2/CloudSpeech.php @@ -0,0 +1,34 @@ +internalAddGeneratedFile( + "\x0A\xF1\xA5\x01\x0A)google/cloud/speech/v2/cloud_speech.proto\x12\x16google.cloud.speech.v2\x1A\x17google/api/client.proto\x1A\x1Fgoogle/api/field_behavior.proto\x1A\x1Bgoogle/api/field_info.proto\x1A\x19google/api/resource.proto\x1A#google/longrunning/operations.proto\x1A\x1Egoogle/protobuf/duration.proto\x1A google/protobuf/field_mask.proto\x1A\x1Fgoogle/protobuf/timestamp.proto\x1A\x17google/rpc/status.proto\"\xBE\x01\x0A\x17CreateRecognizerRequest\x12;\x0A\x0Arecognizer\x18\x01 \x01(\x0B2\".google.cloud.speech.v2.RecognizerB\x03\xE0A\x02\x12\x15\x0A\x0Dvalidate_only\x18\x02 \x01(\x08\x12\x15\x0A\x0Drecognizer_id\x18\x03 \x01(\x09\x128\x0A\x06parent\x18\x04 \x01(\x09B(\xE0A\x02\xFAA\"\x12 speech.googleapis.com/Recognizer\"\xE7\x0C\x0A\x11OperationMetadata\x12/\x0A\x0Bcreate_time\x18\x01 \x01(\x0B2\x1A.google.protobuf.Timestamp\x12/\x0A\x0Bupdate_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.Timestamp\x12\x10\x0A\x08resource\x18\x03 \x01(\x09\x12\x0E\x0A\x06method\x18\x04 \x01(\x09\x12<\x0A\x0Ckms_key_name\x18\x06 \x01(\x09B&\xFAA#\x0A!cloudkms.googleapis.com/CryptoKey\x12K\x0A\x14kms_key_version_name\x18\x07 \x01(\x09B-\xFAA*\x0A(cloudkms.googleapis.com/CryptoKeyVersion\x12P\x0A\x17batch_recognize_request\x18\x08 \x01(\x0B2-.google.cloud.speech.v2.BatchRecognizeRequestH\x00\x12T\x0A\x19create_recognizer_request\x18\x09 \x01(\x0B2/.google.cloud.speech.v2.CreateRecognizerRequestH\x00\x12T\x0A\x19update_recognizer_request\x18\x0A \x01(\x0B2/.google.cloud.speech.v2.UpdateRecognizerRequestH\x00\x12T\x0A\x19delete_recognizer_request\x18\x0B \x01(\x0B2/.google.cloud.speech.v2.DeleteRecognizerRequestH\x00\x12X\x0A\x1Bundelete_recognizer_request\x18\x0C \x01(\x0B21.google.cloud.speech.v2.UndeleteRecognizerRequestH\x00\x12W\x0A\x1Bcreate_custom_class_request\x18\x0D \x01(\x0B20.google.cloud.speech.v2.CreateCustomClassRequestH\x00\x12W\x0A\x1Bupdate_custom_class_request\x18\x0E \x01(\x0B20.google.cloud.speech.v2.UpdateCustomClassRequestH\x00\x12W\x0A\x1Bdelete_custom_class_request\x18\x0F \x01(\x0B20.google.cloud.speech.v2.DeleteCustomClassRequestH\x00\x12[\x0A\x1Dundelete_custom_class_request\x18\x10 \x01(\x0B22.google.cloud.speech.v2.UndeleteCustomClassRequestH\x00\x12S\x0A\x19create_phrase_set_request\x18\x11 \x01(\x0B2..google.cloud.speech.v2.CreatePhraseSetRequestH\x00\x12S\x0A\x19update_phrase_set_request\x18\x12 \x01(\x0B2..google.cloud.speech.v2.UpdatePhraseSetRequestH\x00\x12S\x0A\x19delete_phrase_set_request\x18\x13 \x01(\x0B2..google.cloud.speech.v2.DeletePhraseSetRequestH\x00\x12W\x0A\x1Bundelete_phrase_set_request\x18\x14 \x01(\x0B20.google.cloud.speech.v2.UndeletePhraseSetRequestH\x00\x12P\x0A\x15update_config_request\x18\x15 \x01(\x0B2+.google.cloud.speech.v2.UpdateConfigRequestB\x02\x18\x01H\x00\x12\x18\x0A\x10progress_percent\x18\x16 \x01(\x05\x12R\x0A\x18batch_recognize_metadata\x18\x17 \x01(\x0B2..google.cloud.speech.v2.BatchRecognizeMetadataH\x01B\x09\x0A\x07requestB\x0A\x0A\x08metadata\"\x90\x01\x0A\x16ListRecognizersRequest\x129\x0A\x06parent\x18\x01 \x01(\x09B)\xE0A\x02\xFAA#\x0A!locations.googleapis.com/Location\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\x12\x14\x0A\x0Cshow_deleted\x18\x04 \x01(\x08\"k\x0A\x17ListRecognizersResponse\x127\x0A\x0Brecognizers\x18\x01 \x03(\x0B2\".google.cloud.speech.v2.Recognizer\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\"N\x0A\x14GetRecognizerRequest\x126\x0A\x04name\x18\x01 \x01(\x09B(\xE0A\x02\xFAA\"\x0A speech.googleapis.com/Recognizer\"\x9E\x01\x0A\x17UpdateRecognizerRequest\x12;\x0A\x0Arecognizer\x18\x01 \x01(\x0B2\".google.cloud.speech.v2.RecognizerB\x03\xE0A\x02\x12/\x0A\x0Bupdate_mask\x18\x02 \x01(\x0B2\x1A.google.protobuf.FieldMask\x12\x15\x0A\x0Dvalidate_only\x18\x04 \x01(\x08\"\x8D\x01\x0A\x17DeleteRecognizerRequest\x126\x0A\x04name\x18\x01 \x01(\x09B(\xE0A\x02\xFAA\"\x0A speech.googleapis.com/Recognizer\x12\x15\x0A\x0Dvalidate_only\x18\x02 \x01(\x08\x12\x15\x0A\x0Dallow_missing\x18\x04 \x01(\x08\x12\x0C\x0A\x04etag\x18\x03 \x01(\x09\"x\x0A\x19UndeleteRecognizerRequest\x126\x0A\x04name\x18\x01 \x01(\x09B(\xE0A\x02\xFAA\"\x0A speech.googleapis.com/Recognizer\x12\x15\x0A\x0Dvalidate_only\x18\x03 \x01(\x08\x12\x0C\x0A\x04etag\x18\x04 \x01(\x09\"\xC5\x07\x0A\x0ARecognizer\x12\x14\x0A\x04name\x18\x01 \x01(\x09B\x06\xE0A\x03\xE0A\x08\x12\x10\x0A\x03uid\x18\x02 \x01(\x09B\x03\xE0A\x03\x12\x14\x0A\x0Cdisplay_name\x18\x03 \x01(\x09\x12\x14\x0A\x05model\x18\x04 \x01(\x09B\x05\x18\x01\xE0A\x01\x12\x1D\x0A\x0Elanguage_codes\x18\x11 \x03(\x09B\x05\x18\x01\xE0A\x01\x12M\x0A\x1Adefault_recognition_config\x18\x06 \x01(\x0B2).google.cloud.speech.v2.RecognitionConfig\x12H\x0A\x0Bannotations\x18\x07 \x03(\x0B23.google.cloud.speech.v2.Recognizer.AnnotationsEntry\x12<\x0A\x05state\x18\x08 \x01(\x0E2(.google.cloud.speech.v2.Recognizer.StateB\x03\xE0A\x03\x124\x0A\x0Bcreate_time\x18\x09 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x0A \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bdelete_time\x18\x0B \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bexpire_time\x18\x0E \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12\x11\x0A\x04etag\x18\x0C \x01(\x09B\x03\xE0A\x03\x12\x18\x0A\x0Breconciling\x18\x0D \x01(\x08B\x03\xE0A\x03\x12?\x0A\x0Ckms_key_name\x18\x0F \x01(\x09B)\xE0A\x03\xFAA#\x0A!cloudkms.googleapis.com/CryptoKey\x12N\x0A\x14kms_key_version_name\x18\x10 \x01(\x09B0\xE0A\x03\xFAA*\x0A(cloudkms.googleapis.com/CryptoKeyVersion\x1A2\x0A\x10AnnotationsEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12\x0D\x0A\x05value\x18\x02 \x01(\x09:\x028\x01\"7\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x0A\x0A\x06ACTIVE\x10\x02\x12\x0B\x0A\x07DELETED\x10\x04:j\xEAAg\x0A speech.googleapis.com/Recognizer\x12@projects/{project}/locations/{location}/recognizers/{recognizer}R\x01\x01\"\x1A\x0A\x18AutoDetectDecodingConfig\"\xF0\x02\x0A\x16ExplicitDecodingConfig\x12S\x0A\x08encoding\x18\x01 \x01(\x0E2<.google.cloud.speech.v2.ExplicitDecodingConfig.AudioEncodingB\x03\xE0A\x02\x12\x1E\x0A\x11sample_rate_hertz\x18\x02 \x01(\x05B\x03\xE0A\x01\x12 \x0A\x13audio_channel_count\x18\x03 \x01(\x05B\x03\xE0A\x01\"\xBE\x01\x0A\x0DAudioEncoding\x12\x1E\x0A\x1AAUDIO_ENCODING_UNSPECIFIED\x10\x00\x12\x0C\x0A\x08LINEAR16\x10\x01\x12\x09\x0A\x05MULAW\x10\x02\x12\x08\x0A\x04ALAW\x10\x03\x12\x07\x0A\x03AMR\x10\x04\x12\x0A\x0A\x06AMR_WB\x10\x05\x12\x08\x0A\x04FLAC\x10\x06\x12\x07\x0A\x03MP3\x10\x07\x12\x0C\x0A\x08OGG_OPUS\x10\x08\x12\x0D\x0A\x09WEBM_OPUS\x10\x09\x12\x0B\x0A\x07MP4_AAC\x10\x0A\x12\x0B\x0A\x07M4A_AAC\x10\x0B\x12\x0B\x0A\x07MOV_AAC\x10\x0C\"Z\x0A\x18SpeakerDiarizationConfig\x12\x1E\x0A\x11min_speaker_count\x18\x02 \x01(\x05B\x03\xE0A\x01\x12\x1E\x0A\x11max_speaker_count\x18\x03 \x01(\x05B\x03\xE0A\x01\"0\x0A\x12CustomPromptConfig\x12\x1A\x0A\x0Dcustom_prompt\x18\x01 \x01(\x09B\x03\xE0A\x01\"\xC7\x04\x0A\x13RecognitionFeatures\x12\x18\x0A\x10profanity_filter\x18\x01 \x01(\x08\x12 \x0A\x18enable_word_time_offsets\x18\x02 \x01(\x08\x12\x1E\x0A\x16enable_word_confidence\x18\x03 \x01(\x08\x12\$\x0A\x1Cenable_automatic_punctuation\x18\x04 \x01(\x08\x12!\x0A\x19enable_spoken_punctuation\x18\x0E \x01(\x08\x12\x1C\x0A\x14enable_spoken_emojis\x18\x0F \x01(\x08\x12X\x0A\x12multi_channel_mode\x18\x11 \x01(\x0E2<.google.cloud.speech.v2.RecognitionFeatures.MultiChannelMode\x12L\x0A\x12diarization_config\x18\x09 \x01(\x0B20.google.cloud.speech.v2.SpeakerDiarizationConfig\x12\x18\x0A\x10max_alternatives\x18\x10 \x01(\x05\x12M\x0A\x14custom_prompt_config\x18\x12 \x01(\x0B2*.google.cloud.speech.v2.CustomPromptConfigB\x03\xE0A\x01\"\\\x0A\x10MultiChannelMode\x12\"\x0A\x1EMULTI_CHANNEL_MODE_UNSPECIFIED\x10\x00\x12\$\x0A SEPARATE_RECOGNITION_PER_CHANNEL\x10\x01\"\xA3\x01\x0A\x17TranscriptNormalization\x12F\x0A\x07entries\x18\x01 \x03(\x0B25.google.cloud.speech.v2.TranscriptNormalization.Entry\x1A@\x0A\x05Entry\x12\x0E\x0A\x06search\x18\x01 \x01(\x09\x12\x0F\x0A\x07replace\x18\x02 \x01(\x09\x12\x16\x0A\x0Ecase_sensitive\x18\x03 \x01(\x08\"1\x0A\x11TranslationConfig\x12\x1C\x0A\x0Ftarget_language\x18\x01 \x01(\x09B\x03\xE0A\x02\"\xBF\x02\x0A\x10SpeechAdaptation\x12Q\x0A\x0Bphrase_sets\x18\x01 \x03(\x0B2<.google.cloud.speech.v2.SpeechAdaptation.AdaptationPhraseSet\x12;\x0A\x0Ecustom_classes\x18\x02 \x03(\x0B2#.google.cloud.speech.v2.CustomClass\x1A\x9A\x01\x0A\x13AdaptationPhraseSet\x12:\x0A\x0Aphrase_set\x18\x01 \x01(\x09B\$\xFAA!\x0A\x1Fspeech.googleapis.com/PhraseSetH\x00\x12>\x0A\x11inline_phrase_set\x18\x02 \x01(\x0B2!.google.cloud.speech.v2.PhraseSetH\x00B\x07\x0A\x05value\">\x0A\x0EDenoiserConfig\x12\x15\x0A\x0Ddenoise_audio\x18\x01 \x01(\x08\x12\x15\x0A\x0Dsnr_threshold\x18\x02 \x01(\x02\"\xE4\x04\x0A\x11RecognitionConfig\x12P\x0A\x14auto_decoding_config\x18\x07 \x01(\x0B20.google.cloud.speech.v2.AutoDetectDecodingConfigH\x00\x12R\x0A\x18explicit_decoding_config\x18\x08 \x01(\x0B2..google.cloud.speech.v2.ExplicitDecodingConfigH\x00\x12\x12\x0A\x05model\x18\x09 \x01(\x09B\x03\xE0A\x01\x12\x1B\x0A\x0Elanguage_codes\x18\x0A \x03(\x09B\x03\xE0A\x01\x12=\x0A\x08features\x18\x02 \x01(\x0B2+.google.cloud.speech.v2.RecognitionFeatures\x12<\x0A\x0Aadaptation\x18\x06 \x01(\x0B2(.google.cloud.speech.v2.SpeechAdaptation\x12V\x0A\x18transcript_normalization\x18\x0B \x01(\x0B2/.google.cloud.speech.v2.TranscriptNormalizationB\x03\xE0A\x01\x12J\x0A\x12translation_config\x18\x0F \x01(\x0B2).google.cloud.speech.v2.TranslationConfigB\x03\xE0A\x01\x12D\x0A\x0Fdenoiser_config\x18\x10 \x01(\x0B2&.google.cloud.speech.v2.DenoiserConfigB\x03\xE0A\x01B\x11\x0A\x0Fdecoding_config\"\xEE\x01\x0A\x10RecognizeRequest\x12<\x0A\x0Arecognizer\x18\x03 \x01(\x09B(\xE0A\x02\xFAA\"\x0A speech.googleapis.com/Recognizer\x129\x0A\x06config\x18\x01 \x01(\x0B2).google.cloud.speech.v2.RecognitionConfig\x12/\x0A\x0Bconfig_mask\x18\x08 \x01(\x0B2\x1A.google.protobuf.FieldMask\x12\x11\x0A\x07content\x18\x05 \x01(\x0CH\x00\x12\x0D\x0A\x03uri\x18\x06 \x01(\x09H\x00B\x0E\x0A\x0Caudio_source\"\x9D\x01\x0A\x1BRecognitionResponseMetadata\x12\x1C\x0A\x0Arequest_id\x18\x09 \x01(\x09B\x08\xE2\x8C\xCF\xD7\x08\x02\x08\x01\x128\x0A\x15total_billed_duration\x18\x06 \x01(\x0B2\x19.google.protobuf.Duration\x12\x1B\x0A\x06prompt\x18\x0A \x01(\x09B\x06\xE0A\x03\xE0A\x01H\x00\x88\x01\x01B\x09\x0A\x07_prompt\"w\x0A\x1CSpeechRecognitionAlternative\x12\x12\x0A\x0Atranscript\x18\x01 \x01(\x09\x12\x12\x0A\x0Aconfidence\x18\x02 \x01(\x02\x12/\x0A\x05words\x18\x03 \x03(\x0B2 .google.cloud.speech.v2.WordInfo\"\xA3\x01\x0A\x08WordInfo\x12/\x0A\x0Cstart_offset\x18\x01 \x01(\x0B2\x19.google.protobuf.Duration\x12-\x0A\x0Aend_offset\x18\x02 \x01(\x0B2\x19.google.protobuf.Duration\x12\x0C\x0A\x04word\x18\x03 \x01(\x09\x12\x12\x0A\x0Aconfidence\x18\x04 \x01(\x02\x12\x15\x0A\x0Dspeaker_label\x18\x06 \x01(\x09\"\xCC\x01\x0A\x17SpeechRecognitionResult\x12J\x0A\x0Calternatives\x18\x01 \x03(\x0B24.google.cloud.speech.v2.SpeechRecognitionAlternative\x12\x13\x0A\x0Bchannel_tag\x18\x02 \x01(\x05\x124\x0A\x11result_end_offset\x18\x04 \x01(\x0B2\x19.google.protobuf.Duration\x12\x1A\x0A\x0Dlanguage_code\x18\x05 \x01(\x09B\x03\xE0A\x03\"\x9C\x01\x0A\x11RecognizeResponse\x12@\x0A\x07results\x18\x03 \x03(\x0B2/.google.cloud.speech.v2.SpeechRecognitionResult\x12E\x0A\x08metadata\x18\x02 \x01(\x0B23.google.cloud.speech.v2.RecognitionResponseMetadata\"\xF9\x04\x0A\x1CStreamingRecognitionFeatures\x12\$\x0A\x1Cenable_voice_activity_events\x18\x01 \x01(\x08\x12\x17\x0A\x0Finterim_results\x18\x02 \x01(\x08\x12i\x0A\x16voice_activity_timeout\x18\x03 \x01(\x0B2I.google.cloud.speech.v2.StreamingRecognitionFeatures.VoiceActivityTimeout\x12q\x0A\x17endpointing_sensitivity\x18\x08 \x01(\x0E2K.google.cloud.speech.v2.StreamingRecognitionFeatures.EndpointingSensitivityB\x03\xE0A\x01\x1A\x86\x01\x0A\x14VoiceActivityTimeout\x127\x0A\x14speech_start_timeout\x18\x01 \x01(\x0B2\x19.google.protobuf.Duration\x125\x0A\x12speech_end_timeout\x18\x02 \x01(\x0B2\x19.google.protobuf.Duration\"\xB2\x01\x0A\x16EndpointingSensitivity\x12'\x0A#ENDPOINTING_SENSITIVITY_UNSPECIFIED\x10\x00\x12\$\x0A ENDPOINTING_SENSITIVITY_STANDARD\x10\x01\x12&\x0A\"ENDPOINTING_SENSITIVITY_SUPERSHORT\x10\x02\x12!\x0A\x1DENDPOINTING_SENSITIVITY_SHORT\x10\x03\"\xDF\x01\x0A\x1AStreamingRecognitionConfig\x12>\x0A\x06config\x18\x01 \x01(\x0B2).google.cloud.speech.v2.RecognitionConfigB\x03\xE0A\x02\x12/\x0A\x0Bconfig_mask\x18\x03 \x01(\x0B2\x1A.google.protobuf.FieldMask\x12P\x0A\x12streaming_features\x18\x02 \x01(\x0B24.google.cloud.speech.v2.StreamingRecognitionFeatures\"\xCF\x01\x0A\x19StreamingRecognizeRequest\x12<\x0A\x0Arecognizer\x18\x03 \x01(\x09B(\xE0A\x02\xFAA\"\x0A speech.googleapis.com/Recognizer\x12N\x0A\x10streaming_config\x18\x06 \x01(\x0B22.google.cloud.speech.v2.StreamingRecognitionConfigH\x00\x12\x0F\x0A\x05audio\x18\x05 \x01(\x0CH\x00B\x13\x0A\x11streaming_request\"\x88\x04\x0A\x15BatchRecognizeRequest\x12<\x0A\x0Arecognizer\x18\x01 \x01(\x09B(\xE0A\x02\xFAA\"\x0A speech.googleapis.com/Recognizer\x129\x0A\x06config\x18\x04 \x01(\x0B2).google.cloud.speech.v2.RecognitionConfig\x12/\x0A\x0Bconfig_mask\x18\x05 \x01(\x0B2\x1A.google.protobuf.FieldMask\x12A\x0A\x05files\x18\x03 \x03(\x0B22.google.cloud.speech.v2.BatchRecognizeFileMetadata\x12R\x0A\x19recognition_output_config\x18\x06 \x01(\x0B2/.google.cloud.speech.v2.RecognitionOutputConfig\x12]\x0A\x13processing_strategy\x18\x07 \x01(\x0E2@.google.cloud.speech.v2.BatchRecognizeRequest.ProcessingStrategy\"O\x0A\x12ProcessingStrategy\x12#\x0A\x1FPROCESSING_STRATEGY_UNSPECIFIED\x10\x00\x12\x14\x0A\x10DYNAMIC_BATCHING\x10\x01\"\x1E\x0A\x0FGcsOutputConfig\x12\x0B\x0A\x03uri\x18\x01 \x01(\x09\"\x14\x0A\x12InlineOutputConfig\"\x1E\x0A\x1CNativeOutputFileFormatConfig\"\x1B\x0A\x19VttOutputFileFormatConfig\"\x1B\x0A\x19SrtOutputFileFormatConfig\"\xDA\x01\x0A\x12OutputFormatConfig\x12D\x0A\x06native\x18\x01 \x01(\x0B24.google.cloud.speech.v2.NativeOutputFileFormatConfig\x12>\x0A\x03vtt\x18\x02 \x01(\x0B21.google.cloud.speech.v2.VttOutputFileFormatConfig\x12>\x0A\x03srt\x18\x03 \x01(\x0B21.google.cloud.speech.v2.SrtOutputFileFormatConfig\"\x86\x02\x0A\x17RecognitionOutputConfig\x12D\x0A\x11gcs_output_config\x18\x01 \x01(\x0B2'.google.cloud.speech.v2.GcsOutputConfigH\x00\x12L\x0A\x16inline_response_config\x18\x02 \x01(\x0B2*.google.cloud.speech.v2.InlineOutputConfigH\x00\x12M\x0A\x14output_format_config\x18\x03 \x01(\x0B2*.google.cloud.speech.v2.OutputFormatConfigB\x03\xE0A\x01B\x08\x0A\x06output\"\x82\x02\x0A\x16BatchRecognizeResponse\x12L\x0A\x07results\x18\x01 \x03(\x0B2;.google.cloud.speech.v2.BatchRecognizeResponse.ResultsEntry\x128\x0A\x15total_billed_duration\x18\x02 \x01(\x0B2\x19.google.protobuf.Duration\x1A`\x0A\x0CResultsEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12?\x0A\x05value\x18\x02 \x01(\x0B20.google.cloud.speech.v2.BatchRecognizeFileResult:\x028\x01\"\xA0\x01\x0A\x15BatchRecognizeResults\x12@\x0A\x07results\x18\x01 \x03(\x0B2/.google.cloud.speech.v2.SpeechRecognitionResult\x12E\x0A\x08metadata\x18\x02 \x01(\x0B23.google.cloud.speech.v2.RecognitionResponseMetadata\"Q\x0A\x12CloudStorageResult\x12\x0B\x0A\x03uri\x18\x01 \x01(\x09\x12\x16\x0A\x0Evtt_format_uri\x18\x02 \x01(\x09\x12\x16\x0A\x0Esrt_format_uri\x18\x03 \x01(\x09\"}\x0A\x0CInlineResult\x12A\x0A\x0Atranscript\x18\x01 \x01(\x0B2-.google.cloud.speech.v2.BatchRecognizeResults\x12\x14\x0A\x0Cvtt_captions\x18\x02 \x01(\x09\x12\x14\x0A\x0Csrt_captions\x18\x03 \x01(\x09\"\xF1\x02\x0A\x18BatchRecognizeFileResult\x12!\x0A\x05error\x18\x02 \x01(\x0B2\x12.google.rpc.Status\x12E\x0A\x08metadata\x18\x03 \x01(\x0B23.google.cloud.speech.v2.RecognitionResponseMetadata\x12J\x0A\x14cloud_storage_result\x18\x05 \x01(\x0B2*.google.cloud.speech.v2.CloudStorageResultH\x00\x12=\x0A\x0Dinline_result\x18\x06 \x01(\x0B2\$.google.cloud.speech.v2.InlineResultH\x00\x12\x0F\x0A\x03uri\x18\x01 \x01(\x09B\x02\x18\x01\x12E\x0A\x0Atranscript\x18\x04 \x01(\x0B2-.google.cloud.speech.v2.BatchRecognizeResultsB\x02\x18\x01B\x08\x0A\x06result\"o\x0A#BatchRecognizeTranscriptionMetadata\x12\x18\x0A\x10progress_percent\x18\x01 \x01(\x05\x12!\x0A\x05error\x18\x02 \x01(\x0B2\x12.google.rpc.Status\x12\x0B\x0A\x03uri\x18\x03 \x01(\x09\"\xFE\x01\x0A\x16BatchRecognizeMetadata\x12i\x0A\x16transcription_metadata\x18\x01 \x03(\x0B2I.google.cloud.speech.v2.BatchRecognizeMetadata.TranscriptionMetadataEntry\x1Ay\x0A\x1ATranscriptionMetadataEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12J\x0A\x05value\x18\x02 \x01(\x0B2;.google.cloud.speech.v2.BatchRecognizeTranscriptionMetadata:\x028\x01\"\xA7\x01\x0A\x1ABatchRecognizeFileMetadata\x12\x0D\x0A\x03uri\x18\x01 \x01(\x09H\x00\x129\x0A\x06config\x18\x04 \x01(\x0B2).google.cloud.speech.v2.RecognitionConfig\x12/\x0A\x0Bconfig_mask\x18\x05 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x0E\x0A\x0Caudio_source\"\xF4\x01\x0A\x1AStreamingRecognitionResult\x12J\x0A\x0Calternatives\x18\x01 \x03(\x0B24.google.cloud.speech.v2.SpeechRecognitionAlternative\x12\x10\x0A\x08is_final\x18\x02 \x01(\x08\x12\x11\x0A\x09stability\x18\x03 \x01(\x02\x124\x0A\x11result_end_offset\x18\x04 \x01(\x0B2\x19.google.protobuf.Duration\x12\x13\x0A\x0Bchannel_tag\x18\x05 \x01(\x05\x12\x1A\x0A\x0Dlanguage_code\x18\x06 \x01(\x09B\x03\xE0A\x03\"\xC7\x03\x0A\x1AStreamingRecognizeResponse\x12C\x0A\x07results\x18\x06 \x03(\x0B22.google.cloud.speech.v2.StreamingRecognitionResult\x12]\x0A\x11speech_event_type\x18\x03 \x01(\x0E2B.google.cloud.speech.v2.StreamingRecognizeResponse.SpeechEventType\x126\x0A\x13speech_event_offset\x18\x07 \x01(\x0B2\x19.google.protobuf.Duration\x12E\x0A\x08metadata\x18\x05 \x01(\x0B23.google.cloud.speech.v2.RecognitionResponseMetadata\"\x85\x01\x0A\x0FSpeechEventType\x12!\x0A\x1DSPEECH_EVENT_TYPE_UNSPECIFIED\x10\x00\x12\x1B\x0A\x17END_OF_SINGLE_UTTERANCE\x10\x01\x12\x19\x0A\x15SPEECH_ACTIVITY_BEGIN\x10\x02\x12\x17\x0A\x13SPEECH_ACTIVITY_END\x10\x03\"\xE8\x01\x0A\x06Config\x12\x14\x0A\x04name\x18\x01 \x01(\x09B\x06\xE0A\x03\xE0A\x08\x12?\x0A\x0Ckms_key_name\x18\x02 \x01(\x09B)\xE0A\x01\xFAA#\x0A!cloudkms.googleapis.com/CryptoKey\x124\x0A\x0Bupdate_time\x18\x03 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03:Q\xEAAN\x0A\x1Cspeech.googleapis.com/Config\x12.projects/{project}/locations/{location}/config\"F\x0A\x10GetConfigRequest\x122\x0A\x04name\x18\x01 \x01(\x09B\$\xE0A\x02\xFAA\x1E\x0A\x1Cspeech.googleapis.com/Config\"{\x0A\x13UpdateConfigRequest\x123\x0A\x06config\x18\x01 \x01(\x0B2\x1E.google.cloud.speech.v2.ConfigB\x03\xE0A\x02\x12/\x0A\x0Bupdate_mask\x18\x02 \x01(\x0B2\x1A.google.protobuf.FieldMask\"\xAD\x07\x0A\x0BCustomClass\x12\x14\x0A\x04name\x18\x01 \x01(\x09B\x06\xE0A\x03\xE0A\x08\x12\x10\x0A\x03uid\x18\x02 \x01(\x09B\x03\xE0A\x03\x12\x19\x0A\x0Cdisplay_name\x18\x04 \x01(\x09B\x03\xE0A\x01\x12<\x0A\x05items\x18\x05 \x03(\x0B2-.google.cloud.speech.v2.CustomClass.ClassItem\x12=\x0A\x05state\x18\x0F \x01(\x0E2).google.cloud.speech.v2.CustomClass.StateB\x03\xE0A\x03\x124\x0A\x0Bcreate_time\x18\x06 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x07 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bdelete_time\x18\x08 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bexpire_time\x18\x09 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12N\x0A\x0Bannotations\x18\x0A \x03(\x0B24.google.cloud.speech.v2.CustomClass.AnnotationsEntryB\x03\xE0A\x01\x12\x11\x0A\x04etag\x18\x0B \x01(\x09B\x03\xE0A\x03\x12\x18\x0A\x0Breconciling\x18\x0C \x01(\x08B\x03\xE0A\x03\x12?\x0A\x0Ckms_key_name\x18\x0D \x01(\x09B)\xE0A\x03\xFAA#\x0A!cloudkms.googleapis.com/CryptoKey\x12N\x0A\x14kms_key_version_name\x18\x0E \x01(\x09B0\xE0A\x03\xFAA*\x0A(cloudkms.googleapis.com/CryptoKeyVersion\x1A\x1A\x0A\x09ClassItem\x12\x0D\x0A\x05value\x18\x01 \x01(\x09\x1A2\x0A\x10AnnotationsEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12\x0D\x0A\x05value\x18\x02 \x01(\x09:\x028\x01\"7\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x0A\x0A\x06ACTIVE\x10\x02\x12\x0B\x0A\x07DELETED\x10\x04:o\xEAAl\x0A!speech.googleapis.com/CustomClass\x12Dprojects/{project}/locations/{location}/customClasses/{custom_class}R\x01\x01\"\xAE\x07\x0A\x09PhraseSet\x12\x14\x0A\x04name\x18\x01 \x01(\x09B\x06\xE0A\x03\xE0A\x08\x12\x10\x0A\x03uid\x18\x02 \x01(\x09B\x03\xE0A\x03\x129\x0A\x07phrases\x18\x03 \x03(\x0B2(.google.cloud.speech.v2.PhraseSet.Phrase\x12\x0D\x0A\x05boost\x18\x04 \x01(\x02\x12\x14\x0A\x0Cdisplay_name\x18\x05 \x01(\x09\x12;\x0A\x05state\x18\x0F \x01(\x0E2'.google.cloud.speech.v2.PhraseSet.StateB\x03\xE0A\x03\x124\x0A\x0Bcreate_time\x18\x06 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x07 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bdelete_time\x18\x08 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bexpire_time\x18\x09 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12G\x0A\x0Bannotations\x18\x0A \x03(\x0B22.google.cloud.speech.v2.PhraseSet.AnnotationsEntry\x12\x11\x0A\x04etag\x18\x0B \x01(\x09B\x03\xE0A\x03\x12\x18\x0A\x0Breconciling\x18\x0C \x01(\x08B\x03\xE0A\x03\x12?\x0A\x0Ckms_key_name\x18\x0D \x01(\x09B)\xE0A\x03\xFAA#\x0A!cloudkms.googleapis.com/CryptoKey\x12N\x0A\x14kms_key_version_name\x18\x0E \x01(\x09B0\xE0A\x03\xFAA*\x0A(cloudkms.googleapis.com/CryptoKeyVersion\x1A&\x0A\x06Phrase\x12\x0D\x0A\x05value\x18\x01 \x01(\x09\x12\x0D\x0A\x05boost\x18\x02 \x01(\x02\x1A2\x0A\x10AnnotationsEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12\x0D\x0A\x05value\x18\x02 \x01(\x09:\x028\x01\"7\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x0A\x0A\x06ACTIVE\x10\x02\x12\x0B\x0A\x07DELETED\x10\x04:h\xEAAe\x0A\x1Fspeech.googleapis.com/PhraseSet\x12?projects/{project}/locations/{location}/phraseSets/{phrase_set}R\x01\x01\"\xC5\x01\x0A\x18CreateCustomClassRequest\x12>\x0A\x0Ccustom_class\x18\x01 \x01(\x0B2#.google.cloud.speech.v2.CustomClassB\x03\xE0A\x02\x12\x15\x0A\x0Dvalidate_only\x18\x02 \x01(\x08\x12\x17\x0A\x0Fcustom_class_id\x18\x03 \x01(\x09\x129\x0A\x06parent\x18\x04 \x01(\x09B)\xE0A\x02\xFAA#\x12!speech.googleapis.com/CustomClass\"\x92\x01\x0A\x18ListCustomClassesRequest\x129\x0A\x06parent\x18\x01 \x01(\x09B)\xE0A\x02\xFAA#\x0A!locations.googleapis.com/Location\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\x12\x14\x0A\x0Cshow_deleted\x18\x04 \x01(\x08\"q\x0A\x19ListCustomClassesResponse\x12;\x0A\x0Ecustom_classes\x18\x01 \x03(\x0B2#.google.cloud.speech.v2.CustomClass\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\"P\x0A\x15GetCustomClassRequest\x127\x0A\x04name\x18\x01 \x01(\x09B)\xE0A\x02\xFAA#\x0A!speech.googleapis.com/CustomClass\"\xA2\x01\x0A\x18UpdateCustomClassRequest\x12>\x0A\x0Ccustom_class\x18\x01 \x01(\x0B2#.google.cloud.speech.v2.CustomClassB\x03\xE0A\x02\x12/\x0A\x0Bupdate_mask\x18\x02 \x01(\x0B2\x1A.google.protobuf.FieldMask\x12\x15\x0A\x0Dvalidate_only\x18\x04 \x01(\x08\"\x8F\x01\x0A\x18DeleteCustomClassRequest\x127\x0A\x04name\x18\x01 \x01(\x09B)\xE0A\x02\xFAA#\x0A!speech.googleapis.com/CustomClass\x12\x15\x0A\x0Dvalidate_only\x18\x02 \x01(\x08\x12\x15\x0A\x0Dallow_missing\x18\x04 \x01(\x08\x12\x0C\x0A\x04etag\x18\x03 \x01(\x09\"z\x0A\x1AUndeleteCustomClassRequest\x127\x0A\x04name\x18\x01 \x01(\x09B)\xE0A\x02\xFAA#\x0A!speech.googleapis.com/CustomClass\x12\x15\x0A\x0Dvalidate_only\x18\x03 \x01(\x08\x12\x0C\x0A\x04etag\x18\x04 \x01(\x09\"\xBB\x01\x0A\x16CreatePhraseSetRequest\x12:\x0A\x0Aphrase_set\x18\x01 \x01(\x0B2!.google.cloud.speech.v2.PhraseSetB\x03\xE0A\x02\x12\x15\x0A\x0Dvalidate_only\x18\x02 \x01(\x08\x12\x15\x0A\x0Dphrase_set_id\x18\x03 \x01(\x09\x127\x0A\x06parent\x18\x04 \x01(\x09B'\xE0A\x02\xFAA!\x12\x1Fspeech.googleapis.com/PhraseSet\"\x8F\x01\x0A\x15ListPhraseSetsRequest\x129\x0A\x06parent\x18\x01 \x01(\x09B)\xE0A\x02\xFAA#\x0A!locations.googleapis.com/Location\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\x12\x14\x0A\x0Cshow_deleted\x18\x04 \x01(\x08\"i\x0A\x16ListPhraseSetsResponse\x126\x0A\x0Bphrase_sets\x18\x01 \x03(\x0B2!.google.cloud.speech.v2.PhraseSet\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\"L\x0A\x13GetPhraseSetRequest\x125\x0A\x04name\x18\x01 \x01(\x09B'\xE0A\x02\xFAA!\x0A\x1Fspeech.googleapis.com/PhraseSet\"\x9C\x01\x0A\x16UpdatePhraseSetRequest\x12:\x0A\x0Aphrase_set\x18\x01 \x01(\x0B2!.google.cloud.speech.v2.PhraseSetB\x03\xE0A\x02\x12/\x0A\x0Bupdate_mask\x18\x02 \x01(\x0B2\x1A.google.protobuf.FieldMask\x12\x15\x0A\x0Dvalidate_only\x18\x04 \x01(\x08\"\x8B\x01\x0A\x16DeletePhraseSetRequest\x125\x0A\x04name\x18\x01 \x01(\x09B'\xE0A\x02\xFAA!\x0A\x1Fspeech.googleapis.com/PhraseSet\x12\x15\x0A\x0Dvalidate_only\x18\x02 \x01(\x08\x12\x15\x0A\x0Dallow_missing\x18\x04 \x01(\x08\x12\x0C\x0A\x04etag\x18\x03 \x01(\x09\"v\x0A\x18UndeletePhraseSetRequest\x125\x0A\x04name\x18\x01 \x01(\x09B'\xE0A\x02\xFAA!\x0A\x1Fspeech.googleapis.com/PhraseSet\x12\x15\x0A\x0Dvalidate_only\x18\x03 \x01(\x08\x12\x0C\x0A\x04etag\x18\x04 \x01(\x092\xBF%\x0A\x06Speech\x12\xEC\x01\x0A\x10CreateRecognizer\x12/.google.cloud.speech.v2.CreateRecognizerRequest\x1A\x1D.google.longrunning.Operation\"\x87\x01\xCAA\x1F\x0A\x0ARecognizer\x12\x11OperationMetadata\xDAA\x1Fparent,recognizer,recognizer_id\x82\xD3\xE4\x93\x02=\"//v2/{parent=projects/*/locations/*}/recognizers:\x0Arecognizer\x12\xB4\x01\x0A\x0FListRecognizers\x12..google.cloud.speech.v2.ListRecognizersRequest\x1A/.google.cloud.speech.v2.ListRecognizersResponse\"@\xDAA\x06parent\x82\xD3\xE4\x93\x021\x12//v2/{parent=projects/*/locations/*}/recognizers\x12\xA1\x01\x0A\x0DGetRecognizer\x12,.google.cloud.speech.v2.GetRecognizerRequest\x1A\".google.cloud.speech.v2.Recognizer\">\xDAA\x04name\x82\xD3\xE4\x93\x021\x12//v2/{name=projects/*/locations/*/recognizers/*}\x12\xEE\x01\x0A\x10UpdateRecognizer\x12/.google.cloud.speech.v2.UpdateRecognizerRequest\x1A\x1D.google.longrunning.Operation\"\x89\x01\xCAA\x1F\x0A\x0ARecognizer\x12\x11OperationMetadata\xDAA\x16recognizer,update_mask\x82\xD3\xE4\x93\x02H2:/v2/{recognizer.name=projects/*/locations/*/recognizers/*}:\x0Arecognizer\x12\xC4\x01\x0A\x10DeleteRecognizer\x12/.google.cloud.speech.v2.DeleteRecognizerRequest\x1A\x1D.google.longrunning.Operation\"`\xCAA\x1F\x0A\x0ARecognizer\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x021*//v2/{name=projects/*/locations/*/recognizers/*}\x12\xD4\x01\x0A\x12UndeleteRecognizer\x121.google.cloud.speech.v2.UndeleteRecognizerRequest\x1A\x1D.google.longrunning.Operation\"l\xCAA\x1F\x0A\x0ARecognizer\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x02=\"8/v2/{name=projects/*/locations/*/recognizers/*}:undelete:\x01*\x12\xF9\x01\x0A\x09Recognize\x12(.google.cloud.speech.v2.RecognizeRequest\x1A).google.cloud.speech.v2.RecognizeResponse\"\x96\x01\xDAA%recognizer,config,config_mask,content\xDAA!recognizer,config,config_mask,uri\x82\xD3\xE4\x93\x02D\"?/v2/{recognizer=projects/*/locations/*/recognizers/*}:recognize:\x01*\x12\x81\x01\x0A\x12StreamingRecognize\x121.google.cloud.speech.v2.StreamingRecognizeRequest\x1A2.google.cloud.speech.v2.StreamingRecognizeResponse\"\x00(\x010\x01\x12\x84\x02\x0A\x0EBatchRecognize\x12-.google.cloud.speech.v2.BatchRecognizeRequest\x1A\x1D.google.longrunning.Operation\"\xA3\x01\xCAA+\x0A\x16BatchRecognizeResponse\x12\x11OperationMetadata\xDAA#recognizer,config,config_mask,files\x82\xD3\xE4\x93\x02I\"D/v2/{recognizer=projects/*/locations/*/recognizers/*}:batchRecognize:\x01*\x12\x8E\x01\x0A\x09GetConfig\x12(.google.cloud.speech.v2.GetConfigRequest\x1A\x1E.google.cloud.speech.v2.Config\"7\xDAA\x04name\x82\xD3\xE4\x93\x02*\x12(/v2/{name=projects/*/locations/*/config}\x12\xB1\x01\x0A\x0CUpdateConfig\x12+.google.cloud.speech.v2.UpdateConfigRequest\x1A\x1E.google.cloud.speech.v2.Config\"T\xDAA\x12config,update_mask\x82\xD3\xE4\x93\x0292//v2/{config.name=projects/*/locations/*/config}:\x06config\x12\xF7\x01\x0A\x11CreateCustomClass\x120.google.cloud.speech.v2.CreateCustomClassRequest\x1A\x1D.google.longrunning.Operation\"\x90\x01\xCAA \x0A\x0BCustomClass\x12\x11OperationMetadata\xDAA#parent,custom_class,custom_class_id\x82\xD3\xE4\x93\x02A\"1/v2/{parent=projects/*/locations/*}/customClasses:\x0Ccustom_class\x12\xBC\x01\x0A\x11ListCustomClasses\x120.google.cloud.speech.v2.ListCustomClassesRequest\x1A1.google.cloud.speech.v2.ListCustomClassesResponse\"B\xDAA\x06parent\x82\xD3\xE4\x93\x023\x121/v2/{parent=projects/*/locations/*}/customClasses\x12\xA6\x01\x0A\x0EGetCustomClass\x12-.google.cloud.speech.v2.GetCustomClassRequest\x1A#.google.cloud.speech.v2.CustomClass\"@\xDAA\x04name\x82\xD3\xE4\x93\x023\x121/v2/{name=projects/*/locations/*/customClasses/*}\x12\xF9\x01\x0A\x11UpdateCustomClass\x120.google.cloud.speech.v2.UpdateCustomClassRequest\x1A\x1D.google.longrunning.Operation\"\x92\x01\xCAA \x0A\x0BCustomClass\x12\x11OperationMetadata\xDAA\x18custom_class,update_mask\x82\xD3\xE4\x93\x02N2>/v2/{custom_class.name=projects/*/locations/*/customClasses/*}:\x0Ccustom_class\x12\xC9\x01\x0A\x11DeleteCustomClass\x120.google.cloud.speech.v2.DeleteCustomClassRequest\x1A\x1D.google.longrunning.Operation\"c\xCAA \x0A\x0BCustomClass\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x023*1/v2/{name=projects/*/locations/*/customClasses/*}\x12\xD9\x01\x0A\x13UndeleteCustomClass\x122.google.cloud.speech.v2.UndeleteCustomClassRequest\x1A\x1D.google.longrunning.Operation\"o\xCAA \x0A\x0BCustomClass\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x02?\":/v2/{name=projects/*/locations/*/customClasses/*}:undelete:\x01*\x12\xE8\x01\x0A\x0FCreatePhraseSet\x12..google.cloud.speech.v2.CreatePhraseSetRequest\x1A\x1D.google.longrunning.Operation\"\x85\x01\xCAA\x1E\x0A\x09PhraseSet\x12\x11OperationMetadata\xDAA\x1Fparent,phrase_set,phrase_set_id\x82\xD3\xE4\x93\x02<\"./v2/{parent=projects/*/locations/*}/phraseSets:\x0Aphrase_set\x12\xB0\x01\x0A\x0EListPhraseSets\x12-.google.cloud.speech.v2.ListPhraseSetsRequest\x1A..google.cloud.speech.v2.ListPhraseSetsResponse\"?\xDAA\x06parent\x82\xD3\xE4\x93\x020\x12./v2/{parent=projects/*/locations/*}/phraseSets\x12\x9D\x01\x0A\x0CGetPhraseSet\x12+.google.cloud.speech.v2.GetPhraseSetRequest\x1A!.google.cloud.speech.v2.PhraseSet\"=\xDAA\x04name\x82\xD3\xE4\x93\x020\x12./v2/{name=projects/*/locations/*/phraseSets/*}\x12\xEA\x01\x0A\x0FUpdatePhraseSet\x12..google.cloud.speech.v2.UpdatePhraseSetRequest\x1A\x1D.google.longrunning.Operation\"\x87\x01\xCAA\x1E\x0A\x09PhraseSet\x12\x11OperationMetadata\xDAA\x16phrase_set,update_mask\x82\xD3\xE4\x93\x02G29/v2/{phrase_set.name=projects/*/locations/*/phraseSets/*}:\x0Aphrase_set\x12\xC0\x01\x0A\x0FDeletePhraseSet\x12..google.cloud.speech.v2.DeletePhraseSetRequest\x1A\x1D.google.longrunning.Operation\"^\xCAA\x1E\x0A\x09PhraseSet\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x020*./v2/{name=projects/*/locations/*/phraseSets/*}\x12\xD0\x01\x0A\x11UndeletePhraseSet\x120.google.cloud.speech.v2.UndeletePhraseSetRequest\x1A\x1D.google.longrunning.Operation\"j\xCAA\x1E\x0A\x09PhraseSet\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x02<\"7/v2/{name=projects/*/locations/*/phraseSets/*}:undelete:\x01*\x1AI\xCAA\x15speech.googleapis.com\xD2A.https://www.googleapis.com/auth/cloud-platformB\x89\x03\x0A\x1Acom.google.cloud.speech.v2B\x10CloudSpeechProtoP\x01Z2cloud.google.com/go/speech/apiv2/speechpb;speechpb\xEAAx\x0A!cloudkms.googleapis.com/CryptoKey\x12Sprojects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}\xEAA\xA6\x01\x0A(cloudkms.googleapis.com/CryptoKeyVersion\x12zprojects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}/cryptoKeyVersions/{crypto_key_version}b\x06proto3" + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/GPBMetadata/Google/Cloud/Speech/V2/LocationsMetadata.php b/owl-bot-staging/Speech/v2/proto/src/GPBMetadata/Google/Cloud/Speech/V2/LocationsMetadata.php new file mode 100644 index 000000000000..9c8963af8a3d --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/GPBMetadata/Google/Cloud/Speech/V2/LocationsMetadata.php @@ -0,0 +1,24 @@ +internalAddGeneratedFile( + "\x0A\x94\x08\x0A/google/cloud/speech/v2/locations_metadata.proto\x12\x16google.cloud.speech.v2\"6\x0A\x0CModelFeature\x12\x0F\x0A\x07feature\x18\x01 \x01(\x09\x12\x15\x0A\x0Drelease_state\x18\x02 \x01(\x09\"L\x0A\x0DModelFeatures\x12;\x0A\x0Dmodel_feature\x18\x01 \x03(\x0B2\$.google.cloud.speech.v2.ModelFeature\"\xBE\x01\x0A\x0DModelMetadata\x12P\x0A\x0Emodel_features\x18\x01 \x03(\x0B28.google.cloud.speech.v2.ModelMetadata.ModelFeaturesEntry\x1A[\x0A\x12ModelFeaturesEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x124\x0A\x05value\x18\x02 \x01(\x0B2%.google.cloud.speech.v2.ModelFeatures:\x028\x01\"\xAE\x01\x0A\x10LanguageMetadata\x12D\x0A\x06models\x18\x01 \x03(\x0B24.google.cloud.speech.v2.LanguageMetadata.ModelsEntry\x1AT\x0A\x0BModelsEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x124\x0A\x05value\x18\x02 \x01(\x0B2%.google.cloud.speech.v2.ModelMetadata:\x028\x01\"\xC8\x01\x0A\x0EAccessMetadata\x12N\x0A\x0Fconstraint_type\x18\x01 \x01(\x0E25.google.cloud.speech.v2.AccessMetadata.ConstraintType\"f\x0A\x0EConstraintType\x12\x1F\x0A\x1BCONSTRAINT_TYPE_UNSPECIFIED\x10\x00\x123\x0A/RESOURCE_LOCATIONS_ORG_POLICY_CREATE_CONSTRAINT\x10\x01\"\x91\x01\x0A\x11LocationsMetadata\x12;\x0A\x09languages\x18\x01 \x01(\x0B2(.google.cloud.speech.v2.LanguageMetadata\x12?\x0A\x0Faccess_metadata\x18\x02 \x01(\x0B2&.google.cloud.speech.v2.AccessMetadataBj\x0A\x1Acom.google.cloud.speech.v2B\x16LocationsMetadataProtoP\x01Z2cloud.google.com/go/speech/apiv2/speechpb;speechpbb\x06proto3" + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/AccessMetadata.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/AccessMetadata.php new file mode 100644 index 000000000000..c9bd403692d7 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/AccessMetadata.php @@ -0,0 +1,68 @@ +google.cloud.speech.v2.AccessMetadata + */ +class AccessMetadata extends \Google\Protobuf\Internal\Message +{ + /** + * Describes the different types of constraints that are applied. + * + * Generated from protobuf field .google.cloud.speech.v2.AccessMetadata.ConstraintType constraint_type = 1; + */ + protected $constraint_type = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $constraint_type + * Describes the different types of constraints that are applied. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\LocationsMetadata::initOnce(); + parent::__construct($data); + } + + /** + * Describes the different types of constraints that are applied. + * + * Generated from protobuf field .google.cloud.speech.v2.AccessMetadata.ConstraintType constraint_type = 1; + * @return int + */ + public function getConstraintType() + { + return $this->constraint_type; + } + + /** + * Describes the different types of constraints that are applied. + * + * Generated from protobuf field .google.cloud.speech.v2.AccessMetadata.ConstraintType constraint_type = 1; + * @param int $var + * @return $this + */ + public function setConstraintType($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Speech\V2\AccessMetadata\ConstraintType::class); + $this->constraint_type = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/AccessMetadata/ConstraintType.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/AccessMetadata/ConstraintType.php new file mode 100644 index 000000000000..6a80c5844629 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/AccessMetadata/ConstraintType.php @@ -0,0 +1,55 @@ +google.cloud.speech.v2.AccessMetadata.ConstraintType + */ +class ConstraintType +{ + /** + * Unspecified constraint applied. + * + * Generated from protobuf enum CONSTRAINT_TYPE_UNSPECIFIED = 0; + */ + const CONSTRAINT_TYPE_UNSPECIFIED = 0; + /** + * The project's org policy disallows the given region. + * + * Generated from protobuf enum RESOURCE_LOCATIONS_ORG_POLICY_CREATE_CONSTRAINT = 1; + */ + const RESOURCE_LOCATIONS_ORG_POLICY_CREATE_CONSTRAINT = 1; + + private static $valueToName = [ + self::CONSTRAINT_TYPE_UNSPECIFIED => 'CONSTRAINT_TYPE_UNSPECIFIED', + self::RESOURCE_LOCATIONS_ORG_POLICY_CREATE_CONSTRAINT => 'RESOURCE_LOCATIONS_ORG_POLICY_CREATE_CONSTRAINT', + ]; + + 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/Speech/v2/proto/src/Google/Cloud/Speech/V2/AutoDetectDecodingConfig.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/AutoDetectDecodingConfig.php new file mode 100644 index 000000000000..9a3b7986454e --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/AutoDetectDecodingConfig.php @@ -0,0 +1,46 @@ +google.cloud.speech.v2.AutoDetectDecodingConfig + */ +class AutoDetectDecodingConfig extends \Google\Protobuf\Internal\Message +{ + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeFileMetadata.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeFileMetadata.php new file mode 100644 index 000000000000..88bd91f81ca1 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeFileMetadata.php @@ -0,0 +1,239 @@ +google.cloud.speech.v2.BatchRecognizeFileMetadata + */ +class BatchRecognizeFileMetadata extends \Google\Protobuf\Internal\Message +{ + /** + * Features and audio metadata to use for the Automatic Speech Recognition. + * This field in combination with the + * [config_mask][google.cloud.speech.v2.BatchRecognizeFileMetadata.config_mask] + * field can be used to override parts of the + * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] + * of the Recognizer resource as well as the + * [config][google.cloud.speech.v2.BatchRecognizeRequest.config] at the + * request level. + * + * Generated from protobuf field .google.cloud.speech.v2.RecognitionConfig config = 4; + */ + protected $config = null; + /** + * The list of fields in + * [config][google.cloud.speech.v2.BatchRecognizeFileMetadata.config] that + * override the values in the + * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] + * of the recognizer during this recognition request. If no mask is provided, + * all non-default valued fields in + * [config][google.cloud.speech.v2.BatchRecognizeFileMetadata.config] override + * the values in the recognizer for this recognition request. If a mask is + * provided, only the fields listed in the mask override the config in the + * recognizer for this recognition request. If a wildcard (`*`) is provided, + * [config][google.cloud.speech.v2.BatchRecognizeFileMetadata.config] + * completely overrides and replaces the config in the recognizer for this + * recognition request. + * + * Generated from protobuf field .google.protobuf.FieldMask config_mask = 5; + */ + protected $config_mask = null; + protected $audio_source; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $uri + * Cloud Storage URI for the audio file. + * @type \Google\Cloud\Speech\V2\RecognitionConfig $config + * Features and audio metadata to use for the Automatic Speech Recognition. + * This field in combination with the + * [config_mask][google.cloud.speech.v2.BatchRecognizeFileMetadata.config_mask] + * field can be used to override parts of the + * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] + * of the Recognizer resource as well as the + * [config][google.cloud.speech.v2.BatchRecognizeRequest.config] at the + * request level. + * @type \Google\Protobuf\FieldMask $config_mask + * The list of fields in + * [config][google.cloud.speech.v2.BatchRecognizeFileMetadata.config] that + * override the values in the + * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] + * of the recognizer during this recognition request. If no mask is provided, + * all non-default valued fields in + * [config][google.cloud.speech.v2.BatchRecognizeFileMetadata.config] override + * the values in the recognizer for this recognition request. If a mask is + * provided, only the fields listed in the mask override the config in the + * recognizer for this recognition request. If a wildcard (`*`) is provided, + * [config][google.cloud.speech.v2.BatchRecognizeFileMetadata.config] + * completely overrides and replaces the config in the recognizer for this + * recognition request. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Cloud Storage URI for the audio file. + * + * Generated from protobuf field string uri = 1; + * @return string + */ + public function getUri() + { + return $this->readOneof(1); + } + + public function hasUri() + { + return $this->hasOneof(1); + } + + /** + * Cloud Storage URI for the audio file. + * + * Generated from protobuf field string uri = 1; + * @param string $var + * @return $this + */ + public function setUri($var) + { + GPBUtil::checkString($var, True); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * Features and audio metadata to use for the Automatic Speech Recognition. + * This field in combination with the + * [config_mask][google.cloud.speech.v2.BatchRecognizeFileMetadata.config_mask] + * field can be used to override parts of the + * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] + * of the Recognizer resource as well as the + * [config][google.cloud.speech.v2.BatchRecognizeRequest.config] at the + * request level. + * + * Generated from protobuf field .google.cloud.speech.v2.RecognitionConfig config = 4; + * @return \Google\Cloud\Speech\V2\RecognitionConfig|null + */ + public function getConfig() + { + return $this->config; + } + + public function hasConfig() + { + return isset($this->config); + } + + public function clearConfig() + { + unset($this->config); + } + + /** + * Features and audio metadata to use for the Automatic Speech Recognition. + * This field in combination with the + * [config_mask][google.cloud.speech.v2.BatchRecognizeFileMetadata.config_mask] + * field can be used to override parts of the + * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] + * of the Recognizer resource as well as the + * [config][google.cloud.speech.v2.BatchRecognizeRequest.config] at the + * request level. + * + * Generated from protobuf field .google.cloud.speech.v2.RecognitionConfig config = 4; + * @param \Google\Cloud\Speech\V2\RecognitionConfig $var + * @return $this + */ + public function setConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\RecognitionConfig::class); + $this->config = $var; + + return $this; + } + + /** + * The list of fields in + * [config][google.cloud.speech.v2.BatchRecognizeFileMetadata.config] that + * override the values in the + * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] + * of the recognizer during this recognition request. If no mask is provided, + * all non-default valued fields in + * [config][google.cloud.speech.v2.BatchRecognizeFileMetadata.config] override + * the values in the recognizer for this recognition request. If a mask is + * provided, only the fields listed in the mask override the config in the + * recognizer for this recognition request. If a wildcard (`*`) is provided, + * [config][google.cloud.speech.v2.BatchRecognizeFileMetadata.config] + * completely overrides and replaces the config in the recognizer for this + * recognition request. + * + * Generated from protobuf field .google.protobuf.FieldMask config_mask = 5; + * @return \Google\Protobuf\FieldMask|null + */ + public function getConfigMask() + { + return $this->config_mask; + } + + public function hasConfigMask() + { + return isset($this->config_mask); + } + + public function clearConfigMask() + { + unset($this->config_mask); + } + + /** + * The list of fields in + * [config][google.cloud.speech.v2.BatchRecognizeFileMetadata.config] that + * override the values in the + * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] + * of the recognizer during this recognition request. If no mask is provided, + * all non-default valued fields in + * [config][google.cloud.speech.v2.BatchRecognizeFileMetadata.config] override + * the values in the recognizer for this recognition request. If a mask is + * provided, only the fields listed in the mask override the config in the + * recognizer for this recognition request. If a wildcard (`*`) is provided, + * [config][google.cloud.speech.v2.BatchRecognizeFileMetadata.config] + * completely overrides and replaces the config in the recognizer for this + * recognition request. + * + * Generated from protobuf field .google.protobuf.FieldMask config_mask = 5; + * @param \Google\Protobuf\FieldMask $var + * @return $this + */ + public function setConfigMask($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); + $this->config_mask = $var; + + return $this; + } + + /** + * @return string + */ + public function getAudioSource() + { + return $this->whichOneof("audio_source"); + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeFileResult.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeFileResult.php new file mode 100644 index 000000000000..57c5452e8231 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeFileResult.php @@ -0,0 +1,306 @@ +google.cloud.speech.v2.BatchRecognizeFileResult + */ +class BatchRecognizeFileResult extends \Google\Protobuf\Internal\Message +{ + /** + * Error if one was encountered. + * + * Generated from protobuf field .google.rpc.Status error = 2; + */ + protected $error = null; + /** + * Generated from protobuf field .google.cloud.speech.v2.RecognitionResponseMetadata metadata = 3; + */ + protected $metadata = null; + /** + * Deprecated. Use `cloud_storage_result.native_format_uri` instead. + * + * Generated from protobuf field string uri = 1 [deprecated = true]; + * @deprecated + */ + protected $uri = ''; + /** + * Deprecated. Use `inline_result.transcript` instead. + * + * Generated from protobuf field .google.cloud.speech.v2.BatchRecognizeResults transcript = 4 [deprecated = true]; + * @deprecated + */ + protected $transcript = null; + protected $result; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Rpc\Status $error + * Error if one was encountered. + * @type \Google\Cloud\Speech\V2\RecognitionResponseMetadata $metadata + * @type \Google\Cloud\Speech\V2\CloudStorageResult $cloud_storage_result + * Recognition results written to Cloud Storage. This is + * populated only when + * [GcsOutputConfig][google.cloud.speech.v2.GcsOutputConfig] is set in + * the + * [RecognitionOutputConfig][[google.cloud.speech.v2.RecognitionOutputConfig]. + * @type \Google\Cloud\Speech\V2\InlineResult $inline_result + * Recognition results. This is populated only when + * [InlineOutputConfig][google.cloud.speech.v2.InlineOutputConfig] is set in + * the + * [RecognitionOutputConfig][[google.cloud.speech.v2.RecognitionOutputConfig]. + * @type string $uri + * Deprecated. Use `cloud_storage_result.native_format_uri` instead. + * @type \Google\Cloud\Speech\V2\BatchRecognizeResults $transcript + * Deprecated. Use `inline_result.transcript` instead. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Error if one was encountered. + * + * Generated from protobuf field .google.rpc.Status error = 2; + * @return \Google\Rpc\Status|null + */ + public function getError() + { + return $this->error; + } + + public function hasError() + { + return isset($this->error); + } + + public function clearError() + { + unset($this->error); + } + + /** + * Error if one was encountered. + * + * Generated from protobuf field .google.rpc.Status error = 2; + * @param \Google\Rpc\Status $var + * @return $this + */ + public function setError($var) + { + GPBUtil::checkMessage($var, \Google\Rpc\Status::class); + $this->error = $var; + + return $this; + } + + /** + * Generated from protobuf field .google.cloud.speech.v2.RecognitionResponseMetadata metadata = 3; + * @return \Google\Cloud\Speech\V2\RecognitionResponseMetadata|null + */ + public function getMetadata() + { + return $this->metadata; + } + + public function hasMetadata() + { + return isset($this->metadata); + } + + public function clearMetadata() + { + unset($this->metadata); + } + + /** + * Generated from protobuf field .google.cloud.speech.v2.RecognitionResponseMetadata metadata = 3; + * @param \Google\Cloud\Speech\V2\RecognitionResponseMetadata $var + * @return $this + */ + public function setMetadata($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\RecognitionResponseMetadata::class); + $this->metadata = $var; + + return $this; + } + + /** + * Recognition results written to Cloud Storage. This is + * populated only when + * [GcsOutputConfig][google.cloud.speech.v2.GcsOutputConfig] is set in + * the + * [RecognitionOutputConfig][[google.cloud.speech.v2.RecognitionOutputConfig]. + * + * Generated from protobuf field .google.cloud.speech.v2.CloudStorageResult cloud_storage_result = 5; + * @return \Google\Cloud\Speech\V2\CloudStorageResult|null + */ + public function getCloudStorageResult() + { + return $this->readOneof(5); + } + + public function hasCloudStorageResult() + { + return $this->hasOneof(5); + } + + /** + * Recognition results written to Cloud Storage. This is + * populated only when + * [GcsOutputConfig][google.cloud.speech.v2.GcsOutputConfig] is set in + * the + * [RecognitionOutputConfig][[google.cloud.speech.v2.RecognitionOutputConfig]. + * + * Generated from protobuf field .google.cloud.speech.v2.CloudStorageResult cloud_storage_result = 5; + * @param \Google\Cloud\Speech\V2\CloudStorageResult $var + * @return $this + */ + public function setCloudStorageResult($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\CloudStorageResult::class); + $this->writeOneof(5, $var); + + return $this; + } + + /** + * Recognition results. This is populated only when + * [InlineOutputConfig][google.cloud.speech.v2.InlineOutputConfig] is set in + * the + * [RecognitionOutputConfig][[google.cloud.speech.v2.RecognitionOutputConfig]. + * + * Generated from protobuf field .google.cloud.speech.v2.InlineResult inline_result = 6; + * @return \Google\Cloud\Speech\V2\InlineResult|null + */ + public function getInlineResult() + { + return $this->readOneof(6); + } + + public function hasInlineResult() + { + return $this->hasOneof(6); + } + + /** + * Recognition results. This is populated only when + * [InlineOutputConfig][google.cloud.speech.v2.InlineOutputConfig] is set in + * the + * [RecognitionOutputConfig][[google.cloud.speech.v2.RecognitionOutputConfig]. + * + * Generated from protobuf field .google.cloud.speech.v2.InlineResult inline_result = 6; + * @param \Google\Cloud\Speech\V2\InlineResult $var + * @return $this + */ + public function setInlineResult($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\InlineResult::class); + $this->writeOneof(6, $var); + + return $this; + } + + /** + * Deprecated. Use `cloud_storage_result.native_format_uri` instead. + * + * Generated from protobuf field string uri = 1 [deprecated = true]; + * @return string + * @deprecated + */ + public function getUri() + { + if ($this->uri !== '') { + @trigger_error('uri is deprecated.', E_USER_DEPRECATED); + } + return $this->uri; + } + + /** + * Deprecated. Use `cloud_storage_result.native_format_uri` instead. + * + * Generated from protobuf field string uri = 1 [deprecated = true]; + * @param string $var + * @return $this + * @deprecated + */ + public function setUri($var) + { + @trigger_error('uri is deprecated.', E_USER_DEPRECATED); + GPBUtil::checkString($var, True); + $this->uri = $var; + + return $this; + } + + /** + * Deprecated. Use `inline_result.transcript` instead. + * + * Generated from protobuf field .google.cloud.speech.v2.BatchRecognizeResults transcript = 4 [deprecated = true]; + * @return \Google\Cloud\Speech\V2\BatchRecognizeResults|null + * @deprecated + */ + public function getTranscript() + { + if (isset($this->transcript)) { + @trigger_error('transcript is deprecated.', E_USER_DEPRECATED); + } + return $this->transcript; + } + + public function hasTranscript() + { + if (isset($this->transcript)) { + @trigger_error('transcript is deprecated.', E_USER_DEPRECATED); + } + return isset($this->transcript); + } + + public function clearTranscript() + { + @trigger_error('transcript is deprecated.', E_USER_DEPRECATED); + unset($this->transcript); + } + + /** + * Deprecated. Use `inline_result.transcript` instead. + * + * Generated from protobuf field .google.cloud.speech.v2.BatchRecognizeResults transcript = 4 [deprecated = true]; + * @param \Google\Cloud\Speech\V2\BatchRecognizeResults $var + * @return $this + * @deprecated + */ + public function setTranscript($var) + { + @trigger_error('transcript is deprecated.', E_USER_DEPRECATED); + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\BatchRecognizeResults::class); + $this->transcript = $var; + + return $this; + } + + /** + * @return string + */ + public function getResult() + { + return $this->whichOneof("result"); + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeMetadata.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeMetadata.php new file mode 100644 index 000000000000..43ba95327d4d --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeMetadata.php @@ -0,0 +1,68 @@ +google.cloud.speech.v2.BatchRecognizeMetadata + */ +class BatchRecognizeMetadata extends \Google\Protobuf\Internal\Message +{ + /** + * Map from provided filename to the transcription metadata for that file. + * + * Generated from protobuf field map transcription_metadata = 1; + */ + private $transcription_metadata; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array|\Google\Protobuf\Internal\MapField $transcription_metadata + * Map from provided filename to the transcription metadata for that file. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Map from provided filename to the transcription metadata for that file. + * + * Generated from protobuf field map transcription_metadata = 1; + * @return \Google\Protobuf\Internal\MapField + */ + public function getTranscriptionMetadata() + { + return $this->transcription_metadata; + } + + /** + * Map from provided filename to the transcription metadata for that file. + * + * Generated from protobuf field map transcription_metadata = 1; + * @param array|\Google\Protobuf\Internal\MapField $var + * @return $this + */ + public function setTranscriptionMetadata($var) + { + $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Speech\V2\BatchRecognizeTranscriptionMetadata::class); + $this->transcription_metadata = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeRequest.php new file mode 100644 index 000000000000..d3e2d3d9b300 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeRequest.php @@ -0,0 +1,394 @@ +google.cloud.speech.v2.BatchRecognizeRequest + */ +class BatchRecognizeRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the Recognizer to use during recognition. The + * expected format is + * `projects/{project}/locations/{location}/recognizers/{recognizer}`. The + * {recognizer} segment may be set to `_` to use an empty implicit Recognizer. + * + * Generated from protobuf field string recognizer = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $recognizer = ''; + /** + * Features and audio metadata to use for the Automatic Speech Recognition. + * This field in combination with the + * [config_mask][google.cloud.speech.v2.BatchRecognizeRequest.config_mask] + * field can be used to override parts of the + * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] + * of the Recognizer resource. + * + * Generated from protobuf field .google.cloud.speech.v2.RecognitionConfig config = 4; + */ + protected $config = null; + /** + * The list of fields in + * [config][google.cloud.speech.v2.BatchRecognizeRequest.config] that override + * the values in the + * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] + * of the recognizer during this recognition request. If no mask is provided, + * all given fields in + * [config][google.cloud.speech.v2.BatchRecognizeRequest.config] override the + * values in the recognizer for this recognition request. If a mask is + * provided, only the fields listed in the mask override the config in the + * recognizer for this recognition request. If a wildcard (`*`) is provided, + * [config][google.cloud.speech.v2.BatchRecognizeRequest.config] completely + * overrides and replaces the config in the recognizer for this recognition + * request. + * + * Generated from protobuf field .google.protobuf.FieldMask config_mask = 5; + */ + protected $config_mask = null; + /** + * Audio files with file metadata for ASR. + * The maximum number of files allowed to be specified is 15. + * + * Generated from protobuf field repeated .google.cloud.speech.v2.BatchRecognizeFileMetadata files = 3; + */ + private $files; + /** + * Configuration options for where to output the transcripts of each file. + * + * Generated from protobuf field .google.cloud.speech.v2.RecognitionOutputConfig recognition_output_config = 6; + */ + protected $recognition_output_config = null; + /** + * Processing strategy to use for this request. + * + * Generated from protobuf field .google.cloud.speech.v2.BatchRecognizeRequest.ProcessingStrategy processing_strategy = 7; + */ + protected $processing_strategy = 0; + + /** + * @param string $recognizer Required. The name of the Recognizer to use during recognition. The + * expected format is + * `projects/{project}/locations/{location}/recognizers/{recognizer}`. The + * {recognizer} segment may be set to `_` to use an empty implicit Recognizer. Please see + * {@see SpeechClient::recognizerName()} for help formatting this field. + * @param \Google\Cloud\Speech\V2\RecognitionConfig $config Features and audio metadata to use for the Automatic Speech Recognition. + * This field in combination with the + * [config_mask][google.cloud.speech.v2.BatchRecognizeRequest.config_mask] + * field can be used to override parts of the + * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] + * of the Recognizer resource. + * @param \Google\Protobuf\FieldMask $configMask The list of fields in + * [config][google.cloud.speech.v2.BatchRecognizeRequest.config] that override + * the values in the + * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] + * of the recognizer during this recognition request. If no mask is provided, + * all given fields in + * [config][google.cloud.speech.v2.BatchRecognizeRequest.config] override the + * values in the recognizer for this recognition request. If a mask is + * provided, only the fields listed in the mask override the config in the + * recognizer for this recognition request. If a wildcard (`*`) is provided, + * [config][google.cloud.speech.v2.BatchRecognizeRequest.config] completely + * overrides and replaces the config in the recognizer for this recognition + * request. + * @param \Google\Cloud\Speech\V2\BatchRecognizeFileMetadata[] $files Audio files with file metadata for ASR. + * The maximum number of files allowed to be specified is 15. + * + * @return \Google\Cloud\Speech\V2\BatchRecognizeRequest + * + * @experimental + */ + public static function build(string $recognizer, \Google\Cloud\Speech\V2\RecognitionConfig $config, \Google\Protobuf\FieldMask $configMask, array $files): self + { + return (new self()) + ->setRecognizer($recognizer) + ->setConfig($config) + ->setConfigMask($configMask) + ->setFiles($files); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $recognizer + * Required. The name of the Recognizer to use during recognition. The + * expected format is + * `projects/{project}/locations/{location}/recognizers/{recognizer}`. The + * {recognizer} segment may be set to `_` to use an empty implicit Recognizer. + * @type \Google\Cloud\Speech\V2\RecognitionConfig $config + * Features and audio metadata to use for the Automatic Speech Recognition. + * This field in combination with the + * [config_mask][google.cloud.speech.v2.BatchRecognizeRequest.config_mask] + * field can be used to override parts of the + * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] + * of the Recognizer resource. + * @type \Google\Protobuf\FieldMask $config_mask + * The list of fields in + * [config][google.cloud.speech.v2.BatchRecognizeRequest.config] that override + * the values in the + * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] + * of the recognizer during this recognition request. If no mask is provided, + * all given fields in + * [config][google.cloud.speech.v2.BatchRecognizeRequest.config] override the + * values in the recognizer for this recognition request. If a mask is + * provided, only the fields listed in the mask override the config in the + * recognizer for this recognition request. If a wildcard (`*`) is provided, + * [config][google.cloud.speech.v2.BatchRecognizeRequest.config] completely + * overrides and replaces the config in the recognizer for this recognition + * request. + * @type \Google\Cloud\Speech\V2\BatchRecognizeFileMetadata[] $files + * Audio files with file metadata for ASR. + * The maximum number of files allowed to be specified is 15. + * @type \Google\Cloud\Speech\V2\RecognitionOutputConfig $recognition_output_config + * Configuration options for where to output the transcripts of each file. + * @type int $processing_strategy + * Processing strategy to use for this request. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the Recognizer to use during recognition. The + * expected format is + * `projects/{project}/locations/{location}/recognizers/{recognizer}`. The + * {recognizer} segment may be set to `_` to use an empty implicit Recognizer. + * + * Generated from protobuf field string recognizer = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getRecognizer() + { + return $this->recognizer; + } + + /** + * Required. The name of the Recognizer to use during recognition. The + * expected format is + * `projects/{project}/locations/{location}/recognizers/{recognizer}`. The + * {recognizer} segment may be set to `_` to use an empty implicit Recognizer. + * + * Generated from protobuf field string recognizer = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setRecognizer($var) + { + GPBUtil::checkString($var, True); + $this->recognizer = $var; + + return $this; + } + + /** + * Features and audio metadata to use for the Automatic Speech Recognition. + * This field in combination with the + * [config_mask][google.cloud.speech.v2.BatchRecognizeRequest.config_mask] + * field can be used to override parts of the + * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] + * of the Recognizer resource. + * + * Generated from protobuf field .google.cloud.speech.v2.RecognitionConfig config = 4; + * @return \Google\Cloud\Speech\V2\RecognitionConfig|null + */ + public function getConfig() + { + return $this->config; + } + + public function hasConfig() + { + return isset($this->config); + } + + public function clearConfig() + { + unset($this->config); + } + + /** + * Features and audio metadata to use for the Automatic Speech Recognition. + * This field in combination with the + * [config_mask][google.cloud.speech.v2.BatchRecognizeRequest.config_mask] + * field can be used to override parts of the + * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] + * of the Recognizer resource. + * + * Generated from protobuf field .google.cloud.speech.v2.RecognitionConfig config = 4; + * @param \Google\Cloud\Speech\V2\RecognitionConfig $var + * @return $this + */ + public function setConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\RecognitionConfig::class); + $this->config = $var; + + return $this; + } + + /** + * The list of fields in + * [config][google.cloud.speech.v2.BatchRecognizeRequest.config] that override + * the values in the + * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] + * of the recognizer during this recognition request. If no mask is provided, + * all given fields in + * [config][google.cloud.speech.v2.BatchRecognizeRequest.config] override the + * values in the recognizer for this recognition request. If a mask is + * provided, only the fields listed in the mask override the config in the + * recognizer for this recognition request. If a wildcard (`*`) is provided, + * [config][google.cloud.speech.v2.BatchRecognizeRequest.config] completely + * overrides and replaces the config in the recognizer for this recognition + * request. + * + * Generated from protobuf field .google.protobuf.FieldMask config_mask = 5; + * @return \Google\Protobuf\FieldMask|null + */ + public function getConfigMask() + { + return $this->config_mask; + } + + public function hasConfigMask() + { + return isset($this->config_mask); + } + + public function clearConfigMask() + { + unset($this->config_mask); + } + + /** + * The list of fields in + * [config][google.cloud.speech.v2.BatchRecognizeRequest.config] that override + * the values in the + * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] + * of the recognizer during this recognition request. If no mask is provided, + * all given fields in + * [config][google.cloud.speech.v2.BatchRecognizeRequest.config] override the + * values in the recognizer for this recognition request. If a mask is + * provided, only the fields listed in the mask override the config in the + * recognizer for this recognition request. If a wildcard (`*`) is provided, + * [config][google.cloud.speech.v2.BatchRecognizeRequest.config] completely + * overrides and replaces the config in the recognizer for this recognition + * request. + * + * Generated from protobuf field .google.protobuf.FieldMask config_mask = 5; + * @param \Google\Protobuf\FieldMask $var + * @return $this + */ + public function setConfigMask($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); + $this->config_mask = $var; + + return $this; + } + + /** + * Audio files with file metadata for ASR. + * The maximum number of files allowed to be specified is 15. + * + * Generated from protobuf field repeated .google.cloud.speech.v2.BatchRecognizeFileMetadata files = 3; + * @return RepeatedField<\Google\Cloud\Speech\V2\BatchRecognizeFileMetadata> + */ + public function getFiles() + { + return $this->files; + } + + /** + * Audio files with file metadata for ASR. + * The maximum number of files allowed to be specified is 15. + * + * Generated from protobuf field repeated .google.cloud.speech.v2.BatchRecognizeFileMetadata files = 3; + * @param \Google\Cloud\Speech\V2\BatchRecognizeFileMetadata[] $var + * @return $this + */ + public function setFiles($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Speech\V2\BatchRecognizeFileMetadata::class); + $this->files = $arr; + + return $this; + } + + /** + * Configuration options for where to output the transcripts of each file. + * + * Generated from protobuf field .google.cloud.speech.v2.RecognitionOutputConfig recognition_output_config = 6; + * @return \Google\Cloud\Speech\V2\RecognitionOutputConfig|null + */ + public function getRecognitionOutputConfig() + { + return $this->recognition_output_config; + } + + public function hasRecognitionOutputConfig() + { + return isset($this->recognition_output_config); + } + + public function clearRecognitionOutputConfig() + { + unset($this->recognition_output_config); + } + + /** + * Configuration options for where to output the transcripts of each file. + * + * Generated from protobuf field .google.cloud.speech.v2.RecognitionOutputConfig recognition_output_config = 6; + * @param \Google\Cloud\Speech\V2\RecognitionOutputConfig $var + * @return $this + */ + public function setRecognitionOutputConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\RecognitionOutputConfig::class); + $this->recognition_output_config = $var; + + return $this; + } + + /** + * Processing strategy to use for this request. + * + * Generated from protobuf field .google.cloud.speech.v2.BatchRecognizeRequest.ProcessingStrategy processing_strategy = 7; + * @return int + */ + public function getProcessingStrategy() + { + return $this->processing_strategy; + } + + /** + * Processing strategy to use for this request. + * + * Generated from protobuf field .google.cloud.speech.v2.BatchRecognizeRequest.ProcessingStrategy processing_strategy = 7; + * @param int $var + * @return $this + */ + public function setProcessingStrategy($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Speech\V2\BatchRecognizeRequest\ProcessingStrategy::class); + $this->processing_strategy = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeRequest/ProcessingStrategy.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeRequest/ProcessingStrategy.php new file mode 100644 index 000000000000..fdf6905d01af --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeRequest/ProcessingStrategy.php @@ -0,0 +1,56 @@ +google.cloud.speech.v2.BatchRecognizeRequest.ProcessingStrategy + */ +class ProcessingStrategy +{ + /** + * Default value for the processing strategy. The request is processed as + * soon as its received. + * + * Generated from protobuf enum PROCESSING_STRATEGY_UNSPECIFIED = 0; + */ + const PROCESSING_STRATEGY_UNSPECIFIED = 0; + /** + * If selected, processes the request during lower utilization periods for a + * price discount. The request is fulfilled within 24 hours. + * + * Generated from protobuf enum DYNAMIC_BATCHING = 1; + */ + const DYNAMIC_BATCHING = 1; + + private static $valueToName = [ + self::PROCESSING_STRATEGY_UNSPECIFIED => 'PROCESSING_STRATEGY_UNSPECIFIED', + self::DYNAMIC_BATCHING => 'DYNAMIC_BATCHING', + ]; + + 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/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeResponse.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeResponse.php new file mode 100644 index 000000000000..36b1bf9542dd --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeResponse.php @@ -0,0 +1,113 @@ +google.cloud.speech.v2.BatchRecognizeResponse + */ +class BatchRecognizeResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Map from filename to the final result for that file. + * + * Generated from protobuf field map results = 1; + */ + private $results; + /** + * When available, billed audio seconds for the corresponding request. + * + * Generated from protobuf field .google.protobuf.Duration total_billed_duration = 2; + */ + protected $total_billed_duration = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array|\Google\Protobuf\Internal\MapField $results + * Map from filename to the final result for that file. + * @type \Google\Protobuf\Duration $total_billed_duration + * When available, billed audio seconds for the corresponding request. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Map from filename to the final result for that file. + * + * Generated from protobuf field map results = 1; + * @return \Google\Protobuf\Internal\MapField + */ + public function getResults() + { + return $this->results; + } + + /** + * Map from filename to the final result for that file. + * + * Generated from protobuf field map results = 1; + * @param array|\Google\Protobuf\Internal\MapField $var + * @return $this + */ + public function setResults($var) + { + $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Speech\V2\BatchRecognizeFileResult::class); + $this->results = $arr; + + return $this; + } + + /** + * When available, billed audio seconds for the corresponding request. + * + * Generated from protobuf field .google.protobuf.Duration total_billed_duration = 2; + * @return \Google\Protobuf\Duration|null + */ + public function getTotalBilledDuration() + { + return $this->total_billed_duration; + } + + public function hasTotalBilledDuration() + { + return isset($this->total_billed_duration); + } + + public function clearTotalBilledDuration() + { + unset($this->total_billed_duration); + } + + /** + * When available, billed audio seconds for the corresponding request. + * + * Generated from protobuf field .google.protobuf.Duration total_billed_duration = 2; + * @param \Google\Protobuf\Duration $var + * @return $this + */ + public function setTotalBilledDuration($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); + $this->total_billed_duration = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeResults.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeResults.php new file mode 100644 index 000000000000..be39c6e4a3f8 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeResults.php @@ -0,0 +1,117 @@ +google.cloud.speech.v2.BatchRecognizeResults + */ +class BatchRecognizeResults extends \Google\Protobuf\Internal\Message +{ + /** + * Sequential list of transcription results corresponding to sequential + * portions of audio. + * + * Generated from protobuf field repeated .google.cloud.speech.v2.SpeechRecognitionResult results = 1; + */ + private $results; + /** + * Metadata about the recognition. + * + * Generated from protobuf field .google.cloud.speech.v2.RecognitionResponseMetadata metadata = 2; + */ + protected $metadata = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Speech\V2\SpeechRecognitionResult[] $results + * Sequential list of transcription results corresponding to sequential + * portions of audio. + * @type \Google\Cloud\Speech\V2\RecognitionResponseMetadata $metadata + * Metadata about the recognition. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Sequential list of transcription results corresponding to sequential + * portions of audio. + * + * Generated from protobuf field repeated .google.cloud.speech.v2.SpeechRecognitionResult results = 1; + * @return RepeatedField<\Google\Cloud\Speech\V2\SpeechRecognitionResult> + */ + public function getResults() + { + return $this->results; + } + + /** + * Sequential list of transcription results corresponding to sequential + * portions of audio. + * + * Generated from protobuf field repeated .google.cloud.speech.v2.SpeechRecognitionResult results = 1; + * @param \Google\Cloud\Speech\V2\SpeechRecognitionResult[] $var + * @return $this + */ + public function setResults($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Speech\V2\SpeechRecognitionResult::class); + $this->results = $arr; + + return $this; + } + + /** + * Metadata about the recognition. + * + * Generated from protobuf field .google.cloud.speech.v2.RecognitionResponseMetadata metadata = 2; + * @return \Google\Cloud\Speech\V2\RecognitionResponseMetadata|null + */ + public function getMetadata() + { + return $this->metadata; + } + + public function hasMetadata() + { + return isset($this->metadata); + } + + public function clearMetadata() + { + unset($this->metadata); + } + + /** + * Metadata about the recognition. + * + * Generated from protobuf field .google.cloud.speech.v2.RecognitionResponseMetadata metadata = 2; + * @param \Google\Cloud\Speech\V2\RecognitionResponseMetadata $var + * @return $this + */ + public function setMetadata($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\RecognitionResponseMetadata::class); + $this->metadata = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeTranscriptionMetadata.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeTranscriptionMetadata.php new file mode 100644 index 000000000000..e51976e1e846 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeTranscriptionMetadata.php @@ -0,0 +1,146 @@ +google.cloud.speech.v2.BatchRecognizeTranscriptionMetadata + */ +class BatchRecognizeTranscriptionMetadata extends \Google\Protobuf\Internal\Message +{ + /** + * How much of the file has been transcribed so far. + * + * Generated from protobuf field int32 progress_percent = 1; + */ + protected $progress_percent = 0; + /** + * Error if one was encountered. + * + * Generated from protobuf field .google.rpc.Status error = 2; + */ + protected $error = null; + /** + * The Cloud Storage URI to which recognition results will be written. + * + * Generated from protobuf field string uri = 3; + */ + protected $uri = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $progress_percent + * How much of the file has been transcribed so far. + * @type \Google\Rpc\Status $error + * Error if one was encountered. + * @type string $uri + * The Cloud Storage URI to which recognition results will be written. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * How much of the file has been transcribed so far. + * + * Generated from protobuf field int32 progress_percent = 1; + * @return int + */ + public function getProgressPercent() + { + return $this->progress_percent; + } + + /** + * How much of the file has been transcribed so far. + * + * Generated from protobuf field int32 progress_percent = 1; + * @param int $var + * @return $this + */ + public function setProgressPercent($var) + { + GPBUtil::checkInt32($var); + $this->progress_percent = $var; + + return $this; + } + + /** + * Error if one was encountered. + * + * Generated from protobuf field .google.rpc.Status error = 2; + * @return \Google\Rpc\Status|null + */ + public function getError() + { + return $this->error; + } + + public function hasError() + { + return isset($this->error); + } + + public function clearError() + { + unset($this->error); + } + + /** + * Error if one was encountered. + * + * Generated from protobuf field .google.rpc.Status error = 2; + * @param \Google\Rpc\Status $var + * @return $this + */ + public function setError($var) + { + GPBUtil::checkMessage($var, \Google\Rpc\Status::class); + $this->error = $var; + + return $this; + } + + /** + * The Cloud Storage URI to which recognition results will be written. + * + * Generated from protobuf field string uri = 3; + * @return string + */ + public function getUri() + { + return $this->uri; + } + + /** + * The Cloud Storage URI to which recognition results will be written. + * + * Generated from protobuf field string uri = 3; + * @param string $var + * @return $this + */ + public function setUri($var) + { + GPBUtil::checkString($var, True); + $this->uri = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CloudStorageResult.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CloudStorageResult.php new file mode 100644 index 000000000000..41e59d91553a --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CloudStorageResult.php @@ -0,0 +1,143 @@ +google.cloud.speech.v2.CloudStorageResult + */ +class CloudStorageResult extends \Google\Protobuf\Internal\Message +{ + /** + * The Cloud Storage URI to which recognition results were written. + * + * Generated from protobuf field string uri = 1; + */ + protected $uri = ''; + /** + * The Cloud Storage URI to which recognition results were written as VTT + * formatted captions. This is populated only when `VTT` output is requested. + * + * Generated from protobuf field string vtt_format_uri = 2; + */ + protected $vtt_format_uri = ''; + /** + * The Cloud Storage URI to which recognition results were written as SRT + * formatted captions. This is populated only when `SRT` output is requested. + * + * Generated from protobuf field string srt_format_uri = 3; + */ + protected $srt_format_uri = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $uri + * The Cloud Storage URI to which recognition results were written. + * @type string $vtt_format_uri + * The Cloud Storage URI to which recognition results were written as VTT + * formatted captions. This is populated only when `VTT` output is requested. + * @type string $srt_format_uri + * The Cloud Storage URI to which recognition results were written as SRT + * formatted captions. This is populated only when `SRT` output is requested. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * The Cloud Storage URI to which recognition results were written. + * + * Generated from protobuf field string uri = 1; + * @return string + */ + public function getUri() + { + return $this->uri; + } + + /** + * The Cloud Storage URI to which recognition results were written. + * + * 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; + } + + /** + * The Cloud Storage URI to which recognition results were written as VTT + * formatted captions. This is populated only when `VTT` output is requested. + * + * Generated from protobuf field string vtt_format_uri = 2; + * @return string + */ + public function getVttFormatUri() + { + return $this->vtt_format_uri; + } + + /** + * The Cloud Storage URI to which recognition results were written as VTT + * formatted captions. This is populated only when `VTT` output is requested. + * + * Generated from protobuf field string vtt_format_uri = 2; + * @param string $var + * @return $this + */ + public function setVttFormatUri($var) + { + GPBUtil::checkString($var, True); + $this->vtt_format_uri = $var; + + return $this; + } + + /** + * The Cloud Storage URI to which recognition results were written as SRT + * formatted captions. This is populated only when `SRT` output is requested. + * + * Generated from protobuf field string srt_format_uri = 3; + * @return string + */ + public function getSrtFormatUri() + { + return $this->srt_format_uri; + } + + /** + * The Cloud Storage URI to which recognition results were written as SRT + * formatted captions. This is populated only when `SRT` output is requested. + * + * Generated from protobuf field string srt_format_uri = 3; + * @param string $var + * @return $this + */ + public function setSrtFormatUri($var) + { + GPBUtil::checkString($var, True); + $this->srt_format_uri = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/Config.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/Config.php new file mode 100644 index 000000000000..97cbf042f620 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/Config.php @@ -0,0 +1,175 @@ +google.cloud.speech.v2.Config + */ +class Config extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. Identifier. The name of the config resource. There is exactly + * one config resource per project per location. The expected format is + * `projects/{project}/locations/{location}/config`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IDENTIFIER]; + */ + protected $name = ''; + /** + * Optional. An optional [KMS key + * name](https://cloud.google.com/kms/docs/resource-hierarchy#keys) that if + * present, will be used to encrypt Speech-to-Text resources at-rest. Updating + * this key will not encrypt existing resources using this key; only new + * resources will be encrypted using this key. The expected format is + * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. + * + * Generated from protobuf field string kms_key_name = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { + */ + protected $kms_key_name = ''; + /** + * Output only. The most recent time this resource was modified. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $update_time = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Output only. Identifier. The name of the config resource. There is exactly + * one config resource per project per location. The expected format is + * `projects/{project}/locations/{location}/config`. + * @type string $kms_key_name + * Optional. An optional [KMS key + * name](https://cloud.google.com/kms/docs/resource-hierarchy#keys) that if + * present, will be used to encrypt Speech-to-Text resources at-rest. Updating + * this key will not encrypt existing resources using this key; only new + * resources will be encrypted using this key. The expected format is + * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. + * @type \Google\Protobuf\Timestamp $update_time + * Output only. The most recent time this resource was modified. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Output only. Identifier. The name of the config resource. There is exactly + * one config resource per project per location. The expected format is + * `projects/{project}/locations/{location}/config`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IDENTIFIER]; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Output only. Identifier. The name of the config resource. There is exactly + * one config resource per project per location. The expected format is + * `projects/{project}/locations/{location}/config`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IDENTIFIER]; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Optional. An optional [KMS key + * name](https://cloud.google.com/kms/docs/resource-hierarchy#keys) that if + * present, will be used to encrypt Speech-to-Text resources at-rest. Updating + * this key will not encrypt existing resources using this key; only new + * resources will be encrypted using this key. The expected format is + * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. + * + * Generated from protobuf field string kms_key_name = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { + * @return string + */ + public function getKmsKeyName() + { + return $this->kms_key_name; + } + + /** + * Optional. An optional [KMS key + * name](https://cloud.google.com/kms/docs/resource-hierarchy#keys) that if + * present, will be used to encrypt Speech-to-Text resources at-rest. Updating + * this key will not encrypt existing resources using this key; only new + * resources will be encrypted using this key. The expected format is + * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. + * + * Generated from protobuf field string kms_key_name = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setKmsKeyName($var) + { + GPBUtil::checkString($var, True); + $this->kms_key_name = $var; + + return $this; + } + + /** + * Output only. The most recent time this resource was 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. The most recent time this resource was 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; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CreateCustomClassRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CreateCustomClassRequest.php new file mode 100644 index 000000000000..fe0f6a6171dc --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CreateCustomClassRequest.php @@ -0,0 +1,223 @@ +google.cloud.speech.v2.CreateCustomClassRequest + */ +class CreateCustomClassRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The CustomClass to create. + * + * Generated from protobuf field .google.cloud.speech.v2.CustomClass custom_class = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $custom_class = null; + /** + * If set, validate the request and preview the CustomClass, but do not + * actually create it. + * + * Generated from protobuf field bool validate_only = 2; + */ + protected $validate_only = false; + /** + * The ID to use for the CustomClass, which will become the final component of + * the CustomClass's resource name. + * This value should be 4-63 characters, and valid characters + * are /[a-z][0-9]-/. + * + * Generated from protobuf field string custom_class_id = 3; + */ + protected $custom_class_id = ''; + /** + * Required. The project and location where this CustomClass will be created. + * The expected format is `projects/{project}/locations/{location}`. + * + * Generated from protobuf field string parent = 4 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + + /** + * @param string $parent Required. The project and location where this CustomClass will be created. + * The expected format is `projects/{project}/locations/{location}`. Please see + * {@see SpeechClient::locationName()} for help formatting this field. + * @param \Google\Cloud\Speech\V2\CustomClass $customClass Required. The CustomClass to create. + * @param string $customClassId The ID to use for the CustomClass, which will become the final component of + * the CustomClass's resource name. + * + * This value should be 4-63 characters, and valid characters + * are /[a-z][0-9]-/. + * + * @return \Google\Cloud\Speech\V2\CreateCustomClassRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\Speech\V2\CustomClass $customClass, string $customClassId): self + { + return (new self()) + ->setParent($parent) + ->setCustomClass($customClass) + ->setCustomClassId($customClassId); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Speech\V2\CustomClass $custom_class + * Required. The CustomClass to create. + * @type bool $validate_only + * If set, validate the request and preview the CustomClass, but do not + * actually create it. + * @type string $custom_class_id + * The ID to use for the CustomClass, which will become the final component of + * the CustomClass's resource name. + * This value should be 4-63 characters, and valid characters + * are /[a-z][0-9]-/. + * @type string $parent + * Required. The project and location where this CustomClass will be created. + * The expected format is `projects/{project}/locations/{location}`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Required. The CustomClass to create. + * + * Generated from protobuf field .google.cloud.speech.v2.CustomClass custom_class = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Speech\V2\CustomClass|null + */ + public function getCustomClass() + { + return $this->custom_class; + } + + public function hasCustomClass() + { + return isset($this->custom_class); + } + + public function clearCustomClass() + { + unset($this->custom_class); + } + + /** + * Required. The CustomClass to create. + * + * Generated from protobuf field .google.cloud.speech.v2.CustomClass custom_class = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Speech\V2\CustomClass $var + * @return $this + */ + public function setCustomClass($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\CustomClass::class); + $this->custom_class = $var; + + return $this; + } + + /** + * If set, validate the request and preview the CustomClass, but do not + * actually create it. + * + * Generated from protobuf field bool validate_only = 2; + * @return bool + */ + public function getValidateOnly() + { + return $this->validate_only; + } + + /** + * If set, validate the request and preview the CustomClass, but do not + * actually create it. + * + * Generated from protobuf field bool validate_only = 2; + * @param bool $var + * @return $this + */ + public function setValidateOnly($var) + { + GPBUtil::checkBool($var); + $this->validate_only = $var; + + return $this; + } + + /** + * The ID to use for the CustomClass, which will become the final component of + * the CustomClass's resource name. + * This value should be 4-63 characters, and valid characters + * are /[a-z][0-9]-/. + * + * Generated from protobuf field string custom_class_id = 3; + * @return string + */ + public function getCustomClassId() + { + return $this->custom_class_id; + } + + /** + * The ID to use for the CustomClass, which will become the final component of + * the CustomClass's resource name. + * This value should be 4-63 characters, and valid characters + * are /[a-z][0-9]-/. + * + * Generated from protobuf field string custom_class_id = 3; + * @param string $var + * @return $this + */ + public function setCustomClassId($var) + { + GPBUtil::checkString($var, True); + $this->custom_class_id = $var; + + return $this; + } + + /** + * Required. The project and location where this CustomClass will be created. + * The expected format is `projects/{project}/locations/{location}`. + * + * Generated from protobuf field string parent = 4 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. The project and location where this CustomClass will be created. + * The expected format is `projects/{project}/locations/{location}`. + * + * Generated from protobuf field string parent = 4 [(.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; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CreatePhraseSetRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CreatePhraseSetRequest.php new file mode 100644 index 000000000000..1c9779ed145b --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CreatePhraseSetRequest.php @@ -0,0 +1,223 @@ +google.cloud.speech.v2.CreatePhraseSetRequest + */ +class CreatePhraseSetRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The PhraseSet to create. + * + * Generated from protobuf field .google.cloud.speech.v2.PhraseSet phrase_set = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $phrase_set = null; + /** + * If set, validate the request and preview the PhraseSet, but do not + * actually create it. + * + * Generated from protobuf field bool validate_only = 2; + */ + protected $validate_only = false; + /** + * The ID to use for the PhraseSet, which will become the final component of + * the PhraseSet's resource name. + * This value should be 4-63 characters, and valid characters + * are /[a-z][0-9]-/. + * + * Generated from protobuf field string phrase_set_id = 3; + */ + protected $phrase_set_id = ''; + /** + * Required. The project and location where this PhraseSet will be created. + * The expected format is `projects/{project}/locations/{location}`. + * + * Generated from protobuf field string parent = 4 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + + /** + * @param string $parent Required. The project and location where this PhraseSet will be created. + * The expected format is `projects/{project}/locations/{location}`. Please see + * {@see SpeechClient::locationName()} for help formatting this field. + * @param \Google\Cloud\Speech\V2\PhraseSet $phraseSet Required. The PhraseSet to create. + * @param string $phraseSetId The ID to use for the PhraseSet, which will become the final component of + * the PhraseSet's resource name. + * + * This value should be 4-63 characters, and valid characters + * are /[a-z][0-9]-/. + * + * @return \Google\Cloud\Speech\V2\CreatePhraseSetRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\Speech\V2\PhraseSet $phraseSet, string $phraseSetId): self + { + return (new self()) + ->setParent($parent) + ->setPhraseSet($phraseSet) + ->setPhraseSetId($phraseSetId); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Speech\V2\PhraseSet $phrase_set + * Required. The PhraseSet to create. + * @type bool $validate_only + * If set, validate the request and preview the PhraseSet, but do not + * actually create it. + * @type string $phrase_set_id + * The ID to use for the PhraseSet, which will become the final component of + * the PhraseSet's resource name. + * This value should be 4-63 characters, and valid characters + * are /[a-z][0-9]-/. + * @type string $parent + * Required. The project and location where this PhraseSet will be created. + * The expected format is `projects/{project}/locations/{location}`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Required. The PhraseSet to create. + * + * Generated from protobuf field .google.cloud.speech.v2.PhraseSet phrase_set = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Speech\V2\PhraseSet|null + */ + public function getPhraseSet() + { + return $this->phrase_set; + } + + public function hasPhraseSet() + { + return isset($this->phrase_set); + } + + public function clearPhraseSet() + { + unset($this->phrase_set); + } + + /** + * Required. The PhraseSet to create. + * + * Generated from protobuf field .google.cloud.speech.v2.PhraseSet phrase_set = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Speech\V2\PhraseSet $var + * @return $this + */ + public function setPhraseSet($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\PhraseSet::class); + $this->phrase_set = $var; + + return $this; + } + + /** + * If set, validate the request and preview the PhraseSet, but do not + * actually create it. + * + * Generated from protobuf field bool validate_only = 2; + * @return bool + */ + public function getValidateOnly() + { + return $this->validate_only; + } + + /** + * If set, validate the request and preview the PhraseSet, but do not + * actually create it. + * + * Generated from protobuf field bool validate_only = 2; + * @param bool $var + * @return $this + */ + public function setValidateOnly($var) + { + GPBUtil::checkBool($var); + $this->validate_only = $var; + + return $this; + } + + /** + * The ID to use for the PhraseSet, which will become the final component of + * the PhraseSet's resource name. + * This value should be 4-63 characters, and valid characters + * are /[a-z][0-9]-/. + * + * Generated from protobuf field string phrase_set_id = 3; + * @return string + */ + public function getPhraseSetId() + { + return $this->phrase_set_id; + } + + /** + * The ID to use for the PhraseSet, which will become the final component of + * the PhraseSet's resource name. + * This value should be 4-63 characters, and valid characters + * are /[a-z][0-9]-/. + * + * Generated from protobuf field string phrase_set_id = 3; + * @param string $var + * @return $this + */ + public function setPhraseSetId($var) + { + GPBUtil::checkString($var, True); + $this->phrase_set_id = $var; + + return $this; + } + + /** + * Required. The project and location where this PhraseSet will be created. + * The expected format is `projects/{project}/locations/{location}`. + * + * Generated from protobuf field string parent = 4 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. The project and location where this PhraseSet will be created. + * The expected format is `projects/{project}/locations/{location}`. + * + * Generated from protobuf field string parent = 4 [(.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; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CreateRecognizerRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CreateRecognizerRequest.php new file mode 100644 index 000000000000..bf9c8bd3aa14 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CreateRecognizerRequest.php @@ -0,0 +1,223 @@ +google.cloud.speech.v2.CreateRecognizerRequest + */ +class CreateRecognizerRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The Recognizer to create. + * + * Generated from protobuf field .google.cloud.speech.v2.Recognizer recognizer = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $recognizer = null; + /** + * If set, validate the request and preview the Recognizer, but do not + * actually create it. + * + * Generated from protobuf field bool validate_only = 2; + */ + protected $validate_only = false; + /** + * The ID to use for the Recognizer, which will become the final component of + * the Recognizer's resource name. + * This value should be 4-63 characters, and valid characters + * are /[a-z][0-9]-/. + * + * Generated from protobuf field string recognizer_id = 3; + */ + protected $recognizer_id = ''; + /** + * Required. The project and location where this Recognizer will be created. + * The expected format is `projects/{project}/locations/{location}`. + * + * Generated from protobuf field string parent = 4 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + + /** + * @param string $parent Required. The project and location where this Recognizer will be created. + * The expected format is `projects/{project}/locations/{location}`. Please see + * {@see SpeechClient::locationName()} for help formatting this field. + * @param \Google\Cloud\Speech\V2\Recognizer $recognizer Required. The Recognizer to create. + * @param string $recognizerId The ID to use for the Recognizer, which will become the final component of + * the Recognizer's resource name. + * + * This value should be 4-63 characters, and valid characters + * are /[a-z][0-9]-/. + * + * @return \Google\Cloud\Speech\V2\CreateRecognizerRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\Speech\V2\Recognizer $recognizer, string $recognizerId): self + { + return (new self()) + ->setParent($parent) + ->setRecognizer($recognizer) + ->setRecognizerId($recognizerId); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Speech\V2\Recognizer $recognizer + * Required. The Recognizer to create. + * @type bool $validate_only + * If set, validate the request and preview the Recognizer, but do not + * actually create it. + * @type string $recognizer_id + * The ID to use for the Recognizer, which will become the final component of + * the Recognizer's resource name. + * This value should be 4-63 characters, and valid characters + * are /[a-z][0-9]-/. + * @type string $parent + * Required. The project and location where this Recognizer will be created. + * The expected format is `projects/{project}/locations/{location}`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Required. The Recognizer to create. + * + * Generated from protobuf field .google.cloud.speech.v2.Recognizer recognizer = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Speech\V2\Recognizer|null + */ + public function getRecognizer() + { + return $this->recognizer; + } + + public function hasRecognizer() + { + return isset($this->recognizer); + } + + public function clearRecognizer() + { + unset($this->recognizer); + } + + /** + * Required. The Recognizer to create. + * + * Generated from protobuf field .google.cloud.speech.v2.Recognizer recognizer = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Speech\V2\Recognizer $var + * @return $this + */ + public function setRecognizer($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\Recognizer::class); + $this->recognizer = $var; + + return $this; + } + + /** + * If set, validate the request and preview the Recognizer, but do not + * actually create it. + * + * Generated from protobuf field bool validate_only = 2; + * @return bool + */ + public function getValidateOnly() + { + return $this->validate_only; + } + + /** + * If set, validate the request and preview the Recognizer, but do not + * actually create it. + * + * Generated from protobuf field bool validate_only = 2; + * @param bool $var + * @return $this + */ + public function setValidateOnly($var) + { + GPBUtil::checkBool($var); + $this->validate_only = $var; + + return $this; + } + + /** + * The ID to use for the Recognizer, which will become the final component of + * the Recognizer's resource name. + * This value should be 4-63 characters, and valid characters + * are /[a-z][0-9]-/. + * + * Generated from protobuf field string recognizer_id = 3; + * @return string + */ + public function getRecognizerId() + { + return $this->recognizer_id; + } + + /** + * The ID to use for the Recognizer, which will become the final component of + * the Recognizer's resource name. + * This value should be 4-63 characters, and valid characters + * are /[a-z][0-9]-/. + * + * Generated from protobuf field string recognizer_id = 3; + * @param string $var + * @return $this + */ + public function setRecognizerId($var) + { + GPBUtil::checkString($var, True); + $this->recognizer_id = $var; + + return $this; + } + + /** + * Required. The project and location where this Recognizer will be created. + * The expected format is `projects/{project}/locations/{location}`. + * + * Generated from protobuf field string parent = 4 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. The project and location where this Recognizer will be created. + * The expected format is `projects/{project}/locations/{location}`. + * + * Generated from protobuf field string parent = 4 [(.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; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CustomClass.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CustomClass.php new file mode 100644 index 000000000000..21b809a7e6a9 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CustomClass.php @@ -0,0 +1,607 @@ +google.cloud.speech.v2.CustomClass + */ +class CustomClass extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. Identifier. The resource name of the CustomClass. + * Format: + * `projects/{project}/locations/{location}/customClasses/{custom_class}`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IDENTIFIER]; + */ + protected $name = ''; + /** + * Output only. System-assigned unique identifier for the CustomClass. + * + * Generated from protobuf field string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $uid = ''; + /** + * Optional. User-settable, human-readable name for the CustomClass. Must be + * 63 characters or less. + * + * Generated from protobuf field string display_name = 4 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $display_name = ''; + /** + * A collection of class items. + * + * Generated from protobuf field repeated .google.cloud.speech.v2.CustomClass.ClassItem items = 5; + */ + private $items; + /** + * Output only. The CustomClass lifecycle state. + * + * Generated from protobuf field .google.cloud.speech.v2.CustomClass.State state = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $state = 0; + /** + * Output only. Creation time. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $create_time = null; + /** + * Output only. The most recent time this resource was modified. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $update_time = null; + /** + * Output only. The time at which this resource was requested for deletion. + * + * Generated from protobuf field .google.protobuf.Timestamp delete_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $delete_time = null; + /** + * Output only. The time at which this resource will be purged. + * + * Generated from protobuf field .google.protobuf.Timestamp expire_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $expire_time = null; + /** + * Optional. Allows users to store small amounts of arbitrary data. + * Both the key and the value must be 63 characters or less each. + * At most 100 annotations. + * + * Generated from protobuf field map annotations = 10 [(.google.api.field_behavior) = OPTIONAL]; + */ + private $annotations; + /** + * Output only. This checksum is computed by the server based on the value of + * other fields. This may be sent on update, undelete, and delete requests to + * ensure 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 = ''; + /** + * Output only. Whether or not this CustomClass is in the process of being + * updated. + * + * Generated from protobuf field bool reconciling = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $reconciling = false; + /** + * Output only. The [KMS key + * name](https://cloud.google.com/kms/docs/resource-hierarchy#keys) with which + * the CustomClass is encrypted. The expected format is + * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. + * + * Generated from protobuf field string kms_key_name = 13 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { + */ + protected $kms_key_name = ''; + /** + * Output only. The [KMS key version + * name](https://cloud.google.com/kms/docs/resource-hierarchy#key_versions) + * with which the CustomClass is encrypted. The expected format is + * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}/cryptoKeyVersions/{crypto_key_version}`. + * + * Generated from protobuf field string kms_key_version_name = 14 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { + */ + protected $kms_key_version_name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Output only. Identifier. The resource name of the CustomClass. + * Format: + * `projects/{project}/locations/{location}/customClasses/{custom_class}`. + * @type string $uid + * Output only. System-assigned unique identifier for the CustomClass. + * @type string $display_name + * Optional. User-settable, human-readable name for the CustomClass. Must be + * 63 characters or less. + * @type \Google\Cloud\Speech\V2\CustomClass\ClassItem[] $items + * A collection of class items. + * @type int $state + * Output only. The CustomClass lifecycle state. + * @type \Google\Protobuf\Timestamp $create_time + * Output only. Creation time. + * @type \Google\Protobuf\Timestamp $update_time + * Output only. The most recent time this resource was modified. + * @type \Google\Protobuf\Timestamp $delete_time + * Output only. The time at which this resource was requested for deletion. + * @type \Google\Protobuf\Timestamp $expire_time + * Output only. The time at which this resource will be purged. + * @type array|\Google\Protobuf\Internal\MapField $annotations + * Optional. Allows users to store small amounts of arbitrary data. + * Both the key and the value must be 63 characters or less each. + * At most 100 annotations. + * @type string $etag + * Output only. This checksum is computed by the server based on the value of + * other fields. This may be sent on update, undelete, and delete requests to + * ensure the client has an up-to-date value before proceeding. + * @type bool $reconciling + * Output only. Whether or not this CustomClass is in the process of being + * updated. + * @type string $kms_key_name + * Output only. The [KMS key + * name](https://cloud.google.com/kms/docs/resource-hierarchy#keys) with which + * the CustomClass is encrypted. The expected format is + * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. + * @type string $kms_key_version_name + * Output only. The [KMS key version + * name](https://cloud.google.com/kms/docs/resource-hierarchy#key_versions) + * with which the CustomClass is encrypted. The expected format is + * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}/cryptoKeyVersions/{crypto_key_version}`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Output only. Identifier. The resource name of the CustomClass. + * Format: + * `projects/{project}/locations/{location}/customClasses/{custom_class}`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IDENTIFIER]; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Output only. Identifier. The resource name of the CustomClass. + * Format: + * `projects/{project}/locations/{location}/customClasses/{custom_class}`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IDENTIFIER]; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Output only. System-assigned unique identifier for the CustomClass. + * + * Generated from protobuf field string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getUid() + { + return $this->uid; + } + + /** + * Output only. System-assigned unique identifier for the CustomClass. + * + * 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; + } + + /** + * Optional. User-settable, human-readable name for the CustomClass. Must be + * 63 characters or less. + * + * Generated from protobuf field string display_name = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getDisplayName() + { + return $this->display_name; + } + + /** + * Optional. User-settable, human-readable name for the CustomClass. Must be + * 63 characters or less. + * + * 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; + } + + /** + * A collection of class items. + * + * Generated from protobuf field repeated .google.cloud.speech.v2.CustomClass.ClassItem items = 5; + * @return RepeatedField<\Google\Cloud\Speech\V2\CustomClass\ClassItem> + */ + public function getItems() + { + return $this->items; + } + + /** + * A collection of class items. + * + * Generated from protobuf field repeated .google.cloud.speech.v2.CustomClass.ClassItem items = 5; + * @param \Google\Cloud\Speech\V2\CustomClass\ClassItem[] $var + * @return $this + */ + public function setItems($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Speech\V2\CustomClass\ClassItem::class); + $this->items = $arr; + + return $this; + } + + /** + * Output only. The CustomClass lifecycle state. + * + * Generated from protobuf field .google.cloud.speech.v2.CustomClass.State state = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getState() + { + return $this->state; + } + + /** + * Output only. The CustomClass lifecycle state. + * + * Generated from protobuf field .google.cloud.speech.v2.CustomClass.State state = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setState($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Speech\V2\CustomClass\State::class); + $this->state = $var; + + return $this; + } + + /** + * Output only. Creation time. + * + * 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. Creation time. + * + * 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. The most recent time this resource was modified. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 7 [(.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 most recent time this resource was modified. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 7 [(.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 time at which this resource was requested for deletion. + * + * Generated from protobuf field .google.protobuf.Timestamp delete_time = 8 [(.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. The time at which this resource was requested for deletion. + * + * Generated from protobuf field .google.protobuf.Timestamp delete_time = 8 [(.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. The time at which this resource will be purged. + * + * Generated from protobuf field .google.protobuf.Timestamp expire_time = 9 [(.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 resource will be purged. + * + * Generated from protobuf field .google.protobuf.Timestamp expire_time = 9 [(.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; + } + + /** + * Optional. Allows users to store small amounts of arbitrary data. + * Both the key and the value must be 63 characters or less each. + * At most 100 annotations. + * + * Generated from protobuf field map annotations = 10 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Protobuf\Internal\MapField + */ + public function getAnnotations() + { + return $this->annotations; + } + + /** + * Optional. Allows users to store small amounts of arbitrary data. + * Both the key and the value must be 63 characters or less each. + * At most 100 annotations. + * + * Generated from protobuf field map annotations = 10 [(.google.api.field_behavior) = OPTIONAL]; + * @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. This checksum is computed by the server based on the value of + * other fields. This may be sent on update, undelete, and delete requests to + * ensure 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. This checksum is computed by the server based on the value of + * other fields. This may be sent on update, undelete, and delete requests to + * ensure 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; + } + + /** + * Output only. Whether or not this CustomClass is in the process of being + * updated. + * + * Generated from protobuf field bool reconciling = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return bool + */ + public function getReconciling() + { + return $this->reconciling; + } + + /** + * Output only. Whether or not this CustomClass is in the process of being + * updated. + * + * Generated from protobuf field bool reconciling = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param bool $var + * @return $this + */ + public function setReconciling($var) + { + GPBUtil::checkBool($var); + $this->reconciling = $var; + + return $this; + } + + /** + * Output only. The [KMS key + * name](https://cloud.google.com/kms/docs/resource-hierarchy#keys) with which + * the CustomClass is encrypted. The expected format is + * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. + * + * Generated from protobuf field string kms_key_name = 13 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { + * @return string + */ + public function getKmsKeyName() + { + return $this->kms_key_name; + } + + /** + * Output only. The [KMS key + * name](https://cloud.google.com/kms/docs/resource-hierarchy#keys) with which + * the CustomClass is encrypted. The expected format is + * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. + * + * Generated from protobuf field string kms_key_name = 13 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setKmsKeyName($var) + { + GPBUtil::checkString($var, True); + $this->kms_key_name = $var; + + return $this; + } + + /** + * Output only. The [KMS key version + * name](https://cloud.google.com/kms/docs/resource-hierarchy#key_versions) + * with which the CustomClass is encrypted. The expected format is + * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}/cryptoKeyVersions/{crypto_key_version}`. + * + * Generated from protobuf field string kms_key_version_name = 14 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { + * @return string + */ + public function getKmsKeyVersionName() + { + return $this->kms_key_version_name; + } + + /** + * Output only. The [KMS key version + * name](https://cloud.google.com/kms/docs/resource-hierarchy#key_versions) + * with which the CustomClass is encrypted. The expected format is + * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}/cryptoKeyVersions/{crypto_key_version}`. + * + * Generated from protobuf field string kms_key_version_name = 14 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setKmsKeyVersionName($var) + { + GPBUtil::checkString($var, True); + $this->kms_key_version_name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CustomClass/ClassItem.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CustomClass/ClassItem.php new file mode 100644 index 000000000000..e22137bed692 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CustomClass/ClassItem.php @@ -0,0 +1,67 @@ +google.cloud.speech.v2.CustomClass.ClassItem + */ +class ClassItem extends \Google\Protobuf\Internal\Message +{ + /** + * The class item's value. + * + * Generated from protobuf field string value = 1; + */ + protected $value = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $value + * The class item's value. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * The class item's value. + * + * Generated from protobuf field string value = 1; + * @return string + */ + public function getValue() + { + return $this->value; + } + + /** + * The class item's value. + * + * Generated from protobuf field string value = 1; + * @param string $var + * @return $this + */ + public function setValue($var) + { + GPBUtil::checkString($var, True); + $this->value = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CustomClass/State.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CustomClass/State.php new file mode 100644 index 000000000000..07612958ca0f --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CustomClass/State.php @@ -0,0 +1,62 @@ +google.cloud.speech.v2.CustomClass.State + */ +class State +{ + /** + * Unspecified state. This is only used/useful for distinguishing + * unset values. + * + * Generated from protobuf enum STATE_UNSPECIFIED = 0; + */ + const STATE_UNSPECIFIED = 0; + /** + * The normal and active state. + * + * Generated from protobuf enum ACTIVE = 2; + */ + const ACTIVE = 2; + /** + * This CustomClass has been deleted. + * + * Generated from protobuf enum DELETED = 4; + */ + const DELETED = 4; + + private static $valueToName = [ + self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', + self::ACTIVE => 'ACTIVE', + 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); + } +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CustomPromptConfig.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CustomPromptConfig.php new file mode 100644 index 000000000000..182cf73370b0 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CustomPromptConfig.php @@ -0,0 +1,71 @@ +google.cloud.speech.v2.CustomPromptConfig + */ +class CustomPromptConfig extends \Google\Protobuf\Internal\Message +{ + /** + * Optional. The custom instructions to override the existing instructions for + * chirp3. + * + * Generated from protobuf field string custom_prompt = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $custom_prompt = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $custom_prompt + * Optional. The custom instructions to override the existing instructions for + * chirp3. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Optional. The custom instructions to override the existing instructions for + * chirp3. + * + * Generated from protobuf field string custom_prompt = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getCustomPrompt() + { + return $this->custom_prompt; + } + + /** + * Optional. The custom instructions to override the existing instructions for + * chirp3. + * + * Generated from protobuf field string custom_prompt = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @param string $var + * @return $this + */ + public function setCustomPrompt($var) + { + GPBUtil::checkString($var, True); + $this->custom_prompt = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/DeleteCustomClassRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/DeleteCustomClassRequest.php new file mode 100644 index 000000000000..7017bfe4cfcf --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/DeleteCustomClassRequest.php @@ -0,0 +1,210 @@ +google.cloud.speech.v2.DeleteCustomClassRequest + */ +class DeleteCustomClassRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the CustomClass to delete. + * Format: + * `projects/{project}/locations/{location}/customClasses/{custom_class}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * If set, validate the request and preview the deleted CustomClass, but do + * not actually delete it. + * + * Generated from protobuf field bool validate_only = 2; + */ + protected $validate_only = false; + /** + * If set to true, and the CustomClass is not found, the request will succeed + * and be a no-op (no Operation is recorded in this case). + * + * Generated from protobuf field bool allow_missing = 4; + */ + protected $allow_missing = false; + /** + * This checksum is computed by the server based on the value of other + * fields. This may be sent on update, undelete, and delete requests to ensure + * the client has an up-to-date value before proceeding. + * + * Generated from protobuf field string etag = 3; + */ + protected $etag = ''; + + /** + * @param string $name Required. The name of the CustomClass to delete. + * Format: + * `projects/{project}/locations/{location}/customClasses/{custom_class}` + * Please see {@see SpeechClient::customClassName()} for help formatting this field. + * + * @return \Google\Cloud\Speech\V2\DeleteCustomClassRequest + * + * @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 CustomClass to delete. + * Format: + * `projects/{project}/locations/{location}/customClasses/{custom_class}` + * @type bool $validate_only + * If set, validate the request and preview the deleted CustomClass, but do + * not actually delete it. + * @type bool $allow_missing + * If set to true, and the CustomClass is not found, the request will succeed + * and be a no-op (no Operation is recorded in this case). + * @type string $etag + * This checksum is computed by the server based on the value of other + * fields. This may be sent on update, undelete, and delete requests to ensure + * the client has an up-to-date value before proceeding. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the CustomClass to delete. + * Format: + * `projects/{project}/locations/{location}/customClasses/{custom_class}` + * + * 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 CustomClass to delete. + * Format: + * `projects/{project}/locations/{location}/customClasses/{custom_class}` + * + * 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, validate the request and preview the deleted CustomClass, but do + * not actually delete it. + * + * Generated from protobuf field bool validate_only = 2; + * @return bool + */ + public function getValidateOnly() + { + return $this->validate_only; + } + + /** + * If set, validate the request and preview the deleted CustomClass, but do + * not actually delete it. + * + * Generated from protobuf field bool validate_only = 2; + * @param bool $var + * @return $this + */ + public function setValidateOnly($var) + { + GPBUtil::checkBool($var); + $this->validate_only = $var; + + return $this; + } + + /** + * If set to true, and the CustomClass is not found, the request will succeed + * and be a no-op (no Operation is recorded in this case). + * + * Generated from protobuf field bool allow_missing = 4; + * @return bool + */ + public function getAllowMissing() + { + return $this->allow_missing; + } + + /** + * If set to true, and the CustomClass is not found, the request will succeed + * and be a no-op (no Operation is recorded in this case). + * + * Generated from protobuf field bool allow_missing = 4; + * @param bool $var + * @return $this + */ + public function setAllowMissing($var) + { + GPBUtil::checkBool($var); + $this->allow_missing = $var; + + return $this; + } + + /** + * This checksum is computed by the server based on the value of other + * fields. This may be sent on update, undelete, and delete requests to ensure + * the client has an up-to-date value before proceeding. + * + * Generated from protobuf field string etag = 3; + * @return string + */ + public function getEtag() + { + return $this->etag; + } + + /** + * This checksum is computed by the server based on the value of other + * fields. This may be sent on update, undelete, and delete requests to ensure + * the client has an up-to-date value before proceeding. + * + * Generated from protobuf field string etag = 3; + * @param string $var + * @return $this + */ + public function setEtag($var) + { + GPBUtil::checkString($var, True); + $this->etag = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/DeletePhraseSetRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/DeletePhraseSetRequest.php new file mode 100644 index 000000000000..cc17160faabc --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/DeletePhraseSetRequest.php @@ -0,0 +1,205 @@ +google.cloud.speech.v2.DeletePhraseSetRequest + */ +class DeletePhraseSetRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the PhraseSet to delete. + * Format: `projects/{project}/locations/{location}/phraseSets/{phrase_set}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * If set, validate the request and preview the deleted PhraseSet, but do not + * actually delete it. + * + * Generated from protobuf field bool validate_only = 2; + */ + protected $validate_only = false; + /** + * If set to true, and the PhraseSet is not found, the request will succeed + * and be a no-op (no Operation is recorded in this case). + * + * Generated from protobuf field bool allow_missing = 4; + */ + protected $allow_missing = false; + /** + * This checksum is computed by the server based on the value of other + * fields. This may be sent on update, undelete, and delete requests to ensure + * the client has an up-to-date value before proceeding. + * + * Generated from protobuf field string etag = 3; + */ + protected $etag = ''; + + /** + * @param string $name Required. The name of the PhraseSet to delete. + * Format: `projects/{project}/locations/{location}/phraseSets/{phrase_set}` + * Please see {@see SpeechClient::phraseSetName()} for help formatting this field. + * + * @return \Google\Cloud\Speech\V2\DeletePhraseSetRequest + * + * @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 PhraseSet to delete. + * Format: `projects/{project}/locations/{location}/phraseSets/{phrase_set}` + * @type bool $validate_only + * If set, validate the request and preview the deleted PhraseSet, but do not + * actually delete it. + * @type bool $allow_missing + * If set to true, and the PhraseSet is not found, the request will succeed + * and be a no-op (no Operation is recorded in this case). + * @type string $etag + * This checksum is computed by the server based on the value of other + * fields. This may be sent on update, undelete, and delete requests to ensure + * the client has an up-to-date value before proceeding. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the PhraseSet to delete. + * Format: `projects/{project}/locations/{location}/phraseSets/{phrase_set}` + * + * 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 PhraseSet to delete. + * Format: `projects/{project}/locations/{location}/phraseSets/{phrase_set}` + * + * 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, validate the request and preview the deleted PhraseSet, but do not + * actually delete it. + * + * Generated from protobuf field bool validate_only = 2; + * @return bool + */ + public function getValidateOnly() + { + return $this->validate_only; + } + + /** + * If set, validate the request and preview the deleted PhraseSet, but do not + * actually delete it. + * + * Generated from protobuf field bool validate_only = 2; + * @param bool $var + * @return $this + */ + public function setValidateOnly($var) + { + GPBUtil::checkBool($var); + $this->validate_only = $var; + + return $this; + } + + /** + * If set to true, and the PhraseSet is not found, the request will succeed + * and be a no-op (no Operation is recorded in this case). + * + * Generated from protobuf field bool allow_missing = 4; + * @return bool + */ + public function getAllowMissing() + { + return $this->allow_missing; + } + + /** + * If set to true, and the PhraseSet is not found, the request will succeed + * and be a no-op (no Operation is recorded in this case). + * + * Generated from protobuf field bool allow_missing = 4; + * @param bool $var + * @return $this + */ + public function setAllowMissing($var) + { + GPBUtil::checkBool($var); + $this->allow_missing = $var; + + return $this; + } + + /** + * This checksum is computed by the server based on the value of other + * fields. This may be sent on update, undelete, and delete requests to ensure + * the client has an up-to-date value before proceeding. + * + * Generated from protobuf field string etag = 3; + * @return string + */ + public function getEtag() + { + return $this->etag; + } + + /** + * This checksum is computed by the server based on the value of other + * fields. This may be sent on update, undelete, and delete requests to ensure + * the client has an up-to-date value before proceeding. + * + * Generated from protobuf field string etag = 3; + * @param string $var + * @return $this + */ + public function setEtag($var) + { + GPBUtil::checkString($var, True); + $this->etag = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/DeleteRecognizerRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/DeleteRecognizerRequest.php new file mode 100644 index 000000000000..fa3564d85019 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/DeleteRecognizerRequest.php @@ -0,0 +1,205 @@ +google.cloud.speech.v2.DeleteRecognizerRequest + */ +class DeleteRecognizerRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the Recognizer to delete. + * Format: `projects/{project}/locations/{location}/recognizers/{recognizer}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * If set, validate the request and preview the deleted Recognizer, but do not + * actually delete it. + * + * Generated from protobuf field bool validate_only = 2; + */ + protected $validate_only = false; + /** + * If set to true, and the Recognizer is not found, the request will succeed + * and be a no-op (no Operation is recorded in this case). + * + * Generated from protobuf field bool allow_missing = 4; + */ + protected $allow_missing = false; + /** + * This checksum is computed by the server based on the value of other + * fields. This may be sent on update, undelete, and delete requests to ensure + * the client has an up-to-date value before proceeding. + * + * Generated from protobuf field string etag = 3; + */ + protected $etag = ''; + + /** + * @param string $name Required. The name of the Recognizer to delete. + * Format: `projects/{project}/locations/{location}/recognizers/{recognizer}` + * Please see {@see SpeechClient::recognizerName()} for help formatting this field. + * + * @return \Google\Cloud\Speech\V2\DeleteRecognizerRequest + * + * @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 Recognizer to delete. + * Format: `projects/{project}/locations/{location}/recognizers/{recognizer}` + * @type bool $validate_only + * If set, validate the request and preview the deleted Recognizer, but do not + * actually delete it. + * @type bool $allow_missing + * If set to true, and the Recognizer is not found, the request will succeed + * and be a no-op (no Operation is recorded in this case). + * @type string $etag + * This checksum is computed by the server based on the value of other + * fields. This may be sent on update, undelete, and delete requests to ensure + * the client has an up-to-date value before proceeding. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the Recognizer to delete. + * Format: `projects/{project}/locations/{location}/recognizers/{recognizer}` + * + * 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 Recognizer to delete. + * Format: `projects/{project}/locations/{location}/recognizers/{recognizer}` + * + * 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, validate the request and preview the deleted Recognizer, but do not + * actually delete it. + * + * Generated from protobuf field bool validate_only = 2; + * @return bool + */ + public function getValidateOnly() + { + return $this->validate_only; + } + + /** + * If set, validate the request and preview the deleted Recognizer, but do not + * actually delete it. + * + * Generated from protobuf field bool validate_only = 2; + * @param bool $var + * @return $this + */ + public function setValidateOnly($var) + { + GPBUtil::checkBool($var); + $this->validate_only = $var; + + return $this; + } + + /** + * If set to true, and the Recognizer is not found, the request will succeed + * and be a no-op (no Operation is recorded in this case). + * + * Generated from protobuf field bool allow_missing = 4; + * @return bool + */ + public function getAllowMissing() + { + return $this->allow_missing; + } + + /** + * If set to true, and the Recognizer is not found, the request will succeed + * and be a no-op (no Operation is recorded in this case). + * + * Generated from protobuf field bool allow_missing = 4; + * @param bool $var + * @return $this + */ + public function setAllowMissing($var) + { + GPBUtil::checkBool($var); + $this->allow_missing = $var; + + return $this; + } + + /** + * This checksum is computed by the server based on the value of other + * fields. This may be sent on update, undelete, and delete requests to ensure + * the client has an up-to-date value before proceeding. + * + * Generated from protobuf field string etag = 3; + * @return string + */ + public function getEtag() + { + return $this->etag; + } + + /** + * This checksum is computed by the server based on the value of other + * fields. This may be sent on update, undelete, and delete requests to ensure + * the client has an up-to-date value before proceeding. + * + * Generated from protobuf field string etag = 3; + * @param string $var + * @return $this + */ + public function setEtag($var) + { + GPBUtil::checkString($var, True); + $this->etag = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/DenoiserConfig.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/DenoiserConfig.php new file mode 100644 index 000000000000..7c384f363d6e --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/DenoiserConfig.php @@ -0,0 +1,118 @@ +google.cloud.speech.v2.DenoiserConfig + */ +class DenoiserConfig extends \Google\Protobuf\Internal\Message +{ + /** + * Denoise audio before sending to the transcription model. + * + * Generated from protobuf field bool denoise_audio = 1; + */ + protected $denoise_audio = false; + /** + * Signal-to-Noise Ratio (SNR) threshold for the denoiser. Here SNR means the + * loudness of the speech signal. Audio with an SNR below this threshold, + * meaning the speech is too quiet, will be prevented from being sent to the + * transcription model. + * If snr_threshold=0, no filtering will be applied. + * + * Generated from protobuf field float snr_threshold = 2; + */ + protected $snr_threshold = 0.0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type bool $denoise_audio + * Denoise audio before sending to the transcription model. + * @type float $snr_threshold + * Signal-to-Noise Ratio (SNR) threshold for the denoiser. Here SNR means the + * loudness of the speech signal. Audio with an SNR below this threshold, + * meaning the speech is too quiet, will be prevented from being sent to the + * transcription model. + * If snr_threshold=0, no filtering will be applied. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Denoise audio before sending to the transcription model. + * + * Generated from protobuf field bool denoise_audio = 1; + * @return bool + */ + public function getDenoiseAudio() + { + return $this->denoise_audio; + } + + /** + * Denoise audio before sending to the transcription model. + * + * Generated from protobuf field bool denoise_audio = 1; + * @param bool $var + * @return $this + */ + public function setDenoiseAudio($var) + { + GPBUtil::checkBool($var); + $this->denoise_audio = $var; + + return $this; + } + + /** + * Signal-to-Noise Ratio (SNR) threshold for the denoiser. Here SNR means the + * loudness of the speech signal. Audio with an SNR below this threshold, + * meaning the speech is too quiet, will be prevented from being sent to the + * transcription model. + * If snr_threshold=0, no filtering will be applied. + * + * Generated from protobuf field float snr_threshold = 2; + * @return float + */ + public function getSnrThreshold() + { + return $this->snr_threshold; + } + + /** + * Signal-to-Noise Ratio (SNR) threshold for the denoiser. Here SNR means the + * loudness of the speech signal. Audio with an SNR below this threshold, + * meaning the speech is too quiet, will be prevented from being sent to the + * transcription model. + * If snr_threshold=0, no filtering will be applied. + * + * Generated from protobuf field float snr_threshold = 2; + * @param float $var + * @return $this + */ + public function setSnrThreshold($var) + { + GPBUtil::checkFloat($var); + $this->snr_threshold = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ExplicitDecodingConfig.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ExplicitDecodingConfig.php new file mode 100644 index 000000000000..9eccc86ac02b --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ExplicitDecodingConfig.php @@ -0,0 +1,167 @@ +google.cloud.speech.v2.ExplicitDecodingConfig + */ +class ExplicitDecodingConfig extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Encoding of the audio data sent for recognition. + * + * Generated from protobuf field .google.cloud.speech.v2.ExplicitDecodingConfig.AudioEncoding encoding = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $encoding = 0; + /** + * Optional. Sample rate in Hertz of the audio data sent for recognition. + * Valid values are: 8000-48000, and 16000 is optimal. For best results, set + * the sampling rate of the audio source to 16000 Hz. If that's not possible, + * use the native sample rate of the audio source (instead of resampling). + * Note that this field is marked as OPTIONAL for backward compatibility + * reasons. It is (and has always been) effectively REQUIRED. + * + * Generated from protobuf field int32 sample_rate_hertz = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $sample_rate_hertz = 0; + /** + * Optional. Number of channels present in the audio data sent for + * recognition. Note that this field is marked as OPTIONAL for backward + * compatibility reasons. It is (and has always been) effectively REQUIRED. + * The maximum allowed value is 8. + * + * Generated from protobuf field int32 audio_channel_count = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $audio_channel_count = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $encoding + * Required. Encoding of the audio data sent for recognition. + * @type int $sample_rate_hertz + * Optional. Sample rate in Hertz of the audio data sent for recognition. + * Valid values are: 8000-48000, and 16000 is optimal. For best results, set + * the sampling rate of the audio source to 16000 Hz. If that's not possible, + * use the native sample rate of the audio source (instead of resampling). + * Note that this field is marked as OPTIONAL for backward compatibility + * reasons. It is (and has always been) effectively REQUIRED. + * @type int $audio_channel_count + * Optional. Number of channels present in the audio data sent for + * recognition. Note that this field is marked as OPTIONAL for backward + * compatibility reasons. It is (and has always been) effectively REQUIRED. + * The maximum allowed value is 8. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Required. Encoding of the audio data sent for recognition. + * + * Generated from protobuf field .google.cloud.speech.v2.ExplicitDecodingConfig.AudioEncoding encoding = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return int + */ + public function getEncoding() + { + return $this->encoding; + } + + /** + * Required. Encoding of the audio data sent for recognition. + * + * Generated from protobuf field .google.cloud.speech.v2.ExplicitDecodingConfig.AudioEncoding encoding = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param int $var + * @return $this + */ + public function setEncoding($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Speech\V2\ExplicitDecodingConfig\AudioEncoding::class); + $this->encoding = $var; + + return $this; + } + + /** + * Optional. Sample rate in Hertz of the audio data sent for recognition. + * Valid values are: 8000-48000, and 16000 is optimal. For best results, set + * the sampling rate of the audio source to 16000 Hz. If that's not possible, + * use the native sample rate of the audio source (instead of resampling). + * Note that this field is marked as OPTIONAL for backward compatibility + * reasons. It is (and has always been) effectively REQUIRED. + * + * Generated from protobuf field int32 sample_rate_hertz = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return int + */ + public function getSampleRateHertz() + { + return $this->sample_rate_hertz; + } + + /** + * Optional. Sample rate in Hertz of the audio data sent for recognition. + * Valid values are: 8000-48000, and 16000 is optimal. For best results, set + * the sampling rate of the audio source to 16000 Hz. If that's not possible, + * use the native sample rate of the audio source (instead of resampling). + * Note that this field is marked as OPTIONAL for backward compatibility + * reasons. It is (and has always been) effectively REQUIRED. + * + * Generated from protobuf field int32 sample_rate_hertz = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @param int $var + * @return $this + */ + public function setSampleRateHertz($var) + { + GPBUtil::checkInt32($var); + $this->sample_rate_hertz = $var; + + return $this; + } + + /** + * Optional. Number of channels present in the audio data sent for + * recognition. Note that this field is marked as OPTIONAL for backward + * compatibility reasons. It is (and has always been) effectively REQUIRED. + * The maximum allowed value is 8. + * + * Generated from protobuf field int32 audio_channel_count = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return int + */ + public function getAudioChannelCount() + { + return $this->audio_channel_count; + } + + /** + * Optional. Number of channels present in the audio data sent for + * recognition. Note that this field is marked as OPTIONAL for backward + * compatibility reasons. It is (and has always been) effectively REQUIRED. + * The maximum allowed value is 8. + * + * Generated from protobuf field int32 audio_channel_count = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @param int $var + * @return $this + */ + public function setAudioChannelCount($var) + { + GPBUtil::checkInt32($var); + $this->audio_channel_count = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ExplicitDecodingConfig/AudioEncoding.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ExplicitDecodingConfig/AudioEncoding.php new file mode 100644 index 000000000000..48bc6ce0950c --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ExplicitDecodingConfig/AudioEncoding.php @@ -0,0 +1,131 @@ +google.cloud.speech.v2.ExplicitDecodingConfig.AudioEncoding + */ +class AudioEncoding +{ + /** + * Default value. This value is unused. + * + * Generated from protobuf enum AUDIO_ENCODING_UNSPECIFIED = 0; + */ + const AUDIO_ENCODING_UNSPECIFIED = 0; + /** + * Headerless 16-bit signed little-endian PCM samples. + * + * Generated from protobuf enum LINEAR16 = 1; + */ + const LINEAR16 = 1; + /** + * Headerless 8-bit companded mulaw samples. + * + * Generated from protobuf enum MULAW = 2; + */ + const MULAW = 2; + /** + * Headerless 8-bit companded alaw samples. + * + * Generated from protobuf enum ALAW = 3; + */ + const ALAW = 3; + /** + * AMR frames with an rfc4867.5 header. + * + * Generated from protobuf enum AMR = 4; + */ + const AMR = 4; + /** + * AMR-WB frames with an rfc4867.5 header. + * + * Generated from protobuf enum AMR_WB = 5; + */ + const AMR_WB = 5; + /** + * FLAC frames in the "native FLAC" container format. + * + * Generated from protobuf enum FLAC = 6; + */ + const FLAC = 6; + /** + * MPEG audio frames with optional (ignored) ID3 metadata. + * + * Generated from protobuf enum MP3 = 7; + */ + const MP3 = 7; + /** + * Opus audio frames in an Ogg container. + * + * Generated from protobuf enum OGG_OPUS = 8; + */ + const OGG_OPUS = 8; + /** + * Opus audio frames in a WebM container. + * + * Generated from protobuf enum WEBM_OPUS = 9; + */ + const WEBM_OPUS = 9; + /** + * AAC audio frames in an MP4 container. + * + * Generated from protobuf enum MP4_AAC = 10; + */ + const MP4_AAC = 10; + /** + * AAC audio frames in an M4A container. + * + * Generated from protobuf enum M4A_AAC = 11; + */ + const M4A_AAC = 11; + /** + * AAC audio frames in an MOV container. + * + * Generated from protobuf enum MOV_AAC = 12; + */ + const MOV_AAC = 12; + + private static $valueToName = [ + self::AUDIO_ENCODING_UNSPECIFIED => 'AUDIO_ENCODING_UNSPECIFIED', + self::LINEAR16 => 'LINEAR16', + self::MULAW => 'MULAW', + self::ALAW => 'ALAW', + self::AMR => 'AMR', + self::AMR_WB => 'AMR_WB', + self::FLAC => 'FLAC', + self::MP3 => 'MP3', + self::OGG_OPUS => 'OGG_OPUS', + self::WEBM_OPUS => 'WEBM_OPUS', + self::MP4_AAC => 'MP4_AAC', + self::M4A_AAC => 'M4A_AAC', + self::MOV_AAC => 'MOV_AAC', + ]; + + 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/Speech/v2/proto/src/Google/Cloud/Speech/V2/GcsOutputConfig.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/GcsOutputConfig.php new file mode 100644 index 000000000000..25fa8b2bd1d9 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/GcsOutputConfig.php @@ -0,0 +1,71 @@ +google.cloud.speech.v2.GcsOutputConfig + */ +class GcsOutputConfig extends \Google\Protobuf\Internal\Message +{ + /** + * The Cloud Storage URI prefix with which recognition results will be + * written. + * + * Generated from protobuf field string uri = 1; + */ + protected $uri = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $uri + * The Cloud Storage URI prefix with which recognition results will be + * written. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * The Cloud Storage URI prefix with which recognition results will be + * written. + * + * Generated from protobuf field string uri = 1; + * @return string + */ + public function getUri() + { + return $this->uri; + } + + /** + * The Cloud Storage URI prefix with which recognition results will be + * written. + * + * 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; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/GetConfigRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/GetConfigRequest.php new file mode 100644 index 000000000000..c5f17826a4f9 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/GetConfigRequest.php @@ -0,0 +1,92 @@ +google.cloud.speech.v2.GetConfigRequest + */ +class GetConfigRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the config to retrieve. There is exactly one config + * resource per project per location. The expected format is + * `projects/{project}/locations/{location}/config`. + * + * 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 config to retrieve. There is exactly one config + * resource per project per location. The expected format is + * `projects/{project}/locations/{location}/config`. Please see + * {@see SpeechClient::configName()} for help formatting this field. + * + * @return \Google\Cloud\Speech\V2\GetConfigRequest + * + * @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 config to retrieve. There is exactly one config + * resource per project per location. The expected format is + * `projects/{project}/locations/{location}/config`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the config to retrieve. There is exactly one config + * resource per project per location. The expected format is + * `projects/{project}/locations/{location}/config`. + * + * 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 config to retrieve. There is exactly one config + * resource per project per location. The expected format is + * `projects/{project}/locations/{location}/config`. + * + * 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/Speech/v2/proto/src/Google/Cloud/Speech/V2/GetCustomClassRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/GetCustomClassRequest.php new file mode 100644 index 000000000000..08f98671cf7a --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/GetCustomClassRequest.php @@ -0,0 +1,87 @@ +google.cloud.speech.v2.GetCustomClassRequest + */ +class GetCustomClassRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the CustomClass to retrieve. The expected format is + * `projects/{project}/locations/{location}/customClasses/{custom_class}`. + * + * 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 CustomClass to retrieve. The expected format is + * `projects/{project}/locations/{location}/customClasses/{custom_class}`. Please see + * {@see SpeechClient::customClassName()} for help formatting this field. + * + * @return \Google\Cloud\Speech\V2\GetCustomClassRequest + * + * @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 CustomClass to retrieve. The expected format is + * `projects/{project}/locations/{location}/customClasses/{custom_class}`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the CustomClass to retrieve. The expected format is + * `projects/{project}/locations/{location}/customClasses/{custom_class}`. + * + * 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 CustomClass to retrieve. The expected format is + * `projects/{project}/locations/{location}/customClasses/{custom_class}`. + * + * 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/Speech/v2/proto/src/Google/Cloud/Speech/V2/GetPhraseSetRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/GetPhraseSetRequest.php new file mode 100644 index 000000000000..c9026b85bc8d --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/GetPhraseSetRequest.php @@ -0,0 +1,87 @@ +google.cloud.speech.v2.GetPhraseSetRequest + */ +class GetPhraseSetRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the PhraseSet to retrieve. The expected format is + * `projects/{project}/locations/{location}/phraseSets/{phrase_set}`. + * + * 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 PhraseSet to retrieve. The expected format is + * `projects/{project}/locations/{location}/phraseSets/{phrase_set}`. Please see + * {@see SpeechClient::phraseSetName()} for help formatting this field. + * + * @return \Google\Cloud\Speech\V2\GetPhraseSetRequest + * + * @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 PhraseSet to retrieve. The expected format is + * `projects/{project}/locations/{location}/phraseSets/{phrase_set}`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the PhraseSet to retrieve. The expected format is + * `projects/{project}/locations/{location}/phraseSets/{phrase_set}`. + * + * 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 PhraseSet to retrieve. The expected format is + * `projects/{project}/locations/{location}/phraseSets/{phrase_set}`. + * + * 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/Speech/v2/proto/src/Google/Cloud/Speech/V2/GetRecognizerRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/GetRecognizerRequest.php new file mode 100644 index 000000000000..1354b86ebb1f --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/GetRecognizerRequest.php @@ -0,0 +1,87 @@ +google.cloud.speech.v2.GetRecognizerRequest + */ +class GetRecognizerRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the Recognizer to retrieve. The expected format is + * `projects/{project}/locations/{location}/recognizers/{recognizer}`. + * + * 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 Recognizer to retrieve. The expected format is + * `projects/{project}/locations/{location}/recognizers/{recognizer}`. Please see + * {@see SpeechClient::recognizerName()} for help formatting this field. + * + * @return \Google\Cloud\Speech\V2\GetRecognizerRequest + * + * @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 Recognizer to retrieve. The expected format is + * `projects/{project}/locations/{location}/recognizers/{recognizer}`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the Recognizer to retrieve. The expected format is + * `projects/{project}/locations/{location}/recognizers/{recognizer}`. + * + * 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 Recognizer to retrieve. The expected format is + * `projects/{project}/locations/{location}/recognizers/{recognizer}`. + * + * 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/Speech/v2/proto/src/Google/Cloud/Speech/V2/InlineOutputConfig.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/InlineOutputConfig.php new file mode 100644 index 000000000000..a938828e68d7 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/InlineOutputConfig.php @@ -0,0 +1,33 @@ +google.cloud.speech.v2.InlineOutputConfig + */ +class InlineOutputConfig extends \Google\Protobuf\Internal\Message +{ + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/InlineResult.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/InlineResult.php new file mode 100644 index 000000000000..54e5635ac508 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/InlineResult.php @@ -0,0 +1,153 @@ +google.cloud.speech.v2.InlineResult + */ +class InlineResult extends \Google\Protobuf\Internal\Message +{ + /** + * The transcript for the audio file. + * + * Generated from protobuf field .google.cloud.speech.v2.BatchRecognizeResults transcript = 1; + */ + protected $transcript = null; + /** + * The transcript for the audio file as VTT formatted captions. This is + * populated only when `VTT` output is requested. + * + * Generated from protobuf field string vtt_captions = 2; + */ + protected $vtt_captions = ''; + /** + * The transcript for the audio file as SRT formatted captions. This is + * populated only when `SRT` output is requested. + * + * Generated from protobuf field string srt_captions = 3; + */ + protected $srt_captions = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Speech\V2\BatchRecognizeResults $transcript + * The transcript for the audio file. + * @type string $vtt_captions + * The transcript for the audio file as VTT formatted captions. This is + * populated only when `VTT` output is requested. + * @type string $srt_captions + * The transcript for the audio file as SRT formatted captions. This is + * populated only when `SRT` output is requested. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * The transcript for the audio file. + * + * Generated from protobuf field .google.cloud.speech.v2.BatchRecognizeResults transcript = 1; + * @return \Google\Cloud\Speech\V2\BatchRecognizeResults|null + */ + public function getTranscript() + { + return $this->transcript; + } + + public function hasTranscript() + { + return isset($this->transcript); + } + + public function clearTranscript() + { + unset($this->transcript); + } + + /** + * The transcript for the audio file. + * + * Generated from protobuf field .google.cloud.speech.v2.BatchRecognizeResults transcript = 1; + * @param \Google\Cloud\Speech\V2\BatchRecognizeResults $var + * @return $this + */ + public function setTranscript($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\BatchRecognizeResults::class); + $this->transcript = $var; + + return $this; + } + + /** + * The transcript for the audio file as VTT formatted captions. This is + * populated only when `VTT` output is requested. + * + * Generated from protobuf field string vtt_captions = 2; + * @return string + */ + public function getVttCaptions() + { + return $this->vtt_captions; + } + + /** + * The transcript for the audio file as VTT formatted captions. This is + * populated only when `VTT` output is requested. + * + * Generated from protobuf field string vtt_captions = 2; + * @param string $var + * @return $this + */ + public function setVttCaptions($var) + { + GPBUtil::checkString($var, True); + $this->vtt_captions = $var; + + return $this; + } + + /** + * The transcript for the audio file as SRT formatted captions. This is + * populated only when `SRT` output is requested. + * + * Generated from protobuf field string srt_captions = 3; + * @return string + */ + public function getSrtCaptions() + { + return $this->srt_captions; + } + + /** + * The transcript for the audio file as SRT formatted captions. This is + * populated only when `SRT` output is requested. + * + * Generated from protobuf field string srt_captions = 3; + * @param string $var + * @return $this + */ + public function setSrtCaptions($var) + { + GPBUtil::checkString($var, True); + $this->srt_captions = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/LanguageMetadata.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/LanguageMetadata.php new file mode 100644 index 000000000000..4b4e79d1cf4b --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/LanguageMetadata.php @@ -0,0 +1,68 @@ +google.cloud.speech.v2.LanguageMetadata + */ +class LanguageMetadata extends \Google\Protobuf\Internal\Message +{ + /** + * Map of locale (language code) -> models + * + * Generated from protobuf field map models = 1; + */ + private $models; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array|\Google\Protobuf\Internal\MapField $models + * Map of locale (language code) -> models + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\LocationsMetadata::initOnce(); + parent::__construct($data); + } + + /** + * Map of locale (language code) -> models + * + * Generated from protobuf field map models = 1; + * @return \Google\Protobuf\Internal\MapField + */ + public function getModels() + { + return $this->models; + } + + /** + * Map of locale (language code) -> models + * + * Generated from protobuf field map models = 1; + * @param array|\Google\Protobuf\Internal\MapField $var + * @return $this + */ + public function setModels($var) + { + $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Speech\V2\ModelMetadata::class); + $this->models = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListCustomClassesRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListCustomClassesRequest.php new file mode 100644 index 000000000000..4cb52ef136a0 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListCustomClassesRequest.php @@ -0,0 +1,221 @@ +google.cloud.speech.v2.ListCustomClassesRequest + */ +class ListCustomClassesRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The project and location of CustomClass resources to list. The + * expected format is `projects/{project}/locations/{location}`. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Number of results per requests. A valid page_size ranges from 0 to 100 + * inclusive. If the page_size is zero or unspecified, a page size of 5 will + * be chosen. If the page size exceeds 100, it will be coerced down to 100. + * Note that a call might return fewer results than the requested page size. + * + * Generated from protobuf field int32 page_size = 2; + */ + protected $page_size = 0; + /** + * A page token, received from a previous + * [ListCustomClasses][google.cloud.speech.v2.Speech.ListCustomClasses] call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * [ListCustomClasses][google.cloud.speech.v2.Speech.ListCustomClasses] must + * match the call that provided the page token. + * + * Generated from protobuf field string page_token = 3; + */ + protected $page_token = ''; + /** + * Whether, or not, to show resources that have been deleted. + * + * Generated from protobuf field bool show_deleted = 4; + */ + protected $show_deleted = false; + + /** + * @param string $parent Required. The project and location of CustomClass resources to list. The + * expected format is `projects/{project}/locations/{location}`. Please see + * {@see SpeechClient::locationName()} for help formatting this field. + * + * @return \Google\Cloud\Speech\V2\ListCustomClassesRequest + * + * @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 CustomClass resources to list. The + * expected format is `projects/{project}/locations/{location}`. + * @type int $page_size + * Number of results per requests. A valid page_size ranges from 0 to 100 + * inclusive. If the page_size is zero or unspecified, a page size of 5 will + * be chosen. If the page size exceeds 100, it will be coerced down to 100. + * Note that a call might return fewer results than the requested page size. + * @type string $page_token + * A page token, received from a previous + * [ListCustomClasses][google.cloud.speech.v2.Speech.ListCustomClasses] call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * [ListCustomClasses][google.cloud.speech.v2.Speech.ListCustomClasses] must + * match the call that provided the page token. + * @type bool $show_deleted + * Whether, or not, to show resources that have been deleted. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Required. The project and location of CustomClass resources to list. The + * expected format is `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 of CustomClass resources to list. The + * expected format is `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; + } + + /** + * Number of results per requests. A valid page_size ranges from 0 to 100 + * inclusive. If the page_size is zero or unspecified, a page size of 5 will + * be chosen. If the page size exceeds 100, it will be coerced down to 100. + * Note that a call might return fewer results than the requested page size. + * + * Generated from protobuf field int32 page_size = 2; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * Number of results per requests. A valid page_size ranges from 0 to 100 + * inclusive. If the page_size is zero or unspecified, a page size of 5 will + * be chosen. If the page size exceeds 100, it will be coerced down to 100. + * Note that a call might return fewer results than the requested 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; + } + + /** + * A page token, received from a previous + * [ListCustomClasses][google.cloud.speech.v2.Speech.ListCustomClasses] call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * [ListCustomClasses][google.cloud.speech.v2.Speech.ListCustomClasses] 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 + * [ListCustomClasses][google.cloud.speech.v2.Speech.ListCustomClasses] call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * [ListCustomClasses][google.cloud.speech.v2.Speech.ListCustomClasses] 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; + } + + /** + * Whether, or not, to show resources that have been deleted. + * + * Generated from protobuf field bool show_deleted = 4; + * @return bool + */ + public function getShowDeleted() + { + return $this->show_deleted; + } + + /** + * Whether, or not, to show resources that have been deleted. + * + * Generated from protobuf field bool show_deleted = 4; + * @param bool $var + * @return $this + */ + public function setShowDeleted($var) + { + GPBUtil::checkBool($var); + $this->show_deleted = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListCustomClassesResponse.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListCustomClassesResponse.php new file mode 100644 index 000000000000..77814cc3dd35 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListCustomClassesResponse.php @@ -0,0 +1,114 @@ +google.cloud.speech.v2.ListCustomClassesResponse + */ +class ListCustomClassesResponse extends \Google\Protobuf\Internal\Message +{ + /** + * The list of requested CustomClasses. + * + * Generated from protobuf field repeated .google.cloud.speech.v2.CustomClass custom_classes = 1; + */ + private $custom_classes; + /** + * A token, which can be sent as + * [page_token][google.cloud.speech.v2.ListCustomClassesRequest.page_token] to + * retrieve the next page. If this field is omitted, there are no subsequent + * pages. This token expires after 72 hours. + * + * 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 \Google\Cloud\Speech\V2\CustomClass[] $custom_classes + * The list of requested CustomClasses. + * @type string $next_page_token + * A token, which can be sent as + * [page_token][google.cloud.speech.v2.ListCustomClassesRequest.page_token] to + * retrieve the next page. If this field is omitted, there are no subsequent + * pages. This token expires after 72 hours. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * The list of requested CustomClasses. + * + * Generated from protobuf field repeated .google.cloud.speech.v2.CustomClass custom_classes = 1; + * @return RepeatedField<\Google\Cloud\Speech\V2\CustomClass> + */ + public function getCustomClasses() + { + return $this->custom_classes; + } + + /** + * The list of requested CustomClasses. + * + * Generated from protobuf field repeated .google.cloud.speech.v2.CustomClass custom_classes = 1; + * @param \Google\Cloud\Speech\V2\CustomClass[] $var + * @return $this + */ + public function setCustomClasses($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Speech\V2\CustomClass::class); + $this->custom_classes = $arr; + + return $this; + } + + /** + * A token, which can be sent as + * [page_token][google.cloud.speech.v2.ListCustomClassesRequest.page_token] to + * retrieve the next page. If this field is omitted, there are no subsequent + * pages. This token expires after 72 hours. + * + * 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][google.cloud.speech.v2.ListCustomClassesRequest.page_token] to + * retrieve the next page. If this field is omitted, there are no subsequent + * pages. This token expires after 72 hours. + * + * 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/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListPhraseSetsRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListPhraseSetsRequest.php new file mode 100644 index 000000000000..56b81259bf6c --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListPhraseSetsRequest.php @@ -0,0 +1,217 @@ +google.cloud.speech.v2.ListPhraseSetsRequest + */ +class ListPhraseSetsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The project and location of PhraseSet resources to list. The + * expected format is `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 PhraseSets to return. The service may return fewer + * than this value. If unspecified, at most 5 PhraseSets will be returned. + * The maximum value is 100; values above 100 will be coerced to 100. + * + * Generated from protobuf field int32 page_size = 2; + */ + protected $page_size = 0; + /** + * A page token, received from a previous + * [ListPhraseSets][google.cloud.speech.v2.Speech.ListPhraseSets] call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * [ListPhraseSets][google.cloud.speech.v2.Speech.ListPhraseSets] must match + * the call that provided the page token. + * + * Generated from protobuf field string page_token = 3; + */ + protected $page_token = ''; + /** + * Whether, or not, to show resources that have been deleted. + * + * Generated from protobuf field bool show_deleted = 4; + */ + protected $show_deleted = false; + + /** + * @param string $parent Required. The project and location of PhraseSet resources to list. The + * expected format is `projects/{project}/locations/{location}`. Please see + * {@see SpeechClient::locationName()} for help formatting this field. + * + * @return \Google\Cloud\Speech\V2\ListPhraseSetsRequest + * + * @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 PhraseSet resources to list. The + * expected format is `projects/{project}/locations/{location}`. + * @type int $page_size + * The maximum number of PhraseSets to return. The service may return fewer + * than this value. If unspecified, at most 5 PhraseSets will be returned. + * The maximum value is 100; values above 100 will be coerced to 100. + * @type string $page_token + * A page token, received from a previous + * [ListPhraseSets][google.cloud.speech.v2.Speech.ListPhraseSets] call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * [ListPhraseSets][google.cloud.speech.v2.Speech.ListPhraseSets] must match + * the call that provided the page token. + * @type bool $show_deleted + * Whether, or not, to show resources that have been deleted. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Required. The project and location of PhraseSet resources to list. The + * expected format is `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 of PhraseSet resources to list. The + * expected format is `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 PhraseSets to return. The service may return fewer + * than this value. If unspecified, at most 5 PhraseSets will be returned. + * The maximum value is 100; values above 100 will be coerced to 100. + * + * Generated from protobuf field int32 page_size = 2; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of PhraseSets to return. The service may return fewer + * than this value. If unspecified, at most 5 PhraseSets will be returned. + * The maximum value is 100; values above 100 will be coerced 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; + } + + /** + * A page token, received from a previous + * [ListPhraseSets][google.cloud.speech.v2.Speech.ListPhraseSets] call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * [ListPhraseSets][google.cloud.speech.v2.Speech.ListPhraseSets] 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 + * [ListPhraseSets][google.cloud.speech.v2.Speech.ListPhraseSets] call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * [ListPhraseSets][google.cloud.speech.v2.Speech.ListPhraseSets] 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; + } + + /** + * Whether, or not, to show resources that have been deleted. + * + * Generated from protobuf field bool show_deleted = 4; + * @return bool + */ + public function getShowDeleted() + { + return $this->show_deleted; + } + + /** + * Whether, or not, to show resources that have been deleted. + * + * Generated from protobuf field bool show_deleted = 4; + * @param bool $var + * @return $this + */ + public function setShowDeleted($var) + { + GPBUtil::checkBool($var); + $this->show_deleted = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListPhraseSetsResponse.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListPhraseSetsResponse.php new file mode 100644 index 000000000000..7a088dc8f8c9 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListPhraseSetsResponse.php @@ -0,0 +1,114 @@ +google.cloud.speech.v2.ListPhraseSetsResponse + */ +class ListPhraseSetsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * The list of requested PhraseSets. + * + * Generated from protobuf field repeated .google.cloud.speech.v2.PhraseSet phrase_sets = 1; + */ + private $phrase_sets; + /** + * A token, which can be sent as + * [page_token][google.cloud.speech.v2.ListPhraseSetsRequest.page_token] to + * retrieve the next page. If this field is omitted, there are no subsequent + * pages. This token expires after 72 hours. + * + * 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 \Google\Cloud\Speech\V2\PhraseSet[] $phrase_sets + * The list of requested PhraseSets. + * @type string $next_page_token + * A token, which can be sent as + * [page_token][google.cloud.speech.v2.ListPhraseSetsRequest.page_token] to + * retrieve the next page. If this field is omitted, there are no subsequent + * pages. This token expires after 72 hours. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * The list of requested PhraseSets. + * + * Generated from protobuf field repeated .google.cloud.speech.v2.PhraseSet phrase_sets = 1; + * @return RepeatedField<\Google\Cloud\Speech\V2\PhraseSet> + */ + public function getPhraseSets() + { + return $this->phrase_sets; + } + + /** + * The list of requested PhraseSets. + * + * Generated from protobuf field repeated .google.cloud.speech.v2.PhraseSet phrase_sets = 1; + * @param \Google\Cloud\Speech\V2\PhraseSet[] $var + * @return $this + */ + public function setPhraseSets($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Speech\V2\PhraseSet::class); + $this->phrase_sets = $arr; + + return $this; + } + + /** + * A token, which can be sent as + * [page_token][google.cloud.speech.v2.ListPhraseSetsRequest.page_token] to + * retrieve the next page. If this field is omitted, there are no subsequent + * pages. This token expires after 72 hours. + * + * 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][google.cloud.speech.v2.ListPhraseSetsRequest.page_token] to + * retrieve the next page. If this field is omitted, there are no subsequent + * pages. This token expires after 72 hours. + * + * 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/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListRecognizersRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListRecognizersRequest.php new file mode 100644 index 000000000000..c3f35333b9ec --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListRecognizersRequest.php @@ -0,0 +1,217 @@ +google.cloud.speech.v2.ListRecognizersRequest + */ +class ListRecognizersRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The project and location of Recognizers to list. The expected + * format is `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 Recognizers to return. The service may return fewer + * than this value. If unspecified, at most 5 Recognizers will be returned. + * The maximum value is 100; values above 100 will be coerced to 100. + * + * Generated from protobuf field int32 page_size = 2; + */ + protected $page_size = 0; + /** + * A page token, received from a previous + * [ListRecognizers][google.cloud.speech.v2.Speech.ListRecognizers] call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * [ListRecognizers][google.cloud.speech.v2.Speech.ListRecognizers] must match + * the call that provided the page token. + * + * Generated from protobuf field string page_token = 3; + */ + protected $page_token = ''; + /** + * Whether, or not, to show resources that have been deleted. + * + * Generated from protobuf field bool show_deleted = 4; + */ + protected $show_deleted = false; + + /** + * @param string $parent Required. The project and location of Recognizers to list. The expected + * format is `projects/{project}/locations/{location}`. Please see + * {@see SpeechClient::locationName()} for help formatting this field. + * + * @return \Google\Cloud\Speech\V2\ListRecognizersRequest + * + * @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 Recognizers to list. The expected + * format is `projects/{project}/locations/{location}`. + * @type int $page_size + * The maximum number of Recognizers to return. The service may return fewer + * than this value. If unspecified, at most 5 Recognizers will be returned. + * The maximum value is 100; values above 100 will be coerced to 100. + * @type string $page_token + * A page token, received from a previous + * [ListRecognizers][google.cloud.speech.v2.Speech.ListRecognizers] call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * [ListRecognizers][google.cloud.speech.v2.Speech.ListRecognizers] must match + * the call that provided the page token. + * @type bool $show_deleted + * Whether, or not, to show resources that have been deleted. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Required. The project and location of Recognizers to list. The expected + * format is `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 of Recognizers to list. The expected + * format is `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 Recognizers to return. The service may return fewer + * than this value. If unspecified, at most 5 Recognizers will be returned. + * The maximum value is 100; values above 100 will be coerced to 100. + * + * Generated from protobuf field int32 page_size = 2; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of Recognizers to return. The service may return fewer + * than this value. If unspecified, at most 5 Recognizers will be returned. + * The maximum value is 100; values above 100 will be coerced 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; + } + + /** + * A page token, received from a previous + * [ListRecognizers][google.cloud.speech.v2.Speech.ListRecognizers] call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * [ListRecognizers][google.cloud.speech.v2.Speech.ListRecognizers] 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 + * [ListRecognizers][google.cloud.speech.v2.Speech.ListRecognizers] call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * [ListRecognizers][google.cloud.speech.v2.Speech.ListRecognizers] 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; + } + + /** + * Whether, or not, to show resources that have been deleted. + * + * Generated from protobuf field bool show_deleted = 4; + * @return bool + */ + public function getShowDeleted() + { + return $this->show_deleted; + } + + /** + * Whether, or not, to show resources that have been deleted. + * + * Generated from protobuf field bool show_deleted = 4; + * @param bool $var + * @return $this + */ + public function setShowDeleted($var) + { + GPBUtil::checkBool($var); + $this->show_deleted = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListRecognizersResponse.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListRecognizersResponse.php new file mode 100644 index 000000000000..18e076469df5 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListRecognizersResponse.php @@ -0,0 +1,114 @@ +google.cloud.speech.v2.ListRecognizersResponse + */ +class ListRecognizersResponse extends \Google\Protobuf\Internal\Message +{ + /** + * The list of requested Recognizers. + * + * Generated from protobuf field repeated .google.cloud.speech.v2.Recognizer recognizers = 1; + */ + private $recognizers; + /** + * A token, which can be sent as + * [page_token][google.cloud.speech.v2.ListRecognizersRequest.page_token] to + * retrieve the next page. If this field is omitted, there are no subsequent + * pages. This token expires after 72 hours. + * + * 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 \Google\Cloud\Speech\V2\Recognizer[] $recognizers + * The list of requested Recognizers. + * @type string $next_page_token + * A token, which can be sent as + * [page_token][google.cloud.speech.v2.ListRecognizersRequest.page_token] to + * retrieve the next page. If this field is omitted, there are no subsequent + * pages. This token expires after 72 hours. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * The list of requested Recognizers. + * + * Generated from protobuf field repeated .google.cloud.speech.v2.Recognizer recognizers = 1; + * @return RepeatedField<\Google\Cloud\Speech\V2\Recognizer> + */ + public function getRecognizers() + { + return $this->recognizers; + } + + /** + * The list of requested Recognizers. + * + * Generated from protobuf field repeated .google.cloud.speech.v2.Recognizer recognizers = 1; + * @param \Google\Cloud\Speech\V2\Recognizer[] $var + * @return $this + */ + public function setRecognizers($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Speech\V2\Recognizer::class); + $this->recognizers = $arr; + + return $this; + } + + /** + * A token, which can be sent as + * [page_token][google.cloud.speech.v2.ListRecognizersRequest.page_token] to + * retrieve the next page. If this field is omitted, there are no subsequent + * pages. This token expires after 72 hours. + * + * 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][google.cloud.speech.v2.ListRecognizersRequest.page_token] to + * retrieve the next page. If this field is omitted, there are no subsequent + * pages. This token expires after 72 hours. + * + * 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/Speech/v2/proto/src/Google/Cloud/Speech/V2/LocationsMetadata.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/LocationsMetadata.php new file mode 100644 index 000000000000..cd051e7e965f --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/LocationsMetadata.php @@ -0,0 +1,126 @@ +google.cloud.speech.v2.LocationsMetadata + */ +class LocationsMetadata extends \Google\Protobuf\Internal\Message +{ + /** + * Information about available locales, models, and features represented in + * the hierarchical structure of locales -> models -> features + * + * Generated from protobuf field .google.cloud.speech.v2.LanguageMetadata languages = 1; + */ + protected $languages = null; + /** + * Information about access metadata for the region and given project. + * + * Generated from protobuf field .google.cloud.speech.v2.AccessMetadata access_metadata = 2; + */ + protected $access_metadata = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Speech\V2\LanguageMetadata $languages + * Information about available locales, models, and features represented in + * the hierarchical structure of locales -> models -> features + * @type \Google\Cloud\Speech\V2\AccessMetadata $access_metadata + * Information about access metadata for the region and given project. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\LocationsMetadata::initOnce(); + parent::__construct($data); + } + + /** + * Information about available locales, models, and features represented in + * the hierarchical structure of locales -> models -> features + * + * Generated from protobuf field .google.cloud.speech.v2.LanguageMetadata languages = 1; + * @return \Google\Cloud\Speech\V2\LanguageMetadata|null + */ + public function getLanguages() + { + return $this->languages; + } + + public function hasLanguages() + { + return isset($this->languages); + } + + public function clearLanguages() + { + unset($this->languages); + } + + /** + * Information about available locales, models, and features represented in + * the hierarchical structure of locales -> models -> features + * + * Generated from protobuf field .google.cloud.speech.v2.LanguageMetadata languages = 1; + * @param \Google\Cloud\Speech\V2\LanguageMetadata $var + * @return $this + */ + public function setLanguages($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\LanguageMetadata::class); + $this->languages = $var; + + return $this; + } + + /** + * Information about access metadata for the region and given project. + * + * Generated from protobuf field .google.cloud.speech.v2.AccessMetadata access_metadata = 2; + * @return \Google\Cloud\Speech\V2\AccessMetadata|null + */ + public function getAccessMetadata() + { + return $this->access_metadata; + } + + public function hasAccessMetadata() + { + return isset($this->access_metadata); + } + + public function clearAccessMetadata() + { + unset($this->access_metadata); + } + + /** + * Information about access metadata for the region and given project. + * + * Generated from protobuf field .google.cloud.speech.v2.AccessMetadata access_metadata = 2; + * @param \Google\Cloud\Speech\V2\AccessMetadata $var + * @return $this + */ + public function setAccessMetadata($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\AccessMetadata::class); + $this->access_metadata = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ModelFeature.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ModelFeature.php new file mode 100644 index 000000000000..d64773c74d73 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ModelFeature.php @@ -0,0 +1,102 @@ +google.cloud.speech.v2.ModelFeature + */ +class ModelFeature extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the feature (Note: the feature can be `recognizer`) + * + * Generated from protobuf field string feature = 1; + */ + protected $feature = ''; + /** + * The release state of the feature + * + * Generated from protobuf field string release_state = 2; + */ + protected $release_state = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $feature + * The name of the feature (Note: the feature can be `recognizer`) + * @type string $release_state + * The release state of the feature + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\LocationsMetadata::initOnce(); + parent::__construct($data); + } + + /** + * The name of the feature (Note: the feature can be `recognizer`) + * + * Generated from protobuf field string feature = 1; + * @return string + */ + public function getFeature() + { + return $this->feature; + } + + /** + * The name of the feature (Note: the feature can be `recognizer`) + * + * Generated from protobuf field string feature = 1; + * @param string $var + * @return $this + */ + public function setFeature($var) + { + GPBUtil::checkString($var, True); + $this->feature = $var; + + return $this; + } + + /** + * The release state of the feature + * + * Generated from protobuf field string release_state = 2; + * @return string + */ + public function getReleaseState() + { + return $this->release_state; + } + + /** + * The release state of the feature + * + * Generated from protobuf field string release_state = 2; + * @param string $var + * @return $this + */ + public function setReleaseState($var) + { + GPBUtil::checkString($var, True); + $this->release_state = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ModelFeatures.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ModelFeatures.php new file mode 100644 index 000000000000..b001870bbf47 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ModelFeatures.php @@ -0,0 +1,67 @@ +google.cloud.speech.v2.ModelFeatures + */ +class ModelFeatures extends \Google\Protobuf\Internal\Message +{ + /** + * Repeated field that contains all features of the model + * + * Generated from protobuf field repeated .google.cloud.speech.v2.ModelFeature model_feature = 1; + */ + private $model_feature; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Speech\V2\ModelFeature[] $model_feature + * Repeated field that contains all features of the model + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\LocationsMetadata::initOnce(); + parent::__construct($data); + } + + /** + * Repeated field that contains all features of the model + * + * Generated from protobuf field repeated .google.cloud.speech.v2.ModelFeature model_feature = 1; + * @return RepeatedField<\Google\Cloud\Speech\V2\ModelFeature> + */ + public function getModelFeature() + { + return $this->model_feature; + } + + /** + * Repeated field that contains all features of the model + * + * Generated from protobuf field repeated .google.cloud.speech.v2.ModelFeature model_feature = 1; + * @param \Google\Cloud\Speech\V2\ModelFeature[] $var + * @return $this + */ + public function setModelFeature($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Speech\V2\ModelFeature::class); + $this->model_feature = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ModelMetadata.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ModelMetadata.php new file mode 100644 index 000000000000..e111a6f3f5c1 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ModelMetadata.php @@ -0,0 +1,68 @@ +google.cloud.speech.v2.ModelMetadata + */ +class ModelMetadata extends \Google\Protobuf\Internal\Message +{ + /** + * Map of the model name -> features of that model + * + * Generated from protobuf field map model_features = 1; + */ + private $model_features; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array|\Google\Protobuf\Internal\MapField $model_features + * Map of the model name -> features of that model + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\LocationsMetadata::initOnce(); + parent::__construct($data); + } + + /** + * Map of the model name -> features of that model + * + * Generated from protobuf field map model_features = 1; + * @return \Google\Protobuf\Internal\MapField + */ + public function getModelFeatures() + { + return $this->model_features; + } + + /** + * Map of the model name -> features of that model + * + * Generated from protobuf field map model_features = 1; + * @param array|\Google\Protobuf\Internal\MapField $var + * @return $this + */ + public function setModelFeatures($var) + { + $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Speech\V2\ModelFeatures::class); + $this->model_features = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/NativeOutputFileFormatConfig.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/NativeOutputFileFormatConfig.php new file mode 100644 index 000000000000..3eec04a2e96b --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/NativeOutputFileFormatConfig.php @@ -0,0 +1,33 @@ +google.cloud.speech.v2.NativeOutputFileFormatConfig + */ +class NativeOutputFileFormatConfig extends \Google\Protobuf\Internal\Message +{ + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/OperationMetadata.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/OperationMetadata.php new file mode 100644 index 000000000000..39511aee9bce --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/OperationMetadata.php @@ -0,0 +1,841 @@ +google.cloud.speech.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; + */ + protected $create_time = null; + /** + * The time the operation was last updated. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 2; + */ + protected $update_time = null; + /** + * The resource path for the target of the operation. + * + * Generated from protobuf field string resource = 3; + */ + protected $resource = ''; + /** + * The method that triggered the operation. + * + * Generated from protobuf field string method = 4; + */ + protected $method = ''; + /** + * The [KMS key + * name](https://cloud.google.com/kms/docs/resource-hierarchy#keys) with which + * the content of the Operation is encrypted. The expected format is + * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. + * + * Generated from protobuf field string kms_key_name = 6 [(.google.api.resource_reference) = { + */ + protected $kms_key_name = ''; + /** + * The [KMS key version + * name](https://cloud.google.com/kms/docs/resource-hierarchy#key_versions) + * with which content of the Operation is encrypted. The expected format is + * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}/cryptoKeyVersions/{crypto_key_version}`. + * + * Generated from protobuf field string kms_key_version_name = 7 [(.google.api.resource_reference) = { + */ + protected $kms_key_version_name = ''; + /** + * The percent progress of the Operation. Values can range from 0-100. If the + * value is 100, then the operation is finished. + * + * Generated from protobuf field int32 progress_percent = 22; + */ + protected $progress_percent = 0; + protected $request; + protected $metadata; + + /** + * 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 $update_time + * The time the operation was last updated. + * @type string $resource + * The resource path for the target of the operation. + * @type string $method + * The method that triggered the operation. + * @type string $kms_key_name + * The [KMS key + * name](https://cloud.google.com/kms/docs/resource-hierarchy#keys) with which + * the content of the Operation is encrypted. The expected format is + * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. + * @type string $kms_key_version_name + * The [KMS key version + * name](https://cloud.google.com/kms/docs/resource-hierarchy#key_versions) + * with which content of the Operation is encrypted. The expected format is + * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}/cryptoKeyVersions/{crypto_key_version}`. + * @type \Google\Cloud\Speech\V2\BatchRecognizeRequest $batch_recognize_request + * The BatchRecognizeRequest that spawned the Operation. + * @type \Google\Cloud\Speech\V2\CreateRecognizerRequest $create_recognizer_request + * The CreateRecognizerRequest that spawned the Operation. + * @type \Google\Cloud\Speech\V2\UpdateRecognizerRequest $update_recognizer_request + * The UpdateRecognizerRequest that spawned the Operation. + * @type \Google\Cloud\Speech\V2\DeleteRecognizerRequest $delete_recognizer_request + * The DeleteRecognizerRequest that spawned the Operation. + * @type \Google\Cloud\Speech\V2\UndeleteRecognizerRequest $undelete_recognizer_request + * The UndeleteRecognizerRequest that spawned the Operation. + * @type \Google\Cloud\Speech\V2\CreateCustomClassRequest $create_custom_class_request + * The CreateCustomClassRequest that spawned the Operation. + * @type \Google\Cloud\Speech\V2\UpdateCustomClassRequest $update_custom_class_request + * The UpdateCustomClassRequest that spawned the Operation. + * @type \Google\Cloud\Speech\V2\DeleteCustomClassRequest $delete_custom_class_request + * The DeleteCustomClassRequest that spawned the Operation. + * @type \Google\Cloud\Speech\V2\UndeleteCustomClassRequest $undelete_custom_class_request + * The UndeleteCustomClassRequest that spawned the Operation. + * @type \Google\Cloud\Speech\V2\CreatePhraseSetRequest $create_phrase_set_request + * The CreatePhraseSetRequest that spawned the Operation. + * @type \Google\Cloud\Speech\V2\UpdatePhraseSetRequest $update_phrase_set_request + * The UpdatePhraseSetRequest that spawned the Operation. + * @type \Google\Cloud\Speech\V2\DeletePhraseSetRequest $delete_phrase_set_request + * The DeletePhraseSetRequest that spawned the Operation. + * @type \Google\Cloud\Speech\V2\UndeletePhraseSetRequest $undelete_phrase_set_request + * The UndeletePhraseSetRequest that spawned the Operation. + * @type \Google\Cloud\Speech\V2\UpdateConfigRequest $update_config_request + * The UpdateConfigRequest that spawned the Operation. + * @type int $progress_percent + * The percent progress of the Operation. Values can range from 0-100. If the + * value is 100, then the operation is finished. + * @type \Google\Cloud\Speech\V2\BatchRecognizeMetadata $batch_recognize_metadata + * Metadata specific to the BatchRecognize method. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::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 was last updated. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 2; + * @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); + } + + /** + * The time the operation was last updated. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 2; + * @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 resource path for the target of the operation. + * + * Generated from protobuf field string resource = 3; + * @return string + */ + public function getResource() + { + return $this->resource; + } + + /** + * The resource path for the target of the operation. + * + * Generated from protobuf field string resource = 3; + * @param string $var + * @return $this + */ + public function setResource($var) + { + GPBUtil::checkString($var, True); + $this->resource = $var; + + return $this; + } + + /** + * The method that triggered the operation. + * + * Generated from protobuf field string method = 4; + * @return string + */ + public function getMethod() + { + return $this->method; + } + + /** + * The method that triggered the operation. + * + * Generated from protobuf field string method = 4; + * @param string $var + * @return $this + */ + public function setMethod($var) + { + GPBUtil::checkString($var, True); + $this->method = $var; + + return $this; + } + + /** + * The [KMS key + * name](https://cloud.google.com/kms/docs/resource-hierarchy#keys) with which + * the content of the Operation is encrypted. The expected format is + * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. + * + * Generated from protobuf field string kms_key_name = 6 [(.google.api.resource_reference) = { + * @return string + */ + public function getKmsKeyName() + { + return $this->kms_key_name; + } + + /** + * The [KMS key + * name](https://cloud.google.com/kms/docs/resource-hierarchy#keys) with which + * the content of the Operation is encrypted. The expected format is + * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. + * + * Generated from protobuf field string kms_key_name = 6 [(.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setKmsKeyName($var) + { + GPBUtil::checkString($var, True); + $this->kms_key_name = $var; + + return $this; + } + + /** + * The [KMS key version + * name](https://cloud.google.com/kms/docs/resource-hierarchy#key_versions) + * with which content of the Operation is encrypted. The expected format is + * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}/cryptoKeyVersions/{crypto_key_version}`. + * + * Generated from protobuf field string kms_key_version_name = 7 [(.google.api.resource_reference) = { + * @return string + */ + public function getKmsKeyVersionName() + { + return $this->kms_key_version_name; + } + + /** + * The [KMS key version + * name](https://cloud.google.com/kms/docs/resource-hierarchy#key_versions) + * with which content of the Operation is encrypted. The expected format is + * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}/cryptoKeyVersions/{crypto_key_version}`. + * + * Generated from protobuf field string kms_key_version_name = 7 [(.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setKmsKeyVersionName($var) + { + GPBUtil::checkString($var, True); + $this->kms_key_version_name = $var; + + return $this; + } + + /** + * The BatchRecognizeRequest that spawned the Operation. + * + * Generated from protobuf field .google.cloud.speech.v2.BatchRecognizeRequest batch_recognize_request = 8; + * @return \Google\Cloud\Speech\V2\BatchRecognizeRequest|null + */ + public function getBatchRecognizeRequest() + { + return $this->readOneof(8); + } + + public function hasBatchRecognizeRequest() + { + return $this->hasOneof(8); + } + + /** + * The BatchRecognizeRequest that spawned the Operation. + * + * Generated from protobuf field .google.cloud.speech.v2.BatchRecognizeRequest batch_recognize_request = 8; + * @param \Google\Cloud\Speech\V2\BatchRecognizeRequest $var + * @return $this + */ + public function setBatchRecognizeRequest($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\BatchRecognizeRequest::class); + $this->writeOneof(8, $var); + + return $this; + } + + /** + * The CreateRecognizerRequest that spawned the Operation. + * + * Generated from protobuf field .google.cloud.speech.v2.CreateRecognizerRequest create_recognizer_request = 9; + * @return \Google\Cloud\Speech\V2\CreateRecognizerRequest|null + */ + public function getCreateRecognizerRequest() + { + return $this->readOneof(9); + } + + public function hasCreateRecognizerRequest() + { + return $this->hasOneof(9); + } + + /** + * The CreateRecognizerRequest that spawned the Operation. + * + * Generated from protobuf field .google.cloud.speech.v2.CreateRecognizerRequest create_recognizer_request = 9; + * @param \Google\Cloud\Speech\V2\CreateRecognizerRequest $var + * @return $this + */ + public function setCreateRecognizerRequest($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\CreateRecognizerRequest::class); + $this->writeOneof(9, $var); + + return $this; + } + + /** + * The UpdateRecognizerRequest that spawned the Operation. + * + * Generated from protobuf field .google.cloud.speech.v2.UpdateRecognizerRequest update_recognizer_request = 10; + * @return \Google\Cloud\Speech\V2\UpdateRecognizerRequest|null + */ + public function getUpdateRecognizerRequest() + { + return $this->readOneof(10); + } + + public function hasUpdateRecognizerRequest() + { + return $this->hasOneof(10); + } + + /** + * The UpdateRecognizerRequest that spawned the Operation. + * + * Generated from protobuf field .google.cloud.speech.v2.UpdateRecognizerRequest update_recognizer_request = 10; + * @param \Google\Cloud\Speech\V2\UpdateRecognizerRequest $var + * @return $this + */ + public function setUpdateRecognizerRequest($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\UpdateRecognizerRequest::class); + $this->writeOneof(10, $var); + + return $this; + } + + /** + * The DeleteRecognizerRequest that spawned the Operation. + * + * Generated from protobuf field .google.cloud.speech.v2.DeleteRecognizerRequest delete_recognizer_request = 11; + * @return \Google\Cloud\Speech\V2\DeleteRecognizerRequest|null + */ + public function getDeleteRecognizerRequest() + { + return $this->readOneof(11); + } + + public function hasDeleteRecognizerRequest() + { + return $this->hasOneof(11); + } + + /** + * The DeleteRecognizerRequest that spawned the Operation. + * + * Generated from protobuf field .google.cloud.speech.v2.DeleteRecognizerRequest delete_recognizer_request = 11; + * @param \Google\Cloud\Speech\V2\DeleteRecognizerRequest $var + * @return $this + */ + public function setDeleteRecognizerRequest($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\DeleteRecognizerRequest::class); + $this->writeOneof(11, $var); + + return $this; + } + + /** + * The UndeleteRecognizerRequest that spawned the Operation. + * + * Generated from protobuf field .google.cloud.speech.v2.UndeleteRecognizerRequest undelete_recognizer_request = 12; + * @return \Google\Cloud\Speech\V2\UndeleteRecognizerRequest|null + */ + public function getUndeleteRecognizerRequest() + { + return $this->readOneof(12); + } + + public function hasUndeleteRecognizerRequest() + { + return $this->hasOneof(12); + } + + /** + * The UndeleteRecognizerRequest that spawned the Operation. + * + * Generated from protobuf field .google.cloud.speech.v2.UndeleteRecognizerRequest undelete_recognizer_request = 12; + * @param \Google\Cloud\Speech\V2\UndeleteRecognizerRequest $var + * @return $this + */ + public function setUndeleteRecognizerRequest($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\UndeleteRecognizerRequest::class); + $this->writeOneof(12, $var); + + return $this; + } + + /** + * The CreateCustomClassRequest that spawned the Operation. + * + * Generated from protobuf field .google.cloud.speech.v2.CreateCustomClassRequest create_custom_class_request = 13; + * @return \Google\Cloud\Speech\V2\CreateCustomClassRequest|null + */ + public function getCreateCustomClassRequest() + { + return $this->readOneof(13); + } + + public function hasCreateCustomClassRequest() + { + return $this->hasOneof(13); + } + + /** + * The CreateCustomClassRequest that spawned the Operation. + * + * Generated from protobuf field .google.cloud.speech.v2.CreateCustomClassRequest create_custom_class_request = 13; + * @param \Google\Cloud\Speech\V2\CreateCustomClassRequest $var + * @return $this + */ + public function setCreateCustomClassRequest($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\CreateCustomClassRequest::class); + $this->writeOneof(13, $var); + + return $this; + } + + /** + * The UpdateCustomClassRequest that spawned the Operation. + * + * Generated from protobuf field .google.cloud.speech.v2.UpdateCustomClassRequest update_custom_class_request = 14; + * @return \Google\Cloud\Speech\V2\UpdateCustomClassRequest|null + */ + public function getUpdateCustomClassRequest() + { + return $this->readOneof(14); + } + + public function hasUpdateCustomClassRequest() + { + return $this->hasOneof(14); + } + + /** + * The UpdateCustomClassRequest that spawned the Operation. + * + * Generated from protobuf field .google.cloud.speech.v2.UpdateCustomClassRequest update_custom_class_request = 14; + * @param \Google\Cloud\Speech\V2\UpdateCustomClassRequest $var + * @return $this + */ + public function setUpdateCustomClassRequest($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\UpdateCustomClassRequest::class); + $this->writeOneof(14, $var); + + return $this; + } + + /** + * The DeleteCustomClassRequest that spawned the Operation. + * + * Generated from protobuf field .google.cloud.speech.v2.DeleteCustomClassRequest delete_custom_class_request = 15; + * @return \Google\Cloud\Speech\V2\DeleteCustomClassRequest|null + */ + public function getDeleteCustomClassRequest() + { + return $this->readOneof(15); + } + + public function hasDeleteCustomClassRequest() + { + return $this->hasOneof(15); + } + + /** + * The DeleteCustomClassRequest that spawned the Operation. + * + * Generated from protobuf field .google.cloud.speech.v2.DeleteCustomClassRequest delete_custom_class_request = 15; + * @param \Google\Cloud\Speech\V2\DeleteCustomClassRequest $var + * @return $this + */ + public function setDeleteCustomClassRequest($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\DeleteCustomClassRequest::class); + $this->writeOneof(15, $var); + + return $this; + } + + /** + * The UndeleteCustomClassRequest that spawned the Operation. + * + * Generated from protobuf field .google.cloud.speech.v2.UndeleteCustomClassRequest undelete_custom_class_request = 16; + * @return \Google\Cloud\Speech\V2\UndeleteCustomClassRequest|null + */ + public function getUndeleteCustomClassRequest() + { + return $this->readOneof(16); + } + + public function hasUndeleteCustomClassRequest() + { + return $this->hasOneof(16); + } + + /** + * The UndeleteCustomClassRequest that spawned the Operation. + * + * Generated from protobuf field .google.cloud.speech.v2.UndeleteCustomClassRequest undelete_custom_class_request = 16; + * @param \Google\Cloud\Speech\V2\UndeleteCustomClassRequest $var + * @return $this + */ + public function setUndeleteCustomClassRequest($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\UndeleteCustomClassRequest::class); + $this->writeOneof(16, $var); + + return $this; + } + + /** + * The CreatePhraseSetRequest that spawned the Operation. + * + * Generated from protobuf field .google.cloud.speech.v2.CreatePhraseSetRequest create_phrase_set_request = 17; + * @return \Google\Cloud\Speech\V2\CreatePhraseSetRequest|null + */ + public function getCreatePhraseSetRequest() + { + return $this->readOneof(17); + } + + public function hasCreatePhraseSetRequest() + { + return $this->hasOneof(17); + } + + /** + * The CreatePhraseSetRequest that spawned the Operation. + * + * Generated from protobuf field .google.cloud.speech.v2.CreatePhraseSetRequest create_phrase_set_request = 17; + * @param \Google\Cloud\Speech\V2\CreatePhraseSetRequest $var + * @return $this + */ + public function setCreatePhraseSetRequest($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\CreatePhraseSetRequest::class); + $this->writeOneof(17, $var); + + return $this; + } + + /** + * The UpdatePhraseSetRequest that spawned the Operation. + * + * Generated from protobuf field .google.cloud.speech.v2.UpdatePhraseSetRequest update_phrase_set_request = 18; + * @return \Google\Cloud\Speech\V2\UpdatePhraseSetRequest|null + */ + public function getUpdatePhraseSetRequest() + { + return $this->readOneof(18); + } + + public function hasUpdatePhraseSetRequest() + { + return $this->hasOneof(18); + } + + /** + * The UpdatePhraseSetRequest that spawned the Operation. + * + * Generated from protobuf field .google.cloud.speech.v2.UpdatePhraseSetRequest update_phrase_set_request = 18; + * @param \Google\Cloud\Speech\V2\UpdatePhraseSetRequest $var + * @return $this + */ + public function setUpdatePhraseSetRequest($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\UpdatePhraseSetRequest::class); + $this->writeOneof(18, $var); + + return $this; + } + + /** + * The DeletePhraseSetRequest that spawned the Operation. + * + * Generated from protobuf field .google.cloud.speech.v2.DeletePhraseSetRequest delete_phrase_set_request = 19; + * @return \Google\Cloud\Speech\V2\DeletePhraseSetRequest|null + */ + public function getDeletePhraseSetRequest() + { + return $this->readOneof(19); + } + + public function hasDeletePhraseSetRequest() + { + return $this->hasOneof(19); + } + + /** + * The DeletePhraseSetRequest that spawned the Operation. + * + * Generated from protobuf field .google.cloud.speech.v2.DeletePhraseSetRequest delete_phrase_set_request = 19; + * @param \Google\Cloud\Speech\V2\DeletePhraseSetRequest $var + * @return $this + */ + public function setDeletePhraseSetRequest($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\DeletePhraseSetRequest::class); + $this->writeOneof(19, $var); + + return $this; + } + + /** + * The UndeletePhraseSetRequest that spawned the Operation. + * + * Generated from protobuf field .google.cloud.speech.v2.UndeletePhraseSetRequest undelete_phrase_set_request = 20; + * @return \Google\Cloud\Speech\V2\UndeletePhraseSetRequest|null + */ + public function getUndeletePhraseSetRequest() + { + return $this->readOneof(20); + } + + public function hasUndeletePhraseSetRequest() + { + return $this->hasOneof(20); + } + + /** + * The UndeletePhraseSetRequest that spawned the Operation. + * + * Generated from protobuf field .google.cloud.speech.v2.UndeletePhraseSetRequest undelete_phrase_set_request = 20; + * @param \Google\Cloud\Speech\V2\UndeletePhraseSetRequest $var + * @return $this + */ + public function setUndeletePhraseSetRequest($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\UndeletePhraseSetRequest::class); + $this->writeOneof(20, $var); + + return $this; + } + + /** + * The UpdateConfigRequest that spawned the Operation. + * + * Generated from protobuf field .google.cloud.speech.v2.UpdateConfigRequest update_config_request = 21 [deprecated = true]; + * @return \Google\Cloud\Speech\V2\UpdateConfigRequest|null + * @deprecated + */ + public function getUpdateConfigRequest() + { + if ($this->hasOneof(21)) { + @trigger_error('update_config_request is deprecated.', E_USER_DEPRECATED); + } + return $this->readOneof(21); + } + + public function hasUpdateConfigRequest() + { + if ($this->hasOneof(21)) { + @trigger_error('update_config_request is deprecated.', E_USER_DEPRECATED); + } + return $this->hasOneof(21); + } + + /** + * The UpdateConfigRequest that spawned the Operation. + * + * Generated from protobuf field .google.cloud.speech.v2.UpdateConfigRequest update_config_request = 21 [deprecated = true]; + * @param \Google\Cloud\Speech\V2\UpdateConfigRequest $var + * @return $this + * @deprecated + */ + public function setUpdateConfigRequest($var) + { + @trigger_error('update_config_request is deprecated.', E_USER_DEPRECATED); + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\UpdateConfigRequest::class); + $this->writeOneof(21, $var); + + return $this; + } + + /** + * The percent progress of the Operation. Values can range from 0-100. If the + * value is 100, then the operation is finished. + * + * Generated from protobuf field int32 progress_percent = 22; + * @return int + */ + public function getProgressPercent() + { + return $this->progress_percent; + } + + /** + * The percent progress of the Operation. Values can range from 0-100. If the + * value is 100, then the operation is finished. + * + * Generated from protobuf field int32 progress_percent = 22; + * @param int $var + * @return $this + */ + public function setProgressPercent($var) + { + GPBUtil::checkInt32($var); + $this->progress_percent = $var; + + return $this; + } + + /** + * Metadata specific to the BatchRecognize method. + * + * Generated from protobuf field .google.cloud.speech.v2.BatchRecognizeMetadata batch_recognize_metadata = 23; + * @return \Google\Cloud\Speech\V2\BatchRecognizeMetadata|null + */ + public function getBatchRecognizeMetadata() + { + return $this->readOneof(23); + } + + public function hasBatchRecognizeMetadata() + { + return $this->hasOneof(23); + } + + /** + * Metadata specific to the BatchRecognize method. + * + * Generated from protobuf field .google.cloud.speech.v2.BatchRecognizeMetadata batch_recognize_metadata = 23; + * @param \Google\Cloud\Speech\V2\BatchRecognizeMetadata $var + * @return $this + */ + public function setBatchRecognizeMetadata($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\BatchRecognizeMetadata::class); + $this->writeOneof(23, $var); + + return $this; + } + + /** + * @return string + */ + public function getRequest() + { + return $this->whichOneof("request"); + } + + /** + * @return string + */ + public function getMetadata() + { + return $this->whichOneof("metadata"); + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/OutputFormatConfig.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/OutputFormatConfig.php new file mode 100644 index 000000000000..066ea0a2354d --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/OutputFormatConfig.php @@ -0,0 +1,181 @@ +google.cloud.speech.v2.OutputFormatConfig + */ +class OutputFormatConfig extends \Google\Protobuf\Internal\Message +{ + /** + * Configuration for the native output format. If this field is set or if no + * other output format field is set, then transcripts will be written to the + * sink in the native format. + * + * Generated from protobuf field .google.cloud.speech.v2.NativeOutputFileFormatConfig native = 1; + */ + protected $native = null; + /** + * Configuration for the VTT output format. If this field is set, then + * transcripts will be written to the sink in the VTT format. + * + * Generated from protobuf field .google.cloud.speech.v2.VttOutputFileFormatConfig vtt = 2; + */ + protected $vtt = null; + /** + * Configuration for the SRT output format. If this field is set, then + * transcripts will be written to the sink in the SRT format. + * + * Generated from protobuf field .google.cloud.speech.v2.SrtOutputFileFormatConfig srt = 3; + */ + protected $srt = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Speech\V2\NativeOutputFileFormatConfig $native + * Configuration for the native output format. If this field is set or if no + * other output format field is set, then transcripts will be written to the + * sink in the native format. + * @type \Google\Cloud\Speech\V2\VttOutputFileFormatConfig $vtt + * Configuration for the VTT output format. If this field is set, then + * transcripts will be written to the sink in the VTT format. + * @type \Google\Cloud\Speech\V2\SrtOutputFileFormatConfig $srt + * Configuration for the SRT output format. If this field is set, then + * transcripts will be written to the sink in the SRT format. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Configuration for the native output format. If this field is set or if no + * other output format field is set, then transcripts will be written to the + * sink in the native format. + * + * Generated from protobuf field .google.cloud.speech.v2.NativeOutputFileFormatConfig native = 1; + * @return \Google\Cloud\Speech\V2\NativeOutputFileFormatConfig|null + */ + public function getNative() + { + return $this->native; + } + + public function hasNative() + { + return isset($this->native); + } + + public function clearNative() + { + unset($this->native); + } + + /** + * Configuration for the native output format. If this field is set or if no + * other output format field is set, then transcripts will be written to the + * sink in the native format. + * + * Generated from protobuf field .google.cloud.speech.v2.NativeOutputFileFormatConfig native = 1; + * @param \Google\Cloud\Speech\V2\NativeOutputFileFormatConfig $var + * @return $this + */ + public function setNative($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\NativeOutputFileFormatConfig::class); + $this->native = $var; + + return $this; + } + + /** + * Configuration for the VTT output format. If this field is set, then + * transcripts will be written to the sink in the VTT format. + * + * Generated from protobuf field .google.cloud.speech.v2.VttOutputFileFormatConfig vtt = 2; + * @return \Google\Cloud\Speech\V2\VttOutputFileFormatConfig|null + */ + public function getVtt() + { + return $this->vtt; + } + + public function hasVtt() + { + return isset($this->vtt); + } + + public function clearVtt() + { + unset($this->vtt); + } + + /** + * Configuration for the VTT output format. If this field is set, then + * transcripts will be written to the sink in the VTT format. + * + * Generated from protobuf field .google.cloud.speech.v2.VttOutputFileFormatConfig vtt = 2; + * @param \Google\Cloud\Speech\V2\VttOutputFileFormatConfig $var + * @return $this + */ + public function setVtt($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\VttOutputFileFormatConfig::class); + $this->vtt = $var; + + return $this; + } + + /** + * Configuration for the SRT output format. If this field is set, then + * transcripts will be written to the sink in the SRT format. + * + * Generated from protobuf field .google.cloud.speech.v2.SrtOutputFileFormatConfig srt = 3; + * @return \Google\Cloud\Speech\V2\SrtOutputFileFormatConfig|null + */ + public function getSrt() + { + return $this->srt; + } + + public function hasSrt() + { + return isset($this->srt); + } + + public function clearSrt() + { + unset($this->srt); + } + + /** + * Configuration for the SRT output format. If this field is set, then + * transcripts will be written to the sink in the SRT format. + * + * Generated from protobuf field .google.cloud.speech.v2.SrtOutputFileFormatConfig srt = 3; + * @param \Google\Cloud\Speech\V2\SrtOutputFileFormatConfig $var + * @return $this + */ + public function setSrt($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\SrtOutputFileFormatConfig::class); + $this->srt = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/PhraseSet.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/PhraseSet.php new file mode 100644 index 000000000000..e6f62ab78c9c --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/PhraseSet.php @@ -0,0 +1,657 @@ +google.cloud.speech.v2.PhraseSet + */ +class PhraseSet extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. Identifier. The resource name of the PhraseSet. + * Format: `projects/{project}/locations/{location}/phraseSets/{phrase_set}`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IDENTIFIER]; + */ + protected $name = ''; + /** + * Output only. System-assigned unique identifier for the PhraseSet. + * + * Generated from protobuf field string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $uid = ''; + /** + * A list of word and phrases. + * + * Generated from protobuf field repeated .google.cloud.speech.v2.PhraseSet.Phrase phrases = 3; + */ + private $phrases; + /** + * Hint Boost. Positive value will increase the probability that a specific + * phrase will be recognized over other similar sounding phrases. The higher + * the boost, the higher the chance of false positive recognition as well. + * Valid `boost` values are between 0 (exclusive) and 20. We recommend using a + * binary search approach to finding the optimal value for your use case as + * well as adding phrases both with and without boost to your requests. + * + * Generated from protobuf field float boost = 4; + */ + protected $boost = 0.0; + /** + * User-settable, human-readable name for the PhraseSet. Must be 63 + * characters or less. + * + * Generated from protobuf field string display_name = 5; + */ + protected $display_name = ''; + /** + * Output only. The PhraseSet lifecycle state. + * + * Generated from protobuf field .google.cloud.speech.v2.PhraseSet.State state = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $state = 0; + /** + * Output only. Creation time. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $create_time = null; + /** + * Output only. The most recent time this resource was modified. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $update_time = null; + /** + * Output only. The time at which this resource was requested for deletion. + * + * Generated from protobuf field .google.protobuf.Timestamp delete_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $delete_time = null; + /** + * Output only. The time at which this resource will be purged. + * + * Generated from protobuf field .google.protobuf.Timestamp expire_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $expire_time = null; + /** + * Allows users to store small amounts of arbitrary data. + * Both the key and the value must be 63 characters or less each. + * At most 100 annotations. + * + * Generated from protobuf field map annotations = 10; + */ + private $annotations; + /** + * Output only. This checksum is computed by the server based on the value of + * other fields. This may be sent on update, undelete, and delete requests to + * ensure 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 = ''; + /** + * Output only. Whether or not this PhraseSet is in the process of being + * updated. + * + * Generated from protobuf field bool reconciling = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $reconciling = false; + /** + * Output only. The [KMS key + * name](https://cloud.google.com/kms/docs/resource-hierarchy#keys) with which + * the PhraseSet is encrypted. The expected format is + * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. + * + * Generated from protobuf field string kms_key_name = 13 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { + */ + protected $kms_key_name = ''; + /** + * Output only. The [KMS key version + * name](https://cloud.google.com/kms/docs/resource-hierarchy#key_versions) + * with which the PhraseSet is encrypted. The expected format is + * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}/cryptoKeyVersions/{crypto_key_version}`. + * + * Generated from protobuf field string kms_key_version_name = 14 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { + */ + protected $kms_key_version_name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Output only. Identifier. The resource name of the PhraseSet. + * Format: `projects/{project}/locations/{location}/phraseSets/{phrase_set}`. + * @type string $uid + * Output only. System-assigned unique identifier for the PhraseSet. + * @type \Google\Cloud\Speech\V2\PhraseSet\Phrase[] $phrases + * A list of word and phrases. + * @type float $boost + * Hint Boost. Positive value will increase the probability that a specific + * phrase will be recognized over other similar sounding phrases. The higher + * the boost, the higher the chance of false positive recognition as well. + * Valid `boost` values are between 0 (exclusive) and 20. We recommend using a + * binary search approach to finding the optimal value for your use case as + * well as adding phrases both with and without boost to your requests. + * @type string $display_name + * User-settable, human-readable name for the PhraseSet. Must be 63 + * characters or less. + * @type int $state + * Output only. The PhraseSet lifecycle state. + * @type \Google\Protobuf\Timestamp $create_time + * Output only. Creation time. + * @type \Google\Protobuf\Timestamp $update_time + * Output only. The most recent time this resource was modified. + * @type \Google\Protobuf\Timestamp $delete_time + * Output only. The time at which this resource was requested for deletion. + * @type \Google\Protobuf\Timestamp $expire_time + * Output only. The time at which this resource will be purged. + * @type array|\Google\Protobuf\Internal\MapField $annotations + * Allows users to store small amounts of arbitrary data. + * Both the key and the value must be 63 characters or less each. + * At most 100 annotations. + * @type string $etag + * Output only. This checksum is computed by the server based on the value of + * other fields. This may be sent on update, undelete, and delete requests to + * ensure the client has an up-to-date value before proceeding. + * @type bool $reconciling + * Output only. Whether or not this PhraseSet is in the process of being + * updated. + * @type string $kms_key_name + * Output only. The [KMS key + * name](https://cloud.google.com/kms/docs/resource-hierarchy#keys) with which + * the PhraseSet is encrypted. The expected format is + * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. + * @type string $kms_key_version_name + * Output only. The [KMS key version + * name](https://cloud.google.com/kms/docs/resource-hierarchy#key_versions) + * with which the PhraseSet is encrypted. The expected format is + * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}/cryptoKeyVersions/{crypto_key_version}`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Output only. Identifier. The resource name of the PhraseSet. + * Format: `projects/{project}/locations/{location}/phraseSets/{phrase_set}`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IDENTIFIER]; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Output only. Identifier. The resource name of the PhraseSet. + * Format: `projects/{project}/locations/{location}/phraseSets/{phrase_set}`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IDENTIFIER]; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Output only. System-assigned unique identifier for the PhraseSet. + * + * Generated from protobuf field string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getUid() + { + return $this->uid; + } + + /** + * Output only. System-assigned unique identifier for the PhraseSet. + * + * 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; + } + + /** + * A list of word and phrases. + * + * Generated from protobuf field repeated .google.cloud.speech.v2.PhraseSet.Phrase phrases = 3; + * @return RepeatedField<\Google\Cloud\Speech\V2\PhraseSet\Phrase> + */ + public function getPhrases() + { + return $this->phrases; + } + + /** + * A list of word and phrases. + * + * Generated from protobuf field repeated .google.cloud.speech.v2.PhraseSet.Phrase phrases = 3; + * @param \Google\Cloud\Speech\V2\PhraseSet\Phrase[] $var + * @return $this + */ + public function setPhrases($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Speech\V2\PhraseSet\Phrase::class); + $this->phrases = $arr; + + return $this; + } + + /** + * Hint Boost. Positive value will increase the probability that a specific + * phrase will be recognized over other similar sounding phrases. The higher + * the boost, the higher the chance of false positive recognition as well. + * Valid `boost` values are between 0 (exclusive) and 20. We recommend using a + * binary search approach to finding the optimal value for your use case as + * well as adding phrases both with and without boost to your requests. + * + * Generated from protobuf field float boost = 4; + * @return float + */ + public function getBoost() + { + return $this->boost; + } + + /** + * Hint Boost. Positive value will increase the probability that a specific + * phrase will be recognized over other similar sounding phrases. The higher + * the boost, the higher the chance of false positive recognition as well. + * Valid `boost` values are between 0 (exclusive) and 20. We recommend using a + * binary search approach to finding the optimal value for your use case as + * well as adding phrases both with and without boost to your requests. + * + * Generated from protobuf field float boost = 4; + * @param float $var + * @return $this + */ + public function setBoost($var) + { + GPBUtil::checkFloat($var); + $this->boost = $var; + + return $this; + } + + /** + * User-settable, human-readable name for the PhraseSet. Must be 63 + * characters or less. + * + * Generated from protobuf field string display_name = 5; + * @return string + */ + public function getDisplayName() + { + return $this->display_name; + } + + /** + * User-settable, human-readable name for the PhraseSet. Must be 63 + * characters or less. + * + * Generated from protobuf field string display_name = 5; + * @param string $var + * @return $this + */ + public function setDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->display_name = $var; + + return $this; + } + + /** + * Output only. The PhraseSet lifecycle state. + * + * Generated from protobuf field .google.cloud.speech.v2.PhraseSet.State state = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getState() + { + return $this->state; + } + + /** + * Output only. The PhraseSet lifecycle state. + * + * Generated from protobuf field .google.cloud.speech.v2.PhraseSet.State state = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setState($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Speech\V2\PhraseSet\State::class); + $this->state = $var; + + return $this; + } + + /** + * Output only. Creation time. + * + * 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. Creation time. + * + * 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. The most recent time this resource was modified. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 7 [(.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 most recent time this resource was modified. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 7 [(.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 time at which this resource was requested for deletion. + * + * Generated from protobuf field .google.protobuf.Timestamp delete_time = 8 [(.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. The time at which this resource was requested for deletion. + * + * Generated from protobuf field .google.protobuf.Timestamp delete_time = 8 [(.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. The time at which this resource will be purged. + * + * Generated from protobuf field .google.protobuf.Timestamp expire_time = 9 [(.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 resource will be purged. + * + * Generated from protobuf field .google.protobuf.Timestamp expire_time = 9 [(.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; + } + + /** + * Allows users to store small amounts of arbitrary data. + * Both the key and the value must be 63 characters or less each. + * At most 100 annotations. + * + * Generated from protobuf field map annotations = 10; + * @return \Google\Protobuf\Internal\MapField + */ + public function getAnnotations() + { + return $this->annotations; + } + + /** + * Allows users to store small amounts of arbitrary data. + * Both the key and the value must be 63 characters or less each. + * At most 100 annotations. + * + * 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; + } + + /** + * Output only. This checksum is computed by the server based on the value of + * other fields. This may be sent on update, undelete, and delete requests to + * ensure 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. This checksum is computed by the server based on the value of + * other fields. This may be sent on update, undelete, and delete requests to + * ensure 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; + } + + /** + * Output only. Whether or not this PhraseSet is in the process of being + * updated. + * + * Generated from protobuf field bool reconciling = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return bool + */ + public function getReconciling() + { + return $this->reconciling; + } + + /** + * Output only. Whether or not this PhraseSet is in the process of being + * updated. + * + * Generated from protobuf field bool reconciling = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param bool $var + * @return $this + */ + public function setReconciling($var) + { + GPBUtil::checkBool($var); + $this->reconciling = $var; + + return $this; + } + + /** + * Output only. The [KMS key + * name](https://cloud.google.com/kms/docs/resource-hierarchy#keys) with which + * the PhraseSet is encrypted. The expected format is + * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. + * + * Generated from protobuf field string kms_key_name = 13 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { + * @return string + */ + public function getKmsKeyName() + { + return $this->kms_key_name; + } + + /** + * Output only. The [KMS key + * name](https://cloud.google.com/kms/docs/resource-hierarchy#keys) with which + * the PhraseSet is encrypted. The expected format is + * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. + * + * Generated from protobuf field string kms_key_name = 13 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setKmsKeyName($var) + { + GPBUtil::checkString($var, True); + $this->kms_key_name = $var; + + return $this; + } + + /** + * Output only. The [KMS key version + * name](https://cloud.google.com/kms/docs/resource-hierarchy#key_versions) + * with which the PhraseSet is encrypted. The expected format is + * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}/cryptoKeyVersions/{crypto_key_version}`. + * + * Generated from protobuf field string kms_key_version_name = 14 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { + * @return string + */ + public function getKmsKeyVersionName() + { + return $this->kms_key_version_name; + } + + /** + * Output only. The [KMS key version + * name](https://cloud.google.com/kms/docs/resource-hierarchy#key_versions) + * with which the PhraseSet is encrypted. The expected format is + * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}/cryptoKeyVersions/{crypto_key_version}`. + * + * Generated from protobuf field string kms_key_version_name = 14 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setKmsKeyVersionName($var) + { + GPBUtil::checkString($var, True); + $this->kms_key_version_name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/PhraseSet/Phrase.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/PhraseSet/Phrase.php new file mode 100644 index 000000000000..e081f239c9a9 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/PhraseSet/Phrase.php @@ -0,0 +1,143 @@ +google.cloud.speech.v2.PhraseSet.Phrase + */ +class Phrase extends \Google\Protobuf\Internal\Message +{ + /** + * The phrase itself. + * + * Generated from protobuf field string value = 1; + */ + protected $value = ''; + /** + * Hint Boost. Overrides the boost set at the phrase set level. + * Positive value will increase the probability that a specific phrase will + * be recognized over other similar sounding phrases. The higher the boost, + * the higher the chance of false positive recognition as well. Negative + * boost values would correspond to anti-biasing. Anti-biasing is not + * enabled, so negative boost values will return an error. Boost values must + * be between 0 and 20. Any values outside that range will return an error. + * We recommend using a binary search approach to finding the optimal value + * for your use case as well as adding phrases both with and without boost + * to your requests. + * + * Generated from protobuf field float boost = 2; + */ + protected $boost = 0.0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $value + * The phrase itself. + * @type float $boost + * Hint Boost. Overrides the boost set at the phrase set level. + * Positive value will increase the probability that a specific phrase will + * be recognized over other similar sounding phrases. The higher the boost, + * the higher the chance of false positive recognition as well. Negative + * boost values would correspond to anti-biasing. Anti-biasing is not + * enabled, so negative boost values will return an error. Boost values must + * be between 0 and 20. Any values outside that range will return an error. + * We recommend using a binary search approach to finding the optimal value + * for your use case as well as adding phrases both with and without boost + * to your requests. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * The phrase itself. + * + * Generated from protobuf field string value = 1; + * @return string + */ + public function getValue() + { + return $this->value; + } + + /** + * The phrase itself. + * + * Generated from protobuf field string value = 1; + * @param string $var + * @return $this + */ + public function setValue($var) + { + GPBUtil::checkString($var, True); + $this->value = $var; + + return $this; + } + + /** + * Hint Boost. Overrides the boost set at the phrase set level. + * Positive value will increase the probability that a specific phrase will + * be recognized over other similar sounding phrases. The higher the boost, + * the higher the chance of false positive recognition as well. Negative + * boost values would correspond to anti-biasing. Anti-biasing is not + * enabled, so negative boost values will return an error. Boost values must + * be between 0 and 20. Any values outside that range will return an error. + * We recommend using a binary search approach to finding the optimal value + * for your use case as well as adding phrases both with and without boost + * to your requests. + * + * Generated from protobuf field float boost = 2; + * @return float + */ + public function getBoost() + { + return $this->boost; + } + + /** + * Hint Boost. Overrides the boost set at the phrase set level. + * Positive value will increase the probability that a specific phrase will + * be recognized over other similar sounding phrases. The higher the boost, + * the higher the chance of false positive recognition as well. Negative + * boost values would correspond to anti-biasing. Anti-biasing is not + * enabled, so negative boost values will return an error. Boost values must + * be between 0 and 20. Any values outside that range will return an error. + * We recommend using a binary search approach to finding the optimal value + * for your use case as well as adding phrases both with and without boost + * to your requests. + * + * Generated from protobuf field float boost = 2; + * @param float $var + * @return $this + */ + public function setBoost($var) + { + GPBUtil::checkFloat($var); + $this->boost = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/PhraseSet/State.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/PhraseSet/State.php new file mode 100644 index 000000000000..d905b2637de1 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/PhraseSet/State.php @@ -0,0 +1,62 @@ +google.cloud.speech.v2.PhraseSet.State + */ +class State +{ + /** + * Unspecified state. This is only used/useful for distinguishing + * unset values. + * + * Generated from protobuf enum STATE_UNSPECIFIED = 0; + */ + const STATE_UNSPECIFIED = 0; + /** + * The normal and active state. + * + * Generated from protobuf enum ACTIVE = 2; + */ + const ACTIVE = 2; + /** + * This PhraseSet has been deleted. + * + * Generated from protobuf enum DELETED = 4; + */ + const DELETED = 4; + + private static $valueToName = [ + self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', + self::ACTIVE => 'ACTIVE', + 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); + } +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognitionConfig.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognitionConfig.php new file mode 100644 index 000000000000..1a832099cb6f --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognitionConfig.php @@ -0,0 +1,487 @@ +google.cloud.speech.v2.RecognitionConfig + */ +class RecognitionConfig extends \Google\Protobuf\Internal\Message +{ + /** + * Optional. Which model to use for recognition requests. Select the model + * best suited to your domain to get best results. + * Guidance for choosing which model to use can be found in the [Transcription + * Models + * Documentation](https://cloud.google.com/speech-to-text/v2/docs/transcription-model) + * and the models supported in each region can be found in the [Table Of + * Supported + * Models](https://cloud.google.com/speech-to-text/v2/docs/speech-to-text-supported-languages). + * + * Generated from protobuf field string model = 9 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $model = ''; + /** + * Optional. The language of the supplied audio as a + * [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) language tag. + * Language tags are normalized to BCP-47 before they are used eg "en-us" + * becomes "en-US". + * Supported languages for each model are listed in the [Table of Supported + * Models](https://cloud.google.com/speech-to-text/v2/docs/speech-to-text-supported-languages). + * If additional languages are provided, recognition result will contain + * recognition in the most likely language detected. The recognition result + * will include the language tag of the language detected in the audio. + * + * Generated from protobuf field repeated string language_codes = 10 [(.google.api.field_behavior) = OPTIONAL]; + */ + private $language_codes; + /** + * Speech recognition features to enable. + * + * Generated from protobuf field .google.cloud.speech.v2.RecognitionFeatures features = 2; + */ + protected $features = null; + /** + * Speech adaptation context that weights recognizer predictions for specific + * words and phrases. + * + * Generated from protobuf field .google.cloud.speech.v2.SpeechAdaptation adaptation = 6; + */ + protected $adaptation = null; + /** + * Optional. Use transcription normalization to automatically replace parts of + * the transcript with phrases of your choosing. For StreamingRecognize, this + * normalization only applies to stable partial transcripts (stability > 0.8) + * and final transcripts. + * + * Generated from protobuf field .google.cloud.speech.v2.TranscriptNormalization transcript_normalization = 11 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $transcript_normalization = null; + /** + * Optional. Optional configuration used to automatically run translation on + * the given audio to the desired language for supported models. + * + * Generated from protobuf field .google.cloud.speech.v2.TranslationConfig translation_config = 15 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $translation_config = null; + /** + * Optional. Optional denoiser config. May not be supported for all models + * and may have no effect. + * + * Generated from protobuf field .google.cloud.speech.v2.DenoiserConfig denoiser_config = 16 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $denoiser_config = null; + protected $decoding_config; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Speech\V2\AutoDetectDecodingConfig $auto_decoding_config + * Automatically detect decoding parameters. + * Preferred for supported formats. + * @type \Google\Cloud\Speech\V2\ExplicitDecodingConfig $explicit_decoding_config + * Explicitly specified decoding parameters. + * Required if using headerless PCM audio (linear16, mulaw, alaw). + * @type string $model + * Optional. Which model to use for recognition requests. Select the model + * best suited to your domain to get best results. + * Guidance for choosing which model to use can be found in the [Transcription + * Models + * Documentation](https://cloud.google.com/speech-to-text/v2/docs/transcription-model) + * and the models supported in each region can be found in the [Table Of + * Supported + * Models](https://cloud.google.com/speech-to-text/v2/docs/speech-to-text-supported-languages). + * @type string[] $language_codes + * Optional. The language of the supplied audio as a + * [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) language tag. + * Language tags are normalized to BCP-47 before they are used eg "en-us" + * becomes "en-US". + * Supported languages for each model are listed in the [Table of Supported + * Models](https://cloud.google.com/speech-to-text/v2/docs/speech-to-text-supported-languages). + * If additional languages are provided, recognition result will contain + * recognition in the most likely language detected. The recognition result + * will include the language tag of the language detected in the audio. + * @type \Google\Cloud\Speech\V2\RecognitionFeatures $features + * Speech recognition features to enable. + * @type \Google\Cloud\Speech\V2\SpeechAdaptation $adaptation + * Speech adaptation context that weights recognizer predictions for specific + * words and phrases. + * @type \Google\Cloud\Speech\V2\TranscriptNormalization $transcript_normalization + * Optional. Use transcription normalization to automatically replace parts of + * the transcript with phrases of your choosing. For StreamingRecognize, this + * normalization only applies to stable partial transcripts (stability > 0.8) + * and final transcripts. + * @type \Google\Cloud\Speech\V2\TranslationConfig $translation_config + * Optional. Optional configuration used to automatically run translation on + * the given audio to the desired language for supported models. + * @type \Google\Cloud\Speech\V2\DenoiserConfig $denoiser_config + * Optional. Optional denoiser config. May not be supported for all models + * and may have no effect. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Automatically detect decoding parameters. + * Preferred for supported formats. + * + * Generated from protobuf field .google.cloud.speech.v2.AutoDetectDecodingConfig auto_decoding_config = 7; + * @return \Google\Cloud\Speech\V2\AutoDetectDecodingConfig|null + */ + public function getAutoDecodingConfig() + { + return $this->readOneof(7); + } + + public function hasAutoDecodingConfig() + { + return $this->hasOneof(7); + } + + /** + * Automatically detect decoding parameters. + * Preferred for supported formats. + * + * Generated from protobuf field .google.cloud.speech.v2.AutoDetectDecodingConfig auto_decoding_config = 7; + * @param \Google\Cloud\Speech\V2\AutoDetectDecodingConfig $var + * @return $this + */ + public function setAutoDecodingConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\AutoDetectDecodingConfig::class); + $this->writeOneof(7, $var); + + return $this; + } + + /** + * Explicitly specified decoding parameters. + * Required if using headerless PCM audio (linear16, mulaw, alaw). + * + * Generated from protobuf field .google.cloud.speech.v2.ExplicitDecodingConfig explicit_decoding_config = 8; + * @return \Google\Cloud\Speech\V2\ExplicitDecodingConfig|null + */ + public function getExplicitDecodingConfig() + { + return $this->readOneof(8); + } + + public function hasExplicitDecodingConfig() + { + return $this->hasOneof(8); + } + + /** + * Explicitly specified decoding parameters. + * Required if using headerless PCM audio (linear16, mulaw, alaw). + * + * Generated from protobuf field .google.cloud.speech.v2.ExplicitDecodingConfig explicit_decoding_config = 8; + * @param \Google\Cloud\Speech\V2\ExplicitDecodingConfig $var + * @return $this + */ + public function setExplicitDecodingConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\ExplicitDecodingConfig::class); + $this->writeOneof(8, $var); + + return $this; + } + + /** + * Optional. Which model to use for recognition requests. Select the model + * best suited to your domain to get best results. + * Guidance for choosing which model to use can be found in the [Transcription + * Models + * Documentation](https://cloud.google.com/speech-to-text/v2/docs/transcription-model) + * and the models supported in each region can be found in the [Table Of + * Supported + * Models](https://cloud.google.com/speech-to-text/v2/docs/speech-to-text-supported-languages). + * + * Generated from protobuf field string model = 9 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getModel() + { + return $this->model; + } + + /** + * Optional. Which model to use for recognition requests. Select the model + * best suited to your domain to get best results. + * Guidance for choosing which model to use can be found in the [Transcription + * Models + * Documentation](https://cloud.google.com/speech-to-text/v2/docs/transcription-model) + * and the models supported in each region can be found in the [Table Of + * Supported + * Models](https://cloud.google.com/speech-to-text/v2/docs/speech-to-text-supported-languages). + * + * Generated from protobuf field string model = 9 [(.google.api.field_behavior) = OPTIONAL]; + * @param string $var + * @return $this + */ + public function setModel($var) + { + GPBUtil::checkString($var, True); + $this->model = $var; + + return $this; + } + + /** + * Optional. The language of the supplied audio as a + * [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) language tag. + * Language tags are normalized to BCP-47 before they are used eg "en-us" + * becomes "en-US". + * Supported languages for each model are listed in the [Table of Supported + * Models](https://cloud.google.com/speech-to-text/v2/docs/speech-to-text-supported-languages). + * If additional languages are provided, recognition result will contain + * recognition in the most likely language detected. The recognition result + * will include the language tag of the language detected in the audio. + * + * Generated from protobuf field repeated string language_codes = 10 [(.google.api.field_behavior) = OPTIONAL]; + * @return RepeatedField + */ + public function getLanguageCodes() + { + return $this->language_codes; + } + + /** + * Optional. The language of the supplied audio as a + * [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) language tag. + * Language tags are normalized to BCP-47 before they are used eg "en-us" + * becomes "en-US". + * Supported languages for each model are listed in the [Table of Supported + * Models](https://cloud.google.com/speech-to-text/v2/docs/speech-to-text-supported-languages). + * If additional languages are provided, recognition result will contain + * recognition in the most likely language detected. The recognition result + * will include the language tag of the language detected in the audio. + * + * Generated from protobuf field repeated string language_codes = 10 [(.google.api.field_behavior) = OPTIONAL]; + * @param string[] $var + * @return $this + */ + public function setLanguageCodes($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->language_codes = $arr; + + return $this; + } + + /** + * Speech recognition features to enable. + * + * Generated from protobuf field .google.cloud.speech.v2.RecognitionFeatures features = 2; + * @return \Google\Cloud\Speech\V2\RecognitionFeatures|null + */ + public function getFeatures() + { + return $this->features; + } + + public function hasFeatures() + { + return isset($this->features); + } + + public function clearFeatures() + { + unset($this->features); + } + + /** + * Speech recognition features to enable. + * + * Generated from protobuf field .google.cloud.speech.v2.RecognitionFeatures features = 2; + * @param \Google\Cloud\Speech\V2\RecognitionFeatures $var + * @return $this + */ + public function setFeatures($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\RecognitionFeatures::class); + $this->features = $var; + + return $this; + } + + /** + * Speech adaptation context that weights recognizer predictions for specific + * words and phrases. + * + * Generated from protobuf field .google.cloud.speech.v2.SpeechAdaptation adaptation = 6; + * @return \Google\Cloud\Speech\V2\SpeechAdaptation|null + */ + public function getAdaptation() + { + return $this->adaptation; + } + + public function hasAdaptation() + { + return isset($this->adaptation); + } + + public function clearAdaptation() + { + unset($this->adaptation); + } + + /** + * Speech adaptation context that weights recognizer predictions for specific + * words and phrases. + * + * Generated from protobuf field .google.cloud.speech.v2.SpeechAdaptation adaptation = 6; + * @param \Google\Cloud\Speech\V2\SpeechAdaptation $var + * @return $this + */ + public function setAdaptation($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\SpeechAdaptation::class); + $this->adaptation = $var; + + return $this; + } + + /** + * Optional. Use transcription normalization to automatically replace parts of + * the transcript with phrases of your choosing. For StreamingRecognize, this + * normalization only applies to stable partial transcripts (stability > 0.8) + * and final transcripts. + * + * Generated from protobuf field .google.cloud.speech.v2.TranscriptNormalization transcript_normalization = 11 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\Speech\V2\TranscriptNormalization|null + */ + public function getTranscriptNormalization() + { + return $this->transcript_normalization; + } + + public function hasTranscriptNormalization() + { + return isset($this->transcript_normalization); + } + + public function clearTranscriptNormalization() + { + unset($this->transcript_normalization); + } + + /** + * Optional. Use transcription normalization to automatically replace parts of + * the transcript with phrases of your choosing. For StreamingRecognize, this + * normalization only applies to stable partial transcripts (stability > 0.8) + * and final transcripts. + * + * Generated from protobuf field .google.cloud.speech.v2.TranscriptNormalization transcript_normalization = 11 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\Speech\V2\TranscriptNormalization $var + * @return $this + */ + public function setTranscriptNormalization($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\TranscriptNormalization::class); + $this->transcript_normalization = $var; + + return $this; + } + + /** + * Optional. Optional configuration used to automatically run translation on + * the given audio to the desired language for supported models. + * + * Generated from protobuf field .google.cloud.speech.v2.TranslationConfig translation_config = 15 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\Speech\V2\TranslationConfig|null + */ + public function getTranslationConfig() + { + return $this->translation_config; + } + + public function hasTranslationConfig() + { + return isset($this->translation_config); + } + + public function clearTranslationConfig() + { + unset($this->translation_config); + } + + /** + * Optional. Optional configuration used to automatically run translation on + * the given audio to the desired language for supported models. + * + * Generated from protobuf field .google.cloud.speech.v2.TranslationConfig translation_config = 15 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\Speech\V2\TranslationConfig $var + * @return $this + */ + public function setTranslationConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\TranslationConfig::class); + $this->translation_config = $var; + + return $this; + } + + /** + * Optional. Optional denoiser config. May not be supported for all models + * and may have no effect. + * + * Generated from protobuf field .google.cloud.speech.v2.DenoiserConfig denoiser_config = 16 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\Speech\V2\DenoiserConfig|null + */ + public function getDenoiserConfig() + { + return $this->denoiser_config; + } + + public function hasDenoiserConfig() + { + return isset($this->denoiser_config); + } + + public function clearDenoiserConfig() + { + unset($this->denoiser_config); + } + + /** + * Optional. Optional denoiser config. May not be supported for all models + * and may have no effect. + * + * Generated from protobuf field .google.cloud.speech.v2.DenoiserConfig denoiser_config = 16 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\Speech\V2\DenoiserConfig $var + * @return $this + */ + public function setDenoiserConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\DenoiserConfig::class); + $this->denoiser_config = $var; + + return $this; + } + + /** + * @return string + */ + public function getDecodingConfig() + { + return $this->whichOneof("decoding_config"); + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognitionFeatures.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognitionFeatures.php new file mode 100644 index 000000000000..f53614654057 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognitionFeatures.php @@ -0,0 +1,473 @@ +google.cloud.speech.v2.RecognitionFeatures + */ +class RecognitionFeatures extends \Google\Protobuf\Internal\Message +{ + /** + * If set to `true`, the server will attempt to filter out profanities, + * replacing all but the initial character in each filtered word with + * asterisks, for instance, "f***". If set to `false` or omitted, profanities + * won't be filtered out. + * + * Generated from protobuf field bool profanity_filter = 1; + */ + protected $profanity_filter = false; + /** + * If `true`, the top result includes a list of words and the start and end + * time offsets (timestamps) for those words. If `false`, no word-level time + * offset information is returned. The default is `false`. + * + * Generated from protobuf field bool enable_word_time_offsets = 2; + */ + protected $enable_word_time_offsets = false; + /** + * If `true`, the top result includes a list of words and the confidence for + * those words. If `false`, no word-level confidence information is returned. + * The default is `false`. + * + * Generated from protobuf field bool enable_word_confidence = 3; + */ + protected $enable_word_confidence = false; + /** + * If `true`, adds punctuation to recognition result hypotheses. This feature + * is only available in select languages. The default `false` value does not + * add punctuation to result hypotheses. + * + * Generated from protobuf field bool enable_automatic_punctuation = 4; + */ + protected $enable_automatic_punctuation = false; + /** + * The spoken punctuation behavior for the call. If `true`, replaces spoken + * punctuation with the corresponding symbols in the request. For example, + * "how are you question mark" becomes "how are you?". See + * https://cloud.google.com/speech-to-text/docs/spoken-punctuation for + * support. If `false`, spoken punctuation is not replaced. + * + * Generated from protobuf field bool enable_spoken_punctuation = 14; + */ + protected $enable_spoken_punctuation = false; + /** + * The spoken emoji behavior for the call. If `true`, adds spoken emoji + * formatting for the request. This will replace spoken emojis with the + * corresponding Unicode symbols in the final transcript. If `false`, spoken + * emojis are not replaced. + * + * Generated from protobuf field bool enable_spoken_emojis = 15; + */ + protected $enable_spoken_emojis = false; + /** + * Mode for recognizing multi-channel audio. + * + * Generated from protobuf field .google.cloud.speech.v2.RecognitionFeatures.MultiChannelMode multi_channel_mode = 17; + */ + protected $multi_channel_mode = 0; + /** + * Configuration to enable speaker diarization. To enable diarization, set + * this field to an empty SpeakerDiarizationConfig message. + * + * Generated from protobuf field .google.cloud.speech.v2.SpeakerDiarizationConfig diarization_config = 9; + */ + protected $diarization_config = null; + /** + * Maximum number of recognition hypotheses to be returned. + * The server may return fewer than `max_alternatives`. + * Valid values are `0`-`30`. A value of `0` or `1` will return a maximum of + * one. If omitted, will return a maximum of one. + * + * Generated from protobuf field int32 max_alternatives = 16; + */ + protected $max_alternatives = 0; + /** + * Optional. Configuration to enable custom prompt for chirp3. + * + * Generated from protobuf field .google.cloud.speech.v2.CustomPromptConfig custom_prompt_config = 18 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $custom_prompt_config = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type bool $profanity_filter + * If set to `true`, the server will attempt to filter out profanities, + * replacing all but the initial character in each filtered word with + * asterisks, for instance, "f***". If set to `false` or omitted, profanities + * won't be filtered out. + * @type bool $enable_word_time_offsets + * If `true`, the top result includes a list of words and the start and end + * time offsets (timestamps) for those words. If `false`, no word-level time + * offset information is returned. The default is `false`. + * @type bool $enable_word_confidence + * If `true`, the top result includes a list of words and the confidence for + * those words. If `false`, no word-level confidence information is returned. + * The default is `false`. + * @type bool $enable_automatic_punctuation + * If `true`, adds punctuation to recognition result hypotheses. This feature + * is only available in select languages. The default `false` value does not + * add punctuation to result hypotheses. + * @type bool $enable_spoken_punctuation + * The spoken punctuation behavior for the call. If `true`, replaces spoken + * punctuation with the corresponding symbols in the request. For example, + * "how are you question mark" becomes "how are you?". See + * https://cloud.google.com/speech-to-text/docs/spoken-punctuation for + * support. If `false`, spoken punctuation is not replaced. + * @type bool $enable_spoken_emojis + * The spoken emoji behavior for the call. If `true`, adds spoken emoji + * formatting for the request. This will replace spoken emojis with the + * corresponding Unicode symbols in the final transcript. If `false`, spoken + * emojis are not replaced. + * @type int $multi_channel_mode + * Mode for recognizing multi-channel audio. + * @type \Google\Cloud\Speech\V2\SpeakerDiarizationConfig $diarization_config + * Configuration to enable speaker diarization. To enable diarization, set + * this field to an empty SpeakerDiarizationConfig message. + * @type int $max_alternatives + * Maximum number of recognition hypotheses to be returned. + * The server may return fewer than `max_alternatives`. + * Valid values are `0`-`30`. A value of `0` or `1` will return a maximum of + * one. If omitted, will return a maximum of one. + * @type \Google\Cloud\Speech\V2\CustomPromptConfig $custom_prompt_config + * Optional. Configuration to enable custom prompt for chirp3. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * If set to `true`, the server will attempt to filter out profanities, + * replacing all but the initial character in each filtered word with + * asterisks, for instance, "f***". If set to `false` or omitted, profanities + * won't be filtered out. + * + * Generated from protobuf field bool profanity_filter = 1; + * @return bool + */ + public function getProfanityFilter() + { + return $this->profanity_filter; + } + + /** + * If set to `true`, the server will attempt to filter out profanities, + * replacing all but the initial character in each filtered word with + * asterisks, for instance, "f***". If set to `false` or omitted, profanities + * won't be filtered out. + * + * Generated from protobuf field bool profanity_filter = 1; + * @param bool $var + * @return $this + */ + public function setProfanityFilter($var) + { + GPBUtil::checkBool($var); + $this->profanity_filter = $var; + + return $this; + } + + /** + * If `true`, the top result includes a list of words and the start and end + * time offsets (timestamps) for those words. If `false`, no word-level time + * offset information is returned. The default is `false`. + * + * Generated from protobuf field bool enable_word_time_offsets = 2; + * @return bool + */ + public function getEnableWordTimeOffsets() + { + return $this->enable_word_time_offsets; + } + + /** + * If `true`, the top result includes a list of words and the start and end + * time offsets (timestamps) for those words. If `false`, no word-level time + * offset information is returned. The default is `false`. + * + * Generated from protobuf field bool enable_word_time_offsets = 2; + * @param bool $var + * @return $this + */ + public function setEnableWordTimeOffsets($var) + { + GPBUtil::checkBool($var); + $this->enable_word_time_offsets = $var; + + return $this; + } + + /** + * If `true`, the top result includes a list of words and the confidence for + * those words. If `false`, no word-level confidence information is returned. + * The default is `false`. + * + * Generated from protobuf field bool enable_word_confidence = 3; + * @return bool + */ + public function getEnableWordConfidence() + { + return $this->enable_word_confidence; + } + + /** + * If `true`, the top result includes a list of words and the confidence for + * those words. If `false`, no word-level confidence information is returned. + * The default is `false`. + * + * Generated from protobuf field bool enable_word_confidence = 3; + * @param bool $var + * @return $this + */ + public function setEnableWordConfidence($var) + { + GPBUtil::checkBool($var); + $this->enable_word_confidence = $var; + + return $this; + } + + /** + * If `true`, adds punctuation to recognition result hypotheses. This feature + * is only available in select languages. The default `false` value does not + * add punctuation to result hypotheses. + * + * Generated from protobuf field bool enable_automatic_punctuation = 4; + * @return bool + */ + public function getEnableAutomaticPunctuation() + { + return $this->enable_automatic_punctuation; + } + + /** + * If `true`, adds punctuation to recognition result hypotheses. This feature + * is only available in select languages. The default `false` value does not + * add punctuation to result hypotheses. + * + * Generated from protobuf field bool enable_automatic_punctuation = 4; + * @param bool $var + * @return $this + */ + public function setEnableAutomaticPunctuation($var) + { + GPBUtil::checkBool($var); + $this->enable_automatic_punctuation = $var; + + return $this; + } + + /** + * The spoken punctuation behavior for the call. If `true`, replaces spoken + * punctuation with the corresponding symbols in the request. For example, + * "how are you question mark" becomes "how are you?". See + * https://cloud.google.com/speech-to-text/docs/spoken-punctuation for + * support. If `false`, spoken punctuation is not replaced. + * + * Generated from protobuf field bool enable_spoken_punctuation = 14; + * @return bool + */ + public function getEnableSpokenPunctuation() + { + return $this->enable_spoken_punctuation; + } + + /** + * The spoken punctuation behavior for the call. If `true`, replaces spoken + * punctuation with the corresponding symbols in the request. For example, + * "how are you question mark" becomes "how are you?". See + * https://cloud.google.com/speech-to-text/docs/spoken-punctuation for + * support. If `false`, spoken punctuation is not replaced. + * + * Generated from protobuf field bool enable_spoken_punctuation = 14; + * @param bool $var + * @return $this + */ + public function setEnableSpokenPunctuation($var) + { + GPBUtil::checkBool($var); + $this->enable_spoken_punctuation = $var; + + return $this; + } + + /** + * The spoken emoji behavior for the call. If `true`, adds spoken emoji + * formatting for the request. This will replace spoken emojis with the + * corresponding Unicode symbols in the final transcript. If `false`, spoken + * emojis are not replaced. + * + * Generated from protobuf field bool enable_spoken_emojis = 15; + * @return bool + */ + public function getEnableSpokenEmojis() + { + return $this->enable_spoken_emojis; + } + + /** + * The spoken emoji behavior for the call. If `true`, adds spoken emoji + * formatting for the request. This will replace spoken emojis with the + * corresponding Unicode symbols in the final transcript. If `false`, spoken + * emojis are not replaced. + * + * Generated from protobuf field bool enable_spoken_emojis = 15; + * @param bool $var + * @return $this + */ + public function setEnableSpokenEmojis($var) + { + GPBUtil::checkBool($var); + $this->enable_spoken_emojis = $var; + + return $this; + } + + /** + * Mode for recognizing multi-channel audio. + * + * Generated from protobuf field .google.cloud.speech.v2.RecognitionFeatures.MultiChannelMode multi_channel_mode = 17; + * @return int + */ + public function getMultiChannelMode() + { + return $this->multi_channel_mode; + } + + /** + * Mode for recognizing multi-channel audio. + * + * Generated from protobuf field .google.cloud.speech.v2.RecognitionFeatures.MultiChannelMode multi_channel_mode = 17; + * @param int $var + * @return $this + */ + public function setMultiChannelMode($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Speech\V2\RecognitionFeatures\MultiChannelMode::class); + $this->multi_channel_mode = $var; + + return $this; + } + + /** + * Configuration to enable speaker diarization. To enable diarization, set + * this field to an empty SpeakerDiarizationConfig message. + * + * Generated from protobuf field .google.cloud.speech.v2.SpeakerDiarizationConfig diarization_config = 9; + * @return \Google\Cloud\Speech\V2\SpeakerDiarizationConfig|null + */ + public function getDiarizationConfig() + { + return $this->diarization_config; + } + + public function hasDiarizationConfig() + { + return isset($this->diarization_config); + } + + public function clearDiarizationConfig() + { + unset($this->diarization_config); + } + + /** + * Configuration to enable speaker diarization. To enable diarization, set + * this field to an empty SpeakerDiarizationConfig message. + * + * Generated from protobuf field .google.cloud.speech.v2.SpeakerDiarizationConfig diarization_config = 9; + * @param \Google\Cloud\Speech\V2\SpeakerDiarizationConfig $var + * @return $this + */ + public function setDiarizationConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\SpeakerDiarizationConfig::class); + $this->diarization_config = $var; + + return $this; + } + + /** + * Maximum number of recognition hypotheses to be returned. + * The server may return fewer than `max_alternatives`. + * Valid values are `0`-`30`. A value of `0` or `1` will return a maximum of + * one. If omitted, will return a maximum of one. + * + * Generated from protobuf field int32 max_alternatives = 16; + * @return int + */ + public function getMaxAlternatives() + { + return $this->max_alternatives; + } + + /** + * Maximum number of recognition hypotheses to be returned. + * The server may return fewer than `max_alternatives`. + * Valid values are `0`-`30`. A value of `0` or `1` will return a maximum of + * one. If omitted, will return a maximum of one. + * + * Generated from protobuf field int32 max_alternatives = 16; + * @param int $var + * @return $this + */ + public function setMaxAlternatives($var) + { + GPBUtil::checkInt32($var); + $this->max_alternatives = $var; + + return $this; + } + + /** + * Optional. Configuration to enable custom prompt for chirp3. + * + * Generated from protobuf field .google.cloud.speech.v2.CustomPromptConfig custom_prompt_config = 18 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\Speech\V2\CustomPromptConfig|null + */ + public function getCustomPromptConfig() + { + return $this->custom_prompt_config; + } + + public function hasCustomPromptConfig() + { + return isset($this->custom_prompt_config); + } + + public function clearCustomPromptConfig() + { + unset($this->custom_prompt_config); + } + + /** + * Optional. Configuration to enable custom prompt for chirp3. + * + * Generated from protobuf field .google.cloud.speech.v2.CustomPromptConfig custom_prompt_config = 18 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\Speech\V2\CustomPromptConfig $var + * @return $this + */ + public function setCustomPromptConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\CustomPromptConfig::class); + $this->custom_prompt_config = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognitionFeatures/MultiChannelMode.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognitionFeatures/MultiChannelMode.php new file mode 100644 index 000000000000..a1b656025dfa --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognitionFeatures/MultiChannelMode.php @@ -0,0 +1,58 @@ +google.cloud.speech.v2.RecognitionFeatures.MultiChannelMode + */ +class MultiChannelMode +{ + /** + * Default value for the multi-channel mode. If the audio contains + * multiple channels, only the first channel will be transcribed; other + * channels will be ignored. + * + * Generated from protobuf enum MULTI_CHANNEL_MODE_UNSPECIFIED = 0; + */ + const MULTI_CHANNEL_MODE_UNSPECIFIED = 0; + /** + * If selected, each channel in the provided audio is transcribed + * independently. This cannot be selected if the selected + * [model][google.cloud.speech.v2.Recognizer.model] is `latest_short`. + * + * Generated from protobuf enum SEPARATE_RECOGNITION_PER_CHANNEL = 1; + */ + const SEPARATE_RECOGNITION_PER_CHANNEL = 1; + + private static $valueToName = [ + self::MULTI_CHANNEL_MODE_UNSPECIFIED => 'MULTI_CHANNEL_MODE_UNSPECIFIED', + self::SEPARATE_RECOGNITION_PER_CHANNEL => 'SEPARATE_RECOGNITION_PER_CHANNEL', + ]; + + 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/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognitionOutputConfig.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognitionOutputConfig.php new file mode 100644 index 000000000000..41054fa5bf14 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognitionOutputConfig.php @@ -0,0 +1,171 @@ +google.cloud.speech.v2.RecognitionOutputConfig + */ +class RecognitionOutputConfig extends \Google\Protobuf\Internal\Message +{ + /** + * Optional. Configuration for the format of the results stored to `output`. + * If unspecified transcripts will be written in the `NATIVE` format only. + * + * Generated from protobuf field .google.cloud.speech.v2.OutputFormatConfig output_format_config = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $output_format_config = null; + protected $output; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Speech\V2\GcsOutputConfig $gcs_output_config + * If this message is populated, recognition results are written to the + * provided Google Cloud Storage URI. + * @type \Google\Cloud\Speech\V2\InlineOutputConfig $inline_response_config + * If this message is populated, recognition results are provided in the + * [BatchRecognizeResponse][google.cloud.speech.v2.BatchRecognizeResponse] + * message of the Operation when completed. This is only supported when + * calling [BatchRecognize][google.cloud.speech.v2.Speech.BatchRecognize] + * with just one audio file. + * @type \Google\Cloud\Speech\V2\OutputFormatConfig $output_format_config + * Optional. Configuration for the format of the results stored to `output`. + * If unspecified transcripts will be written in the `NATIVE` format only. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * If this message is populated, recognition results are written to the + * provided Google Cloud Storage URI. + * + * Generated from protobuf field .google.cloud.speech.v2.GcsOutputConfig gcs_output_config = 1; + * @return \Google\Cloud\Speech\V2\GcsOutputConfig|null + */ + public function getGcsOutputConfig() + { + return $this->readOneof(1); + } + + public function hasGcsOutputConfig() + { + return $this->hasOneof(1); + } + + /** + * If this message is populated, recognition results are written to the + * provided Google Cloud Storage URI. + * + * Generated from protobuf field .google.cloud.speech.v2.GcsOutputConfig gcs_output_config = 1; + * @param \Google\Cloud\Speech\V2\GcsOutputConfig $var + * @return $this + */ + public function setGcsOutputConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\GcsOutputConfig::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * If this message is populated, recognition results are provided in the + * [BatchRecognizeResponse][google.cloud.speech.v2.BatchRecognizeResponse] + * message of the Operation when completed. This is only supported when + * calling [BatchRecognize][google.cloud.speech.v2.Speech.BatchRecognize] + * with just one audio file. + * + * Generated from protobuf field .google.cloud.speech.v2.InlineOutputConfig inline_response_config = 2; + * @return \Google\Cloud\Speech\V2\InlineOutputConfig|null + */ + public function getInlineResponseConfig() + { + return $this->readOneof(2); + } + + public function hasInlineResponseConfig() + { + return $this->hasOneof(2); + } + + /** + * If this message is populated, recognition results are provided in the + * [BatchRecognizeResponse][google.cloud.speech.v2.BatchRecognizeResponse] + * message of the Operation when completed. This is only supported when + * calling [BatchRecognize][google.cloud.speech.v2.Speech.BatchRecognize] + * with just one audio file. + * + * Generated from protobuf field .google.cloud.speech.v2.InlineOutputConfig inline_response_config = 2; + * @param \Google\Cloud\Speech\V2\InlineOutputConfig $var + * @return $this + */ + public function setInlineResponseConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\InlineOutputConfig::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * Optional. Configuration for the format of the results stored to `output`. + * If unspecified transcripts will be written in the `NATIVE` format only. + * + * Generated from protobuf field .google.cloud.speech.v2.OutputFormatConfig output_format_config = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\Speech\V2\OutputFormatConfig|null + */ + public function getOutputFormatConfig() + { + return $this->output_format_config; + } + + public function hasOutputFormatConfig() + { + return isset($this->output_format_config); + } + + public function clearOutputFormatConfig() + { + unset($this->output_format_config); + } + + /** + * Optional. Configuration for the format of the results stored to `output`. + * If unspecified transcripts will be written in the `NATIVE` format only. + * + * Generated from protobuf field .google.cloud.speech.v2.OutputFormatConfig output_format_config = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\Speech\V2\OutputFormatConfig $var + * @return $this + */ + public function setOutputFormatConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\OutputFormatConfig::class); + $this->output_format_config = $var; + + return $this; + } + + /** + * @return string + */ + public function getOutput() + { + return $this->whichOneof("output"); + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognitionResponseMetadata.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognitionResponseMetadata.php new file mode 100644 index 000000000000..1fd568b071ec --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognitionResponseMetadata.php @@ -0,0 +1,159 @@ +google.cloud.speech.v2.RecognitionResponseMetadata + */ +class RecognitionResponseMetadata extends \Google\Protobuf\Internal\Message +{ + /** + * Global request identifier auto-generated by the API. + * + * Generated from protobuf field string request_id = 9 [(.google.api.field_info) = { + */ + protected $request_id = ''; + /** + * When available, billed audio seconds for the corresponding request. + * + * Generated from protobuf field .google.protobuf.Duration total_billed_duration = 6; + */ + protected $total_billed_duration = null; + /** + * Optional. Output only. Provides the prompt used for the recognition + * request. + * + * Generated from protobuf field optional string prompt = 10 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = OPTIONAL]; + */ + protected $prompt = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $request_id + * Global request identifier auto-generated by the API. + * @type \Google\Protobuf\Duration $total_billed_duration + * When available, billed audio seconds for the corresponding request. + * @type string $prompt + * Optional. Output only. Provides the prompt used for the recognition + * request. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Global request identifier auto-generated by the API. + * + * Generated from protobuf field string request_id = 9 [(.google.api.field_info) = { + * @return string + */ + public function getRequestId() + { + return $this->request_id; + } + + /** + * Global request identifier auto-generated by the API. + * + * Generated from protobuf field string request_id = 9 [(.google.api.field_info) = { + * @param string $var + * @return $this + */ + public function setRequestId($var) + { + GPBUtil::checkString($var, True); + $this->request_id = $var; + + return $this; + } + + /** + * When available, billed audio seconds for the corresponding request. + * + * Generated from protobuf field .google.protobuf.Duration total_billed_duration = 6; + * @return \Google\Protobuf\Duration|null + */ + public function getTotalBilledDuration() + { + return $this->total_billed_duration; + } + + public function hasTotalBilledDuration() + { + return isset($this->total_billed_duration); + } + + public function clearTotalBilledDuration() + { + unset($this->total_billed_duration); + } + + /** + * When available, billed audio seconds for the corresponding request. + * + * Generated from protobuf field .google.protobuf.Duration total_billed_duration = 6; + * @param \Google\Protobuf\Duration $var + * @return $this + */ + public function setTotalBilledDuration($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); + $this->total_billed_duration = $var; + + return $this; + } + + /** + * Optional. Output only. Provides the prompt used for the recognition + * request. + * + * Generated from protobuf field optional string prompt = 10 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getPrompt() + { + return isset($this->prompt) ? $this->prompt : ''; + } + + public function hasPrompt() + { + return isset($this->prompt); + } + + public function clearPrompt() + { + unset($this->prompt); + } + + /** + * Optional. Output only. Provides the prompt used for the recognition + * request. + * + * Generated from protobuf field optional string prompt = 10 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = OPTIONAL]; + * @param string $var + * @return $this + */ + public function setPrompt($var) + { + GPBUtil::checkString($var, True); + $this->prompt = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognizeRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognizeRequest.php new file mode 100644 index 000000000000..823ef1be1a1c --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognizeRequest.php @@ -0,0 +1,434 @@ +google.cloud.speech.v2.RecognizeRequest + */ +class RecognizeRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the Recognizer to use during recognition. The + * expected format is + * `projects/{project}/locations/{location}/recognizers/{recognizer}`. The + * {recognizer} segment may be set to `_` to use an empty implicit Recognizer. + * + * Generated from protobuf field string recognizer = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $recognizer = ''; + /** + * Features and audio metadata to use for the Automatic Speech Recognition. + * This field in combination with the + * [config_mask][google.cloud.speech.v2.RecognizeRequest.config_mask] field + * can be used to override parts of the + * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] + * of the Recognizer resource. + * + * Generated from protobuf field .google.cloud.speech.v2.RecognitionConfig config = 1; + */ + protected $config = null; + /** + * The list of fields in + * [config][google.cloud.speech.v2.RecognizeRequest.config] that override the + * values in the + * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] + * of the recognizer during this recognition request. If no mask is provided, + * all non-default valued fields in + * [config][google.cloud.speech.v2.RecognizeRequest.config] override the + * values in the recognizer for this recognition request. If a mask is + * provided, only the fields listed in the mask override the config in the + * recognizer for this recognition request. If a wildcard (`*`) is provided, + * [config][google.cloud.speech.v2.RecognizeRequest.config] completely + * overrides and replaces the config in the recognizer for this recognition + * request. + * + * Generated from protobuf field .google.protobuf.FieldMask config_mask = 8; + */ + protected $config_mask = null; + protected $audio_source; + + /** + * @param string $recognizer Required. The name of the Recognizer to use during recognition. The + * expected format is + * `projects/{project}/locations/{location}/recognizers/{recognizer}`. The + * {recognizer} segment may be set to `_` to use an empty implicit Recognizer. Please see + * {@see SpeechClient::recognizerName()} for help formatting this field. + * @param \Google\Cloud\Speech\V2\RecognitionConfig $config Features and audio metadata to use for the Automatic Speech Recognition. + * This field in combination with the + * [config_mask][google.cloud.speech.v2.RecognizeRequest.config_mask] field + * can be used to override parts of the + * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] + * of the Recognizer resource. + * @param \Google\Protobuf\FieldMask $configMask The list of fields in + * [config][google.cloud.speech.v2.RecognizeRequest.config] that override the + * values in the + * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] + * of the recognizer during this recognition request. If no mask is provided, + * all non-default valued fields in + * [config][google.cloud.speech.v2.RecognizeRequest.config] override the + * values in the recognizer for this recognition request. If a mask is + * provided, only the fields listed in the mask override the config in the + * recognizer for this recognition request. If a wildcard (`*`) is provided, + * [config][google.cloud.speech.v2.RecognizeRequest.config] completely + * overrides and replaces the config in the recognizer for this recognition + * request. + * @param string $content The audio data bytes encoded as specified in + * [RecognitionConfig][google.cloud.speech.v2.RecognitionConfig]. As + * with all bytes fields, proto buffers use a pure binary representation, + * whereas JSON representations use base64. + * + * @return \Google\Cloud\Speech\V2\RecognizeRequest + * + * @experimental + */ + public static function build(string $recognizer, \Google\Cloud\Speech\V2\RecognitionConfig $config, \Google\Protobuf\FieldMask $configMask, string $content): self + { + return (new self()) + ->setRecognizer($recognizer) + ->setConfig($config) + ->setConfigMask($configMask) + ->setContent($content); + } + + /** + * @param string $recognizer Required. The name of the Recognizer to use during recognition. The + * expected format is + * `projects/{project}/locations/{location}/recognizers/{recognizer}`. The + * {recognizer} segment may be set to `_` to use an empty implicit Recognizer. Please see + * {@see SpeechClient::recognizerName()} for help formatting this field. + * @param \Google\Cloud\Speech\V2\RecognitionConfig $config Features and audio metadata to use for the Automatic Speech Recognition. + * This field in combination with the + * [config_mask][google.cloud.speech.v2.RecognizeRequest.config_mask] field + * can be used to override parts of the + * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] + * of the Recognizer resource. + * @param \Google\Protobuf\FieldMask $configMask The list of fields in + * [config][google.cloud.speech.v2.RecognizeRequest.config] that override the + * values in the + * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] + * of the recognizer during this recognition request. If no mask is provided, + * all non-default valued fields in + * [config][google.cloud.speech.v2.RecognizeRequest.config] override the + * values in the recognizer for this recognition request. If a mask is + * provided, only the fields listed in the mask override the config in the + * recognizer for this recognition request. If a wildcard (`*`) is provided, + * [config][google.cloud.speech.v2.RecognizeRequest.config] completely + * overrides and replaces the config in the recognizer for this recognition + * request. + * @param string $uri URI that points to a file that contains audio data bytes as specified in + * [RecognitionConfig][google.cloud.speech.v2.RecognitionConfig]. The file + * must not be compressed (for example, gzip). Currently, only Google Cloud + * Storage URIs are supported, which must be specified in the following + * format: `gs://bucket_name/object_name` (other URI formats return + * [INVALID_ARGUMENT][google.rpc.Code.INVALID_ARGUMENT]). For more + * information, see [Request + * URIs](https://cloud.google.com/storage/docs/reference-uris). + * + * @return \Google\Cloud\Speech\V2\RecognizeRequest + * + * @experimental + */ + public static function buildFromRecognizerConfigConfigMaskUri(string $recognizer, \Google\Cloud\Speech\V2\RecognitionConfig $config, \Google\Protobuf\FieldMask $configMask, string $uri): self + { + return (new self()) + ->setRecognizer($recognizer) + ->setConfig($config) + ->setConfigMask($configMask) + ->setUri($uri); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $recognizer + * Required. The name of the Recognizer to use during recognition. The + * expected format is + * `projects/{project}/locations/{location}/recognizers/{recognizer}`. The + * {recognizer} segment may be set to `_` to use an empty implicit Recognizer. + * @type \Google\Cloud\Speech\V2\RecognitionConfig $config + * Features and audio metadata to use for the Automatic Speech Recognition. + * This field in combination with the + * [config_mask][google.cloud.speech.v2.RecognizeRequest.config_mask] field + * can be used to override parts of the + * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] + * of the Recognizer resource. + * @type \Google\Protobuf\FieldMask $config_mask + * The list of fields in + * [config][google.cloud.speech.v2.RecognizeRequest.config] that override the + * values in the + * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] + * of the recognizer during this recognition request. If no mask is provided, + * all non-default valued fields in + * [config][google.cloud.speech.v2.RecognizeRequest.config] override the + * values in the recognizer for this recognition request. If a mask is + * provided, only the fields listed in the mask override the config in the + * recognizer for this recognition request. If a wildcard (`*`) is provided, + * [config][google.cloud.speech.v2.RecognizeRequest.config] completely + * overrides and replaces the config in the recognizer for this recognition + * request. + * @type string $content + * The audio data bytes encoded as specified in + * [RecognitionConfig][google.cloud.speech.v2.RecognitionConfig]. As + * with all bytes fields, proto buffers use a pure binary representation, + * whereas JSON representations use base64. + * @type string $uri + * URI that points to a file that contains audio data bytes as specified in + * [RecognitionConfig][google.cloud.speech.v2.RecognitionConfig]. The file + * must not be compressed (for example, gzip). Currently, only Google Cloud + * Storage URIs are supported, which must be specified in the following + * format: `gs://bucket_name/object_name` (other URI formats return + * [INVALID_ARGUMENT][google.rpc.Code.INVALID_ARGUMENT]). For more + * information, see [Request + * URIs](https://cloud.google.com/storage/docs/reference-uris). + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the Recognizer to use during recognition. The + * expected format is + * `projects/{project}/locations/{location}/recognizers/{recognizer}`. The + * {recognizer} segment may be set to `_` to use an empty implicit Recognizer. + * + * Generated from protobuf field string recognizer = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getRecognizer() + { + return $this->recognizer; + } + + /** + * Required. The name of the Recognizer to use during recognition. The + * expected format is + * `projects/{project}/locations/{location}/recognizers/{recognizer}`. The + * {recognizer} segment may be set to `_` to use an empty implicit Recognizer. + * + * Generated from protobuf field string recognizer = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setRecognizer($var) + { + GPBUtil::checkString($var, True); + $this->recognizer = $var; + + return $this; + } + + /** + * Features and audio metadata to use for the Automatic Speech Recognition. + * This field in combination with the + * [config_mask][google.cloud.speech.v2.RecognizeRequest.config_mask] field + * can be used to override parts of the + * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] + * of the Recognizer resource. + * + * Generated from protobuf field .google.cloud.speech.v2.RecognitionConfig config = 1; + * @return \Google\Cloud\Speech\V2\RecognitionConfig|null + */ + public function getConfig() + { + return $this->config; + } + + public function hasConfig() + { + return isset($this->config); + } + + public function clearConfig() + { + unset($this->config); + } + + /** + * Features and audio metadata to use for the Automatic Speech Recognition. + * This field in combination with the + * [config_mask][google.cloud.speech.v2.RecognizeRequest.config_mask] field + * can be used to override parts of the + * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] + * of the Recognizer resource. + * + * Generated from protobuf field .google.cloud.speech.v2.RecognitionConfig config = 1; + * @param \Google\Cloud\Speech\V2\RecognitionConfig $var + * @return $this + */ + public function setConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\RecognitionConfig::class); + $this->config = $var; + + return $this; + } + + /** + * The list of fields in + * [config][google.cloud.speech.v2.RecognizeRequest.config] that override the + * values in the + * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] + * of the recognizer during this recognition request. If no mask is provided, + * all non-default valued fields in + * [config][google.cloud.speech.v2.RecognizeRequest.config] override the + * values in the recognizer for this recognition request. If a mask is + * provided, only the fields listed in the mask override the config in the + * recognizer for this recognition request. If a wildcard (`*`) is provided, + * [config][google.cloud.speech.v2.RecognizeRequest.config] completely + * overrides and replaces the config in the recognizer for this recognition + * request. + * + * Generated from protobuf field .google.protobuf.FieldMask config_mask = 8; + * @return \Google\Protobuf\FieldMask|null + */ + public function getConfigMask() + { + return $this->config_mask; + } + + public function hasConfigMask() + { + return isset($this->config_mask); + } + + public function clearConfigMask() + { + unset($this->config_mask); + } + + /** + * The list of fields in + * [config][google.cloud.speech.v2.RecognizeRequest.config] that override the + * values in the + * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] + * of the recognizer during this recognition request. If no mask is provided, + * all non-default valued fields in + * [config][google.cloud.speech.v2.RecognizeRequest.config] override the + * values in the recognizer for this recognition request. If a mask is + * provided, only the fields listed in the mask override the config in the + * recognizer for this recognition request. If a wildcard (`*`) is provided, + * [config][google.cloud.speech.v2.RecognizeRequest.config] completely + * overrides and replaces the config in the recognizer for this recognition + * request. + * + * Generated from protobuf field .google.protobuf.FieldMask config_mask = 8; + * @param \Google\Protobuf\FieldMask $var + * @return $this + */ + public function setConfigMask($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); + $this->config_mask = $var; + + return $this; + } + + /** + * The audio data bytes encoded as specified in + * [RecognitionConfig][google.cloud.speech.v2.RecognitionConfig]. As + * with all bytes fields, proto buffers use a pure binary representation, + * whereas JSON representations use base64. + * + * Generated from protobuf field bytes content = 5; + * @return string + */ + public function getContent() + { + return $this->readOneof(5); + } + + public function hasContent() + { + return $this->hasOneof(5); + } + + /** + * The audio data bytes encoded as specified in + * [RecognitionConfig][google.cloud.speech.v2.RecognitionConfig]. As + * with all bytes fields, proto buffers use a pure binary representation, + * whereas JSON representations use base64. + * + * Generated from protobuf field bytes content = 5; + * @param string $var + * @return $this + */ + public function setContent($var) + { + GPBUtil::checkString($var, False); + $this->writeOneof(5, $var); + + return $this; + } + + /** + * URI that points to a file that contains audio data bytes as specified in + * [RecognitionConfig][google.cloud.speech.v2.RecognitionConfig]. The file + * must not be compressed (for example, gzip). Currently, only Google Cloud + * Storage URIs are supported, which must be specified in the following + * format: `gs://bucket_name/object_name` (other URI formats return + * [INVALID_ARGUMENT][google.rpc.Code.INVALID_ARGUMENT]). For more + * information, see [Request + * URIs](https://cloud.google.com/storage/docs/reference-uris). + * + * Generated from protobuf field string uri = 6; + * @return string + */ + public function getUri() + { + return $this->readOneof(6); + } + + public function hasUri() + { + return $this->hasOneof(6); + } + + /** + * URI that points to a file that contains audio data bytes as specified in + * [RecognitionConfig][google.cloud.speech.v2.RecognitionConfig]. The file + * must not be compressed (for example, gzip). Currently, only Google Cloud + * Storage URIs are supported, which must be specified in the following + * format: `gs://bucket_name/object_name` (other URI formats return + * [INVALID_ARGUMENT][google.rpc.Code.INVALID_ARGUMENT]). For more + * information, see [Request + * URIs](https://cloud.google.com/storage/docs/reference-uris). + * + * Generated from protobuf field string uri = 6; + * @param string $var + * @return $this + */ + public function setUri($var) + { + GPBUtil::checkString($var, True); + $this->writeOneof(6, $var); + + return $this; + } + + /** + * @return string + */ + public function getAudioSource() + { + return $this->whichOneof("audio_source"); + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognizeResponse.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognizeResponse.php new file mode 100644 index 000000000000..ff783930527a --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognizeResponse.php @@ -0,0 +1,116 @@ +google.cloud.speech.v2.RecognizeResponse + */ +class RecognizeResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Sequential list of transcription results corresponding to sequential + * portions of audio. + * + * Generated from protobuf field repeated .google.cloud.speech.v2.SpeechRecognitionResult results = 3; + */ + private $results; + /** + * Metadata about the recognition. + * + * Generated from protobuf field .google.cloud.speech.v2.RecognitionResponseMetadata metadata = 2; + */ + protected $metadata = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Speech\V2\SpeechRecognitionResult[] $results + * Sequential list of transcription results corresponding to sequential + * portions of audio. + * @type \Google\Cloud\Speech\V2\RecognitionResponseMetadata $metadata + * Metadata about the recognition. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Sequential list of transcription results corresponding to sequential + * portions of audio. + * + * Generated from protobuf field repeated .google.cloud.speech.v2.SpeechRecognitionResult results = 3; + * @return RepeatedField<\Google\Cloud\Speech\V2\SpeechRecognitionResult> + */ + public function getResults() + { + return $this->results; + } + + /** + * Sequential list of transcription results corresponding to sequential + * portions of audio. + * + * Generated from protobuf field repeated .google.cloud.speech.v2.SpeechRecognitionResult results = 3; + * @param \Google\Cloud\Speech\V2\SpeechRecognitionResult[] $var + * @return $this + */ + public function setResults($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Speech\V2\SpeechRecognitionResult::class); + $this->results = $arr; + + return $this; + } + + /** + * Metadata about the recognition. + * + * Generated from protobuf field .google.cloud.speech.v2.RecognitionResponseMetadata metadata = 2; + * @return \Google\Cloud\Speech\V2\RecognitionResponseMetadata|null + */ + public function getMetadata() + { + return $this->metadata; + } + + public function hasMetadata() + { + return isset($this->metadata); + } + + public function clearMetadata() + { + unset($this->metadata); + } + + /** + * Metadata about the recognition. + * + * Generated from protobuf field .google.cloud.speech.v2.RecognitionResponseMetadata metadata = 2; + * @param \Google\Cloud\Speech\V2\RecognitionResponseMetadata $var + * @return $this + */ + public function setMetadata($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\RecognitionResponseMetadata::class); + $this->metadata = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/Recognizer.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/Recognizer.php new file mode 100644 index 000000000000..dc1b0485f5ce --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/Recognizer.php @@ -0,0 +1,799 @@ +google.cloud.speech.v2.Recognizer + */ +class Recognizer extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. Identifier. The resource name of the Recognizer. + * Format: `projects/{project}/locations/{location}/recognizers/{recognizer}`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IDENTIFIER]; + */ + protected $name = ''; + /** + * Output only. System-assigned unique identifier for the Recognizer. + * + * Generated from protobuf field string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $uid = ''; + /** + * User-settable, human-readable name for the Recognizer. Must be 63 + * characters or less. + * + * Generated from protobuf field string display_name = 3; + */ + protected $display_name = ''; + /** + * Optional. This field is now deprecated. Prefer the + * [`model`][google.cloud.speech.v2.RecognitionConfig.model] field in the + * [`RecognitionConfig`][google.cloud.speech.v2.RecognitionConfig] message. + * Which model to use for recognition requests. Select the model best suited + * to your domain to get best results. + * Guidance for choosing which model to use can be found in the [Transcription + * Models + * Documentation](https://cloud.google.com/speech-to-text/v2/docs/transcription-model) + * and the models supported in each region can be found in the [Table Of + * Supported + * Models](https://cloud.google.com/speech-to-text/v2/docs/speech-to-text-supported-languages). + * + * Generated from protobuf field string model = 4 [deprecated = true, (.google.api.field_behavior) = OPTIONAL]; + * @deprecated + */ + protected $model = ''; + /** + * Optional. This field is now deprecated. Prefer the + * [`language_codes`][google.cloud.speech.v2.RecognitionConfig.language_codes] + * field in the + * [`RecognitionConfig`][google.cloud.speech.v2.RecognitionConfig] message. + * The language of the supplied audio as a + * [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) language tag. + * Supported languages for each model are listed in the [Table of Supported + * Models](https://cloud.google.com/speech-to-text/v2/docs/speech-to-text-supported-languages). + * If additional languages are provided, recognition result will contain + * recognition in the most likely language detected. The recognition result + * will include the language tag of the language detected in the audio. + * When you create or update a Recognizer, these values are + * stored in normalized BCP-47 form. For example, "en-us" is stored as + * "en-US". + * + * Generated from protobuf field repeated string language_codes = 17 [deprecated = true, (.google.api.field_behavior) = OPTIONAL]; + * @deprecated + */ + private $language_codes; + /** + * Default configuration to use for requests with this Recognizer. + * This can be overwritten by inline configuration in the + * [RecognizeRequest.config][google.cloud.speech.v2.RecognizeRequest.config] + * field. + * + * Generated from protobuf field .google.cloud.speech.v2.RecognitionConfig default_recognition_config = 6; + */ + protected $default_recognition_config = null; + /** + * Allows users to store small amounts of arbitrary data. + * Both the key and the value must be 63 characters or less each. + * At most 100 annotations. + * + * Generated from protobuf field map annotations = 7; + */ + private $annotations; + /** + * Output only. The Recognizer lifecycle state. + * + * Generated from protobuf field .google.cloud.speech.v2.Recognizer.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $state = 0; + /** + * Output only. Creation time. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $create_time = null; + /** + * Output only. The most recent time this Recognizer was modified. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $update_time = null; + /** + * Output only. The time at which this Recognizer was requested for deletion. + * + * Generated from protobuf field .google.protobuf.Timestamp delete_time = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $delete_time = null; + /** + * Output only. The time at which this Recognizer will be purged. + * + * Generated from protobuf field .google.protobuf.Timestamp expire_time = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $expire_time = null; + /** + * Output only. This checksum is computed by the server based on the value of + * other fields. This may be sent on update, undelete, and delete requests to + * ensure the client has an up-to-date value before proceeding. + * + * Generated from protobuf field string etag = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $etag = ''; + /** + * Output only. Whether or not this Recognizer is in the process of being + * updated. + * + * Generated from protobuf field bool reconciling = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $reconciling = false; + /** + * Output only. The [KMS key + * name](https://cloud.google.com/kms/docs/resource-hierarchy#keys) with which + * the Recognizer is encrypted. The expected format is + * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. + * + * Generated from protobuf field string kms_key_name = 15 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { + */ + protected $kms_key_name = ''; + /** + * Output only. The [KMS key version + * name](https://cloud.google.com/kms/docs/resource-hierarchy#key_versions) + * with which the Recognizer is encrypted. The expected format is + * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}/cryptoKeyVersions/{crypto_key_version}`. + * + * Generated from protobuf field string kms_key_version_name = 16 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { + */ + protected $kms_key_version_name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Output only. Identifier. The resource name of the Recognizer. + * Format: `projects/{project}/locations/{location}/recognizers/{recognizer}`. + * @type string $uid + * Output only. System-assigned unique identifier for the Recognizer. + * @type string $display_name + * User-settable, human-readable name for the Recognizer. Must be 63 + * characters or less. + * @type string $model + * Optional. This field is now deprecated. Prefer the + * [`model`][google.cloud.speech.v2.RecognitionConfig.model] field in the + * [`RecognitionConfig`][google.cloud.speech.v2.RecognitionConfig] message. + * Which model to use for recognition requests. Select the model best suited + * to your domain to get best results. + * Guidance for choosing which model to use can be found in the [Transcription + * Models + * Documentation](https://cloud.google.com/speech-to-text/v2/docs/transcription-model) + * and the models supported in each region can be found in the [Table Of + * Supported + * Models](https://cloud.google.com/speech-to-text/v2/docs/speech-to-text-supported-languages). + * @type string[] $language_codes + * Optional. This field is now deprecated. Prefer the + * [`language_codes`][google.cloud.speech.v2.RecognitionConfig.language_codes] + * field in the + * [`RecognitionConfig`][google.cloud.speech.v2.RecognitionConfig] message. + * The language of the supplied audio as a + * [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) language tag. + * Supported languages for each model are listed in the [Table of Supported + * Models](https://cloud.google.com/speech-to-text/v2/docs/speech-to-text-supported-languages). + * If additional languages are provided, recognition result will contain + * recognition in the most likely language detected. The recognition result + * will include the language tag of the language detected in the audio. + * When you create or update a Recognizer, these values are + * stored in normalized BCP-47 form. For example, "en-us" is stored as + * "en-US". + * @type \Google\Cloud\Speech\V2\RecognitionConfig $default_recognition_config + * Default configuration to use for requests with this Recognizer. + * This can be overwritten by inline configuration in the + * [RecognizeRequest.config][google.cloud.speech.v2.RecognizeRequest.config] + * field. + * @type array|\Google\Protobuf\Internal\MapField $annotations + * Allows users to store small amounts of arbitrary data. + * Both the key and the value must be 63 characters or less each. + * At most 100 annotations. + * @type int $state + * Output only. The Recognizer lifecycle state. + * @type \Google\Protobuf\Timestamp $create_time + * Output only. Creation time. + * @type \Google\Protobuf\Timestamp $update_time + * Output only. The most recent time this Recognizer was modified. + * @type \Google\Protobuf\Timestamp $delete_time + * Output only. The time at which this Recognizer was requested for deletion. + * @type \Google\Protobuf\Timestamp $expire_time + * Output only. The time at which this Recognizer will be purged. + * @type string $etag + * Output only. This checksum is computed by the server based on the value of + * other fields. This may be sent on update, undelete, and delete requests to + * ensure the client has an up-to-date value before proceeding. + * @type bool $reconciling + * Output only. Whether or not this Recognizer is in the process of being + * updated. + * @type string $kms_key_name + * Output only. The [KMS key + * name](https://cloud.google.com/kms/docs/resource-hierarchy#keys) with which + * the Recognizer is encrypted. The expected format is + * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. + * @type string $kms_key_version_name + * Output only. The [KMS key version + * name](https://cloud.google.com/kms/docs/resource-hierarchy#key_versions) + * with which the Recognizer is encrypted. The expected format is + * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}/cryptoKeyVersions/{crypto_key_version}`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Output only. Identifier. The resource name of the Recognizer. + * Format: `projects/{project}/locations/{location}/recognizers/{recognizer}`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IDENTIFIER]; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Output only. Identifier. The resource name of the Recognizer. + * Format: `projects/{project}/locations/{location}/recognizers/{recognizer}`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IDENTIFIER]; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Output only. System-assigned unique identifier for the Recognizer. + * + * Generated from protobuf field string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getUid() + { + return $this->uid; + } + + /** + * Output only. System-assigned unique identifier for the Recognizer. + * + * 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; + } + + /** + * User-settable, human-readable name for the Recognizer. Must be 63 + * characters or less. + * + * Generated from protobuf field string display_name = 3; + * @return string + */ + public function getDisplayName() + { + return $this->display_name; + } + + /** + * User-settable, human-readable name for the Recognizer. Must be 63 + * characters or less. + * + * Generated from protobuf field string display_name = 3; + * @param string $var + * @return $this + */ + public function setDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->display_name = $var; + + return $this; + } + + /** + * Optional. This field is now deprecated. Prefer the + * [`model`][google.cloud.speech.v2.RecognitionConfig.model] field in the + * [`RecognitionConfig`][google.cloud.speech.v2.RecognitionConfig] message. + * Which model to use for recognition requests. Select the model best suited + * to your domain to get best results. + * Guidance for choosing which model to use can be found in the [Transcription + * Models + * Documentation](https://cloud.google.com/speech-to-text/v2/docs/transcription-model) + * and the models supported in each region can be found in the [Table Of + * Supported + * Models](https://cloud.google.com/speech-to-text/v2/docs/speech-to-text-supported-languages). + * + * Generated from protobuf field string model = 4 [deprecated = true, (.google.api.field_behavior) = OPTIONAL]; + * @return string + * @deprecated + */ + public function getModel() + { + if ($this->model !== '') { + @trigger_error('model is deprecated.', E_USER_DEPRECATED); + } + return $this->model; + } + + /** + * Optional. This field is now deprecated. Prefer the + * [`model`][google.cloud.speech.v2.RecognitionConfig.model] field in the + * [`RecognitionConfig`][google.cloud.speech.v2.RecognitionConfig] message. + * Which model to use for recognition requests. Select the model best suited + * to your domain to get best results. + * Guidance for choosing which model to use can be found in the [Transcription + * Models + * Documentation](https://cloud.google.com/speech-to-text/v2/docs/transcription-model) + * and the models supported in each region can be found in the [Table Of + * Supported + * Models](https://cloud.google.com/speech-to-text/v2/docs/speech-to-text-supported-languages). + * + * Generated from protobuf field string model = 4 [deprecated = true, (.google.api.field_behavior) = OPTIONAL]; + * @param string $var + * @return $this + * @deprecated + */ + public function setModel($var) + { + @trigger_error('model is deprecated.', E_USER_DEPRECATED); + GPBUtil::checkString($var, True); + $this->model = $var; + + return $this; + } + + /** + * Optional. This field is now deprecated. Prefer the + * [`language_codes`][google.cloud.speech.v2.RecognitionConfig.language_codes] + * field in the + * [`RecognitionConfig`][google.cloud.speech.v2.RecognitionConfig] message. + * The language of the supplied audio as a + * [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) language tag. + * Supported languages for each model are listed in the [Table of Supported + * Models](https://cloud.google.com/speech-to-text/v2/docs/speech-to-text-supported-languages). + * If additional languages are provided, recognition result will contain + * recognition in the most likely language detected. The recognition result + * will include the language tag of the language detected in the audio. + * When you create or update a Recognizer, these values are + * stored in normalized BCP-47 form. For example, "en-us" is stored as + * "en-US". + * + * Generated from protobuf field repeated string language_codes = 17 [deprecated = true, (.google.api.field_behavior) = OPTIONAL]; + * @return RepeatedField + * @deprecated + */ + public function getLanguageCodes() + { + if ($this->language_codes->count() !== 0) { + @trigger_error('language_codes is deprecated.', E_USER_DEPRECATED); + } + return $this->language_codes; + } + + /** + * Optional. This field is now deprecated. Prefer the + * [`language_codes`][google.cloud.speech.v2.RecognitionConfig.language_codes] + * field in the + * [`RecognitionConfig`][google.cloud.speech.v2.RecognitionConfig] message. + * The language of the supplied audio as a + * [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) language tag. + * Supported languages for each model are listed in the [Table of Supported + * Models](https://cloud.google.com/speech-to-text/v2/docs/speech-to-text-supported-languages). + * If additional languages are provided, recognition result will contain + * recognition in the most likely language detected. The recognition result + * will include the language tag of the language detected in the audio. + * When you create or update a Recognizer, these values are + * stored in normalized BCP-47 form. For example, "en-us" is stored as + * "en-US". + * + * Generated from protobuf field repeated string language_codes = 17 [deprecated = true, (.google.api.field_behavior) = OPTIONAL]; + * @param string[] $var + * @return $this + * @deprecated + */ + public function setLanguageCodes($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + if ($arr->count() !== 0) { + @trigger_error('language_codes is deprecated.', E_USER_DEPRECATED); + } + $this->language_codes = $arr; + + return $this; + } + + /** + * Default configuration to use for requests with this Recognizer. + * This can be overwritten by inline configuration in the + * [RecognizeRequest.config][google.cloud.speech.v2.RecognizeRequest.config] + * field. + * + * Generated from protobuf field .google.cloud.speech.v2.RecognitionConfig default_recognition_config = 6; + * @return \Google\Cloud\Speech\V2\RecognitionConfig|null + */ + public function getDefaultRecognitionConfig() + { + return $this->default_recognition_config; + } + + public function hasDefaultRecognitionConfig() + { + return isset($this->default_recognition_config); + } + + public function clearDefaultRecognitionConfig() + { + unset($this->default_recognition_config); + } + + /** + * Default configuration to use for requests with this Recognizer. + * This can be overwritten by inline configuration in the + * [RecognizeRequest.config][google.cloud.speech.v2.RecognizeRequest.config] + * field. + * + * Generated from protobuf field .google.cloud.speech.v2.RecognitionConfig default_recognition_config = 6; + * @param \Google\Cloud\Speech\V2\RecognitionConfig $var + * @return $this + */ + public function setDefaultRecognitionConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\RecognitionConfig::class); + $this->default_recognition_config = $var; + + return $this; + } + + /** + * Allows users to store small amounts of arbitrary data. + * Both the key and the value must be 63 characters or less each. + * At most 100 annotations. + * + * Generated from protobuf field map annotations = 7; + * @return \Google\Protobuf\Internal\MapField + */ + public function getAnnotations() + { + return $this->annotations; + } + + /** + * Allows users to store small amounts of arbitrary data. + * Both the key and the value must be 63 characters or less each. + * At most 100 annotations. + * + * Generated from protobuf field map annotations = 7; + * @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. The Recognizer lifecycle state. + * + * Generated from protobuf field .google.cloud.speech.v2.Recognizer.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getState() + { + return $this->state; + } + + /** + * Output only. The Recognizer lifecycle state. + * + * Generated from protobuf field .google.cloud.speech.v2.Recognizer.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setState($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Speech\V2\Recognizer\State::class); + $this->state = $var; + + return $this; + } + + /** + * Output only. Creation time. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 9 [(.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 time. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 9 [(.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 most recent time this Recognizer was modified. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 10 [(.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 most recent time this Recognizer was modified. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 10 [(.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 time at which this Recognizer was requested for deletion. + * + * Generated from protobuf field .google.protobuf.Timestamp delete_time = 11 [(.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. The time at which this Recognizer was requested for deletion. + * + * Generated from protobuf field .google.protobuf.Timestamp delete_time = 11 [(.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. The time at which this Recognizer will be purged. + * + * Generated from protobuf field .google.protobuf.Timestamp expire_time = 14 [(.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 Recognizer will be purged. + * + * Generated from protobuf field .google.protobuf.Timestamp expire_time = 14 [(.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. This checksum is computed by the server based on the value of + * other fields. This may be sent on update, undelete, and delete requests to + * ensure the client has an up-to-date value before proceeding. + * + * Generated from protobuf field string etag = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getEtag() + { + return $this->etag; + } + + /** + * Output only. This checksum is computed by the server based on the value of + * other fields. This may be sent on update, undelete, and delete requests to + * ensure the client has an up-to-date value before proceeding. + * + * Generated from protobuf field string etag = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setEtag($var) + { + GPBUtil::checkString($var, True); + $this->etag = $var; + + return $this; + } + + /** + * Output only. Whether or not this Recognizer is in the process of being + * updated. + * + * Generated from protobuf field bool reconciling = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return bool + */ + public function getReconciling() + { + return $this->reconciling; + } + + /** + * Output only. Whether or not this Recognizer is in the process of being + * updated. + * + * Generated from protobuf field bool reconciling = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param bool $var + * @return $this + */ + public function setReconciling($var) + { + GPBUtil::checkBool($var); + $this->reconciling = $var; + + return $this; + } + + /** + * Output only. The [KMS key + * name](https://cloud.google.com/kms/docs/resource-hierarchy#keys) with which + * the Recognizer is encrypted. The expected format is + * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. + * + * Generated from protobuf field string kms_key_name = 15 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { + * @return string + */ + public function getKmsKeyName() + { + return $this->kms_key_name; + } + + /** + * Output only. The [KMS key + * name](https://cloud.google.com/kms/docs/resource-hierarchy#keys) with which + * the Recognizer is encrypted. The expected format is + * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. + * + * Generated from protobuf field string kms_key_name = 15 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setKmsKeyName($var) + { + GPBUtil::checkString($var, True); + $this->kms_key_name = $var; + + return $this; + } + + /** + * Output only. The [KMS key version + * name](https://cloud.google.com/kms/docs/resource-hierarchy#key_versions) + * with which the Recognizer is encrypted. The expected format is + * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}/cryptoKeyVersions/{crypto_key_version}`. + * + * Generated from protobuf field string kms_key_version_name = 16 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { + * @return string + */ + public function getKmsKeyVersionName() + { + return $this->kms_key_version_name; + } + + /** + * Output only. The [KMS key version + * name](https://cloud.google.com/kms/docs/resource-hierarchy#key_versions) + * with which the Recognizer is encrypted. The expected format is + * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}/cryptoKeyVersions/{crypto_key_version}`. + * + * Generated from protobuf field string kms_key_version_name = 16 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setKmsKeyVersionName($var) + { + GPBUtil::checkString($var, True); + $this->kms_key_version_name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/Recognizer/State.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/Recognizer/State.php new file mode 100644 index 000000000000..1bc8bcec0b83 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/Recognizer/State.php @@ -0,0 +1,61 @@ +google.cloud.speech.v2.Recognizer.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 Recognizer is active and ready for use. + * + * Generated from protobuf enum ACTIVE = 2; + */ + const ACTIVE = 2; + /** + * This Recognizer has been deleted. + * + * Generated from protobuf enum DELETED = 4; + */ + const DELETED = 4; + + private static $valueToName = [ + self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', + self::ACTIVE => 'ACTIVE', + 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); + } +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SpeakerDiarizationConfig.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SpeakerDiarizationConfig.php new file mode 100644 index 000000000000..e9b16ce24755 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SpeakerDiarizationConfig.php @@ -0,0 +1,109 @@ +google.cloud.speech.v2.SpeakerDiarizationConfig + */ +class SpeakerDiarizationConfig extends \Google\Protobuf\Internal\Message +{ + /** + * Optional. The system automatically determines the number of speakers. This + * value is not currently used. + * + * Generated from protobuf field int32 min_speaker_count = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $min_speaker_count = 0; + /** + * Optional. The system automatically determines the number of speakers. This + * value is not currently used. + * + * Generated from protobuf field int32 max_speaker_count = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $max_speaker_count = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $min_speaker_count + * Optional. The system automatically determines the number of speakers. This + * value is not currently used. + * @type int $max_speaker_count + * Optional. The system automatically determines the number of speakers. This + * value is not currently used. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Optional. The system automatically determines the number of speakers. This + * value is not currently used. + * + * Generated from protobuf field int32 min_speaker_count = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return int + */ + public function getMinSpeakerCount() + { + return $this->min_speaker_count; + } + + /** + * Optional. The system automatically determines the number of speakers. This + * value is not currently used. + * + * Generated from protobuf field int32 min_speaker_count = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @param int $var + * @return $this + */ + public function setMinSpeakerCount($var) + { + GPBUtil::checkInt32($var); + $this->min_speaker_count = $var; + + return $this; + } + + /** + * Optional. The system automatically determines the number of speakers. This + * value is not currently used. + * + * Generated from protobuf field int32 max_speaker_count = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return int + */ + public function getMaxSpeakerCount() + { + return $this->max_speaker_count; + } + + /** + * Optional. The system automatically determines the number of speakers. This + * value is not currently used. + * + * Generated from protobuf field int32 max_speaker_count = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @param int $var + * @return $this + */ + public function setMaxSpeakerCount($var) + { + GPBUtil::checkInt32($var); + $this->max_speaker_count = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SpeechAdaptation.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SpeechAdaptation.php new file mode 100644 index 000000000000..c0cdfd7c6b5f --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SpeechAdaptation.php @@ -0,0 +1,107 @@ +google.cloud.speech.v2.SpeechAdaptation + */ +class SpeechAdaptation extends \Google\Protobuf\Internal\Message +{ + /** + * A list of inline or referenced PhraseSets. + * + * Generated from protobuf field repeated .google.cloud.speech.v2.SpeechAdaptation.AdaptationPhraseSet phrase_sets = 1; + */ + private $phrase_sets; + /** + * A list of inline CustomClasses. Existing CustomClass resources can be + * referenced directly in a PhraseSet. + * + * Generated from protobuf field repeated .google.cloud.speech.v2.CustomClass custom_classes = 2; + */ + private $custom_classes; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Speech\V2\SpeechAdaptation\AdaptationPhraseSet[] $phrase_sets + * A list of inline or referenced PhraseSets. + * @type \Google\Cloud\Speech\V2\CustomClass[] $custom_classes + * A list of inline CustomClasses. Existing CustomClass resources can be + * referenced directly in a PhraseSet. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * A list of inline or referenced PhraseSets. + * + * Generated from protobuf field repeated .google.cloud.speech.v2.SpeechAdaptation.AdaptationPhraseSet phrase_sets = 1; + * @return RepeatedField<\Google\Cloud\Speech\V2\SpeechAdaptation\AdaptationPhraseSet> + */ + public function getPhraseSets() + { + return $this->phrase_sets; + } + + /** + * A list of inline or referenced PhraseSets. + * + * Generated from protobuf field repeated .google.cloud.speech.v2.SpeechAdaptation.AdaptationPhraseSet phrase_sets = 1; + * @param \Google\Cloud\Speech\V2\SpeechAdaptation\AdaptationPhraseSet[] $var + * @return $this + */ + public function setPhraseSets($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Speech\V2\SpeechAdaptation\AdaptationPhraseSet::class); + $this->phrase_sets = $arr; + + return $this; + } + + /** + * A list of inline CustomClasses. Existing CustomClass resources can be + * referenced directly in a PhraseSet. + * + * Generated from protobuf field repeated .google.cloud.speech.v2.CustomClass custom_classes = 2; + * @return RepeatedField<\Google\Cloud\Speech\V2\CustomClass> + */ + public function getCustomClasses() + { + return $this->custom_classes; + } + + /** + * A list of inline CustomClasses. Existing CustomClass resources can be + * referenced directly in a PhraseSet. + * + * Generated from protobuf field repeated .google.cloud.speech.v2.CustomClass custom_classes = 2; + * @param \Google\Cloud\Speech\V2\CustomClass[] $var + * @return $this + */ + public function setCustomClasses($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Speech\V2\CustomClass::class); + $this->custom_classes = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SpeechAdaptation/AdaptationPhraseSet.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SpeechAdaptation/AdaptationPhraseSet.php new file mode 100644 index 000000000000..8228d4de3a48 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SpeechAdaptation/AdaptationPhraseSet.php @@ -0,0 +1,112 @@ +google.cloud.speech.v2.SpeechAdaptation.AdaptationPhraseSet + */ +class AdaptationPhraseSet extends \Google\Protobuf\Internal\Message +{ + protected $value; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $phrase_set + * The name of an existing PhraseSet resource. The user must have read + * access to the resource and it must not be deleted. + * @type \Google\Cloud\Speech\V2\PhraseSet $inline_phrase_set + * An inline defined PhraseSet. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * The name of an existing PhraseSet resource. The user must have read + * access to the resource and it must not be deleted. + * + * Generated from protobuf field string phrase_set = 1 [(.google.api.resource_reference) = { + * @return string + */ + public function getPhraseSet() + { + return $this->readOneof(1); + } + + public function hasPhraseSet() + { + return $this->hasOneof(1); + } + + /** + * The name of an existing PhraseSet resource. The user must have read + * access to the resource and it must not be deleted. + * + * Generated from protobuf field string phrase_set = 1 [(.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setPhraseSet($var) + { + GPBUtil::checkString($var, True); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * An inline defined PhraseSet. + * + * Generated from protobuf field .google.cloud.speech.v2.PhraseSet inline_phrase_set = 2; + * @return \Google\Cloud\Speech\V2\PhraseSet|null + */ + public function getInlinePhraseSet() + { + return $this->readOneof(2); + } + + public function hasInlinePhraseSet() + { + return $this->hasOneof(2); + } + + /** + * An inline defined PhraseSet. + * + * Generated from protobuf field .google.cloud.speech.v2.PhraseSet inline_phrase_set = 2; + * @param \Google\Cloud\Speech\V2\PhraseSet $var + * @return $this + */ + public function setInlinePhraseSet($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\PhraseSet::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * @return string + */ + public function getValue() + { + return $this->whichOneof("value"); + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SpeechRecognitionAlternative.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SpeechRecognitionAlternative.php new file mode 100644 index 000000000000..78b109df6ad0 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SpeechRecognitionAlternative.php @@ -0,0 +1,175 @@ +google.cloud.speech.v2.SpeechRecognitionAlternative + */ +class SpeechRecognitionAlternative extends \Google\Protobuf\Internal\Message +{ + /** + * Transcript text representing the words that the user spoke. + * + * Generated from protobuf field string transcript = 1; + */ + protected $transcript = ''; + /** + * The confidence estimate between 0.0 and 1.0. A higher number + * indicates an estimated greater likelihood that the recognized words are + * correct. This field is set only for the top alternative of a non-streaming + * result or, of a streaming result where + * [is_final][google.cloud.speech.v2.StreamingRecognitionResult.is_final] is + * set to `true`. This field is not guaranteed to be accurate and users should + * not rely on it to be always provided. The default of 0.0 is a sentinel + * value indicating `confidence` was not set. + * + * Generated from protobuf field float confidence = 2; + */ + protected $confidence = 0.0; + /** + * A list of word-specific information for each recognized word. + * When the + * [SpeakerDiarizationConfig][google.cloud.speech.v2.SpeakerDiarizationConfig] + * is set, you will see all the words from the beginning of the audio. + * + * Generated from protobuf field repeated .google.cloud.speech.v2.WordInfo words = 3; + */ + private $words; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $transcript + * Transcript text representing the words that the user spoke. + * @type float $confidence + * The confidence estimate between 0.0 and 1.0. A higher number + * indicates an estimated greater likelihood that the recognized words are + * correct. This field is set only for the top alternative of a non-streaming + * result or, of a streaming result where + * [is_final][google.cloud.speech.v2.StreamingRecognitionResult.is_final] is + * set to `true`. This field is not guaranteed to be accurate and users should + * not rely on it to be always provided. The default of 0.0 is a sentinel + * value indicating `confidence` was not set. + * @type \Google\Cloud\Speech\V2\WordInfo[] $words + * A list of word-specific information for each recognized word. + * When the + * [SpeakerDiarizationConfig][google.cloud.speech.v2.SpeakerDiarizationConfig] + * is set, you will see all the words from the beginning of the audio. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Transcript text representing the words that the user spoke. + * + * Generated from protobuf field string transcript = 1; + * @return string + */ + public function getTranscript() + { + return $this->transcript; + } + + /** + * Transcript text representing the words that the user spoke. + * + * Generated from protobuf field string transcript = 1; + * @param string $var + * @return $this + */ + public function setTranscript($var) + { + GPBUtil::checkString($var, True); + $this->transcript = $var; + + return $this; + } + + /** + * The confidence estimate between 0.0 and 1.0. A higher number + * indicates an estimated greater likelihood that the recognized words are + * correct. This field is set only for the top alternative of a non-streaming + * result or, of a streaming result where + * [is_final][google.cloud.speech.v2.StreamingRecognitionResult.is_final] is + * set to `true`. This field is not guaranteed to be accurate and users should + * not rely on it to be always provided. The default of 0.0 is a sentinel + * value indicating `confidence` was not set. + * + * Generated from protobuf field float confidence = 2; + * @return float + */ + public function getConfidence() + { + return $this->confidence; + } + + /** + * The confidence estimate between 0.0 and 1.0. A higher number + * indicates an estimated greater likelihood that the recognized words are + * correct. This field is set only for the top alternative of a non-streaming + * result or, of a streaming result where + * [is_final][google.cloud.speech.v2.StreamingRecognitionResult.is_final] is + * set to `true`. This field is not guaranteed to be accurate and users should + * not rely on it to be always provided. The default of 0.0 is a sentinel + * value indicating `confidence` was not set. + * + * Generated from protobuf field float confidence = 2; + * @param float $var + * @return $this + */ + public function setConfidence($var) + { + GPBUtil::checkFloat($var); + $this->confidence = $var; + + return $this; + } + + /** + * A list of word-specific information for each recognized word. + * When the + * [SpeakerDiarizationConfig][google.cloud.speech.v2.SpeakerDiarizationConfig] + * is set, you will see all the words from the beginning of the audio. + * + * Generated from protobuf field repeated .google.cloud.speech.v2.WordInfo words = 3; + * @return RepeatedField<\Google\Cloud\Speech\V2\WordInfo> + */ + public function getWords() + { + return $this->words; + } + + /** + * A list of word-specific information for each recognized word. + * When the + * [SpeakerDiarizationConfig][google.cloud.speech.v2.SpeakerDiarizationConfig] + * is set, you will see all the words from the beginning of the audio. + * + * Generated from protobuf field repeated .google.cloud.speech.v2.WordInfo words = 3; + * @param \Google\Cloud\Speech\V2\WordInfo[] $var + * @return $this + */ + public function setWords($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Speech\V2\WordInfo::class); + $this->words = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SpeechRecognitionResult.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SpeechRecognitionResult.php new file mode 100644 index 000000000000..fa0fed2c6e3c --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SpeechRecognitionResult.php @@ -0,0 +1,211 @@ +google.cloud.speech.v2.SpeechRecognitionResult + */ +class SpeechRecognitionResult extends \Google\Protobuf\Internal\Message +{ + /** + * May contain one or more recognition hypotheses. These alternatives are + * ordered in terms of accuracy, with the top (first) alternative being the + * most probable, as ranked by the recognizer. + * + * Generated from protobuf field repeated .google.cloud.speech.v2.SpeechRecognitionAlternative alternatives = 1; + */ + private $alternatives; + /** + * For multi-channel audio, this is the channel number corresponding to the + * recognized result for the audio from that channel. + * For `audio_channel_count` = `N`, its output values can range from `1` to + * `N`. + * + * Generated from protobuf field int32 channel_tag = 2; + */ + protected $channel_tag = 0; + /** + * Time offset of the end of this result relative to the beginning of the + * audio. + * + * Generated from protobuf field .google.protobuf.Duration result_end_offset = 4; + */ + protected $result_end_offset = null; + /** + * Output only. The [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) + * language tag of the language in this result. This language code was + * detected to have the most likelihood of being spoken in the audio. + * + * Generated from protobuf field string language_code = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $language_code = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Speech\V2\SpeechRecognitionAlternative[] $alternatives + * May contain one or more recognition hypotheses. These alternatives are + * ordered in terms of accuracy, with the top (first) alternative being the + * most probable, as ranked by the recognizer. + * @type int $channel_tag + * For multi-channel audio, this is the channel number corresponding to the + * recognized result for the audio from that channel. + * For `audio_channel_count` = `N`, its output values can range from `1` to + * `N`. + * @type \Google\Protobuf\Duration $result_end_offset + * Time offset of the end of this result relative to the beginning of the + * audio. + * @type string $language_code + * Output only. The [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) + * language tag of the language in this result. This language code was + * detected to have the most likelihood of being spoken in the audio. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * May contain one or more recognition hypotheses. These alternatives are + * ordered in terms of accuracy, with the top (first) alternative being the + * most probable, as ranked by the recognizer. + * + * Generated from protobuf field repeated .google.cloud.speech.v2.SpeechRecognitionAlternative alternatives = 1; + * @return RepeatedField<\Google\Cloud\Speech\V2\SpeechRecognitionAlternative> + */ + public function getAlternatives() + { + return $this->alternatives; + } + + /** + * May contain one or more recognition hypotheses. These alternatives are + * ordered in terms of accuracy, with the top (first) alternative being the + * most probable, as ranked by the recognizer. + * + * Generated from protobuf field repeated .google.cloud.speech.v2.SpeechRecognitionAlternative alternatives = 1; + * @param \Google\Cloud\Speech\V2\SpeechRecognitionAlternative[] $var + * @return $this + */ + public function setAlternatives($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Speech\V2\SpeechRecognitionAlternative::class); + $this->alternatives = $arr; + + return $this; + } + + /** + * For multi-channel audio, this is the channel number corresponding to the + * recognized result for the audio from that channel. + * For `audio_channel_count` = `N`, its output values can range from `1` to + * `N`. + * + * Generated from protobuf field int32 channel_tag = 2; + * @return int + */ + public function getChannelTag() + { + return $this->channel_tag; + } + + /** + * For multi-channel audio, this is the channel number corresponding to the + * recognized result for the audio from that channel. + * For `audio_channel_count` = `N`, its output values can range from `1` to + * `N`. + * + * Generated from protobuf field int32 channel_tag = 2; + * @param int $var + * @return $this + */ + public function setChannelTag($var) + { + GPBUtil::checkInt32($var); + $this->channel_tag = $var; + + return $this; + } + + /** + * Time offset of the end of this result relative to the beginning of the + * audio. + * + * Generated from protobuf field .google.protobuf.Duration result_end_offset = 4; + * @return \Google\Protobuf\Duration|null + */ + public function getResultEndOffset() + { + return $this->result_end_offset; + } + + public function hasResultEndOffset() + { + return isset($this->result_end_offset); + } + + public function clearResultEndOffset() + { + unset($this->result_end_offset); + } + + /** + * Time offset of the end of this result relative to the beginning of the + * audio. + * + * Generated from protobuf field .google.protobuf.Duration result_end_offset = 4; + * @param \Google\Protobuf\Duration $var + * @return $this + */ + public function setResultEndOffset($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); + $this->result_end_offset = $var; + + return $this; + } + + /** + * Output only. The [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) + * language tag of the language in this result. This language code was + * detected to have the most likelihood of being spoken in the audio. + * + * Generated from protobuf field string language_code = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getLanguageCode() + { + return $this->language_code; + } + + /** + * Output only. The [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) + * language tag of the language in this result. This language code was + * detected to have the most likelihood of being spoken in the audio. + * + * Generated from protobuf field string language_code = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setLanguageCode($var) + { + GPBUtil::checkString($var, True); + $this->language_code = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SrtOutputFileFormatConfig.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SrtOutputFileFormatConfig.php new file mode 100644 index 000000000000..13554265d0c1 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SrtOutputFileFormatConfig.php @@ -0,0 +1,35 @@ +google.cloud.speech.v2.SrtOutputFileFormatConfig + */ +class SrtOutputFileFormatConfig extends \Google\Protobuf\Internal\Message +{ + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognitionConfig.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognitionConfig.php new file mode 100644 index 000000000000..b62e4795bd44 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognitionConfig.php @@ -0,0 +1,237 @@ +google.cloud.speech.v2.StreamingRecognitionConfig + */ +class StreamingRecognitionConfig extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Features and audio metadata to use for the Automatic Speech + * Recognition. This field in combination with the + * [config_mask][google.cloud.speech.v2.StreamingRecognitionConfig.config_mask] + * field can be used to override parts of the + * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] + * of the Recognizer resource. + * + * Generated from protobuf field .google.cloud.speech.v2.RecognitionConfig config = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $config = null; + /** + * The list of fields in + * [config][google.cloud.speech.v2.StreamingRecognitionConfig.config] that + * override the values in the + * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] + * of the recognizer during this recognition request. If no mask is provided, + * all non-default valued fields in + * [config][google.cloud.speech.v2.StreamingRecognitionConfig.config] override + * the values in the Recognizer for this recognition request. If a mask is + * provided, only the fields listed in the mask override the config in the + * Recognizer for this recognition request. If a wildcard (`*`) is provided, + * [config][google.cloud.speech.v2.StreamingRecognitionConfig.config] + * completely overrides and replaces the config in the recognizer for this + * recognition request. + * + * Generated from protobuf field .google.protobuf.FieldMask config_mask = 3; + */ + protected $config_mask = null; + /** + * Speech recognition features to enable specific to streaming audio + * recognition requests. + * + * Generated from protobuf field .google.cloud.speech.v2.StreamingRecognitionFeatures streaming_features = 2; + */ + protected $streaming_features = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Speech\V2\RecognitionConfig $config + * Required. Features and audio metadata to use for the Automatic Speech + * Recognition. This field in combination with the + * [config_mask][google.cloud.speech.v2.StreamingRecognitionConfig.config_mask] + * field can be used to override parts of the + * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] + * of the Recognizer resource. + * @type \Google\Protobuf\FieldMask $config_mask + * The list of fields in + * [config][google.cloud.speech.v2.StreamingRecognitionConfig.config] that + * override the values in the + * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] + * of the recognizer during this recognition request. If no mask is provided, + * all non-default valued fields in + * [config][google.cloud.speech.v2.StreamingRecognitionConfig.config] override + * the values in the Recognizer for this recognition request. If a mask is + * provided, only the fields listed in the mask override the config in the + * Recognizer for this recognition request. If a wildcard (`*`) is provided, + * [config][google.cloud.speech.v2.StreamingRecognitionConfig.config] + * completely overrides and replaces the config in the recognizer for this + * recognition request. + * @type \Google\Cloud\Speech\V2\StreamingRecognitionFeatures $streaming_features + * Speech recognition features to enable specific to streaming audio + * recognition requests. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Required. Features and audio metadata to use for the Automatic Speech + * Recognition. This field in combination with the + * [config_mask][google.cloud.speech.v2.StreamingRecognitionConfig.config_mask] + * field can be used to override parts of the + * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] + * of the Recognizer resource. + * + * Generated from protobuf field .google.cloud.speech.v2.RecognitionConfig config = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Speech\V2\RecognitionConfig|null + */ + public function getConfig() + { + return $this->config; + } + + public function hasConfig() + { + return isset($this->config); + } + + public function clearConfig() + { + unset($this->config); + } + + /** + * Required. Features and audio metadata to use for the Automatic Speech + * Recognition. This field in combination with the + * [config_mask][google.cloud.speech.v2.StreamingRecognitionConfig.config_mask] + * field can be used to override parts of the + * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] + * of the Recognizer resource. + * + * Generated from protobuf field .google.cloud.speech.v2.RecognitionConfig config = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Speech\V2\RecognitionConfig $var + * @return $this + */ + public function setConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\RecognitionConfig::class); + $this->config = $var; + + return $this; + } + + /** + * The list of fields in + * [config][google.cloud.speech.v2.StreamingRecognitionConfig.config] that + * override the values in the + * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] + * of the recognizer during this recognition request. If no mask is provided, + * all non-default valued fields in + * [config][google.cloud.speech.v2.StreamingRecognitionConfig.config] override + * the values in the Recognizer for this recognition request. If a mask is + * provided, only the fields listed in the mask override the config in the + * Recognizer for this recognition request. If a wildcard (`*`) is provided, + * [config][google.cloud.speech.v2.StreamingRecognitionConfig.config] + * completely overrides and replaces the config in the recognizer for this + * recognition request. + * + * Generated from protobuf field .google.protobuf.FieldMask config_mask = 3; + * @return \Google\Protobuf\FieldMask|null + */ + public function getConfigMask() + { + return $this->config_mask; + } + + public function hasConfigMask() + { + return isset($this->config_mask); + } + + public function clearConfigMask() + { + unset($this->config_mask); + } + + /** + * The list of fields in + * [config][google.cloud.speech.v2.StreamingRecognitionConfig.config] that + * override the values in the + * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] + * of the recognizer during this recognition request. If no mask is provided, + * all non-default valued fields in + * [config][google.cloud.speech.v2.StreamingRecognitionConfig.config] override + * the values in the Recognizer for this recognition request. If a mask is + * provided, only the fields listed in the mask override the config in the + * Recognizer for this recognition request. If a wildcard (`*`) is provided, + * [config][google.cloud.speech.v2.StreamingRecognitionConfig.config] + * completely overrides and replaces the config in the recognizer for this + * recognition request. + * + * Generated from protobuf field .google.protobuf.FieldMask config_mask = 3; + * @param \Google\Protobuf\FieldMask $var + * @return $this + */ + public function setConfigMask($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); + $this->config_mask = $var; + + return $this; + } + + /** + * Speech recognition features to enable specific to streaming audio + * recognition requests. + * + * Generated from protobuf field .google.cloud.speech.v2.StreamingRecognitionFeatures streaming_features = 2; + * @return \Google\Cloud\Speech\V2\StreamingRecognitionFeatures|null + */ + public function getStreamingFeatures() + { + return $this->streaming_features; + } + + public function hasStreamingFeatures() + { + return isset($this->streaming_features); + } + + public function clearStreamingFeatures() + { + unset($this->streaming_features); + } + + /** + * Speech recognition features to enable specific to streaming audio + * recognition requests. + * + * Generated from protobuf field .google.cloud.speech.v2.StreamingRecognitionFeatures streaming_features = 2; + * @param \Google\Cloud\Speech\V2\StreamingRecognitionFeatures $var + * @return $this + */ + public function setStreamingFeatures($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\StreamingRecognitionFeatures::class); + $this->streaming_features = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognitionFeatures.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognitionFeatures.php new file mode 100644 index 000000000000..4ae1a513ac4f --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognitionFeatures.php @@ -0,0 +1,199 @@ +google.cloud.speech.v2.StreamingRecognitionFeatures + */ +class StreamingRecognitionFeatures extends \Google\Protobuf\Internal\Message +{ + /** + * If `true`, responses with voice activity speech events will be returned as + * they are detected. + * + * Generated from protobuf field bool enable_voice_activity_events = 1; + */ + protected $enable_voice_activity_events = false; + /** + * Whether or not to stream interim results to the client. If set to true, + * interim results will be streamed to the client. Otherwise, only the final + * response will be streamed back. + * + * Generated from protobuf field bool interim_results = 2; + */ + protected $interim_results = false; + /** + * If set, the server will automatically close the stream after the specified + * duration has elapsed after the last VOICE_ACTIVITY speech event has been + * sent. The field `voice_activity_events` must also be set to true. + * + * Generated from protobuf field .google.cloud.speech.v2.StreamingRecognitionFeatures.VoiceActivityTimeout voice_activity_timeout = 3; + */ + protected $voice_activity_timeout = null; + /** + * Optional. Endpointing sensitivity for this stream. + * + * Generated from protobuf field .google.cloud.speech.v2.StreamingRecognitionFeatures.EndpointingSensitivity endpointing_sensitivity = 8 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $endpointing_sensitivity = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type bool $enable_voice_activity_events + * If `true`, responses with voice activity speech events will be returned as + * they are detected. + * @type bool $interim_results + * Whether or not to stream interim results to the client. If set to true, + * interim results will be streamed to the client. Otherwise, only the final + * response will be streamed back. + * @type \Google\Cloud\Speech\V2\StreamingRecognitionFeatures\VoiceActivityTimeout $voice_activity_timeout + * If set, the server will automatically close the stream after the specified + * duration has elapsed after the last VOICE_ACTIVITY speech event has been + * sent. The field `voice_activity_events` must also be set to true. + * @type int $endpointing_sensitivity + * Optional. Endpointing sensitivity for this stream. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * If `true`, responses with voice activity speech events will be returned as + * they are detected. + * + * Generated from protobuf field bool enable_voice_activity_events = 1; + * @return bool + */ + public function getEnableVoiceActivityEvents() + { + return $this->enable_voice_activity_events; + } + + /** + * If `true`, responses with voice activity speech events will be returned as + * they are detected. + * + * Generated from protobuf field bool enable_voice_activity_events = 1; + * @param bool $var + * @return $this + */ + public function setEnableVoiceActivityEvents($var) + { + GPBUtil::checkBool($var); + $this->enable_voice_activity_events = $var; + + return $this; + } + + /** + * Whether or not to stream interim results to the client. If set to true, + * interim results will be streamed to the client. Otherwise, only the final + * response will be streamed back. + * + * Generated from protobuf field bool interim_results = 2; + * @return bool + */ + public function getInterimResults() + { + return $this->interim_results; + } + + /** + * Whether or not to stream interim results to the client. If set to true, + * interim results will be streamed to the client. Otherwise, only the final + * response will be streamed back. + * + * Generated from protobuf field bool interim_results = 2; + * @param bool $var + * @return $this + */ + public function setInterimResults($var) + { + GPBUtil::checkBool($var); + $this->interim_results = $var; + + return $this; + } + + /** + * If set, the server will automatically close the stream after the specified + * duration has elapsed after the last VOICE_ACTIVITY speech event has been + * sent. The field `voice_activity_events` must also be set to true. + * + * Generated from protobuf field .google.cloud.speech.v2.StreamingRecognitionFeatures.VoiceActivityTimeout voice_activity_timeout = 3; + * @return \Google\Cloud\Speech\V2\StreamingRecognitionFeatures\VoiceActivityTimeout|null + */ + public function getVoiceActivityTimeout() + { + return $this->voice_activity_timeout; + } + + public function hasVoiceActivityTimeout() + { + return isset($this->voice_activity_timeout); + } + + public function clearVoiceActivityTimeout() + { + unset($this->voice_activity_timeout); + } + + /** + * If set, the server will automatically close the stream after the specified + * duration has elapsed after the last VOICE_ACTIVITY speech event has been + * sent. The field `voice_activity_events` must also be set to true. + * + * Generated from protobuf field .google.cloud.speech.v2.StreamingRecognitionFeatures.VoiceActivityTimeout voice_activity_timeout = 3; + * @param \Google\Cloud\Speech\V2\StreamingRecognitionFeatures\VoiceActivityTimeout $var + * @return $this + */ + public function setVoiceActivityTimeout($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\StreamingRecognitionFeatures\VoiceActivityTimeout::class); + $this->voice_activity_timeout = $var; + + return $this; + } + + /** + * Optional. Endpointing sensitivity for this stream. + * + * Generated from protobuf field .google.cloud.speech.v2.StreamingRecognitionFeatures.EndpointingSensitivity endpointing_sensitivity = 8 [(.google.api.field_behavior) = OPTIONAL]; + * @return int + */ + public function getEndpointingSensitivity() + { + return $this->endpointing_sensitivity; + } + + /** + * Optional. Endpointing sensitivity for this stream. + * + * Generated from protobuf field .google.cloud.speech.v2.StreamingRecognitionFeatures.EndpointingSensitivity endpointing_sensitivity = 8 [(.google.api.field_behavior) = OPTIONAL]; + * @param int $var + * @return $this + */ + public function setEndpointingSensitivity($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Speech\V2\StreamingRecognitionFeatures\EndpointingSensitivity::class); + $this->endpointing_sensitivity = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognitionFeatures/EndpointingSensitivity.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognitionFeatures/EndpointingSensitivity.php new file mode 100644 index 000000000000..1d90bf17eca9 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognitionFeatures/EndpointingSensitivity.php @@ -0,0 +1,75 @@ +google.cloud.speech.v2.StreamingRecognitionFeatures.EndpointingSensitivity + */ +class EndpointingSensitivity +{ + /** + * If no value is specified, the values for + * ENDPOINTING_SENSITIVITY_STANDARD will be used. + * + * Generated from protobuf enum ENDPOINTING_SENSITIVITY_UNSPECIFIED = 0; + */ + const ENDPOINTING_SENSITIVITY_UNSPECIFIED = 0; + /** + * Standard sensitivity, no optimization for latency. + * + * Generated from protobuf enum ENDPOINTING_SENSITIVITY_STANDARD = 1; + */ + const ENDPOINTING_SENSITIVITY_STANDARD = 1; + /** + * Super short sensitivity, optimized for super short utterances like single + * words ("Yes", "No", "Hello", etc.) or a single phrase, command or short + * query (e.g. "check balance", "five dollars", "call Mom"). + * + * Generated from protobuf enum ENDPOINTING_SENSITIVITY_SUPERSHORT = 2; + */ + const ENDPOINTING_SENSITIVITY_SUPERSHORT = 2; + /** + * Short sensitivity, optimized for short utterances like single sentences. + * (e.g. "Remind me to call the dentist tomorrow morning at nine", + * "Navigate to the nearest coffee shop that is currently open") + * + * Generated from protobuf enum ENDPOINTING_SENSITIVITY_SHORT = 3; + */ + const ENDPOINTING_SENSITIVITY_SHORT = 3; + + private static $valueToName = [ + self::ENDPOINTING_SENSITIVITY_UNSPECIFIED => 'ENDPOINTING_SENSITIVITY_UNSPECIFIED', + self::ENDPOINTING_SENSITIVITY_STANDARD => 'ENDPOINTING_SENSITIVITY_STANDARD', + self::ENDPOINTING_SENSITIVITY_SUPERSHORT => 'ENDPOINTING_SENSITIVITY_SUPERSHORT', + self::ENDPOINTING_SENSITIVITY_SHORT => 'ENDPOINTING_SENSITIVITY_SHORT', + ]; + + 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/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognitionFeatures/VoiceActivityTimeout.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognitionFeatures/VoiceActivityTimeout.php new file mode 100644 index 000000000000..e5b711ff4cd6 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognitionFeatures/VoiceActivityTimeout.php @@ -0,0 +1,137 @@ +google.cloud.speech.v2.StreamingRecognitionFeatures.VoiceActivityTimeout + */ +class VoiceActivityTimeout extends \Google\Protobuf\Internal\Message +{ + /** + * Duration to timeout the stream if no speech begins. If this is set and + * no speech is detected in this duration at the start of the stream, the + * server will close the stream. + * + * Generated from protobuf field .google.protobuf.Duration speech_start_timeout = 1; + */ + protected $speech_start_timeout = null; + /** + * Duration to timeout the stream after speech ends. If this is set and no + * speech is detected in this duration after speech was detected, the server + * will close the stream. + * + * Generated from protobuf field .google.protobuf.Duration speech_end_timeout = 2; + */ + protected $speech_end_timeout = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Protobuf\Duration $speech_start_timeout + * Duration to timeout the stream if no speech begins. If this is set and + * no speech is detected in this duration at the start of the stream, the + * server will close the stream. + * @type \Google\Protobuf\Duration $speech_end_timeout + * Duration to timeout the stream after speech ends. If this is set and no + * speech is detected in this duration after speech was detected, the server + * will close the stream. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Duration to timeout the stream if no speech begins. If this is set and + * no speech is detected in this duration at the start of the stream, the + * server will close the stream. + * + * Generated from protobuf field .google.protobuf.Duration speech_start_timeout = 1; + * @return \Google\Protobuf\Duration|null + */ + public function getSpeechStartTimeout() + { + return $this->speech_start_timeout; + } + + public function hasSpeechStartTimeout() + { + return isset($this->speech_start_timeout); + } + + public function clearSpeechStartTimeout() + { + unset($this->speech_start_timeout); + } + + /** + * Duration to timeout the stream if no speech begins. If this is set and + * no speech is detected in this duration at the start of the stream, the + * server will close the stream. + * + * Generated from protobuf field .google.protobuf.Duration speech_start_timeout = 1; + * @param \Google\Protobuf\Duration $var + * @return $this + */ + public function setSpeechStartTimeout($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); + $this->speech_start_timeout = $var; + + return $this; + } + + /** + * Duration to timeout the stream after speech ends. If this is set and no + * speech is detected in this duration after speech was detected, the server + * will close the stream. + * + * Generated from protobuf field .google.protobuf.Duration speech_end_timeout = 2; + * @return \Google\Protobuf\Duration|null + */ + public function getSpeechEndTimeout() + { + return $this->speech_end_timeout; + } + + public function hasSpeechEndTimeout() + { + return isset($this->speech_end_timeout); + } + + public function clearSpeechEndTimeout() + { + unset($this->speech_end_timeout); + } + + /** + * Duration to timeout the stream after speech ends. If this is set and no + * speech is detected in this duration after speech was detected, the server + * will close the stream. + * + * Generated from protobuf field .google.protobuf.Duration speech_end_timeout = 2; + * @param \Google\Protobuf\Duration $var + * @return $this + */ + public function setSpeechEndTimeout($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); + $this->speech_end_timeout = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognitionResult.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognitionResult.php new file mode 100644 index 000000000000..d05932b7e0bd --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognitionResult.php @@ -0,0 +1,320 @@ +google.cloud.speech.v2.StreamingRecognitionResult + */ +class StreamingRecognitionResult extends \Google\Protobuf\Internal\Message +{ + /** + * May contain one or more recognition hypotheses. These alternatives are + * ordered in terms of accuracy, with the top (first) alternative being the + * most probable, as ranked by the recognizer. + * + * Generated from protobuf field repeated .google.cloud.speech.v2.SpeechRecognitionAlternative alternatives = 1; + */ + private $alternatives; + /** + * If `false`, this + * [StreamingRecognitionResult][google.cloud.speech.v2.StreamingRecognitionResult] + * represents an interim result that may change. If `true`, this is the final + * time the speech service will return this particular + * [StreamingRecognitionResult][google.cloud.speech.v2.StreamingRecognitionResult], + * the recognizer will not return any further hypotheses for this portion of + * the transcript and corresponding audio. + * + * Generated from protobuf field bool is_final = 2; + */ + protected $is_final = false; + /** + * An estimate of the likelihood that the recognizer will not change its guess + * about this interim result. Values range from 0.0 (completely unstable) + * to 1.0 (completely stable). This field is only provided for interim results + * ([is_final][google.cloud.speech.v2.StreamingRecognitionResult.is_final]=`false`). + * The default of 0.0 is a sentinel value indicating `stability` was not set. + * + * Generated from protobuf field float stability = 3; + */ + protected $stability = 0.0; + /** + * Time offset of the end of this result relative to the beginning of the + * audio. + * + * Generated from protobuf field .google.protobuf.Duration result_end_offset = 4; + */ + protected $result_end_offset = null; + /** + * For multi-channel audio, this is the channel number corresponding to the + * recognized result for the audio from that channel. + * For + * `audio_channel_count` = `N`, its output values can range from `1` to `N`. + * + * Generated from protobuf field int32 channel_tag = 5; + */ + protected $channel_tag = 0; + /** + * Output only. The [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) + * language tag of the language in this result. This language code was + * detected to have the most likelihood of being spoken in the audio. + * + * Generated from protobuf field string language_code = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $language_code = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Speech\V2\SpeechRecognitionAlternative[] $alternatives + * May contain one or more recognition hypotheses. These alternatives are + * ordered in terms of accuracy, with the top (first) alternative being the + * most probable, as ranked by the recognizer. + * @type bool $is_final + * If `false`, this + * [StreamingRecognitionResult][google.cloud.speech.v2.StreamingRecognitionResult] + * represents an interim result that may change. If `true`, this is the final + * time the speech service will return this particular + * [StreamingRecognitionResult][google.cloud.speech.v2.StreamingRecognitionResult], + * the recognizer will not return any further hypotheses for this portion of + * the transcript and corresponding audio. + * @type float $stability + * An estimate of the likelihood that the recognizer will not change its guess + * about this interim result. Values range from 0.0 (completely unstable) + * to 1.0 (completely stable). This field is only provided for interim results + * ([is_final][google.cloud.speech.v2.StreamingRecognitionResult.is_final]=`false`). + * The default of 0.0 is a sentinel value indicating `stability` was not set. + * @type \Google\Protobuf\Duration $result_end_offset + * Time offset of the end of this result relative to the beginning of the + * audio. + * @type int $channel_tag + * For multi-channel audio, this is the channel number corresponding to the + * recognized result for the audio from that channel. + * For + * `audio_channel_count` = `N`, its output values can range from `1` to `N`. + * @type string $language_code + * Output only. The [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) + * language tag of the language in this result. This language code was + * detected to have the most likelihood of being spoken in the audio. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * May contain one or more recognition hypotheses. These alternatives are + * ordered in terms of accuracy, with the top (first) alternative being the + * most probable, as ranked by the recognizer. + * + * Generated from protobuf field repeated .google.cloud.speech.v2.SpeechRecognitionAlternative alternatives = 1; + * @return RepeatedField<\Google\Cloud\Speech\V2\SpeechRecognitionAlternative> + */ + public function getAlternatives() + { + return $this->alternatives; + } + + /** + * May contain one or more recognition hypotheses. These alternatives are + * ordered in terms of accuracy, with the top (first) alternative being the + * most probable, as ranked by the recognizer. + * + * Generated from protobuf field repeated .google.cloud.speech.v2.SpeechRecognitionAlternative alternatives = 1; + * @param \Google\Cloud\Speech\V2\SpeechRecognitionAlternative[] $var + * @return $this + */ + public function setAlternatives($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Speech\V2\SpeechRecognitionAlternative::class); + $this->alternatives = $arr; + + return $this; + } + + /** + * If `false`, this + * [StreamingRecognitionResult][google.cloud.speech.v2.StreamingRecognitionResult] + * represents an interim result that may change. If `true`, this is the final + * time the speech service will return this particular + * [StreamingRecognitionResult][google.cloud.speech.v2.StreamingRecognitionResult], + * the recognizer will not return any further hypotheses for this portion of + * the transcript and corresponding audio. + * + * Generated from protobuf field bool is_final = 2; + * @return bool + */ + public function getIsFinal() + { + return $this->is_final; + } + + /** + * If `false`, this + * [StreamingRecognitionResult][google.cloud.speech.v2.StreamingRecognitionResult] + * represents an interim result that may change. If `true`, this is the final + * time the speech service will return this particular + * [StreamingRecognitionResult][google.cloud.speech.v2.StreamingRecognitionResult], + * the recognizer will not return any further hypotheses for this portion of + * the transcript and corresponding audio. + * + * Generated from protobuf field bool is_final = 2; + * @param bool $var + * @return $this + */ + public function setIsFinal($var) + { + GPBUtil::checkBool($var); + $this->is_final = $var; + + return $this; + } + + /** + * An estimate of the likelihood that the recognizer will not change its guess + * about this interim result. Values range from 0.0 (completely unstable) + * to 1.0 (completely stable). This field is only provided for interim results + * ([is_final][google.cloud.speech.v2.StreamingRecognitionResult.is_final]=`false`). + * The default of 0.0 is a sentinel value indicating `stability` was not set. + * + * Generated from protobuf field float stability = 3; + * @return float + */ + public function getStability() + { + return $this->stability; + } + + /** + * An estimate of the likelihood that the recognizer will not change its guess + * about this interim result. Values range from 0.0 (completely unstable) + * to 1.0 (completely stable). This field is only provided for interim results + * ([is_final][google.cloud.speech.v2.StreamingRecognitionResult.is_final]=`false`). + * The default of 0.0 is a sentinel value indicating `stability` was not set. + * + * Generated from protobuf field float stability = 3; + * @param float $var + * @return $this + */ + public function setStability($var) + { + GPBUtil::checkFloat($var); + $this->stability = $var; + + return $this; + } + + /** + * Time offset of the end of this result relative to the beginning of the + * audio. + * + * Generated from protobuf field .google.protobuf.Duration result_end_offset = 4; + * @return \Google\Protobuf\Duration|null + */ + public function getResultEndOffset() + { + return $this->result_end_offset; + } + + public function hasResultEndOffset() + { + return isset($this->result_end_offset); + } + + public function clearResultEndOffset() + { + unset($this->result_end_offset); + } + + /** + * Time offset of the end of this result relative to the beginning of the + * audio. + * + * Generated from protobuf field .google.protobuf.Duration result_end_offset = 4; + * @param \Google\Protobuf\Duration $var + * @return $this + */ + public function setResultEndOffset($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); + $this->result_end_offset = $var; + + return $this; + } + + /** + * For multi-channel audio, this is the channel number corresponding to the + * recognized result for the audio from that channel. + * For + * `audio_channel_count` = `N`, its output values can range from `1` to `N`. + * + * Generated from protobuf field int32 channel_tag = 5; + * @return int + */ + public function getChannelTag() + { + return $this->channel_tag; + } + + /** + * For multi-channel audio, this is the channel number corresponding to the + * recognized result for the audio from that channel. + * For + * `audio_channel_count` = `N`, its output values can range from `1` to `N`. + * + * Generated from protobuf field int32 channel_tag = 5; + * @param int $var + * @return $this + */ + public function setChannelTag($var) + { + GPBUtil::checkInt32($var); + $this->channel_tag = $var; + + return $this; + } + + /** + * Output only. The [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) + * language tag of the language in this result. This language code was + * detected to have the most likelihood of being spoken in the audio. + * + * Generated from protobuf field string language_code = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getLanguageCode() + { + return $this->language_code; + } + + /** + * Output only. The [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) + * language tag of the language in this result. This language code was + * detected to have the most likelihood of being spoken in the audio. + * + * Generated from protobuf field string language_code = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setLanguageCode($var) + { + GPBUtil::checkString($var, True); + $this->language_code = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognizeRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognizeRequest.php new file mode 100644 index 000000000000..7555eef97584 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognizeRequest.php @@ -0,0 +1,180 @@ +google.cloud.speech.v2.StreamingRecognizeRequest + */ +class StreamingRecognizeRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the Recognizer to use during recognition. The + * expected format is + * `projects/{project}/locations/{location}/recognizers/{recognizer}`. The + * {recognizer} segment may be set to `_` to use an empty implicit Recognizer. + * + * Generated from protobuf field string recognizer = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $recognizer = ''; + protected $streaming_request; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $recognizer + * Required. The name of the Recognizer to use during recognition. The + * expected format is + * `projects/{project}/locations/{location}/recognizers/{recognizer}`. The + * {recognizer} segment may be set to `_` to use an empty implicit Recognizer. + * @type \Google\Cloud\Speech\V2\StreamingRecognitionConfig $streaming_config + * StreamingRecognitionConfig to be used in this recognition attempt. + * If provided, it will override the default RecognitionConfig stored in the + * Recognizer. + * @type string $audio + * Inline audio bytes to be Recognized. + * Maximum size for this field is 15 KB per request. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the Recognizer to use during recognition. The + * expected format is + * `projects/{project}/locations/{location}/recognizers/{recognizer}`. The + * {recognizer} segment may be set to `_` to use an empty implicit Recognizer. + * + * Generated from protobuf field string recognizer = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getRecognizer() + { + return $this->recognizer; + } + + /** + * Required. The name of the Recognizer to use during recognition. The + * expected format is + * `projects/{project}/locations/{location}/recognizers/{recognizer}`. The + * {recognizer} segment may be set to `_` to use an empty implicit Recognizer. + * + * Generated from protobuf field string recognizer = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setRecognizer($var) + { + GPBUtil::checkString($var, True); + $this->recognizer = $var; + + return $this; + } + + /** + * StreamingRecognitionConfig to be used in this recognition attempt. + * If provided, it will override the default RecognitionConfig stored in the + * Recognizer. + * + * Generated from protobuf field .google.cloud.speech.v2.StreamingRecognitionConfig streaming_config = 6; + * @return \Google\Cloud\Speech\V2\StreamingRecognitionConfig|null + */ + public function getStreamingConfig() + { + return $this->readOneof(6); + } + + public function hasStreamingConfig() + { + return $this->hasOneof(6); + } + + /** + * StreamingRecognitionConfig to be used in this recognition attempt. + * If provided, it will override the default RecognitionConfig stored in the + * Recognizer. + * + * Generated from protobuf field .google.cloud.speech.v2.StreamingRecognitionConfig streaming_config = 6; + * @param \Google\Cloud\Speech\V2\StreamingRecognitionConfig $var + * @return $this + */ + public function setStreamingConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\StreamingRecognitionConfig::class); + $this->writeOneof(6, $var); + + return $this; + } + + /** + * Inline audio bytes to be Recognized. + * Maximum size for this field is 15 KB per request. + * + * Generated from protobuf field bytes audio = 5; + * @return string + */ + public function getAudio() + { + return $this->readOneof(5); + } + + public function hasAudio() + { + return $this->hasOneof(5); + } + + /** + * Inline audio bytes to be Recognized. + * Maximum size for this field is 15 KB per request. + * + * Generated from protobuf field bytes audio = 5; + * @param string $var + * @return $this + */ + public function setAudio($var) + { + GPBUtil::checkString($var, False); + $this->writeOneof(5, $var); + + return $this; + } + + /** + * @return string + */ + public function getStreamingRequest() + { + return $this->whichOneof("streaming_request"); + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognizeResponse.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognizeResponse.php new file mode 100644 index 000000000000..ce2d5e061ab2 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognizeResponse.php @@ -0,0 +1,247 @@ +google.cloud.speech.v2.StreamingRecognizeResponse + */ +class StreamingRecognizeResponse extends \Google\Protobuf\Internal\Message +{ + /** + * This repeated list contains zero or more results that + * correspond to consecutive portions of the audio currently being processed. + * It contains zero or one + * [is_final][google.cloud.speech.v2.StreamingRecognitionResult.is_final]=`true` + * result (the newly settled portion), followed by zero or more + * [is_final][google.cloud.speech.v2.StreamingRecognitionResult.is_final]=`false` + * results (the interim results). + * + * Generated from protobuf field repeated .google.cloud.speech.v2.StreamingRecognitionResult results = 6; + */ + private $results; + /** + * Indicates the type of speech event. + * + * Generated from protobuf field .google.cloud.speech.v2.StreamingRecognizeResponse.SpeechEventType speech_event_type = 3; + */ + protected $speech_event_type = 0; + /** + * Time offset between the beginning of the audio and event emission. + * + * Generated from protobuf field .google.protobuf.Duration speech_event_offset = 7; + */ + protected $speech_event_offset = null; + /** + * Metadata about the recognition. + * + * Generated from protobuf field .google.cloud.speech.v2.RecognitionResponseMetadata metadata = 5; + */ + protected $metadata = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Speech\V2\StreamingRecognitionResult[] $results + * This repeated list contains zero or more results that + * correspond to consecutive portions of the audio currently being processed. + * It contains zero or one + * [is_final][google.cloud.speech.v2.StreamingRecognitionResult.is_final]=`true` + * result (the newly settled portion), followed by zero or more + * [is_final][google.cloud.speech.v2.StreamingRecognitionResult.is_final]=`false` + * results (the interim results). + * @type int $speech_event_type + * Indicates the type of speech event. + * @type \Google\Protobuf\Duration $speech_event_offset + * Time offset between the beginning of the audio and event emission. + * @type \Google\Cloud\Speech\V2\RecognitionResponseMetadata $metadata + * Metadata about the recognition. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * This repeated list contains zero or more results that + * correspond to consecutive portions of the audio currently being processed. + * It contains zero or one + * [is_final][google.cloud.speech.v2.StreamingRecognitionResult.is_final]=`true` + * result (the newly settled portion), followed by zero or more + * [is_final][google.cloud.speech.v2.StreamingRecognitionResult.is_final]=`false` + * results (the interim results). + * + * Generated from protobuf field repeated .google.cloud.speech.v2.StreamingRecognitionResult results = 6; + * @return RepeatedField<\Google\Cloud\Speech\V2\StreamingRecognitionResult> + */ + public function getResults() + { + return $this->results; + } + + /** + * This repeated list contains zero or more results that + * correspond to consecutive portions of the audio currently being processed. + * It contains zero or one + * [is_final][google.cloud.speech.v2.StreamingRecognitionResult.is_final]=`true` + * result (the newly settled portion), followed by zero or more + * [is_final][google.cloud.speech.v2.StreamingRecognitionResult.is_final]=`false` + * results (the interim results). + * + * Generated from protobuf field repeated .google.cloud.speech.v2.StreamingRecognitionResult results = 6; + * @param \Google\Cloud\Speech\V2\StreamingRecognitionResult[] $var + * @return $this + */ + public function setResults($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Speech\V2\StreamingRecognitionResult::class); + $this->results = $arr; + + return $this; + } + + /** + * Indicates the type of speech event. + * + * Generated from protobuf field .google.cloud.speech.v2.StreamingRecognizeResponse.SpeechEventType speech_event_type = 3; + * @return int + */ + public function getSpeechEventType() + { + return $this->speech_event_type; + } + + /** + * Indicates the type of speech event. + * + * Generated from protobuf field .google.cloud.speech.v2.StreamingRecognizeResponse.SpeechEventType speech_event_type = 3; + * @param int $var + * @return $this + */ + public function setSpeechEventType($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\Speech\V2\StreamingRecognizeResponse\SpeechEventType::class); + $this->speech_event_type = $var; + + return $this; + } + + /** + * Time offset between the beginning of the audio and event emission. + * + * Generated from protobuf field .google.protobuf.Duration speech_event_offset = 7; + * @return \Google\Protobuf\Duration|null + */ + public function getSpeechEventOffset() + { + return $this->speech_event_offset; + } + + public function hasSpeechEventOffset() + { + return isset($this->speech_event_offset); + } + + public function clearSpeechEventOffset() + { + unset($this->speech_event_offset); + } + + /** + * Time offset between the beginning of the audio and event emission. + * + * Generated from protobuf field .google.protobuf.Duration speech_event_offset = 7; + * @param \Google\Protobuf\Duration $var + * @return $this + */ + public function setSpeechEventOffset($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); + $this->speech_event_offset = $var; + + return $this; + } + + /** + * Metadata about the recognition. + * + * Generated from protobuf field .google.cloud.speech.v2.RecognitionResponseMetadata metadata = 5; + * @return \Google\Cloud\Speech\V2\RecognitionResponseMetadata|null + */ + public function getMetadata() + { + return $this->metadata; + } + + public function hasMetadata() + { + return isset($this->metadata); + } + + public function clearMetadata() + { + unset($this->metadata); + } + + /** + * Metadata about the recognition. + * + * Generated from protobuf field .google.cloud.speech.v2.RecognitionResponseMetadata metadata = 5; + * @param \Google\Cloud\Speech\V2\RecognitionResponseMetadata $var + * @return $this + */ + public function setMetadata($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\RecognitionResponseMetadata::class); + $this->metadata = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognizeResponse/SpeechEventType.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognizeResponse/SpeechEventType.php new file mode 100644 index 000000000000..4d09423db8da --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognizeResponse/SpeechEventType.php @@ -0,0 +1,79 @@ +google.cloud.speech.v2.StreamingRecognizeResponse.SpeechEventType + */ +class SpeechEventType +{ + /** + * No speech event specified. + * + * Generated from protobuf enum SPEECH_EVENT_TYPE_UNSPECIFIED = 0; + */ + const SPEECH_EVENT_TYPE_UNSPECIFIED = 0; + /** + * This event indicates that the server has detected the end of the user's + * speech utterance and expects no additional speech. Therefore, the server + * will not process additional audio and will close the gRPC bidirectional + * stream. This event is only sent if there was a force cutoff due to + * silence being detected early. This event is only available through the + * `latest_short` [model][google.cloud.speech.v2.Recognizer.model]. + * + * Generated from protobuf enum END_OF_SINGLE_UTTERANCE = 1; + */ + const END_OF_SINGLE_UTTERANCE = 1; + /** + * This event indicates that the server has detected the beginning of human + * voice activity in the stream. This event can be returned multiple times + * if speech starts and stops repeatedly throughout the stream. This event + * is only sent if `voice_activity_events` is set to true. + * + * Generated from protobuf enum SPEECH_ACTIVITY_BEGIN = 2; + */ + const SPEECH_ACTIVITY_BEGIN = 2; + /** + * This event indicates that the server has detected the end of human voice + * activity in the stream. This event can be returned multiple times if + * speech starts and stops repeatedly throughout the stream. This event is + * only sent if `voice_activity_events` is set to true. + * + * Generated from protobuf enum SPEECH_ACTIVITY_END = 3; + */ + const SPEECH_ACTIVITY_END = 3; + + private static $valueToName = [ + self::SPEECH_EVENT_TYPE_UNSPECIFIED => 'SPEECH_EVENT_TYPE_UNSPECIFIED', + self::END_OF_SINGLE_UTTERANCE => 'END_OF_SINGLE_UTTERANCE', + self::SPEECH_ACTIVITY_BEGIN => 'SPEECH_ACTIVITY_BEGIN', + self::SPEECH_ACTIVITY_END => 'SPEECH_ACTIVITY_END', + ]; + + 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/Speech/v2/proto/src/Google/Cloud/Speech/V2/TranscriptNormalization.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/TranscriptNormalization.php new file mode 100644 index 000000000000..8b6ccebc21cd --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/TranscriptNormalization.php @@ -0,0 +1,82 @@ + 0.8) and final transcripts. + * + * Generated from protobuf message google.cloud.speech.v2.TranscriptNormalization + */ +class TranscriptNormalization extends \Google\Protobuf\Internal\Message +{ + /** + * A list of replacement entries. We will perform replacement with one entry + * at a time. For example, the second entry in ["cat" => "dog", "mountain cat" + * => "mountain dog"] will never be applied because we will always process the + * first entry before it. At most 100 entries. + * + * Generated from protobuf field repeated .google.cloud.speech.v2.TranscriptNormalization.Entry entries = 1; + */ + private $entries; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Speech\V2\TranscriptNormalization\Entry[] $entries + * A list of replacement entries. We will perform replacement with one entry + * at a time. For example, the second entry in ["cat" => "dog", "mountain cat" + * => "mountain dog"] will never be applied because we will always process the + * first entry before it. At most 100 entries. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * A list of replacement entries. We will perform replacement with one entry + * at a time. For example, the second entry in ["cat" => "dog", "mountain cat" + * => "mountain dog"] will never be applied because we will always process the + * first entry before it. At most 100 entries. + * + * Generated from protobuf field repeated .google.cloud.speech.v2.TranscriptNormalization.Entry entries = 1; + * @return RepeatedField<\Google\Cloud\Speech\V2\TranscriptNormalization\Entry> + */ + public function getEntries() + { + return $this->entries; + } + + /** + * A list of replacement entries. We will perform replacement with one entry + * at a time. For example, the second entry in ["cat" => "dog", "mountain cat" + * => "mountain dog"] will never be applied because we will always process the + * first entry before it. At most 100 entries. + * + * Generated from protobuf field repeated .google.cloud.speech.v2.TranscriptNormalization.Entry entries = 1; + * @param \Google\Cloud\Speech\V2\TranscriptNormalization\Entry[] $var + * @return $this + */ + public function setEntries($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Speech\V2\TranscriptNormalization\Entry::class); + $this->entries = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/TranscriptNormalization/Entry.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/TranscriptNormalization/Entry.php new file mode 100644 index 000000000000..266f1a7f7982 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/TranscriptNormalization/Entry.php @@ -0,0 +1,135 @@ +google.cloud.speech.v2.TranscriptNormalization.Entry + */ +class Entry extends \Google\Protobuf\Internal\Message +{ + /** + * What to replace. Max length is 100 characters. + * + * Generated from protobuf field string search = 1; + */ + protected $search = ''; + /** + * What to replace with. Max length is 100 characters. + * + * Generated from protobuf field string replace = 2; + */ + protected $replace = ''; + /** + * Whether the search is case sensitive. + * + * Generated from protobuf field bool case_sensitive = 3; + */ + protected $case_sensitive = false; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $search + * What to replace. Max length is 100 characters. + * @type string $replace + * What to replace with. Max length is 100 characters. + * @type bool $case_sensitive + * Whether the search is case sensitive. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * What to replace. Max length is 100 characters. + * + * Generated from protobuf field string search = 1; + * @return string + */ + public function getSearch() + { + return $this->search; + } + + /** + * What to replace. Max length is 100 characters. + * + * Generated from protobuf field string search = 1; + * @param string $var + * @return $this + */ + public function setSearch($var) + { + GPBUtil::checkString($var, True); + $this->search = $var; + + return $this; + } + + /** + * What to replace with. Max length is 100 characters. + * + * Generated from protobuf field string replace = 2; + * @return string + */ + public function getReplace() + { + return $this->replace; + } + + /** + * What to replace with. Max length is 100 characters. + * + * Generated from protobuf field string replace = 2; + * @param string $var + * @return $this + */ + public function setReplace($var) + { + GPBUtil::checkString($var, True); + $this->replace = $var; + + return $this; + } + + /** + * Whether the search is case sensitive. + * + * Generated from protobuf field bool case_sensitive = 3; + * @return bool + */ + public function getCaseSensitive() + { + return $this->case_sensitive; + } + + /** + * Whether the search is case sensitive. + * + * Generated from protobuf field bool case_sensitive = 3; + * @param bool $var + * @return $this + */ + public function setCaseSensitive($var) + { + GPBUtil::checkBool($var); + $this->case_sensitive = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/TranslationConfig.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/TranslationConfig.php new file mode 100644 index 000000000000..5a980886f570 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/TranslationConfig.php @@ -0,0 +1,68 @@ +google.cloud.speech.v2.TranslationConfig + */ +class TranslationConfig extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The language code to translate to. + * + * Generated from protobuf field string target_language = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $target_language = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $target_language + * Required. The language code to translate to. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Required. The language code to translate to. + * + * Generated from protobuf field string target_language = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getTargetLanguage() + { + return $this->target_language; + } + + /** + * Required. The language code to translate to. + * + * Generated from protobuf field string target_language = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setTargetLanguage($var) + { + GPBUtil::checkString($var, True); + $this->target_language = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UndeleteCustomClassRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UndeleteCustomClassRequest.php new file mode 100644 index 000000000000..fd41ece79277 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UndeleteCustomClassRequest.php @@ -0,0 +1,173 @@ +google.cloud.speech.v2.UndeleteCustomClassRequest + */ +class UndeleteCustomClassRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the CustomClass to undelete. + * Format: + * `projects/{project}/locations/{location}/customClasses/{custom_class}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * If set, validate the request and preview the undeleted CustomClass, but do + * not actually undelete it. + * + * Generated from protobuf field bool validate_only = 3; + */ + protected $validate_only = false; + /** + * This checksum is computed by the server based on the value of other + * fields. This may be sent on update, undelete, and delete requests to ensure + * the client has an up-to-date value before proceeding. + * + * Generated from protobuf field string etag = 4; + */ + protected $etag = ''; + + /** + * @param string $name Required. The name of the CustomClass to undelete. + * Format: + * `projects/{project}/locations/{location}/customClasses/{custom_class}` + * Please see {@see SpeechClient::customClassName()} for help formatting this field. + * + * @return \Google\Cloud\Speech\V2\UndeleteCustomClassRequest + * + * @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 CustomClass to undelete. + * Format: + * `projects/{project}/locations/{location}/customClasses/{custom_class}` + * @type bool $validate_only + * If set, validate the request and preview the undeleted CustomClass, but do + * not actually undelete it. + * @type string $etag + * This checksum is computed by the server based on the value of other + * fields. This may be sent on update, undelete, and delete requests to ensure + * the client has an up-to-date value before proceeding. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the CustomClass to undelete. + * Format: + * `projects/{project}/locations/{location}/customClasses/{custom_class}` + * + * 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 CustomClass to undelete. + * Format: + * `projects/{project}/locations/{location}/customClasses/{custom_class}` + * + * 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, validate the request and preview the undeleted CustomClass, but do + * not actually undelete it. + * + * Generated from protobuf field bool validate_only = 3; + * @return bool + */ + public function getValidateOnly() + { + return $this->validate_only; + } + + /** + * If set, validate the request and preview the undeleted CustomClass, but do + * not actually undelete 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; + } + + /** + * This checksum is computed by the server based on the value of other + * fields. This may be sent on update, undelete, and delete requests to ensure + * the client has an up-to-date value before proceeding. + * + * Generated from protobuf field string etag = 4; + * @return string + */ + public function getEtag() + { + return $this->etag; + } + + /** + * This checksum is computed by the server based on the value of other + * fields. This may be sent on update, undelete, and delete requests to ensure + * the client has an up-to-date value before proceeding. + * + * 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/Speech/v2/proto/src/Google/Cloud/Speech/V2/UndeletePhraseSetRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UndeletePhraseSetRequest.php new file mode 100644 index 000000000000..2c448595d447 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UndeletePhraseSetRequest.php @@ -0,0 +1,168 @@ +google.cloud.speech.v2.UndeletePhraseSetRequest + */ +class UndeletePhraseSetRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the PhraseSet to undelete. + * Format: `projects/{project}/locations/{location}/phraseSets/{phrase_set}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * If set, validate the request and preview the undeleted PhraseSet, but do + * not actually undelete it. + * + * Generated from protobuf field bool validate_only = 3; + */ + protected $validate_only = false; + /** + * This checksum is computed by the server based on the value of other + * fields. This may be sent on update, undelete, and delete requests to ensure + * the client has an up-to-date value before proceeding. + * + * Generated from protobuf field string etag = 4; + */ + protected $etag = ''; + + /** + * @param string $name Required. The name of the PhraseSet to undelete. + * Format: `projects/{project}/locations/{location}/phraseSets/{phrase_set}` + * Please see {@see SpeechClient::phraseSetName()} for help formatting this field. + * + * @return \Google\Cloud\Speech\V2\UndeletePhraseSetRequest + * + * @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 PhraseSet to undelete. + * Format: `projects/{project}/locations/{location}/phraseSets/{phrase_set}` + * @type bool $validate_only + * If set, validate the request and preview the undeleted PhraseSet, but do + * not actually undelete it. + * @type string $etag + * This checksum is computed by the server based on the value of other + * fields. This may be sent on update, undelete, and delete requests to ensure + * the client has an up-to-date value before proceeding. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the PhraseSet to undelete. + * Format: `projects/{project}/locations/{location}/phraseSets/{phrase_set}` + * + * 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 PhraseSet to undelete. + * Format: `projects/{project}/locations/{location}/phraseSets/{phrase_set}` + * + * 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, validate the request and preview the undeleted PhraseSet, but do + * not actually undelete it. + * + * Generated from protobuf field bool validate_only = 3; + * @return bool + */ + public function getValidateOnly() + { + return $this->validate_only; + } + + /** + * If set, validate the request and preview the undeleted PhraseSet, but do + * not actually undelete 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; + } + + /** + * This checksum is computed by the server based on the value of other + * fields. This may be sent on update, undelete, and delete requests to ensure + * the client has an up-to-date value before proceeding. + * + * Generated from protobuf field string etag = 4; + * @return string + */ + public function getEtag() + { + return $this->etag; + } + + /** + * This checksum is computed by the server based on the value of other + * fields. This may be sent on update, undelete, and delete requests to ensure + * the client has an up-to-date value before proceeding. + * + * 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/Speech/v2/proto/src/Google/Cloud/Speech/V2/UndeleteRecognizerRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UndeleteRecognizerRequest.php new file mode 100644 index 000000000000..b174c06a152d --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UndeleteRecognizerRequest.php @@ -0,0 +1,168 @@ +google.cloud.speech.v2.UndeleteRecognizerRequest + */ +class UndeleteRecognizerRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the Recognizer to undelete. + * Format: `projects/{project}/locations/{location}/recognizers/{recognizer}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * If set, validate the request and preview the undeleted Recognizer, but do + * not actually undelete it. + * + * Generated from protobuf field bool validate_only = 3; + */ + protected $validate_only = false; + /** + * This checksum is computed by the server based on the value of other + * fields. This may be sent on update, undelete, and delete requests to ensure + * the client has an up-to-date value before proceeding. + * + * Generated from protobuf field string etag = 4; + */ + protected $etag = ''; + + /** + * @param string $name Required. The name of the Recognizer to undelete. + * Format: `projects/{project}/locations/{location}/recognizers/{recognizer}` + * Please see {@see SpeechClient::recognizerName()} for help formatting this field. + * + * @return \Google\Cloud\Speech\V2\UndeleteRecognizerRequest + * + * @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 Recognizer to undelete. + * Format: `projects/{project}/locations/{location}/recognizers/{recognizer}` + * @type bool $validate_only + * If set, validate the request and preview the undeleted Recognizer, but do + * not actually undelete it. + * @type string $etag + * This checksum is computed by the server based on the value of other + * fields. This may be sent on update, undelete, and delete requests to ensure + * the client has an up-to-date value before proceeding. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the Recognizer to undelete. + * Format: `projects/{project}/locations/{location}/recognizers/{recognizer}` + * + * 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 Recognizer to undelete. + * Format: `projects/{project}/locations/{location}/recognizers/{recognizer}` + * + * 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, validate the request and preview the undeleted Recognizer, but do + * not actually undelete it. + * + * Generated from protobuf field bool validate_only = 3; + * @return bool + */ + public function getValidateOnly() + { + return $this->validate_only; + } + + /** + * If set, validate the request and preview the undeleted Recognizer, but do + * not actually undelete 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; + } + + /** + * This checksum is computed by the server based on the value of other + * fields. This may be sent on update, undelete, and delete requests to ensure + * the client has an up-to-date value before proceeding. + * + * Generated from protobuf field string etag = 4; + * @return string + */ + public function getEtag() + { + return $this->etag; + } + + /** + * This checksum is computed by the server based on the value of other + * fields. This may be sent on update, undelete, and delete requests to ensure + * the client has an up-to-date value before proceeding. + * + * 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/Speech/v2/proto/src/Google/Cloud/Speech/V2/UpdateConfigRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UpdateConfigRequest.php new file mode 100644 index 000000000000..72383c2fca69 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UpdateConfigRequest.php @@ -0,0 +1,148 @@ +google.cloud.speech.v2.UpdateConfigRequest + */ +class UpdateConfigRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The config to update. + * The config's `name` field is used to identify the config to be updated. + * The expected format is `projects/{project}/locations/{location}/config`. + * + * Generated from protobuf field .google.cloud.speech.v2.Config config = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $config = null; + /** + * The list of fields to be updated. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + */ + protected $update_mask = null; + + /** + * @param \Google\Cloud\Speech\V2\Config $config Required. The config to update. + * + * The config's `name` field is used to identify the config to be updated. + * The expected format is `projects/{project}/locations/{location}/config`. + * @param \Google\Protobuf\FieldMask $updateMask The list of fields to be updated. + * + * @return \Google\Cloud\Speech\V2\UpdateConfigRequest + * + * @experimental + */ + public static function build(\Google\Cloud\Speech\V2\Config $config, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setConfig($config) + ->setUpdateMask($updateMask); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Speech\V2\Config $config + * Required. The config to update. + * The config's `name` field is used to identify the config to be updated. + * The expected format is `projects/{project}/locations/{location}/config`. + * @type \Google\Protobuf\FieldMask $update_mask + * The list of fields to be updated. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Required. The config to update. + * The config's `name` field is used to identify the config to be updated. + * The expected format is `projects/{project}/locations/{location}/config`. + * + * Generated from protobuf field .google.cloud.speech.v2.Config config = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Speech\V2\Config|null + */ + public function getConfig() + { + return $this->config; + } + + public function hasConfig() + { + return isset($this->config); + } + + public function clearConfig() + { + unset($this->config); + } + + /** + * Required. The config to update. + * The config's `name` field is used to identify the config to be updated. + * The expected format is `projects/{project}/locations/{location}/config`. + * + * Generated from protobuf field .google.cloud.speech.v2.Config config = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Speech\V2\Config $var + * @return $this + */ + public function setConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\Config::class); + $this->config = $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; + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UpdateCustomClassRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UpdateCustomClassRequest.php new file mode 100644 index 000000000000..034469cd91b4 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UpdateCustomClassRequest.php @@ -0,0 +1,196 @@ +google.cloud.speech.v2.UpdateCustomClassRequest + */ +class UpdateCustomClassRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The CustomClass to update. + * The CustomClass's `name` field is used to identify the CustomClass to + * update. Format: + * `projects/{project}/locations/{location}/customClasses/{custom_class}`. + * + * Generated from protobuf field .google.cloud.speech.v2.CustomClass custom_class = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $custom_class = null; + /** + * The list of fields to be updated. If empty, all fields are considered for + * update. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + */ + protected $update_mask = null; + /** + * If set, validate the request and preview the updated CustomClass, but do + * not actually update it. + * + * Generated from protobuf field bool validate_only = 4; + */ + protected $validate_only = false; + + /** + * @param \Google\Cloud\Speech\V2\CustomClass $customClass Required. The CustomClass to update. + * + * The CustomClass's `name` field is used to identify the CustomClass to + * update. Format: + * `projects/{project}/locations/{location}/customClasses/{custom_class}`. + * @param \Google\Protobuf\FieldMask $updateMask The list of fields to be updated. If empty, all fields are considered for + * update. + * + * @return \Google\Cloud\Speech\V2\UpdateCustomClassRequest + * + * @experimental + */ + public static function build(\Google\Cloud\Speech\V2\CustomClass $customClass, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setCustomClass($customClass) + ->setUpdateMask($updateMask); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Speech\V2\CustomClass $custom_class + * Required. The CustomClass to update. + * The CustomClass's `name` field is used to identify the CustomClass to + * update. Format: + * `projects/{project}/locations/{location}/customClasses/{custom_class}`. + * @type \Google\Protobuf\FieldMask $update_mask + * The list of fields to be updated. If empty, all fields are considered for + * update. + * @type bool $validate_only + * If set, validate the request and preview the updated CustomClass, but do + * not actually update it. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Required. The CustomClass to update. + * The CustomClass's `name` field is used to identify the CustomClass to + * update. Format: + * `projects/{project}/locations/{location}/customClasses/{custom_class}`. + * + * Generated from protobuf field .google.cloud.speech.v2.CustomClass custom_class = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Speech\V2\CustomClass|null + */ + public function getCustomClass() + { + return $this->custom_class; + } + + public function hasCustomClass() + { + return isset($this->custom_class); + } + + public function clearCustomClass() + { + unset($this->custom_class); + } + + /** + * Required. The CustomClass to update. + * The CustomClass's `name` field is used to identify the CustomClass to + * update. Format: + * `projects/{project}/locations/{location}/customClasses/{custom_class}`. + * + * Generated from protobuf field .google.cloud.speech.v2.CustomClass custom_class = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Speech\V2\CustomClass $var + * @return $this + */ + public function setCustomClass($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\CustomClass::class); + $this->custom_class = $var; + + return $this; + } + + /** + * The list of fields to be updated. If empty, all fields are considered for + * 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); + } + + /** + * The list of fields to be updated. If empty, all fields are considered for + * 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 updated CustomClass, but do + * not actually update 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 updated CustomClass, but do + * not actually update 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/Speech/v2/proto/src/Google/Cloud/Speech/V2/UpdatePhraseSetRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UpdatePhraseSetRequest.php new file mode 100644 index 000000000000..2e23fe934808 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UpdatePhraseSetRequest.php @@ -0,0 +1,191 @@ +google.cloud.speech.v2.UpdatePhraseSetRequest + */ +class UpdatePhraseSetRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The PhraseSet to update. + * The PhraseSet's `name` field is used to identify the PhraseSet to update. + * Format: `projects/{project}/locations/{location}/phraseSets/{phrase_set}`. + * + * Generated from protobuf field .google.cloud.speech.v2.PhraseSet phrase_set = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $phrase_set = null; + /** + * The list of fields to update. If empty, all non-default valued fields are + * considered for update. Use `*` to update the entire PhraseSet resource. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + */ + protected $update_mask = null; + /** + * If set, validate the request and preview the updated PhraseSet, but do not + * actually update it. + * + * Generated from protobuf field bool validate_only = 4; + */ + protected $validate_only = false; + + /** + * @param \Google\Cloud\Speech\V2\PhraseSet $phraseSet Required. The PhraseSet to update. + * + * The PhraseSet's `name` field is used to identify the PhraseSet to update. + * Format: `projects/{project}/locations/{location}/phraseSets/{phrase_set}`. + * @param \Google\Protobuf\FieldMask $updateMask The list of fields to update. If empty, all non-default valued fields are + * considered for update. Use `*` to update the entire PhraseSet resource. + * + * @return \Google\Cloud\Speech\V2\UpdatePhraseSetRequest + * + * @experimental + */ + public static function build(\Google\Cloud\Speech\V2\PhraseSet $phraseSet, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setPhraseSet($phraseSet) + ->setUpdateMask($updateMask); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Speech\V2\PhraseSet $phrase_set + * Required. The PhraseSet to update. + * The PhraseSet's `name` field is used to identify the PhraseSet to update. + * Format: `projects/{project}/locations/{location}/phraseSets/{phrase_set}`. + * @type \Google\Protobuf\FieldMask $update_mask + * The list of fields to update. If empty, all non-default valued fields are + * considered for update. Use `*` to update the entire PhraseSet resource. + * @type bool $validate_only + * If set, validate the request and preview the updated PhraseSet, but do not + * actually update it. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Required. The PhraseSet to update. + * The PhraseSet's `name` field is used to identify the PhraseSet to update. + * Format: `projects/{project}/locations/{location}/phraseSets/{phrase_set}`. + * + * Generated from protobuf field .google.cloud.speech.v2.PhraseSet phrase_set = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Speech\V2\PhraseSet|null + */ + public function getPhraseSet() + { + return $this->phrase_set; + } + + public function hasPhraseSet() + { + return isset($this->phrase_set); + } + + public function clearPhraseSet() + { + unset($this->phrase_set); + } + + /** + * Required. The PhraseSet to update. + * The PhraseSet's `name` field is used to identify the PhraseSet to update. + * Format: `projects/{project}/locations/{location}/phraseSets/{phrase_set}`. + * + * Generated from protobuf field .google.cloud.speech.v2.PhraseSet phrase_set = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Speech\V2\PhraseSet $var + * @return $this + */ + public function setPhraseSet($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\PhraseSet::class); + $this->phrase_set = $var; + + return $this; + } + + /** + * The list of fields to update. If empty, all non-default valued fields are + * considered for update. Use `*` to update the entire PhraseSet resource. + * + * 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. If empty, all non-default valued fields are + * considered for update. Use `*` to update the entire PhraseSet resource. + * + * 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 updated PhraseSet, but do not + * actually update 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 updated PhraseSet, but do not + * actually update 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/Speech/v2/proto/src/Google/Cloud/Speech/V2/UpdateRecognizerRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UpdateRecognizerRequest.php new file mode 100644 index 000000000000..cf1e9ea1c51a --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UpdateRecognizerRequest.php @@ -0,0 +1,191 @@ +google.cloud.speech.v2.UpdateRecognizerRequest + */ +class UpdateRecognizerRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The Recognizer to update. + * The Recognizer's `name` field is used to identify the Recognizer to update. + * Format: `projects/{project}/locations/{location}/recognizers/{recognizer}`. + * + * Generated from protobuf field .google.cloud.speech.v2.Recognizer recognizer = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $recognizer = null; + /** + * The list of fields to update. If empty, all non-default valued fields are + * considered for update. Use `*` to update the entire Recognizer resource. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; + */ + protected $update_mask = null; + /** + * If set, validate the request and preview the updated Recognizer, but do not + * actually update it. + * + * Generated from protobuf field bool validate_only = 4; + */ + protected $validate_only = false; + + /** + * @param \Google\Cloud\Speech\V2\Recognizer $recognizer Required. The Recognizer to update. + * + * The Recognizer's `name` field is used to identify the Recognizer to update. + * Format: `projects/{project}/locations/{location}/recognizers/{recognizer}`. + * @param \Google\Protobuf\FieldMask $updateMask The list of fields to update. If empty, all non-default valued fields are + * considered for update. Use `*` to update the entire Recognizer resource. + * + * @return \Google\Cloud\Speech\V2\UpdateRecognizerRequest + * + * @experimental + */ + public static function build(\Google\Cloud\Speech\V2\Recognizer $recognizer, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setRecognizer($recognizer) + ->setUpdateMask($updateMask); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\Speech\V2\Recognizer $recognizer + * Required. The Recognizer to update. + * The Recognizer's `name` field is used to identify the Recognizer to update. + * Format: `projects/{project}/locations/{location}/recognizers/{recognizer}`. + * @type \Google\Protobuf\FieldMask $update_mask + * The list of fields to update. If empty, all non-default valued fields are + * considered for update. Use `*` to update the entire Recognizer resource. + * @type bool $validate_only + * If set, validate the request and preview the updated Recognizer, but do not + * actually update it. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Required. The Recognizer to update. + * The Recognizer's `name` field is used to identify the Recognizer to update. + * Format: `projects/{project}/locations/{location}/recognizers/{recognizer}`. + * + * Generated from protobuf field .google.cloud.speech.v2.Recognizer recognizer = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\Speech\V2\Recognizer|null + */ + public function getRecognizer() + { + return $this->recognizer; + } + + public function hasRecognizer() + { + return isset($this->recognizer); + } + + public function clearRecognizer() + { + unset($this->recognizer); + } + + /** + * Required. The Recognizer to update. + * The Recognizer's `name` field is used to identify the Recognizer to update. + * Format: `projects/{project}/locations/{location}/recognizers/{recognizer}`. + * + * Generated from protobuf field .google.cloud.speech.v2.Recognizer recognizer = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\Speech\V2\Recognizer $var + * @return $this + */ + public function setRecognizer($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\Recognizer::class); + $this->recognizer = $var; + + return $this; + } + + /** + * The list of fields to update. If empty, all non-default valued fields are + * considered for update. Use `*` to update the entire Recognizer resource. + * + * 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. If empty, all non-default valued fields are + * considered for update. Use `*` to update the entire Recognizer resource. + * + * 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 updated Recognizer, but do not + * actually update 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 updated Recognizer, but do not + * actually update 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/Speech/v2/proto/src/Google/Cloud/Speech/V2/VttOutputFileFormatConfig.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/VttOutputFileFormatConfig.php new file mode 100644 index 000000000000..ddcd270dc0d4 --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/VttOutputFileFormatConfig.php @@ -0,0 +1,34 @@ +google.cloud.speech.v2.VttOutputFileFormatConfig + */ +class VttOutputFileFormatConfig extends \Google\Protobuf\Internal\Message +{ + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + +} + diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/WordInfo.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/WordInfo.php new file mode 100644 index 000000000000..86c599acc13f --- /dev/null +++ b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/WordInfo.php @@ -0,0 +1,307 @@ +google.cloud.speech.v2.WordInfo + */ +class WordInfo extends \Google\Protobuf\Internal\Message +{ + /** + * Time offset relative to the beginning of the audio, + * and corresponding to the start of the spoken word. + * This field is only set if + * [enable_word_time_offsets][google.cloud.speech.v2.RecognitionFeatures.enable_word_time_offsets] + * is `true` and only in the top hypothesis. This is an experimental feature + * and the accuracy of the time offset can vary. + * + * Generated from protobuf field .google.protobuf.Duration start_offset = 1; + */ + protected $start_offset = null; + /** + * Time offset relative to the beginning of the audio, + * and corresponding to the end of the spoken word. + * This field is only set if + * [enable_word_time_offsets][google.cloud.speech.v2.RecognitionFeatures.enable_word_time_offsets] + * is `true` and only in the top hypothesis. This is an experimental feature + * and the accuracy of the time offset can vary. + * + * Generated from protobuf field .google.protobuf.Duration end_offset = 2; + */ + protected $end_offset = null; + /** + * The word corresponding to this set of information. + * + * Generated from protobuf field string word = 3; + */ + protected $word = ''; + /** + * The confidence estimate between 0.0 and 1.0. A higher number + * indicates an estimated greater likelihood that the recognized words are + * correct. This field is set only for the top alternative of a non-streaming + * result or, of a streaming result where + * [is_final][google.cloud.speech.v2.StreamingRecognitionResult.is_final] is + * set to `true`. This field is not guaranteed to be accurate and users should + * not rely on it to be always provided. The default of 0.0 is a sentinel + * value indicating `confidence` was not set. + * + * Generated from protobuf field float confidence = 4; + */ + protected $confidence = 0.0; + /** + * A distinct label is assigned for every speaker within the audio. This field + * specifies which one of those speakers was detected to have spoken this + * word. `speaker_label` is set if + * [SpeakerDiarizationConfig][google.cloud.speech.v2.SpeakerDiarizationConfig] + * is given and only in the top alternative. + * + * Generated from protobuf field string speaker_label = 6; + */ + protected $speaker_label = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Protobuf\Duration $start_offset + * Time offset relative to the beginning of the audio, + * and corresponding to the start of the spoken word. + * This field is only set if + * [enable_word_time_offsets][google.cloud.speech.v2.RecognitionFeatures.enable_word_time_offsets] + * is `true` and only in the top hypothesis. This is an experimental feature + * and the accuracy of the time offset can vary. + * @type \Google\Protobuf\Duration $end_offset + * Time offset relative to the beginning of the audio, + * and corresponding to the end of the spoken word. + * This field is only set if + * [enable_word_time_offsets][google.cloud.speech.v2.RecognitionFeatures.enable_word_time_offsets] + * is `true` and only in the top hypothesis. This is an experimental feature + * and the accuracy of the time offset can vary. + * @type string $word + * The word corresponding to this set of information. + * @type float $confidence + * The confidence estimate between 0.0 and 1.0. A higher number + * indicates an estimated greater likelihood that the recognized words are + * correct. This field is set only for the top alternative of a non-streaming + * result or, of a streaming result where + * [is_final][google.cloud.speech.v2.StreamingRecognitionResult.is_final] is + * set to `true`. This field is not guaranteed to be accurate and users should + * not rely on it to be always provided. The default of 0.0 is a sentinel + * value indicating `confidence` was not set. + * @type string $speaker_label + * A distinct label is assigned for every speaker within the audio. This field + * specifies which one of those speakers was detected to have spoken this + * word. `speaker_label` is set if + * [SpeakerDiarizationConfig][google.cloud.speech.v2.SpeakerDiarizationConfig] + * is given and only in the top alternative. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); + parent::__construct($data); + } + + /** + * Time offset relative to the beginning of the audio, + * and corresponding to the start of the spoken word. + * This field is only set if + * [enable_word_time_offsets][google.cloud.speech.v2.RecognitionFeatures.enable_word_time_offsets] + * is `true` and only in the top hypothesis. This is an experimental feature + * and the accuracy of the time offset can vary. + * + * Generated from protobuf field .google.protobuf.Duration start_offset = 1; + * @return \Google\Protobuf\Duration|null + */ + public function getStartOffset() + { + return $this->start_offset; + } + + public function hasStartOffset() + { + return isset($this->start_offset); + } + + public function clearStartOffset() + { + unset($this->start_offset); + } + + /** + * Time offset relative to the beginning of the audio, + * and corresponding to the start of the spoken word. + * This field is only set if + * [enable_word_time_offsets][google.cloud.speech.v2.RecognitionFeatures.enable_word_time_offsets] + * is `true` and only in the top hypothesis. This is an experimental feature + * and the accuracy of the time offset can vary. + * + * Generated from protobuf field .google.protobuf.Duration start_offset = 1; + * @param \Google\Protobuf\Duration $var + * @return $this + */ + public function setStartOffset($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); + $this->start_offset = $var; + + return $this; + } + + /** + * Time offset relative to the beginning of the audio, + * and corresponding to the end of the spoken word. + * This field is only set if + * [enable_word_time_offsets][google.cloud.speech.v2.RecognitionFeatures.enable_word_time_offsets] + * is `true` and only in the top hypothesis. This is an experimental feature + * and the accuracy of the time offset can vary. + * + * Generated from protobuf field .google.protobuf.Duration end_offset = 2; + * @return \Google\Protobuf\Duration|null + */ + public function getEndOffset() + { + return $this->end_offset; + } + + public function hasEndOffset() + { + return isset($this->end_offset); + } + + public function clearEndOffset() + { + unset($this->end_offset); + } + + /** + * Time offset relative to the beginning of the audio, + * and corresponding to the end of the spoken word. + * This field is only set if + * [enable_word_time_offsets][google.cloud.speech.v2.RecognitionFeatures.enable_word_time_offsets] + * is `true` and only in the top hypothesis. This is an experimental feature + * and the accuracy of the time offset can vary. + * + * Generated from protobuf field .google.protobuf.Duration end_offset = 2; + * @param \Google\Protobuf\Duration $var + * @return $this + */ + public function setEndOffset($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); + $this->end_offset = $var; + + return $this; + } + + /** + * The word corresponding to this set of information. + * + * Generated from protobuf field string word = 3; + * @return string + */ + public function getWord() + { + return $this->word; + } + + /** + * The word corresponding to this set of information. + * + * Generated from protobuf field string word = 3; + * @param string $var + * @return $this + */ + public function setWord($var) + { + GPBUtil::checkString($var, True); + $this->word = $var; + + return $this; + } + + /** + * The confidence estimate between 0.0 and 1.0. A higher number + * indicates an estimated greater likelihood that the recognized words are + * correct. This field is set only for the top alternative of a non-streaming + * result or, of a streaming result where + * [is_final][google.cloud.speech.v2.StreamingRecognitionResult.is_final] is + * set to `true`. This field is not guaranteed to be accurate and users should + * not rely on it to be always provided. The default of 0.0 is a sentinel + * value indicating `confidence` was not set. + * + * Generated from protobuf field float confidence = 4; + * @return float + */ + public function getConfidence() + { + return $this->confidence; + } + + /** + * The confidence estimate between 0.0 and 1.0. A higher number + * indicates an estimated greater likelihood that the recognized words are + * correct. This field is set only for the top alternative of a non-streaming + * result or, of a streaming result where + * [is_final][google.cloud.speech.v2.StreamingRecognitionResult.is_final] is + * set to `true`. This field is not guaranteed to be accurate and users should + * not rely on it to be always provided. The default of 0.0 is a sentinel + * value indicating `confidence` was not set. + * + * Generated from protobuf field float confidence = 4; + * @param float $var + * @return $this + */ + public function setConfidence($var) + { + GPBUtil::checkFloat($var); + $this->confidence = $var; + + return $this; + } + + /** + * A distinct label is assigned for every speaker within the audio. This field + * specifies which one of those speakers was detected to have spoken this + * word. `speaker_label` is set if + * [SpeakerDiarizationConfig][google.cloud.speech.v2.SpeakerDiarizationConfig] + * is given and only in the top alternative. + * + * Generated from protobuf field string speaker_label = 6; + * @return string + */ + public function getSpeakerLabel() + { + return $this->speaker_label; + } + + /** + * A distinct label is assigned for every speaker within the audio. This field + * specifies which one of those speakers was detected to have spoken this + * word. `speaker_label` is set if + * [SpeakerDiarizationConfig][google.cloud.speech.v2.SpeakerDiarizationConfig] + * is given and only in the top alternative. + * + * Generated from protobuf field string speaker_label = 6; + * @param string $var + * @return $this + */ + public function setSpeakerLabel($var) + { + GPBUtil::checkString($var, True); + $this->speaker_label = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/batch_recognize.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/batch_recognize.php new file mode 100644 index 000000000000..65d2ac0db81b --- /dev/null +++ b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/batch_recognize.php @@ -0,0 +1,88 @@ +setRecognizer($formattedRecognizer); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $speechClient->batchRecognize($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var BatchRecognizeResponse $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 +{ + $formattedRecognizer = SpeechClient::recognizerName('[PROJECT]', '[LOCATION]', '[RECOGNIZER]'); + + batch_recognize_sample($formattedRecognizer); +} +// [END speech_v2_generated_Speech_BatchRecognize_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/create_custom_class.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/create_custom_class.php new file mode 100644 index 000000000000..5ff6e27b3b79 --- /dev/null +++ b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/create_custom_class.php @@ -0,0 +1,86 @@ +setCustomClass($customClass) + ->setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $speechClient->createCustomClass($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var CustomClass $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 = SpeechClient::locationName('[PROJECT]', '[LOCATION]'); + + create_custom_class_sample($formattedParent); +} +// [END speech_v2_generated_Speech_CreateCustomClass_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/create_phrase_set.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/create_phrase_set.php new file mode 100644 index 000000000000..445e6537585f --- /dev/null +++ b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/create_phrase_set.php @@ -0,0 +1,86 @@ +setPhraseSet($phraseSet) + ->setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $speechClient->createPhraseSet($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var PhraseSet $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 = SpeechClient::locationName('[PROJECT]', '[LOCATION]'); + + create_phrase_set_sample($formattedParent); +} +// [END speech_v2_generated_Speech_CreatePhraseSet_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/create_recognizer.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/create_recognizer.php new file mode 100644 index 000000000000..f923356ae385 --- /dev/null +++ b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/create_recognizer.php @@ -0,0 +1,86 @@ +setRecognizer($recognizer) + ->setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $speechClient->createRecognizer($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var Recognizer $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 = SpeechClient::locationName('[PROJECT]', '[LOCATION]'); + + create_recognizer_sample($formattedParent); +} +// [END speech_v2_generated_Speech_CreateRecognizer_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/delete_custom_class.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/delete_custom_class.php new file mode 100644 index 000000000000..ba763fbe24e8 --- /dev/null +++ b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/delete_custom_class.php @@ -0,0 +1,85 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $speechClient->deleteCustomClass($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var CustomClass $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 = SpeechClient::customClassName('[PROJECT]', '[LOCATION]', '[CUSTOM_CLASS]'); + + delete_custom_class_sample($formattedName); +} +// [END speech_v2_generated_Speech_DeleteCustomClass_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/delete_phrase_set.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/delete_phrase_set.php new file mode 100644 index 000000000000..12f7de6cb8f1 --- /dev/null +++ b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/delete_phrase_set.php @@ -0,0 +1,84 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $speechClient->deletePhraseSet($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var PhraseSet $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 = SpeechClient::phraseSetName('[PROJECT]', '[LOCATION]', '[PHRASE_SET]'); + + delete_phrase_set_sample($formattedName); +} +// [END speech_v2_generated_Speech_DeletePhraseSet_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/delete_recognizer.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/delete_recognizer.php new file mode 100644 index 000000000000..8cac60beca4e --- /dev/null +++ b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/delete_recognizer.php @@ -0,0 +1,84 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $speechClient->deleteRecognizer($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var Recognizer $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 = SpeechClient::recognizerName('[PROJECT]', '[LOCATION]', '[RECOGNIZER]'); + + delete_recognizer_sample($formattedName); +} +// [END speech_v2_generated_Speech_DeleteRecognizer_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/get_config.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/get_config.php new file mode 100644 index 000000000000..791ca668dee0 --- /dev/null +++ b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/get_config.php @@ -0,0 +1,73 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var Config $response */ + $response = $speechClient->getConfig($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 = SpeechClient::configName('[PROJECT]', '[LOCATION]'); + + get_config_sample($formattedName); +} +// [END speech_v2_generated_Speech_GetConfig_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/get_custom_class.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/get_custom_class.php new file mode 100644 index 000000000000..1935c6ca7d3a --- /dev/null +++ b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/get_custom_class.php @@ -0,0 +1,73 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var CustomClass $response */ + $response = $speechClient->getCustomClass($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 = SpeechClient::customClassName('[PROJECT]', '[LOCATION]', '[CUSTOM_CLASS]'); + + get_custom_class_sample($formattedName); +} +// [END speech_v2_generated_Speech_GetCustomClass_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/get_location.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/get_location.php new file mode 100644 index 000000000000..e570d04c6a7e --- /dev/null +++ b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/get_location.php @@ -0,0 +1,57 @@ +getLocation($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} +// [END speech_v2_generated_Speech_GetLocation_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/get_phrase_set.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/get_phrase_set.php new file mode 100644 index 000000000000..2764e2c6e55b --- /dev/null +++ b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/get_phrase_set.php @@ -0,0 +1,73 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var PhraseSet $response */ + $response = $speechClient->getPhraseSet($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 = SpeechClient::phraseSetName('[PROJECT]', '[LOCATION]', '[PHRASE_SET]'); + + get_phrase_set_sample($formattedName); +} +// [END speech_v2_generated_Speech_GetPhraseSet_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/get_recognizer.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/get_recognizer.php new file mode 100644 index 000000000000..a9bdaa424341 --- /dev/null +++ b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/get_recognizer.php @@ -0,0 +1,75 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var Recognizer $response */ + $response = $speechClient->getRecognizer($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 = SpeechClient::recognizerName('[PROJECT]', '[LOCATION]', '[RECOGNIZER]'); + + get_recognizer_sample($formattedName); +} +// [END speech_v2_generated_Speech_GetRecognizer_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/list_custom_classes.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/list_custom_classes.php new file mode 100644 index 000000000000..241c3b5072aa --- /dev/null +++ b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/list_custom_classes.php @@ -0,0 +1,77 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $speechClient->listCustomClasses($request); + + /** @var CustomClass $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 = SpeechClient::locationName('[PROJECT]', '[LOCATION]'); + + list_custom_classes_sample($formattedParent); +} +// [END speech_v2_generated_Speech_ListCustomClasses_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/list_locations.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/list_locations.php new file mode 100644 index 000000000000..8f437d0d9583 --- /dev/null +++ b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/list_locations.php @@ -0,0 +1,69 @@ +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 speech_v2_generated_Speech_ListLocations_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/list_phrase_sets.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/list_phrase_sets.php new file mode 100644 index 000000000000..24808eff8975 --- /dev/null +++ b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/list_phrase_sets.php @@ -0,0 +1,77 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $speechClient->listPhraseSets($request); + + /** @var PhraseSet $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 = SpeechClient::locationName('[PROJECT]', '[LOCATION]'); + + list_phrase_sets_sample($formattedParent); +} +// [END speech_v2_generated_Speech_ListPhraseSets_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/list_recognizers.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/list_recognizers.php new file mode 100644 index 000000000000..9fc2ff0a2126 --- /dev/null +++ b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/list_recognizers.php @@ -0,0 +1,77 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $speechClient->listRecognizers($request); + + /** @var Recognizer $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 = SpeechClient::locationName('[PROJECT]', '[LOCATION]'); + + list_recognizers_sample($formattedParent); +} +// [END speech_v2_generated_Speech_ListRecognizers_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/recognize.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/recognize.php new file mode 100644 index 000000000000..db5043715fad --- /dev/null +++ b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/recognize.php @@ -0,0 +1,75 @@ +setRecognizer($formattedRecognizer); + + // Call the API and handle any network failures. + try { + /** @var RecognizeResponse $response */ + $response = $speechClient->recognize($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 +{ + $formattedRecognizer = SpeechClient::recognizerName('[PROJECT]', '[LOCATION]', '[RECOGNIZER]'); + + recognize_sample($formattedRecognizer); +} +// [END speech_v2_generated_Speech_Recognize_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/streaming_recognize.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/streaming_recognize.php new file mode 100644 index 000000000000..f4b1fdb5504a --- /dev/null +++ b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/streaming_recognize.php @@ -0,0 +1,81 @@ +setRecognizer($formattedRecognizer); + + // Call the API and handle any network failures. + try { + /** @var BidiStream $stream */ + $stream = $speechClient->streamingRecognize(); + $stream->writeAll([$request,]); + + /** @var StreamingRecognizeResponse $element */ + foreach ($stream->closeWriteAndReadAll() 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 +{ + $formattedRecognizer = SpeechClient::recognizerName('[PROJECT]', '[LOCATION]', '[RECOGNIZER]'); + + streaming_recognize_sample($formattedRecognizer); +} +// [END speech_v2_generated_Speech_StreamingRecognize_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/undelete_custom_class.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/undelete_custom_class.php new file mode 100644 index 000000000000..40bcd62e88c0 --- /dev/null +++ b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/undelete_custom_class.php @@ -0,0 +1,85 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $speechClient->undeleteCustomClass($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var CustomClass $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 = SpeechClient::customClassName('[PROJECT]', '[LOCATION]', '[CUSTOM_CLASS]'); + + undelete_custom_class_sample($formattedName); +} +// [END speech_v2_generated_Speech_UndeleteCustomClass_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/undelete_phrase_set.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/undelete_phrase_set.php new file mode 100644 index 000000000000..2185309a83f7 --- /dev/null +++ b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/undelete_phrase_set.php @@ -0,0 +1,84 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $speechClient->undeletePhraseSet($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var PhraseSet $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 = SpeechClient::phraseSetName('[PROJECT]', '[LOCATION]', '[PHRASE_SET]'); + + undelete_phrase_set_sample($formattedName); +} +// [END speech_v2_generated_Speech_UndeletePhraseSet_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/undelete_recognizer.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/undelete_recognizer.php new file mode 100644 index 000000000000..96ab483bbbcf --- /dev/null +++ b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/undelete_recognizer.php @@ -0,0 +1,84 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $speechClient->undeleteRecognizer($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var Recognizer $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 = SpeechClient::recognizerName('[PROJECT]', '[LOCATION]', '[RECOGNIZER]'); + + undelete_recognizer_sample($formattedName); +} +// [END speech_v2_generated_Speech_UndeleteRecognizer_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/update_config.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/update_config.php new file mode 100644 index 000000000000..45cb1763e0f6 --- /dev/null +++ b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/update_config.php @@ -0,0 +1,59 @@ +setConfig($config); + + // Call the API and handle any network failures. + try { + /** @var Config $response */ + $response = $speechClient->updateConfig($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} +// [END speech_v2_generated_Speech_UpdateConfig_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/update_custom_class.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/update_custom_class.php new file mode 100644 index 000000000000..82c20a85957e --- /dev/null +++ b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/update_custom_class.php @@ -0,0 +1,71 @@ +setCustomClass($customClass); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $speechClient->updateCustomClass($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var CustomClass $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 speech_v2_generated_Speech_UpdateCustomClass_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/update_phrase_set.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/update_phrase_set.php new file mode 100644 index 000000000000..e3e0228abd3a --- /dev/null +++ b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/update_phrase_set.php @@ -0,0 +1,71 @@ +setPhraseSet($phraseSet); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $speechClient->updatePhraseSet($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var PhraseSet $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 speech_v2_generated_Speech_UpdatePhraseSet_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/update_recognizer.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/update_recognizer.php new file mode 100644 index 000000000000..70edda904635 --- /dev/null +++ b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/update_recognizer.php @@ -0,0 +1,71 @@ +setRecognizer($recognizer); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $speechClient->updateRecognizer($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var Recognizer $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 speech_v2_generated_Speech_UpdateRecognizer_sync] diff --git a/owl-bot-staging/Speech/v2/src/V2/Client/SpeechClient.php b/owl-bot-staging/Speech/v2/src/V2/Client/SpeechClient.php new file mode 100644 index 000000000000..61aba8321f65 --- /dev/null +++ b/owl-bot-staging/Speech/v2/src/V2/Client/SpeechClient.php @@ -0,0 +1,1120 @@ + batchRecognizeAsync(BatchRecognizeRequest $request, array $optionalArgs = []) + * @method PromiseInterface createCustomClassAsync(CreateCustomClassRequest $request, array $optionalArgs = []) + * @method PromiseInterface createPhraseSetAsync(CreatePhraseSetRequest $request, array $optionalArgs = []) + * @method PromiseInterface createRecognizerAsync(CreateRecognizerRequest $request, array $optionalArgs = []) + * @method PromiseInterface deleteCustomClassAsync(DeleteCustomClassRequest $request, array $optionalArgs = []) + * @method PromiseInterface deletePhraseSetAsync(DeletePhraseSetRequest $request, array $optionalArgs = []) + * @method PromiseInterface deleteRecognizerAsync(DeleteRecognizerRequest $request, array $optionalArgs = []) + * @method PromiseInterface getConfigAsync(GetConfigRequest $request, array $optionalArgs = []) + * @method PromiseInterface getCustomClassAsync(GetCustomClassRequest $request, array $optionalArgs = []) + * @method PromiseInterface getPhraseSetAsync(GetPhraseSetRequest $request, array $optionalArgs = []) + * @method PromiseInterface getRecognizerAsync(GetRecognizerRequest $request, array $optionalArgs = []) + * @method PromiseInterface listCustomClassesAsync(ListCustomClassesRequest $request, array $optionalArgs = []) + * @method PromiseInterface listPhraseSetsAsync(ListPhraseSetsRequest $request, array $optionalArgs = []) + * @method PromiseInterface listRecognizersAsync(ListRecognizersRequest $request, array $optionalArgs = []) + * @method PromiseInterface recognizeAsync(RecognizeRequest $request, array $optionalArgs = []) + * @method PromiseInterface undeleteCustomClassAsync(UndeleteCustomClassRequest $request, array $optionalArgs = []) + * @method PromiseInterface undeletePhraseSetAsync(UndeletePhraseSetRequest $request, array $optionalArgs = []) + * @method PromiseInterface undeleteRecognizerAsync(UndeleteRecognizerRequest $request, array $optionalArgs = []) + * @method PromiseInterface updateConfigAsync(UpdateConfigRequest $request, array $optionalArgs = []) + * @method PromiseInterface updateCustomClassAsync(UpdateCustomClassRequest $request, array $optionalArgs = []) + * @method PromiseInterface updatePhraseSetAsync(UpdatePhraseSetRequest $request, array $optionalArgs = []) + * @method PromiseInterface updateRecognizerAsync(UpdateRecognizerRequest $request, array $optionalArgs = []) + * @method PromiseInterface getLocationAsync(GetLocationRequest $request, array $optionalArgs = []) + * @method PromiseInterface listLocationsAsync(ListLocationsRequest $request, array $optionalArgs = []) + */ +final class SpeechClient +{ + use GapicClientTrait; + use ResourceHelperTrait; + + /** The name of the service. */ + private const SERVICE_NAME = 'google.cloud.speech.v2.Speech'; + + /** + * The default address of the service. + * + * @deprecated SERVICE_ADDRESS_TEMPLATE should be used instead. + */ + private const SERVICE_ADDRESS = 'speech.googleapis.com'; + + /** The address template of the service. */ + private const SERVICE_ADDRESS_TEMPLATE = 'speech.UNIVERSE_DOMAIN'; + + /** The default port of the service. */ + private const DEFAULT_SERVICE_PORT = 443; + + /** The name of the code generator, to be included in the agent header. */ + private const CODEGEN_NAME = 'gapic'; + + /** The default scopes required by the service. */ + public static $serviceScopes = [ + 'https://www.googleapis.com/auth/cloud-platform', + ]; + + private $operationsClient; + + private static function getClientDefaults() + { + return [ + 'serviceName' => self::SERVICE_NAME, + 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, + 'clientConfig' => __DIR__ . '/../resources/speech_client_config.json', + 'descriptorsConfigPath' => __DIR__ . '/../resources/speech_descriptor_config.php', + 'gcpApiConfigPath' => __DIR__ . '/../resources/speech_grpc_config.json', + 'credentialsConfig' => [ + 'defaultScopes' => self::$serviceScopes, + ], + 'transportConfig' => [ + 'rest' => [ + 'restClientConfigPath' => __DIR__ . '/../resources/speech_rest_client_config.php', + ], + ], + ]; + } + + /** + * 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 = $this->descriptors[$methodName]['longRunning'] ?? []; + $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); + $operation->reload(); + return $operation; + } + + /** + * Create the default operation client for the service. + * + * @param array $options ClientOptions for the client. + * + * @return OperationsClient + */ + private function createOperationsClient(array $options) + { + // Unset client-specific configuration options + unset($options['serviceName'], $options['clientConfig'], $options['descriptorsConfigPath']); + + if (isset($options['operationsClient'])) { + return $options['operationsClient']; + } + + return new OperationsClient($options); + } + + /** + * Formats a string containing the fully-qualified path to represent a config + * resource. + * + * @param string $project + * @param string $location + * + * @return string The formatted config resource. + */ + public static function configName(string $project, string $location): string + { + return self::getPathTemplate('config')->render([ + 'project' => $project, + 'location' => $location, + ]); + } + + /** + * 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(string $project, string $location, string $keyRing, string $cryptoKey): string + { + return self::getPathTemplate('cryptoKey')->render([ + 'project' => $project, + 'location' => $location, + 'key_ring' => $keyRing, + 'crypto_key' => $cryptoKey, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * crypto_key_version resource. + * + * @param string $project + * @param string $location + * @param string $keyRing + * @param string $cryptoKey + * @param string $cryptoKeyVersion + * + * @return string The formatted crypto_key_version resource. + */ + public static function cryptoKeyVersionName(string $project, string $location, string $keyRing, string $cryptoKey, string $cryptoKeyVersion): string + { + return self::getPathTemplate('cryptoKeyVersion')->render([ + 'project' => $project, + 'location' => $location, + 'key_ring' => $keyRing, + 'crypto_key' => $cryptoKey, + 'crypto_key_version' => $cryptoKeyVersion, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a custom_class + * resource. + * + * @param string $project + * @param string $location + * @param string $customClass + * + * @return string The formatted custom_class resource. + */ + public static function customClassName(string $project, string $location, string $customClass): string + { + return self::getPathTemplate('customClass')->render([ + 'project' => $project, + 'location' => $location, + 'custom_class' => $customClass, + ]); + } + + /** + * 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(string $project, string $location): string + { + return self::getPathTemplate('location')->render([ + 'project' => $project, + 'location' => $location, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a phrase_set + * resource. + * + * @param string $project + * @param string $location + * @param string $phraseSet + * + * @return string The formatted phrase_set resource. + */ + public static function phraseSetName(string $project, string $location, string $phraseSet): string + { + return self::getPathTemplate('phraseSet')->render([ + 'project' => $project, + 'location' => $location, + 'phrase_set' => $phraseSet, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a recognizer + * resource. + * + * @param string $project + * @param string $location + * @param string $recognizer + * + * @return string The formatted recognizer resource. + */ + public static function recognizerName(string $project, string $location, string $recognizer): string + { + return self::getPathTemplate('recognizer')->render([ + 'project' => $project, + 'location' => $location, + 'recognizer' => $recognizer, + ]); + } + + /** + * Parses a formatted name string and returns an associative array of the components in the name. + * The following name formats are supported: + * Template: Pattern + * - config: projects/{project}/locations/{location}/config + * - cryptoKey: projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key} + * - cryptoKeyVersion: projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}/cryptoKeyVersions/{crypto_key_version} + * - customClass: projects/{project}/locations/{location}/customClasses/{custom_class} + * - location: projects/{project}/locations/{location} + * - phraseSet: projects/{project}/locations/{location}/phraseSets/{phrase_set} + * - recognizer: projects/{project}/locations/{location}/recognizers/{recognizer} + * + * 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(string $formattedName, ?string $template = null): array + { + return self::parseFormattedName($formattedName, $template); + } + + /** + * Constructor. + * + * @param array|ClientOptions $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 'speech.googleapis.com:443'. + * @type FetchAuthTokenInterface|CredentialsWrapper $credentials + * This option should only be used with a pre-constructed + * {@see FetchAuthTokenInterface} or {@see CredentialsWrapper} object. Note that + * when one of these objects are provided, any settings in $credentialsConfig will + * be ignored. + * **Important**: If you are providing a path to a credentials file, or a decoded + * credentials file as a PHP array, this usage is now DEPRECATED. Providing an + * unvalidated credential configuration to Google APIs can compromise the security + * of your systems and data. It is recommended to create the credentials explicitly + * ``` + * use Google\Auth\Credentials\ServiceAccountCredentials; + * use Google\Cloud\Speech\V2\SpeechClient; + * $creds = new ServiceAccountCredentials($scopes, $json); + * $options = new SpeechClient(['credentials' => $creds]); + * ``` + * {@see + * https://cloud.google.com/docs/authentication/external/externally-sourced-credentials} + * @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. + * @type false|LoggerInterface $logger + * A PSR-3 compliant logger. If set to false, logging is disabled, ignoring the + * 'GOOGLE_SDK_PHP_LOGGING' environment flag + * @type string $universeDomain + * The service domain for the client. Defaults to 'googleapis.com'. + * } + * + * @throws ValidationException + */ + public function __construct(array|ClientOptions $options = []) + { + $clientOptions = $this->buildClientOptions($options); + $this->setClientOptions($clientOptions); + $this->operationsClient = $this->createOperationsClient($clientOptions); + } + + /** Handles execution of the async variants for each documented method. */ + public function __call($method, $args) + { + if (substr($method, -5) !== 'Async') { + trigger_error('Call to undefined method ' . __CLASS__ . "::$method()", E_USER_ERROR); + } + + array_unshift($args, substr($method, 0, -5)); + return call_user_func_array([$this, 'startAsyncCall'], $args); + } + + /** + * Performs batch asynchronous speech recognition: send a request with N + * audio files and receive a long running operation that can be polled to see + * when the transcriptions are finished. + * + * The async variant is {@see SpeechClient::batchRecognizeAsync()} . + * + * @example samples/V2/SpeechClient/batch_recognize.php + * + * @param BatchRecognizeRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function batchRecognize(BatchRecognizeRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('BatchRecognize', $request, $callOptions)->wait(); + } + + /** + * Creates a [CustomClass][google.cloud.speech.v2.CustomClass]. + * + * The async variant is {@see SpeechClient::createCustomClassAsync()} . + * + * @example samples/V2/SpeechClient/create_custom_class.php + * + * @param CreateCustomClassRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function createCustomClass(CreateCustomClassRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('CreateCustomClass', $request, $callOptions)->wait(); + } + + /** + * Creates a [PhraseSet][google.cloud.speech.v2.PhraseSet]. + * + * The async variant is {@see SpeechClient::createPhraseSetAsync()} . + * + * @example samples/V2/SpeechClient/create_phrase_set.php + * + * @param CreatePhraseSetRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function createPhraseSet(CreatePhraseSetRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('CreatePhraseSet', $request, $callOptions)->wait(); + } + + /** + * Creates a [Recognizer][google.cloud.speech.v2.Recognizer]. + * + * The async variant is {@see SpeechClient::createRecognizerAsync()} . + * + * @example samples/V2/SpeechClient/create_recognizer.php + * + * @param CreateRecognizerRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function createRecognizer(CreateRecognizerRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('CreateRecognizer', $request, $callOptions)->wait(); + } + + /** + * Deletes the [CustomClass][google.cloud.speech.v2.CustomClass]. + * + * The async variant is {@see SpeechClient::deleteCustomClassAsync()} . + * + * @example samples/V2/SpeechClient/delete_custom_class.php + * + * @param DeleteCustomClassRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function deleteCustomClass(DeleteCustomClassRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('DeleteCustomClass', $request, $callOptions)->wait(); + } + + /** + * Deletes the [PhraseSet][google.cloud.speech.v2.PhraseSet]. + * + * The async variant is {@see SpeechClient::deletePhraseSetAsync()} . + * + * @example samples/V2/SpeechClient/delete_phrase_set.php + * + * @param DeletePhraseSetRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function deletePhraseSet(DeletePhraseSetRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('DeletePhraseSet', $request, $callOptions)->wait(); + } + + /** + * Deletes the [Recognizer][google.cloud.speech.v2.Recognizer]. + * + * The async variant is {@see SpeechClient::deleteRecognizerAsync()} . + * + * @example samples/V2/SpeechClient/delete_recognizer.php + * + * @param DeleteRecognizerRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function deleteRecognizer(DeleteRecognizerRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('DeleteRecognizer', $request, $callOptions)->wait(); + } + + /** + * Returns the requested [Config][google.cloud.speech.v2.Config]. + * + * The async variant is {@see SpeechClient::getConfigAsync()} . + * + * @example samples/V2/SpeechClient/get_config.php + * + * @param GetConfigRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Config + * + * @throws ApiException Thrown if the API call fails. + */ + public function getConfig(GetConfigRequest $request, array $callOptions = []): Config + { + return $this->startApiCall('GetConfig', $request, $callOptions)->wait(); + } + + /** + * Returns the requested + * [CustomClass][google.cloud.speech.v2.CustomClass]. + * + * The async variant is {@see SpeechClient::getCustomClassAsync()} . + * + * @example samples/V2/SpeechClient/get_custom_class.php + * + * @param GetCustomClassRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 CustomClass + * + * @throws ApiException Thrown if the API call fails. + */ + public function getCustomClass(GetCustomClassRequest $request, array $callOptions = []): CustomClass + { + return $this->startApiCall('GetCustomClass', $request, $callOptions)->wait(); + } + + /** + * Returns the requested + * [PhraseSet][google.cloud.speech.v2.PhraseSet]. + * + * The async variant is {@see SpeechClient::getPhraseSetAsync()} . + * + * @example samples/V2/SpeechClient/get_phrase_set.php + * + * @param GetPhraseSetRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PhraseSet + * + * @throws ApiException Thrown if the API call fails. + */ + public function getPhraseSet(GetPhraseSetRequest $request, array $callOptions = []): PhraseSet + { + return $this->startApiCall('GetPhraseSet', $request, $callOptions)->wait(); + } + + /** + * Returns the requested + * [Recognizer][google.cloud.speech.v2.Recognizer]. Fails with + * [NOT_FOUND][google.rpc.Code.NOT_FOUND] if the requested Recognizer doesn't + * exist. + * + * The async variant is {@see SpeechClient::getRecognizerAsync()} . + * + * @example samples/V2/SpeechClient/get_recognizer.php + * + * @param GetRecognizerRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Recognizer + * + * @throws ApiException Thrown if the API call fails. + */ + public function getRecognizer(GetRecognizerRequest $request, array $callOptions = []): Recognizer + { + return $this->startApiCall('GetRecognizer', $request, $callOptions)->wait(); + } + + /** + * Lists CustomClasses. + * + * The async variant is {@see SpeechClient::listCustomClassesAsync()} . + * + * @example samples/V2/SpeechClient/list_custom_classes.php + * + * @param ListCustomClassesRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listCustomClasses(ListCustomClassesRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListCustomClasses', $request, $callOptions); + } + + /** + * Lists PhraseSets. + * + * The async variant is {@see SpeechClient::listPhraseSetsAsync()} . + * + * @example samples/V2/SpeechClient/list_phrase_sets.php + * + * @param ListPhraseSetsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listPhraseSets(ListPhraseSetsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListPhraseSets', $request, $callOptions); + } + + /** + * Lists Recognizers. + * + * The async variant is {@see SpeechClient::listRecognizersAsync()} . + * + * @example samples/V2/SpeechClient/list_recognizers.php + * + * @param ListRecognizersRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listRecognizers(ListRecognizersRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListRecognizers', $request, $callOptions); + } + + /** + * Performs synchronous Speech recognition: receive results after all audio + * has been sent and processed. + * + * The async variant is {@see SpeechClient::recognizeAsync()} . + * + * @example samples/V2/SpeechClient/recognize.php + * + * @param RecognizeRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 RecognizeResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function recognize(RecognizeRequest $request, array $callOptions = []): RecognizeResponse + { + return $this->startApiCall('Recognize', $request, $callOptions)->wait(); + } + + /** + * Performs bidirectional streaming speech recognition: receive results while + * sending audio. This method is only available via the gRPC API (not REST). + * + * @example samples/V2/SpeechClient/streaming_recognize.php + * + * @param array $callOptions { + * Optional. + * + * @type int $timeoutMillis + * Timeout to use for this call. + * } + * + * @return BidiStream + * + * @throws ApiException Thrown if the API call fails. + */ + public function streamingRecognize(array $callOptions = []): BidiStream + { + return $this->startApiCall('StreamingRecognize', null, $callOptions); + } + + /** + * Undeletes the [CustomClass][google.cloud.speech.v2.CustomClass]. + * + * The async variant is {@see SpeechClient::undeleteCustomClassAsync()} . + * + * @example samples/V2/SpeechClient/undelete_custom_class.php + * + * @param UndeleteCustomClassRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function undeleteCustomClass(UndeleteCustomClassRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('UndeleteCustomClass', $request, $callOptions)->wait(); + } + + /** + * Undeletes the [PhraseSet][google.cloud.speech.v2.PhraseSet]. + * + * The async variant is {@see SpeechClient::undeletePhraseSetAsync()} . + * + * @example samples/V2/SpeechClient/undelete_phrase_set.php + * + * @param UndeletePhraseSetRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function undeletePhraseSet(UndeletePhraseSetRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('UndeletePhraseSet', $request, $callOptions)->wait(); + } + + /** + * Undeletes the [Recognizer][google.cloud.speech.v2.Recognizer]. + * + * The async variant is {@see SpeechClient::undeleteRecognizerAsync()} . + * + * @example samples/V2/SpeechClient/undelete_recognizer.php + * + * @param UndeleteRecognizerRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function undeleteRecognizer(UndeleteRecognizerRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('UndeleteRecognizer', $request, $callOptions)->wait(); + } + + /** + * Updates the [Config][google.cloud.speech.v2.Config]. + * + * The async variant is {@see SpeechClient::updateConfigAsync()} . + * + * @example samples/V2/SpeechClient/update_config.php + * + * @param UpdateConfigRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Config + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateConfig(UpdateConfigRequest $request, array $callOptions = []): Config + { + return $this->startApiCall('UpdateConfig', $request, $callOptions)->wait(); + } + + /** + * Updates the [CustomClass][google.cloud.speech.v2.CustomClass]. + * + * The async variant is {@see SpeechClient::updateCustomClassAsync()} . + * + * @example samples/V2/SpeechClient/update_custom_class.php + * + * @param UpdateCustomClassRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateCustomClass(UpdateCustomClassRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('UpdateCustomClass', $request, $callOptions)->wait(); + } + + /** + * Updates the [PhraseSet][google.cloud.speech.v2.PhraseSet]. + * + * The async variant is {@see SpeechClient::updatePhraseSetAsync()} . + * + * @example samples/V2/SpeechClient/update_phrase_set.php + * + * @param UpdatePhraseSetRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function updatePhraseSet(UpdatePhraseSetRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('UpdatePhraseSet', $request, $callOptions)->wait(); + } + + /** + * Updates the [Recognizer][google.cloud.speech.v2.Recognizer]. + * + * The async variant is {@see SpeechClient::updateRecognizerAsync()} . + * + * @example samples/V2/SpeechClient/update_recognizer.php + * + * @param UpdateRecognizerRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateRecognizer(UpdateRecognizerRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('UpdateRecognizer', $request, $callOptions)->wait(); + } + + /** + * Gets information about a location. + * + * The async variant is {@see SpeechClient::getLocationAsync()} . + * + * @example samples/V2/SpeechClient/get_location.php + * + * @param GetLocationRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Location + * + * @throws ApiException Thrown if the API call fails. + */ + public function getLocation(GetLocationRequest $request, array $callOptions = []): Location + { + return $this->startApiCall('GetLocation', $request, $callOptions)->wait(); + } + + /** + * Lists information about the supported locations for this service. + * This method can be called in two ways: + * + * * **List all public locations:** Use the path `GET /v1/locations`. + * * **List project-visible locations:** Use the path + * `GET /v1/projects/{project_id}/locations`. This may include public + * locations as well as private or other locations specifically visible + * to the project. + * + * The async variant is {@see SpeechClient::listLocationsAsync()} . + * + * @example samples/V2/SpeechClient/list_locations.php + * + * @param ListLocationsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listLocations(ListLocationsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListLocations', $request, $callOptions); + } +} diff --git a/owl-bot-staging/Speech/v2/src/V2/gapic_metadata.json b/owl-bot-staging/Speech/v2/src/V2/gapic_metadata.json new file mode 100644 index 000000000000..1ad2778b344f --- /dev/null +++ b/owl-bot-staging/Speech/v2/src/V2/gapic_metadata.json @@ -0,0 +1,143 @@ +{ + "schema": "1.0", + "comment": "This file maps proto services\/RPCs to the corresponding library clients\/methods", + "language": "php", + "protoPackage": "google.cloud.speech.v2", + "libraryPackage": "Google\\Cloud\\Speech\\V2", + "services": { + "Speech": { + "clients": { + "grpc": { + "libraryClient": "SpeechGapicClient", + "rpcs": { + "BatchRecognize": { + "methods": [ + "batchRecognize" + ] + }, + "CreateCustomClass": { + "methods": [ + "createCustomClass" + ] + }, + "CreatePhraseSet": { + "methods": [ + "createPhraseSet" + ] + }, + "CreateRecognizer": { + "methods": [ + "createRecognizer" + ] + }, + "DeleteCustomClass": { + "methods": [ + "deleteCustomClass" + ] + }, + "DeletePhraseSet": { + "methods": [ + "deletePhraseSet" + ] + }, + "DeleteRecognizer": { + "methods": [ + "deleteRecognizer" + ] + }, + "GetConfig": { + "methods": [ + "getConfig" + ] + }, + "GetCustomClass": { + "methods": [ + "getCustomClass" + ] + }, + "GetPhraseSet": { + "methods": [ + "getPhraseSet" + ] + }, + "GetRecognizer": { + "methods": [ + "getRecognizer" + ] + }, + "ListCustomClasses": { + "methods": [ + "listCustomClasses" + ] + }, + "ListPhraseSets": { + "methods": [ + "listPhraseSets" + ] + }, + "ListRecognizers": { + "methods": [ + "listRecognizers" + ] + }, + "Recognize": { + "methods": [ + "recognize" + ] + }, + "StreamingRecognize": { + "methods": [ + "streamingRecognize" + ] + }, + "UndeleteCustomClass": { + "methods": [ + "undeleteCustomClass" + ] + }, + "UndeletePhraseSet": { + "methods": [ + "undeletePhraseSet" + ] + }, + "UndeleteRecognizer": { + "methods": [ + "undeleteRecognizer" + ] + }, + "UpdateConfig": { + "methods": [ + "updateConfig" + ] + }, + "UpdateCustomClass": { + "methods": [ + "updateCustomClass" + ] + }, + "UpdatePhraseSet": { + "methods": [ + "updatePhraseSet" + ] + }, + "UpdateRecognizer": { + "methods": [ + "updateRecognizer" + ] + }, + "GetLocation": { + "methods": [ + "getLocation" + ] + }, + "ListLocations": { + "methods": [ + "listLocations" + ] + } + } + } + } + } + } +} \ No newline at end of file diff --git a/owl-bot-staging/Speech/v2/src/V2/resources/speech_client_config.json b/owl-bot-staging/Speech/v2/src/V2/resources/speech_client_config.json new file mode 100644 index 000000000000..09ee645f6c5c --- /dev/null +++ b/owl-bot-staging/Speech/v2/src/V2/resources/speech_client_config.json @@ -0,0 +1,158 @@ +{ + "interfaces": { + "google.cloud.speech.v2.Speech": { + "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": 100, + "retry_delay_multiplier": 1.3, + "max_retry_delay_millis": 60000, + "initial_rpc_timeout_millis": 5000000, + "rpc_timeout_multiplier": 1.0, + "max_rpc_timeout_millis": 5000000, + "total_timeout_millis": 5000000 + } + }, + "methods": { + "BatchRecognize": { + "timeout_millis": 5000000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "CreateCustomClass": { + "timeout_millis": 5000000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "CreatePhraseSet": { + "timeout_millis": 5000000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "CreateRecognizer": { + "timeout_millis": 5000000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "DeleteCustomClass": { + "timeout_millis": 5000000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "DeletePhraseSet": { + "timeout_millis": 5000000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "DeleteRecognizer": { + "timeout_millis": 5000000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "GetConfig": { + "timeout_millis": 5000000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "GetCustomClass": { + "timeout_millis": 5000000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "GetPhraseSet": { + "timeout_millis": 5000000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "GetRecognizer": { + "timeout_millis": 5000000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ListCustomClasses": { + "timeout_millis": 5000000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ListPhraseSets": { + "timeout_millis": 5000000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ListRecognizers": { + "timeout_millis": 5000000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "Recognize": { + "timeout_millis": 5000000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "StreamingRecognize": { + "timeout_millis": 5000000 + }, + "UndeleteCustomClass": { + "timeout_millis": 5000000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "UndeletePhraseSet": { + "timeout_millis": 5000000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "UndeleteRecognizer": { + "timeout_millis": 5000000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "UpdateConfig": { + "timeout_millis": 5000000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "UpdateCustomClass": { + "timeout_millis": 5000000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "UpdatePhraseSet": { + "timeout_millis": 5000000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "UpdateRecognizer": { + "timeout_millis": 5000000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "GetLocation": { + "timeout_millis": 5000000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ListLocations": { + "timeout_millis": 5000000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + } + } + } + } +} diff --git a/owl-bot-staging/Speech/v2/src/V2/resources/speech_descriptor_config.php b/owl-bot-staging/Speech/v2/src/V2/resources/speech_descriptor_config.php new file mode 100644 index 000000000000..091a1cff366b --- /dev/null +++ b/owl-bot-staging/Speech/v2/src/V2/resources/speech_descriptor_config.php @@ -0,0 +1,461 @@ + [ + 'google.cloud.speech.v2.Speech' => [ + 'BatchRecognize' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\Speech\V2\BatchRecognizeResponse', + 'metadataReturnType' => '\Google\Cloud\Speech\V2\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'recognizer', + 'fieldAccessors' => [ + 'getRecognizer', + ], + ], + ], + ], + 'CreateCustomClass' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\Speech\V2\CustomClass', + 'metadataReturnType' => '\Google\Cloud\Speech\V2\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreatePhraseSet' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\Speech\V2\PhraseSet', + 'metadataReturnType' => '\Google\Cloud\Speech\V2\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateRecognizer' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\Speech\V2\Recognizer', + 'metadataReturnType' => '\Google\Cloud\Speech\V2\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'DeleteCustomClass' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\Speech\V2\CustomClass', + 'metadataReturnType' => '\Google\Cloud\Speech\V2\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'DeletePhraseSet' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\Speech\V2\PhraseSet', + 'metadataReturnType' => '\Google\Cloud\Speech\V2\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'DeleteRecognizer' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\Speech\V2\Recognizer', + 'metadataReturnType' => '\Google\Cloud\Speech\V2\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'UndeleteCustomClass' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\Speech\V2\CustomClass', + 'metadataReturnType' => '\Google\Cloud\Speech\V2\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'UndeletePhraseSet' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\Speech\V2\PhraseSet', + 'metadataReturnType' => '\Google\Cloud\Speech\V2\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'UndeleteRecognizer' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\Speech\V2\Recognizer', + 'metadataReturnType' => '\Google\Cloud\Speech\V2\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'UpdateCustomClass' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\Speech\V2\CustomClass', + 'metadataReturnType' => '\Google\Cloud\Speech\V2\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'custom_class.name', + 'fieldAccessors' => [ + 'getCustomClass', + 'getName', + ], + ], + ], + ], + 'UpdatePhraseSet' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\Speech\V2\PhraseSet', + 'metadataReturnType' => '\Google\Cloud\Speech\V2\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'phrase_set.name', + 'fieldAccessors' => [ + 'getPhraseSet', + 'getName', + ], + ], + ], + ], + 'UpdateRecognizer' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\Speech\V2\Recognizer', + 'metadataReturnType' => '\Google\Cloud\Speech\V2\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'recognizer.name', + 'fieldAccessors' => [ + 'getRecognizer', + 'getName', + ], + ], + ], + ], + 'GetConfig' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Speech\V2\Config', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetCustomClass' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Speech\V2\CustomClass', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetPhraseSet' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Speech\V2\PhraseSet', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetRecognizer' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Speech\V2\Recognizer', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'ListCustomClasses' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getCustomClasses', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\Speech\V2\ListCustomClassesResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListPhraseSets' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getPhraseSets', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\Speech\V2\ListPhraseSetsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListRecognizers' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getRecognizers', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\Speech\V2\ListRecognizersResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'Recognize' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Speech\V2\RecognizeResponse', + 'headerParams' => [ + [ + 'keyName' => 'recognizer', + 'fieldAccessors' => [ + 'getRecognizer', + ], + ], + ], + ], + 'StreamingRecognize' => [ + 'grpcStreaming' => [ + 'grpcStreamingType' => 'BidiStreaming', + ], + 'callType' => \Google\ApiCore\Call::BIDI_STREAMING_CALL, + 'responseType' => 'Google\Cloud\Speech\V2\StreamingRecognizeResponse', + ], + 'UpdateConfig' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\Speech\V2\Config', + 'headerParams' => [ + [ + 'keyName' => 'config.name', + 'fieldAccessors' => [ + 'getConfig', + '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' => [ + 'config' => 'projects/{project}/locations/{location}/config', + 'cryptoKey' => 'projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}', + 'cryptoKeyVersion' => 'projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}/cryptoKeyVersions/{crypto_key_version}', + 'customClass' => 'projects/{project}/locations/{location}/customClasses/{custom_class}', + 'location' => 'projects/{project}/locations/{location}', + 'phraseSet' => 'projects/{project}/locations/{location}/phraseSets/{phrase_set}', + 'recognizer' => 'projects/{project}/locations/{location}/recognizers/{recognizer}', + ], + ], + ], +]; diff --git a/owl-bot-staging/Speech/v2/src/V2/resources/speech_rest_client_config.php b/owl-bot-staging/Speech/v2/src/V2/resources/speech_rest_client_config.php new file mode 100644 index 000000000000..504f631d5d8a --- /dev/null +++ b/owl-bot-staging/Speech/v2/src/V2/resources/speech_rest_client_config.php @@ -0,0 +1,358 @@ + [ + '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', + ], + ], + ], + ], + ], + 'google.cloud.speech.v2.Speech' => [ + 'BatchRecognize' => [ + 'method' => 'post', + 'uriTemplate' => '/v2/{recognizer=projects/*/locations/*/recognizers/*}:batchRecognize', + 'body' => '*', + 'placeholders' => [ + 'recognizer' => [ + 'getters' => [ + 'getRecognizer', + ], + ], + ], + ], + 'CreateCustomClass' => [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/customClasses', + 'body' => 'custom_class', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'CreatePhraseSet' => [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/phraseSets', + 'body' => 'phrase_set', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'CreateRecognizer' => [ + 'method' => 'post', + 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/recognizers', + 'body' => 'recognizer', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'DeleteCustomClass' => [ + 'method' => 'delete', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/customClasses/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'DeletePhraseSet' => [ + 'method' => 'delete', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/phraseSets/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'DeleteRecognizer' => [ + 'method' => 'delete', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/recognizers/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetConfig' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/config}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetCustomClass' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/customClasses/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetPhraseSet' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/phraseSets/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetRecognizer' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/recognizers/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'ListCustomClasses' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/customClasses', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListPhraseSets' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/phraseSets', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListRecognizers' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/recognizers', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'Recognize' => [ + 'method' => 'post', + 'uriTemplate' => '/v2/{recognizer=projects/*/locations/*/recognizers/*}:recognize', + 'body' => '*', + 'placeholders' => [ + 'recognizer' => [ + 'getters' => [ + 'getRecognizer', + ], + ], + ], + ], + 'UndeleteCustomClass' => [ + 'method' => 'post', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/customClasses/*}:undelete', + 'body' => '*', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'UndeletePhraseSet' => [ + 'method' => 'post', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/phraseSets/*}:undelete', + 'body' => '*', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'UndeleteRecognizer' => [ + 'method' => 'post', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/recognizers/*}:undelete', + 'body' => '*', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'UpdateConfig' => [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{config.name=projects/*/locations/*/config}', + 'body' => 'config', + 'placeholders' => [ + 'config.name' => [ + 'getters' => [ + 'getConfig', + 'getName', + ], + ], + ], + ], + 'UpdateCustomClass' => [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{custom_class.name=projects/*/locations/*/customClasses/*}', + 'body' => 'custom_class', + 'placeholders' => [ + 'custom_class.name' => [ + 'getters' => [ + 'getCustomClass', + 'getName', + ], + ], + ], + ], + 'UpdatePhraseSet' => [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{phrase_set.name=projects/*/locations/*/phraseSets/*}', + 'body' => 'phrase_set', + 'placeholders' => [ + 'phrase_set.name' => [ + 'getters' => [ + 'getPhraseSet', + 'getName', + ], + ], + ], + ], + 'UpdateRecognizer' => [ + 'method' => 'patch', + 'uriTemplate' => '/v2/{recognizer.name=projects/*/locations/*/recognizers/*}', + 'body' => 'recognizer', + 'placeholders' => [ + 'recognizer.name' => [ + 'getters' => [ + 'getRecognizer', + 'getName', + ], + ], + ], + ], + ], + 'google.longrunning.Operations' => [ + 'CancelOperation' => [ + 'method' => 'post', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/operations/*}:cancel', + 'body' => '*', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'DeleteOperation' => [ + 'method' => 'delete', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/operations/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetOperation' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=projects/*/locations/*/operations/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'ListOperations' => [ + 'method' => 'get', + 'uriTemplate' => '/v2/{name=projects/*/locations/*}/operations', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + ], + ], + 'numericEnums' => true, +]; diff --git a/owl-bot-staging/Speech/v2/tests/Unit/V2/Client/SpeechClientTest.php b/owl-bot-staging/Speech/v2/tests/Unit/V2/Client/SpeechClientTest.php new file mode 100644 index 000000000000..af3e0ee40bbe --- /dev/null +++ b/owl-bot-staging/Speech/v2/tests/Unit/V2/Client/SpeechClientTest.php @@ -0,0 +1,2801 @@ +getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); + } + + /** @return SpeechClient */ + private function createClient(array $options = []) + { + $options += [ + 'credentials' => $this->createCredentials(), + ]; + return new SpeechClient($options); + } + + /** @test */ + public function batchRecognizeTest() + { + $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/batchRecognizeTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $expectedResponse = new BatchRecognizeResponse(); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/batchRecognizeTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedRecognizer = $gapicClient->recognizerName('[PROJECT]', '[LOCATION]', '[RECOGNIZER]'); + $request = (new BatchRecognizeRequest()) + ->setRecognizer($formattedRecognizer); + $response = $gapicClient->batchRecognize($request); + $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.speech.v2.Speech/BatchRecognize', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getRecognizer(); + $this->assertProtobufEquals($formattedRecognizer, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/batchRecognizeTest'); + $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 batchRecognizeExceptionTest() + { + $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/batchRecognizeTest'); + $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 + $formattedRecognizer = $gapicClient->recognizerName('[PROJECT]', '[LOCATION]', '[RECOGNIZER]'); + $request = (new BatchRecognizeRequest()) + ->setRecognizer($formattedRecognizer); + $response = $gapicClient->batchRecognize($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/batchRecognizeTest'); + 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 createCustomClassTest() + { + $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/createCustomClassTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $uid = 'uid115792'; + $displayName = 'displayName1615086568'; + $etag = 'etag3123477'; + $reconciling = false; + $kmsKeyName = 'kmsKeyName2094986649'; + $kmsKeyVersionName = 'kmsKeyVersionName-1734350176'; + $expectedResponse = new CustomClass(); + $expectedResponse->setName($name); + $expectedResponse->setUid($uid); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setEtag($etag); + $expectedResponse->setReconciling($reconciling); + $expectedResponse->setKmsKeyName($kmsKeyName); + $expectedResponse->setKmsKeyVersionName($kmsKeyVersionName); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/createCustomClassTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $customClass = new CustomClass(); + $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); + $request = (new CreateCustomClassRequest()) + ->setCustomClass($customClass) + ->setParent($formattedParent); + $response = $gapicClient->createCustomClass($request); + $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.speech.v2.Speech/CreateCustomClass', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getCustomClass(); + $this->assertProtobufEquals($customClass, $actualValue); + $actualValue = $actualApiRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createCustomClassTest'); + $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 createCustomClassExceptionTest() + { + $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/createCustomClassTest'); + $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 + $customClass = new CustomClass(); + $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); + $request = (new CreateCustomClassRequest()) + ->setCustomClass($customClass) + ->setParent($formattedParent); + $response = $gapicClient->createCustomClass($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createCustomClassTest'); + 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 createPhraseSetTest() + { + $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/createPhraseSetTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $uid = 'uid115792'; + $boost = 9392221; + $displayName = 'displayName1615086568'; + $etag = 'etag3123477'; + $reconciling = false; + $kmsKeyName = 'kmsKeyName2094986649'; + $kmsKeyVersionName = 'kmsKeyVersionName-1734350176'; + $expectedResponse = new PhraseSet(); + $expectedResponse->setName($name); + $expectedResponse->setUid($uid); + $expectedResponse->setBoost($boost); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setEtag($etag); + $expectedResponse->setReconciling($reconciling); + $expectedResponse->setKmsKeyName($kmsKeyName); + $expectedResponse->setKmsKeyVersionName($kmsKeyVersionName); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/createPhraseSetTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $phraseSet = new PhraseSet(); + $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); + $request = (new CreatePhraseSetRequest()) + ->setPhraseSet($phraseSet) + ->setParent($formattedParent); + $response = $gapicClient->createPhraseSet($request); + $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.speech.v2.Speech/CreatePhraseSet', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getPhraseSet(); + $this->assertProtobufEquals($phraseSet, $actualValue); + $actualValue = $actualApiRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createPhraseSetTest'); + $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 createPhraseSetExceptionTest() + { + $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/createPhraseSetTest'); + $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 + $phraseSet = new PhraseSet(); + $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); + $request = (new CreatePhraseSetRequest()) + ->setPhraseSet($phraseSet) + ->setParent($formattedParent); + $response = $gapicClient->createPhraseSet($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createPhraseSetTest'); + 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 createRecognizerTest() + { + $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/createRecognizerTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $uid = 'uid115792'; + $displayName = 'displayName1615086568'; + $model = 'model104069929'; + $etag = 'etag3123477'; + $reconciling = false; + $kmsKeyName = 'kmsKeyName2094986649'; + $kmsKeyVersionName = 'kmsKeyVersionName-1734350176'; + $expectedResponse = new Recognizer(); + $expectedResponse->setName($name); + $expectedResponse->setUid($uid); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setModel($model); + $expectedResponse->setEtag($etag); + $expectedResponse->setReconciling($reconciling); + $expectedResponse->setKmsKeyName($kmsKeyName); + $expectedResponse->setKmsKeyVersionName($kmsKeyVersionName); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/createRecognizerTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $recognizer = new Recognizer(); + $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); + $request = (new CreateRecognizerRequest()) + ->setRecognizer($recognizer) + ->setParent($formattedParent); + $response = $gapicClient->createRecognizer($request); + $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.speech.v2.Speech/CreateRecognizer', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getRecognizer(); + $this->assertProtobufEquals($recognizer, $actualValue); + $actualValue = $actualApiRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createRecognizerTest'); + $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 createRecognizerExceptionTest() + { + $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/createRecognizerTest'); + $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 + $recognizer = new Recognizer(); + $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); + $request = (new CreateRecognizerRequest()) + ->setRecognizer($recognizer) + ->setParent($formattedParent); + $response = $gapicClient->createRecognizer($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createRecognizerTest'); + 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 deleteCustomClassTest() + { + $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/deleteCustomClassTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name2 = 'name2-1052831874'; + $uid = 'uid115792'; + $displayName = 'displayName1615086568'; + $etag2 = 'etag2-1293302904'; + $reconciling = false; + $kmsKeyName = 'kmsKeyName2094986649'; + $kmsKeyVersionName = 'kmsKeyVersionName-1734350176'; + $expectedResponse = new CustomClass(); + $expectedResponse->setName($name2); + $expectedResponse->setUid($uid); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setEtag($etag2); + $expectedResponse->setReconciling($reconciling); + $expectedResponse->setKmsKeyName($kmsKeyName); + $expectedResponse->setKmsKeyVersionName($kmsKeyVersionName); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/deleteCustomClassTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedName = $gapicClient->customClassName('[PROJECT]', '[LOCATION]', '[CUSTOM_CLASS]'); + $request = (new DeleteCustomClassRequest()) + ->setName($formattedName); + $response = $gapicClient->deleteCustomClass($request); + $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.speech.v2.Speech/DeleteCustomClass', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/deleteCustomClassTest'); + $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 deleteCustomClassExceptionTest() + { + $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/deleteCustomClassTest'); + $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->customClassName('[PROJECT]', '[LOCATION]', '[CUSTOM_CLASS]'); + $request = (new DeleteCustomClassRequest()) + ->setName($formattedName); + $response = $gapicClient->deleteCustomClass($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/deleteCustomClassTest'); + 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 deletePhraseSetTest() + { + $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/deletePhraseSetTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name2 = 'name2-1052831874'; + $uid = 'uid115792'; + $boost = 9392221; + $displayName = 'displayName1615086568'; + $etag2 = 'etag2-1293302904'; + $reconciling = false; + $kmsKeyName = 'kmsKeyName2094986649'; + $kmsKeyVersionName = 'kmsKeyVersionName-1734350176'; + $expectedResponse = new PhraseSet(); + $expectedResponse->setName($name2); + $expectedResponse->setUid($uid); + $expectedResponse->setBoost($boost); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setEtag($etag2); + $expectedResponse->setReconciling($reconciling); + $expectedResponse->setKmsKeyName($kmsKeyName); + $expectedResponse->setKmsKeyVersionName($kmsKeyVersionName); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/deletePhraseSetTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedName = $gapicClient->phraseSetName('[PROJECT]', '[LOCATION]', '[PHRASE_SET]'); + $request = (new DeletePhraseSetRequest()) + ->setName($formattedName); + $response = $gapicClient->deletePhraseSet($request); + $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.speech.v2.Speech/DeletePhraseSet', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/deletePhraseSetTest'); + $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 deletePhraseSetExceptionTest() + { + $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/deletePhraseSetTest'); + $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->phraseSetName('[PROJECT]', '[LOCATION]', '[PHRASE_SET]'); + $request = (new DeletePhraseSetRequest()) + ->setName($formattedName); + $response = $gapicClient->deletePhraseSet($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/deletePhraseSetTest'); + 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 deleteRecognizerTest() + { + $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/deleteRecognizerTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name2 = 'name2-1052831874'; + $uid = 'uid115792'; + $displayName = 'displayName1615086568'; + $model = 'model104069929'; + $etag2 = 'etag2-1293302904'; + $reconciling = false; + $kmsKeyName = 'kmsKeyName2094986649'; + $kmsKeyVersionName = 'kmsKeyVersionName-1734350176'; + $expectedResponse = new Recognizer(); + $expectedResponse->setName($name2); + $expectedResponse->setUid($uid); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setModel($model); + $expectedResponse->setEtag($etag2); + $expectedResponse->setReconciling($reconciling); + $expectedResponse->setKmsKeyName($kmsKeyName); + $expectedResponse->setKmsKeyVersionName($kmsKeyVersionName); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/deleteRecognizerTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedName = $gapicClient->recognizerName('[PROJECT]', '[LOCATION]', '[RECOGNIZER]'); + $request = (new DeleteRecognizerRequest()) + ->setName($formattedName); + $response = $gapicClient->deleteRecognizer($request); + $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.speech.v2.Speech/DeleteRecognizer', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/deleteRecognizerTest'); + $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 deleteRecognizerExceptionTest() + { + $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/deleteRecognizerTest'); + $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->recognizerName('[PROJECT]', '[LOCATION]', '[RECOGNIZER]'); + $request = (new DeleteRecognizerRequest()) + ->setName($formattedName); + $response = $gapicClient->deleteRecognizer($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/deleteRecognizerTest'); + 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 getConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $kmsKeyName = 'kmsKeyName2094986649'; + $expectedResponse = new Config(); + $expectedResponse->setName($name2); + $expectedResponse->setKmsKeyName($kmsKeyName); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->configName('[PROJECT]', '[LOCATION]'); + $request = (new GetConfigRequest()) + ->setName($formattedName); + $response = $gapicClient->getConfig($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.speech.v2.Speech/GetConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getConfigExceptionTest() + { + $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->configName('[PROJECT]', '[LOCATION]'); + $request = (new GetConfigRequest()) + ->setName($formattedName); + try { + $gapicClient->getConfig($request); + // 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 getCustomClassTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $uid = 'uid115792'; + $displayName = 'displayName1615086568'; + $etag = 'etag3123477'; + $reconciling = false; + $kmsKeyName = 'kmsKeyName2094986649'; + $kmsKeyVersionName = 'kmsKeyVersionName-1734350176'; + $expectedResponse = new CustomClass(); + $expectedResponse->setName($name2); + $expectedResponse->setUid($uid); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setEtag($etag); + $expectedResponse->setReconciling($reconciling); + $expectedResponse->setKmsKeyName($kmsKeyName); + $expectedResponse->setKmsKeyVersionName($kmsKeyVersionName); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->customClassName('[PROJECT]', '[LOCATION]', '[CUSTOM_CLASS]'); + $request = (new GetCustomClassRequest()) + ->setName($formattedName); + $response = $gapicClient->getCustomClass($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.speech.v2.Speech/GetCustomClass', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getCustomClassExceptionTest() + { + $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->customClassName('[PROJECT]', '[LOCATION]', '[CUSTOM_CLASS]'); + $request = (new GetCustomClassRequest()) + ->setName($formattedName); + try { + $gapicClient->getCustomClass($request); + // 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 getPhraseSetTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $uid = 'uid115792'; + $boost = 9392221; + $displayName = 'displayName1615086568'; + $etag = 'etag3123477'; + $reconciling = false; + $kmsKeyName = 'kmsKeyName2094986649'; + $kmsKeyVersionName = 'kmsKeyVersionName-1734350176'; + $expectedResponse = new PhraseSet(); + $expectedResponse->setName($name2); + $expectedResponse->setUid($uid); + $expectedResponse->setBoost($boost); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setEtag($etag); + $expectedResponse->setReconciling($reconciling); + $expectedResponse->setKmsKeyName($kmsKeyName); + $expectedResponse->setKmsKeyVersionName($kmsKeyVersionName); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->phraseSetName('[PROJECT]', '[LOCATION]', '[PHRASE_SET]'); + $request = (new GetPhraseSetRequest()) + ->setName($formattedName); + $response = $gapicClient->getPhraseSet($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.speech.v2.Speech/GetPhraseSet', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getPhraseSetExceptionTest() + { + $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->phraseSetName('[PROJECT]', '[LOCATION]', '[PHRASE_SET]'); + $request = (new GetPhraseSetRequest()) + ->setName($formattedName); + try { + $gapicClient->getPhraseSet($request); + // 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 getRecognizerTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $uid = 'uid115792'; + $displayName = 'displayName1615086568'; + $model = 'model104069929'; + $etag = 'etag3123477'; + $reconciling = false; + $kmsKeyName = 'kmsKeyName2094986649'; + $kmsKeyVersionName = 'kmsKeyVersionName-1734350176'; + $expectedResponse = new Recognizer(); + $expectedResponse->setName($name2); + $expectedResponse->setUid($uid); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setModel($model); + $expectedResponse->setEtag($etag); + $expectedResponse->setReconciling($reconciling); + $expectedResponse->setKmsKeyName($kmsKeyName); + $expectedResponse->setKmsKeyVersionName($kmsKeyVersionName); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->recognizerName('[PROJECT]', '[LOCATION]', '[RECOGNIZER]'); + $request = (new GetRecognizerRequest()) + ->setName($formattedName); + $response = $gapicClient->getRecognizer($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.speech.v2.Speech/GetRecognizer', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getRecognizerExceptionTest() + { + $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->recognizerName('[PROJECT]', '[LOCATION]', '[RECOGNIZER]'); + $request = (new GetRecognizerRequest()) + ->setName($formattedName); + try { + $gapicClient->getRecognizer($request); + // 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 listCustomClassesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $customClassesElement = new CustomClass(); + $customClasses = [ + $customClassesElement, + ]; + $expectedResponse = new ListCustomClassesResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setCustomClasses($customClasses); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); + $request = (new ListCustomClassesRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listCustomClasses($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getCustomClasses()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.speech.v2.Speech/ListCustomClasses', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listCustomClassesExceptionTest() + { + $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]'); + $request = (new ListCustomClassesRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listCustomClasses($request); + // 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 listPhraseSetsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $phraseSetsElement = new PhraseSet(); + $phraseSets = [ + $phraseSetsElement, + ]; + $expectedResponse = new ListPhraseSetsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setPhraseSets($phraseSets); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); + $request = (new ListPhraseSetsRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listPhraseSets($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getPhraseSets()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.speech.v2.Speech/ListPhraseSets', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listPhraseSetsExceptionTest() + { + $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]'); + $request = (new ListPhraseSetsRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listPhraseSets($request); + // 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 listRecognizersTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $recognizersElement = new Recognizer(); + $recognizers = [ + $recognizersElement, + ]; + $expectedResponse = new ListRecognizersResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setRecognizers($recognizers); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); + $request = (new ListRecognizersRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listRecognizers($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getRecognizers()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.speech.v2.Speech/ListRecognizers', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listRecognizersExceptionTest() + { + $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]'); + $request = (new ListRecognizersRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listRecognizers($request); + // 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 recognizeTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new RecognizeResponse(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedRecognizer = $gapicClient->recognizerName('[PROJECT]', '[LOCATION]', '[RECOGNIZER]'); + $request = (new RecognizeRequest()) + ->setRecognizer($formattedRecognizer); + $response = $gapicClient->recognize($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.speech.v2.Speech/Recognize', $actualFuncCall); + $actualValue = $actualRequestObject->getRecognizer(); + $this->assertProtobufEquals($formattedRecognizer, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function recognizeExceptionTest() + { + $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 + $formattedRecognizer = $gapicClient->recognizerName('[PROJECT]', '[LOCATION]', '[RECOGNIZER]'); + $request = (new RecognizeRequest()) + ->setRecognizer($formattedRecognizer); + try { + $gapicClient->recognize($request); + // 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 streamingRecognizeTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new StreamingRecognizeResponse(); + $transport->addResponse($expectedResponse); + $expectedResponse2 = new StreamingRecognizeResponse(); + $transport->addResponse($expectedResponse2); + $expectedResponse3 = new StreamingRecognizeResponse(); + $transport->addResponse($expectedResponse3); + // Mock request + $formattedRecognizer = $gapicClient->recognizerName('[PROJECT]', '[LOCATION]', '[RECOGNIZER]'); + $request = new StreamingRecognizeRequest(); + $request->setRecognizer($formattedRecognizer); + $formattedRecognizer2 = $gapicClient->recognizerName('[PROJECT]', '[LOCATION]', '[RECOGNIZER]'); + $request2 = new StreamingRecognizeRequest(); + $request2->setRecognizer($formattedRecognizer2); + $formattedRecognizer3 = $gapicClient->recognizerName('[PROJECT]', '[LOCATION]', '[RECOGNIZER]'); + $request3 = new StreamingRecognizeRequest(); + $request3->setRecognizer($formattedRecognizer3); + $bidi = $gapicClient->streamingRecognize(); + $this->assertInstanceOf(BidiStream::class, $bidi); + $bidi->write($request); + $responses = []; + $responses[] = $bidi->read(); + $bidi->writeAll([ + $request2, + $request3, + ]); + foreach ($bidi->closeWriteAndReadAll() as $response) { + $responses[] = $response; + } + + $expectedResponses = []; + $expectedResponses[] = $expectedResponse; + $expectedResponses[] = $expectedResponse2; + $expectedResponses[] = $expectedResponse3; + $this->assertEquals($expectedResponses, $responses); + $createStreamRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($createStreamRequests)); + $streamFuncCall = $createStreamRequests[0]->getFuncCall(); + $streamRequestObject = $createStreamRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.speech.v2.Speech/StreamingRecognize', $streamFuncCall); + $this->assertNull($streamRequestObject); + $callObjects = $transport->popCallObjects(); + $this->assertSame(1, count($callObjects)); + $bidiCall = $callObjects[0]; + $writeRequests = $bidiCall->popReceivedCalls(); + $expectedRequests = []; + $expectedRequests[] = $request; + $expectedRequests[] = $request2; + $expectedRequests[] = $request3; + $this->assertEquals($expectedRequests, $writeRequests); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function streamingRecognizeExceptionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $status = new stdClass(); + $status->code = 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->setStreamingStatus($status); + $this->assertTrue($transport->isExhausted()); + $bidi = $gapicClient->streamingRecognize(); + $results = $bidi->closeWriteAndReadAll(); + try { + iterator_to_array($results); + // If the close stream method call did not throw, fail the test + $this->fail('Expected an ApiException, 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 undeleteCustomClassTest() + { + $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/undeleteCustomClassTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name2 = 'name2-1052831874'; + $uid = 'uid115792'; + $displayName = 'displayName1615086568'; + $etag2 = 'etag2-1293302904'; + $reconciling = false; + $kmsKeyName = 'kmsKeyName2094986649'; + $kmsKeyVersionName = 'kmsKeyVersionName-1734350176'; + $expectedResponse = new CustomClass(); + $expectedResponse->setName($name2); + $expectedResponse->setUid($uid); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setEtag($etag2); + $expectedResponse->setReconciling($reconciling); + $expectedResponse->setKmsKeyName($kmsKeyName); + $expectedResponse->setKmsKeyVersionName($kmsKeyVersionName); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/undeleteCustomClassTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedName = $gapicClient->customClassName('[PROJECT]', '[LOCATION]', '[CUSTOM_CLASS]'); + $request = (new UndeleteCustomClassRequest()) + ->setName($formattedName); + $response = $gapicClient->undeleteCustomClass($request); + $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.speech.v2.Speech/UndeleteCustomClass', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/undeleteCustomClassTest'); + $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 undeleteCustomClassExceptionTest() + { + $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/undeleteCustomClassTest'); + $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->customClassName('[PROJECT]', '[LOCATION]', '[CUSTOM_CLASS]'); + $request = (new UndeleteCustomClassRequest()) + ->setName($formattedName); + $response = $gapicClient->undeleteCustomClass($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/undeleteCustomClassTest'); + 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 undeletePhraseSetTest() + { + $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/undeletePhraseSetTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name2 = 'name2-1052831874'; + $uid = 'uid115792'; + $boost = 9392221; + $displayName = 'displayName1615086568'; + $etag2 = 'etag2-1293302904'; + $reconciling = false; + $kmsKeyName = 'kmsKeyName2094986649'; + $kmsKeyVersionName = 'kmsKeyVersionName-1734350176'; + $expectedResponse = new PhraseSet(); + $expectedResponse->setName($name2); + $expectedResponse->setUid($uid); + $expectedResponse->setBoost($boost); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setEtag($etag2); + $expectedResponse->setReconciling($reconciling); + $expectedResponse->setKmsKeyName($kmsKeyName); + $expectedResponse->setKmsKeyVersionName($kmsKeyVersionName); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/undeletePhraseSetTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedName = $gapicClient->phraseSetName('[PROJECT]', '[LOCATION]', '[PHRASE_SET]'); + $request = (new UndeletePhraseSetRequest()) + ->setName($formattedName); + $response = $gapicClient->undeletePhraseSet($request); + $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.speech.v2.Speech/UndeletePhraseSet', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/undeletePhraseSetTest'); + $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 undeletePhraseSetExceptionTest() + { + $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/undeletePhraseSetTest'); + $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->phraseSetName('[PROJECT]', '[LOCATION]', '[PHRASE_SET]'); + $request = (new UndeletePhraseSetRequest()) + ->setName($formattedName); + $response = $gapicClient->undeletePhraseSet($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/undeletePhraseSetTest'); + 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 undeleteRecognizerTest() + { + $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/undeleteRecognizerTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name2 = 'name2-1052831874'; + $uid = 'uid115792'; + $displayName = 'displayName1615086568'; + $model = 'model104069929'; + $etag2 = 'etag2-1293302904'; + $reconciling = false; + $kmsKeyName = 'kmsKeyName2094986649'; + $kmsKeyVersionName = 'kmsKeyVersionName-1734350176'; + $expectedResponse = new Recognizer(); + $expectedResponse->setName($name2); + $expectedResponse->setUid($uid); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setModel($model); + $expectedResponse->setEtag($etag2); + $expectedResponse->setReconciling($reconciling); + $expectedResponse->setKmsKeyName($kmsKeyName); + $expectedResponse->setKmsKeyVersionName($kmsKeyVersionName); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/undeleteRecognizerTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedName = $gapicClient->recognizerName('[PROJECT]', '[LOCATION]', '[RECOGNIZER]'); + $request = (new UndeleteRecognizerRequest()) + ->setName($formattedName); + $response = $gapicClient->undeleteRecognizer($request); + $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.speech.v2.Speech/UndeleteRecognizer', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/undeleteRecognizerTest'); + $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 undeleteRecognizerExceptionTest() + { + $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/undeleteRecognizerTest'); + $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->recognizerName('[PROJECT]', '[LOCATION]', '[RECOGNIZER]'); + $request = (new UndeleteRecognizerRequest()) + ->setName($formattedName); + $response = $gapicClient->undeleteRecognizer($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/undeleteRecognizerTest'); + 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 updateConfigTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $kmsKeyName = 'kmsKeyName2094986649'; + $expectedResponse = new Config(); + $expectedResponse->setName($name); + $expectedResponse->setKmsKeyName($kmsKeyName); + $transport->addResponse($expectedResponse); + // Mock request + $config = new Config(); + $request = (new UpdateConfigRequest()) + ->setConfig($config); + $response = $gapicClient->updateConfig($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.speech.v2.Speech/UpdateConfig', $actualFuncCall); + $actualValue = $actualRequestObject->getConfig(); + $this->assertProtobufEquals($config, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateConfigExceptionTest() + { + $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 + $config = new Config(); + $request = (new UpdateConfigRequest()) + ->setConfig($config); + try { + $gapicClient->updateConfig($request); + // 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 updateCustomClassTest() + { + $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/updateCustomClassTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $uid = 'uid115792'; + $displayName = 'displayName1615086568'; + $etag = 'etag3123477'; + $reconciling = false; + $kmsKeyName = 'kmsKeyName2094986649'; + $kmsKeyVersionName = 'kmsKeyVersionName-1734350176'; + $expectedResponse = new CustomClass(); + $expectedResponse->setName($name); + $expectedResponse->setUid($uid); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setEtag($etag); + $expectedResponse->setReconciling($reconciling); + $expectedResponse->setKmsKeyName($kmsKeyName); + $expectedResponse->setKmsKeyVersionName($kmsKeyVersionName); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/updateCustomClassTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $customClass = new CustomClass(); + $request = (new UpdateCustomClassRequest()) + ->setCustomClass($customClass); + $response = $gapicClient->updateCustomClass($request); + $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.speech.v2.Speech/UpdateCustomClass', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getCustomClass(); + $this->assertProtobufEquals($customClass, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updateCustomClassTest'); + $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 updateCustomClassExceptionTest() + { + $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/updateCustomClassTest'); + $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 + $customClass = new CustomClass(); + $request = (new UpdateCustomClassRequest()) + ->setCustomClass($customClass); + $response = $gapicClient->updateCustomClass($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updateCustomClassTest'); + 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 updatePhraseSetTest() + { + $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/updatePhraseSetTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $uid = 'uid115792'; + $boost = 9392221; + $displayName = 'displayName1615086568'; + $etag = 'etag3123477'; + $reconciling = false; + $kmsKeyName = 'kmsKeyName2094986649'; + $kmsKeyVersionName = 'kmsKeyVersionName-1734350176'; + $expectedResponse = new PhraseSet(); + $expectedResponse->setName($name); + $expectedResponse->setUid($uid); + $expectedResponse->setBoost($boost); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setEtag($etag); + $expectedResponse->setReconciling($reconciling); + $expectedResponse->setKmsKeyName($kmsKeyName); + $expectedResponse->setKmsKeyVersionName($kmsKeyVersionName); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/updatePhraseSetTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $phraseSet = new PhraseSet(); + $request = (new UpdatePhraseSetRequest()) + ->setPhraseSet($phraseSet); + $response = $gapicClient->updatePhraseSet($request); + $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.speech.v2.Speech/UpdatePhraseSet', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getPhraseSet(); + $this->assertProtobufEquals($phraseSet, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updatePhraseSetTest'); + $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 updatePhraseSetExceptionTest() + { + $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/updatePhraseSetTest'); + $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 + $phraseSet = new PhraseSet(); + $request = (new UpdatePhraseSetRequest()) + ->setPhraseSet($phraseSet); + $response = $gapicClient->updatePhraseSet($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updatePhraseSetTest'); + 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 updateRecognizerTest() + { + $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/updateRecognizerTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $uid = 'uid115792'; + $displayName = 'displayName1615086568'; + $model = 'model104069929'; + $etag = 'etag3123477'; + $reconciling = false; + $kmsKeyName = 'kmsKeyName2094986649'; + $kmsKeyVersionName = 'kmsKeyVersionName-1734350176'; + $expectedResponse = new Recognizer(); + $expectedResponse->setName($name); + $expectedResponse->setUid($uid); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setModel($model); + $expectedResponse->setEtag($etag); + $expectedResponse->setReconciling($reconciling); + $expectedResponse->setKmsKeyName($kmsKeyName); + $expectedResponse->setKmsKeyVersionName($kmsKeyVersionName); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/updateRecognizerTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $recognizer = new Recognizer(); + $request = (new UpdateRecognizerRequest()) + ->setRecognizer($recognizer); + $response = $gapicClient->updateRecognizer($request); + $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.speech.v2.Speech/UpdateRecognizer', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getRecognizer(); + $this->assertProtobufEquals($recognizer, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updateRecognizerTest'); + $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 updateRecognizerExceptionTest() + { + $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/updateRecognizerTest'); + $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 + $recognizer = new Recognizer(); + $request = (new UpdateRecognizerRequest()) + ->setRecognizer($recognizer); + $response = $gapicClient->updateRecognizer($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updateRecognizerTest'); + 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); + $request = new GetLocationRequest(); + $response = $gapicClient->getLocation($request); + $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); + $request = new GetLocationRequest(); + try { + $gapicClient->getLocation($request); + // 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); + $request = new ListLocationsRequest(); + $response = $gapicClient->listLocations($request); + $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); + $request = new ListLocationsRequest(); + try { + $gapicClient->listLocations($request); + // 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 batchRecognizeAsyncTest() + { + $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/batchRecognizeTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $expectedResponse = new BatchRecognizeResponse(); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/batchRecognizeTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedRecognizer = $gapicClient->recognizerName('[PROJECT]', '[LOCATION]', '[RECOGNIZER]'); + $request = (new BatchRecognizeRequest()) + ->setRecognizer($formattedRecognizer); + $response = $gapicClient->batchRecognizeAsync($request)->wait(); + $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.speech.v2.Speech/BatchRecognize', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getRecognizer(); + $this->assertProtobufEquals($formattedRecognizer, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/batchRecognizeTest'); + $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()); + } +} diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/Common.php b/owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/Common.php new file mode 100644 index 000000000000..cd467ddbc772 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/Common.php @@ -0,0 +1,24 @@ +internalAddGeneratedFile( + "\x0A\x84\x03\x0A)google/cloud/vectorsearch/v1/common.proto\x12\x1Cgoogle.cloud.vectorsearch.v1*W\x0A\x0EDistanceMetric\x12\x1F\x0A\x1BDISTANCE_METRIC_UNSPECIFIED\x10\x00\x12\x0F\x0A\x0BDOT_PRODUCT\x10\x01\x12\x13\x0A\x0FCOSINE_DISTANCE\x10\x02B\xD7\x01\x0A com.google.cloud.vectorsearch.v1B\x0BCommonProtoP\x01ZDcloud.google.com/go/vectorsearch/apiv1/vectorsearchpb;vectorsearchpb\xAA\x02\x1CGoogle.Cloud.VectorSearch.V1\xCA\x02\x1CGoogle\\Cloud\\VectorSearch\\V1\xEA\x02\x1FGoogle::Cloud::VectorSearch::V1b\x06proto3" + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/DataObject.php b/owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/DataObject.php new file mode 100644 index 000000000000..a0be445d7b98 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/DataObject.php @@ -0,0 +1,28 @@ +internalAddGeneratedFile( + "\x0A\xB1\x09\x0A.google/cloud/vectorsearch/v1/data_object.proto\x12\x1Cgoogle.cloud.vectorsearch.v1\x1A\x19google/api/resource.proto\x1A\x1Cgoogle/protobuf/struct.proto\x1A\x1Fgoogle/protobuf/timestamp.proto\"\xAD\x04\x0A\x0ADataObject\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x08\x12\x1B\x0A\x0Edata_object_id\x18\x02 \x01(\x09B\x03\xE0A\x03\x124\x0A\x0Bcreate_time\x18\x04 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x05 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12*\x0A\x04data\x18\x06 \x01(\x0B2\x17.google.protobuf.StructB\x03\xE0A\x01\x12K\x0A\x07vectors\x18\x07 \x03(\x0B25.google.cloud.vectorsearch.v1.DataObject.VectorsEntryB\x03\xE0A\x01\x12\x11\x0A\x04etag\x18\x08 \x01(\x09B\x03\xE0A\x01\x1AT\x0A\x0CVectorsEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x123\x0A\x05value\x18\x02 \x01(\x0B2\$.google.cloud.vectorsearch.v1.Vector:\x028\x01:\xA0\x01\xEAA\x9C\x01\x0A&vectorsearch.googleapis.com/DataObject\x12Yprojects/{project}/locations/{location}/collections/{collection}/dataObjects/{dataObject}*\x0BdataObjects2\x0AdataObject\"\x91\x01\x0A\x06Vector\x12:\x0A\x05dense\x18\x02 \x01(\x0B2).google.cloud.vectorsearch.v1.DenseVectorH\x00\x12<\x0A\x06sparse\x18\x03 \x01(\x0B2*.google.cloud.vectorsearch.v1.SparseVectorH\x00B\x0D\x0A\x0Bvector_type\"\"\x0A\x0BDenseVector\x12\x13\x0A\x06values\x18\x01 \x03(\x02B\x03\xE0A\x02\"9\x0A\x0CSparseVector\x12\x13\x0A\x06values\x18\x01 \x03(\x02B\x03\xE0A\x02\x12\x14\x0A\x07indices\x18\x02 \x03(\x05B\x03\xE0A\x02B\xDB\x01\x0A com.google.cloud.vectorsearch.v1B\x0FDataObjectProtoP\x01ZDcloud.google.com/go/vectorsearch/apiv1/vectorsearchpb;vectorsearchpb\xAA\x02\x1CGoogle.Cloud.VectorSearch.V1\xCA\x02\x1CGoogle\\Cloud\\VectorSearch\\V1\xEA\x02\x1FGoogle::Cloud::VectorSearch::V1b\x06proto3" + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/DataObjectSearchService.php b/owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/DataObjectSearchService.php new file mode 100644 index 000000000000..34f80ed9d5b4 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/DataObjectSearchService.php @@ -0,0 +1,32 @@ +internalAddGeneratedFile( + "\x0A\xD6)\x0A=google/cloud/vectorsearch/v1/data_object_search_service.proto\x12\x1Cgoogle.cloud.vectorsearch.v1\x1A\x17google/api/client.proto\x1A\x1Fgoogle/api/field_behavior.proto\x1A\x19google/api/resource.proto\x1A)google/cloud/vectorsearch/v1/common.proto\x1A.google/cloud/vectorsearch/v1/data_object.proto\x1A3google/cloud/vectorsearch/v1/embedding_config.proto\x1A\x1Cgoogle/protobuf/struct.proto\"b\x0A\x0COutputFields\x12\x18\x0A\x0Bdata_fields\x18\x01 \x03(\x09B\x03\xE0A\x01\x12\x1A\x0A\x0Dvector_fields\x18\x02 \x03(\x09B\x03\xE0A\x01\x12\x1C\x0A\x0Fmetadata_fields\x18\x03 \x03(\x09B\x03\xE0A\x01\"\x85\x02\x0A\x0ASearchHint\x12I\x0A\x08knn_hint\x18\x03 \x01(\x0B20.google.cloud.vectorsearch.v1.SearchHint.KnnHintB\x03\xE0A\x01H\x00\x12M\x0A\x0Aindex_hint\x18\x04 \x01(\x0B22.google.cloud.vectorsearch.v1.SearchHint.IndexHintB\x03\xE0A\x01H\x00\x1AD\x0A\x09IndexHint\x127\x0A\x04name\x18\x01 \x01(\x09B)\xE0A\x02\xFAA#\x0A!vectorsearch.googleapis.com/Index\x1A\x09\x0A\x07KnnHintB\x0C\x0A\x0Aindex_type\"\xE6\x01\x0A\x06Search\x12C\x0A\x0Dvector_search\x18\x01 \x01(\x0B2*.google.cloud.vectorsearch.v1.VectorSearchH\x00\x12G\x0A\x0Fsemantic_search\x18\x02 \x01(\x0B2,.google.cloud.vectorsearch.v1.SemanticSearchH\x00\x12?\x0A\x0Btext_search\x18\x03 \x01(\x0B2(.google.cloud.vectorsearch.v1.TextSearchH\x00B\x0D\x0A\x0Bsearch_type\"\xE3\x03\x0A\x0CVectorSearch\x12;\x0A\x06vector\x18\x01 \x01(\x0B2).google.cloud.vectorsearch.v1.DenseVectorH\x00\x12C\x0A\x0Dsparse_vector\x18\x02 \x01(\x0B2*.google.cloud.vectorsearch.v1.SparseVectorH\x00\x12\x19\x0A\x0Csearch_field\x18\x08 \x01(\x09B\x03\xE0A\x02\x12,\x0A\x06filter\x18\x04 \x01(\x0B2\x17.google.protobuf.StructB\x03\xE0A\x01\x12\x17\x0A\x05top_k\x18\x05 \x01(\x05B\x03\xE0A\x01H\x01\x88\x01\x01\x12F\x0A\x0Doutput_fields\x18\x07 \x01(\x0B2*.google.cloud.vectorsearch.v1.OutputFieldsB\x03\xE0A\x01\x12B\x0A\x0Bsearch_hint\x18\x09 \x01(\x0B2(.google.cloud.vectorsearch.v1.SearchHintB\x03\xE0A\x01\x12J\x0A\x0Fdistance_metric\x18\x0B \x01(\x0E2,.google.cloud.vectorsearch.v1.DistanceMetricB\x03\xE0A\x01B\x0D\x0A\x0Bvector_typeB\x08\x0A\x06_top_k\"\xEB\x02\x0A\x0ESemanticSearch\x12\x18\x0A\x0Bsearch_text\x18\x01 \x01(\x09B\x03\xE0A\x02\x12\x19\x0A\x0Csearch_field\x18\x02 \x01(\x09B\x03\xE0A\x02\x12G\x0A\x09task_type\x18\x05 \x01(\x0E2/.google.cloud.vectorsearch.v1.EmbeddingTaskTypeB\x03\xE0A\x02\x12F\x0A\x0Doutput_fields\x18\x03 \x01(\x0B2*.google.cloud.vectorsearch.v1.OutputFieldsB\x03\xE0A\x01\x12,\x0A\x06filter\x18\x06 \x01(\x0B2\x17.google.protobuf.StructB\x03\xE0A\x01\x12\x17\x0A\x05top_k\x18\x04 \x01(\x05B\x03\xE0A\x01H\x00\x88\x01\x01\x12B\x0A\x0Bsearch_hint\x18\x07 \x01(\x0B2(.google.cloud.vectorsearch.v1.SearchHintB\x03\xE0A\x01B\x08\x0A\x06_top_k\"\xDE\x01\x0A\x0ATextSearch\x12\x18\x0A\x0Bsearch_text\x18\x01 \x01(\x09B\x03\xE0A\x02\x12\x1D\x0A\x10data_field_names\x18\x02 \x03(\x09B\x03\xE0A\x02\x12F\x0A\x0Doutput_fields\x18\x03 \x01(\x0B2*.google.cloud.vectorsearch.v1.OutputFieldsB\x03\xE0A\x01\x12\x17\x0A\x05top_k\x18\x04 \x01(\x05B\x03\xE0A\x01H\x00\x88\x01\x01\x12,\x0A\x06filter\x18\x05 \x01(\x0B2\x17.google.protobuf.StructB\x03\xE0A\x01B\x08\x0A\x06_top_k\"\xEE\x02\x0A\x18SearchDataObjectsRequest\x12C\x0A\x0Dvector_search\x18\x02 \x01(\x0B2*.google.cloud.vectorsearch.v1.VectorSearchH\x00\x12G\x0A\x0Fsemantic_search\x18\x04 \x01(\x0B2,.google.cloud.vectorsearch.v1.SemanticSearchH\x00\x12D\x0A\x0Btext_search\x18\x07 \x01(\x0B2(.google.cloud.vectorsearch.v1.TextSearchB\x03\xE0A\x01H\x00\x12>\x0A\x06parent\x18\x01 \x01(\x09B.\xE0A\x02\xFAA(\x0A&vectorsearch.googleapis.com/Collection\x12\x16\x0A\x09page_size\x18\x05 \x01(\x05B\x03\xE0A\x01\x12\x17\x0A\x0Apage_token\x18\x06 \x01(\x09B\x03\xE0A\x01B\x0D\x0A\x0Bsearch_type\"{\x0A\x0CSearchResult\x12B\x0A\x0Bdata_object\x18\x01 \x01(\x0B2(.google.cloud.vectorsearch.v1.DataObjectB\x03\xE0A\x03\x12\x1A\x0A\x08distance\x18\x02 \x01(\x01B\x03\xE0A\x03H\x00\x88\x01\x01B\x0B\x0A\x09_distance\"{\x0A\x19SearchDataObjectsResponse\x12@\x0A\x07results\x18\x01 \x03(\x0B2*.google.cloud.vectorsearch.v1.SearchResultB\x03\xE0A\x03\x12\x1C\x0A\x0Fnext_page_token\x18\x02 \x01(\x09B\x03\xE0A\x03\"\xD4\x01\x0A\x1BAggregateDataObjectsRequest\x12>\x0A\x06parent\x18\x01 \x01(\x09B.\xE0A\x02\xFAA(\x0A&vectorsearch.googleapis.com/Collection\x12,\x0A\x06filter\x18\x02 \x01(\x0B2\x17.google.protobuf.StructB\x03\xE0A\x01\x12G\x0A\x09aggregate\x18\x03 \x01(\x0E2/.google.cloud.vectorsearch.v1.AggregationMethodB\x03\xE0A\x02\"W\x0A\x1CAggregateDataObjectsResponse\x127\x0A\x11aggregate_results\x18\x01 \x03(\x0B2\x17.google.protobuf.StructB\x03\xE0A\x03\"\x80\x02\x0A\x17QueryDataObjectsRequest\x12>\x0A\x06parent\x18\x01 \x01(\x09B.\xE0A\x02\xFAA(\x0A&vectorsearch.googleapis.com/Collection\x12,\x0A\x06filter\x18\x02 \x01(\x0B2\x17.google.protobuf.StructB\x03\xE0A\x01\x12F\x0A\x0Doutput_fields\x18\x07 \x01(\x0B2*.google.cloud.vectorsearch.v1.OutputFieldsB\x03\xE0A\x01\x12\x16\x0A\x09page_size\x18\x05 \x01(\x05B\x03\xE0A\x01\x12\x17\x0A\x0Apage_token\x18\x06 \x01(\x09B\x03\xE0A\x01\"}\x0A\x18QueryDataObjectsResponse\x12C\x0A\x0Cdata_objects\x18\x04 \x03(\x0B2(.google.cloud.vectorsearch.v1.DataObjectB\x03\xE0A\x03\x12\x1C\x0A\x0Fnext_page_token\x18\x03 \x01(\x09B\x03\xE0A\x03\"\xB6\x03\x0A\x1DBatchSearchDataObjectsRequest\x12>\x0A\x06parent\x18\x01 \x01(\x09B.\xE0A\x02\xFAA(\x0A&vectorsearch.googleapis.com/Collection\x12;\x0A\x08searches\x18\x02 \x03(\x0B2\$.google.cloud.vectorsearch.v1.SearchB\x03\xE0A\x02\x12g\x0A\x07combine\x18\x03 \x01(\x0B2Q.google.cloud.vectorsearch.v1.BatchSearchDataObjectsRequest.CombineResultsOptionsB\x03\xE0A\x01\x1A\xAE\x01\x0A\x15CombineResultsOptions\x129\x0A\x06ranker\x18\x01 \x01(\x0B2\$.google.cloud.vectorsearch.v1.RankerB\x03\xE0A\x02\x12F\x0A\x0Doutput_fields\x18\x02 \x01(\x0B2*.google.cloud.vectorsearch.v1.OutputFieldsB\x03\xE0A\x01\x12\x12\x0A\x05top_k\x18\x03 \x01(\x05B\x03\xE0A\x01\"U\x0A\x06Ranker\x12A\x0A\x03rrf\x18\x01 \x01(\x0B22.google.cloud.vectorsearch.v1.ReciprocalRankFusionH\x00B\x08\x0A\x06ranker\",\x0A\x14ReciprocalRankFusion\x12\x14\x0A\x07weights\x18\x01 \x03(\x01B\x03\xE0A\x02\"o\x0A\x1EBatchSearchDataObjectsResponse\x12M\x0A\x07results\x18\x01 \x03(\x0B27.google.cloud.vectorsearch.v1.SearchDataObjectsResponseB\x03\xE0A\x03*B\x0A\x11AggregationMethod\x12\"\x0A\x1EAGGREGATION_METHOD_UNSPECIFIED\x10\x00\x12\x09\x0A\x05COUNT\x10\x012\xE6\x07\x0A\x17DataObjectSearchService\x12\xD5\x01\x0A\x11SearchDataObjects\x126.google.cloud.vectorsearch.v1.SearchDataObjectsRequest\x1A7.google.cloud.vectorsearch.v1.SearchDataObjectsResponse\"O\x82\xD3\xE4\x93\x02I\"D/v1/{parent=projects/*/locations/*/collections/*}/dataObjects:search:\x01*\x12\xD1\x01\x0A\x10QueryDataObjects\x125.google.cloud.vectorsearch.v1.QueryDataObjectsRequest\x1A6.google.cloud.vectorsearch.v1.QueryDataObjectsResponse\"N\x82\xD3\xE4\x93\x02H\"C/v1/{parent=projects/*/locations/*/collections/*}/dataObjects:query:\x01*\x12\xE1\x01\x0A\x14AggregateDataObjects\x129.google.cloud.vectorsearch.v1.AggregateDataObjectsRequest\x1A:.google.cloud.vectorsearch.v1.AggregateDataObjectsResponse\"R\x82\xD3\xE4\x93\x02L\"G/v1/{parent=projects/*/locations/*/collections/*}/dataObjects:aggregate:\x01*\x12\xE9\x01\x0A\x16BatchSearchDataObjects\x12;.google.cloud.vectorsearch.v1.BatchSearchDataObjectsRequest\x1A<.google.cloud.vectorsearch.v1.BatchSearchDataObjectsResponse\"T\x82\xD3\xE4\x93\x02N\"I/v1/{parent=projects/*/locations/*/collections/*}/dataObjects:batchSearch:\x01*\x1AO\xCAA\x1Bvectorsearch.googleapis.com\xD2A.https://www.googleapis.com/auth/cloud-platformB\xE8\x01\x0A com.google.cloud.vectorsearch.v1B\x1CDataObjectSearchServiceProtoP\x01ZDcloud.google.com/go/vectorsearch/apiv1/vectorsearchpb;vectorsearchpb\xAA\x02\x1CGoogle.Cloud.VectorSearch.V1\xCA\x02\x1CGoogle\\Cloud\\VectorSearch\\V1\xEA\x02\x1FGoogle::Cloud::VectorSearch::V1b\x06proto3" + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/DataObjectService.php b/owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/DataObjectService.php new file mode 100644 index 000000000000..b3cfadbf1eaa --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/DataObjectService.php @@ -0,0 +1,31 @@ +internalAddGeneratedFile( + "\x0A\xAC\x1A\x0A6google/cloud/vectorsearch/v1/data_object_service.proto\x12\x1Cgoogle.cloud.vectorsearch.v1\x1A\x17google/api/client.proto\x1A\x1Fgoogle/api/field_behavior.proto\x1A\x19google/api/resource.proto\x1A.google/cloud/vectorsearch/v1/data_object.proto\x1A\x1Bgoogle/protobuf/empty.proto\x1A google/protobuf/field_mask.proto\"\xBA\x01\x0A\x17CreateDataObjectRequest\x12>\x0A\x06parent\x18\x01 \x01(\x09B.\xE0A\x02\xFAA(\x0A&vectorsearch.googleapis.com/Collection\x12\x1B\x0A\x0Edata_object_id\x18\x02 \x01(\x09B\x03\xE0A\x02\x12B\x0A\x0Bdata_object\x18\x03 \x01(\x0B2(.google.cloud.vectorsearch.v1.DataObjectB\x03\xE0A\x02\"\xAD\x01\x0A\x1DBatchCreateDataObjectsRequest\x12>\x0A\x06parent\x18\x01 \x01(\x09B.\xE0A\x02\xFAA(\x0A&vectorsearch.googleapis.com/Collection\x12L\x0A\x08requests\x18\x02 \x03(\x0B25.google.cloud.vectorsearch.v1.CreateDataObjectRequestB\x03\xE0A\x02\"e\x0A\x1EBatchCreateDataObjectsResponse\x12C\x0A\x0Cdata_objects\x18\x01 \x03(\x0B2(.google.cloud.vectorsearch.v1.DataObjectB\x03\xE0A\x03\"T\x0A\x14GetDataObjectRequest\x12<\x0A\x04name\x18\x01 \x01(\x09B.\xE0A\x02\xFAA(\x0A&vectorsearch.googleapis.com/DataObject\"\x93\x01\x0A\x17UpdateDataObjectRequest\x12B\x0A\x0Bdata_object\x18\x01 \x01(\x0B2(.google.cloud.vectorsearch.v1.DataObjectB\x03\xE0A\x02\x124\x0A\x0Bupdate_mask\x18\x02 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x01\"\xAD\x01\x0A\x1DBatchUpdateDataObjectsRequest\x12>\x0A\x06parent\x18\x01 \x01(\x09B.\xE0A\x02\xFAA(\x0A&vectorsearch.googleapis.com/Collection\x12L\x0A\x08requests\x18\x02 \x03(\x0B25.google.cloud.vectorsearch.v1.UpdateDataObjectRequestB\x03\xE0A\x02\" \x0A\x1EBatchUpdateDataObjectsResponse\"j\x0A\x17DeleteDataObjectRequest\x12<\x0A\x04name\x18\x01 \x01(\x09B.\xE0A\x02\xFAA(\x0A&vectorsearch.googleapis.com/DataObject\x12\x11\x0A\x04etag\x18\x02 \x01(\x09B\x03\xE0A\x01\"\xAD\x01\x0A\x1DBatchDeleteDataObjectsRequest\x12>\x0A\x06parent\x18\x01 \x01(\x09B.\xE0A\x02\xFAA(\x0A&vectorsearch.googleapis.com/Collection\x12L\x0A\x08requests\x18\x03 \x03(\x0B25.google.cloud.vectorsearch.v1.DeleteDataObjectRequestB\x03\xE0A\x022\xF4\x0C\x0A\x11DataObjectService\x12\xEB\x01\x0A\x10CreateDataObject\x125.google.cloud.vectorsearch.v1.CreateDataObjectRequest\x1A(.google.cloud.vectorsearch.v1.DataObject\"v\xDAA!parent,data_object,data_object_id\x82\xD3\xE4\x93\x02L\"=/v1/{parent=projects/*/locations/*/collections/*}/dataObjects:\x0Bdata_object\x12\xE9\x01\x0A\x16BatchCreateDataObjects\x12;.google.cloud.vectorsearch.v1.BatchCreateDataObjectsRequest\x1A<.google.cloud.vectorsearch.v1.BatchCreateDataObjectsResponse\"T\x82\xD3\xE4\x93\x02N\"I/v1/{parent=projects/*/locations/*/collections/*}/dataObjects:batchCreate:\x01*\x12\xBB\x01\x0A\x0DGetDataObject\x122.google.cloud.vectorsearch.v1.GetDataObjectRequest\x1A(.google.cloud.vectorsearch.v1.DataObject\"L\xDAA\x04name\x82\xD3\xE4\x93\x02?\x12=/v1/{name=projects/*/locations/*/collections/*/dataObjects/*}\x12\xED\x01\x0A\x10UpdateDataObject\x125.google.cloud.vectorsearch.v1.UpdateDataObjectRequest\x1A(.google.cloud.vectorsearch.v1.DataObject\"x\xDAA\x17data_object,update_mask\x82\xD3\xE4\x93\x02X2I/v1/{data_object.name=projects/*/locations/*/collections/*/dataObjects/*}:\x0Bdata_object\x12\xFB\x01\x0A\x16BatchUpdateDataObjects\x12;.google.cloud.vectorsearch.v1.BatchUpdateDataObjectsRequest\x1A<.google.cloud.vectorsearch.v1.BatchUpdateDataObjectsResponse\"f\xDAA\x0Fparent,requests\x82\xD3\xE4\x93\x02N\"I/v1/{parent=projects/*/locations/*/collections/*}/dataObjects:batchUpdate:\x01*\x12\xAF\x01\x0A\x10DeleteDataObject\x125.google.cloud.vectorsearch.v1.DeleteDataObjectRequest\x1A\x16.google.protobuf.Empty\"L\xDAA\x04name\x82\xD3\xE4\x93\x02?*=/v1/{name=projects/*/locations/*/collections/*/dataObjects/*}\x12\xD5\x01\x0A\x16BatchDeleteDataObjects\x12;.google.cloud.vectorsearch.v1.BatchDeleteDataObjectsRequest\x1A\x16.google.protobuf.Empty\"f\xDAA\x0Fparent,requests\x82\xD3\xE4\x93\x02N\"I/v1/{parent=projects/*/locations/*/collections/*}/dataObjects:batchDelete:\x01*\x1AO\xCAA\x1Bvectorsearch.googleapis.com\xD2A.https://www.googleapis.com/auth/cloud-platformB\xE2\x01\x0A com.google.cloud.vectorsearch.v1B\x16DataObjectServiceProtoP\x01ZDcloud.google.com/go/vectorsearch/apiv1/vectorsearchpb;vectorsearchpb\xAA\x02\x1CGoogle.Cloud.VectorSearch.V1\xCA\x02\x1CGoogle\\Cloud\\VectorSearch\\V1\xEA\x02\x1FGoogle::Cloud::VectorSearch::V1b\x06proto3" + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/EmbeddingConfig.php b/owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/EmbeddingConfig.php new file mode 100644 index 000000000000..ac217693e49c --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/EmbeddingConfig.php @@ -0,0 +1,25 @@ +internalAddGeneratedFile( + "\x0A\xC2\x05\x0A3google/cloud/vectorsearch/v1/embedding_config.proto\x12\x1Cgoogle.cloud.vectorsearch.v1\"\x93\x01\x0A\x15VertexEmbeddingConfig\x12\x15\x0A\x08model_id\x18\x01 \x01(\x09B\x03\xE0A\x02\x12\x1A\x0A\x0Dtext_template\x18\x02 \x01(\x09B\x03\xE0A\x02\x12G\x0A\x09task_type\x18\x03 \x01(\x0E2/.google.cloud.vectorsearch.v1.EmbeddingTaskTypeB\x03\xE0A\x02*\xEB\x01\x0A\x11EmbeddingTaskType\x12#\x0A\x1FEMBEDDING_TASK_TYPE_UNSPECIFIED\x10\x00\x12\x13\x0A\x0FRETRIEVAL_QUERY\x10\x01\x12\x16\x0A\x12RETRIEVAL_DOCUMENT\x10\x02\x12\x17\x0A\x13SEMANTIC_SIMILARITY\x10\x03\x12\x12\x0A\x0ECLASSIFICATION\x10\x04\x12\x0E\x0A\x0ACLUSTERING\x10\x05\x12\x16\x0A\x12QUESTION_ANSWERING\x10\x06\x12\x15\x0A\x11FACT_VERIFICATION\x10\x07\x12\x18\x0A\x14CODE_RETRIEVAL_QUERY\x10\x08B\xE0\x01\x0A com.google.cloud.vectorsearch.v1B\x14EmbeddingConfigProtoP\x01ZDcloud.google.com/go/vectorsearch/apiv1/vectorsearchpb;vectorsearchpb\xAA\x02\x1CGoogle.Cloud.VectorSearch.V1\xCA\x02\x1CGoogle\\Cloud\\VectorSearch\\V1\xEA\x02\x1FGoogle::Cloud::VectorSearch::V1b\x06proto3" + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/EncryptionSpec.php b/owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/EncryptionSpec.php new file mode 100644 index 000000000000..af0cb82e4992 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/EncryptionSpec.php @@ -0,0 +1,26 @@ +internalAddGeneratedFile( + "\x0A\xA8\x04\x0A2google/cloud/vectorsearch/v1/encryption_spec.proto\x12\x1Cgoogle.cloud.vectorsearch.v1\x1A\x19google/api/resource.proto\"T\x0A\x0EEncryptionSpec\x12B\x0A\x0Fcrypto_key_name\x18\x01 \x01(\x09B)\xE0A\x02\xFAA#\x0A!cloudkms.googleapis.com/CryptoKeyB\xDA\x02\x0A com.google.cloud.vectorsearch.v1B\x13EncryptionSpecProtoP\x01ZDcloud.google.com/go/vectorsearch/apiv1/vectorsearchpb;vectorsearchpb\xAA\x02\x1CGoogle.Cloud.VectorSearch.V1\xCA\x02\x1CGoogle\\Cloud\\VectorSearch\\V1\xEA\x02\x1FGoogle::Cloud::VectorSearch::V1\xEAAx\x0A!cloudkms.googleapis.com/CryptoKey\x12Sprojects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}b\x06proto3" + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/VectorsearchService.php b/owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/VectorsearchService.php new file mode 100644 index 000000000000..163e08d1aa1e --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/VectorsearchService.php @@ -0,0 +1,38 @@ +internalAddGeneratedFile( + "\x0A\xA5G\x0A7google/cloud/vectorsearch/v1/vectorsearch_service.proto\x12\x1Cgoogle.cloud.vectorsearch.v1\x1A\x17google/api/client.proto\x1A\x1Fgoogle/api/field_behavior.proto\x1A\x1Bgoogle/api/field_info.proto\x1A\x19google/api/resource.proto\x1A)google/cloud/vectorsearch/v1/common.proto\x1A3google/cloud/vectorsearch/v1/embedding_config.proto\x1A2google/cloud/vectorsearch/v1/encryption_spec.proto\x1A#google/longrunning/operations.proto\x1A\x1Bgoogle/protobuf/empty.proto\x1A google/protobuf/field_mask.proto\x1A\x1Cgoogle/protobuf/struct.proto\x1A\x1Fgoogle/protobuf/timestamp.proto\x1A\x17google/rpc/status.proto\"\xFE\x05\x0A\x0ACollection\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x08\x12\x19\x0A\x0Cdisplay_name\x18\x08 \x01(\x09B\x03\xE0A\x01\x12\x18\x0A\x0Bdescription\x18\x09 \x01(\x09B\x03\xE0A\x01\x124\x0A\x0Bcreate_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x03 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12I\x0A\x06labels\x18\x04 \x03(\x0B24.google.cloud.vectorsearch.v1.Collection.LabelsEntryB\x03\xE0A\x01\x12V\x0A\x0Dvector_schema\x18\x07 \x03(\x0B2:.google.cloud.vectorsearch.v1.Collection.VectorSchemaEntryB\x03\xE0A\x01\x121\x0A\x0Bdata_schema\x18\x0A \x01(\x0B2\x17.google.protobuf.StructB\x03\xE0A\x01\x12M\x0A\x0Fencryption_spec\x18\x0B \x01(\x0B2,.google.cloud.vectorsearch.v1.EncryptionSpecB\x06\xE0A\x05\xE0A\x01\x1A-\x0A\x0BLabelsEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12\x0D\x0A\x05value\x18\x02 \x01(\x09:\x028\x01\x1A^\x0A\x11VectorSchemaEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x128\x0A\x05value\x18\x02 \x01(\x0B2).google.cloud.vectorsearch.v1.VectorField:\x028\x01:\x87\x01\xEAA\x83\x01\x0A&vectorsearch.googleapis.com/Collection\x12@projects/{project}/locations/{location}/collections/{collection}*\x0Bcollections2\x0Acollection\"\xB5\x01\x0A\x0BVectorField\x12F\x0A\x0Cdense_vector\x18\x03 \x01(\x0B2..google.cloud.vectorsearch.v1.DenseVectorFieldH\x00\x12H\x0A\x0Dsparse_vector\x18\x04 \x01(\x0B2/.google.cloud.vectorsearch.v1.SparseVectorFieldH\x00B\x14\x0A\x12vector_type_config\"\x81\x01\x0A\x10DenseVectorField\x12\x12\x0A\x0Adimensions\x18\x01 \x01(\x05\x12Y\x0A\x17vertex_embedding_config\x18\x03 \x01(\x0B23.google.cloud.vectorsearch.v1.VertexEmbeddingConfigB\x03\xE0A\x01\"\x13\x0A\x11SparseVectorField\"\xB5\x01\x0A\x16ListCollectionsRequest\x12>\x0A\x06parent\x18\x01 \x01(\x09B.\xE0A\x02\xFAA(\x12&vectorsearch.googleapis.com/Collection\x12\x16\x0A\x09page_size\x18\x02 \x01(\x05B\x03\xE0A\x01\x12\x17\x0A\x0Apage_token\x18\x03 \x01(\x09B\x03\xE0A\x01\x12\x13\x0A\x06filter\x18\x04 \x01(\x09B\x03\xE0A\x01\x12\x15\x0A\x08order_by\x18\x05 \x01(\x09B\x03\xE0A\x01\"\x8B\x01\x0A\x17ListCollectionsResponse\x12=\x0A\x0Bcollections\x18\x01 \x03(\x0B2(.google.cloud.vectorsearch.v1.Collection\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\x12\x18\x0A\x0Bunreachable\x18\x03 \x03(\x09B\x03\xE0A\x06\"T\x0A\x14GetCollectionRequest\x12<\x0A\x04name\x18\x01 \x01(\x09B.\xE0A\x02\xFAA(\x0A&vectorsearch.googleapis.com/Collection\"\xD9\x01\x0A\x17CreateCollectionRequest\x12>\x0A\x06parent\x18\x01 \x01(\x09B.\xE0A\x02\xFAA(\x12&vectorsearch.googleapis.com/Collection\x12\x1A\x0A\x0Dcollection_id\x18\x02 \x01(\x09B\x03\xE0A\x02\x12A\x0A\x0Acollection\x18\x03 \x01(\x0B2(.google.cloud.vectorsearch.v1.CollectionB\x03\xE0A\x02\x12\x1F\x0A\x0Arequest_id\x18\x04 \x01(\x09B\x0B\xE0A\x01\xE2\x8C\xCF\xD7\x08\x02\x08\x01\"\xB3\x01\x0A\x17UpdateCollectionRequest\x124\x0A\x0Bupdate_mask\x18\x01 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x01\x12A\x0A\x0Acollection\x18\x02 \x01(\x0B2(.google.cloud.vectorsearch.v1.CollectionB\x03\xE0A\x02\x12\x1F\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x0B\xE0A\x01\xE2\x8C\xCF\xD7\x08\x02\x08\x01\"x\x0A\x17DeleteCollectionRequest\x12<\x0A\x04name\x18\x01 \x01(\x09B.\xE0A\x02\xFAA(\x0A&vectorsearch.googleapis.com/Collection\x12\x1F\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x0B\xE0A\x01\xE2\x8C\xCF\xD7\x08\x02\x08\x01\"\xA0\x06\x0A\x05Index\x12^\x0A\x18dedicated_infrastructure\x18\x0B \x01(\x0B25.google.cloud.vectorsearch.v1.DedicatedInfrastructureB\x03\xE0A\x01H\x00\x12I\x0A\x0Bdense_scann\x18\x0C \x01(\x0B2-.google.cloud.vectorsearch.v1.DenseScannIndexB\x03\xE0A\x01H\x01\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x08\x12\x19\x0A\x0Cdisplay_name\x18\x08 \x01(\x09B\x03\xE0A\x01\x12\x18\x0A\x0Bdescription\x18\x09 \x01(\x09B\x03\xE0A\x01\x12D\x0A\x06labels\x18\x0A \x03(\x0B2/.google.cloud.vectorsearch.v1.Index.LabelsEntryB\x03\xE0A\x01\x124\x0A\x0Bcreate_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x03 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12J\x0A\x0Fdistance_metric\x18\x04 \x01(\x0E2,.google.cloud.vectorsearch.v1.DistanceMetricB\x03\xE0A\x01\x12\x18\x0A\x0Bindex_field\x18\x05 \x01(\x09B\x03\xE0A\x02\x12\x1A\x0A\x0Dfilter_fields\x18\x06 \x03(\x09B\x03\xE0A\x01\x12\x19\x0A\x0Cstore_fields\x18\x07 \x03(\x09B\x03\xE0A\x01\x1A-\x0A\x0BLabelsEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12\x0D\x0A\x05value\x18\x02 \x01(\x09:\x028\x01:\x89\x01\xEAA\x85\x01\x0A!vectorsearch.googleapis.com/Index\x12Pprojects/{project}/locations/{location}/collections/{collection}/indexes/{index}*\x07indexes2\x05indexB\x0C\x0A\x0Ainfra_typeB\x0C\x0A\x0Aindex_type\"\xC5\x01\x0A\x12CreateIndexRequest\x12>\x0A\x06parent\x18\x01 \x01(\x09B.\xE0A\x02\xFAA(\x0A&vectorsearch.googleapis.com/Collection\x12\x15\x0A\x08index_id\x18\x02 \x01(\x09B\x03\xE0A\x02\x127\x0A\x05index\x18\x03 \x01(\x0B2#.google.cloud.vectorsearch.v1.IndexB\x03\xE0A\x02\x12\x1F\x0A\x0Arequest_id\x18\x04 \x01(\x09B\x0B\xE0A\x01\xE2\x8C\xCF\xD7\x08\x02\x08\x01\"\xA4\x01\x0A\x12UpdateIndexRequest\x127\x0A\x05index\x18\x01 \x01(\x0B2#.google.cloud.vectorsearch.v1.IndexB\x03\xE0A\x02\x124\x0A\x0Bupdate_mask\x18\x02 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x01\x12\x1F\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x0B\xE0A\x01\xE2\x8C\xCF\xD7\x08\x02\x08\x01\"n\x0A\x12DeleteIndexRequest\x127\x0A\x04name\x18\x01 \x01(\x09B)\xE0A\x02\xFAA#\x0A!vectorsearch.googleapis.com/Index\x12\x1F\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x0B\xE0A\x01\xE2\x8C\xCF\xD7\x08\x02\x08\x01\"\xAC\x01\x0A\x12ListIndexesRequest\x129\x0A\x06parent\x18\x01 \x01(\x09B)\xE0A\x02\xFAA#\x12!vectorsearch.googleapis.com/Index\x12\x16\x0A\x09page_size\x18\x02 \x01(\x05B\x03\xE0A\x01\x12\x17\x0A\x0Apage_token\x18\x03 \x01(\x09B\x03\xE0A\x01\x12\x13\x0A\x06filter\x18\x04 \x01(\x09B\x03\xE0A\x01\x12\x15\x0A\x08order_by\x18\x05 \x01(\x09B\x03\xE0A\x01\"d\x0A\x13ListIndexesResponse\x124\x0A\x07indexes\x18\x01 \x03(\x0B2#.google.cloud.vectorsearch.v1.Index\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\"J\x0A\x0FGetIndexRequest\x127\x0A\x04name\x18\x01 \x01(\x09B)\xE0A\x02\xFAA#\x0A!vectorsearch.googleapis.com/Index\"\x80\x02\x0A\x11OperationMetadata\x124\x0A\x0Bcreate_time\x18\x01 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x121\x0A\x08end_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12\x13\x0A\x06target\x18\x03 \x01(\x09B\x03\xE0A\x03\x12\x11\x0A\x04verb\x18\x04 \x01(\x09B\x03\xE0A\x03\x12\x1B\x0A\x0Estatus_message\x18\x05 \x01(\x09B\x03\xE0A\x03\x12#\x0A\x16requested_cancellation\x18\x06 \x01(\x08B\x03\xE0A\x03\x12\x18\x0A\x0Bapi_version\x18\x07 \x01(\x09B\x03\xE0A\x03\"\x9F\x02\x0A\x18ImportDataObjectsRequest\x12\\\x0A\x0Agcs_import\x18\x02 \x01(\x0B2F.google.cloud.vectorsearch.v1.ImportDataObjectsRequest.GcsImportConfigH\x00\x12<\x0A\x04name\x18\x01 \x01(\x09B.\xE0A\x02\xFAA(\x0A&vectorsearch.googleapis.com/Collection\x1A]\x0A\x0FGcsImportConfig\x12\x19\x0A\x0Ccontents_uri\x18\x01 \x01(\x09B\x03\xE0A\x02\x12\x16\x0A\x09error_uri\x18\x02 \x01(\x09B\x03\xE0A\x02\x12\x17\x0A\x0Aoutput_uri\x18\x03 \x01(\x09B\x03\xE0A\x01B\x08\x0A\x06config\"\xBF\x01\x0A\x19ImportDataObjectsMetadata\x124\x0A\x0Bcreate_time\x18\x01 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12\x1A\x0A\x0Dsuccess_count\x18\x03 \x01(\x03B\x03\xE0A\x03\x12\x1A\x0A\x0Dfailure_count\x18\x04 \x01(\x03B\x03\xE0A\x03\"?\x0A\x19ImportDataObjectsResponse\x12\"\x0A\x06status\x18\x01 \x01(\x0B2\x12.google.rpc.Status\"\x97\x03\x0A\x18ExportDataObjectsRequest\x12f\x0A\x0Fgcs_destination\x18\x02 \x01(\x0B2K.google.cloud.vectorsearch.v1.ExportDataObjectsRequest.GcsExportDestinationH\x00\x12<\x0A\x04name\x18\x01 \x01(\x09B.\xE0A\x02\xFAA(\x0A&vectorsearch.googleapis.com/Collection\x1A\xC5\x01\x0A\x14GcsExportDestination\x12\x17\x0A\x0Aexport_uri\x18\x01 \x01(\x09B\x03\xE0A\x02\x12g\x0A\x06format\x18\x02 \x01(\x0E2R.google.cloud.vectorsearch.v1.ExportDataObjectsRequest.GcsExportDestination.FormatB\x03\xE0A\x02\"+\x0A\x06Format\x12\x16\x0A\x12FORMAT_UNSPECIFIED\x10\x00\x12\x09\x0A\x05JSONL\x10\x02B\x0D\x0A\x0Bdestination\"\x87\x01\x0A\x19ExportDataObjectsMetadata\x124\x0A\x0Bcreate_time\x18\x01 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bfinish_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\"\x1B\x0A\x19ExportDataObjectsResponse\"\xFF\x02\x0A\x17DedicatedInfrastructure\x12R\x0A\x04mode\x18\x01 \x01(\x0E2:.google.cloud.vectorsearch.v1.DedicatedInfrastructure.ModeB\x03\xE0A\x01H\x00\x88\x01\x01\x12d\x0A\x10autoscaling_spec\x18\x02 \x01(\x0B2E.google.cloud.vectorsearch.v1.DedicatedInfrastructure.AutoscalingSpecB\x03\xE0A\x01\x1AQ\x0A\x0FAutoscalingSpec\x12\x1E\x0A\x11min_replica_count\x18\x01 \x01(\x05B\x03\xE0A\x01\x12\x1E\x0A\x11max_replica_count\x18\x02 \x01(\x05B\x03\xE0A\x01\"N\x0A\x04Mode\x12\x14\x0A\x10MODE_UNSPECIFIED\x10\x00\x12\x15\x0A\x11STORAGE_OPTIMIZED\x10\x01\x12\x19\x0A\x15PERFORMANCE_OPTIMIZED\x10\x02B\x07\x0A\x05_mode\"\xC2\x01\x0A\x0FDenseScannIndex\x12]\x0A\x11feature_norm_type\x18\x02 \x01(\x0E2=.google.cloud.vectorsearch.v1.DenseScannIndex.FeatureNormTypeB\x03\xE0A\x01\"P\x0A\x0FFeatureNormType\x12!\x0A\x1DFEATURE_NORM_TYPE_UNSPECIFIED\x10\x00\x12\x08\x0A\x04NONE\x10\x01\x12\x10\x0A\x0CUNIT_L2_NORM\x10\x022\x8D\x15\x0A\x13VectorSearchService\x12\xC0\x01\x0A\x0FListCollections\x124.google.cloud.vectorsearch.v1.ListCollectionsRequest\x1A5.google.cloud.vectorsearch.v1.ListCollectionsResponse\"@\xDAA\x06parent\x82\xD3\xE4\x93\x021\x12//v1/{parent=projects/*/locations/*}/collections\x12\xAD\x01\x0A\x0DGetCollection\x122.google.cloud.vectorsearch.v1.GetCollectionRequest\x1A(.google.cloud.vectorsearch.v1.Collection\">\xDAA\x04name\x82\xD3\xE4\x93\x021\x12//v1/{name=projects/*/locations/*/collections/*}\x12\xF2\x01\x0A\x10CreateCollection\x125.google.cloud.vectorsearch.v1.CreateCollectionRequest\x1A\x1D.google.longrunning.Operation\"\x87\x01\xCAA\x1F\x0A\x0ACollection\x12\x11OperationMetadata\xDAA\x1Fparent,collection,collection_id\x82\xD3\xE4\x93\x02=\"//v1/{parent=projects/*/locations/*}/collections:\x0Acollection\x12\xF4\x01\x0A\x10UpdateCollection\x125.google.cloud.vectorsearch.v1.UpdateCollectionRequest\x1A\x1D.google.longrunning.Operation\"\x89\x01\xCAA\x1F\x0A\x0ACollection\x12\x11OperationMetadata\xDAA\x16collection,update_mask\x82\xD3\xE4\x93\x02H2:/v1/{collection.name=projects/*/locations/*/collections/*}:\x0Acollection\x12\xD5\x01\x0A\x10DeleteCollection\x125.google.cloud.vectorsearch.v1.DeleteCollectionRequest\x1A\x1D.google.longrunning.Operation\"k\xCAA*\x0A\x15google.protobuf.Empty\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x021*//v1/{name=projects/*/locations/*/collections/*}\x12\xBE\x01\x0A\x0BListIndexes\x120.google.cloud.vectorsearch.v1.ListIndexesRequest\x1A1.google.cloud.vectorsearch.v1.ListIndexesResponse\"J\xDAA\x06parent\x82\xD3\xE4\x93\x02;\x129/v1/{parent=projects/*/locations/*/collections/*}/indexes\x12\xA8\x01\x0A\x08GetIndex\x12-.google.cloud.vectorsearch.v1.GetIndexRequest\x1A#.google.cloud.vectorsearch.v1.Index\"H\xDAA\x04name\x82\xD3\xE4\x93\x02;\x129/v1/{name=projects/*/locations/*/collections/*/indexes/*}\x12\xDD\x01\x0A\x0BCreateIndex\x120.google.cloud.vectorsearch.v1.CreateIndexRequest\x1A\x1D.google.longrunning.Operation\"}\xCAA\x1A\x0A\x05Index\x12\x11OperationMetadata\xDAA\x15parent,index,index_id\x82\xD3\xE4\x93\x02B\"9/v1/{parent=projects/*/locations/*/collections/*}/indexes:\x05index\x12\xDF\x01\x0A\x0BUpdateIndex\x120.google.cloud.vectorsearch.v1.UpdateIndexRequest\x1A\x1D.google.longrunning.Operation\"\x7F\xCAA\x1A\x0A\x05Index\x12\x11OperationMetadata\xDAA\x11index,update_mask\x82\xD3\xE4\x93\x02H2?/v1/{index.name=projects/*/locations/*/collections/*/indexes/*}:\x05index\x12\xD5\x01\x0A\x0BDeleteIndex\x120.google.cloud.vectorsearch.v1.DeleteIndexRequest\x1A\x1D.google.longrunning.Operation\"u\xCAA*\x0A\x15google.protobuf.Empty\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x02;*9/v1/{name=projects/*/locations/*/collections/*/indexes/*}\x12\xF2\x01\x0A\x11ImportDataObjects\x126.google.cloud.vectorsearch.v1.ImportDataObjectsRequest\x1A\x1D.google.longrunning.Operation\"\x85\x01\xCAA6\x0A\x19ImportDataObjectsResponse\x12\x19ImportDataObjectsMetadata\x82\xD3\xE4\x93\x02F\"A/v1/{name=projects/*/locations/*/collections/*}:importDataObjects:\x01*\x12\xF2\x01\x0A\x11ExportDataObjects\x126.google.cloud.vectorsearch.v1.ExportDataObjectsRequest\x1A\x1D.google.longrunning.Operation\"\x85\x01\xCAA6\x0A\x19ExportDataObjectsResponse\x12\x19ExportDataObjectsMetadata\x82\xD3\xE4\x93\x02F\"A/v1/{name=projects/*/locations/*/collections/*}:exportDataObjects:\x01*\x1AO\xCAA\x1Bvectorsearch.googleapis.com\xD2A.https://www.googleapis.com/auth/cloud-platformB\xE4\x01\x0A com.google.cloud.vectorsearch.v1B\x18VectorSearchServiceProtoP\x01ZDcloud.google.com/go/vectorsearch/apiv1/vectorsearchpb;vectorsearchpb\xAA\x02\x1CGoogle.Cloud.VectorSearch.V1\xCA\x02\x1CGoogle\\Cloud\\VectorSearch\\V1\xEA\x02\x1FGoogle::Cloud::VectorSearch::V1b\x06proto3" + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/AggregateDataObjectsRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/AggregateDataObjectsRequest.php new file mode 100644 index 000000000000..d5b23e5eed71 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/AggregateDataObjectsRequest.php @@ -0,0 +1,154 @@ +google.cloud.vectorsearch.v1.AggregateDataObjectsRequest + */ +class AggregateDataObjectsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the Collection for which to query. + * Format: `projects/{project}/locations/{location}/collections/{collection}` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Optional. A JSON filter expression, e.g. {"genre": {"$eq": "sci-fi"}}, + * represented as a google.protobuf.Struct. + * + * Generated from protobuf field .google.protobuf.Struct filter = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $filter = null; + /** + * Required. The aggregation method to apply to the query. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.AggregationMethod aggregate = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $aggregate = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. The resource name of the Collection for which to query. + * Format: `projects/{project}/locations/{location}/collections/{collection}` + * @type \Google\Protobuf\Struct $filter + * Optional. A JSON filter expression, e.g. {"genre": {"$eq": "sci-fi"}}, + * represented as a google.protobuf.Struct. + * @type int $aggregate + * Required. The aggregation method to apply to the query. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectSearchService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the Collection for which to query. + * Format: `projects/{project}/locations/{location}/collections/{collection}` + * + * 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 Collection for which to query. + * Format: `projects/{project}/locations/{location}/collections/{collection}` + * + * 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. A JSON filter expression, e.g. {"genre": {"$eq": "sci-fi"}}, + * represented as a google.protobuf.Struct. + * + * Generated from protobuf field .google.protobuf.Struct filter = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Protobuf\Struct|null + */ + public function getFilter() + { + return $this->filter; + } + + public function hasFilter() + { + return isset($this->filter); + } + + public function clearFilter() + { + unset($this->filter); + } + + /** + * Optional. A JSON filter expression, e.g. {"genre": {"$eq": "sci-fi"}}, + * represented as a google.protobuf.Struct. + * + * Generated from protobuf field .google.protobuf.Struct filter = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Protobuf\Struct $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Struct::class); + $this->filter = $var; + + return $this; + } + + /** + * Required. The aggregation method to apply to the query. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.AggregationMethod aggregate = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return int + */ + public function getAggregate() + { + return $this->aggregate; + } + + /** + * Required. The aggregation method to apply to the query. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.AggregationMethod aggregate = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param int $var + * @return $this + */ + public function setAggregate($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\VectorSearch\V1\AggregationMethod::class); + $this->aggregate = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/AggregateDataObjectsResponse.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/AggregateDataObjectsResponse.php new file mode 100644 index 000000000000..8ea65dd63840 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/AggregateDataObjectsResponse.php @@ -0,0 +1,68 @@ +google.cloud.vectorsearch.v1.AggregateDataObjectsResponse + */ +class AggregateDataObjectsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. The aggregated results of the query. + * + * Generated from protobuf field repeated .google.protobuf.Struct aggregate_results = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + private $aggregate_results; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Protobuf\Struct[] $aggregate_results + * Output only. The aggregated results of the query. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectSearchService::initOnce(); + parent::__construct($data); + } + + /** + * Output only. The aggregated results of the query. + * + * Generated from protobuf field repeated .google.protobuf.Struct aggregate_results = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return RepeatedField<\Google\Protobuf\Struct> + */ + public function getAggregateResults() + { + return $this->aggregate_results; + } + + /** + * Output only. The aggregated results of the query. + * + * Generated from protobuf field repeated .google.protobuf.Struct aggregate_results = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Protobuf\Struct[] $var + * @return $this + */ + public function setAggregateResults($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Struct::class); + $this->aggregate_results = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/AggregationMethod.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/AggregationMethod.php new file mode 100644 index 000000000000..fed256de20ce --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/AggregationMethod.php @@ -0,0 +1,54 @@ +google.cloud.vectorsearch.v1.AggregationMethod + */ +class AggregationMethod +{ + /** + * Should not be used. + * + * Generated from protobuf enum AGGREGATION_METHOD_UNSPECIFIED = 0; + */ + const AGGREGATION_METHOD_UNSPECIFIED = 0; + /** + * Count the number of data objects that match the filter. + * + * Generated from protobuf enum COUNT = 1; + */ + const COUNT = 1; + + private static $valueToName = [ + self::AGGREGATION_METHOD_UNSPECIFIED => 'AGGREGATION_METHOD_UNSPECIFIED', + self::COUNT => 'COUNT', + ]; + + 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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchCreateDataObjectsRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchCreateDataObjectsRequest.php new file mode 100644 index 000000000000..7312e88d14d3 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchCreateDataObjectsRequest.php @@ -0,0 +1,118 @@ +google.cloud.vectorsearch.v1.BatchCreateDataObjectsRequest + */ +class BatchCreateDataObjectsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the Collection to create the DataObjects in. + * Format: `projects/{project}/locations/{location}/collections/{collection}`. + * The parent field in the CreateDataObjectRequest messages must match this + * field. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. The request message specifying the resources to create. + * A maximum of 1000 DataObjects can be created in a batch. + * + * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.CreateDataObjectRequest requests = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + private $requests; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. The resource name of the Collection to create the DataObjects in. + * Format: `projects/{project}/locations/{location}/collections/{collection}`. + * The parent field in the CreateDataObjectRequest messages must match this + * field. + * @type \Google\Cloud\VectorSearch\V1\CreateDataObjectRequest[] $requests + * Required. The request message specifying the resources to create. + * A maximum of 1000 DataObjects can be created in a batch. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the Collection to create the DataObjects in. + * Format: `projects/{project}/locations/{location}/collections/{collection}`. + * The parent field in the CreateDataObjectRequest messages must 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 resource name of the Collection to create the DataObjects in. + * Format: `projects/{project}/locations/{location}/collections/{collection}`. + * The parent field in the CreateDataObjectRequest messages must 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 message specifying the resources to create. + * A maximum of 1000 DataObjects can be created in a batch. + * + * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.CreateDataObjectRequest requests = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return RepeatedField<\Google\Cloud\VectorSearch\V1\CreateDataObjectRequest> + */ + public function getRequests() + { + return $this->requests; + } + + /** + * Required. The request message specifying the resources to create. + * A maximum of 1000 DataObjects can be created in a batch. + * + * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.CreateDataObjectRequest requests = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\VectorSearch\V1\CreateDataObjectRequest[] $var + * @return $this + */ + public function setRequests($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VectorSearch\V1\CreateDataObjectRequest::class); + $this->requests = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchCreateDataObjectsResponse.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchCreateDataObjectsResponse.php new file mode 100644 index 000000000000..724830369569 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchCreateDataObjectsResponse.php @@ -0,0 +1,68 @@ +google.cloud.vectorsearch.v1.BatchCreateDataObjectsResponse + */ +class BatchCreateDataObjectsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. DataObjects created. + * + * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.DataObject data_objects = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + private $data_objects; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\VectorSearch\V1\DataObject[] $data_objects + * Output only. DataObjects created. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectService::initOnce(); + parent::__construct($data); + } + + /** + * Output only. DataObjects created. + * + * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.DataObject data_objects = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return RepeatedField<\Google\Cloud\VectorSearch\V1\DataObject> + */ + public function getDataObjects() + { + return $this->data_objects; + } + + /** + * Output only. DataObjects created. + * + * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.DataObject data_objects = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Cloud\VectorSearch\V1\DataObject[] $var + * @return $this + */ + public function setDataObjects($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VectorSearch\V1\DataObject::class); + $this->data_objects = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchDeleteDataObjectsRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchDeleteDataObjectsRequest.php new file mode 100644 index 000000000000..0288323d7c76 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchDeleteDataObjectsRequest.php @@ -0,0 +1,128 @@ +google.cloud.vectorsearch.v1.BatchDeleteDataObjectsRequest + */ +class BatchDeleteDataObjectsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the Collection to delete the DataObjects in. + * Format: `projects/{project}/locations/{location}/collections/{collection}`. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. The request message specifying the resources to delete. + * A maximum of 1000 DataObjects can be deleted in a batch. + * + * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.DeleteDataObjectRequest requests = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + private $requests; + + /** + * @param string $parent Required. The resource name of the Collection to delete the DataObjects in. + * Format: `projects/{project}/locations/{location}/collections/{collection}`. Please see + * {@see DataObjectServiceClient::collectionName()} for help formatting this field. + * @param \Google\Cloud\VectorSearch\V1\DeleteDataObjectRequest[] $requests Required. The request message specifying the resources to delete. + * A maximum of 1000 DataObjects can be deleted in a batch. + * + * @return \Google\Cloud\VectorSearch\V1\BatchDeleteDataObjectsRequest + * + * @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 resource name of the Collection to delete the DataObjects in. + * Format: `projects/{project}/locations/{location}/collections/{collection}`. + * @type \Google\Cloud\VectorSearch\V1\DeleteDataObjectRequest[] $requests + * Required. The request message specifying the resources to delete. + * A maximum of 1000 DataObjects can be deleted in a batch. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the Collection to delete the DataObjects in. + * Format: `projects/{project}/locations/{location}/collections/{collection}`. + * + * 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 Collection to delete the DataObjects in. + * Format: `projects/{project}/locations/{location}/collections/{collection}`. + * + * 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 message specifying the resources to delete. + * A maximum of 1000 DataObjects can be deleted in a batch. + * + * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.DeleteDataObjectRequest requests = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return RepeatedField<\Google\Cloud\VectorSearch\V1\DeleteDataObjectRequest> + */ + public function getRequests() + { + return $this->requests; + } + + /** + * Required. The request message specifying the resources to delete. + * A maximum of 1000 DataObjects can be deleted in a batch. + * + * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.DeleteDataObjectRequest requests = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\VectorSearch\V1\DeleteDataObjectRequest[] $var + * @return $this + */ + public function setRequests($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VectorSearch\V1\DeleteDataObjectRequest::class); + $this->requests = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchSearchDataObjectsRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchSearchDataObjectsRequest.php new file mode 100644 index 000000000000..e0a0b9bef1c4 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchSearchDataObjectsRequest.php @@ -0,0 +1,149 @@ +google.cloud.vectorsearch.v1.BatchSearchDataObjectsRequest + */ +class BatchSearchDataObjectsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the Collection for which to search. + * Format: `projects/{project}/locations/{location}/collections/{collection}` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. A list of search requests to execute in parallel. + * + * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.Search searches = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + private $searches; + /** + * Optional. Options for combining the results of the batch search operations. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.BatchSearchDataObjectsRequest.CombineResultsOptions combine = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $combine = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. The resource name of the Collection for which to search. + * Format: `projects/{project}/locations/{location}/collections/{collection}` + * @type \Google\Cloud\VectorSearch\V1\Search[] $searches + * Required. A list of search requests to execute in parallel. + * @type \Google\Cloud\VectorSearch\V1\BatchSearchDataObjectsRequest\CombineResultsOptions $combine + * Optional. Options for combining the results of the batch search operations. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectSearchService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the Collection for which to search. + * Format: `projects/{project}/locations/{location}/collections/{collection}` + * + * 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 Collection for which to search. + * Format: `projects/{project}/locations/{location}/collections/{collection}` + * + * 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 list of search requests to execute in parallel. + * + * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.Search searches = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return RepeatedField<\Google\Cloud\VectorSearch\V1\Search> + */ + public function getSearches() + { + return $this->searches; + } + + /** + * Required. A list of search requests to execute in parallel. + * + * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.Search searches = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\VectorSearch\V1\Search[] $var + * @return $this + */ + public function setSearches($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VectorSearch\V1\Search::class); + $this->searches = $arr; + + return $this; + } + + /** + * Optional. Options for combining the results of the batch search operations. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.BatchSearchDataObjectsRequest.CombineResultsOptions combine = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\VectorSearch\V1\BatchSearchDataObjectsRequest\CombineResultsOptions|null + */ + public function getCombine() + { + return $this->combine; + } + + public function hasCombine() + { + return isset($this->combine); + } + + public function clearCombine() + { + unset($this->combine); + } + + /** + * Optional. Options for combining the results of the batch search operations. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.BatchSearchDataObjectsRequest.CombineResultsOptions combine = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\VectorSearch\V1\BatchSearchDataObjectsRequest\CombineResultsOptions $var + * @return $this + */ + public function setCombine($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\BatchSearchDataObjectsRequest\CombineResultsOptions::class); + $this->combine = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchSearchDataObjectsRequest/CombineResultsOptions.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchSearchDataObjectsRequest/CombineResultsOptions.php new file mode 100644 index 000000000000..35714245de22 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchSearchDataObjectsRequest/CombineResultsOptions.php @@ -0,0 +1,159 @@ +google.cloud.vectorsearch.v1.BatchSearchDataObjectsRequest.CombineResultsOptions + */ +class CombineResultsOptions extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The ranker to use for combining the results. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.Ranker ranker = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $ranker = null; + /** + * Optional. Mask specifying which fields to return. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.OutputFields output_fields = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $output_fields = null; + /** + * Optional. The number of results to return. If not set, a default value + * will be used. + * + * Generated from protobuf field int32 top_k = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $top_k = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\VectorSearch\V1\Ranker $ranker + * Required. The ranker to use for combining the results. + * @type \Google\Cloud\VectorSearch\V1\OutputFields $output_fields + * Optional. Mask specifying which fields to return. + * @type int $top_k + * Optional. The number of results to return. If not set, a default value + * will be used. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectSearchService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The ranker to use for combining the results. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.Ranker ranker = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\VectorSearch\V1\Ranker|null + */ + public function getRanker() + { + return $this->ranker; + } + + public function hasRanker() + { + return isset($this->ranker); + } + + public function clearRanker() + { + unset($this->ranker); + } + + /** + * Required. The ranker to use for combining the results. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.Ranker ranker = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\VectorSearch\V1\Ranker $var + * @return $this + */ + public function setRanker($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\Ranker::class); + $this->ranker = $var; + + return $this; + } + + /** + * Optional. Mask specifying which fields to return. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.OutputFields output_fields = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\VectorSearch\V1\OutputFields|null + */ + public function getOutputFields() + { + return $this->output_fields; + } + + public function hasOutputFields() + { + return isset($this->output_fields); + } + + public function clearOutputFields() + { + unset($this->output_fields); + } + + /** + * Optional. Mask specifying which fields to return. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.OutputFields output_fields = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\VectorSearch\V1\OutputFields $var + * @return $this + */ + public function setOutputFields($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\OutputFields::class); + $this->output_fields = $var; + + return $this; + } + + /** + * Optional. The number of results to return. If not set, a default value + * will be used. + * + * Generated from protobuf field int32 top_k = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return int + */ + public function getTopK() + { + return $this->top_k; + } + + /** + * Optional. The number of results to return. If not set, a default value + * will be used. + * + * Generated from protobuf field int32 top_k = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @param int $var + * @return $this + */ + public function setTopK($var) + { + GPBUtil::checkInt32($var); + $this->top_k = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchSearchDataObjectsResponse.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchSearchDataObjectsResponse.php new file mode 100644 index 000000000000..d872d51f5956 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchSearchDataObjectsResponse.php @@ -0,0 +1,71 @@ +google.cloud.vectorsearch.v1.BatchSearchDataObjectsResponse + */ +class BatchSearchDataObjectsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. A list of search responses, one for each request in the batch. + * If a ranker is used, a single ranked list of results is returned. + * + * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.SearchDataObjectsResponse results = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + private $results; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\VectorSearch\V1\SearchDataObjectsResponse[] $results + * Output only. A list of search responses, one for each request in the batch. + * If a ranker is used, a single ranked list of results is returned. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectSearchService::initOnce(); + parent::__construct($data); + } + + /** + * Output only. A list of search responses, one for each request in the batch. + * If a ranker is used, a single ranked list of results is returned. + * + * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.SearchDataObjectsResponse results = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return RepeatedField<\Google\Cloud\VectorSearch\V1\SearchDataObjectsResponse> + */ + public function getResults() + { + return $this->results; + } + + /** + * Output only. A list of search responses, one for each request in the batch. + * If a ranker is used, a single ranked list of results is returned. + * + * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.SearchDataObjectsResponse results = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Cloud\VectorSearch\V1\SearchDataObjectsResponse[] $var + * @return $this + */ + public function setResults($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VectorSearch\V1\SearchDataObjectsResponse::class); + $this->results = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchUpdateDataObjectsRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchUpdateDataObjectsRequest.php new file mode 100644 index 000000000000..b2d8e7c61cea --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchUpdateDataObjectsRequest.php @@ -0,0 +1,138 @@ +google.cloud.vectorsearch.v1.BatchUpdateDataObjectsRequest + */ +class BatchUpdateDataObjectsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the Collection to update the DataObjects in. + * Format: `projects/{project}/locations/{location}/collections/{collection}`. + * The parent field in the UpdateDataObjectRequest messages must match this + * field. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. The request message specifying the resources to update. + * A maximum of 1000 DataObjects can be updated in a batch. + * + * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.UpdateDataObjectRequest requests = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + private $requests; + + /** + * @param string $parent Required. The resource name of the Collection to update the DataObjects in. + * Format: `projects/{project}/locations/{location}/collections/{collection}`. + * The parent field in the UpdateDataObjectRequest messages must match this + * field. Please see + * {@see DataObjectServiceClient::collectionName()} for help formatting this field. + * @param \Google\Cloud\VectorSearch\V1\UpdateDataObjectRequest[] $requests Required. The request message specifying the resources to update. + * A maximum of 1000 DataObjects can be updated in a batch. + * + * @return \Google\Cloud\VectorSearch\V1\BatchUpdateDataObjectsRequest + * + * @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 resource name of the Collection to update the DataObjects in. + * Format: `projects/{project}/locations/{location}/collections/{collection}`. + * The parent field in the UpdateDataObjectRequest messages must match this + * field. + * @type \Google\Cloud\VectorSearch\V1\UpdateDataObjectRequest[] $requests + * Required. The request message specifying the resources to update. + * A maximum of 1000 DataObjects can be updated in a batch. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the Collection to update the DataObjects in. + * Format: `projects/{project}/locations/{location}/collections/{collection}`. + * The parent field in the UpdateDataObjectRequest messages must 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 resource name of the Collection to update the DataObjects in. + * Format: `projects/{project}/locations/{location}/collections/{collection}`. + * The parent field in the UpdateDataObjectRequest messages must 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 message specifying the resources to update. + * A maximum of 1000 DataObjects can be updated in a batch. + * + * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.UpdateDataObjectRequest requests = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return RepeatedField<\Google\Cloud\VectorSearch\V1\UpdateDataObjectRequest> + */ + public function getRequests() + { + return $this->requests; + } + + /** + * Required. The request message specifying the resources to update. + * A maximum of 1000 DataObjects can be updated in a batch. + * + * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.UpdateDataObjectRequest requests = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\VectorSearch\V1\UpdateDataObjectRequest[] $var + * @return $this + */ + public function setRequests($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VectorSearch\V1\UpdateDataObjectRequest::class); + $this->requests = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchUpdateDataObjectsResponse.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchUpdateDataObjectsResponse.php new file mode 100644 index 000000000000..dba807289c3b --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchUpdateDataObjectsResponse.php @@ -0,0 +1,34 @@ +google.cloud.vectorsearch.v1.BatchUpdateDataObjectsResponse + */ +class BatchUpdateDataObjectsResponse extends \Google\Protobuf\Internal\Message +{ + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectService::initOnce(); + parent::__construct($data); + } + +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/Collection.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/Collection.php new file mode 100644 index 000000000000..da1eeca2f43f --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/Collection.php @@ -0,0 +1,411 @@ +google.cloud.vectorsearch.v1.Collection + */ +class Collection extends \Google\Protobuf\Internal\Message +{ + /** + * Identifier. name of resource + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + */ + protected $name = ''; + /** + * Optional. User-specified display name of the collection + * + * Generated from protobuf field string display_name = 8 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $display_name = ''; + /** + * Optional. User-specified description of the collection + * + * Generated from protobuf field string description = 9 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $description = ''; + /** + * 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. Labels as key value pairs. + * + * Generated from protobuf field map labels = 4 [(.google.api.field_behavior) = OPTIONAL]; + */ + private $labels; + /** + * Optional. Schema for vector fields. Only vector fields in this schema will + * be searchable. Field names must contain only alphanumeric characters, + * underscores, and hyphens. + * + * Generated from protobuf field map vector_schema = 7 [(.google.api.field_behavior) = OPTIONAL]; + */ + private $vector_schema; + /** + * Optional. JSON Schema for data. + * Field names must contain only alphanumeric characters, + * underscores, and hyphens. + * The schema must be compliant with + * [JSON Schema Draft 7](https://json-schema.org/draft-07/schema). + * + * Generated from protobuf field .google.protobuf.Struct data_schema = 10 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $data_schema = null; + /** + * Optional. Immutable. Specifies the customer-managed encryption key spec for + * a Collection. If set, this Collection and all sub-resources of this + * Collection will be secured by this key. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.EncryptionSpec encryption_spec = 11 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + */ + protected $encryption_spec = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Identifier. name of resource + * @type string $display_name + * Optional. User-specified display name of the collection + * @type string $description + * Optional. User-specified description of the collection + * @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 array|\Google\Protobuf\Internal\MapField $labels + * Optional. Labels as key value pairs. + * @type array|\Google\Protobuf\Internal\MapField $vector_schema + * Optional. Schema for vector fields. Only vector fields in this schema will + * be searchable. Field names must contain only alphanumeric characters, + * underscores, and hyphens. + * @type \Google\Protobuf\Struct $data_schema + * Optional. JSON Schema for data. + * Field names must contain only alphanumeric characters, + * underscores, and hyphens. + * The schema must be compliant with + * [JSON Schema Draft 7](https://json-schema.org/draft-07/schema). + * @type \Google\Cloud\VectorSearch\V1\EncryptionSpec $encryption_spec + * Optional. Immutable. Specifies the customer-managed encryption key spec for + * a Collection. If set, this Collection and all sub-resources of this + * Collection will be secured by this key. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\VectorsearchService::initOnce(); + parent::__construct($data); + } + + /** + * Identifier. name of resource + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Identifier. name of resource + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Optional. User-specified display name of the collection + * + * Generated from protobuf field string display_name = 8 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getDisplayName() + { + return $this->display_name; + } + + /** + * Optional. User-specified display name of the collection + * + * Generated from protobuf field string display_name = 8 [(.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. User-specified description of the collection + * + * Generated from protobuf field string description = 9 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * Optional. User-specified description of the collection + * + * Generated from protobuf field string description = 9 [(.google.api.field_behavior) = OPTIONAL]; + * @param string $var + * @return $this + */ + public function setDescription($var) + { + GPBUtil::checkString($var, True); + $this->description = $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. Labels as key value pairs. + * + * Generated from protobuf field map labels = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Protobuf\Internal\MapField + */ + public function getLabels() + { + return $this->labels; + } + + /** + * Optional. Labels as key value pairs. + * + * 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. Schema for vector fields. Only vector fields in this schema will + * be searchable. Field names must contain only alphanumeric characters, + * underscores, and hyphens. + * + * Generated from protobuf field map vector_schema = 7 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Protobuf\Internal\MapField + */ + public function getVectorSchema() + { + return $this->vector_schema; + } + + /** + * Optional. Schema for vector fields. Only vector fields in this schema will + * be searchable. Field names must contain only alphanumeric characters, + * underscores, and hyphens. + * + * Generated from protobuf field map vector_schema = 7 [(.google.api.field_behavior) = OPTIONAL]; + * @param array|\Google\Protobuf\Internal\MapField $var + * @return $this + */ + public function setVectorSchema($var) + { + $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VectorSearch\V1\VectorField::class); + $this->vector_schema = $arr; + + return $this; + } + + /** + * Optional. JSON Schema for data. + * Field names must contain only alphanumeric characters, + * underscores, and hyphens. + * The schema must be compliant with + * [JSON Schema Draft 7](https://json-schema.org/draft-07/schema). + * + * Generated from protobuf field .google.protobuf.Struct data_schema = 10 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Protobuf\Struct|null + */ + public function getDataSchema() + { + return $this->data_schema; + } + + public function hasDataSchema() + { + return isset($this->data_schema); + } + + public function clearDataSchema() + { + unset($this->data_schema); + } + + /** + * Optional. JSON Schema for data. + * Field names must contain only alphanumeric characters, + * underscores, and hyphens. + * The schema must be compliant with + * [JSON Schema Draft 7](https://json-schema.org/draft-07/schema). + * + * Generated from protobuf field .google.protobuf.Struct data_schema = 10 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Protobuf\Struct $var + * @return $this + */ + public function setDataSchema($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Struct::class); + $this->data_schema = $var; + + return $this; + } + + /** + * Optional. Immutable. Specifies the customer-managed encryption key spec for + * a Collection. If set, this Collection and all sub-resources of this + * Collection will be secured by this key. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.EncryptionSpec encryption_spec = 11 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\VectorSearch\V1\EncryptionSpec|null + */ + public function getEncryptionSpec() + { + return $this->encryption_spec; + } + + public function hasEncryptionSpec() + { + return isset($this->encryption_spec); + } + + public function clearEncryptionSpec() + { + unset($this->encryption_spec); + } + + /** + * Optional. Immutable. Specifies the customer-managed encryption key spec for + * a Collection. If set, this Collection and all sub-resources of this + * Collection will be secured by this key. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.EncryptionSpec encryption_spec = 11 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\VectorSearch\V1\EncryptionSpec $var + * @return $this + */ + public function setEncryptionSpec($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\EncryptionSpec::class); + $this->encryption_spec = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/CreateCollectionRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/CreateCollectionRequest.php new file mode 100644 index 000000000000..ad98dfd9a292 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/CreateCollectionRequest.php @@ -0,0 +1,257 @@ +google.cloud.vectorsearch.v1.CreateCollectionRequest + */ +class CreateCollectionRequest 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 = ''; + /** + * Required. ID of the Collection to create. + * The id must be 1-63 characters long, and comply with + * [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). + * Specifically, it must be 1-63 characters long and match the regular + * expression `[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?`. + * + * Generated from protobuf field string collection_id = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $collection_id = ''; + /** + * Required. The resource being created + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.Collection collection = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $collection = 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, (.google.api.field_info) = { + */ + protected $request_id = ''; + + /** + * @param string $parent Required. Value for parent. Please see + * {@see VectorSearchServiceClient::locationName()} for help formatting this field. + * @param \Google\Cloud\VectorSearch\V1\Collection $collection Required. The resource being created + * @param string $collectionId Required. ID of the Collection to create. + * The id must be 1-63 characters long, and comply with + * [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). + * Specifically, it must be 1-63 characters long and match the regular + * expression `[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?`. + * + * @return \Google\Cloud\VectorSearch\V1\CreateCollectionRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\VectorSearch\V1\Collection $collection, string $collectionId): self + { + return (new self()) + ->setParent($parent) + ->setCollection($collection) + ->setCollectionId($collectionId); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. Value for parent. + * @type string $collection_id + * Required. ID of the Collection to create. + * The id must be 1-63 characters long, and comply with + * [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). + * Specifically, it must be 1-63 characters long and match the regular + * expression `[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?`. + * @type \Google\Cloud\VectorSearch\V1\Collection $collection + * 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 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\Vectorsearch\V1\VectorsearchService::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; + } + + /** + * Required. ID of the Collection to create. + * The id must be 1-63 characters long, and comply with + * [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). + * Specifically, it must be 1-63 characters long and match the regular + * expression `[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?`. + * + * Generated from protobuf field string collection_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getCollectionId() + { + return $this->collection_id; + } + + /** + * Required. ID of the Collection to create. + * The id must be 1-63 characters long, and comply with + * [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). + * Specifically, it must be 1-63 characters long and match the regular + * expression `[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?`. + * + * Generated from protobuf field string collection_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setCollectionId($var) + { + GPBUtil::checkString($var, True); + $this->collection_id = $var; + + return $this; + } + + /** + * Required. The resource being created + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.Collection collection = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\VectorSearch\V1\Collection|null + */ + public function getCollection() + { + return $this->collection; + } + + public function hasCollection() + { + return isset($this->collection); + } + + public function clearCollection() + { + unset($this->collection); + } + + /** + * Required. The resource being created + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.Collection collection = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\VectorSearch\V1\Collection $var + * @return $this + */ + public function setCollection($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\Collection::class); + $this->collection = $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, (.google.api.field_info) = { + * @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, (.google.api.field_info) = { + * @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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/CreateDataObjectRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/CreateDataObjectRequest.php new file mode 100644 index 000000000000..48de8c4ab540 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/CreateDataObjectRequest.php @@ -0,0 +1,189 @@ +google.cloud.vectorsearch.v1.CreateDataObjectRequest + */ +class CreateDataObjectRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the Collection to create the DataObject in. + * Format: `projects/{project}/locations/{location}/collections/{collection}` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. The id of the dataObject to create. + * The id must be 1-63 characters long, and comply with + * [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). + * Specifically, it must be 1-63 characters long and match the regular + * expression `[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?`. + * + * Generated from protobuf field string data_object_id = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $data_object_id = ''; + /** + * Required. The DataObject to create. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.DataObject data_object = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $data_object = null; + + /** + * @param string $parent Required. The resource name of the Collection to create the DataObject in. + * Format: `projects/{project}/locations/{location}/collections/{collection}` + * Please see {@see DataObjectServiceClient::collectionName()} for help formatting this field. + * @param \Google\Cloud\VectorSearch\V1\DataObject $dataObject Required. The DataObject to create. + * @param string $dataObjectId Required. The id of the dataObject to create. + * The id must be 1-63 characters long, and comply with + * [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). + * Specifically, it must be 1-63 characters long and match the regular + * expression `[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?`. + * + * @return \Google\Cloud\VectorSearch\V1\CreateDataObjectRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\VectorSearch\V1\DataObject $dataObject, string $dataObjectId): self + { + return (new self()) + ->setParent($parent) + ->setDataObject($dataObject) + ->setDataObjectId($dataObjectId); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. The resource name of the Collection to create the DataObject in. + * Format: `projects/{project}/locations/{location}/collections/{collection}` + * @type string $data_object_id + * Required. The id of the dataObject to create. + * The id must be 1-63 characters long, and comply with + * [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). + * Specifically, it must be 1-63 characters long and match the regular + * expression `[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?`. + * @type \Google\Cloud\VectorSearch\V1\DataObject $data_object + * Required. The DataObject to create. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the Collection to create the DataObject in. + * Format: `projects/{project}/locations/{location}/collections/{collection}` + * + * 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 Collection to create the DataObject in. + * Format: `projects/{project}/locations/{location}/collections/{collection}` + * + * 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 dataObject to create. + * The id must be 1-63 characters long, and comply with + * [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). + * Specifically, it must be 1-63 characters long and match the regular + * expression `[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?`. + * + * Generated from protobuf field string data_object_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getDataObjectId() + { + return $this->data_object_id; + } + + /** + * Required. The id of the dataObject to create. + * The id must be 1-63 characters long, and comply with + * [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). + * Specifically, it must be 1-63 characters long and match the regular + * expression `[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?`. + * + * Generated from protobuf field string data_object_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setDataObjectId($var) + { + GPBUtil::checkString($var, True); + $this->data_object_id = $var; + + return $this; + } + + /** + * Required. The DataObject to create. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.DataObject data_object = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\VectorSearch\V1\DataObject|null + */ + public function getDataObject() + { + return $this->data_object; + } + + public function hasDataObject() + { + return isset($this->data_object); + } + + public function clearDataObject() + { + unset($this->data_object); + } + + /** + * Required. The DataObject to create. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.DataObject data_object = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\VectorSearch\V1\DataObject $var + * @return $this + */ + public function setDataObject($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\DataObject::class); + $this->data_object = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/CreateIndexRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/CreateIndexRequest.php new file mode 100644 index 000000000000..a97225541f3c --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/CreateIndexRequest.php @@ -0,0 +1,267 @@ +google.cloud.vectorsearch.v1.CreateIndexRequest + */ +class CreateIndexRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the Collection for which to create the + * Index. Format: + * `projects/{project}/locations/{location}/collections/{collection}` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. ID of the Index to create. + * The id must be 1-63 characters long, and comply with + * [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). + * Specifically, it must be 1-63 characters long and match the regular + * expression `[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?`. + * + * Generated from protobuf field string index_id = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $index_id = ''; + /** + * Required. The resource being created + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.Index index = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $index = 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, (.google.api.field_info) = { + */ + protected $request_id = ''; + + /** + * @param string $parent Required. The resource name of the Collection for which to create the + * Index. Format: + * `projects/{project}/locations/{location}/collections/{collection}` + * Please see {@see VectorSearchServiceClient::collectionName()} for help formatting this field. + * @param \Google\Cloud\VectorSearch\V1\Index $index Required. The resource being created + * @param string $indexId Required. ID of the Index to create. + * The id must be 1-63 characters long, and comply with + * [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). + * Specifically, it must be 1-63 characters long and match the regular + * expression `[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?`. + * + * @return \Google\Cloud\VectorSearch\V1\CreateIndexRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\VectorSearch\V1\Index $index, string $indexId): self + { + return (new self()) + ->setParent($parent) + ->setIndex($index) + ->setIndexId($indexId); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. The resource name of the Collection for which to create the + * Index. Format: + * `projects/{project}/locations/{location}/collections/{collection}` + * @type string $index_id + * Required. ID of the Index to create. + * The id must be 1-63 characters long, and comply with + * [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). + * Specifically, it must be 1-63 characters long and match the regular + * expression `[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?`. + * @type \Google\Cloud\VectorSearch\V1\Index $index + * 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 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\Vectorsearch\V1\VectorsearchService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the Collection for which to create the + * Index. Format: + * `projects/{project}/locations/{location}/collections/{collection}` + * + * 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 Collection for which to create the + * Index. Format: + * `projects/{project}/locations/{location}/collections/{collection}` + * + * 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. ID of the Index to create. + * The id must be 1-63 characters long, and comply with + * [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). + * Specifically, it must be 1-63 characters long and match the regular + * expression `[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?`. + * + * Generated from protobuf field string index_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getIndexId() + { + return $this->index_id; + } + + /** + * Required. ID of the Index to create. + * The id must be 1-63 characters long, and comply with + * [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). + * Specifically, it must be 1-63 characters long and match the regular + * expression `[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?`. + * + * Generated from protobuf field string index_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setIndexId($var) + { + GPBUtil::checkString($var, True); + $this->index_id = $var; + + return $this; + } + + /** + * Required. The resource being created + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.Index index = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\VectorSearch\V1\Index|null + */ + public function getIndex() + { + return $this->index; + } + + public function hasIndex() + { + return isset($this->index); + } + + public function clearIndex() + { + unset($this->index); + } + + /** + * Required. The resource being created + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.Index index = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\VectorSearch\V1\Index $var + * @return $this + */ + public function setIndex($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\Index::class); + $this->index = $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, (.google.api.field_info) = { + * @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, (.google.api.field_info) = { + * @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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DataObject.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DataObject.php new file mode 100644 index 000000000000..2501187cbe74 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DataObject.php @@ -0,0 +1,317 @@ +google.cloud.vectorsearch.v1.DataObject + */ +class DataObject extends \Google\Protobuf\Internal\Message +{ + /** + * Identifier. The fully qualified resource name of the dataObject. + * Format: + * `projects/{project}/locations/{location}/collections/{collection}/dataObjects/{data_object_id}` + * The data_object_id must be 1-63 characters + * long, and comply with [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + */ + protected $name = ''; + /** + * Output only. The id of the dataObject. + * + * Generated from protobuf field string data_object_id = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $data_object_id = ''; + /** + * Output only. Timestamp the dataObject was created at. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $create_time = null; + /** + * Output only. Timestamp the dataObject was last updated. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $update_time = null; + /** + * Optional. The data of the dataObject. + * + * Generated from protobuf field .google.protobuf.Struct data = 6 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $data = null; + /** + * Optional. The vectors of the dataObject. + * + * Generated from protobuf field map vectors = 7 [(.google.api.field_behavior) = OPTIONAL]; + */ + private $vectors; + /** + * Optional. The etag of the dataObject. + * + * Generated from protobuf field string etag = 8 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $etag = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Identifier. The fully qualified resource name of the dataObject. + * Format: + * `projects/{project}/locations/{location}/collections/{collection}/dataObjects/{data_object_id}` + * The data_object_id must be 1-63 characters + * long, and comply with [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). + * @type string $data_object_id + * Output only. The id of the dataObject. + * @type \Google\Protobuf\Timestamp $create_time + * Output only. Timestamp the dataObject was created at. + * @type \Google\Protobuf\Timestamp $update_time + * Output only. Timestamp the dataObject was last updated. + * @type \Google\Protobuf\Struct $data + * Optional. The data of the dataObject. + * @type array|\Google\Protobuf\Internal\MapField $vectors + * Optional. The vectors of the dataObject. + * @type string $etag + * Optional. The etag of the dataObject. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObject::initOnce(); + parent::__construct($data); + } + + /** + * Identifier. The fully qualified resource name of the dataObject. + * Format: + * `projects/{project}/locations/{location}/collections/{collection}/dataObjects/{data_object_id}` + * The data_object_id must be 1-63 characters + * long, and comply with [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Identifier. The fully qualified resource name of the dataObject. + * Format: + * `projects/{project}/locations/{location}/collections/{collection}/dataObjects/{data_object_id}` + * The data_object_id must be 1-63 characters + * long, and comply with [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Output only. The id of the dataObject. + * + * Generated from protobuf field string data_object_id = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getDataObjectId() + { + return $this->data_object_id; + } + + /** + * Output only. The id of the dataObject. + * + * Generated from protobuf field string data_object_id = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setDataObjectId($var) + { + GPBUtil::checkString($var, True); + $this->data_object_id = $var; + + return $this; + } + + /** + * Output only. Timestamp the dataObject was created at. + * + * 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. Timestamp the dataObject was created at. + * + * 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. Timestamp the dataObject was last 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. Timestamp the dataObject was last 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; + } + + /** + * Optional. The data of the dataObject. + * + * Generated from protobuf field .google.protobuf.Struct data = 6 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Protobuf\Struct|null + */ + public function getData() + { + return $this->data; + } + + public function hasData() + { + return isset($this->data); + } + + public function clearData() + { + unset($this->data); + } + + /** + * Optional. The data of the dataObject. + * + * Generated from protobuf field .google.protobuf.Struct data = 6 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Protobuf\Struct $var + * @return $this + */ + public function setData($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Struct::class); + $this->data = $var; + + return $this; + } + + /** + * Optional. The vectors of the dataObject. + * + * Generated from protobuf field map vectors = 7 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Protobuf\Internal\MapField + */ + public function getVectors() + { + return $this->vectors; + } + + /** + * Optional. The vectors of the dataObject. + * + * Generated from protobuf field map vectors = 7 [(.google.api.field_behavior) = OPTIONAL]; + * @param array|\Google\Protobuf\Internal\MapField $var + * @return $this + */ + public function setVectors($var) + { + $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VectorSearch\V1\Vector::class); + $this->vectors = $arr; + + return $this; + } + + /** + * Optional. The etag of the dataObject. + * + * Generated from protobuf field string etag = 8 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getEtag() + { + return $this->etag; + } + + /** + * Optional. The etag of the dataObject. + * + * Generated from protobuf field string etag = 8 [(.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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DedicatedInfrastructure.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DedicatedInfrastructure.php new file mode 100644 index 000000000000..30eb1135250f --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DedicatedInfrastructure.php @@ -0,0 +1,121 @@ +google.cloud.vectorsearch.v1.DedicatedInfrastructure + */ +class DedicatedInfrastructure extends \Google\Protobuf\Internal\Message +{ + /** + * Optional. Mode of the dedicated infrastructure. + * + * Generated from protobuf field optional .google.cloud.vectorsearch.v1.DedicatedInfrastructure.Mode mode = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $mode = null; + /** + * Optional. Autoscaling specification. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.DedicatedInfrastructure.AutoscalingSpec autoscaling_spec = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $autoscaling_spec = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $mode + * Optional. Mode of the dedicated infrastructure. + * @type \Google\Cloud\VectorSearch\V1\DedicatedInfrastructure\AutoscalingSpec $autoscaling_spec + * Optional. Autoscaling specification. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\VectorsearchService::initOnce(); + parent::__construct($data); + } + + /** + * Optional. Mode of the dedicated infrastructure. + * + * Generated from protobuf field optional .google.cloud.vectorsearch.v1.DedicatedInfrastructure.Mode mode = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @return int + */ + public function getMode() + { + return isset($this->mode) ? $this->mode : 0; + } + + public function hasMode() + { + return isset($this->mode); + } + + public function clearMode() + { + unset($this->mode); + } + + /** + * Optional. Mode of the dedicated infrastructure. + * + * Generated from protobuf field optional .google.cloud.vectorsearch.v1.DedicatedInfrastructure.Mode mode = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @param int $var + * @return $this + */ + public function setMode($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\VectorSearch\V1\DedicatedInfrastructure\Mode::class); + $this->mode = $var; + + return $this; + } + + /** + * Optional. Autoscaling specification. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.DedicatedInfrastructure.AutoscalingSpec autoscaling_spec = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\VectorSearch\V1\DedicatedInfrastructure\AutoscalingSpec|null + */ + public function getAutoscalingSpec() + { + return $this->autoscaling_spec; + } + + public function hasAutoscalingSpec() + { + return isset($this->autoscaling_spec); + } + + public function clearAutoscalingSpec() + { + unset($this->autoscaling_spec); + } + + /** + * Optional. Autoscaling specification. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.DedicatedInfrastructure.AutoscalingSpec autoscaling_spec = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\VectorSearch\V1\DedicatedInfrastructure\AutoscalingSpec $var + * @return $this + */ + public function setAutoscalingSpec($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\DedicatedInfrastructure\AutoscalingSpec::class); + $this->autoscaling_spec = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DedicatedInfrastructure/AutoscalingSpec.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DedicatedInfrastructure/AutoscalingSpec.php new file mode 100644 index 000000000000..7435105a9140 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DedicatedInfrastructure/AutoscalingSpec.php @@ -0,0 +1,125 @@ +google.cloud.vectorsearch.v1.DedicatedInfrastructure.AutoscalingSpec + */ +class AutoscalingSpec extends \Google\Protobuf\Internal\Message +{ + /** + * Optional. The minimum number of replicas. If not set or set to `0`, + * defaults to `2`. Must be >= `1` and <= `1000`. + * + * Generated from protobuf field int32 min_replica_count = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $min_replica_count = 0; + /** + * Optional. The maximum number of replicas. Must be >= + * `min_replica_count` and <= `1000`. + * For the v1beta version, if not set or set to `0`, defaults to + * the greater of `min_replica_count` and `5`. + * For all other versions, if not set or set to `0`, defaults to + * the greater of `min_replica_count` and `2`. + * + * Generated from protobuf field int32 max_replica_count = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $max_replica_count = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $min_replica_count + * Optional. The minimum number of replicas. If not set or set to `0`, + * defaults to `2`. Must be >= `1` and <= `1000`. + * @type int $max_replica_count + * Optional. The maximum number of replicas. Must be >= + * `min_replica_count` and <= `1000`. + * For the v1beta version, if not set or set to `0`, defaults to + * the greater of `min_replica_count` and `5`. + * For all other versions, if not set or set to `0`, defaults to + * the greater of `min_replica_count` and `2`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\VectorsearchService::initOnce(); + parent::__construct($data); + } + + /** + * Optional. The minimum number of replicas. If not set or set to `0`, + * defaults to `2`. Must be >= `1` and <= `1000`. + * + * Generated from protobuf field int32 min_replica_count = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @return int + */ + public function getMinReplicaCount() + { + return $this->min_replica_count; + } + + /** + * Optional. The minimum number of replicas. If not set or set to `0`, + * defaults to `2`. Must be >= `1` and <= `1000`. + * + * Generated from protobuf field int32 min_replica_count = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @param int $var + * @return $this + */ + public function setMinReplicaCount($var) + { + GPBUtil::checkInt32($var); + $this->min_replica_count = $var; + + return $this; + } + + /** + * Optional. The maximum number of replicas. Must be >= + * `min_replica_count` and <= `1000`. + * For the v1beta version, if not set or set to `0`, defaults to + * the greater of `min_replica_count` and `5`. + * For all other versions, if not set or set to `0`, defaults to + * the greater of `min_replica_count` and `2`. + * + * Generated from protobuf field int32 max_replica_count = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return int + */ + public function getMaxReplicaCount() + { + return $this->max_replica_count; + } + + /** + * Optional. The maximum number of replicas. Must be >= + * `min_replica_count` and <= `1000`. + * For the v1beta version, if not set or set to `0`, defaults to + * the greater of `min_replica_count` and `5`. + * For all other versions, if not set or set to `0`, defaults to + * the greater of `min_replica_count` and `2`. + * + * Generated from protobuf field int32 max_replica_count = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @param int $var + * @return $this + */ + public function setMaxReplicaCount($var) + { + GPBUtil::checkInt32($var); + $this->max_replica_count = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DedicatedInfrastructure/Mode.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DedicatedInfrastructure/Mode.php new file mode 100644 index 000000000000..2a01db202e2d --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DedicatedInfrastructure/Mode.php @@ -0,0 +1,61 @@ +google.cloud.vectorsearch.v1.DedicatedInfrastructure.Mode + */ +class Mode +{ + /** + * Default will use `PERFORMANCE_OPTIMIZED`. + * + * Generated from protobuf enum MODE_UNSPECIFIED = 0; + */ + const MODE_UNSPECIFIED = 0; + /** + * This is storage optimized variation. + * + * Generated from protobuf enum STORAGE_OPTIMIZED = 1; + */ + const STORAGE_OPTIMIZED = 1; + /** + * This is Performance optimized on E2 or equivalent family. + * + * Generated from protobuf enum PERFORMANCE_OPTIMIZED = 2; + */ + const PERFORMANCE_OPTIMIZED = 2; + + private static $valueToName = [ + self::MODE_UNSPECIFIED => 'MODE_UNSPECIFIED', + self::STORAGE_OPTIMIZED => 'STORAGE_OPTIMIZED', + self::PERFORMANCE_OPTIMIZED => 'PERFORMANCE_OPTIMIZED', + ]; + + 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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DeleteCollectionRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DeleteCollectionRequest.php new file mode 100644 index 000000000000..a15a54e937b2 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DeleteCollectionRequest.php @@ -0,0 +1,155 @@ +google.cloud.vectorsearch.v1.DeleteCollectionRequest + */ +class DeleteCollectionRequest 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 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { + */ + protected $request_id = ''; + + /** + * @param string $name Required. Name of the resource + * Please see {@see VectorSearchServiceClient::collectionName()} for help formatting this field. + * + * @return \Google\Cloud\VectorSearch\V1\DeleteCollectionRequest + * + * @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 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\Vectorsearch\V1\VectorsearchService::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 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { + * @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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { + * @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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DeleteDataObjectRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DeleteDataObjectRequest.php new file mode 100644 index 000000000000..7b02cd1fe558 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DeleteDataObjectRequest.php @@ -0,0 +1,134 @@ +google.cloud.vectorsearch.v1.DeleteDataObjectRequest + */ +class DeleteDataObjectRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the DataObject resource to be deleted. + * Format: + * `projects/{project}/locations/{location}/collections/{collection}/dataObjects/{dataObject}` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * Optional. The current etag of the DataObject. + * If an etag is provided and does not match the current etag of the + * DataObject, deletion will be blocked and an ABORTED error will be returned. + * + * Generated from protobuf field string etag = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $etag = ''; + + /** + * @param string $name Required. The name of the DataObject resource to be deleted. + * Format: + * `projects/{project}/locations/{location}/collections/{collection}/dataObjects/{dataObject}` + * Please see {@see DataObjectServiceClient::dataObjectName()} for help formatting this field. + * + * @return \Google\Cloud\VectorSearch\V1\DeleteDataObjectRequest + * + * @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 DataObject resource to be deleted. + * Format: + * `projects/{project}/locations/{location}/collections/{collection}/dataObjects/{dataObject}` + * @type string $etag + * Optional. The current etag of the DataObject. + * If an etag is provided and does not match the current etag of the + * DataObject, deletion will be blocked and an ABORTED error will be returned. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the DataObject resource to be deleted. + * Format: + * `projects/{project}/locations/{location}/collections/{collection}/dataObjects/{dataObject}` + * + * 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 DataObject resource to be deleted. + * Format: + * `projects/{project}/locations/{location}/collections/{collection}/dataObjects/{dataObject}` + * + * 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 current etag of the DataObject. + * If an etag is provided and does not match the current etag of the + * DataObject, deletion will be blocked and an ABORTED error will be returned. + * + * Generated from protobuf field string etag = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getEtag() + { + return $this->etag; + } + + /** + * Optional. The current etag of the DataObject. + * If an etag is provided and does not match the current etag of the + * DataObject, deletion will be blocked and an ABORTED error will be returned. + * + * 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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DeleteIndexRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DeleteIndexRequest.php new file mode 100644 index 000000000000..312854bce6d7 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DeleteIndexRequest.php @@ -0,0 +1,165 @@ +google.cloud.vectorsearch.v1.DeleteIndexRequest + */ +class DeleteIndexRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the Index to delete. + * Format: + * `projects/{project}/locations/{location}/collections/{collection}/indexes/{index}` + * + * 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 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { + */ + protected $request_id = ''; + + /** + * @param string $name Required. The resource name of the Index to delete. + * Format: + * `projects/{project}/locations/{location}/collections/{collection}/indexes/{index}` + * Please see {@see VectorSearchServiceClient::indexName()} for help formatting this field. + * + * @return \Google\Cloud\VectorSearch\V1\DeleteIndexRequest + * + * @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 Index to delete. + * Format: + * `projects/{project}/locations/{location}/collections/{collection}/indexes/{index}` + * @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\Vectorsearch\V1\VectorsearchService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the Index to delete. + * Format: + * `projects/{project}/locations/{location}/collections/{collection}/indexes/{index}` + * + * 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 Index to delete. + * Format: + * `projects/{project}/locations/{location}/collections/{collection}/indexes/{index}` + * + * 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 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { + * @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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { + * @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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DenseScannIndex.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DenseScannIndex.php new file mode 100644 index 000000000000..597ff9a9b6ac --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DenseScannIndex.php @@ -0,0 +1,67 @@ +google.cloud.vectorsearch.v1.DenseScannIndex + */ +class DenseScannIndex extends \Google\Protobuf\Internal\Message +{ + /** + * Optional. Feature norm type. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.DenseScannIndex.FeatureNormType feature_norm_type = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $feature_norm_type = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $feature_norm_type + * Optional. Feature norm type. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\VectorsearchService::initOnce(); + parent::__construct($data); + } + + /** + * Optional. Feature norm type. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.DenseScannIndex.FeatureNormType feature_norm_type = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return int + */ + public function getFeatureNormType() + { + return $this->feature_norm_type; + } + + /** + * Optional. Feature norm type. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.DenseScannIndex.FeatureNormType feature_norm_type = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @param int $var + * @return $this + */ + public function setFeatureNormType($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\VectorSearch\V1\DenseScannIndex\FeatureNormType::class); + $this->feature_norm_type = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DenseScannIndex/FeatureNormType.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DenseScannIndex/FeatureNormType.php new file mode 100644 index 000000000000..fb2ac5c5d670 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DenseScannIndex/FeatureNormType.php @@ -0,0 +1,61 @@ +google.cloud.vectorsearch.v1.DenseScannIndex.FeatureNormType + */ +class FeatureNormType +{ + /** + * Unspecified feature norm type. + * + * Generated from protobuf enum FEATURE_NORM_TYPE_UNSPECIFIED = 0; + */ + const FEATURE_NORM_TYPE_UNSPECIFIED = 0; + /** + * No norm applied. + * + * Generated from protobuf enum NONE = 1; + */ + const NONE = 1; + /** + * Unit L2 norm. + * + * Generated from protobuf enum UNIT_L2_NORM = 2; + */ + const UNIT_L2_NORM = 2; + + private static $valueToName = [ + self::FEATURE_NORM_TYPE_UNSPECIFIED => 'FEATURE_NORM_TYPE_UNSPECIFIED', + self::NONE => 'NONE', + self::UNIT_L2_NORM => 'UNIT_L2_NORM', + ]; + + 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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DenseVector.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DenseVector.php new file mode 100644 index 000000000000..c3e81f1d2b3a --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DenseVector.php @@ -0,0 +1,67 @@ +google.cloud.vectorsearch.v1.DenseVector + */ +class DenseVector extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The values of the vector. + * + * Generated from protobuf field repeated float values = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + private $values; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type float[] $values + * Required. The values of the vector. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObject::initOnce(); + parent::__construct($data); + } + + /** + * Required. The values of the vector. + * + * Generated from protobuf field repeated float values = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return RepeatedField + */ + public function getValues() + { + return $this->values; + } + + /** + * Required. The values of the vector. + * + * Generated from protobuf field repeated float values = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param float[] $var + * @return $this + */ + public function setValues($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::FLOAT); + $this->values = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DenseVectorField.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DenseVectorField.php new file mode 100644 index 000000000000..bb67c3ad25a6 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DenseVectorField.php @@ -0,0 +1,115 @@ +google.cloud.vectorsearch.v1.DenseVectorField + */ +class DenseVectorField extends \Google\Protobuf\Internal\Message +{ + /** + * Dimensionality of the vector field. + * + * Generated from protobuf field int32 dimensions = 1; + */ + protected $dimensions = 0; + /** + * Optional. Configuration for generating embeddings for the vector field. If + * not specified, the embedding field must be populated in the DataObject. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.VertexEmbeddingConfig vertex_embedding_config = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $vertex_embedding_config = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $dimensions + * Dimensionality of the vector field. + * @type \Google\Cloud\VectorSearch\V1\VertexEmbeddingConfig $vertex_embedding_config + * Optional. Configuration for generating embeddings for the vector field. If + * not specified, the embedding field must be populated in the DataObject. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\VectorsearchService::initOnce(); + parent::__construct($data); + } + + /** + * Dimensionality of the vector field. + * + * Generated from protobuf field int32 dimensions = 1; + * @return int + */ + public function getDimensions() + { + return $this->dimensions; + } + + /** + * Dimensionality of the vector field. + * + * Generated from protobuf field int32 dimensions = 1; + * @param int $var + * @return $this + */ + public function setDimensions($var) + { + GPBUtil::checkInt32($var); + $this->dimensions = $var; + + return $this; + } + + /** + * Optional. Configuration for generating embeddings for the vector field. If + * not specified, the embedding field must be populated in the DataObject. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.VertexEmbeddingConfig vertex_embedding_config = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\VectorSearch\V1\VertexEmbeddingConfig|null + */ + public function getVertexEmbeddingConfig() + { + return $this->vertex_embedding_config; + } + + public function hasVertexEmbeddingConfig() + { + return isset($this->vertex_embedding_config); + } + + public function clearVertexEmbeddingConfig() + { + unset($this->vertex_embedding_config); + } + + /** + * Optional. Configuration for generating embeddings for the vector field. If + * not specified, the embedding field must be populated in the DataObject. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.VertexEmbeddingConfig vertex_embedding_config = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\VectorSearch\V1\VertexEmbeddingConfig $var + * @return $this + */ + public function setVertexEmbeddingConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\VertexEmbeddingConfig::class); + $this->vertex_embedding_config = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DistanceMetric.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DistanceMetric.php new file mode 100644 index 000000000000..e9956ad6fe10 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DistanceMetric.php @@ -0,0 +1,61 @@ +google.cloud.vectorsearch.v1.DistanceMetric + */ +class DistanceMetric +{ + /** + * Default value, distance metric is not specified. + * + * Generated from protobuf enum DISTANCE_METRIC_UNSPECIFIED = 0; + */ + const DISTANCE_METRIC_UNSPECIFIED = 0; + /** + * Dot product distance metric. + * + * Generated from protobuf enum DOT_PRODUCT = 1; + */ + const DOT_PRODUCT = 1; + /** + * Cosine distance metric. + * + * Generated from protobuf enum COSINE_DISTANCE = 2; + */ + const COSINE_DISTANCE = 2; + + private static $valueToName = [ + self::DISTANCE_METRIC_UNSPECIFIED => 'DISTANCE_METRIC_UNSPECIFIED', + self::DOT_PRODUCT => 'DOT_PRODUCT', + self::COSINE_DISTANCE => 'COSINE_DISTANCE', + ]; + + 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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/EmbeddingTaskType.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/EmbeddingTaskType.php new file mode 100644 index 000000000000..36e86bca6e50 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/EmbeddingTaskType.php @@ -0,0 +1,103 @@ +google.cloud.vectorsearch.v1.EmbeddingTaskType + */ +class EmbeddingTaskType +{ + /** + * Unspecified task type. + * + * Generated from protobuf enum EMBEDDING_TASK_TYPE_UNSPECIFIED = 0; + */ + const EMBEDDING_TASK_TYPE_UNSPECIFIED = 0; + /** + * Specifies the given text is a query in a search/retrieval setting. + * + * Generated from protobuf enum RETRIEVAL_QUERY = 1; + */ + const RETRIEVAL_QUERY = 1; + /** + * Specifies the given text is a document from the corpus being searched. + * + * Generated from protobuf enum RETRIEVAL_DOCUMENT = 2; + */ + const RETRIEVAL_DOCUMENT = 2; + /** + * Specifies the given text will be used for STS. + * + * Generated from protobuf enum SEMANTIC_SIMILARITY = 3; + */ + const SEMANTIC_SIMILARITY = 3; + /** + * Specifies that the given text will be classified. + * + * Generated from protobuf enum CLASSIFICATION = 4; + */ + const CLASSIFICATION = 4; + /** + * Specifies that the embeddings will be used for clustering. + * + * Generated from protobuf enum CLUSTERING = 5; + */ + const CLUSTERING = 5; + /** + * Specifies that the embeddings will be used for question answering. + * + * Generated from protobuf enum QUESTION_ANSWERING = 6; + */ + const QUESTION_ANSWERING = 6; + /** + * Specifies that the embeddings will be used for fact verification. + * + * Generated from protobuf enum FACT_VERIFICATION = 7; + */ + const FACT_VERIFICATION = 7; + /** + * Specifies that the embeddings will be used for code retrieval. + * + * Generated from protobuf enum CODE_RETRIEVAL_QUERY = 8; + */ + const CODE_RETRIEVAL_QUERY = 8; + + private static $valueToName = [ + self::EMBEDDING_TASK_TYPE_UNSPECIFIED => 'EMBEDDING_TASK_TYPE_UNSPECIFIED', + self::RETRIEVAL_QUERY => 'RETRIEVAL_QUERY', + self::RETRIEVAL_DOCUMENT => 'RETRIEVAL_DOCUMENT', + self::SEMANTIC_SIMILARITY => 'SEMANTIC_SIMILARITY', + self::CLASSIFICATION => 'CLASSIFICATION', + self::CLUSTERING => 'CLUSTERING', + self::QUESTION_ANSWERING => 'QUESTION_ANSWERING', + self::FACT_VERIFICATION => 'FACT_VERIFICATION', + self::CODE_RETRIEVAL_QUERY => 'CODE_RETRIEVAL_QUERY', + ]; + + 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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/EncryptionSpec.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/EncryptionSpec.php new file mode 100644 index 000000000000..82c9f1b9b187 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/EncryptionSpec.php @@ -0,0 +1,80 @@ +google.cloud.vectorsearch.v1.EncryptionSpec + */ +class EncryptionSpec extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Resource name of the Cloud KMS key used to protect the resource. + * The Cloud KMS key must be in the same region as the resource. It must have + * the format + * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. + * + * Generated from protobuf field string crypto_key_name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $crypto_key_name = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $crypto_key_name + * Required. Resource name of the Cloud KMS key used to protect the resource. + * The Cloud KMS key must be in the same region as the resource. It must have + * the format + * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\EncryptionSpec::initOnce(); + parent::__construct($data); + } + + /** + * Required. Resource name of the Cloud KMS key used to protect the resource. + * The Cloud KMS key must be in the same region as the resource. It must have + * the format + * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. + * + * Generated from protobuf field string crypto_key_name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getCryptoKeyName() + { + return $this->crypto_key_name; + } + + /** + * Required. Resource name of the Cloud KMS key used to protect the resource. + * The Cloud KMS key must be in the same region as the resource. It must have + * the format + * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. + * + * Generated from protobuf field string crypto_key_name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setCryptoKeyName($var) + { + GPBUtil::checkString($var, True); + $this->crypto_key_name = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ExportDataObjectsMetadata.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ExportDataObjectsMetadata.php new file mode 100644 index 000000000000..891402eb6a5a --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ExportDataObjectsMetadata.php @@ -0,0 +1,121 @@ +google.cloud.vectorsearch.v1.ExportDataObjectsMetadata + */ +class ExportDataObjectsMetadata 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. + * + * Generated from protobuf field .google.protobuf.Timestamp finish_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $finish_time = null; + + /** + * 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 $finish_time + * Output only. The time the operation finished. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\VectorsearchService::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. + * + * Generated from protobuf field .google.protobuf.Timestamp finish_time = 2 [(.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. The time the operation finished. + * + * Generated from protobuf field .google.protobuf.Timestamp finish_time = 2 [(.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; + } + +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ExportDataObjectsRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ExportDataObjectsRequest.php new file mode 100644 index 000000000000..707456e9a116 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ExportDataObjectsRequest.php @@ -0,0 +1,118 @@ +google.cloud.vectorsearch.v1.ExportDataObjectsRequest + */ +class ExportDataObjectsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the Collection from which we want to export + * Data Objects. Format: + * `projects/{project}/locations/{location}/collections/{collection}`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + protected $destination; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\VectorSearch\V1\ExportDataObjectsRequest\GcsExportDestination $gcs_destination + * The Cloud Storage location where user wants to export Data Objects. + * @type string $name + * Required. The resource name of the Collection from which we want to export + * Data Objects. Format: + * `projects/{project}/locations/{location}/collections/{collection}`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\VectorsearchService::initOnce(); + parent::__construct($data); + } + + /** + * The Cloud Storage location where user wants to export Data Objects. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.ExportDataObjectsRequest.GcsExportDestination gcs_destination = 2; + * @return \Google\Cloud\VectorSearch\V1\ExportDataObjectsRequest\GcsExportDestination|null + */ + public function getGcsDestination() + { + return $this->readOneof(2); + } + + public function hasGcsDestination() + { + return $this->hasOneof(2); + } + + /** + * The Cloud Storage location where user wants to export Data Objects. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.ExportDataObjectsRequest.GcsExportDestination gcs_destination = 2; + * @param \Google\Cloud\VectorSearch\V1\ExportDataObjectsRequest\GcsExportDestination $var + * @return $this + */ + public function setGcsDestination($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\ExportDataObjectsRequest\GcsExportDestination::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * Required. The resource name of the Collection from which we want to export + * Data Objects. Format: + * `projects/{project}/locations/{location}/collections/{collection}`. + * + * 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 Collection from which we want to export + * Data Objects. Format: + * `projects/{project}/locations/{location}/collections/{collection}`. + * + * 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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ExportDataObjectsRequest/GcsExportDestination.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ExportDataObjectsRequest/GcsExportDestination.php new file mode 100644 index 000000000000..64fa188a3160 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ExportDataObjectsRequest/GcsExportDestination.php @@ -0,0 +1,105 @@ +google.cloud.vectorsearch.v1.ExportDataObjectsRequest.GcsExportDestination + */ +class GcsExportDestination extends \Google\Protobuf\Internal\Message +{ + /** + * Required. URI prefix of the Cloud Storage where to export Data Objects. + * The bucket is required to be in the same region as the collection. + * + * Generated from protobuf field string export_uri = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $export_uri = ''; + /** + * Required. The format of the exported Data Objects. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.ExportDataObjectsRequest.GcsExportDestination.Format format = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $format = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $export_uri + * Required. URI prefix of the Cloud Storage where to export Data Objects. + * The bucket is required to be in the same region as the collection. + * @type int $format + * Required. The format of the exported Data Objects. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\VectorsearchService::initOnce(); + parent::__construct($data); + } + + /** + * Required. URI prefix of the Cloud Storage where to export Data Objects. + * The bucket is required to be in the same region as the collection. + * + * Generated from protobuf field string export_uri = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getExportUri() + { + return $this->export_uri; + } + + /** + * Required. URI prefix of the Cloud Storage where to export Data Objects. + * The bucket is required to be in the same region as the collection. + * + * Generated from protobuf field string export_uri = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setExportUri($var) + { + GPBUtil::checkString($var, True); + $this->export_uri = $var; + + return $this; + } + + /** + * Required. The format of the exported Data Objects. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.ExportDataObjectsRequest.GcsExportDestination.Format format = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return int + */ + public function getFormat() + { + return $this->format; + } + + /** + * Required. The format of the exported Data Objects. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.ExportDataObjectsRequest.GcsExportDestination.Format format = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param int $var + * @return $this + */ + public function setFormat($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\VectorSearch\V1\ExportDataObjectsRequest\GcsExportDestination\Format::class); + $this->format = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ExportDataObjectsRequest/GcsExportDestination/Format.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ExportDataObjectsRequest/GcsExportDestination/Format.php new file mode 100644 index 000000000000..18b8f8a0fad6 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ExportDataObjectsRequest/GcsExportDestination/Format.php @@ -0,0 +1,54 @@ +google.cloud.vectorsearch.v1.ExportDataObjectsRequest.GcsExportDestination.Format + */ +class Format +{ + /** + * Unspecified format. + * + * Generated from protobuf enum FORMAT_UNSPECIFIED = 0; + */ + const FORMAT_UNSPECIFIED = 0; + /** + * Exports Data Objects in `JSONL` format. + * + * Generated from protobuf enum JSONL = 2; + */ + const JSONL = 2; + + private static $valueToName = [ + self::FORMAT_UNSPECIFIED => 'FORMAT_UNSPECIFIED', + self::JSONL => 'JSONL', + ]; + + 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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ExportDataObjectsResponse.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ExportDataObjectsResponse.php new file mode 100644 index 000000000000..bc89240cfc6a --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ExportDataObjectsResponse.php @@ -0,0 +1,33 @@ +google.cloud.vectorsearch.v1.ExportDataObjectsResponse + */ +class ExportDataObjectsResponse extends \Google\Protobuf\Internal\Message +{ + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\VectorsearchService::initOnce(); + parent::__construct($data); + } + +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/GetCollectionRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/GetCollectionRequest.php new file mode 100644 index 000000000000..19bffcd2399c --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/GetCollectionRequest.php @@ -0,0 +1,81 @@ +google.cloud.vectorsearch.v1.GetCollectionRequest + */ +class GetCollectionRequest 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 VectorSearchServiceClient::collectionName()} for help formatting this field. + * + * @return \Google\Cloud\VectorSearch\V1\GetCollectionRequest + * + * @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\Vectorsearch\V1\VectorsearchService::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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/GetDataObjectRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/GetDataObjectRequest.php new file mode 100644 index 000000000000..be7fb8fd8310 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/GetDataObjectRequest.php @@ -0,0 +1,92 @@ +google.cloud.vectorsearch.v1.GetDataObjectRequest + */ +class GetDataObjectRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the DataObject resource. + * Format: + * `projects/{project}/locations/{location}/collections/{collection}/dataObjects/{dataObject}` + * + * 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 DataObject resource. + * Format: + * `projects/{project}/locations/{location}/collections/{collection}/dataObjects/{dataObject}` + * Please see {@see DataObjectServiceClient::dataObjectName()} for help formatting this field. + * + * @return \Google\Cloud\VectorSearch\V1\GetDataObjectRequest + * + * @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 DataObject resource. + * Format: + * `projects/{project}/locations/{location}/collections/{collection}/dataObjects/{dataObject}` + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the DataObject resource. + * Format: + * `projects/{project}/locations/{location}/collections/{collection}/dataObjects/{dataObject}` + * + * 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 DataObject resource. + * Format: + * `projects/{project}/locations/{location}/collections/{collection}/dataObjects/{dataObject}` + * + * 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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/GetIndexRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/GetIndexRequest.php new file mode 100644 index 000000000000..68af998408f1 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/GetIndexRequest.php @@ -0,0 +1,81 @@ +google.cloud.vectorsearch.v1.GetIndexRequest + */ +class GetIndexRequest 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 VectorSearchServiceClient::indexName()} for help formatting this field. + * + * @return \Google\Cloud\VectorSearch\V1\GetIndexRequest + * + * @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\Vectorsearch\V1\VectorsearchService::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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ImportDataObjectsMetadata.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ImportDataObjectsMetadata.php new file mode 100644 index 000000000000..1b6aea8316d2 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ImportDataObjectsMetadata.php @@ -0,0 +1,190 @@ +google.cloud.vectorsearch.v1.ImportDataObjectsMetadata + */ +class ImportDataObjectsMetadata 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 was last updated. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $update_time = null; + /** + * Output only. Number of DataObjects that were processed successfully. + * + * Generated from protobuf field int64 success_count = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $success_count = 0; + /** + * Output only. Number of DataObjects that failed during processing. + * + * Generated from protobuf field int64 failure_count = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $failure_count = 0; + + /** + * 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 $update_time + * Output only. The time the operation was last updated. + * @type int|string $success_count + * Output only. Number of DataObjects that were processed successfully. + * @type int|string $failure_count + * Output only. Number of DataObjects that failed during processing. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\VectorsearchService::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 was last updated. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 2 [(.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 operation was last updated. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 2 [(.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. Number of DataObjects that were processed successfully. + * + * Generated from protobuf field int64 success_count = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int|string + */ + public function getSuccessCount() + { + return $this->success_count; + } + + /** + * Output only. Number of DataObjects that were processed successfully. + * + * Generated from protobuf field int64 success_count = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int|string $var + * @return $this + */ + public function setSuccessCount($var) + { + GPBUtil::checkInt64($var); + $this->success_count = $var; + + return $this; + } + + /** + * Output only. Number of DataObjects that failed during processing. + * + * Generated from protobuf field int64 failure_count = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int|string + */ + public function getFailureCount() + { + return $this->failure_count; + } + + /** + * Output only. Number of DataObjects that failed during processing. + * + * Generated from protobuf field int64 failure_count = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int|string $var + * @return $this + */ + public function setFailureCount($var) + { + GPBUtil::checkInt64($var); + $this->failure_count = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ImportDataObjectsRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ImportDataObjectsRequest.php new file mode 100644 index 000000000000..7b8aeb8422ab --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ImportDataObjectsRequest.php @@ -0,0 +1,114 @@ +google.cloud.vectorsearch.v1.ImportDataObjectsRequest + */ +class ImportDataObjectsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the Collection to import DataObjects into. + * Format: `projects/{project}/locations/{location}/collections/{collection}`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + protected $config; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\VectorSearch\V1\ImportDataObjectsRequest\GcsImportConfig $gcs_import + * The Cloud Storage location of the input content. + * @type string $name + * Required. The resource name of the Collection to import DataObjects into. + * Format: `projects/{project}/locations/{location}/collections/{collection}`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\VectorsearchService::initOnce(); + parent::__construct($data); + } + + /** + * The Cloud Storage location of the input content. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.ImportDataObjectsRequest.GcsImportConfig gcs_import = 2; + * @return \Google\Cloud\VectorSearch\V1\ImportDataObjectsRequest\GcsImportConfig|null + */ + public function getGcsImport() + { + return $this->readOneof(2); + } + + public function hasGcsImport() + { + return $this->hasOneof(2); + } + + /** + * The Cloud Storage location of the input content. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.ImportDataObjectsRequest.GcsImportConfig gcs_import = 2; + * @param \Google\Cloud\VectorSearch\V1\ImportDataObjectsRequest\GcsImportConfig $var + * @return $this + */ + public function setGcsImport($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\ImportDataObjectsRequest\GcsImportConfig::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * Required. The resource name of the Collection to import DataObjects into. + * Format: `projects/{project}/locations/{location}/collections/{collection}`. + * + * 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 Collection to import DataObjects into. + * Format: `projects/{project}/locations/{location}/collections/{collection}`. + * + * 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 getConfig() + { + return $this->whichOneof("config"); + } + +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ImportDataObjectsRequest/GcsImportConfig.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ImportDataObjectsRequest/GcsImportConfig.php new file mode 100644 index 000000000000..f60f8a784d42 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ImportDataObjectsRequest/GcsImportConfig.php @@ -0,0 +1,151 @@ +google.cloud.vectorsearch.v1.ImportDataObjectsRequest.GcsImportConfig + */ +class GcsImportConfig extends \Google\Protobuf\Internal\Message +{ + /** + * Required. URI prefix of the Cloud Storage DataObjects to import. + * + * Generated from protobuf field string contents_uri = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $contents_uri = ''; + /** + * Required. URI prefix of the Cloud Storage location to write any errors + * encountered during the import. + * + * Generated from protobuf field string error_uri = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $error_uri = ''; + /** + * Optional. URI prefix of the Cloud Storage location to write DataObject + * `IDs` and `etags` of DataObjects that were successfully imported. The + * service will write the successfully imported DataObjects to sharded files + * under this prefix. If this field is empty, no output will be written. + * + * Generated from protobuf field string output_uri = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $output_uri = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $contents_uri + * Required. URI prefix of the Cloud Storage DataObjects to import. + * @type string $error_uri + * Required. URI prefix of the Cloud Storage location to write any errors + * encountered during the import. + * @type string $output_uri + * Optional. URI prefix of the Cloud Storage location to write DataObject + * `IDs` and `etags` of DataObjects that were successfully imported. The + * service will write the successfully imported DataObjects to sharded files + * under this prefix. If this field is empty, no output will be written. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\VectorsearchService::initOnce(); + parent::__construct($data); + } + + /** + * Required. URI prefix of the Cloud Storage DataObjects to import. + * + * Generated from protobuf field string contents_uri = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getContentsUri() + { + return $this->contents_uri; + } + + /** + * Required. URI prefix of the Cloud Storage DataObjects to import. + * + * Generated from protobuf field string contents_uri = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setContentsUri($var) + { + GPBUtil::checkString($var, True); + $this->contents_uri = $var; + + return $this; + } + + /** + * Required. URI prefix of the Cloud Storage location to write any errors + * encountered during the import. + * + * Generated from protobuf field string error_uri = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getErrorUri() + { + return $this->error_uri; + } + + /** + * Required. URI prefix of the Cloud Storage location to write any errors + * encountered during the import. + * + * Generated from protobuf field string error_uri = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setErrorUri($var) + { + GPBUtil::checkString($var, True); + $this->error_uri = $var; + + return $this; + } + + /** + * Optional. URI prefix of the Cloud Storage location to write DataObject + * `IDs` and `etags` of DataObjects that were successfully imported. The + * service will write the successfully imported DataObjects to sharded files + * under this prefix. If this field is empty, no output will be written. + * + * Generated from protobuf field string output_uri = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getOutputUri() + { + return $this->output_uri; + } + + /** + * Optional. URI prefix of the Cloud Storage location to write DataObject + * `IDs` and `etags` of DataObjects that were successfully imported. The + * service will write the successfully imported DataObjects to sharded files + * under this prefix. If this field is empty, no output will be written. + * + * Generated from protobuf field string output_uri = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @param string $var + * @return $this + */ + public function setOutputUri($var) + { + GPBUtil::checkString($var, True); + $this->output_uri = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ImportDataObjectsResponse.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ImportDataObjectsResponse.php new file mode 100644 index 000000000000..7509212d5269 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ImportDataObjectsResponse.php @@ -0,0 +1,78 @@ +google.cloud.vectorsearch.v1.ImportDataObjectsResponse + */ +class ImportDataObjectsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Status of the LRO + * + * Generated from protobuf field .google.rpc.Status status = 1; + */ + protected $status = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Rpc\Status $status + * Status of the LRO + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\VectorsearchService::initOnce(); + parent::__construct($data); + } + + /** + * Status of the LRO + * + * Generated from protobuf field .google.rpc.Status status = 1; + * @return \Google\Rpc\Status|null + */ + public function getStatus() + { + return $this->status; + } + + public function hasStatus() + { + return isset($this->status); + } + + public function clearStatus() + { + unset($this->status); + } + + /** + * Status of the LRO + * + * Generated from protobuf field .google.rpc.Status status = 1; + * @param \Google\Rpc\Status $var + * @return $this + */ + public function setStatus($var) + { + GPBUtil::checkMessage($var, \Google\Rpc\Status::class); + $this->status = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/Index.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/Index.php new file mode 100644 index 000000000000..4ff336fedcc6 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/Index.php @@ -0,0 +1,489 @@ +google.cloud.vectorsearch.v1.Index + */ +class Index extends \Google\Protobuf\Internal\Message +{ + /** + * Identifier. name of resource + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + */ + protected $name = ''; + /** + * Optional. User-specified display name of the index + * + * Generated from protobuf field string display_name = 8 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $display_name = ''; + /** + * Optional. User-specified description of the index + * + * Generated from protobuf field string description = 9 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $description = ''; + /** + * Optional. Labels as key value pairs. + * + * Generated from protobuf field map labels = 10 [(.google.api.field_behavior) = OPTIONAL]; + */ + private $labels; + /** + * 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. Distance metric used for indexing. If not specified, will default + * to DOT_PRODUCT. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.DistanceMetric distance_metric = 4 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $distance_metric = 0; + /** + * Required. The collection schema field to index. + * + * Generated from protobuf field string index_field = 5 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $index_field = ''; + /** + * Optional. The fields to push into the index to enable fast ANN inline + * filtering. + * + * Generated from protobuf field repeated string filter_fields = 6 [(.google.api.field_behavior) = OPTIONAL]; + */ + private $filter_fields; + /** + * Optional. The fields to push into the index to enable inline data + * retrieval. + * + * Generated from protobuf field repeated string store_fields = 7 [(.google.api.field_behavior) = OPTIONAL]; + */ + private $store_fields; + protected $infra_type; + protected $index_type; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\VectorSearch\V1\DedicatedInfrastructure $dedicated_infrastructure + * Optional. Dedicated infrastructure for the index. + * @type \Google\Cloud\VectorSearch\V1\DenseScannIndex $dense_scann + * Optional. Dense ScaNN index. + * @type string $name + * Identifier. name of resource + * @type string $display_name + * Optional. User-specified display name of the index + * @type string $description + * Optional. User-specified description of the index + * @type array|\Google\Protobuf\Internal\MapField $labels + * Optional. Labels as key value pairs. + * @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 $distance_metric + * Optional. Distance metric used for indexing. If not specified, will default + * to DOT_PRODUCT. + * @type string $index_field + * Required. The collection schema field to index. + * @type string[] $filter_fields + * Optional. The fields to push into the index to enable fast ANN inline + * filtering. + * @type string[] $store_fields + * Optional. The fields to push into the index to enable inline data + * retrieval. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\VectorsearchService::initOnce(); + parent::__construct($data); + } + + /** + * Optional. Dedicated infrastructure for the index. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.DedicatedInfrastructure dedicated_infrastructure = 11 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\VectorSearch\V1\DedicatedInfrastructure|null + */ + public function getDedicatedInfrastructure() + { + return $this->readOneof(11); + } + + public function hasDedicatedInfrastructure() + { + return $this->hasOneof(11); + } + + /** + * Optional. Dedicated infrastructure for the index. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.DedicatedInfrastructure dedicated_infrastructure = 11 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\VectorSearch\V1\DedicatedInfrastructure $var + * @return $this + */ + public function setDedicatedInfrastructure($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\DedicatedInfrastructure::class); + $this->writeOneof(11, $var); + + return $this; + } + + /** + * Optional. Dense ScaNN index. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.DenseScannIndex dense_scann = 12 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\VectorSearch\V1\DenseScannIndex|null + */ + public function getDenseScann() + { + return $this->readOneof(12); + } + + public function hasDenseScann() + { + return $this->hasOneof(12); + } + + /** + * Optional. Dense ScaNN index. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.DenseScannIndex dense_scann = 12 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\VectorSearch\V1\DenseScannIndex $var + * @return $this + */ + public function setDenseScann($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\DenseScannIndex::class); + $this->writeOneof(12, $var); + + return $this; + } + + /** + * Identifier. name of resource + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Identifier. name of resource + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; + * @param string $var + * @return $this + */ + public function setName($var) + { + GPBUtil::checkString($var, True); + $this->name = $var; + + return $this; + } + + /** + * Optional. User-specified display name of the index + * + * Generated from protobuf field string display_name = 8 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getDisplayName() + { + return $this->display_name; + } + + /** + * Optional. User-specified display name of the index + * + * Generated from protobuf field string display_name = 8 [(.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. User-specified description of the index + * + * Generated from protobuf field string description = 9 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * Optional. User-specified description of the index + * + * Generated from protobuf field string description = 9 [(.google.api.field_behavior) = OPTIONAL]; + * @param string $var + * @return $this + */ + public function setDescription($var) + { + GPBUtil::checkString($var, True); + $this->description = $var; + + return $this; + } + + /** + * Optional. Labels as key value pairs. + * + * Generated from protobuf field map labels = 10 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Protobuf\Internal\MapField + */ + public function getLabels() + { + return $this->labels; + } + + /** + * Optional. Labels as key value pairs. + * + * Generated from protobuf field map labels = 10 [(.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; + } + + /** + * 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. Distance metric used for indexing. If not specified, will default + * to DOT_PRODUCT. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.DistanceMetric distance_metric = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @return int + */ + public function getDistanceMetric() + { + return $this->distance_metric; + } + + /** + * Optional. Distance metric used for indexing. If not specified, will default + * to DOT_PRODUCT. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.DistanceMetric distance_metric = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @param int $var + * @return $this + */ + public function setDistanceMetric($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\VectorSearch\V1\DistanceMetric::class); + $this->distance_metric = $var; + + return $this; + } + + /** + * Required. The collection schema field to index. + * + * Generated from protobuf field string index_field = 5 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getIndexField() + { + return $this->index_field; + } + + /** + * Required. The collection schema field to index. + * + * Generated from protobuf field string index_field = 5 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setIndexField($var) + { + GPBUtil::checkString($var, True); + $this->index_field = $var; + + return $this; + } + + /** + * Optional. The fields to push into the index to enable fast ANN inline + * filtering. + * + * Generated from protobuf field repeated string filter_fields = 6 [(.google.api.field_behavior) = OPTIONAL]; + * @return RepeatedField + */ + public function getFilterFields() + { + return $this->filter_fields; + } + + /** + * Optional. The fields to push into the index to enable fast ANN inline + * filtering. + * + * Generated from protobuf field repeated string filter_fields = 6 [(.google.api.field_behavior) = OPTIONAL]; + * @param string[] $var + * @return $this + */ + public function setFilterFields($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->filter_fields = $arr; + + return $this; + } + + /** + * Optional. The fields to push into the index to enable inline data + * retrieval. + * + * Generated from protobuf field repeated string store_fields = 7 [(.google.api.field_behavior) = OPTIONAL]; + * @return RepeatedField + */ + public function getStoreFields() + { + return $this->store_fields; + } + + /** + * Optional. The fields to push into the index to enable inline data + * retrieval. + * + * Generated from protobuf field repeated string store_fields = 7 [(.google.api.field_behavior) = OPTIONAL]; + * @param string[] $var + * @return $this + */ + public function setStoreFields($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->store_fields = $arr; + + return $this; + } + + /** + * @return string + */ + public function getInfraType() + { + return $this->whichOneof("infra_type"); + } + + /** + * @return string + */ + public function getIndexType() + { + return $this->whichOneof("index_type"); + } + +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ListCollectionsRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ListCollectionsRequest.php new file mode 100644 index 000000000000..274dbd3cbc56 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ListCollectionsRequest.php @@ -0,0 +1,221 @@ +google.cloud.vectorsearch.v1.ListCollectionsRequest + */ +class ListCollectionsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Parent value for ListCollectionsRequest + * + * 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 ListCollectionsRequest + * Please see {@see VectorSearchServiceClient::locationName()} for help formatting this field. + * + * @return \Google\Cloud\VectorSearch\V1\ListCollectionsRequest + * + * @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 ListCollectionsRequest + * @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\Vectorsearch\V1\VectorsearchService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Parent value for ListCollectionsRequest + * + * 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 ListCollectionsRequest + * + * 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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ListCollectionsResponse.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ListCollectionsResponse.php new file mode 100644 index 000000000000..fe7602172c0a --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ListCollectionsResponse.php @@ -0,0 +1,135 @@ +google.cloud.vectorsearch.v1.ListCollectionsResponse + */ +class ListCollectionsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * The list of Collection + * + * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.Collection collections = 1; + */ + private $collections; + /** + * A token identifying a page of results the server should return. + * + * Generated from protobuf field string next_page_token = 2; + */ + protected $next_page_token = ''; + /** + * Unordered list. Locations that could not be reached. + * + * Generated from protobuf field repeated string unreachable = 3 [(.google.api.field_behavior) = UNORDERED_LIST]; + */ + private $unreachable; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\VectorSearch\V1\Collection[] $collections + * The list of Collection + * @type string $next_page_token + * A token identifying a page of results the server should return. + * @type string[] $unreachable + * Unordered list. Locations that could not be reached. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\VectorsearchService::initOnce(); + parent::__construct($data); + } + + /** + * The list of Collection + * + * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.Collection collections = 1; + * @return RepeatedField<\Google\Cloud\VectorSearch\V1\Collection> + */ + public function getCollections() + { + return $this->collections; + } + + /** + * The list of Collection + * + * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.Collection collections = 1; + * @param \Google\Cloud\VectorSearch\V1\Collection[] $var + * @return $this + */ + public function setCollections($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VectorSearch\V1\Collection::class); + $this->collections = $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; + } + + /** + * Unordered list. Locations that could not be reached. + * + * Generated from protobuf field repeated string unreachable = 3 [(.google.api.field_behavior) = UNORDERED_LIST]; + * @return RepeatedField + */ + public function getUnreachable() + { + return $this->unreachable; + } + + /** + * Unordered list. Locations that could not be reached. + * + * Generated from protobuf field repeated string unreachable = 3 [(.google.api.field_behavior) = UNORDERED_LIST]; + * @param string[] $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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ListIndexesRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ListIndexesRequest.php new file mode 100644 index 000000000000..8f0becae371a --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ListIndexesRequest.php @@ -0,0 +1,221 @@ +google.cloud.vectorsearch.v1.ListIndexesRequest + */ +class ListIndexesRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Parent value for ListIndexesRequest + * + * 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 ListIndexesRequest + * Please see {@see VectorSearchServiceClient::collectionName()} for help formatting this field. + * + * @return \Google\Cloud\VectorSearch\V1\ListIndexesRequest + * + * @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 ListIndexesRequest + * @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\Vectorsearch\V1\VectorsearchService::initOnce(); + parent::__construct($data); + } + + /** + * Required. Parent value for ListIndexesRequest + * + * 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 ListIndexesRequest + * + * 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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ListIndexesResponse.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ListIndexesResponse.php new file mode 100644 index 000000000000..48db430c005f --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ListIndexesResponse.php @@ -0,0 +1,101 @@ +google.cloud.vectorsearch.v1.ListIndexesResponse + */ +class ListIndexesResponse extends \Google\Protobuf\Internal\Message +{ + /** + * The list of Index + * + * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.Index indexes = 1; + */ + private $indexes; + /** + * 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 \Google\Cloud\VectorSearch\V1\Index[] $indexes + * The list of Index + * @type string $next_page_token + * A token identifying a page of results the server should return. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\VectorsearchService::initOnce(); + parent::__construct($data); + } + + /** + * The list of Index + * + * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.Index indexes = 1; + * @return RepeatedField<\Google\Cloud\VectorSearch\V1\Index> + */ + public function getIndexes() + { + return $this->indexes; + } + + /** + * The list of Index + * + * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.Index indexes = 1; + * @param \Google\Cloud\VectorSearch\V1\Index[] $var + * @return $this + */ + public function setIndexes($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VectorSearch\V1\Index::class); + $this->indexes = $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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/OperationMetadata.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/OperationMetadata.php new file mode 100644 index 000000000000..f8363f5cc8c1 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/OperationMetadata.php @@ -0,0 +1,311 @@ +google.cloud.vectorsearch.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 been cancelled successfully + * have + * [google.longrunning.Operation.error][google.longrunning.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 + * [google.longrunning.Operation.error][google.longrunning.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\Vectorsearch\V1\VectorsearchService::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 + * [google.longrunning.Operation.error][google.longrunning.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 + * [google.longrunning.Operation.error][google.longrunning.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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/OutputFields.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/OutputFields.php new file mode 100644 index 000000000000..8fd505929402 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/OutputFields.php @@ -0,0 +1,135 @@ +google.cloud.vectorsearch.v1.OutputFields + */ +class OutputFields extends \Google\Protobuf\Internal\Message +{ + /** + * Optional. The fields from the data fields to include in the output. + * + * Generated from protobuf field repeated string data_fields = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + private $data_fields; + /** + * Optional. The fields from the vector fields to include in the output. + * + * Generated from protobuf field repeated string vector_fields = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + private $vector_fields; + /** + * Optional. The fields from the DataObject metadata to include in the output. + * + * Generated from protobuf field repeated string metadata_fields = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + private $metadata_fields; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string[] $data_fields + * Optional. The fields from the data fields to include in the output. + * @type string[] $vector_fields + * Optional. The fields from the vector fields to include in the output. + * @type string[] $metadata_fields + * Optional. The fields from the DataObject metadata to include in the output. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectSearchService::initOnce(); + parent::__construct($data); + } + + /** + * Optional. The fields from the data fields to include in the output. + * + * Generated from protobuf field repeated string data_fields = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @return RepeatedField + */ + public function getDataFields() + { + return $this->data_fields; + } + + /** + * Optional. The fields from the data fields to include in the output. + * + * Generated from protobuf field repeated string data_fields = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @param string[] $var + * @return $this + */ + public function setDataFields($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->data_fields = $arr; + + return $this; + } + + /** + * Optional. The fields from the vector fields to include in the output. + * + * Generated from protobuf field repeated string vector_fields = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return RepeatedField + */ + public function getVectorFields() + { + return $this->vector_fields; + } + + /** + * Optional. The fields from the vector fields to include in the output. + * + * Generated from protobuf field repeated string vector_fields = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @param string[] $var + * @return $this + */ + public function setVectorFields($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->vector_fields = $arr; + + return $this; + } + + /** + * Optional. The fields from the DataObject metadata to include in the output. + * + * Generated from protobuf field repeated string metadata_fields = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return RepeatedField + */ + public function getMetadataFields() + { + return $this->metadata_fields; + } + + /** + * Optional. The fields from the DataObject metadata to include in the output. + * + * Generated from protobuf field repeated string metadata_fields = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @param string[] $var + * @return $this + */ + public function setMetadataFields($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->metadata_fields = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/QueryDataObjectsRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/QueryDataObjectsRequest.php new file mode 100644 index 000000000000..3541cbbd21d5 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/QueryDataObjectsRequest.php @@ -0,0 +1,256 @@ +google.cloud.vectorsearch.v1.QueryDataObjectsRequest + */ +class QueryDataObjectsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the Collection for which to query. + * Format: `projects/{project}/locations/{location}/collections/{collection}` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Optional. A JSON filter expression, e.g. {"genre": {"$eq": "sci-fi"}}, + * represented as a google.protobuf.Struct. + * + * Generated from protobuf field .google.protobuf.Struct filter = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $filter = null; + /** + * Optional. Mask specifying which fields to return. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.OutputFields output_fields = 7 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $output_fields = null; + /** + * Optional. The standard list page size. Default is 100. + * The maximum value is 1000; values above 1000 will be coerced to 1000. + * + * Generated from protobuf field int32 page_size = 5 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $page_size = 0; + /** + * Optional. The standard list page token. + * Typically obtained via + * [QueryDataObjectsResponse.next_page_token][google.cloud.vectorsearch.v1.QueryDataObjectsResponse.next_page_token] + * of the previous + * [DataObjectSearchService.QueryDataObjects][google.cloud.vectorsearch.v1.DataObjectSearchService.QueryDataObjects] + * call. + * + * Generated from protobuf field string page_token = 6 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $page_token = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. The resource name of the Collection for which to query. + * Format: `projects/{project}/locations/{location}/collections/{collection}` + * @type \Google\Protobuf\Struct $filter + * Optional. A JSON filter expression, e.g. {"genre": {"$eq": "sci-fi"}}, + * represented as a google.protobuf.Struct. + * @type \Google\Cloud\VectorSearch\V1\OutputFields $output_fields + * Optional. Mask specifying which fields to return. + * @type int $page_size + * Optional. The standard list page size. Default is 100. + * The maximum value is 1000; values above 1000 will be coerced to 1000. + * @type string $page_token + * Optional. The standard list page token. + * Typically obtained via + * [QueryDataObjectsResponse.next_page_token][google.cloud.vectorsearch.v1.QueryDataObjectsResponse.next_page_token] + * of the previous + * [DataObjectSearchService.QueryDataObjects][google.cloud.vectorsearch.v1.DataObjectSearchService.QueryDataObjects] + * call. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectSearchService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the Collection for which to query. + * Format: `projects/{project}/locations/{location}/collections/{collection}` + * + * 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 Collection for which to query. + * Format: `projects/{project}/locations/{location}/collections/{collection}` + * + * 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. A JSON filter expression, e.g. {"genre": {"$eq": "sci-fi"}}, + * represented as a google.protobuf.Struct. + * + * Generated from protobuf field .google.protobuf.Struct filter = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Protobuf\Struct|null + */ + public function getFilter() + { + return $this->filter; + } + + public function hasFilter() + { + return isset($this->filter); + } + + public function clearFilter() + { + unset($this->filter); + } + + /** + * Optional. A JSON filter expression, e.g. {"genre": {"$eq": "sci-fi"}}, + * represented as a google.protobuf.Struct. + * + * Generated from protobuf field .google.protobuf.Struct filter = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Protobuf\Struct $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Struct::class); + $this->filter = $var; + + return $this; + } + + /** + * Optional. Mask specifying which fields to return. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.OutputFields output_fields = 7 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\VectorSearch\V1\OutputFields|null + */ + public function getOutputFields() + { + return $this->output_fields; + } + + public function hasOutputFields() + { + return isset($this->output_fields); + } + + public function clearOutputFields() + { + unset($this->output_fields); + } + + /** + * Optional. Mask specifying which fields to return. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.OutputFields output_fields = 7 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\VectorSearch\V1\OutputFields $var + * @return $this + */ + public function setOutputFields($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\OutputFields::class); + $this->output_fields = $var; + + return $this; + } + + /** + * Optional. The standard list page size. Default is 100. + * The maximum value is 1000; values above 1000 will be coerced to 1000. + * + * Generated from protobuf field int32 page_size = 5 [(.google.api.field_behavior) = OPTIONAL]; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * Optional. The standard list page size. Default is 100. + * The maximum value is 1000; values above 1000 will be coerced to 1000. + * + * Generated from protobuf field int32 page_size = 5 [(.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 standard list page token. + * Typically obtained via + * [QueryDataObjectsResponse.next_page_token][google.cloud.vectorsearch.v1.QueryDataObjectsResponse.next_page_token] + * of the previous + * [DataObjectSearchService.QueryDataObjects][google.cloud.vectorsearch.v1.DataObjectSearchService.QueryDataObjects] + * call. + * + * Generated from protobuf field string page_token = 6 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * Optional. The standard list page token. + * Typically obtained via + * [QueryDataObjectsResponse.next_page_token][google.cloud.vectorsearch.v1.QueryDataObjectsResponse.next_page_token] + * of the previous + * [DataObjectSearchService.QueryDataObjects][google.cloud.vectorsearch.v1.DataObjectSearchService.QueryDataObjects] + * call. + * + * Generated from protobuf field string page_token = 6 [(.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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/QueryDataObjectsResponse.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/QueryDataObjectsResponse.php new file mode 100644 index 000000000000..4e90b7849c2d --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/QueryDataObjectsResponse.php @@ -0,0 +1,110 @@ +google.cloud.vectorsearch.v1.QueryDataObjectsResponse + */ +class QueryDataObjectsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. The list of dataObjects that match the query. + * + * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.DataObject data_objects = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + private $data_objects; + /** + * Output only. A token to retrieve next page of results. + * Pass to [DataObjectSearchService.QueryDataObjectsRequest.page_token][] to + * obtain that page. + * + * Generated from protobuf field string next_page_token = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $next_page_token = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\VectorSearch\V1\DataObject[] $data_objects + * Output only. The list of dataObjects that match the query. + * @type string $next_page_token + * Output only. A token to retrieve next page of results. + * Pass to [DataObjectSearchService.QueryDataObjectsRequest.page_token][] to + * obtain that page. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectSearchService::initOnce(); + parent::__construct($data); + } + + /** + * Output only. The list of dataObjects that match the query. + * + * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.DataObject data_objects = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return RepeatedField<\Google\Cloud\VectorSearch\V1\DataObject> + */ + public function getDataObjects() + { + return $this->data_objects; + } + + /** + * Output only. The list of dataObjects that match the query. + * + * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.DataObject data_objects = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Cloud\VectorSearch\V1\DataObject[] $var + * @return $this + */ + public function setDataObjects($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VectorSearch\V1\DataObject::class); + $this->data_objects = $arr; + + return $this; + } + + /** + * Output only. A token to retrieve next page of results. + * Pass to [DataObjectSearchService.QueryDataObjectsRequest.page_token][] to + * obtain that page. + * + * Generated from protobuf field string next_page_token = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * Output only. A token to retrieve next page of results. + * Pass to [DataObjectSearchService.QueryDataObjectsRequest.page_token][] to + * obtain that page. + * + * Generated from protobuf field string next_page_token = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/Ranker.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/Ranker.php new file mode 100644 index 000000000000..a0aa74f03057 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/Ranker.php @@ -0,0 +1,75 @@ +google.cloud.vectorsearch.v1.Ranker + */ +class Ranker extends \Google\Protobuf\Internal\Message +{ + protected $ranker; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\VectorSearch\V1\ReciprocalRankFusion $rrf + * Reciprocal Rank Fusion ranking. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectSearchService::initOnce(); + parent::__construct($data); + } + + /** + * Reciprocal Rank Fusion ranking. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.ReciprocalRankFusion rrf = 1; + * @return \Google\Cloud\VectorSearch\V1\ReciprocalRankFusion|null + */ + public function getRrf() + { + return $this->readOneof(1); + } + + public function hasRrf() + { + return $this->hasOneof(1); + } + + /** + * Reciprocal Rank Fusion ranking. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.ReciprocalRankFusion rrf = 1; + * @param \Google\Cloud\VectorSearch\V1\ReciprocalRankFusion $var + * @return $this + */ + public function setRrf($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\ReciprocalRankFusion::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * @return string + */ + public function getRanker() + { + return $this->whichOneof("ranker"); + } + +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ReciprocalRankFusion.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ReciprocalRankFusion.php new file mode 100644 index 000000000000..9d529790eaca --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ReciprocalRankFusion.php @@ -0,0 +1,67 @@ +google.cloud.vectorsearch.v1.ReciprocalRankFusion + */ +class ReciprocalRankFusion extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The weights to apply to each search result set during fusion. + * + * Generated from protobuf field repeated double weights = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + private $weights; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type float[] $weights + * Required. The weights to apply to each search result set during fusion. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectSearchService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The weights to apply to each search result set during fusion. + * + * Generated from protobuf field repeated double weights = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return RepeatedField + */ + public function getWeights() + { + return $this->weights; + } + + /** + * Required. The weights to apply to each search result set during fusion. + * + * Generated from protobuf field repeated double weights = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param float[] $var + * @return $this + */ + public function setWeights($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::DOUBLE); + $this->weights = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/Search.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/Search.php new file mode 100644 index 000000000000..911a22fc617a --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/Search.php @@ -0,0 +1,141 @@ +google.cloud.vectorsearch.v1.Search + */ +class Search extends \Google\Protobuf\Internal\Message +{ + protected $search_type; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\VectorSearch\V1\VectorSearch $vector_search + * A vector-based search. + * @type \Google\Cloud\VectorSearch\V1\SemanticSearch $semantic_search + * A semantic search. + * @type \Google\Cloud\VectorSearch\V1\TextSearch $text_search + * A text search operation. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectSearchService::initOnce(); + parent::__construct($data); + } + + /** + * A vector-based search. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.VectorSearch vector_search = 1; + * @return \Google\Cloud\VectorSearch\V1\VectorSearch|null + */ + public function getVectorSearch() + { + return $this->readOneof(1); + } + + public function hasVectorSearch() + { + return $this->hasOneof(1); + } + + /** + * A vector-based search. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.VectorSearch vector_search = 1; + * @param \Google\Cloud\VectorSearch\V1\VectorSearch $var + * @return $this + */ + public function setVectorSearch($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\VectorSearch::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * A semantic search. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.SemanticSearch semantic_search = 2; + * @return \Google\Cloud\VectorSearch\V1\SemanticSearch|null + */ + public function getSemanticSearch() + { + return $this->readOneof(2); + } + + public function hasSemanticSearch() + { + return $this->hasOneof(2); + } + + /** + * A semantic search. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.SemanticSearch semantic_search = 2; + * @param \Google\Cloud\VectorSearch\V1\SemanticSearch $var + * @return $this + */ + public function setSemanticSearch($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\SemanticSearch::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * A text search operation. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.TextSearch text_search = 3; + * @return \Google\Cloud\VectorSearch\V1\TextSearch|null + */ + public function getTextSearch() + { + return $this->readOneof(3); + } + + public function hasTextSearch() + { + return $this->hasOneof(3); + } + + /** + * A text search operation. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.TextSearch text_search = 3; + * @param \Google\Cloud\VectorSearch\V1\TextSearch $var + * @return $this + */ + public function setTextSearch($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\TextSearch::class); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * @return string + */ + public function getSearchType() + { + return $this->whichOneof("search_type"); + } + +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchDataObjectsRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchDataObjectsRequest.php new file mode 100644 index 000000000000..d8b0cb20dfe5 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchDataObjectsRequest.php @@ -0,0 +1,275 @@ +google.cloud.vectorsearch.v1.SearchDataObjectsRequest + */ +class SearchDataObjectsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the Collection for which to search. + * Format: `projects/{project}/locations/{location}/collections/{collection}` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Optional. The standard list page size. Only supported for KNN. If not set, + * up to search_type.top_k results will be returned. The maximum value is + * 1000; values above 1000 will be coerced to 1000. + * + * Generated from protobuf field int32 page_size = 5 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $page_size = 0; + /** + * Optional. The standard list page token. + * Typically obtained via + * [SearchDataObjectsResponse.next_page_token][google.cloud.vectorsearch.v1.SearchDataObjectsResponse.next_page_token] + * of the previous + * [DataObjectSearchService.SearchDataObjects][google.cloud.vectorsearch.v1.DataObjectSearchService.SearchDataObjects] + * call. + * + * Generated from protobuf field string page_token = 6 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $page_token = ''; + protected $search_type; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\VectorSearch\V1\VectorSearch $vector_search + * A vector search operation. + * @type \Google\Cloud\VectorSearch\V1\SemanticSearch $semantic_search + * A semantic search operation. + * @type \Google\Cloud\VectorSearch\V1\TextSearch $text_search + * Optional. A text search operation. + * @type string $parent + * Required. The resource name of the Collection for which to search. + * Format: `projects/{project}/locations/{location}/collections/{collection}` + * @type int $page_size + * Optional. The standard list page size. Only supported for KNN. If not set, + * up to search_type.top_k results will be returned. The maximum value is + * 1000; values above 1000 will be coerced to 1000. + * @type string $page_token + * Optional. The standard list page token. + * Typically obtained via + * [SearchDataObjectsResponse.next_page_token][google.cloud.vectorsearch.v1.SearchDataObjectsResponse.next_page_token] + * of the previous + * [DataObjectSearchService.SearchDataObjects][google.cloud.vectorsearch.v1.DataObjectSearchService.SearchDataObjects] + * call. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectSearchService::initOnce(); + parent::__construct($data); + } + + /** + * A vector search operation. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.VectorSearch vector_search = 2; + * @return \Google\Cloud\VectorSearch\V1\VectorSearch|null + */ + public function getVectorSearch() + { + return $this->readOneof(2); + } + + public function hasVectorSearch() + { + return $this->hasOneof(2); + } + + /** + * A vector search operation. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.VectorSearch vector_search = 2; + * @param \Google\Cloud\VectorSearch\V1\VectorSearch $var + * @return $this + */ + public function setVectorSearch($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\VectorSearch::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * A semantic search operation. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.SemanticSearch semantic_search = 4; + * @return \Google\Cloud\VectorSearch\V1\SemanticSearch|null + */ + public function getSemanticSearch() + { + return $this->readOneof(4); + } + + public function hasSemanticSearch() + { + return $this->hasOneof(4); + } + + /** + * A semantic search operation. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.SemanticSearch semantic_search = 4; + * @param \Google\Cloud\VectorSearch\V1\SemanticSearch $var + * @return $this + */ + public function setSemanticSearch($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\SemanticSearch::class); + $this->writeOneof(4, $var); + + return $this; + } + + /** + * Optional. A text search operation. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.TextSearch text_search = 7 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\VectorSearch\V1\TextSearch|null + */ + public function getTextSearch() + { + return $this->readOneof(7); + } + + public function hasTextSearch() + { + return $this->hasOneof(7); + } + + /** + * Optional. A text search operation. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.TextSearch text_search = 7 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\VectorSearch\V1\TextSearch $var + * @return $this + */ + public function setTextSearch($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\TextSearch::class); + $this->writeOneof(7, $var); + + return $this; + } + + /** + * Required. The resource name of the Collection for which to search. + * Format: `projects/{project}/locations/{location}/collections/{collection}` + * + * 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 Collection for which to search. + * Format: `projects/{project}/locations/{location}/collections/{collection}` + * + * 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 standard list page size. Only supported for KNN. If not set, + * up to search_type.top_k results will be returned. The maximum value is + * 1000; values above 1000 will be coerced to 1000. + * + * Generated from protobuf field int32 page_size = 5 [(.google.api.field_behavior) = OPTIONAL]; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * Optional. The standard list page size. Only supported for KNN. If not set, + * up to search_type.top_k results will be returned. The maximum value is + * 1000; values above 1000 will be coerced to 1000. + * + * Generated from protobuf field int32 page_size = 5 [(.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 standard list page token. + * Typically obtained via + * [SearchDataObjectsResponse.next_page_token][google.cloud.vectorsearch.v1.SearchDataObjectsResponse.next_page_token] + * of the previous + * [DataObjectSearchService.SearchDataObjects][google.cloud.vectorsearch.v1.DataObjectSearchService.SearchDataObjects] + * call. + * + * Generated from protobuf field string page_token = 6 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * Optional. The standard list page token. + * Typically obtained via + * [SearchDataObjectsResponse.next_page_token][google.cloud.vectorsearch.v1.SearchDataObjectsResponse.next_page_token] + * of the previous + * [DataObjectSearchService.SearchDataObjects][google.cloud.vectorsearch.v1.DataObjectSearchService.SearchDataObjects] + * call. + * + * Generated from protobuf field string page_token = 6 [(.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 getSearchType() + { + return $this->whichOneof("search_type"); + } + +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchDataObjectsResponse.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchDataObjectsResponse.php new file mode 100644 index 000000000000..72f03ef01dc2 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchDataObjectsResponse.php @@ -0,0 +1,109 @@ +google.cloud.vectorsearch.v1.SearchDataObjectsResponse + */ +class SearchDataObjectsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. The list of dataObjects that match the search criteria. + * + * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.SearchResult results = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + private $results; + /** + * Output only. A token to retrieve next page of results. + * Pass to [DataObjectSearchService.SearchDataObjectsRequest.page_token][] to + * obtain that page. + * + * Generated from protobuf field string next_page_token = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $next_page_token = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\VectorSearch\V1\SearchResult[] $results + * Output only. The list of dataObjects that match the search criteria. + * @type string $next_page_token + * Output only. A token to retrieve next page of results. + * Pass to [DataObjectSearchService.SearchDataObjectsRequest.page_token][] to + * obtain that page. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectSearchService::initOnce(); + parent::__construct($data); + } + + /** + * Output only. The list of dataObjects that match the search criteria. + * + * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.SearchResult results = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return RepeatedField<\Google\Cloud\VectorSearch\V1\SearchResult> + */ + public function getResults() + { + return $this->results; + } + + /** + * Output only. The list of dataObjects that match the search criteria. + * + * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.SearchResult results = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Cloud\VectorSearch\V1\SearchResult[] $var + * @return $this + */ + public function setResults($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VectorSearch\V1\SearchResult::class); + $this->results = $arr; + + return $this; + } + + /** + * Output only. A token to retrieve next page of results. + * Pass to [DataObjectSearchService.SearchDataObjectsRequest.page_token][] to + * obtain that page. + * + * Generated from protobuf field string next_page_token = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getNextPageToken() + { + return $this->next_page_token; + } + + /** + * Output only. A token to retrieve next page of results. + * Pass to [DataObjectSearchService.SearchDataObjectsRequest.page_token][] to + * obtain that page. + * + * Generated from protobuf field string next_page_token = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchHint.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchHint.php new file mode 100644 index 000000000000..5ed0fb6d89b6 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchHint.php @@ -0,0 +1,111 @@ +google.cloud.vectorsearch.v1.SearchHint + */ +class SearchHint extends \Google\Protobuf\Internal\Message +{ + protected $index_type; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\VectorSearch\V1\SearchHint\KnnHint $knn_hint + * Optional. If set, the search will use the system's default + * K-Nearest Neighbor (KNN) index engine. + * @type \Google\Cloud\VectorSearch\V1\SearchHint\IndexHint $index_hint + * Optional. Specifies that the search should use a particular index. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectSearchService::initOnce(); + parent::__construct($data); + } + + /** + * Optional. If set, the search will use the system's default + * K-Nearest Neighbor (KNN) index engine. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.SearchHint.KnnHint knn_hint = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\VectorSearch\V1\SearchHint\KnnHint|null + */ + public function getKnnHint() + { + return $this->readOneof(3); + } + + public function hasKnnHint() + { + return $this->hasOneof(3); + } + + /** + * Optional. If set, the search will use the system's default + * K-Nearest Neighbor (KNN) index engine. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.SearchHint.KnnHint knn_hint = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\VectorSearch\V1\SearchHint\KnnHint $var + * @return $this + */ + public function setKnnHint($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\SearchHint\KnnHint::class); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * Optional. Specifies that the search should use a particular index. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.SearchHint.IndexHint index_hint = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\VectorSearch\V1\SearchHint\IndexHint|null + */ + public function getIndexHint() + { + return $this->readOneof(4); + } + + public function hasIndexHint() + { + return $this->hasOneof(4); + } + + /** + * Optional. Specifies that the search should use a particular index. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.SearchHint.IndexHint index_hint = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\VectorSearch\V1\SearchHint\IndexHint $var + * @return $this + */ + public function setIndexHint($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\SearchHint\IndexHint::class); + $this->writeOneof(4, $var); + + return $this; + } + + /** + * @return string + */ + public function getIndexType() + { + return $this->whichOneof("index_type"); + } + +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchHint/IndexHint.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchHint/IndexHint.php new file mode 100644 index 000000000000..e002e515f974 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchHint/IndexHint.php @@ -0,0 +1,79 @@ +google.cloud.vectorsearch.v1.SearchHint.IndexHint + */ +class IndexHint extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the index to use for the search. + * The index must be in the same project, location, and collection. + * Format: + * `projects/{project}/locations/{location}/collections/{collection}/indexes/{index}` + * + * 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 index to use for the search. + * The index must be in the same project, location, and collection. + * Format: + * `projects/{project}/locations/{location}/collections/{collection}/indexes/{index}` + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectSearchService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the index to use for the search. + * The index must be in the same project, location, and collection. + * Format: + * `projects/{project}/locations/{location}/collections/{collection}/indexes/{index}` + * + * 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 index to use for the search. + * The index must be in the same project, location, and collection. + * Format: + * `projects/{project}/locations/{location}/collections/{collection}/indexes/{index}` + * + * 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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchHint/KnnHint.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchHint/KnnHint.php new file mode 100644 index 000000000000..0253c90e18ef --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchHint/KnnHint.php @@ -0,0 +1,34 @@ +google.cloud.vectorsearch.v1.SearchHint.KnnHint + */ +class KnnHint extends \Google\Protobuf\Internal\Message +{ + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectSearchService::initOnce(); + parent::__construct($data); + } + +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchResult.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchResult.php new file mode 100644 index 000000000000..12f1790ab082 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchResult.php @@ -0,0 +1,125 @@ +google.cloud.vectorsearch.v1.SearchResult + */ +class SearchResult extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. The matching data object. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.DataObject data_object = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $data_object = null; + /** + * Output only. Similarity distance or ranker score returned by + * BatchSearchDataObjects. + * + * Generated from protobuf field optional double distance = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $distance = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\VectorSearch\V1\DataObject $data_object + * Output only. The matching data object. + * @type float $distance + * Output only. Similarity distance or ranker score returned by + * BatchSearchDataObjects. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectSearchService::initOnce(); + parent::__construct($data); + } + + /** + * Output only. The matching data object. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.DataObject data_object = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Cloud\VectorSearch\V1\DataObject|null + */ + public function getDataObject() + { + return $this->data_object; + } + + public function hasDataObject() + { + return isset($this->data_object); + } + + public function clearDataObject() + { + unset($this->data_object); + } + + /** + * Output only. The matching data object. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.DataObject data_object = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Cloud\VectorSearch\V1\DataObject $var + * @return $this + */ + public function setDataObject($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\DataObject::class); + $this->data_object = $var; + + return $this; + } + + /** + * Output only. Similarity distance or ranker score returned by + * BatchSearchDataObjects. + * + * Generated from protobuf field optional double distance = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return float + */ + public function getDistance() + { + return isset($this->distance) ? $this->distance : 0.0; + } + + public function hasDistance() + { + return isset($this->distance); + } + + public function clearDistance() + { + unset($this->distance); + } + + /** + * Output only. Similarity distance or ranker score returned by + * BatchSearchDataObjects. + * + * Generated from protobuf field optional double distance = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param float $var + * @return $this + */ + public function setDistance($var) + { + GPBUtil::checkDouble($var); + $this->distance = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SemanticSearch.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SemanticSearch.php new file mode 100644 index 000000000000..4dfdde9fb02e --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SemanticSearch.php @@ -0,0 +1,327 @@ +google.cloud.vectorsearch.v1.SemanticSearch + */ +class SemanticSearch extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The query text, which is used to generate an embedding according + * to the embedding model specified in the collection config. + * + * Generated from protobuf field string search_text = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $search_text = ''; + /** + * Required. The vector field to search. + * + * Generated from protobuf field string search_field = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $search_field = ''; + /** + * Required. The task type of the query embedding. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.EmbeddingTaskType task_type = 5 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $task_type = 0; + /** + * Optional. The fields to return in the search results. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.OutputFields output_fields = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $output_fields = null; + /** + * Optional. A JSON filter expression, e.g. {"genre": {"$eq": "sci-fi"}}, + * represented as a google.protobuf.Struct. + * + * Generated from protobuf field .google.protobuf.Struct filter = 6 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $filter = null; + /** + * Optional. The number of data objects to return. + * + * Generated from protobuf field optional int32 top_k = 4 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $top_k = null; + /** + * Optional. Sets the search hint. If no strategy is specified, the service + * will use an index if one is available, and fall back to KNN search + * otherwise. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.SearchHint search_hint = 7 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $search_hint = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $search_text + * Required. The query text, which is used to generate an embedding according + * to the embedding model specified in the collection config. + * @type string $search_field + * Required. The vector field to search. + * @type int $task_type + * Required. The task type of the query embedding. + * @type \Google\Cloud\VectorSearch\V1\OutputFields $output_fields + * Optional. The fields to return in the search results. + * @type \Google\Protobuf\Struct $filter + * Optional. A JSON filter expression, e.g. {"genre": {"$eq": "sci-fi"}}, + * represented as a google.protobuf.Struct. + * @type int $top_k + * Optional. The number of data objects to return. + * @type \Google\Cloud\VectorSearch\V1\SearchHint $search_hint + * Optional. Sets the search hint. If no strategy is specified, the service + * will use an index if one is available, and fall back to KNN search + * otherwise. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectSearchService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The query text, which is used to generate an embedding according + * to the embedding model specified in the collection config. + * + * Generated from protobuf field string search_text = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getSearchText() + { + return $this->search_text; + } + + /** + * Required. The query text, which is used to generate an embedding according + * to the embedding model specified in the collection config. + * + * Generated from protobuf field string search_text = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setSearchText($var) + { + GPBUtil::checkString($var, True); + $this->search_text = $var; + + return $this; + } + + /** + * Required. The vector field to search. + * + * Generated from protobuf field string search_field = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getSearchField() + { + return $this->search_field; + } + + /** + * Required. The vector field to search. + * + * Generated from protobuf field string search_field = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setSearchField($var) + { + GPBUtil::checkString($var, True); + $this->search_field = $var; + + return $this; + } + + /** + * Required. The task type of the query embedding. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.EmbeddingTaskType task_type = 5 [(.google.api.field_behavior) = REQUIRED]; + * @return int + */ + public function getTaskType() + { + return $this->task_type; + } + + /** + * Required. The task type of the query embedding. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.EmbeddingTaskType task_type = 5 [(.google.api.field_behavior) = REQUIRED]; + * @param int $var + * @return $this + */ + public function setTaskType($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\VectorSearch\V1\EmbeddingTaskType::class); + $this->task_type = $var; + + return $this; + } + + /** + * Optional. The fields to return in the search results. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.OutputFields output_fields = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\VectorSearch\V1\OutputFields|null + */ + public function getOutputFields() + { + return $this->output_fields; + } + + public function hasOutputFields() + { + return isset($this->output_fields); + } + + public function clearOutputFields() + { + unset($this->output_fields); + } + + /** + * Optional. The fields to return in the search results. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.OutputFields output_fields = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\VectorSearch\V1\OutputFields $var + * @return $this + */ + public function setOutputFields($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\OutputFields::class); + $this->output_fields = $var; + + return $this; + } + + /** + * Optional. A JSON filter expression, e.g. {"genre": {"$eq": "sci-fi"}}, + * represented as a google.protobuf.Struct. + * + * Generated from protobuf field .google.protobuf.Struct filter = 6 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Protobuf\Struct|null + */ + public function getFilter() + { + return $this->filter; + } + + public function hasFilter() + { + return isset($this->filter); + } + + public function clearFilter() + { + unset($this->filter); + } + + /** + * Optional. A JSON filter expression, e.g. {"genre": {"$eq": "sci-fi"}}, + * represented as a google.protobuf.Struct. + * + * Generated from protobuf field .google.protobuf.Struct filter = 6 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Protobuf\Struct $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Struct::class); + $this->filter = $var; + + return $this; + } + + /** + * Optional. The number of data objects to return. + * + * Generated from protobuf field optional int32 top_k = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @return int + */ + public function getTopK() + { + return isset($this->top_k) ? $this->top_k : 0; + } + + public function hasTopK() + { + return isset($this->top_k); + } + + public function clearTopK() + { + unset($this->top_k); + } + + /** + * Optional. The number of data objects to return. + * + * Generated from protobuf field optional int32 top_k = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @param int $var + * @return $this + */ + public function setTopK($var) + { + GPBUtil::checkInt32($var); + $this->top_k = $var; + + return $this; + } + + /** + * Optional. Sets the search hint. If no strategy is specified, the service + * will use an index if one is available, and fall back to KNN search + * otherwise. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.SearchHint search_hint = 7 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\VectorSearch\V1\SearchHint|null + */ + public function getSearchHint() + { + return $this->search_hint; + } + + public function hasSearchHint() + { + return isset($this->search_hint); + } + + public function clearSearchHint() + { + unset($this->search_hint); + } + + /** + * Optional. Sets the search hint. If no strategy is specified, the service + * will use an index if one is available, and fall back to KNN search + * otherwise. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.SearchHint search_hint = 7 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\VectorSearch\V1\SearchHint $var + * @return $this + */ + public function setSearchHint($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\SearchHint::class); + $this->search_hint = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SparseVector.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SparseVector.php new file mode 100644 index 000000000000..21af72420f0c --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SparseVector.php @@ -0,0 +1,101 @@ +google.cloud.vectorsearch.v1.SparseVector + */ +class SparseVector extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The values of the vector. + * + * Generated from protobuf field repeated float values = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + private $values; + /** + * Required. The corresponding indices for the values. + * + * Generated from protobuf field repeated int32 indices = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + private $indices; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type float[] $values + * Required. The values of the vector. + * @type int[] $indices + * Required. The corresponding indices for the values. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObject::initOnce(); + parent::__construct($data); + } + + /** + * Required. The values of the vector. + * + * Generated from protobuf field repeated float values = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return RepeatedField + */ + public function getValues() + { + return $this->values; + } + + /** + * Required. The values of the vector. + * + * Generated from protobuf field repeated float values = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param float[] $var + * @return $this + */ + public function setValues($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::FLOAT); + $this->values = $arr; + + return $this; + } + + /** + * Required. The corresponding indices for the values. + * + * Generated from protobuf field repeated int32 indices = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return RepeatedField + */ + public function getIndices() + { + return $this->indices; + } + + /** + * Required. The corresponding indices for the values. + * + * Generated from protobuf field repeated int32 indices = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param int[] $var + * @return $this + */ + public function setIndices($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::INT32); + $this->indices = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SparseVectorField.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SparseVectorField.php new file mode 100644 index 000000000000..65c8ffdbca52 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SparseVectorField.php @@ -0,0 +1,33 @@ +google.cloud.vectorsearch.v1.SparseVectorField + */ +class SparseVectorField extends \Google\Protobuf\Internal\Message +{ + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\VectorsearchService::initOnce(); + parent::__construct($data); + } + +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/TextSearch.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/TextSearch.php new file mode 100644 index 000000000000..60bd53821ac3 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/TextSearch.php @@ -0,0 +1,237 @@ +google.cloud.vectorsearch.v1.TextSearch + */ +class TextSearch extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The query text. + * + * Generated from protobuf field string search_text = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $search_text = ''; + /** + * Required. The data field names to search. + * + * Generated from protobuf field repeated string data_field_names = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + private $data_field_names; + /** + * Optional. The fields to return in the search results. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.OutputFields output_fields = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $output_fields = null; + /** + * Optional. The number of results to return. + * + * Generated from protobuf field optional int32 top_k = 4 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $top_k = null; + /** + * Optional. A JSON filter expression, e.g. `{"genre": {"$eq": "sci-fi"}}`, + * represented as a `google.protobuf.Struct`. + * + * Generated from protobuf field .google.protobuf.Struct filter = 5 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $filter = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $search_text + * Required. The query text. + * @type string[] $data_field_names + * Required. The data field names to search. + * @type \Google\Cloud\VectorSearch\V1\OutputFields $output_fields + * Optional. The fields to return in the search results. + * @type int $top_k + * Optional. The number of results to return. + * @type \Google\Protobuf\Struct $filter + * Optional. A JSON filter expression, e.g. `{"genre": {"$eq": "sci-fi"}}`, + * represented as a `google.protobuf.Struct`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectSearchService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The query text. + * + * Generated from protobuf field string search_text = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getSearchText() + { + return $this->search_text; + } + + /** + * Required. The query text. + * + * Generated from protobuf field string search_text = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setSearchText($var) + { + GPBUtil::checkString($var, True); + $this->search_text = $var; + + return $this; + } + + /** + * Required. The data field names to search. + * + * Generated from protobuf field repeated string data_field_names = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return RepeatedField + */ + public function getDataFieldNames() + { + return $this->data_field_names; + } + + /** + * Required. The data field names to search. + * + * Generated from protobuf field repeated string data_field_names = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param string[] $var + * @return $this + */ + public function setDataFieldNames($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->data_field_names = $arr; + + return $this; + } + + /** + * Optional. The fields to return in the search results. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.OutputFields output_fields = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\VectorSearch\V1\OutputFields|null + */ + public function getOutputFields() + { + return $this->output_fields; + } + + public function hasOutputFields() + { + return isset($this->output_fields); + } + + public function clearOutputFields() + { + unset($this->output_fields); + } + + /** + * Optional. The fields to return in the search results. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.OutputFields output_fields = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\VectorSearch\V1\OutputFields $var + * @return $this + */ + public function setOutputFields($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\OutputFields::class); + $this->output_fields = $var; + + return $this; + } + + /** + * Optional. The number of results to return. + * + * Generated from protobuf field optional int32 top_k = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @return int + */ + public function getTopK() + { + return isset($this->top_k) ? $this->top_k : 0; + } + + public function hasTopK() + { + return isset($this->top_k); + } + + public function clearTopK() + { + unset($this->top_k); + } + + /** + * Optional. The number of results to return. + * + * Generated from protobuf field optional int32 top_k = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @param int $var + * @return $this + */ + public function setTopK($var) + { + GPBUtil::checkInt32($var); + $this->top_k = $var; + + return $this; + } + + /** + * Optional. A JSON filter expression, e.g. `{"genre": {"$eq": "sci-fi"}}`, + * represented as a `google.protobuf.Struct`. + * + * Generated from protobuf field .google.protobuf.Struct filter = 5 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Protobuf\Struct|null + */ + public function getFilter() + { + return $this->filter; + } + + public function hasFilter() + { + return isset($this->filter); + } + + public function clearFilter() + { + unset($this->filter); + } + + /** + * Optional. A JSON filter expression, e.g. `{"genre": {"$eq": "sci-fi"}}`, + * represented as a `google.protobuf.Struct`. + * + * Generated from protobuf field .google.protobuf.Struct filter = 5 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Protobuf\Struct $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Struct::class); + $this->filter = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/UpdateCollectionRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/UpdateCollectionRequest.php new file mode 100644 index 000000000000..2aa5781afe3c --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/UpdateCollectionRequest.php @@ -0,0 +1,282 @@ +google.cloud.vectorsearch.v1.UpdateCollectionRequest + */ +class UpdateCollectionRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Optional. Field mask is used to specify the fields to be overwritten in the + * Collection 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 present in the request will be + * overwritten. + * The following fields support update: `display_name`, `description`, + * `labels`, `data_schema`, `vector_schema`. + * For `data_schema` and `vector_schema`, fields can only be added, not + * deleted, but `vertex_embedding_config` in `vector_schema` can be added or + * removed. + * Partial updates for `data_schema` and `vector_schema` are also supported + * by using sub-field paths in `update_mask`, e.g. + * `data_schema.properties.foo` or `vector_schema.my_vector_field`. + * If `*` is provided in the update_mask, full replacement will be performed. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $update_mask = null; + /** + * Required. The resource being updated + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.Collection collection = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $collection = 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 = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { + */ + protected $request_id = ''; + + /** + * @param \Google\Cloud\VectorSearch\V1\Collection $collection Required. The resource being updated + * @param \Google\Protobuf\FieldMask $updateMask Optional. Field mask is used to specify the fields to be overwritten in the + * Collection 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 present in the request will be + * overwritten. + * + * The following fields support update: `display_name`, `description`, + * `labels`, `data_schema`, `vector_schema`. + * For `data_schema` and `vector_schema`, fields can only be added, not + * deleted, but `vertex_embedding_config` in `vector_schema` can be added or + * removed. + * Partial updates for `data_schema` and `vector_schema` are also supported + * by using sub-field paths in `update_mask`, e.g. + * `data_schema.properties.foo` or `vector_schema.my_vector_field`. + * + * If `*` is provided in the update_mask, full replacement will be performed. + * + * @return \Google\Cloud\VectorSearch\V1\UpdateCollectionRequest + * + * @experimental + */ + public static function build(\Google\Cloud\VectorSearch\V1\Collection $collection, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setCollection($collection) + ->setUpdateMask($updateMask); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Protobuf\FieldMask $update_mask + * Optional. Field mask is used to specify the fields to be overwritten in the + * Collection 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 present in the request will be + * overwritten. + * The following fields support update: `display_name`, `description`, + * `labels`, `data_schema`, `vector_schema`. + * For `data_schema` and `vector_schema`, fields can only be added, not + * deleted, but `vertex_embedding_config` in `vector_schema` can be added or + * removed. + * Partial updates for `data_schema` and `vector_schema` are also supported + * by using sub-field paths in `update_mask`, e.g. + * `data_schema.properties.foo` or `vector_schema.my_vector_field`. + * If `*` is provided in the update_mask, full replacement will be performed. + * @type \Google\Cloud\VectorSearch\V1\Collection $collection + * 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 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\Vectorsearch\V1\VectorsearchService::initOnce(); + parent::__construct($data); + } + + /** + * Optional. Field mask is used to specify the fields to be overwritten in the + * Collection 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 present in the request will be + * overwritten. + * The following fields support update: `display_name`, `description`, + * `labels`, `data_schema`, `vector_schema`. + * For `data_schema` and `vector_schema`, fields can only be added, not + * deleted, but `vertex_embedding_config` in `vector_schema` can be added or + * removed. + * Partial updates for `data_schema` and `vector_schema` are also supported + * by using sub-field paths in `update_mask`, e.g. + * `data_schema.properties.foo` or `vector_schema.my_vector_field`. + * If `*` is provided in the update_mask, full replacement will be performed. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @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); + } + + /** + * Optional. Field mask is used to specify the fields to be overwritten in the + * Collection 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 present in the request will be + * overwritten. + * The following fields support update: `display_name`, `description`, + * `labels`, `data_schema`, `vector_schema`. + * For `data_schema` and `vector_schema`, fields can only be added, not + * deleted, but `vertex_embedding_config` in `vector_schema` can be added or + * removed. + * Partial updates for `data_schema` and `vector_schema` are also supported + * by using sub-field paths in `update_mask`, e.g. + * `data_schema.properties.foo` or `vector_schema.my_vector_field`. + * If `*` is provided in the update_mask, full replacement will be performed. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @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.vectorsearch.v1.Collection collection = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\VectorSearch\V1\Collection|null + */ + public function getCollection() + { + return $this->collection; + } + + public function hasCollection() + { + return isset($this->collection); + } + + public function clearCollection() + { + unset($this->collection); + } + + /** + * Required. The resource being updated + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.Collection collection = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\VectorSearch\V1\Collection $var + * @return $this + */ + public function setCollection($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\Collection::class); + $this->collection = $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 = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { + * @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 = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { + * @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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/UpdateDataObjectRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/UpdateDataObjectRequest.php new file mode 100644 index 000000000000..f69018d6edde --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/UpdateDataObjectRequest.php @@ -0,0 +1,142 @@ +google.cloud.vectorsearch.v1.UpdateDataObjectRequest + */ +class UpdateDataObjectRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The DataObject which replaces the resource on the server. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.DataObject data_object = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $data_object = null; + /** + * Optional. The update mask applies to the resource. See + * [google.protobuf.FieldMask][google.protobuf.FieldMask]. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $update_mask = null; + + /** + * @param \Google\Cloud\VectorSearch\V1\DataObject $dataObject Required. The DataObject which replaces the resource on the server. + * @param \Google\Protobuf\FieldMask $updateMask Optional. The update mask applies to the resource. See + * [google.protobuf.FieldMask][google.protobuf.FieldMask]. + * + * @return \Google\Cloud\VectorSearch\V1\UpdateDataObjectRequest + * + * @experimental + */ + public static function build(\Google\Cloud\VectorSearch\V1\DataObject $dataObject, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setDataObject($dataObject) + ->setUpdateMask($updateMask); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\VectorSearch\V1\DataObject $data_object + * Required. The DataObject which replaces the resource on the server. + * @type \Google\Protobuf\FieldMask $update_mask + * Optional. The update mask applies to the resource. See + * [google.protobuf.FieldMask][google.protobuf.FieldMask]. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The DataObject which replaces the resource on the server. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.DataObject data_object = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\VectorSearch\V1\DataObject|null + */ + public function getDataObject() + { + return $this->data_object; + } + + public function hasDataObject() + { + return isset($this->data_object); + } + + public function clearDataObject() + { + unset($this->data_object); + } + + /** + * Required. The DataObject which replaces the resource on the server. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.DataObject data_object = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\VectorSearch\V1\DataObject $var + * @return $this + */ + public function setDataObject($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\DataObject::class); + $this->data_object = $var; + + return $this; + } + + /** + * Optional. The update mask applies to the resource. See + * [google.protobuf.FieldMask][google.protobuf.FieldMask]. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @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); + } + + /** + * Optional. The update mask applies to the resource. See + * [google.protobuf.FieldMask][google.protobuf.FieldMask]. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/UpdateIndexRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/UpdateIndexRequest.php new file mode 100644 index 000000000000..5591f43847a6 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/UpdateIndexRequest.php @@ -0,0 +1,272 @@ +google.cloud.vectorsearch.v1.UpdateIndexRequest + */ +class UpdateIndexRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource being updated. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.Index index = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $index = null; + /** + * Optional. Specifies the fields to be overwritten in the Index 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 present in the + * request with non-empty values will be overwritten. + * The following fields support update: + * * `display_name` + * * `description` + * * `labels` + * * `dedicated_infrastructure.autoscaling_spec.min_replica_count` + * * `dedicated_infrastructure.autoscaling_spec.max_replica_count` + * If `*` is provided in the `update_mask`, full replacement of mutable fields + * will be performed. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $update_mask = 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 = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { + */ + protected $request_id = ''; + + /** + * @param \Google\Cloud\VectorSearch\V1\Index $index Required. The resource being updated. + * @param \Google\Protobuf\FieldMask $updateMask Optional. Specifies the fields to be overwritten in the Index 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 present in the + * request with non-empty values will be overwritten. + * + * The following fields support update: + * * `display_name` + * * `description` + * * `labels` + * * `dedicated_infrastructure.autoscaling_spec.min_replica_count` + * * `dedicated_infrastructure.autoscaling_spec.max_replica_count` + * + * If `*` is provided in the `update_mask`, full replacement of mutable fields + * will be performed. + * + * @return \Google\Cloud\VectorSearch\V1\UpdateIndexRequest + * + * @experimental + */ + public static function build(\Google\Cloud\VectorSearch\V1\Index $index, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setIndex($index) + ->setUpdateMask($updateMask); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\VectorSearch\V1\Index $index + * Required. The resource being updated. + * @type \Google\Protobuf\FieldMask $update_mask + * Optional. Specifies the fields to be overwritten in the Index 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 present in the + * request with non-empty values will be overwritten. + * The following fields support update: + * * `display_name` + * * `description` + * * `labels` + * * `dedicated_infrastructure.autoscaling_spec.min_replica_count` + * * `dedicated_infrastructure.autoscaling_spec.max_replica_count` + * If `*` is provided in the `update_mask`, full replacement of mutable fields + * will be performed. + * @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\Vectorsearch\V1\VectorsearchService::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource being updated. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.Index index = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\VectorSearch\V1\Index|null + */ + public function getIndex() + { + return $this->index; + } + + public function hasIndex() + { + return isset($this->index); + } + + public function clearIndex() + { + unset($this->index); + } + + /** + * Required. The resource being updated. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.Index index = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\VectorSearch\V1\Index $var + * @return $this + */ + public function setIndex($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\Index::class); + $this->index = $var; + + return $this; + } + + /** + * Optional. Specifies the fields to be overwritten in the Index 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 present in the + * request with non-empty values will be overwritten. + * The following fields support update: + * * `display_name` + * * `description` + * * `labels` + * * `dedicated_infrastructure.autoscaling_spec.min_replica_count` + * * `dedicated_infrastructure.autoscaling_spec.max_replica_count` + * If `*` is provided in the `update_mask`, full replacement of mutable fields + * will be performed. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @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); + } + + /** + * Optional. Specifies the fields to be overwritten in the Index 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 present in the + * request with non-empty values will be overwritten. + * The following fields support update: + * * `display_name` + * * `description` + * * `labels` + * * `dedicated_infrastructure.autoscaling_spec.min_replica_count` + * * `dedicated_infrastructure.autoscaling_spec.max_replica_count` + * If `*` is provided in the `update_mask`, full replacement of mutable fields + * will be performed. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Protobuf\FieldMask $var + * @return $this + */ + public function setUpdateMask($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); + $this->update_mask = $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 = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { + * @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 = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { + * @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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/Vector.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/Vector.php new file mode 100644 index 000000000000..a05fb25b7172 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/Vector.php @@ -0,0 +1,108 @@ +google.cloud.vectorsearch.v1.Vector + */ +class Vector extends \Google\Protobuf\Internal\Message +{ + protected $vector_type; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\VectorSearch\V1\DenseVector $dense + * A dense vector. + * @type \Google\Cloud\VectorSearch\V1\SparseVector $sparse + * A sparse vector. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObject::initOnce(); + parent::__construct($data); + } + + /** + * A dense vector. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.DenseVector dense = 2; + * @return \Google\Cloud\VectorSearch\V1\DenseVector|null + */ + public function getDense() + { + return $this->readOneof(2); + } + + public function hasDense() + { + return $this->hasOneof(2); + } + + /** + * A dense vector. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.DenseVector dense = 2; + * @param \Google\Cloud\VectorSearch\V1\DenseVector $var + * @return $this + */ + public function setDense($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\DenseVector::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * A sparse vector. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.SparseVector sparse = 3; + * @return \Google\Cloud\VectorSearch\V1\SparseVector|null + */ + public function getSparse() + { + return $this->readOneof(3); + } + + public function hasSparse() + { + return $this->hasOneof(3); + } + + /** + * A sparse vector. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.SparseVector sparse = 3; + * @param \Google\Cloud\VectorSearch\V1\SparseVector $var + * @return $this + */ + public function setSparse($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\SparseVector::class); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * @return string + */ + public function getVectorType() + { + return $this->whichOneof("vector_type"); + } + +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/VectorField.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/VectorField.php new file mode 100644 index 000000000000..dfcb5f2c5683 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/VectorField.php @@ -0,0 +1,108 @@ +google.cloud.vectorsearch.v1.VectorField + */ +class VectorField extends \Google\Protobuf\Internal\Message +{ + protected $vector_type_config; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\VectorSearch\V1\DenseVectorField $dense_vector + * Dense vector field. + * @type \Google\Cloud\VectorSearch\V1\SparseVectorField $sparse_vector + * Sparse vector field. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\VectorsearchService::initOnce(); + parent::__construct($data); + } + + /** + * Dense vector field. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.DenseVectorField dense_vector = 3; + * @return \Google\Cloud\VectorSearch\V1\DenseVectorField|null + */ + public function getDenseVector() + { + return $this->readOneof(3); + } + + public function hasDenseVector() + { + return $this->hasOneof(3); + } + + /** + * Dense vector field. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.DenseVectorField dense_vector = 3; + * @param \Google\Cloud\VectorSearch\V1\DenseVectorField $var + * @return $this + */ + public function setDenseVector($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\DenseVectorField::class); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * Sparse vector field. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.SparseVectorField sparse_vector = 4; + * @return \Google\Cloud\VectorSearch\V1\SparseVectorField|null + */ + public function getSparseVector() + { + return $this->readOneof(4); + } + + public function hasSparseVector() + { + return $this->hasOneof(4); + } + + /** + * Sparse vector field. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.SparseVectorField sparse_vector = 4; + * @param \Google\Cloud\VectorSearch\V1\SparseVectorField $var + * @return $this + */ + public function setSparseVector($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\SparseVectorField::class); + $this->writeOneof(4, $var); + + return $this; + } + + /** + * @return string + */ + public function getVectorTypeConfig() + { + return $this->whichOneof("vector_type_config"); + } + +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/VectorSearch.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/VectorSearch.php new file mode 100644 index 000000000000..c068f2a4e9d3 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/VectorSearch.php @@ -0,0 +1,368 @@ +google.cloud.vectorsearch.v1.VectorSearch + */ +class VectorSearch extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The vector field to search. + * + * Generated from protobuf field string search_field = 8 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $search_field = ''; + /** + * Optional. A JSON filter expression, e.g. {"genre": {"$eq": "sci-fi"}}, + * represented as a google.protobuf.Struct. + * + * Generated from protobuf field .google.protobuf.Struct filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $filter = null; + /** + * Optional. The number of nearest neighbors to return. + * + * Generated from protobuf field optional int32 top_k = 5 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $top_k = null; + /** + * Optional. Mask specifying which fields to return. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.OutputFields output_fields = 7 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $output_fields = null; + /** + * Optional. Sets the search hint. If no strategy is specified, the service + * will use an index if one is available, and fall back to the default KNN + * search otherwise. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.SearchHint search_hint = 9 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $search_hint = null; + /** + * Optional. The distance metric to use for the KNN search. If not specified, + * DOT_PRODUCT will be used as the default. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.DistanceMetric distance_metric = 11 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $distance_metric = 0; + protected $vector_type; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\VectorSearch\V1\DenseVector $vector + * A dense vector for the query. + * @type \Google\Cloud\VectorSearch\V1\SparseVector $sparse_vector + * A sparse vector for the query. + * @type string $search_field + * Required. The vector field to search. + * @type \Google\Protobuf\Struct $filter + * Optional. A JSON filter expression, e.g. {"genre": {"$eq": "sci-fi"}}, + * represented as a google.protobuf.Struct. + * @type int $top_k + * Optional. The number of nearest neighbors to return. + * @type \Google\Cloud\VectorSearch\V1\OutputFields $output_fields + * Optional. Mask specifying which fields to return. + * @type \Google\Cloud\VectorSearch\V1\SearchHint $search_hint + * Optional. Sets the search hint. If no strategy is specified, the service + * will use an index if one is available, and fall back to the default KNN + * search otherwise. + * @type int $distance_metric + * Optional. The distance metric to use for the KNN search. If not specified, + * DOT_PRODUCT will be used as the default. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectSearchService::initOnce(); + parent::__construct($data); + } + + /** + * A dense vector for the query. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.DenseVector vector = 1; + * @return \Google\Cloud\VectorSearch\V1\DenseVector|null + */ + public function getVector() + { + return $this->readOneof(1); + } + + public function hasVector() + { + return $this->hasOneof(1); + } + + /** + * A dense vector for the query. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.DenseVector vector = 1; + * @param \Google\Cloud\VectorSearch\V1\DenseVector $var + * @return $this + */ + public function setVector($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\DenseVector::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * A sparse vector for the query. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.SparseVector sparse_vector = 2; + * @return \Google\Cloud\VectorSearch\V1\SparseVector|null + */ + public function getSparseVector() + { + return $this->readOneof(2); + } + + public function hasSparseVector() + { + return $this->hasOneof(2); + } + + /** + * A sparse vector for the query. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.SparseVector sparse_vector = 2; + * @param \Google\Cloud\VectorSearch\V1\SparseVector $var + * @return $this + */ + public function setSparseVector($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\SparseVector::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * Required. The vector field to search. + * + * Generated from protobuf field string search_field = 8 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getSearchField() + { + return $this->search_field; + } + + /** + * Required. The vector field to search. + * + * Generated from protobuf field string search_field = 8 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setSearchField($var) + { + GPBUtil::checkString($var, True); + $this->search_field = $var; + + return $this; + } + + /** + * Optional. A JSON filter expression, e.g. {"genre": {"$eq": "sci-fi"}}, + * represented as a google.protobuf.Struct. + * + * Generated from protobuf field .google.protobuf.Struct filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Protobuf\Struct|null + */ + public function getFilter() + { + return $this->filter; + } + + public function hasFilter() + { + return isset($this->filter); + } + + public function clearFilter() + { + unset($this->filter); + } + + /** + * Optional. A JSON filter expression, e.g. {"genre": {"$eq": "sci-fi"}}, + * represented as a google.protobuf.Struct. + * + * Generated from protobuf field .google.protobuf.Struct filter = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Protobuf\Struct $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Struct::class); + $this->filter = $var; + + return $this; + } + + /** + * Optional. The number of nearest neighbors to return. + * + * Generated from protobuf field optional int32 top_k = 5 [(.google.api.field_behavior) = OPTIONAL]; + * @return int + */ + public function getTopK() + { + return isset($this->top_k) ? $this->top_k : 0; + } + + public function hasTopK() + { + return isset($this->top_k); + } + + public function clearTopK() + { + unset($this->top_k); + } + + /** + * Optional. The number of nearest neighbors to return. + * + * Generated from protobuf field optional int32 top_k = 5 [(.google.api.field_behavior) = OPTIONAL]; + * @param int $var + * @return $this + */ + public function setTopK($var) + { + GPBUtil::checkInt32($var); + $this->top_k = $var; + + return $this; + } + + /** + * Optional. Mask specifying which fields to return. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.OutputFields output_fields = 7 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\VectorSearch\V1\OutputFields|null + */ + public function getOutputFields() + { + return $this->output_fields; + } + + public function hasOutputFields() + { + return isset($this->output_fields); + } + + public function clearOutputFields() + { + unset($this->output_fields); + } + + /** + * Optional. Mask specifying which fields to return. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.OutputFields output_fields = 7 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\VectorSearch\V1\OutputFields $var + * @return $this + */ + public function setOutputFields($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\OutputFields::class); + $this->output_fields = $var; + + return $this; + } + + /** + * Optional. Sets the search hint. If no strategy is specified, the service + * will use an index if one is available, and fall back to the default KNN + * search otherwise. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.SearchHint search_hint = 9 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\VectorSearch\V1\SearchHint|null + */ + public function getSearchHint() + { + return $this->search_hint; + } + + public function hasSearchHint() + { + return isset($this->search_hint); + } + + public function clearSearchHint() + { + unset($this->search_hint); + } + + /** + * Optional. Sets the search hint. If no strategy is specified, the service + * will use an index if one is available, and fall back to the default KNN + * search otherwise. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.SearchHint search_hint = 9 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\VectorSearch\V1\SearchHint $var + * @return $this + */ + public function setSearchHint($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\SearchHint::class); + $this->search_hint = $var; + + return $this; + } + + /** + * Optional. The distance metric to use for the KNN search. If not specified, + * DOT_PRODUCT will be used as the default. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.DistanceMetric distance_metric = 11 [(.google.api.field_behavior) = OPTIONAL]; + * @return int + */ + public function getDistanceMetric() + { + return $this->distance_metric; + } + + /** + * Optional. The distance metric to use for the KNN search. If not specified, + * DOT_PRODUCT will be used as the default. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.DistanceMetric distance_metric = 11 [(.google.api.field_behavior) = OPTIONAL]; + * @param int $var + * @return $this + */ + public function setDistanceMetric($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\VectorSearch\V1\DistanceMetric::class); + $this->distance_metric = $var; + + return $this; + } + + /** + * @return string + */ + public function getVectorType() + { + return $this->whichOneof("vector_type"); + } + +} + diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/VertexEmbeddingConfig.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/VertexEmbeddingConfig.php new file mode 100644 index 000000000000..441e52948d3e --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/VertexEmbeddingConfig.php @@ -0,0 +1,152 @@ +google.cloud.vectorsearch.v1.VertexEmbeddingConfig + */ +class VertexEmbeddingConfig extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Required: ID of the embedding model to use. See + * https://cloud.google.com/vertex-ai/generative-ai/docs/learn/models#embeddings-models + * for the list of supported models. + * + * Generated from protobuf field string model_id = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $model_id = ''; + /** + * Required. Required: Text template for the input to the model. The template + * must contain one or more references to fields in the DataObject, e.g.: + * "Movie Title: {title} ---- Movie Plot: {plot}". + * + * Generated from protobuf field string text_template = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $text_template = ''; + /** + * Required. Required: Task type for the embeddings. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.EmbeddingTaskType task_type = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $task_type = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $model_id + * Required. Required: ID of the embedding model to use. See + * https://cloud.google.com/vertex-ai/generative-ai/docs/learn/models#embeddings-models + * for the list of supported models. + * @type string $text_template + * Required. Required: Text template for the input to the model. The template + * must contain one or more references to fields in the DataObject, e.g.: + * "Movie Title: {title} ---- Movie Plot: {plot}". + * @type int $task_type + * Required. Required: Task type for the embeddings. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vectorsearch\V1\EmbeddingConfig::initOnce(); + parent::__construct($data); + } + + /** + * Required. Required: ID of the embedding model to use. See + * https://cloud.google.com/vertex-ai/generative-ai/docs/learn/models#embeddings-models + * for the list of supported models. + * + * Generated from protobuf field string model_id = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getModelId() + { + return $this->model_id; + } + + /** + * Required. Required: ID of the embedding model to use. See + * https://cloud.google.com/vertex-ai/generative-ai/docs/learn/models#embeddings-models + * for the list of supported models. + * + * Generated from protobuf field string model_id = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setModelId($var) + { + GPBUtil::checkString($var, True); + $this->model_id = $var; + + return $this; + } + + /** + * Required. Required: Text template for the input to the model. The template + * must contain one or more references to fields in the DataObject, e.g.: + * "Movie Title: {title} ---- Movie Plot: {plot}". + * + * Generated from protobuf field string text_template = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getTextTemplate() + { + return $this->text_template; + } + + /** + * Required. Required: Text template for the input to the model. The template + * must contain one or more references to fields in the DataObject, e.g.: + * "Movie Title: {title} ---- Movie Plot: {plot}". + * + * Generated from protobuf field string text_template = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setTextTemplate($var) + { + GPBUtil::checkString($var, True); + $this->text_template = $var; + + return $this; + } + + /** + * Required. Required: Task type for the embeddings. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.EmbeddingTaskType task_type = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return int + */ + public function getTaskType() + { + return $this->task_type; + } + + /** + * Required. Required: Task type for the embeddings. + * + * Generated from protobuf field .google.cloud.vectorsearch.v1.EmbeddingTaskType task_type = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param int $var + * @return $this + */ + public function setTaskType($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\VectorSearch\V1\EmbeddingTaskType::class); + $this->task_type = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/aggregate_data_objects.php b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/aggregate_data_objects.php new file mode 100644 index 000000000000..901f38ec5006 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/aggregate_data_objects.php @@ -0,0 +1,80 @@ +setParent($formattedParent) + ->setAggregate($aggregate); + + // Call the API and handle any network failures. + try { + /** @var AggregateDataObjectsResponse $response */ + $response = $dataObjectSearchServiceClient->aggregateDataObjects($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 = DataObjectSearchServiceClient::collectionName( + '[PROJECT]', + '[LOCATION]', + '[COLLECTION]' + ); + $aggregate = AggregationMethod::AGGREGATION_METHOD_UNSPECIFIED; + + aggregate_data_objects_sample($formattedParent, $aggregate); +} +// [END vectorsearch_v1_generated_DataObjectSearchService_AggregateDataObjects_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/batch_search_data_objects.php b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/batch_search_data_objects.php new file mode 100644 index 000000000000..f4c1b6907b50 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/batch_search_data_objects.php @@ -0,0 +1,79 @@ +setParent($formattedParent) + ->setSearches($searches); + + // Call the API and handle any network failures. + try { + /** @var BatchSearchDataObjectsResponse $response */ + $response = $dataObjectSearchServiceClient->batchSearchDataObjects($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 = DataObjectSearchServiceClient::collectionName( + '[PROJECT]', + '[LOCATION]', + '[COLLECTION]' + ); + + batch_search_data_objects_sample($formattedParent); +} +// [END vectorsearch_v1_generated_DataObjectSearchService_BatchSearchDataObjects_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/get_location.php b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/get_location.php new file mode 100644 index 000000000000..4dd8d9aff4a8 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/get_location.php @@ -0,0 +1,57 @@ +getLocation($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} +// [END vectorsearch_v1_generated_DataObjectSearchService_GetLocation_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/list_locations.php b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/list_locations.php new file mode 100644 index 000000000000..65a26d857a7f --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/list_locations.php @@ -0,0 +1,78 @@ +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 vectorsearch_v1_generated_DataObjectSearchService_ListLocations_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/query_data_objects.php b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/query_data_objects.php new file mode 100644 index 000000000000..84e7266cbc2e --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/query_data_objects.php @@ -0,0 +1,81 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $dataObjectSearchServiceClient->queryDataObjects($request); + + /** @var DataObject $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 = DataObjectSearchServiceClient::collectionName( + '[PROJECT]', + '[LOCATION]', + '[COLLECTION]' + ); + + query_data_objects_sample($formattedParent); +} +// [END vectorsearch_v1_generated_DataObjectSearchService_QueryDataObjects_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/search_data_objects.php b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/search_data_objects.php new file mode 100644 index 000000000000..1b87176767b6 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/search_data_objects.php @@ -0,0 +1,81 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $dataObjectSearchServiceClient->searchDataObjects($request); + + /** @var SearchResult $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 = DataObjectSearchServiceClient::collectionName( + '[PROJECT]', + '[LOCATION]', + '[COLLECTION]' + ); + + search_data_objects_sample($formattedParent); +} +// [END vectorsearch_v1_generated_DataObjectSearchService_SearchDataObjects_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/batch_create_data_objects.php b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/batch_create_data_objects.php new file mode 100644 index 000000000000..03b5d12f1736 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/batch_create_data_objects.php @@ -0,0 +1,104 @@ +setParent($formattedRequestsParent) + ->setDataObjectId($requestsDataObjectId) + ->setDataObject($requestsDataObject); + $requests = [$createDataObjectRequest,]; + $request = (new BatchCreateDataObjectsRequest()) + ->setParent($formattedParent) + ->setRequests($requests); + + // Call the API and handle any network failures. + try { + /** @var BatchCreateDataObjectsResponse $response */ + $response = $dataObjectServiceClient->batchCreateDataObjects($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 = DataObjectServiceClient::collectionName( + '[PROJECT]', + '[LOCATION]', + '[COLLECTION]' + ); + $formattedRequestsParent = DataObjectServiceClient::collectionName( + '[PROJECT]', + '[LOCATION]', + '[COLLECTION]' + ); + $requestsDataObjectId = '[DATA_OBJECT_ID]'; + + batch_create_data_objects_sample($formattedParent, $formattedRequestsParent, $requestsDataObjectId); +} +// [END vectorsearch_v1_generated_DataObjectService_BatchCreateDataObjects_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/batch_delete_data_objects.php b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/batch_delete_data_objects.php new file mode 100644 index 000000000000..9bcdc587e81d --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/batch_delete_data_objects.php @@ -0,0 +1,91 @@ +setName($formattedRequestsName); + $requests = [$deleteDataObjectRequest,]; + $request = (new BatchDeleteDataObjectsRequest()) + ->setParent($formattedParent) + ->setRequests($requests); + + // Call the API and handle any network failures. + try { + $dataObjectServiceClient->batchDeleteDataObjects($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 +{ + $formattedParent = DataObjectServiceClient::collectionName( + '[PROJECT]', + '[LOCATION]', + '[COLLECTION]' + ); + $formattedRequestsName = DataObjectServiceClient::dataObjectName( + '[PROJECT]', + '[LOCATION]', + '[COLLECTION]', + '[DATAOBJECT]' + ); + + batch_delete_data_objects_sample($formattedParent, $formattedRequestsName); +} +// [END vectorsearch_v1_generated_DataObjectService_BatchDeleteDataObjects_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/batch_update_data_objects.php b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/batch_update_data_objects.php new file mode 100644 index 000000000000..148400e360b5 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/batch_update_data_objects.php @@ -0,0 +1,85 @@ +setDataObject($requestsDataObject); + $requests = [$updateDataObjectRequest,]; + $request = (new BatchUpdateDataObjectsRequest()) + ->setParent($formattedParent) + ->setRequests($requests); + + // Call the API and handle any network failures. + try { + /** @var BatchUpdateDataObjectsResponse $response */ + $response = $dataObjectServiceClient->batchUpdateDataObjects($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 = DataObjectServiceClient::collectionName( + '[PROJECT]', + '[LOCATION]', + '[COLLECTION]' + ); + + batch_update_data_objects_sample($formattedParent); +} +// [END vectorsearch_v1_generated_DataObjectService_BatchUpdateDataObjects_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/create_data_object.php b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/create_data_object.php new file mode 100644 index 000000000000..0adc95b4be0a --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/create_data_object.php @@ -0,0 +1,85 @@ +setParent($formattedParent) + ->setDataObjectId($dataObjectId) + ->setDataObject($dataObject); + + // Call the API and handle any network failures. + try { + /** @var DataObject $response */ + $response = $dataObjectServiceClient->createDataObject($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 = DataObjectServiceClient::collectionName( + '[PROJECT]', + '[LOCATION]', + '[COLLECTION]' + ); + $dataObjectId = '[DATA_OBJECT_ID]'; + + create_data_object_sample($formattedParent, $dataObjectId); +} +// [END vectorsearch_v1_generated_DataObjectService_CreateDataObject_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/delete_data_object.php b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/delete_data_object.php new file mode 100644 index 000000000000..1f544ed85ecc --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/delete_data_object.php @@ -0,0 +1,76 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + $dataObjectServiceClient->deleteDataObject($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 = DataObjectServiceClient::dataObjectName( + '[PROJECT]', + '[LOCATION]', + '[COLLECTION]', + '[DATAOBJECT]' + ); + + delete_data_object_sample($formattedName); +} +// [END vectorsearch_v1_generated_DataObjectService_DeleteDataObject_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/get_data_object.php b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/get_data_object.php new file mode 100644 index 000000000000..c9998dfb9cd8 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/get_data_object.php @@ -0,0 +1,78 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var DataObject $response */ + $response = $dataObjectServiceClient->getDataObject($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 = DataObjectServiceClient::dataObjectName( + '[PROJECT]', + '[LOCATION]', + '[COLLECTION]', + '[DATAOBJECT]' + ); + + get_data_object_sample($formattedName); +} +// [END vectorsearch_v1_generated_DataObjectService_GetDataObject_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/get_location.php b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/get_location.php new file mode 100644 index 000000000000..9edd13df81e2 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/get_location.php @@ -0,0 +1,57 @@ +getLocation($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} +// [END vectorsearch_v1_generated_DataObjectService_GetLocation_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/list_locations.php b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/list_locations.php new file mode 100644 index 000000000000..0a4730deaa8c --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/list_locations.php @@ -0,0 +1,78 @@ +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 vectorsearch_v1_generated_DataObjectService_ListLocations_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/update_data_object.php b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/update_data_object.php new file mode 100644 index 000000000000..1fd6306c28dc --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/update_data_object.php @@ -0,0 +1,59 @@ +setDataObject($dataObject); + + // Call the API and handle any network failures. + try { + /** @var DataObject $response */ + $response = $dataObjectServiceClient->updateDataObject($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} +// [END vectorsearch_v1_generated_DataObjectService_UpdateDataObject_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/create_collection.php b/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/create_collection.php new file mode 100644 index 000000000000..b5dba9b52e21 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/create_collection.php @@ -0,0 +1,92 @@ +setParent($formattedParent) + ->setCollectionId($collectionId) + ->setCollection($collection); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vectorSearchServiceClient->createCollection($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var Collection $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 = VectorSearchServiceClient::locationName('[PROJECT]', '[LOCATION]'); + $collectionId = '[COLLECTION_ID]'; + + create_collection_sample($formattedParent, $collectionId); +} +// [END vectorsearch_v1_generated_VectorSearchService_CreateCollection_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/create_index.php b/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/create_index.php new file mode 100644 index 000000000000..929e3279b24e --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/create_index.php @@ -0,0 +1,104 @@ +setIndexField($indexIndexField); + $request = (new CreateIndexRequest()) + ->setParent($formattedParent) + ->setIndexId($indexId) + ->setIndex($index); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vectorSearchServiceClient->createIndex($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var Index $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 = VectorSearchServiceClient::collectionName( + '[PROJECT]', + '[LOCATION]', + '[COLLECTION]' + ); + $indexId = '[INDEX_ID]'; + $indexIndexField = '[INDEX_FIELD]'; + + create_index_sample($formattedParent, $indexId, $indexIndexField); +} +// [END vectorsearch_v1_generated_VectorSearchService_CreateIndex_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/delete_collection.php b/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/delete_collection.php new file mode 100644 index 000000000000..7ab95231c955 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/delete_collection.php @@ -0,0 +1,84 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vectorSearchServiceClient->deleteCollection($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 = VectorSearchServiceClient::collectionName( + '[PROJECT]', + '[LOCATION]', + '[COLLECTION]' + ); + + delete_collection_sample($formattedName); +} +// [END vectorsearch_v1_generated_VectorSearchService_DeleteCollection_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/delete_index.php b/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/delete_index.php new file mode 100644 index 000000000000..ebcaa4e77d8a --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/delete_index.php @@ -0,0 +1,87 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vectorSearchServiceClient->deleteIndex($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 = VectorSearchServiceClient::indexName( + '[PROJECT]', + '[LOCATION]', + '[COLLECTION]', + '[INDEX]' + ); + + delete_index_sample($formattedName); +} +// [END vectorsearch_v1_generated_VectorSearchService_DeleteIndex_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/export_data_objects.php b/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/export_data_objects.php new file mode 100644 index 000000000000..c3081a2d0c6f --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/export_data_objects.php @@ -0,0 +1,89 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vectorSearchServiceClient->exportDataObjects($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var ExportDataObjectsResponse $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 = VectorSearchServiceClient::collectionName( + '[PROJECT]', + '[LOCATION]', + '[COLLECTION]' + ); + + export_data_objects_sample($formattedName); +} +// [END vectorsearch_v1_generated_VectorSearchService_ExportDataObjects_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/get_collection.php b/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/get_collection.php new file mode 100644 index 000000000000..d02572d30bf2 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/get_collection.php @@ -0,0 +1,75 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var Collection $response */ + $response = $vectorSearchServiceClient->getCollection($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 = VectorSearchServiceClient::collectionName( + '[PROJECT]', + '[LOCATION]', + '[COLLECTION]' + ); + + get_collection_sample($formattedName); +} +// [END vectorsearch_v1_generated_VectorSearchService_GetCollection_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/get_index.php b/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/get_index.php new file mode 100644 index 000000000000..140b096be0dd --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/get_index.php @@ -0,0 +1,76 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var Index $response */ + $response = $vectorSearchServiceClient->getIndex($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 = VectorSearchServiceClient::indexName( + '[PROJECT]', + '[LOCATION]', + '[COLLECTION]', + '[INDEX]' + ); + + get_index_sample($formattedName); +} +// [END vectorsearch_v1_generated_VectorSearchService_GetIndex_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/get_location.php b/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/get_location.php new file mode 100644 index 000000000000..2dac0088703d --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/get_location.php @@ -0,0 +1,57 @@ +getLocation($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} +// [END vectorsearch_v1_generated_VectorSearchService_GetLocation_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/import_data_objects.php b/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/import_data_objects.php new file mode 100644 index 000000000000..a5c5f7f3da75 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/import_data_objects.php @@ -0,0 +1,88 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vectorSearchServiceClient->importDataObjects($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var ImportDataObjectsResponse $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 = VectorSearchServiceClient::collectionName( + '[PROJECT]', + '[LOCATION]', + '[COLLECTION]' + ); + + import_data_objects_sample($formattedName); +} +// [END vectorsearch_v1_generated_VectorSearchService_ImportDataObjects_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/list_collections.php b/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/list_collections.php new file mode 100644 index 000000000000..5121f672420e --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/list_collections.php @@ -0,0 +1,76 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $vectorSearchServiceClient->listCollections($request); + + /** @var Collection $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 = VectorSearchServiceClient::locationName('[PROJECT]', '[LOCATION]'); + + list_collections_sample($formattedParent); +} +// [END vectorsearch_v1_generated_VectorSearchService_ListCollections_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/list_indexes.php b/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/list_indexes.php new file mode 100644 index 000000000000..6aaa50ebb75a --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/list_indexes.php @@ -0,0 +1,80 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $vectorSearchServiceClient->listIndexes($request); + + /** @var Index $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 = VectorSearchServiceClient::collectionName( + '[PROJECT]', + '[LOCATION]', + '[COLLECTION]' + ); + + list_indexes_sample($formattedParent); +} +// [END vectorsearch_v1_generated_VectorSearchService_ListIndexes_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/list_locations.php b/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/list_locations.php new file mode 100644 index 000000000000..212feaf99516 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/list_locations.php @@ -0,0 +1,78 @@ +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 vectorsearch_v1_generated_VectorSearchService_ListLocations_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/update_collection.php b/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/update_collection.php new file mode 100644 index 000000000000..928fc297b03e --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/update_collection.php @@ -0,0 +1,71 @@ +setCollection($collection); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vectorSearchServiceClient->updateCollection($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var Collection $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 vectorsearch_v1_generated_VectorSearchService_UpdateCollection_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/update_index.php b/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/update_index.php new file mode 100644 index 000000000000..91bbca2bab09 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/update_index.php @@ -0,0 +1,84 @@ +setIndexField($indexIndexField); + $request = (new UpdateIndexRequest()) + ->setIndex($index); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vectorSearchServiceClient->updateIndex($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var Index $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 +{ + $indexIndexField = '[INDEX_FIELD]'; + + update_index_sample($indexIndexField); +} +// [END vectorsearch_v1_generated_VectorSearchService_UpdateIndex_sync] diff --git a/owl-bot-staging/VectorSearch/v1/src/V1/Client/DataObjectSearchServiceClient.php b/owl-bot-staging/VectorSearch/v1/src/V1/Client/DataObjectSearchServiceClient.php new file mode 100644 index 000000000000..7fab589eb36f --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/src/V1/Client/DataObjectSearchServiceClient.php @@ -0,0 +1,441 @@ + aggregateDataObjectsAsync(AggregateDataObjectsRequest $request, array $optionalArgs = []) + * @method PromiseInterface batchSearchDataObjectsAsync(BatchSearchDataObjectsRequest $request, array $optionalArgs = []) + * @method PromiseInterface queryDataObjectsAsync(QueryDataObjectsRequest $request, array $optionalArgs = []) + * @method PromiseInterface searchDataObjectsAsync(SearchDataObjectsRequest $request, array $optionalArgs = []) + * @method PromiseInterface getLocationAsync(GetLocationRequest $request, array $optionalArgs = []) + * @method PromiseInterface listLocationsAsync(ListLocationsRequest $request, array $optionalArgs = []) + */ +final class DataObjectSearchServiceClient +{ + use GapicClientTrait; + use ResourceHelperTrait; + + /** The name of the service. */ + private const SERVICE_NAME = 'google.cloud.vectorsearch.v1.DataObjectSearchService'; + + /** + * The default address of the service. + * + * @deprecated SERVICE_ADDRESS_TEMPLATE should be used instead. + */ + private const SERVICE_ADDRESS = 'vectorsearch.googleapis.com'; + + /** The address template of the service. */ + private const SERVICE_ADDRESS_TEMPLATE = 'vectorsearch.UNIVERSE_DOMAIN'; + + /** The default port of the service. */ + private const DEFAULT_SERVICE_PORT = 443; + + /** The name of the code generator, to be included in the agent header. */ + private const CODEGEN_NAME = 'gapic'; + + /** The default scopes required by the service. */ + public static $serviceScopes = [ + 'https://www.googleapis.com/auth/cloud-platform', + ]; + + private static function getClientDefaults() + { + return [ + 'serviceName' => self::SERVICE_NAME, + 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, + 'clientConfig' => __DIR__ . '/../resources/data_object_search_service_client_config.json', + 'descriptorsConfigPath' => __DIR__ . '/../resources/data_object_search_service_descriptor_config.php', + 'gcpApiConfigPath' => __DIR__ . '/../resources/data_object_search_service_grpc_config.json', + 'credentialsConfig' => [ + 'defaultScopes' => self::$serviceScopes, + ], + 'transportConfig' => [ + 'rest' => [ + 'restClientConfigPath' => __DIR__ . '/../resources/data_object_search_service_rest_client_config.php', + ], + ], + ]; + } + + /** + * Formats a string containing the fully-qualified path to represent a collection + * resource. + * + * @param string $project + * @param string $location + * @param string $collection + * + * @return string The formatted collection resource. + */ + public static function collectionName(string $project, string $location, string $collection): string + { + return self::getPathTemplate('collection')->render([ + 'project' => $project, + 'location' => $location, + 'collection' => $collection, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a index + * resource. + * + * @param string $project + * @param string $location + * @param string $collection + * @param string $index + * + * @return string The formatted index resource. + */ + public static function indexName(string $project, string $location, string $collection, string $index): string + { + return self::getPathTemplate('index')->render([ + 'project' => $project, + 'location' => $location, + 'collection' => $collection, + 'index' => $index, + ]); + } + + /** + * Parses a formatted name string and returns an associative array of the components in the name. + * The following name formats are supported: + * Template: Pattern + * - collection: projects/{project}/locations/{location}/collections/{collection} + * - index: projects/{project}/locations/{location}/collections/{collection}/indexes/{index} + * + * 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(string $formattedName, ?string $template = null): array + { + return self::parseFormattedName($formattedName, $template); + } + + /** + * Constructor. + * + * @param array|ClientOptions $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 'vectorsearch.googleapis.com:443'. + * @type FetchAuthTokenInterface|CredentialsWrapper $credentials + * This option should only be used with a pre-constructed + * {@see FetchAuthTokenInterface} or {@see CredentialsWrapper} object. Note that + * when one of these objects are provided, any settings in $credentialsConfig will + * be ignored. + * **Important**: If you are providing a path to a credentials file, or a decoded + * credentials file as a PHP array, this usage is now DEPRECATED. Providing an + * unvalidated credential configuration to Google APIs can compromise the security + * of your systems and data. It is recommended to create the credentials explicitly + * ``` + * use Google\Auth\Credentials\ServiceAccountCredentials; + * use Google\Cloud\VectorSearch\V1\DataObjectSearchServiceClient; + * $creds = new ServiceAccountCredentials($scopes, $json); + * $options = new DataObjectSearchServiceClient(['credentials' => $creds]); + * ``` + * {@see + * https://cloud.google.com/docs/authentication/external/externally-sourced-credentials} + * @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. + * @type false|LoggerInterface $logger + * A PSR-3 compliant logger. If set to false, logging is disabled, ignoring the + * 'GOOGLE_SDK_PHP_LOGGING' environment flag + * @type string $universeDomain + * The service domain for the client. Defaults to 'googleapis.com'. + * } + * + * @throws ValidationException + */ + public function __construct(array|ClientOptions $options = []) + { + $clientOptions = $this->buildClientOptions($options); + $this->setClientOptions($clientOptions); + } + + /** Handles execution of the async variants for each documented method. */ + public function __call($method, $args) + { + if (substr($method, -5) !== 'Async') { + trigger_error('Call to undefined method ' . __CLASS__ . "::$method()", E_USER_ERROR); + } + + array_unshift($args, substr($method, 0, -5)); + return call_user_func_array([$this, 'startAsyncCall'], $args); + } + + /** + * Aggregates data objects. + * + * The async variant is + * {@see DataObjectSearchServiceClient::aggregateDataObjectsAsync()} . + * + * @example samples/V1/DataObjectSearchServiceClient/aggregate_data_objects.php + * + * @param AggregateDataObjectsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 AggregateDataObjectsResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function aggregateDataObjects(AggregateDataObjectsRequest $request, array $callOptions = []): AggregateDataObjectsResponse + { + return $this->startApiCall('AggregateDataObjects', $request, $callOptions)->wait(); + } + + /** + * Batch searches data objects. + * + * The async variant is + * {@see DataObjectSearchServiceClient::batchSearchDataObjectsAsync()} . + * + * @example samples/V1/DataObjectSearchServiceClient/batch_search_data_objects.php + * + * @param BatchSearchDataObjectsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 BatchSearchDataObjectsResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function batchSearchDataObjects(BatchSearchDataObjectsRequest $request, array $callOptions = []): BatchSearchDataObjectsResponse + { + return $this->startApiCall('BatchSearchDataObjects', $request, $callOptions)->wait(); + } + + /** + * Queries data objects. + * + * The async variant is + * {@see DataObjectSearchServiceClient::queryDataObjectsAsync()} . + * + * @example samples/V1/DataObjectSearchServiceClient/query_data_objects.php + * + * @param QueryDataObjectsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function queryDataObjects(QueryDataObjectsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('QueryDataObjects', $request, $callOptions); + } + + /** + * Searches data objects. + * + * The async variant is + * {@see DataObjectSearchServiceClient::searchDataObjectsAsync()} . + * + * @example samples/V1/DataObjectSearchServiceClient/search_data_objects.php + * + * @param SearchDataObjectsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function searchDataObjects(SearchDataObjectsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('SearchDataObjects', $request, $callOptions); + } + + /** + * Gets information about a location. + * + * The async variant is {@see DataObjectSearchServiceClient::getLocationAsync()} . + * + * @example samples/V1/DataObjectSearchServiceClient/get_location.php + * + * @param GetLocationRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Location + * + * @throws ApiException Thrown if the API call fails. + */ + public function getLocation(GetLocationRequest $request, array $callOptions = []): Location + { + return $this->startApiCall('GetLocation', $request, $callOptions)->wait(); + } + + /** + * Lists information about the supported locations for this service. + * + * This method lists locations based on the resource scope provided in + * the [ListLocationsRequest.name] field: + * + * * **Global locations**: If `name` is empty, the method lists the + * public locations available to all projects. * **Project-specific + * locations**: If `name` follows the format + * `projects/{project}`, the method lists locations visible to that + * specific project. This includes public, private, or other + * project-specific locations enabled for the project. + * + * For gRPC and client library implementations, the resource name is + * passed as the `name` field. For direct service calls, the resource + * name is + * incorporated into the request path based on the specific service + * implementation and version. + * + * The async variant is {@see DataObjectSearchServiceClient::listLocationsAsync()} + * . + * + * @example samples/V1/DataObjectSearchServiceClient/list_locations.php + * + * @param ListLocationsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listLocations(ListLocationsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListLocations', $request, $callOptions); + } +} diff --git a/owl-bot-staging/VectorSearch/v1/src/V1/Client/DataObjectServiceClient.php b/owl-bot-staging/VectorSearch/v1/src/V1/Client/DataObjectServiceClient.php new file mode 100644 index 000000000000..1eed6ba2f80c --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/src/V1/Client/DataObjectServiceClient.php @@ -0,0 +1,520 @@ + batchCreateDataObjectsAsync(BatchCreateDataObjectsRequest $request, array $optionalArgs = []) + * @method PromiseInterface batchDeleteDataObjectsAsync(BatchDeleteDataObjectsRequest $request, array $optionalArgs = []) + * @method PromiseInterface batchUpdateDataObjectsAsync(BatchUpdateDataObjectsRequest $request, array $optionalArgs = []) + * @method PromiseInterface createDataObjectAsync(CreateDataObjectRequest $request, array $optionalArgs = []) + * @method PromiseInterface deleteDataObjectAsync(DeleteDataObjectRequest $request, array $optionalArgs = []) + * @method PromiseInterface getDataObjectAsync(GetDataObjectRequest $request, array $optionalArgs = []) + * @method PromiseInterface updateDataObjectAsync(UpdateDataObjectRequest $request, array $optionalArgs = []) + * @method PromiseInterface getLocationAsync(GetLocationRequest $request, array $optionalArgs = []) + * @method PromiseInterface listLocationsAsync(ListLocationsRequest $request, array $optionalArgs = []) + */ +final class DataObjectServiceClient +{ + use GapicClientTrait; + use ResourceHelperTrait; + + /** The name of the service. */ + private const SERVICE_NAME = 'google.cloud.vectorsearch.v1.DataObjectService'; + + /** + * The default address of the service. + * + * @deprecated SERVICE_ADDRESS_TEMPLATE should be used instead. + */ + private const SERVICE_ADDRESS = 'vectorsearch.googleapis.com'; + + /** The address template of the service. */ + private const SERVICE_ADDRESS_TEMPLATE = 'vectorsearch.UNIVERSE_DOMAIN'; + + /** The default port of the service. */ + private const DEFAULT_SERVICE_PORT = 443; + + /** The name of the code generator, to be included in the agent header. */ + private const CODEGEN_NAME = 'gapic'; + + /** The default scopes required by the service. */ + public static $serviceScopes = [ + 'https://www.googleapis.com/auth/cloud-platform', + ]; + + private static function getClientDefaults() + { + return [ + 'serviceName' => self::SERVICE_NAME, + 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, + 'clientConfig' => __DIR__ . '/../resources/data_object_service_client_config.json', + 'descriptorsConfigPath' => __DIR__ . '/../resources/data_object_service_descriptor_config.php', + 'gcpApiConfigPath' => __DIR__ . '/../resources/data_object_service_grpc_config.json', + 'credentialsConfig' => [ + 'defaultScopes' => self::$serviceScopes, + ], + 'transportConfig' => [ + 'rest' => [ + 'restClientConfigPath' => __DIR__ . '/../resources/data_object_service_rest_client_config.php', + ], + ], + ]; + } + + /** + * Formats a string containing the fully-qualified path to represent a collection + * resource. + * + * @param string $project + * @param string $location + * @param string $collection + * + * @return string The formatted collection resource. + */ + public static function collectionName(string $project, string $location, string $collection): string + { + return self::getPathTemplate('collection')->render([ + 'project' => $project, + 'location' => $location, + 'collection' => $collection, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a data_object + * resource. + * + * @param string $project + * @param string $location + * @param string $collection + * @param string $dataObject + * + * @return string The formatted data_object resource. + */ + public static function dataObjectName(string $project, string $location, string $collection, string $dataObject): string + { + return self::getPathTemplate('dataObject')->render([ + 'project' => $project, + 'location' => $location, + 'collection' => $collection, + 'dataObject' => $dataObject, + ]); + } + + /** + * Parses a formatted name string and returns an associative array of the components in the name. + * The following name formats are supported: + * Template: Pattern + * - collection: projects/{project}/locations/{location}/collections/{collection} + * - dataObject: projects/{project}/locations/{location}/collections/{collection}/dataObjects/{dataObject} + * + * 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(string $formattedName, ?string $template = null): array + { + return self::parseFormattedName($formattedName, $template); + } + + /** + * Constructor. + * + * @param array|ClientOptions $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 'vectorsearch.googleapis.com:443'. + * @type FetchAuthTokenInterface|CredentialsWrapper $credentials + * This option should only be used with a pre-constructed + * {@see FetchAuthTokenInterface} or {@see CredentialsWrapper} object. Note that + * when one of these objects are provided, any settings in $credentialsConfig will + * be ignored. + * **Important**: If you are providing a path to a credentials file, or a decoded + * credentials file as a PHP array, this usage is now DEPRECATED. Providing an + * unvalidated credential configuration to Google APIs can compromise the security + * of your systems and data. It is recommended to create the credentials explicitly + * ``` + * use Google\Auth\Credentials\ServiceAccountCredentials; + * use Google\Cloud\VectorSearch\V1\DataObjectServiceClient; + * $creds = new ServiceAccountCredentials($scopes, $json); + * $options = new DataObjectServiceClient(['credentials' => $creds]); + * ``` + * {@see + * https://cloud.google.com/docs/authentication/external/externally-sourced-credentials} + * @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. + * @type false|LoggerInterface $logger + * A PSR-3 compliant logger. If set to false, logging is disabled, ignoring the + * 'GOOGLE_SDK_PHP_LOGGING' environment flag + * @type string $universeDomain + * The service domain for the client. Defaults to 'googleapis.com'. + * } + * + * @throws ValidationException + */ + public function __construct(array|ClientOptions $options = []) + { + $clientOptions = $this->buildClientOptions($options); + $this->setClientOptions($clientOptions); + } + + /** Handles execution of the async variants for each documented method. */ + public function __call($method, $args) + { + if (substr($method, -5) !== 'Async') { + trigger_error('Call to undefined method ' . __CLASS__ . "::$method()", E_USER_ERROR); + } + + array_unshift($args, substr($method, 0, -5)); + return call_user_func_array([$this, 'startAsyncCall'], $args); + } + + /** + * Creates a batch of dataObjects. + * + * The async variant is + * {@see DataObjectServiceClient::batchCreateDataObjectsAsync()} . + * + * @example samples/V1/DataObjectServiceClient/batch_create_data_objects.php + * + * @param BatchCreateDataObjectsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 BatchCreateDataObjectsResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function batchCreateDataObjects(BatchCreateDataObjectsRequest $request, array $callOptions = []): BatchCreateDataObjectsResponse + { + return $this->startApiCall('BatchCreateDataObjects', $request, $callOptions)->wait(); + } + + /** + * Deletes dataObjects in a batch. + * + * The async variant is + * {@see DataObjectServiceClient::batchDeleteDataObjectsAsync()} . + * + * @example samples/V1/DataObjectServiceClient/batch_delete_data_objects.php + * + * @param BatchDeleteDataObjectsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Thrown if the API call fails. + */ + public function batchDeleteDataObjects(BatchDeleteDataObjectsRequest $request, array $callOptions = []): void + { + $this->startApiCall('BatchDeleteDataObjects', $request, $callOptions)->wait(); + } + + /** + * Updates dataObjects in a batch. + * + * The async variant is + * {@see DataObjectServiceClient::batchUpdateDataObjectsAsync()} . + * + * @example samples/V1/DataObjectServiceClient/batch_update_data_objects.php + * + * @param BatchUpdateDataObjectsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 BatchUpdateDataObjectsResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function batchUpdateDataObjects(BatchUpdateDataObjectsRequest $request, array $callOptions = []): BatchUpdateDataObjectsResponse + { + return $this->startApiCall('BatchUpdateDataObjects', $request, $callOptions)->wait(); + } + + /** + * Creates a dataObject. + * + * The async variant is {@see DataObjectServiceClient::createDataObjectAsync()} . + * + * @example samples/V1/DataObjectServiceClient/create_data_object.php + * + * @param CreateDataObjectRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 DataObject + * + * @throws ApiException Thrown if the API call fails. + */ + public function createDataObject(CreateDataObjectRequest $request, array $callOptions = []): DataObject + { + return $this->startApiCall('CreateDataObject', $request, $callOptions)->wait(); + } + + /** + * Deletes a dataObject. + * + * The async variant is {@see DataObjectServiceClient::deleteDataObjectAsync()} . + * + * @example samples/V1/DataObjectServiceClient/delete_data_object.php + * + * @param DeleteDataObjectRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Thrown if the API call fails. + */ + public function deleteDataObject(DeleteDataObjectRequest $request, array $callOptions = []): void + { + $this->startApiCall('DeleteDataObject', $request, $callOptions)->wait(); + } + + /** + * Gets a data object. + * + * The async variant is {@see DataObjectServiceClient::getDataObjectAsync()} . + * + * @example samples/V1/DataObjectServiceClient/get_data_object.php + * + * @param GetDataObjectRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 DataObject + * + * @throws ApiException Thrown if the API call fails. + */ + public function getDataObject(GetDataObjectRequest $request, array $callOptions = []): DataObject + { + return $this->startApiCall('GetDataObject', $request, $callOptions)->wait(); + } + + /** + * Updates a dataObject. + * + * The async variant is {@see DataObjectServiceClient::updateDataObjectAsync()} . + * + * @example samples/V1/DataObjectServiceClient/update_data_object.php + * + * @param UpdateDataObjectRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 DataObject + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateDataObject(UpdateDataObjectRequest $request, array $callOptions = []): DataObject + { + return $this->startApiCall('UpdateDataObject', $request, $callOptions)->wait(); + } + + /** + * Gets information about a location. + * + * The async variant is {@see DataObjectServiceClient::getLocationAsync()} . + * + * @example samples/V1/DataObjectServiceClient/get_location.php + * + * @param GetLocationRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Location + * + * @throws ApiException Thrown if the API call fails. + */ + public function getLocation(GetLocationRequest $request, array $callOptions = []): Location + { + return $this->startApiCall('GetLocation', $request, $callOptions)->wait(); + } + + /** + * Lists information about the supported locations for this service. + * + * This method lists locations based on the resource scope provided in + * the [ListLocationsRequest.name] field: + * + * * **Global locations**: If `name` is empty, the method lists the + * public locations available to all projects. * **Project-specific + * locations**: If `name` follows the format + * `projects/{project}`, the method lists locations visible to that + * specific project. This includes public, private, or other + * project-specific locations enabled for the project. + * + * For gRPC and client library implementations, the resource name is + * passed as the `name` field. For direct service calls, the resource + * name is + * incorporated into the request path based on the specific service + * implementation and version. + * + * The async variant is {@see DataObjectServiceClient::listLocationsAsync()} . + * + * @example samples/V1/DataObjectServiceClient/list_locations.php + * + * @param ListLocationsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listLocations(ListLocationsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListLocations', $request, $callOptions); + } +} diff --git a/owl-bot-staging/VectorSearch/v1/src/V1/Client/VectorSearchServiceClient.php b/owl-bot-staging/VectorSearch/v1/src/V1/Client/VectorSearchServiceClient.php new file mode 100644 index 000000000000..7cf31c22c00b --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/src/V1/Client/VectorSearchServiceClient.php @@ -0,0 +1,762 @@ + createCollectionAsync(CreateCollectionRequest $request, array $optionalArgs = []) + * @method PromiseInterface createIndexAsync(CreateIndexRequest $request, array $optionalArgs = []) + * @method PromiseInterface deleteCollectionAsync(DeleteCollectionRequest $request, array $optionalArgs = []) + * @method PromiseInterface deleteIndexAsync(DeleteIndexRequest $request, array $optionalArgs = []) + * @method PromiseInterface exportDataObjectsAsync(ExportDataObjectsRequest $request, array $optionalArgs = []) + * @method PromiseInterface getCollectionAsync(GetCollectionRequest $request, array $optionalArgs = []) + * @method PromiseInterface getIndexAsync(GetIndexRequest $request, array $optionalArgs = []) + * @method PromiseInterface importDataObjectsAsync(ImportDataObjectsRequest $request, array $optionalArgs = []) + * @method PromiseInterface listCollectionsAsync(ListCollectionsRequest $request, array $optionalArgs = []) + * @method PromiseInterface listIndexesAsync(ListIndexesRequest $request, array $optionalArgs = []) + * @method PromiseInterface updateCollectionAsync(UpdateCollectionRequest $request, array $optionalArgs = []) + * @method PromiseInterface updateIndexAsync(UpdateIndexRequest $request, array $optionalArgs = []) + * @method PromiseInterface getLocationAsync(GetLocationRequest $request, array $optionalArgs = []) + * @method PromiseInterface listLocationsAsync(ListLocationsRequest $request, array $optionalArgs = []) + */ +final class VectorSearchServiceClient +{ + use GapicClientTrait; + use ResourceHelperTrait; + + /** The name of the service. */ + private const SERVICE_NAME = 'google.cloud.vectorsearch.v1.VectorSearchService'; + + /** + * The default address of the service. + * + * @deprecated SERVICE_ADDRESS_TEMPLATE should be used instead. + */ + private const SERVICE_ADDRESS = 'vectorsearch.googleapis.com'; + + /** The address template of the service. */ + private const SERVICE_ADDRESS_TEMPLATE = 'vectorsearch.UNIVERSE_DOMAIN'; + + /** The default port of the service. */ + private const DEFAULT_SERVICE_PORT = 443; + + /** The name of the code generator, to be included in the agent header. */ + private const CODEGEN_NAME = 'gapic'; + + /** The default scopes required by the service. */ + public static $serviceScopes = [ + 'https://www.googleapis.com/auth/cloud-platform', + ]; + + private $operationsClient; + + private static function getClientDefaults() + { + return [ + 'serviceName' => self::SERVICE_NAME, + 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, + 'clientConfig' => __DIR__ . '/../resources/vector_search_service_client_config.json', + 'descriptorsConfigPath' => __DIR__ . '/../resources/vector_search_service_descriptor_config.php', + 'gcpApiConfigPath' => __DIR__ . '/../resources/vector_search_service_grpc_config.json', + 'credentialsConfig' => [ + 'defaultScopes' => self::$serviceScopes, + ], + 'transportConfig' => [ + 'rest' => [ + 'restClientConfigPath' => __DIR__ . '/../resources/vector_search_service_rest_client_config.php', + ], + ], + ]; + } + + /** + * 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 = $this->descriptors[$methodName]['longRunning'] ?? []; + $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); + $operation->reload(); + return $operation; + } + + /** + * Create the default operation client for the service. + * + * @param array $options ClientOptions for the client. + * + * @return OperationsClient + */ + private function createOperationsClient(array $options) + { + // Unset client-specific configuration options + unset($options['serviceName'], $options['clientConfig'], $options['descriptorsConfigPath']); + + if (isset($options['operationsClient'])) { + return $options['operationsClient']; + } + + return new OperationsClient($options); + } + + /** + * Formats a string containing the fully-qualified path to represent a collection + * resource. + * + * @param string $project + * @param string $location + * @param string $collection + * + * @return string The formatted collection resource. + */ + public static function collectionName(string $project, string $location, string $collection): string + { + return self::getPathTemplate('collection')->render([ + 'project' => $project, + 'location' => $location, + 'collection' => $collection, + ]); + } + + /** + * 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(string $project, string $location, string $keyRing, string $cryptoKey): string + { + return self::getPathTemplate('cryptoKey')->render([ + 'project' => $project, + 'location' => $location, + 'key_ring' => $keyRing, + 'crypto_key' => $cryptoKey, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a index + * resource. + * + * @param string $project + * @param string $location + * @param string $collection + * @param string $index + * + * @return string The formatted index resource. + */ + public static function indexName(string $project, string $location, string $collection, string $index): string + { + return self::getPathTemplate('index')->render([ + 'project' => $project, + 'location' => $location, + 'collection' => $collection, + 'index' => $index, + ]); + } + + /** + * 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(string $project, string $location): string + { + return self::getPathTemplate('location')->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 + * - collection: projects/{project}/locations/{location}/collections/{collection} + * - cryptoKey: projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key} + * - index: projects/{project}/locations/{location}/collections/{collection}/indexes/{index} + * - 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(string $formattedName, ?string $template = null): array + { + return self::parseFormattedName($formattedName, $template); + } + + /** + * Constructor. + * + * @param array|ClientOptions $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 'vectorsearch.googleapis.com:443'. + * @type FetchAuthTokenInterface|CredentialsWrapper $credentials + * This option should only be used with a pre-constructed + * {@see FetchAuthTokenInterface} or {@see CredentialsWrapper} object. Note that + * when one of these objects are provided, any settings in $credentialsConfig will + * be ignored. + * **Important**: If you are providing a path to a credentials file, or a decoded + * credentials file as a PHP array, this usage is now DEPRECATED. Providing an + * unvalidated credential configuration to Google APIs can compromise the security + * of your systems and data. It is recommended to create the credentials explicitly + * ``` + * use Google\Auth\Credentials\ServiceAccountCredentials; + * use Google\Cloud\VectorSearch\V1\VectorSearchServiceClient; + * $creds = new ServiceAccountCredentials($scopes, $json); + * $options = new VectorSearchServiceClient(['credentials' => $creds]); + * ``` + * {@see + * https://cloud.google.com/docs/authentication/external/externally-sourced-credentials} + * @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. + * @type false|LoggerInterface $logger + * A PSR-3 compliant logger. If set to false, logging is disabled, ignoring the + * 'GOOGLE_SDK_PHP_LOGGING' environment flag + * @type string $universeDomain + * The service domain for the client. Defaults to 'googleapis.com'. + * } + * + * @throws ValidationException + */ + public function __construct(array|ClientOptions $options = []) + { + $clientOptions = $this->buildClientOptions($options); + $this->setClientOptions($clientOptions); + $this->operationsClient = $this->createOperationsClient($clientOptions); + } + + /** Handles execution of the async variants for each documented method. */ + public function __call($method, $args) + { + if (substr($method, -5) !== 'Async') { + trigger_error('Call to undefined method ' . __CLASS__ . "::$method()", E_USER_ERROR); + } + + array_unshift($args, substr($method, 0, -5)); + return call_user_func_array([$this, 'startAsyncCall'], $args); + } + + /** + * Creates a new Collection in a given project and location. + * + * The async variant is {@see VectorSearchServiceClient::createCollectionAsync()} . + * + * @example samples/V1/VectorSearchServiceClient/create_collection.php + * + * @param CreateCollectionRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function createCollection(CreateCollectionRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('CreateCollection', $request, $callOptions)->wait(); + } + + /** + * Creates a new Index in a given project and location. + * + * The async variant is {@see VectorSearchServiceClient::createIndexAsync()} . + * + * @example samples/V1/VectorSearchServiceClient/create_index.php + * + * @param CreateIndexRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function createIndex(CreateIndexRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('CreateIndex', $request, $callOptions)->wait(); + } + + /** + * Deletes a single Collection. + * + * The async variant is {@see VectorSearchServiceClient::deleteCollectionAsync()} . + * + * @example samples/V1/VectorSearchServiceClient/delete_collection.php + * + * @param DeleteCollectionRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function deleteCollection(DeleteCollectionRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('DeleteCollection', $request, $callOptions)->wait(); + } + + /** + * Deletes a single Index. + * + * The async variant is {@see VectorSearchServiceClient::deleteIndexAsync()} . + * + * @example samples/V1/VectorSearchServiceClient/delete_index.php + * + * @param DeleteIndexRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function deleteIndex(DeleteIndexRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('DeleteIndex', $request, $callOptions)->wait(); + } + + /** + * Initiates a Long-Running Operation to export DataObjects from a Collection. + * + * The async variant is {@see VectorSearchServiceClient::exportDataObjectsAsync()} + * . + * + * @example samples/V1/VectorSearchServiceClient/export_data_objects.php + * + * @param ExportDataObjectsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function exportDataObjects(ExportDataObjectsRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('ExportDataObjects', $request, $callOptions)->wait(); + } + + /** + * Gets details of a single Collection. + * + * The async variant is {@see VectorSearchServiceClient::getCollectionAsync()} . + * + * @example samples/V1/VectorSearchServiceClient/get_collection.php + * + * @param GetCollectionRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Collection + * + * @throws ApiException Thrown if the API call fails. + */ + public function getCollection(GetCollectionRequest $request, array $callOptions = []): Collection + { + return $this->startApiCall('GetCollection', $request, $callOptions)->wait(); + } + + /** + * Gets details of a single Index. + * + * The async variant is {@see VectorSearchServiceClient::getIndexAsync()} . + * + * @example samples/V1/VectorSearchServiceClient/get_index.php + * + * @param GetIndexRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Index + * + * @throws ApiException Thrown if the API call fails. + */ + public function getIndex(GetIndexRequest $request, array $callOptions = []): Index + { + return $this->startApiCall('GetIndex', $request, $callOptions)->wait(); + } + + /** + * Initiates a Long-Running Operation to import DataObjects into a Collection. + * + * The async variant is {@see VectorSearchServiceClient::importDataObjectsAsync()} + * . + * + * @example samples/V1/VectorSearchServiceClient/import_data_objects.php + * + * @param ImportDataObjectsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function importDataObjects(ImportDataObjectsRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('ImportDataObjects', $request, $callOptions)->wait(); + } + + /** + * Lists Collections in a given project and location. + * + * The async variant is {@see VectorSearchServiceClient::listCollectionsAsync()} . + * + * @example samples/V1/VectorSearchServiceClient/list_collections.php + * + * @param ListCollectionsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listCollections(ListCollectionsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListCollections', $request, $callOptions); + } + + /** + * Lists Indexes in a given project and location. + * + * The async variant is {@see VectorSearchServiceClient::listIndexesAsync()} . + * + * @example samples/V1/VectorSearchServiceClient/list_indexes.php + * + * @param ListIndexesRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listIndexes(ListIndexesRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListIndexes', $request, $callOptions); + } + + /** + * Updates the parameters of a single Collection. + * + * The async variant is {@see VectorSearchServiceClient::updateCollectionAsync()} . + * + * @example samples/V1/VectorSearchServiceClient/update_collection.php + * + * @param UpdateCollectionRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateCollection(UpdateCollectionRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('UpdateCollection', $request, $callOptions)->wait(); + } + + /** + * Updates the parameters of a single Index. + * + * The async variant is {@see VectorSearchServiceClient::updateIndexAsync()} . + * + * @example samples/V1/VectorSearchServiceClient/update_index.php + * + * @param UpdateIndexRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateIndex(UpdateIndexRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('UpdateIndex', $request, $callOptions)->wait(); + } + + /** + * Gets information about a location. + * + * The async variant is {@see VectorSearchServiceClient::getLocationAsync()} . + * + * @example samples/V1/VectorSearchServiceClient/get_location.php + * + * @param GetLocationRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Location + * + * @throws ApiException Thrown if the API call fails. + */ + public function getLocation(GetLocationRequest $request, array $callOptions = []): Location + { + return $this->startApiCall('GetLocation', $request, $callOptions)->wait(); + } + + /** + * Lists information about the supported locations for this service. + * + * This method lists locations based on the resource scope provided in + * the [ListLocationsRequest.name] field: + * + * * **Global locations**: If `name` is empty, the method lists the + * public locations available to all projects. * **Project-specific + * locations**: If `name` follows the format + * `projects/{project}`, the method lists locations visible to that + * specific project. This includes public, private, or other + * project-specific locations enabled for the project. + * + * For gRPC and client library implementations, the resource name is + * passed as the `name` field. For direct service calls, the resource + * name is + * incorporated into the request path based on the specific service + * implementation and version. + * + * The async variant is {@see VectorSearchServiceClient::listLocationsAsync()} . + * + * @example samples/V1/VectorSearchServiceClient/list_locations.php + * + * @param ListLocationsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listLocations(ListLocationsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListLocations', $request, $callOptions); + } +} diff --git a/owl-bot-staging/VectorSearch/v1/src/V1/gapic_metadata.json b/owl-bot-staging/VectorSearch/v1/src/V1/gapic_metadata.json new file mode 100644 index 000000000000..4e80203638a5 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/src/V1/gapic_metadata.json @@ -0,0 +1,181 @@ +{ + "schema": "1.0", + "comment": "This file maps proto services\/RPCs to the corresponding library clients\/methods", + "language": "php", + "protoPackage": "google.cloud.vectorsearch.v1", + "libraryPackage": "Google\\Cloud\\VectorSearch\\V1", + "services": { + "DataObjectSearchService": { + "clients": { + "grpc": { + "libraryClient": "DataObjectSearchServiceGapicClient", + "rpcs": { + "AggregateDataObjects": { + "methods": [ + "aggregateDataObjects" + ] + }, + "BatchSearchDataObjects": { + "methods": [ + "batchSearchDataObjects" + ] + }, + "QueryDataObjects": { + "methods": [ + "queryDataObjects" + ] + }, + "SearchDataObjects": { + "methods": [ + "searchDataObjects" + ] + }, + "GetLocation": { + "methods": [ + "getLocation" + ] + }, + "ListLocations": { + "methods": [ + "listLocations" + ] + } + } + } + } + }, + "DataObjectService": { + "clients": { + "grpc": { + "libraryClient": "DataObjectServiceGapicClient", + "rpcs": { + "BatchCreateDataObjects": { + "methods": [ + "batchCreateDataObjects" + ] + }, + "BatchDeleteDataObjects": { + "methods": [ + "batchDeleteDataObjects" + ] + }, + "BatchUpdateDataObjects": { + "methods": [ + "batchUpdateDataObjects" + ] + }, + "CreateDataObject": { + "methods": [ + "createDataObject" + ] + }, + "DeleteDataObject": { + "methods": [ + "deleteDataObject" + ] + }, + "GetDataObject": { + "methods": [ + "getDataObject" + ] + }, + "UpdateDataObject": { + "methods": [ + "updateDataObject" + ] + }, + "GetLocation": { + "methods": [ + "getLocation" + ] + }, + "ListLocations": { + "methods": [ + "listLocations" + ] + } + } + } + } + }, + "VectorSearchService": { + "clients": { + "grpc": { + "libraryClient": "VectorSearchServiceGapicClient", + "rpcs": { + "CreateCollection": { + "methods": [ + "createCollection" + ] + }, + "CreateIndex": { + "methods": [ + "createIndex" + ] + }, + "DeleteCollection": { + "methods": [ + "deleteCollection" + ] + }, + "DeleteIndex": { + "methods": [ + "deleteIndex" + ] + }, + "ExportDataObjects": { + "methods": [ + "exportDataObjects" + ] + }, + "GetCollection": { + "methods": [ + "getCollection" + ] + }, + "GetIndex": { + "methods": [ + "getIndex" + ] + }, + "ImportDataObjects": { + "methods": [ + "importDataObjects" + ] + }, + "ListCollections": { + "methods": [ + "listCollections" + ] + }, + "ListIndexes": { + "methods": [ + "listIndexes" + ] + }, + "UpdateCollection": { + "methods": [ + "updateCollection" + ] + }, + "UpdateIndex": { + "methods": [ + "updateIndex" + ] + }, + "GetLocation": { + "methods": [ + "getLocation" + ] + }, + "ListLocations": { + "methods": [ + "listLocations" + ] + } + } + } + } + } + } +} \ No newline at end of file diff --git a/owl-bot-staging/VectorSearch/v1/src/V1/resources/data_object_search_service_client_config.json b/owl-bot-staging/VectorSearch/v1/src/V1/resources/data_object_search_service_client_config.json new file mode 100644 index 000000000000..50aeb62f8c33 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/src/V1/resources/data_object_search_service_client_config.json @@ -0,0 +1,64 @@ +{ + "interfaces": { + "google.cloud.vectorsearch.v1.DataObjectSearchService": { + "retry_codes": { + "no_retry_codes": [], + "retry_policy_2_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_2_params": { + "initial_retry_delay_millis": 1000, + "retry_delay_multiplier": 1.3, + "max_retry_delay_millis": 10000, + "initial_rpc_timeout_millis": 300000, + "rpc_timeout_multiplier": 1.0, + "max_rpc_timeout_millis": 300000, + "total_timeout_millis": 300000 + } + }, + "methods": { + "AggregateDataObjects": { + "timeout_millis": 300000, + "retry_codes_name": "retry_policy_2_codes", + "retry_params_name": "retry_policy_2_params" + }, + "BatchSearchDataObjects": { + "timeout_millis": 300000, + "retry_codes_name": "retry_policy_2_codes", + "retry_params_name": "retry_policy_2_params" + }, + "QueryDataObjects": { + "timeout_millis": 300000, + "retry_codes_name": "retry_policy_2_codes", + "retry_params_name": "retry_policy_2_params" + }, + "SearchDataObjects": { + "timeout_millis": 300000, + "retry_codes_name": "retry_policy_2_codes", + "retry_params_name": "retry_policy_2_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/VectorSearch/v1/src/V1/resources/data_object_search_service_descriptor_config.php b/owl-bot-staging/VectorSearch/v1/src/V1/resources/data_object_search_service_descriptor_config.php new file mode 100644 index 000000000000..8db464a2a450 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/src/V1/resources/data_object_search_service_descriptor_config.php @@ -0,0 +1,130 @@ + [ + 'google.cloud.vectorsearch.v1.DataObjectSearchService' => [ + 'AggregateDataObjects' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\VectorSearch\V1\AggregateDataObjectsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'BatchSearchDataObjects' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\VectorSearch\V1\BatchSearchDataObjectsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'QueryDataObjects' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getDataObjects', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\VectorSearch\V1\QueryDataObjectsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'SearchDataObjects' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getResults', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\VectorSearch\V1\SearchDataObjectsResponse', + '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' => [ + 'collection' => 'projects/{project}/locations/{location}/collections/{collection}', + 'index' => 'projects/{project}/locations/{location}/collections/{collection}/indexes/{index}', + ], + ], + ], +]; diff --git a/owl-bot-staging/VectorSearch/v1/src/V1/resources/data_object_search_service_rest_client_config.php b/owl-bot-staging/VectorSearch/v1/src/V1/resources/data_object_search_service_rest_client_config.php new file mode 100644 index 000000000000..68333383a6e5 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/src/V1/resources/data_object_search_service_rest_client_config.php @@ -0,0 +1,148 @@ + [ + '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.cloud.vectorsearch.v1.DataObjectSearchService' => [ + 'AggregateDataObjects' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*/collections/*}/dataObjects:aggregate', + 'body' => '*', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'BatchSearchDataObjects' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*/collections/*}/dataObjects:batchSearch', + 'body' => '*', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'QueryDataObjects' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*/collections/*}/dataObjects:query', + 'body' => '*', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'SearchDataObjects' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*/collections/*}/dataObjects:search', + 'body' => '*', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + ], + '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/VectorSearch/v1/src/V1/resources/data_object_service_client_config.json b/owl-bot-staging/VectorSearch/v1/src/V1/resources/data_object_service_client_config.json new file mode 100644 index 000000000000..a78004bb0501 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/src/V1/resources/data_object_service_client_config.json @@ -0,0 +1,103 @@ +{ + "interfaces": { + "google.cloud.vectorsearch.v1.DataObjectService": { + "retry_codes": { + "no_retry_codes": [], + "retry_policy_1_codes": [ + "UNAVAILABLE" + ], + "retry_policy_3_codes": [ + "UNAVAILABLE" + ], + "retry_policy_4_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 + }, + "retry_policy_3_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 + }, + "retry_policy_4_params": { + "initial_retry_delay_millis": 1000, + "retry_delay_multiplier": 1.3, + "max_retry_delay_millis": 10000, + "initial_rpc_timeout_millis": 300000, + "rpc_timeout_multiplier": 1.0, + "max_rpc_timeout_millis": 300000, + "total_timeout_millis": 300000 + } + }, + "methods": { + "BatchCreateDataObjects": { + "timeout_millis": 300000, + "retry_codes_name": "retry_policy_4_codes", + "retry_params_name": "retry_policy_4_params" + }, + "BatchDeleteDataObjects": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_3_codes", + "retry_params_name": "retry_policy_3_params" + }, + "BatchUpdateDataObjects": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_3_codes", + "retry_params_name": "retry_policy_3_params" + }, + "CreateDataObject": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_3_codes", + "retry_params_name": "retry_policy_3_params" + }, + "DeleteDataObject": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_3_codes", + "retry_params_name": "retry_policy_3_params" + }, + "GetDataObject": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "UpdateDataObject": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_3_codes", + "retry_params_name": "retry_policy_3_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/VectorSearch/v1/src/V1/resources/data_object_service_descriptor_config.php b/owl-bot-staging/VectorSearch/v1/src/V1/resources/data_object_service_descriptor_config.php new file mode 100644 index 000000000000..a66571732eb9 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/src/V1/resources/data_object_service_descriptor_config.php @@ -0,0 +1,151 @@ + [ + 'google.cloud.vectorsearch.v1.DataObjectService' => [ + 'BatchCreateDataObjects' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\VectorSearch\V1\BatchCreateDataObjectsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'BatchDeleteDataObjects' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Protobuf\GPBEmpty', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'BatchUpdateDataObjects' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\VectorSearch\V1\BatchUpdateDataObjectsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateDataObject' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\VectorSearch\V1\DataObject', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'DeleteDataObject' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Protobuf\GPBEmpty', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetDataObject' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\VectorSearch\V1\DataObject', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'UpdateDataObject' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\VectorSearch\V1\DataObject', + 'headerParams' => [ + [ + 'keyName' => 'data_object.name', + 'fieldAccessors' => [ + 'getDataObject', + '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' => [ + 'collection' => 'projects/{project}/locations/{location}/collections/{collection}', + 'dataObject' => 'projects/{project}/locations/{location}/collections/{collection}/dataObjects/{dataObject}', + ], + ], + ], +]; diff --git a/owl-bot-staging/VectorSearch/v1/src/V1/resources/data_object_service_rest_client_config.php b/owl-bot-staging/VectorSearch/v1/src/V1/resources/data_object_service_rest_client_config.php new file mode 100644 index 000000000000..d92a9eabd1e4 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/src/V1/resources/data_object_service_rest_client_config.php @@ -0,0 +1,186 @@ + [ + '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.cloud.vectorsearch.v1.DataObjectService' => [ + 'BatchCreateDataObjects' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*/collections/*}/dataObjects:batchCreate', + 'body' => '*', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'BatchDeleteDataObjects' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*/collections/*}/dataObjects:batchDelete', + 'body' => '*', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'BatchUpdateDataObjects' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*/collections/*}/dataObjects:batchUpdate', + 'body' => '*', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'CreateDataObject' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*/collections/*}/dataObjects', + 'body' => 'data_object', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + 'queryParams' => [ + 'data_object_id', + ], + ], + 'DeleteDataObject' => [ + 'method' => 'delete', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/collections/*/dataObjects/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetDataObject' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/collections/*/dataObjects/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'UpdateDataObject' => [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{data_object.name=projects/*/locations/*/collections/*/dataObjects/*}', + 'body' => 'data_object', + 'placeholders' => [ + 'data_object.name' => [ + 'getters' => [ + 'getDataObject', + '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/VectorSearch/v1/src/V1/resources/vector_search_service_client_config.json b/owl-bot-staging/VectorSearch/v1/src/V1/resources/vector_search_service_client_config.json new file mode 100644 index 000000000000..e055528d9e03 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/src/V1/resources/vector_search_service_client_config.json @@ -0,0 +1,116 @@ +{ + "interfaces": { + "google.cloud.vectorsearch.v1.VectorSearchService": { + "retry_codes": { + "no_retry_codes": [], + "retry_policy_1_codes": [ + "UNAVAILABLE" + ], + "retry_policy_3_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 + }, + "retry_policy_3_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": { + "CreateCollection": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_3_codes", + "retry_params_name": "retry_policy_3_params" + }, + "CreateIndex": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_3_codes", + "retry_params_name": "retry_policy_3_params" + }, + "DeleteCollection": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_3_codes", + "retry_params_name": "retry_policy_3_params" + }, + "DeleteIndex": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_3_codes", + "retry_params_name": "retry_policy_3_params" + }, + "ExportDataObjects": { + "timeout_millis": 60000, + "retry_codes_name": "no_retry_codes", + "retry_params_name": "no_retry_params" + }, + "GetCollection": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "GetIndex": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ImportDataObjects": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_3_codes", + "retry_params_name": "retry_policy_3_params" + }, + "ListCollections": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ListIndexes": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "UpdateCollection": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_3_codes", + "retry_params_name": "retry_policy_3_params" + }, + "UpdateIndex": { + "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" + } + } + } + } +} diff --git a/owl-bot-staging/VectorSearch/v1/src/V1/resources/vector_search_service_descriptor_config.php b/owl-bot-staging/VectorSearch/v1/src/V1/resources/vector_search_service_descriptor_config.php new file mode 100644 index 000000000000..5e588fcd5a52 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/src/V1/resources/vector_search_service_descriptor_config.php @@ -0,0 +1,286 @@ + [ + 'google.cloud.vectorsearch.v1.VectorSearchService' => [ + 'CreateCollection' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\VectorSearch\V1\Collection', + 'metadataReturnType' => '\Google\Cloud\VectorSearch\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateIndex' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\VectorSearch\V1\Index', + 'metadataReturnType' => '\Google\Cloud\VectorSearch\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'DeleteCollection' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Protobuf\GPBEmpty', + 'metadataReturnType' => '\Google\Cloud\VectorSearch\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'DeleteIndex' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Protobuf\GPBEmpty', + 'metadataReturnType' => '\Google\Cloud\VectorSearch\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'ExportDataObjects' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\VectorSearch\V1\ExportDataObjectsResponse', + 'metadataReturnType' => '\Google\Cloud\VectorSearch\V1\ExportDataObjectsMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'ImportDataObjects' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\VectorSearch\V1\ImportDataObjectsResponse', + 'metadataReturnType' => '\Google\Cloud\VectorSearch\V1\ImportDataObjectsMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'UpdateCollection' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\VectorSearch\V1\Collection', + 'metadataReturnType' => '\Google\Cloud\VectorSearch\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'collection.name', + 'fieldAccessors' => [ + 'getCollection', + 'getName', + ], + ], + ], + ], + 'UpdateIndex' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\VectorSearch\V1\Index', + 'metadataReturnType' => '\Google\Cloud\VectorSearch\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'index.name', + 'fieldAccessors' => [ + 'getIndex', + 'getName', + ], + ], + ], + ], + 'GetCollection' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\VectorSearch\V1\Collection', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetIndex' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\VectorSearch\V1\Index', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'ListCollections' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getCollections', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\VectorSearch\V1\ListCollectionsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListIndexes' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getIndexes', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\VectorSearch\V1\ListIndexesResponse', + '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' => [ + 'collection' => 'projects/{project}/locations/{location}/collections/{collection}', + 'cryptoKey' => 'projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}', + 'index' => 'projects/{project}/locations/{location}/collections/{collection}/indexes/{index}', + 'location' => 'projects/{project}/locations/{location}', + ], + ], + ], +]; diff --git a/owl-bot-staging/VectorSearch/v1/src/V1/resources/vector_search_service_rest_client_config.php b/owl-bot-staging/VectorSearch/v1/src/V1/resources/vector_search_service_rest_client_config.php new file mode 100644 index 000000000000..e6f18f8e46f2 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/src/V1/resources/vector_search_service_rest_client_config.php @@ -0,0 +1,246 @@ + [ + '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.cloud.vectorsearch.v1.VectorSearchService' => [ + 'CreateCollection' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/collections', + 'body' => 'collection', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + 'queryParams' => [ + 'collection_id', + ], + ], + 'CreateIndex' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*/collections/*}/indexes', + 'body' => 'index', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + 'queryParams' => [ + 'index_id', + ], + ], + 'DeleteCollection' => [ + 'method' => 'delete', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/collections/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'DeleteIndex' => [ + 'method' => 'delete', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/collections/*/indexes/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'ExportDataObjects' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/collections/*}:exportDataObjects', + 'body' => '*', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetCollection' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/collections/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetIndex' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/collections/*/indexes/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'ImportDataObjects' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/collections/*}:importDataObjects', + 'body' => '*', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'ListCollections' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/collections', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListIndexes' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*/collections/*}/indexes', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'UpdateCollection' => [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{collection.name=projects/*/locations/*/collections/*}', + 'body' => 'collection', + 'placeholders' => [ + 'collection.name' => [ + 'getters' => [ + 'getCollection', + 'getName', + ], + ], + ], + ], + 'UpdateIndex' => [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{index.name=projects/*/locations/*/collections/*/indexes/*}', + 'body' => 'index', + 'placeholders' => [ + 'index.name' => [ + 'getters' => [ + 'getIndex', + '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/VectorSearch/v1/tests/Unit/V1/Client/DataObjectSearchServiceClientTest.php b/owl-bot-staging/VectorSearch/v1/tests/Unit/V1/Client/DataObjectSearchServiceClientTest.php new file mode 100644 index 000000000000..4fd194a1ff95 --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/tests/Unit/V1/Client/DataObjectSearchServiceClientTest.php @@ -0,0 +1,510 @@ +getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); + } + + /** @return DataObjectSearchServiceClient */ + private function createClient(array $options = []) + { + $options += [ + 'credentials' => $this->createCredentials(), + ]; + return new DataObjectSearchServiceClient($options); + } + + /** @test */ + public function aggregateDataObjectsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new AggregateDataObjectsResponse(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); + $aggregate = AggregationMethod::AGGREGATION_METHOD_UNSPECIFIED; + $request = (new AggregateDataObjectsRequest()) + ->setParent($formattedParent) + ->setAggregate($aggregate); + $response = $gapicClient->aggregateDataObjects($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vectorsearch.v1.DataObjectSearchService/AggregateDataObjects', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getAggregate(); + $this->assertProtobufEquals($aggregate, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function aggregateDataObjectsExceptionTest() + { + $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->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); + $aggregate = AggregationMethod::AGGREGATION_METHOD_UNSPECIFIED; + $request = (new AggregateDataObjectsRequest()) + ->setParent($formattedParent) + ->setAggregate($aggregate); + try { + $gapicClient->aggregateDataObjects($request); + // 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 batchSearchDataObjectsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new BatchSearchDataObjectsResponse(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); + $searches = []; + $request = (new BatchSearchDataObjectsRequest()) + ->setParent($formattedParent) + ->setSearches($searches); + $response = $gapicClient->batchSearchDataObjects($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vectorsearch.v1.DataObjectSearchService/BatchSearchDataObjects', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getSearches(); + $this->assertProtobufEquals($searches, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function batchSearchDataObjectsExceptionTest() + { + $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->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); + $searches = []; + $request = (new BatchSearchDataObjectsRequest()) + ->setParent($formattedParent) + ->setSearches($searches); + try { + $gapicClient->batchSearchDataObjects($request); + // 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 queryDataObjectsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $dataObjectsElement = new DataObject(); + $dataObjects = [ + $dataObjectsElement, + ]; + $expectedResponse = new QueryDataObjectsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setDataObjects($dataObjects); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); + $request = (new QueryDataObjectsRequest()) + ->setParent($formattedParent); + $response = $gapicClient->queryDataObjects($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getDataObjects()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vectorsearch.v1.DataObjectSearchService/QueryDataObjects', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function queryDataObjectsExceptionTest() + { + $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->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); + $request = (new QueryDataObjectsRequest()) + ->setParent($formattedParent); + try { + $gapicClient->queryDataObjects($request); + // 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 searchDataObjectsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $resultsElement = new SearchResult(); + $results = [ + $resultsElement, + ]; + $expectedResponse = new SearchDataObjectsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setResults($results); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); + $request = (new SearchDataObjectsRequest()) + ->setParent($formattedParent); + $response = $gapicClient->searchDataObjects($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getResults()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vectorsearch.v1.DataObjectSearchService/SearchDataObjects', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function searchDataObjectsExceptionTest() + { + $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->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); + $request = (new SearchDataObjectsRequest()) + ->setParent($formattedParent); + try { + $gapicClient->searchDataObjects($request); + // 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); + $request = new GetLocationRequest(); + $response = $gapicClient->getLocation($request); + $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); + $request = new GetLocationRequest(); + try { + $gapicClient->getLocation($request); + // 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); + $request = new ListLocationsRequest(); + $response = $gapicClient->listLocations($request); + $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); + $request = new ListLocationsRequest(); + try { + $gapicClient->listLocations($request); + // 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 aggregateDataObjectsAsyncTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new AggregateDataObjectsResponse(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); + $aggregate = AggregationMethod::AGGREGATION_METHOD_UNSPECIFIED; + $request = (new AggregateDataObjectsRequest()) + ->setParent($formattedParent) + ->setAggregate($aggregate); + $response = $gapicClient->aggregateDataObjectsAsync($request)->wait(); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vectorsearch.v1.DataObjectSearchService/AggregateDataObjects', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getAggregate(); + $this->assertProtobufEquals($aggregate, $actualValue); + $this->assertTrue($transport->isExhausted()); + } +} diff --git a/owl-bot-staging/VectorSearch/v1/tests/Unit/V1/Client/DataObjectServiceClientTest.php b/owl-bot-staging/VectorSearch/v1/tests/Unit/V1/Client/DataObjectServiceClientTest.php new file mode 100644 index 000000000000..4153f2fdcc4f --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/tests/Unit/V1/Client/DataObjectServiceClientTest.php @@ -0,0 +1,710 @@ +getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); + } + + /** @return DataObjectServiceClient */ + private function createClient(array $options = []) + { + $options += [ + 'credentials' => $this->createCredentials(), + ]; + return new DataObjectServiceClient($options); + } + + /** @test */ + public function batchCreateDataObjectsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new BatchCreateDataObjectsResponse(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); + $requests = []; + $request = (new BatchCreateDataObjectsRequest()) + ->setParent($formattedParent) + ->setRequests($requests); + $response = $gapicClient->batchCreateDataObjects($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vectorsearch.v1.DataObjectService/BatchCreateDataObjects', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getRequests(); + $this->assertProtobufEquals($requests, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function batchCreateDataObjectsExceptionTest() + { + $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->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); + $requests = []; + $request = (new BatchCreateDataObjectsRequest()) + ->setParent($formattedParent) + ->setRequests($requests); + try { + $gapicClient->batchCreateDataObjects($request); + // 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 batchDeleteDataObjectsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new GPBEmpty(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); + $requests = []; + $request = (new BatchDeleteDataObjectsRequest()) + ->setParent($formattedParent) + ->setRequests($requests); + $gapicClient->batchDeleteDataObjects($request); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vectorsearch.v1.DataObjectService/BatchDeleteDataObjects', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getRequests(); + $this->assertProtobufEquals($requests, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function batchDeleteDataObjectsExceptionTest() + { + $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->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); + $requests = []; + $request = (new BatchDeleteDataObjectsRequest()) + ->setParent($formattedParent) + ->setRequests($requests); + try { + $gapicClient->batchDeleteDataObjects($request); + // 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 batchUpdateDataObjectsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new BatchUpdateDataObjectsResponse(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); + $requests = []; + $request = (new BatchUpdateDataObjectsRequest()) + ->setParent($formattedParent) + ->setRequests($requests); + $response = $gapicClient->batchUpdateDataObjects($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vectorsearch.v1.DataObjectService/BatchUpdateDataObjects', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getRequests(); + $this->assertProtobufEquals($requests, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function batchUpdateDataObjectsExceptionTest() + { + $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->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); + $requests = []; + $request = (new BatchUpdateDataObjectsRequest()) + ->setParent($formattedParent) + ->setRequests($requests); + try { + $gapicClient->batchUpdateDataObjects($request); + // 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 createDataObjectTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $dataObjectId2 = 'dataObjectId21879679481'; + $etag = 'etag3123477'; + $expectedResponse = new DataObject(); + $expectedResponse->setName($name); + $expectedResponse->setDataObjectId($dataObjectId2); + $expectedResponse->setEtag($etag); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); + $dataObjectId = 'dataObjectId-806981690'; + $dataObject = new DataObject(); + $request = (new CreateDataObjectRequest()) + ->setParent($formattedParent) + ->setDataObjectId($dataObjectId) + ->setDataObject($dataObject); + $response = $gapicClient->createDataObject($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vectorsearch.v1.DataObjectService/CreateDataObject', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getDataObjectId(); + $this->assertProtobufEquals($dataObjectId, $actualValue); + $actualValue = $actualRequestObject->getDataObject(); + $this->assertProtobufEquals($dataObject, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function createDataObjectExceptionTest() + { + $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->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); + $dataObjectId = 'dataObjectId-806981690'; + $dataObject = new DataObject(); + $request = (new CreateDataObjectRequest()) + ->setParent($formattedParent) + ->setDataObjectId($dataObjectId) + ->setDataObject($dataObject); + try { + $gapicClient->createDataObject($request); + // 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 deleteDataObjectTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new GPBEmpty(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->dataObjectName('[PROJECT]', '[LOCATION]', '[COLLECTION]', '[DATAOBJECT]'); + $request = (new DeleteDataObjectRequest()) + ->setName($formattedName); + $gapicClient->deleteDataObject($request); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vectorsearch.v1.DataObjectService/DeleteDataObject', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function deleteDataObjectExceptionTest() + { + $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->dataObjectName('[PROJECT]', '[LOCATION]', '[COLLECTION]', '[DATAOBJECT]'); + $request = (new DeleteDataObjectRequest()) + ->setName($formattedName); + try { + $gapicClient->deleteDataObject($request); + // 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 getDataObjectTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $dataObjectId = 'dataObjectId-806981690'; + $etag = 'etag3123477'; + $expectedResponse = new DataObject(); + $expectedResponse->setName($name2); + $expectedResponse->setDataObjectId($dataObjectId); + $expectedResponse->setEtag($etag); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->dataObjectName('[PROJECT]', '[LOCATION]', '[COLLECTION]', '[DATAOBJECT]'); + $request = (new GetDataObjectRequest()) + ->setName($formattedName); + $response = $gapicClient->getDataObject($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vectorsearch.v1.DataObjectService/GetDataObject', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getDataObjectExceptionTest() + { + $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->dataObjectName('[PROJECT]', '[LOCATION]', '[COLLECTION]', '[DATAOBJECT]'); + $request = (new GetDataObjectRequest()) + ->setName($formattedName); + try { + $gapicClient->getDataObject($request); + // 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 updateDataObjectTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name = 'name3373707'; + $dataObjectId = 'dataObjectId-806981690'; + $etag = 'etag3123477'; + $expectedResponse = new DataObject(); + $expectedResponse->setName($name); + $expectedResponse->setDataObjectId($dataObjectId); + $expectedResponse->setEtag($etag); + $transport->addResponse($expectedResponse); + // Mock request + $dataObject = new DataObject(); + $request = (new UpdateDataObjectRequest()) + ->setDataObject($dataObject); + $response = $gapicClient->updateDataObject($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vectorsearch.v1.DataObjectService/UpdateDataObject', $actualFuncCall); + $actualValue = $actualRequestObject->getDataObject(); + $this->assertProtobufEquals($dataObject, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function updateDataObjectExceptionTest() + { + $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 + $dataObject = new DataObject(); + $request = (new UpdateDataObjectRequest()) + ->setDataObject($dataObject); + try { + $gapicClient->updateDataObject($request); + // 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); + $request = new GetLocationRequest(); + $response = $gapicClient->getLocation($request); + $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); + $request = new GetLocationRequest(); + try { + $gapicClient->getLocation($request); + // 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); + $request = new ListLocationsRequest(); + $response = $gapicClient->listLocations($request); + $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); + $request = new ListLocationsRequest(); + try { + $gapicClient->listLocations($request); + // 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 batchCreateDataObjectsAsyncTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new BatchCreateDataObjectsResponse(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); + $requests = []; + $request = (new BatchCreateDataObjectsRequest()) + ->setParent($formattedParent) + ->setRequests($requests); + $response = $gapicClient->batchCreateDataObjectsAsync($request)->wait(); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vectorsearch.v1.DataObjectService/BatchCreateDataObjects', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualRequestObject->getRequests(); + $this->assertProtobufEquals($requests, $actualValue); + $this->assertTrue($transport->isExhausted()); + } +} diff --git a/owl-bot-staging/VectorSearch/v1/tests/Unit/V1/Client/VectorSearchServiceClientTest.php b/owl-bot-staging/VectorSearch/v1/tests/Unit/V1/Client/VectorSearchServiceClientTest.php new file mode 100644 index 000000000000..e78cd9f0334a --- /dev/null +++ b/owl-bot-staging/VectorSearch/v1/tests/Unit/V1/Client/VectorSearchServiceClientTest.php @@ -0,0 +1,1599 @@ +getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); + } + + /** @return VectorSearchServiceClient */ + private function createClient(array $options = []) + { + $options += [ + 'credentials' => $this->createCredentials(), + ]; + return new VectorSearchServiceClient($options); + } + + /** @test */ + public function createCollectionTest() + { + $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/createCollectionTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $expectedResponse = new Collection(); + $expectedResponse->setName($name); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/createCollectionTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); + $collectionId = 'collectionId-821242276'; + $collection = new Collection(); + $request = (new CreateCollectionRequest()) + ->setParent($formattedParent) + ->setCollectionId($collectionId) + ->setCollection($collection); + $response = $gapicClient->createCollection($request); + $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.vectorsearch.v1.VectorSearchService/CreateCollection', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualApiRequestObject->getCollectionId(); + $this->assertProtobufEquals($collectionId, $actualValue); + $actualValue = $actualApiRequestObject->getCollection(); + $this->assertProtobufEquals($collection, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createCollectionTest'); + $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 createCollectionExceptionTest() + { + $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/createCollectionTest'); + $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]'); + $collectionId = 'collectionId-821242276'; + $collection = new Collection(); + $request = (new CreateCollectionRequest()) + ->setParent($formattedParent) + ->setCollectionId($collectionId) + ->setCollection($collection); + $response = $gapicClient->createCollection($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createCollectionTest'); + 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 createIndexTest() + { + $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/createIndexTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $indexField = 'indexField1673840461'; + $expectedResponse = new Index(); + $expectedResponse->setName($name); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $expectedResponse->setIndexField($indexField); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/createIndexTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedParent = $gapicClient->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); + $indexId = 'indexId112508840'; + $index = new Index(); + $indexIndexField = 'indexIndexField-1984372294'; + $index->setIndexField($indexIndexField); + $request = (new CreateIndexRequest()) + ->setParent($formattedParent) + ->setIndexId($indexId) + ->setIndex($index); + $response = $gapicClient->createIndex($request); + $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.vectorsearch.v1.VectorSearchService/CreateIndex', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualApiRequestObject->getIndexId(); + $this->assertProtobufEquals($indexId, $actualValue); + $actualValue = $actualApiRequestObject->getIndex(); + $this->assertProtobufEquals($index, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createIndexTest'); + $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 createIndexExceptionTest() + { + $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/createIndexTest'); + $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->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); + $indexId = 'indexId112508840'; + $index = new Index(); + $indexIndexField = 'indexIndexField-1984372294'; + $index->setIndexField($indexIndexField); + $request = (new CreateIndexRequest()) + ->setParent($formattedParent) + ->setIndexId($indexId) + ->setIndex($index); + $response = $gapicClient->createIndex($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createIndexTest'); + 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 deleteCollectionTest() + { + $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/deleteCollectionTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $expectedResponse = new GPBEmpty(); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/deleteCollectionTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedName = $gapicClient->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); + $request = (new DeleteCollectionRequest()) + ->setName($formattedName); + $response = $gapicClient->deleteCollection($request); + $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.vectorsearch.v1.VectorSearchService/DeleteCollection', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/deleteCollectionTest'); + $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 deleteCollectionExceptionTest() + { + $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/deleteCollectionTest'); + $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->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); + $request = (new DeleteCollectionRequest()) + ->setName($formattedName); + $response = $gapicClient->deleteCollection($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/deleteCollectionTest'); + 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 deleteIndexTest() + { + $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/deleteIndexTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $expectedResponse = new GPBEmpty(); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/deleteIndexTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedName = $gapicClient->indexName('[PROJECT]', '[LOCATION]', '[COLLECTION]', '[INDEX]'); + $request = (new DeleteIndexRequest()) + ->setName($formattedName); + $response = $gapicClient->deleteIndex($request); + $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.vectorsearch.v1.VectorSearchService/DeleteIndex', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/deleteIndexTest'); + $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 deleteIndexExceptionTest() + { + $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/deleteIndexTest'); + $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->indexName('[PROJECT]', '[LOCATION]', '[COLLECTION]', '[INDEX]'); + $request = (new DeleteIndexRequest()) + ->setName($formattedName); + $response = $gapicClient->deleteIndex($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/deleteIndexTest'); + 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 exportDataObjectsTest() + { + $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/exportDataObjectsTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $expectedResponse = new ExportDataObjectsResponse(); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/exportDataObjectsTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedName = $gapicClient->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); + $request = (new ExportDataObjectsRequest()) + ->setName($formattedName); + $response = $gapicClient->exportDataObjects($request); + $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.vectorsearch.v1.VectorSearchService/ExportDataObjects', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/exportDataObjectsTest'); + $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 exportDataObjectsExceptionTest() + { + $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/exportDataObjectsTest'); + $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->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); + $request = (new ExportDataObjectsRequest()) + ->setName($formattedName); + $response = $gapicClient->exportDataObjects($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/exportDataObjectsTest'); + 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 getCollectionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $expectedResponse = new Collection(); + $expectedResponse->setName($name2); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); + $request = (new GetCollectionRequest()) + ->setName($formattedName); + $response = $gapicClient->getCollection($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vectorsearch.v1.VectorSearchService/GetCollection', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getCollectionExceptionTest() + { + $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->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); + $request = (new GetCollectionRequest()) + ->setName($formattedName); + try { + $gapicClient->getCollection($request); + // 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 getIndexTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $indexField = 'indexField1673840461'; + $expectedResponse = new Index(); + $expectedResponse->setName($name2); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $expectedResponse->setIndexField($indexField); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->indexName('[PROJECT]', '[LOCATION]', '[COLLECTION]', '[INDEX]'); + $request = (new GetIndexRequest()) + ->setName($formattedName); + $response = $gapicClient->getIndex($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vectorsearch.v1.VectorSearchService/GetIndex', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getIndexExceptionTest() + { + $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->indexName('[PROJECT]', '[LOCATION]', '[COLLECTION]', '[INDEX]'); + $request = (new GetIndexRequest()) + ->setName($formattedName); + try { + $gapicClient->getIndex($request); + // 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 importDataObjectsTest() + { + $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/importDataObjectsTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $expectedResponse = new ImportDataObjectsResponse(); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/importDataObjectsTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedName = $gapicClient->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); + $request = (new ImportDataObjectsRequest()) + ->setName($formattedName); + $response = $gapicClient->importDataObjects($request); + $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.vectorsearch.v1.VectorSearchService/ImportDataObjects', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/importDataObjectsTest'); + $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 importDataObjectsExceptionTest() + { + $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/importDataObjectsTest'); + $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->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); + $request = (new ImportDataObjectsRequest()) + ->setName($formattedName); + $response = $gapicClient->importDataObjects($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/importDataObjectsTest'); + 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 listCollectionsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $collectionsElement = new Collection(); + $collections = [ + $collectionsElement, + ]; + $expectedResponse = new ListCollectionsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setCollections($collections); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); + $request = (new ListCollectionsRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listCollections($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getCollections()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vectorsearch.v1.VectorSearchService/ListCollections', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listCollectionsExceptionTest() + { + $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]'); + $request = (new ListCollectionsRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listCollections($request); + // 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 listIndexesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $indexesElement = new Index(); + $indexes = [ + $indexesElement, + ]; + $expectedResponse = new ListIndexesResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setIndexes($indexes); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); + $request = (new ListIndexesRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listIndexes($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getIndexes()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vectorsearch.v1.VectorSearchService/ListIndexes', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listIndexesExceptionTest() + { + $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->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); + $request = (new ListIndexesRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listIndexes($request); + // 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 updateCollectionTest() + { + $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/updateCollectionTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $expectedResponse = new Collection(); + $expectedResponse->setName($name); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/updateCollectionTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $collection = new Collection(); + $request = (new UpdateCollectionRequest()) + ->setCollection($collection); + $response = $gapicClient->updateCollection($request); + $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.vectorsearch.v1.VectorSearchService/UpdateCollection', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getCollection(); + $this->assertProtobufEquals($collection, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updateCollectionTest'); + $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 updateCollectionExceptionTest() + { + $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/updateCollectionTest'); + $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 + $collection = new Collection(); + $request = (new UpdateCollectionRequest()) + ->setCollection($collection); + $response = $gapicClient->updateCollection($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updateCollectionTest'); + 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 updateIndexTest() + { + $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/updateIndexTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $indexField = 'indexField1673840461'; + $expectedResponse = new Index(); + $expectedResponse->setName($name); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $expectedResponse->setIndexField($indexField); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/updateIndexTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $index = new Index(); + $indexIndexField = 'indexIndexField-1984372294'; + $index->setIndexField($indexIndexField); + $request = (new UpdateIndexRequest()) + ->setIndex($index); + $response = $gapicClient->updateIndex($request); + $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.vectorsearch.v1.VectorSearchService/UpdateIndex', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getIndex(); + $this->assertProtobufEquals($index, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updateIndexTest'); + $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 updateIndexExceptionTest() + { + $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/updateIndexTest'); + $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 + $index = new Index(); + $indexIndexField = 'indexIndexField-1984372294'; + $index->setIndexField($indexIndexField); + $request = (new UpdateIndexRequest()) + ->setIndex($index); + $response = $gapicClient->updateIndex($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updateIndexTest'); + 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); + $request = new GetLocationRequest(); + $response = $gapicClient->getLocation($request); + $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); + $request = new GetLocationRequest(); + try { + $gapicClient->getLocation($request); + // 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); + $request = new ListLocationsRequest(); + $response = $gapicClient->listLocations($request); + $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); + $request = new ListLocationsRequest(); + try { + $gapicClient->listLocations($request); + // 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 createCollectionAsyncTest() + { + $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/createCollectionTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $displayName = 'displayName1615086568'; + $description = 'description-1724546052'; + $expectedResponse = new Collection(); + $expectedResponse->setName($name); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setDescription($description); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/createCollectionTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); + $collectionId = 'collectionId-821242276'; + $collection = new Collection(); + $request = (new CreateCollectionRequest()) + ->setParent($formattedParent) + ->setCollectionId($collectionId) + ->setCollection($collection); + $response = $gapicClient->createCollectionAsync($request)->wait(); + $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.vectorsearch.v1.VectorSearchService/CreateCollection', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualApiRequestObject->getCollectionId(); + $this->assertProtobufEquals($collectionId, $actualValue); + $actualValue = $actualApiRequestObject->getCollection(); + $this->assertProtobufEquals($collection, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createCollectionTest'); + $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()); + } +} diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/GPBMetadata/Google/Cloud/Vmwareengine/V1/Vmwareengine.php b/owl-bot-staging/VmwareEngine/v1/proto/src/GPBMetadata/Google/Cloud/Vmwareengine/V1/Vmwareengine.php new file mode 100644 index 000000000000..c3d849f4d60b --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/GPBMetadata/Google/Cloud/Vmwareengine/V1/Vmwareengine.php @@ -0,0 +1,34 @@ +internalAddGeneratedFile( + "\x0A\x94\x84\x02\x0A/google/cloud/vmwareengine/v1/vmwareengine.proto\x12\x1Cgoogle.cloud.vmwareengine.v1\x1A\x17google/api/client.proto\x1A\x1Fgoogle/api/field_behavior.proto\x1A\x1Bgoogle/api/field_info.proto\x1A\x19google/api/resource.proto\x1A9google/cloud/vmwareengine/v1/vmwareengine_resources.proto\x1A#google/longrunning/operations.proto\x1A\x1Bgoogle/protobuf/empty.proto\x1A google/protobuf/field_mask.proto\x1A\x1Fgoogle/protobuf/timestamp.proto\"\x9E\x01\x0A\x18ListPrivateCloudsRequest\x129\x0A\x06parent\x18\x01 \x01(\x09B)\xE0A\x02\xFAA#\x0A!locations.googleapis.com/Location\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\x12\x0E\x0A\x06filter\x18\x04 \x01(\x09\x12\x10\x0A\x08order_by\x18\x05 \x01(\x09\"\x8D\x01\x0A\x19ListPrivateCloudsResponse\x12B\x0A\x0Eprivate_clouds\x18\x01 \x03(\x0B2*.google.cloud.vmwareengine.v1.PrivateCloud\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\x12\x13\x0A\x0Bunreachable\x18\x03 \x03(\x09\"X\x0A\x16GetPrivateCloudRequest\x12>\x0A\x04name\x18\x01 \x01(\x09B0\xE0A\x02\xFAA*\x0A(vmwareengine.googleapis.com/PrivateCloud\"\xF2\x01\x0A\x19CreatePrivateCloudRequest\x129\x0A\x06parent\x18\x01 \x01(\x09B)\xE0A\x02\xFAA#\x0A!locations.googleapis.com/Location\x12\x1D\x0A\x10private_cloud_id\x18\x02 \x01(\x09B\x03\xE0A\x02\x12F\x0A\x0Dprivate_cloud\x18\x03 \x01(\x0B2*.google.cloud.vmwareengine.v1.PrivateCloudB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x04 \x01(\x09B\x03\xE0A\x01\x12\x1A\x0A\x0Dvalidate_only\x18\x05 \x01(\x08B\x03\xE0A\x01\"\xB2\x01\x0A\x19UpdatePrivateCloudRequest\x12F\x0A\x0Dprivate_cloud\x18\x01 \x01(\x0B2*.google.cloud.vmwareengine.v1.PrivateCloudB\x03\xE0A\x02\x124\x0A\x0Bupdate_mask\x18\x02 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x03\xE0A\x01\"\xB7\x01\x0A\x19DeletePrivateCloudRequest\x12>\x0A\x04name\x18\x01 \x01(\x09B0\xE0A\x02\xFAA*\x0A(vmwareengine.googleapis.com/PrivateCloud\x12\x17\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x03\xE0A\x01\x12\x12\x0A\x05force\x18\x03 \x01(\x08B\x03\xE0A\x01\x12\x1D\x0A\x0Bdelay_hours\x18\x04 \x01(\x05B\x03\xE0A\x01H\x00\x88\x01\x01B\x0E\x0A\x0C_delay_hours\"v\x0A\x1BUndeletePrivateCloudRequest\x12>\x0A\x04name\x18\x01 \x01(\x09B0\xE0A\x02\xFAA*\x0A(vmwareengine.googleapis.com/PrivateCloud\x12\x17\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x03\xE0A\x01\"\xA0\x01\x0A\x13ListClustersRequest\x12@\x0A\x06parent\x18\x01 \x01(\x09B0\xE0A\x02\xFAA*\x0A(vmwareengine.googleapis.com/PrivateCloud\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\x12\x0E\x0A\x06filter\x18\x04 \x01(\x09\x12\x10\x0A\x08order_by\x18\x05 \x01(\x09\"}\x0A\x14ListClustersResponse\x127\x0A\x08clusters\x18\x01 \x03(\x0B2%.google.cloud.vmwareengine.v1.Cluster\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\x12\x13\x0A\x0Bunreachable\x18\x03 \x03(\x09\"N\x0A\x11GetClusterRequest\x129\x0A\x04name\x18\x01 \x01(\x09B+\xE0A\x02\xFAA%\x0A#vmwareengine.googleapis.com/Cluster\"\xE3\x01\x0A\x14CreateClusterRequest\x12@\x0A\x06parent\x18\x01 \x01(\x09B0\xE0A\x02\xFAA*\x0A(vmwareengine.googleapis.com/PrivateCloud\x12\x17\x0A\x0Acluster_id\x18\x02 \x01(\x09B\x03\xE0A\x02\x12;\x0A\x07cluster\x18\x03 \x01(\x0B2%.google.cloud.vmwareengine.v1.ClusterB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x04 \x01(\x09B\x03\xE0A\x01\x12\x1A\x0A\x0Dvalidate_only\x18\x05 \x01(\x08B\x03\xE0A\x01\"\xBE\x01\x0A\x14UpdateClusterRequest\x124\x0A\x0Bupdate_mask\x18\x01 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x02\x12;\x0A\x07cluster\x18\x02 \x01(\x0B2%.google.cloud.vmwareengine.v1.ClusterB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x03\xE0A\x01\x12\x1A\x0A\x0Dvalidate_only\x18\x04 \x01(\x08B\x03\xE0A\x01\"j\x0A\x14DeleteClusterRequest\x129\x0A\x04name\x18\x01 \x01(\x09B+\xE0A\x02\xFAA%\x0A#vmwareengine.googleapis.com/Cluster\x12\x17\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x03\xE0A\x01\"v\x0A\x10ListNodesRequest\x12;\x0A\x06parent\x18\x01 \x01(\x09B+\xE0A\x02\xFAA%\x0A#vmwareengine.googleapis.com/Cluster\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\"_\x0A\x11ListNodesResponse\x121\x0A\x05nodes\x18\x01 \x03(\x0B2\".google.cloud.vmwareengine.v1.Node\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\"H\x0A\x0EGetNodeRequest\x126\x0A\x04name\x18\x01 \x01(\x09B(\xE0A\x02\xFAA\"\x0A vmwareengine.googleapis.com/Node\"\xA9\x01\x0A\x1CListExternalAddressesRequest\x12@\x0A\x06parent\x18\x01 \x01(\x09B0\xE0A\x02\xFAA*\x0A(vmwareengine.googleapis.com/PrivateCloud\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\x12\x0E\x0A\x06filter\x18\x04 \x01(\x09\x12\x10\x0A\x08order_by\x18\x05 \x01(\x09\"\x98\x01\x0A\x1DListExternalAddressesResponse\x12I\x0A\x12external_addresses\x18\x01 \x03(\x0B2-.google.cloud.vmwareengine.v1.ExternalAddress\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\x12\x13\x0A\x0Bunreachable\x18\x03 \x03(\x09\"\x9E\x01\x0A*FetchNetworkPolicyExternalAddressesRequest\x12I\x0A\x0Enetwork_policy\x18\x01 \x01(\x09B1\xE0A\x02\xFAA+\x0A)vmwareengine.googleapis.com/NetworkPolicy\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\"\x91\x01\x0A+FetchNetworkPolicyExternalAddressesResponse\x12I\x0A\x12external_addresses\x18\x01 \x03(\x0B2-.google.cloud.vmwareengine.v1.ExternalAddress\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\"^\x0A\x19GetExternalAddressRequest\x12A\x0A\x04name\x18\x01 \x01(\x09B3\xE0A\x02\xFAA-\x0A+vmwareengine.googleapis.com/ExternalAddress\"\xE9\x01\x0A\x1CCreateExternalAddressRequest\x12@\x0A\x06parent\x18\x01 \x01(\x09B0\xE0A\x02\xFAA*\x0A(vmwareengine.googleapis.com/PrivateCloud\x12L\x0A\x10external_address\x18\x02 \x01(\x0B2-.google.cloud.vmwareengine.v1.ExternalAddressB\x03\xE0A\x02\x12 \x0A\x13external_address_id\x18\x03 \x01(\x09B\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x04 \x01(\x09B\x03\xE0A\x01\"\xBB\x01\x0A\x1CUpdateExternalAddressRequest\x124\x0A\x0Bupdate_mask\x18\x01 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x02\x12L\x0A\x10external_address\x18\x02 \x01(\x0B2-.google.cloud.vmwareengine.v1.ExternalAddressB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x03\xE0A\x01\"z\x0A\x1CDeleteExternalAddressRequest\x12A\x0A\x04name\x18\x01 \x01(\x09B3\xE0A\x02\xFAA-\x0A+vmwareengine.googleapis.com/ExternalAddress\x12\x17\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x03\xE0A\x01\"}\x0A\x12ListSubnetsRequest\x12@\x0A\x06parent\x18\x01 \x01(\x09B0\xE0A\x02\xFAA*\x0A(vmwareengine.googleapis.com/PrivateCloud\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\"z\x0A\x13ListSubnetsResponse\x125\x0A\x07subnets\x18\x01 \x03(\x0B2\$.google.cloud.vmwareengine.v1.Subnet\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\x12\x13\x0A\x0Bunreachable\x18\x03 \x03(\x09\"L\x0A\x10GetSubnetRequest\x128\x0A\x04name\x18\x01 \x01(\x09B*\xE0A\x02\xFAA\$\x0A\"vmwareengine.googleapis.com/Subnet\"\x86\x01\x0A\x13UpdateSubnetRequest\x124\x0A\x0Bupdate_mask\x18\x01 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x02\x129\x0A\x06subnet\x18\x02 \x01(\x0B2\$.google.cloud.vmwareengine.v1.SubnetB\x03\xE0A\x02\"\xAC\x01\x0A\x1EListExternalAccessRulesRequest\x12A\x0A\x06parent\x18\x01 \x01(\x09B1\xE0A\x02\xFAA+\x0A)vmwareengine.googleapis.com/NetworkPolicy\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\x12\x0E\x0A\x06filter\x18\x04 \x01(\x09\x12\x10\x0A\x08order_by\x18\x05 \x01(\x09\"\xA0\x01\x0A\x1FListExternalAccessRulesResponse\x12O\x0A\x15external_access_rules\x18\x01 \x03(\x0B20.google.cloud.vmwareengine.v1.ExternalAccessRule\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\x12\x13\x0A\x0Bunreachable\x18\x03 \x03(\x09\"d\x0A\x1CGetExternalAccessRuleRequest\x12D\x0A\x04name\x18\x01 \x01(\x09B6\xE0A\x02\xFAA0\x0A.vmwareengine.googleapis.com/ExternalAccessRule\"\xF3\x01\x0A\x1FCreateExternalAccessRuleRequest\x12A\x0A\x06parent\x18\x01 \x01(\x09B1\xE0A\x02\xFAA+\x0A)vmwareengine.googleapis.com/NetworkPolicy\x12S\x0A\x14external_access_rule\x18\x02 \x01(\x0B20.google.cloud.vmwareengine.v1.ExternalAccessRuleB\x03\xE0A\x02\x12\$\x0A\x17external_access_rule_id\x18\x03 \x01(\x09B\x03\xE0A\x02\x12\x12\x0A\x0Arequest_id\x18\x04 \x01(\x09\"\xC5\x01\x0A\x1FUpdateExternalAccessRuleRequest\x124\x0A\x0Bupdate_mask\x18\x01 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x02\x12S\x0A\x14external_access_rule\x18\x02 \x01(\x0B20.google.cloud.vmwareengine.v1.ExternalAccessRuleB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x03\xE0A\x01\"\x80\x01\x0A\x1FDeleteExternalAccessRuleRequest\x12D\x0A\x04name\x18\x01 \x01(\x09B6\xE0A\x02\xFAA0\x0A.vmwareengine.googleapis.com/ExternalAccessRule\x12\x17\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x03\xE0A\x01\"\xA6\x01\x0A\x19ListLoggingServersRequest\x12@\x0A\x06parent\x18\x01 \x01(\x09B0\xE0A\x02\xFAA*\x0A(vmwareengine.googleapis.com/PrivateCloud\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\x12\x0E\x0A\x06filter\x18\x04 \x01(\x09\x12\x10\x0A\x08order_by\x18\x05 \x01(\x09\"\x90\x01\x0A\x1AListLoggingServersResponse\x12D\x0A\x0Flogging_servers\x18\x01 \x03(\x0B2+.google.cloud.vmwareengine.v1.LoggingServer\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\x12\x13\x0A\x0Bunreachable\x18\x03 \x03(\x09\"Z\x0A\x17GetLoggingServerRequest\x12?\x0A\x04name\x18\x01 \x01(\x09B1\xE0A\x02\xFAA+\x0A)vmwareengine.googleapis.com/LoggingServer\"\xE1\x01\x0A\x1ACreateLoggingServerRequest\x12@\x0A\x06parent\x18\x01 \x01(\x09B0\xE0A\x02\xFAA*\x0A(vmwareengine.googleapis.com/PrivateCloud\x12H\x0A\x0Elogging_server\x18\x02 \x01(\x0B2+.google.cloud.vmwareengine.v1.LoggingServerB\x03\xE0A\x02\x12\x1E\x0A\x11logging_server_id\x18\x03 \x01(\x09B\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x04 \x01(\x09B\x03\xE0A\x01\"\xB5\x01\x0A\x1AUpdateLoggingServerRequest\x124\x0A\x0Bupdate_mask\x18\x01 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x02\x12H\x0A\x0Elogging_server\x18\x02 \x01(\x0B2+.google.cloud.vmwareengine.v1.LoggingServerB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x03\xE0A\x01\"v\x0A\x1ADeleteLoggingServerRequest\x12?\x0A\x04name\x18\x01 \x01(\x09B1\xE0A\x02\xFAA+\x0A)vmwareengine.googleapis.com/LoggingServer\x12\x17\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x03\xE0A\x01\"\x80\x02\x0A\x11OperationMetadata\x124\x0A\x0Bcreate_time\x18\x01 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x121\x0A\x08end_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12\x13\x0A\x06target\x18\x03 \x01(\x09B\x03\xE0A\x03\x12\x11\x0A\x04verb\x18\x04 \x01(\x09B\x03\xE0A\x03\x12\x1B\x0A\x0Estatus_message\x18\x05 \x01(\x09B\x03\xE0A\x03\x12#\x0A\x16requested_cancellation\x18\x06 \x01(\x08B\x03\xE0A\x03\x12\x18\x0A\x0Bapi_version\x18\x07 \x01(\x09B\x03\xE0A\x03\"\x88\x01\x0A\x14ListNodeTypesRequest\x129\x0A\x06parent\x18\x01 \x01(\x09B)\xE0A\x02\xFAA#\x0A!locations.googleapis.com/Location\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\x12\x0E\x0A\x06filter\x18\x04 \x01(\x09\"\x81\x01\x0A\x15ListNodeTypesResponse\x12:\x0A\x0Anode_types\x18\x01 \x03(\x0B2&.google.cloud.vmwareengine.v1.NodeType\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\x12\x13\x0A\x0Bunreachable\x18\x03 \x03(\x09\"P\x0A\x12GetNodeTypeRequest\x12:\x0A\x04name\x18\x01 \x01(\x09B,\xE0A\x02\xFAA&\x0A\$vmwareengine.googleapis.com/NodeType\"d\x0A\x19ShowNsxCredentialsRequest\x12G\x0A\x0Dprivate_cloud\x18\x01 \x01(\x09B0\xE0A\x02\xFAA*\x0A(vmwareengine.googleapis.com/PrivateCloud\"\x7F\x0A\x1DShowVcenterCredentialsRequest\x12G\x0A\x0Dprivate_cloud\x18\x01 \x01(\x09B0\xE0A\x02\xFAA*\x0A(vmwareengine.googleapis.com/PrivateCloud\x12\x15\x0A\x08username\x18\x02 \x01(\x09B\x03\xE0A\x01\"~\x0A\x1AResetNsxCredentialsRequest\x12G\x0A\x0Dprivate_cloud\x18\x01 \x01(\x09B0\xE0A\x02\xFAA*\x0A(vmwareengine.googleapis.com/PrivateCloud\x12\x17\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x03\xE0A\x01\"\x99\x01\x0A\x1EResetVcenterCredentialsRequest\x12G\x0A\x0Dprivate_cloud\x18\x01 \x01(\x09B0\xE0A\x02\xFAA*\x0A(vmwareengine.googleapis.com/PrivateCloud\x12\x17\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x03\xE0A\x01\x12\x15\x0A\x08username\x18\x03 \x01(\x09B\x03\xE0A\x01\"\x9A\x01\x0A\x1DListHcxActivationKeysResponse\x12K\x0A\x13hcx_activation_keys\x18\x01 \x03(\x0B2..google.cloud.vmwareengine.v1.HcxActivationKey\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\x12\x13\x0A\x0Bunreachable\x18\x03 \x03(\x09\"\x87\x01\x0A\x1CListHcxActivationKeysRequest\x12@\x0A\x06parent\x18\x01 \x01(\x09B0\xE0A\x02\xFAA*\x0A(vmwareengine.googleapis.com/PrivateCloud\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\"`\x0A\x1AGetHcxActivationKeyRequest\x12B\x0A\x04name\x18\x01 \x01(\x09B4\xE0A\x02\xFAA.\x0A,vmwareengine.googleapis.com/HcxActivationKey\"\xEA\x01\x0A\x1DCreateHcxActivationKeyRequest\x12@\x0A\x06parent\x18\x01 \x01(\x09B0\xE0A\x02\xFAA*\x0A(vmwareengine.googleapis.com/PrivateCloud\x12O\x0A\x12hcx_activation_key\x18\x02 \x01(\x0B2..google.cloud.vmwareengine.v1.HcxActivationKeyB\x03\xE0A\x02\x12\"\x0A\x15hcx_activation_key_id\x18\x03 \x01(\x09B\x03\xE0A\x02\x12\x12\x0A\x0Arequest_id\x18\x04 \x01(\x09\"Z\x0A\x17GetDnsForwardingRequest\x12?\x0A\x04name\x18\x01 \x01(\x09B1\xE0A\x02\xFAA+\x0A)vmwareengine.googleapis.com/DnsForwarding\"\xB5\x01\x0A\x1AUpdateDnsForwardingRequest\x12H\x0A\x0Edns_forwarding\x18\x01 \x01(\x0B2+.google.cloud.vmwareengine.v1.DnsForwardingB\x03\xE0A\x02\x124\x0A\x0Bupdate_mask\x18\x02 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x03\xE0A\x01\"\xDE\x01\x0A\x1BCreateNetworkPeeringRequest\x129\x0A\x06parent\x18\x01 \x01(\x09B)\xE0A\x02\xFAA#\x0A!locations.googleapis.com/Location\x12\x1F\x0A\x12network_peering_id\x18\x02 \x01(\x09B\x03\xE0A\x02\x12J\x0A\x0Fnetwork_peering\x18\x03 \x01(\x0B2,.google.cloud.vmwareengine.v1.NetworkPeeringB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x04 \x01(\x09B\x03\xE0A\x01\"x\x0A\x1BDeleteNetworkPeeringRequest\x12@\x0A\x04name\x18\x01 \x01(\x09B2\xE0A\x02\xFAA,\x0A*vmwareengine.googleapis.com/NetworkPeering\x12\x17\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x03\xE0A\x01\"\\\x0A\x18GetNetworkPeeringRequest\x12@\x0A\x04name\x18\x01 \x01(\x09B2\xE0A\x02\xFAA,\x0A*vmwareengine.googleapis.com/NetworkPeering\"\xA9\x01\x0A\x1AListNetworkPeeringsRequest\x12B\x0A\x06parent\x18\x01 \x01(\x09B2\xE0A\x02\xFAA,\x12*vmwareengine.googleapis.com/NetworkPeering\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\x12\x0E\x0A\x06filter\x18\x04 \x01(\x09\x12\x10\x0A\x08order_by\x18\x05 \x01(\x09\"\xB8\x01\x0A\x1BUpdateNetworkPeeringRequest\x12J\x0A\x0Fnetwork_peering\x18\x01 \x01(\x0B2,.google.cloud.vmwareengine.v1.NetworkPeeringB\x03\xE0A\x02\x124\x0A\x0Bupdate_mask\x18\x02 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x03\xE0A\x01\"\x93\x01\x0A\x1BListNetworkPeeringsResponse\x12F\x0A\x10network_peerings\x18\x01 \x03(\x0B2,.google.cloud.vmwareengine.v1.NetworkPeering\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\x12\x13\x0A\x0Bunreachable\x18\x03 \x03(\x09\"\x95\x01\x0A\x18ListPeeringRoutesRequest\x12B\x0A\x06parent\x18\x01 \x01(\x09B2\xE0A\x02\xFAA,\x0A*vmwareengine.googleapis.com/NetworkPeering\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\x12\x0E\x0A\x06filter\x18\x06 \x01(\x09\"x\x0A\x19ListPeeringRoutesResponse\x12B\x0A\x0Epeering_routes\x18\x01 \x03(\x0B2*.google.cloud.vmwareengine.v1.PeeringRoute\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\"\xA8\x01\x0A\x1AListNetworkPoliciesRequest\x12A\x0A\x06parent\x18\x01 \x01(\x09B1\xE0A\x02\xFAA+\x12)vmwareengine.googleapis.com/NetworkPolicy\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\x12\x0E\x0A\x06filter\x18\x04 \x01(\x09\x12\x10\x0A\x08order_by\x18\x05 \x01(\x09\"\x92\x01\x0A\x1BListNetworkPoliciesResponse\x12E\x0A\x10network_policies\x18\x01 \x03(\x0B2+.google.cloud.vmwareengine.v1.NetworkPolicy\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\x12\x13\x0A\x0Bunreachable\x18\x03 \x03(\x09\"Z\x0A\x17GetNetworkPolicyRequest\x12?\x0A\x04name\x18\x01 \x01(\x09B1\xE0A\x02\xFAA+\x0A)vmwareengine.googleapis.com/NetworkPolicy\"\xB5\x01\x0A\x1AUpdateNetworkPolicyRequest\x12H\x0A\x0Enetwork_policy\x18\x01 \x01(\x0B2+.google.cloud.vmwareengine.v1.NetworkPolicyB\x03\xE0A\x02\x124\x0A\x0Bupdate_mask\x18\x02 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x03\xE0A\x01\"\xE2\x01\x0A\x1ACreateNetworkPolicyRequest\x12A\x0A\x06parent\x18\x01 \x01(\x09B1\xE0A\x02\xFAA+\x12)vmwareengine.googleapis.com/NetworkPolicy\x12\x1E\x0A\x11network_policy_id\x18\x02 \x01(\x09B\x03\xE0A\x02\x12H\x0A\x0Enetwork_policy\x18\x03 \x01(\x0B2+.google.cloud.vmwareengine.v1.NetworkPolicyB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x04 \x01(\x09B\x03\xE0A\x01\"v\x0A\x1ADeleteNetworkPolicyRequest\x12?\x0A\x04name\x18\x01 \x01(\x09B1\xE0A\x02\xFAA+\x0A)vmwareengine.googleapis.com/NetworkPolicy\x12\x17\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x03\xE0A\x01\"\xB1\x01\x0A\$ListManagementDnsZoneBindingsRequest\x12@\x0A\x06parent\x18\x01 \x01(\x09B0\xE0A\x02\xFAA*\x0A(vmwareengine.googleapis.com/PrivateCloud\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\x12\x0E\x0A\x06filter\x18\x04 \x01(\x09\x12\x10\x0A\x08order_by\x18\x05 \x01(\x09\"\xB3\x01\x0A%ListManagementDnsZoneBindingsResponse\x12\\\x0A\x1Cmanagement_dns_zone_bindings\x18\x01 \x03(\x0B26.google.cloud.vmwareengine.v1.ManagementDnsZoneBinding\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\x12\x13\x0A\x0Bunreachable\x18\x03 \x03(\x09\"p\x0A\"GetManagementDnsZoneBindingRequest\x12J\x0A\x04name\x18\x01 \x01(\x09B<\xE0A\x02\xFAA6\x0A4vmwareengine.googleapis.com/ManagementDnsZoneBinding\"\x91\x02\x0A%CreateManagementDnsZoneBindingRequest\x12@\x0A\x06parent\x18\x01 \x01(\x09B0\xE0A\x02\xFAA*\x0A(vmwareengine.googleapis.com/PrivateCloud\x12`\x0A\x1Bmanagement_dns_zone_binding\x18\x02 \x01(\x0B26.google.cloud.vmwareengine.v1.ManagementDnsZoneBindingB\x03\xE0A\x02\x12+\x0A\x1Emanagement_dns_zone_binding_id\x18\x03 \x01(\x09B\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x04 \x01(\x09B\x03\xE0A\x01\"\xD8\x01\x0A%UpdateManagementDnsZoneBindingRequest\x124\x0A\x0Bupdate_mask\x18\x01 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x02\x12`\x0A\x1Bmanagement_dns_zone_binding\x18\x02 \x01(\x0B26.google.cloud.vmwareengine.v1.ManagementDnsZoneBindingB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x03\xE0A\x01\"\x8C\x01\x0A%DeleteManagementDnsZoneBindingRequest\x12J\x0A\x04name\x18\x01 \x01(\x09B<\xE0A\x02\xFAA6\x0A4vmwareengine.googleapis.com/ManagementDnsZoneBinding\x12\x17\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x03\xE0A\x01\"\x8C\x01\x0A%RepairManagementDnsZoneBindingRequest\x12J\x0A\x04name\x18\x01 \x01(\x09B<\xE0A\x02\xFAA6\x0A4vmwareengine.googleapis.com/ManagementDnsZoneBinding\x12\x17\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x03\xE0A\x01\"\x82\x02\x0A CreateVmwareEngineNetworkRequest\x12G\x0A\x06parent\x18\x01 \x01(\x09B7\xE0A\x02\xFAA1\x12/vmwareengine.googleapis.com/VmwareEngineNetwork\x12%\x0A\x18vmware_engine_network_id\x18\x02 \x01(\x09B\x03\xE0A\x02\x12U\x0A\x15vmware_engine_network\x18\x03 \x01(\x0B21.google.cloud.vmwareengine.v1.VmwareEngineNetworkB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x04 \x01(\x09B\x03\xE0A\x01\"\xC8\x01\x0A UpdateVmwareEngineNetworkRequest\x12U\x0A\x15vmware_engine_network\x18\x01 \x01(\x0B21.google.cloud.vmwareengine.v1.VmwareEngineNetworkB\x03\xE0A\x02\x124\x0A\x0Bupdate_mask\x18\x02 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x03\xE0A\x01\"\x95\x01\x0A DeleteVmwareEngineNetworkRequest\x12E\x0A\x04name\x18\x01 \x01(\x09B7\xE0A\x02\xFAA1\x0A/vmwareengine.googleapis.com/VmwareEngineNetwork\x12\x17\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x03\xE0A\x01\x12\x11\x0A\x04etag\x18\x03 \x01(\x09B\x03\xE0A\x01\"f\x0A\x1DGetVmwareEngineNetworkRequest\x12E\x0A\x04name\x18\x01 \x01(\x09B7\xE0A\x02\xFAA1\x0A/vmwareengine.googleapis.com/VmwareEngineNetwork\"\xA5\x01\x0A\x1FListVmwareEngineNetworksRequest\x129\x0A\x06parent\x18\x01 \x01(\x09B)\xE0A\x02\xFAA#\x0A!locations.googleapis.com/Location\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\x12\x0E\x0A\x06filter\x18\x04 \x01(\x09\x12\x10\x0A\x08order_by\x18\x05 \x01(\x09\"\xA3\x01\x0A ListVmwareEngineNetworksResponse\x12Q\x0A\x16vmware_engine_networks\x18\x01 \x03(\x0B21.google.cloud.vmwareengine.v1.VmwareEngineNetwork\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\x12\x13\x0A\x0Bunreachable\x18\x03 \x03(\x09\"\xF6\x01\x0A\x1ECreatePrivateConnectionRequest\x12E\x0A\x06parent\x18\x01 \x01(\x09B5\xE0A\x02\xFAA/\x12-vmwareengine.googleapis.com/PrivateConnection\x12\"\x0A\x15private_connection_id\x18\x02 \x01(\x09B\x03\xE0A\x02\x12P\x0A\x12private_connection\x18\x03 \x01(\x0B2/.google.cloud.vmwareengine.v1.PrivateConnectionB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x04 \x01(\x09B\x03\xE0A\x01\"b\x0A\x1BGetPrivateConnectionRequest\x12C\x0A\x04name\x18\x01 \x01(\x09B5\xE0A\x02\xFAA/\x0A-vmwareengine.googleapis.com/PrivateConnection\"\xAF\x01\x0A\x1DListPrivateConnectionsRequest\x12E\x0A\x06parent\x18\x01 \x01(\x09B5\xE0A\x02\xFAA/\x12-vmwareengine.googleapis.com/PrivateConnection\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\x12\x0E\x0A\x06filter\x18\x04 \x01(\x09\x12\x10\x0A\x08order_by\x18\x05 \x01(\x09\"\x9C\x01\x0A\x1EListPrivateConnectionsResponse\x12L\x0A\x13private_connections\x18\x01 \x03(\x0B2/.google.cloud.vmwareengine.v1.PrivateConnection\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\x12\x13\x0A\x0Bunreachable\x18\x03 \x03(\x09\"\xC1\x01\x0A\x1EUpdatePrivateConnectionRequest\x12P\x0A\x12private_connection\x18\x01 \x01(\x0B2/.google.cloud.vmwareengine.v1.PrivateConnectionB\x03\xE0A\x02\x124\x0A\x0Bupdate_mask\x18\x02 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x03\xE0A\x01\"~\x0A\x1EDeletePrivateConnectionRequest\x12C\x0A\x04name\x18\x01 \x01(\x09B5\xE0A\x02\xFAA/\x0A-vmwareengine.googleapis.com/PrivateConnection\x12\x17\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x03\xE0A\x01\"\x99\x01\x0A)ListPrivateConnectionPeeringRoutesRequest\x12E\x0A\x06parent\x18\x01 \x01(\x09B5\xE0A\x02\xFAA/\x0A-vmwareengine.googleapis.com/PrivateConnection\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\"\x89\x01\x0A*ListPrivateConnectionPeeringRoutesResponse\x12B\x0A\x0Epeering_routes\x18\x01 \x03(\x0B2*.google.cloud.vmwareengine.v1.PeeringRoute\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\"\xBE\x01\x0A\x1DGrantDnsBindPermissionRequest\x12C\x0A\x04name\x18\x01 \x01(\x09B5\xE0A\x02\xFAA/\x0A-vmwareengine.googleapis.com/DnsBindPermission\x12?\x0A\x09principal\x18\x02 \x01(\x0B2'.google.cloud.vmwareengine.v1.PrincipalB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x03\xE0A\x01\"\xBF\x01\x0A\x1ERevokeDnsBindPermissionRequest\x12C\x0A\x04name\x18\x01 \x01(\x09B5\xE0A\x02\xFAA/\x0A-vmwareengine.googleapis.com/DnsBindPermission\x12?\x0A\x09principal\x18\x02 \x01(\x0B2'.google.cloud.vmwareengine.v1.PrincipalB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x03\xE0A\x01\"b\x0A\x1BGetDnsBindPermissionRequest\x12C\x0A\x04name\x18\x01 \x01(\x09B5\xE0A\x02\xFAA/\x0A-vmwareengine.googleapis.com/DnsBindPermission2\xDC\x8E\x01\x0A\x0CVmwareEngine\x12\xC8\x01\x0A\x11ListPrivateClouds\x126.google.cloud.vmwareengine.v1.ListPrivateCloudsRequest\x1A7.google.cloud.vmwareengine.v1.ListPrivateCloudsResponse\"B\xDAA\x06parent\x82\xD3\xE4\x93\x023\x121/v1/{parent=projects/*/locations/*}/privateClouds\x12\xB5\x01\x0A\x0FGetPrivateCloud\x124.google.cloud.vmwareengine.v1.GetPrivateCloudRequest\x1A*.google.cloud.vmwareengine.v1.PrivateCloud\"@\xDAA\x04name\x82\xD3\xE4\x93\x023\x121/v1/{name=projects/*/locations/*/privateClouds/*}\x12\x83\x02\x0A\x12CreatePrivateCloud\x127.google.cloud.vmwareengine.v1.CreatePrivateCloudRequest\x1A\x1D.google.longrunning.Operation\"\x94\x01\xCAA!\x0A\x0CPrivateCloud\x12\x11OperationMetadata\xDAA%parent,private_cloud,private_cloud_id\x82\xD3\xE4\x93\x02B\"1/v1/{parent=projects/*/locations/*}/privateClouds:\x0Dprivate_cloud\x12\x85\x02\x0A\x12UpdatePrivateCloud\x127.google.cloud.vmwareengine.v1.UpdatePrivateCloudRequest\x1A\x1D.google.longrunning.Operation\"\x96\x01\xCAA!\x0A\x0CPrivateCloud\x12\x11OperationMetadata\xDAA\x19private_cloud,update_mask\x82\xD3\xE4\x93\x02P2?/v1/{private_cloud.name=projects/*/locations/*/privateClouds/*}:\x0Dprivate_cloud\x12\xD2\x01\x0A\x12DeletePrivateCloud\x127.google.cloud.vmwareengine.v1.DeletePrivateCloudRequest\x1A\x1D.google.longrunning.Operation\"d\xCAA!\x0A\x0CPrivateCloud\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x023*1/v1/{name=projects/*/locations/*/privateClouds/*}\x12\xE2\x01\x0A\x14UndeletePrivateCloud\x129.google.cloud.vmwareengine.v1.UndeletePrivateCloudRequest\x1A\x1D.google.longrunning.Operation\"p\xCAA!\x0A\x0CPrivateCloud\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x02?\":/v1/{name=projects/*/locations/*/privateClouds/*}:undelete:\x01*\x12\xC4\x01\x0A\x0CListClusters\x121.google.cloud.vmwareengine.v1.ListClustersRequest\x1A2.google.cloud.vmwareengine.v1.ListClustersResponse\"M\xDAA\x06parent\x82\xD3\xE4\x93\x02>\x12\x12*\xDAA\x06parent\x82\xD3\xE4\x93\x02/\x12-/v1/{parent=projects/*/locations/*}/nodeTypes\x12\xA5\x01\x0A\x0BGetNodeType\x120.google.cloud.vmwareengine.v1.GetNodeTypeRequest\x1A&.google.cloud.vmwareengine.v1.NodeType\"<\xDAA\x04name\x82\xD3\xE4\x93\x02/\x12-/v1/{name=projects/*/locations/*/nodeTypes/*}\x12\xDF\x01\x0A\x12ShowNsxCredentials\x127.google.cloud.vmwareengine.v1.ShowNsxCredentialsRequest\x1A).google.cloud.vmwareengine.v1.Credentials\"e\xDAA\x0Dprivate_cloud\x82\xD3\xE4\x93\x02O\x12M/v1/{private_cloud=projects/*/locations/*/privateClouds/*}:showNsxCredentials\x12\xEB\x01\x0A\x16ShowVcenterCredentials\x12;.google.cloud.vmwareengine.v1.ShowVcenterCredentialsRequest\x1A).google.cloud.vmwareengine.v1.Credentials\"i\xDAA\x0Dprivate_cloud\x82\xD3\xE4\x93\x02S\x12Q/v1/{private_cloud=projects/*/locations/*/privateClouds/*}:showVcenterCredentials\x12\xFE\x01\x0A\x13ResetNsxCredentials\x128.google.cloud.vmwareengine.v1.ResetNsxCredentialsRequest\x1A\x1D.google.longrunning.Operation\"\x8D\x01\xCAA!\x0A\x0CPrivateCloud\x12\x11OperationMetadata\xDAA\x0Dprivate_cloud\x82\xD3\xE4\x93\x02S\"N/v1/{private_cloud=projects/*/locations/*/privateClouds/*}:resetNsxCredentials:\x01*\x12\x8A\x02\x0A\x17ResetVcenterCredentials\x12<.google.cloud.vmwareengine.v1.ResetVcenterCredentialsRequest\x1A\x1D.google.longrunning.Operation\"\x91\x01\xCAA!\x0A\x0CPrivateCloud\x12\x11OperationMetadata\xDAA\x0Dprivate_cloud\x82\xD3\xE4\x93\x02W\"R/v1/{private_cloud=projects/*/locations/*/privateClouds/*}:resetVcenterCredentials:\x01*\x12\xC6\x01\x0A\x10GetDnsForwarding\x125.google.cloud.vmwareengine.v1.GetDnsForwardingRequest\x1A+.google.cloud.vmwareengine.v1.DnsForwarding\"N\xDAA\x04name\x82\xD3\xE4\x93\x02A\x12?/v1/{name=projects/*/locations/*/privateClouds/*/dnsForwarding}\x12\x99\x02\x0A\x13UpdateDnsForwarding\x128.google.cloud.vmwareengine.v1.UpdateDnsForwardingRequest\x1A\x1D.google.longrunning.Operation\"\xA8\x01\xCAA\"\x0A\x0DDnsForwarding\x12\x11OperationMetadata\xDAA\x1Adns_forwarding,update_mask\x82\xD3\xE4\x93\x02`2N/v1/{dns_forwarding.name=projects/*/locations/*/privateClouds/*/dnsForwarding}:\x0Edns_forwarding\x12\xBD\x01\x0A\x11GetNetworkPeering\x126.google.cloud.vmwareengine.v1.GetNetworkPeeringRequest\x1A,.google.cloud.vmwareengine.v1.NetworkPeering\"B\xDAA\x04name\x82\xD3\xE4\x93\x025\x123/v1/{name=projects/*/locations/*/networkPeerings/*}\x12\xD0\x01\x0A\x13ListNetworkPeerings\x128.google.cloud.vmwareengine.v1.ListNetworkPeeringsRequest\x1A9.google.cloud.vmwareengine.v1.ListNetworkPeeringsResponse\"D\xDAA\x06parent\x82\xD3\xE4\x93\x025\x123/v1/{parent=projects/*/locations/*}/networkPeerings\x12\x91\x02\x0A\x14CreateNetworkPeering\x129.google.cloud.vmwareengine.v1.CreateNetworkPeeringRequest\x1A\x1D.google.longrunning.Operation\"\x9E\x01\xCAA#\x0A\x0ENetworkPeering\x12\x11OperationMetadata\xDAA)parent,network_peering,network_peering_id\x82\xD3\xE4\x93\x02F\"3/v1/{parent=projects/*/locations/*}/networkPeerings:\x0Fnetwork_peering\x12\xE1\x01\x0A\x14DeleteNetworkPeering\x129.google.cloud.vmwareengine.v1.DeleteNetworkPeeringRequest\x1A\x1D.google.longrunning.Operation\"o\xCAA*\x0A\x15google.protobuf.Empty\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x025*3/v1/{name=projects/*/locations/*/networkPeerings/*}\x12\x93\x02\x0A\x14UpdateNetworkPeering\x129.google.cloud.vmwareengine.v1.UpdateNetworkPeeringRequest\x1A\x1D.google.longrunning.Operation\"\xA0\x01\xCAA#\x0A\x0ENetworkPeering\x12\x11OperationMetadata\xDAA\x1Bnetwork_peering,update_mask\x82\xD3\xE4\x93\x02V2C/v1/{network_peering.name=projects/*/locations/*/networkPeerings/*}:\x0Fnetwork_peering\x12\xDA\x01\x0A\x11ListPeeringRoutes\x126.google.cloud.vmwareengine.v1.ListPeeringRoutesRequest\x1A7.google.cloud.vmwareengine.v1.ListPeeringRoutesResponse\"T\xDAA\x06parent\x82\xD3\xE4\x93\x02E\x12C/v1/{parent=projects/*/locations/*/networkPeerings/*}/peeringRoutes\x12\xB2\x02\x0A\x16CreateHcxActivationKey\x12;.google.cloud.vmwareengine.v1.CreateHcxActivationKeyRequest\x1A\x1D.google.longrunning.Operation\"\xBB\x01\xCAA%\x0A\x10HcxActivationKey\x12\x11OperationMetadata\xDAA/parent,hcx_activation_key,hcx_activation_key_id\x82\xD3\xE4\x93\x02[\"E/v1/{parent=projects/*/locations/*/privateClouds/*}/hcxActivationKeys:\x12hcx_activation_key\x12\xE8\x01\x0A\x15ListHcxActivationKeys\x12:.google.cloud.vmwareengine.v1.ListHcxActivationKeysRequest\x1A;.google.cloud.vmwareengine.v1.ListHcxActivationKeysResponse\"V\xDAA\x06parent\x82\xD3\xE4\x93\x02G\x12E/v1/{parent=projects/*/locations/*/privateClouds/*}/hcxActivationKeys\x12\xD5\x01\x0A\x13GetHcxActivationKey\x128.google.cloud.vmwareengine.v1.GetHcxActivationKeyRequest\x1A..google.cloud.vmwareengine.v1.HcxActivationKey\"T\xDAA\x04name\x82\xD3\xE4\x93\x02G\x12E/v1/{name=projects/*/locations/*/privateClouds/*/hcxActivationKeys/*}\x12\xBA\x01\x0A\x10GetNetworkPolicy\x125.google.cloud.vmwareengine.v1.GetNetworkPolicyRequest\x1A+.google.cloud.vmwareengine.v1.NetworkPolicy\"B\xDAA\x04name\x82\xD3\xE4\x93\x025\x123/v1/{name=projects/*/locations/*/networkPolicies/*}\x12\xD0\x01\x0A\x13ListNetworkPolicies\x128.google.cloud.vmwareengine.v1.ListNetworkPoliciesRequest\x1A9.google.cloud.vmwareengine.v1.ListNetworkPoliciesResponse\"D\xDAA\x06parent\x82\xD3\xE4\x93\x025\x123/v1/{parent=projects/*/locations/*}/networkPolicies\x12\x8B\x02\x0A\x13CreateNetworkPolicy\x128.google.cloud.vmwareengine.v1.CreateNetworkPolicyRequest\x1A\x1D.google.longrunning.Operation\"\x9A\x01\xCAA\"\x0A\x0DNetworkPolicy\x12\x11OperationMetadata\xDAA'parent,network_policy,network_policy_id\x82\xD3\xE4\x93\x02E\"3/v1/{parent=projects/*/locations/*}/networkPolicies:\x0Enetwork_policy\x12\x8D\x02\x0A\x13UpdateNetworkPolicy\x128.google.cloud.vmwareengine.v1.UpdateNetworkPolicyRequest\x1A\x1D.google.longrunning.Operation\"\x9C\x01\xCAA\"\x0A\x0DNetworkPolicy\x12\x11OperationMetadata\xDAA\x1Anetwork_policy,update_mask\x82\xD3\xE4\x93\x02T2B/v1/{network_policy.name=projects/*/locations/*/networkPolicies/*}:\x0Enetwork_policy\x12\xDF\x01\x0A\x13DeleteNetworkPolicy\x128.google.cloud.vmwareengine.v1.DeleteNetworkPolicyRequest\x1A\x1D.google.longrunning.Operation\"o\xCAA*\x0A\x15google.protobuf.Empty\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x025*3/v1/{name=projects/*/locations/*/networkPolicies/*}\x12\x88\x02\x0A\x1DListManagementDnsZoneBindings\x12B.google.cloud.vmwareengine.v1.ListManagementDnsZoneBindingsRequest\x1AC.google.cloud.vmwareengine.v1.ListManagementDnsZoneBindingsResponse\"^\xDAA\x06parent\x82\xD3\xE4\x93\x02O\x12M/v1/{parent=projects/*/locations/*/privateClouds/*}/managementDnsZoneBindings\x12\xF5\x01\x0A\x1BGetManagementDnsZoneBinding\x12@.google.cloud.vmwareengine.v1.GetManagementDnsZoneBindingRequest\x1A6.google.cloud.vmwareengine.v1.ManagementDnsZoneBinding\"\\\xDAA\x04name\x82\xD3\xE4\x93\x02O\x12M/v1/{name=projects/*/locations/*/privateClouds/*/managementDnsZoneBindings/*}\x12\xED\x02\x0A\x1ECreateManagementDnsZoneBinding\x12C.google.cloud.vmwareengine.v1.CreateManagementDnsZoneBindingRequest\x1A\x1D.google.longrunning.Operation\"\xE6\x01\xCAA-\x0A\x18ManagementDnsZoneBinding\x12\x11OperationMetadata\xDAAAparent,management_dns_zone_binding,management_dns_zone_binding_id\x82\xD3\xE4\x93\x02l\"M/v1/{parent=projects/*/locations/*/privateClouds/*}/managementDnsZoneBindings:\x1Bmanagement_dns_zone_binding\x12\xF0\x02\x0A\x1EUpdateManagementDnsZoneBinding\x12C.google.cloud.vmwareengine.v1.UpdateManagementDnsZoneBindingRequest\x1A\x1D.google.longrunning.Operation\"\xE9\x01\xCAA-\x0A\x18ManagementDnsZoneBinding\x12\x11OperationMetadata\xDAA'management_dns_zone_binding,update_mask\x82\xD3\xE4\x93\x02\x88\x012i/v1/{management_dns_zone_binding.name=projects/*/locations/*/privateClouds/*/managementDnsZoneBindings/*}:\x1Bmanagement_dns_zone_binding\x12\x90\x02\x0A\x1EDeleteManagementDnsZoneBinding\x12C.google.cloud.vmwareengine.v1.DeleteManagementDnsZoneBindingRequest\x1A\x1D.google.longrunning.Operation\"\x89\x01\xCAA*\x0A\x15google.protobuf.Empty\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x02O*M/v1/{name=projects/*/locations/*/privateClouds/*/managementDnsZoneBindings/*}\x12\x9D\x02\x0A\x1ERepairManagementDnsZoneBinding\x12C.google.cloud.vmwareengine.v1.RepairManagementDnsZoneBindingRequest\x1A\x1D.google.longrunning.Operation\"\x96\x01\xCAA-\x0A\x18ManagementDnsZoneBinding\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x02Y\"T/v1/{name=projects/*/locations/*/privateClouds/*/managementDnsZoneBindings/*}:repair:\x01*\x12\xB7\x02\x0A\x19CreateVmwareEngineNetwork\x12>.google.cloud.vmwareengine.v1.CreateVmwareEngineNetworkRequest\x1A\x1D.google.longrunning.Operation\"\xBA\x01\xCAA(\x0A\x13VmwareEngineNetwork\x12\x11OperationMetadata\xDAA5parent,vmware_engine_network,vmware_engine_network_id\x82\xD3\xE4\x93\x02Q\"8/v1/{parent=projects/*/locations/*}/vmwareEngineNetworks:\x15vmware_engine_network\x12\xB9\x02\x0A\x19UpdateVmwareEngineNetwork\x12>.google.cloud.vmwareengine.v1.UpdateVmwareEngineNetworkRequest\x1A\x1D.google.longrunning.Operation\"\xBC\x01\xCAA(\x0A\x13VmwareEngineNetwork\x12\x11OperationMetadata\xDAA!vmware_engine_network,update_mask\x82\xD3\xE4\x93\x02g2N/v1/{vmware_engine_network.name=projects/*/locations/*/vmwareEngineNetworks/*}:\x15vmware_engine_network\x12\xF0\x01\x0A\x19DeleteVmwareEngineNetwork\x12>.google.cloud.vmwareengine.v1.DeleteVmwareEngineNetworkRequest\x1A\x1D.google.longrunning.Operation\"t\xCAA*\x0A\x15google.protobuf.Empty\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x02:*8/v1/{name=projects/*/locations/*/vmwareEngineNetworks/*}\x12\xD1\x01\x0A\x16GetVmwareEngineNetwork\x12;.google.cloud.vmwareengine.v1.GetVmwareEngineNetworkRequest\x1A1.google.cloud.vmwareengine.v1.VmwareEngineNetwork\"G\xDAA\x04name\x82\xD3\xE4\x93\x02:\x128/v1/{name=projects/*/locations/*/vmwareEngineNetworks/*}\x12\xE4\x01\x0A\x18ListVmwareEngineNetworks\x12=.google.cloud.vmwareengine.v1.ListVmwareEngineNetworksRequest\x1A>.google.cloud.vmwareengine.v1.ListVmwareEngineNetworksResponse\"I\xDAA\x06parent\x82\xD3\xE4\x93\x02:\x128/v1/{parent=projects/*/locations/*}/vmwareEngineNetworks\x12\xA6\x02\x0A\x17CreatePrivateConnection\x12<.google.cloud.vmwareengine.v1.CreatePrivateConnectionRequest\x1A\x1D.google.longrunning.Operation\"\xAD\x01\xCAA&\x0A\x11PrivateConnection\x12\x11OperationMetadata\xDAA/parent,private_connection,private_connection_id\x82\xD3\xE4\x93\x02L\"6/v1/{parent=projects/*/locations/*}/privateConnections:\x12private_connection\x12\xC9\x01\x0A\x14GetPrivateConnection\x129.google.cloud.vmwareengine.v1.GetPrivateConnectionRequest\x1A/.google.cloud.vmwareengine.v1.PrivateConnection\"E\xDAA\x04name\x82\xD3\xE4\x93\x028\x126/v1/{name=projects/*/locations/*/privateConnections/*}\x12\xDC\x01\x0A\x16ListPrivateConnections\x12;.google.cloud.vmwareengine.v1.ListPrivateConnectionsRequest\x1A<.google.cloud.vmwareengine.v1.ListPrivateConnectionsResponse\"G\xDAA\x06parent\x82\xD3\xE4\x93\x028\x126/v1/{parent=projects/*/locations/*}/privateConnections\x12\xA8\x02\x0A\x17UpdatePrivateConnection\x12<.google.cloud.vmwareengine.v1.UpdatePrivateConnectionRequest\x1A\x1D.google.longrunning.Operation\"\xAF\x01\xCAA&\x0A\x11PrivateConnection\x12\x11OperationMetadata\xDAA\x1Eprivate_connection,update_mask\x82\xD3\xE4\x93\x02_2I/v1/{private_connection.name=projects/*/locations/*/privateConnections/*}:\x12private_connection\x12\xEA\x01\x0A\x17DeletePrivateConnection\x12<.google.cloud.vmwareengine.v1.DeletePrivateConnectionRequest\x1A\x1D.google.longrunning.Operation\"r\xCAA*\x0A\x15google.protobuf.Empty\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x028*6/v1/{name=projects/*/locations/*/privateConnections/*}\x12\x90\x02\x0A\"ListPrivateConnectionPeeringRoutes\x12G.google.cloud.vmwareengine.v1.ListPrivateConnectionPeeringRoutesRequest\x1AH.google.cloud.vmwareengine.v1.ListPrivateConnectionPeeringRoutesResponse\"W\xDAA\x06parent\x82\xD3\xE4\x93\x02H\x12F/v1/{parent=projects/*/locations/*/privateConnections/*}/peeringRoutes\x12\xF4\x01\x0A\x16GrantDnsBindPermission\x12;.google.cloud.vmwareengine.v1.GrantDnsBindPermissionRequest\x1A\x1D.google.longrunning.Operation\"~\xCAA&\x0A\x11DnsBindPermission\x12\x11OperationMetadata\xDAA\x0Ename,principal\x82\xD3\xE4\x93\x02>\"9/v1/{name=projects/*/locations/*/dnsBindPermission}:grant:\x01*\x12\xC6\x01\x0A\x14GetDnsBindPermission\x129.google.cloud.vmwareengine.v1.GetDnsBindPermissionRequest\x1A/.google.cloud.vmwareengine.v1.DnsBindPermission\"B\xDAA\x04name\x82\xD3\xE4\x93\x025\x123/v1/{name=projects/*/locations/*/dnsBindPermission}\x12\xF7\x01\x0A\x17RevokeDnsBindPermission\x12<.google.cloud.vmwareengine.v1.RevokeDnsBindPermissionRequest\x1A\x1D.google.longrunning.Operation\"\x7F\xCAA&\x0A\x11DnsBindPermission\x12\x11OperationMetadata\xDAA\x0Ename,principal\x82\xD3\xE4\x93\x02?\":/v1/{name=projects/*/locations/*/dnsBindPermission}:revoke:\x01*\x1AO\xCAA\x1Bvmwareengine.googleapis.com\xD2A.https://www.googleapis.com/auth/cloud-platformB\xAE\x02\x0A com.google.cloud.vmwareengine.v1B\x11VmwareengineProtoP\x01ZDcloud.google.com/go/vmwareengine/apiv1/vmwareenginepb;vmwareenginepb\xAA\x02\x1CGoogle.Cloud.VmwareEngine.V1\xCA\x02\x1CGoogle\\Cloud\\VmwareEngine\\V1\xEA\x02\x1FGoogle::Cloud::VmwareEngine::V1\xEAAN\x0A\x1Ecompute.googleapis.com/Network\x12,projects/{project}/global/networks/{network}b\x06proto3" + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/GPBMetadata/Google/Cloud/Vmwareengine/V1/VmwareengineResources.php b/owl-bot-staging/VmwareEngine/v1/proto/src/GPBMetadata/Google/Cloud/Vmwareengine/V1/VmwareengineResources.php new file mode 100644 index 000000000000..ff6a24d52935 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/GPBMetadata/Google/Cloud/Vmwareengine/V1/VmwareengineResources.php @@ -0,0 +1,29 @@ +internalAddGeneratedFile( + "\x0A\xB0z\x0A9google/cloud/vmwareengine/v1/vmwareengine_resources.proto\x12\x1Cgoogle.cloud.vmwareengine.v1\x1A\x1Bgoogle/api/field_info.proto\x1A\x19google/api/resource.proto\x1A\x1Egoogle/protobuf/duration.proto\x1A\x1Fgoogle/protobuf/timestamp.proto\"\xB6\x02\x0A\x0DNetworkConfig\x12\x1C\x0A\x0Fmanagement_cidr\x18\x04 \x01(\x09B\x03\xE0A\x02\x12V\x0A\x15vmware_engine_network\x18\x05 \x01(\x09B7\xE0A\x01\xFAA1\x0A/vmwareengine.googleapis.com/VmwareEngineNetwork\x12`\x0A\x1Fvmware_engine_network_canonical\x18\x06 \x01(\x09B7\xE0A\x03\xFAA1\x0A/vmwareengine.googleapis.com/VmwareEngineNetwork\x121\x0A\$management_ip_address_layout_version\x18\x08 \x01(\x05B\x03\xE0A\x03\x12\x1A\x0A\x0Ddns_server_ip\x18\x09 \x01(\x09B\x03\xE0A\x03\"I\x0A\x0ENodeTypeConfig\x12\x17\x0A\x0Anode_count\x18\x01 \x01(\x05B\x03\xE0A\x02\x12\x1E\x0A\x11custom_core_count\x18\x02 \x01(\x05B\x03\xE0A\x01\"\xA6\x01\x0A\x16StretchedClusterConfig\x12E\x0A\x12preferred_location\x18\x01 \x01(\x09B)\xE0A\x02\xFAA#\x0A!locations.googleapis.com/Location\x12E\x0A\x12secondary_location\x18\x02 \x01(\x09B)\xE0A\x02\xFAA#\x0A!locations.googleapis.com/Location\"\xFD\x0A\x0A\x0CPrivateCloud\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x03\x124\x0A\x0Bcreate_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x03 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bdelete_time\x18\x04 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bexpire_time\x18\x05 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12D\x0A\x05state\x18\x08 \x01(\x0E20.google.cloud.vmwareengine.v1.PrivateCloud.StateB\x03\xE0A\x03\x12H\x0A\x0Enetwork_config\x18\x09 \x01(\x0B2+.google.cloud.vmwareengine.v1.NetworkConfigB\x03\xE0A\x02\x12`\x0A\x12management_cluster\x18\x0A \x01(\x0B2<.google.cloud.vmwareengine.v1.PrivateCloud.ManagementClusterB\x06\xE0A\x04\xE0A\x02\x12\x13\x0A\x0Bdescription\x18\x0B \x01(\x09\x123\x0A\x03hcx\x18\x11 \x01(\x0B2!.google.cloud.vmwareengine.v1.HcxB\x03\xE0A\x03\x123\x0A\x03nsx\x18\x12 \x01(\x0B2!.google.cloud.vmwareengine.v1.NsxB\x03\xE0A\x03\x12;\x0A\x07vcenter\x18\x13 \x01(\x0B2%.google.cloud.vmwareengine.v1.VcenterB\x03\xE0A\x03\x12\x10\x0A\x03uid\x18\x14 \x01(\x09B\x03\xE0A\x03\x12B\x0A\x04type\x18\x16 \x01(\x0E2/.google.cloud.vmwareengine.v1.PrivateCloud.TypeB\x03\xE0A\x01\x1A\xE2\x02\x0A\x11ManagementCluster\x12\x17\x0A\x0Acluster_id\x18\x01 \x01(\x09B\x03\xE0A\x02\x12q\x0A\x11node_type_configs\x18\x07 \x03(\x0B2Q.google.cloud.vmwareengine.v1.PrivateCloud.ManagementCluster.NodeTypeConfigsEntryB\x03\xE0A\x02\x12[\x0A\x18stretched_cluster_config\x18\x08 \x01(\x0B24.google.cloud.vmwareengine.v1.StretchedClusterConfigB\x03\xE0A\x01\x1Ad\x0A\x14NodeTypeConfigsEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12;\x0A\x05value\x18\x02 \x01(\x0B2,.google.cloud.vmwareengine.v1.NodeTypeConfig:\x028\x01\"l\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x0A\x0A\x06ACTIVE\x10\x01\x12\x0C\x0A\x08CREATING\x10\x02\x12\x0C\x0A\x08UPDATING\x10\x03\x12\x0A\x0A\x06FAILED\x10\x05\x12\x0B\x0A\x07DELETED\x10\x06\x12\x0B\x0A\x07PURGING\x10\x07\"5\x0A\x04Type\x12\x0C\x0A\x08STANDARD\x10\x00\x12\x10\x0A\x0CTIME_LIMITED\x10\x01\x12\x0D\x0A\x09STRETCHED\x10\x02:t\xEAAq\x0A(vmwareengine.googleapis.com/PrivateCloud\x12Eprojects/{project}/locations/{location}/privateClouds/{private_cloud}\"\xD3\x06\x0A\x07Cluster\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x03\x124\x0A\x0Bcreate_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x03 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12?\x0A\x05state\x18\x06 \x01(\x0E2+.google.cloud.vmwareengine.v1.Cluster.StateB\x03\xE0A\x03\x12\x17\x0A\x0Amanagement\x18\x07 \x01(\x08B\x03\xE0A\x03\x12T\x0A\x14autoscaling_settings\x18\x12 \x01(\x0B21.google.cloud.vmwareengine.v1.AutoscalingSettingsB\x03\xE0A\x01\x12\x10\x0A\x03uid\x18\x0E \x01(\x09B\x03\xE0A\x03\x12Z\x0A\x11node_type_configs\x18\x10 \x03(\x0B2:.google.cloud.vmwareengine.v1.Cluster.NodeTypeConfigsEntryB\x03\xE0A\x02\x12[\x0A\x18stretched_cluster_config\x18\x11 \x01(\x0B24.google.cloud.vmwareengine.v1.StretchedClusterConfigB\x03\xE0A\x01\x1Ad\x0A\x14NodeTypeConfigsEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12;\x0A\x05value\x18\x02 \x01(\x0B2,.google.cloud.vmwareengine.v1.NodeTypeConfig:\x028\x01\"c\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x0A\x0A\x06ACTIVE\x10\x01\x12\x0C\x0A\x08CREATING\x10\x02\x12\x0C\x0A\x08UPDATING\x10\x03\x12\x0C\x0A\x08DELETING\x10\x04\x12\x0D\x0A\x09REPAIRING\x10\x05:\x82\x01\xEAA\x7F\x0A#vmwareengine.googleapis.com/Cluster\x12Xprojects/{project}/locations/{location}/privateClouds/{private_cloud}/clusters/{cluster}\"\xBA\x03\x0A\x04Node\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x03\x12\x11\x0A\x04fqdn\x18\x02 \x01(\x09B\x03\xE0A\x03\x12\x18\x0A\x0Binternal_ip\x18\x03 \x01(\x09B\x03\xE0A\x03\x12\x19\x0A\x0Cnode_type_id\x18\x04 \x01(\x09B\x03\xE0A\x03\x12\x14\x0A\x07version\x18\x05 \x01(\x09B\x03\xE0A\x03\x12\x1E\x0A\x11custom_core_count\x18\x06 \x01(\x03B\x03\xE0A\x03\x12<\x0A\x05state\x18\x07 \x01(\x0E2(.google.cloud.vmwareengine.v1.Node.StateB\x03\xE0A\x03\"S\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x0A\x0A\x06ACTIVE\x10\x01\x12\x0C\x0A\x08CREATING\x10\x02\x12\x0A\x0A\x06FAILED\x10\x03\x12\x0D\x0A\x09UPGRADING\x10\x04:\x8D\x01\xEAA\x89\x01\x0A vmwareengine.googleapis.com/Node\x12eprojects/{project}/locations/{location}/privateClouds/{private_cloud}/clusters/{cluster}/nodes/{node}\"\xA5\x04\x0A\x0FExternalAddress\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x03\x124\x0A\x0Bcreate_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x03 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12\x13\x0A\x0Binternal_ip\x18\x06 \x01(\x09\x12\x18\x0A\x0Bexternal_ip\x18\x07 \x01(\x09B\x03\xE0A\x03\x12G\x0A\x05state\x18\x08 \x01(\x0E23.google.cloud.vmwareengine.v1.ExternalAddress.StateB\x03\xE0A\x03\x12\x10\x0A\x03uid\x18\x09 \x01(\x09B\x03\xE0A\x03\x12\x13\x0A\x0Bdescription\x18\x0B \x01(\x09\"T\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x0A\x0A\x06ACTIVE\x10\x01\x12\x0C\x0A\x08CREATING\x10\x02\x12\x0C\x0A\x08UPDATING\x10\x03\x12\x0C\x0A\x08DELETING\x10\x04:\x9D\x01\xEAA\x99\x01\x0A+vmwareengine.googleapis.com/ExternalAddress\x12jprojects/{project}/locations/{location}/privateClouds/{private_cloud}/externalAddresses/{external_address}\"\xA3\x03\x0A\x06Subnet\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x03\x12\x15\x0A\x0Dip_cidr_range\x18\x07 \x01(\x09\x12\x12\x0A\x0Agateway_ip\x18\x08 \x01(\x09\x12\x11\x0A\x04type\x18\x0B \x01(\x09B\x03\xE0A\x03\x12>\x0A\x05state\x18\x0D \x01(\x0E2*.google.cloud.vmwareengine.v1.Subnet.StateB\x03\xE0A\x03\x12\x14\x0A\x07vlan_id\x18\x10 \x01(\x05B\x03\xE0A\x03\"q\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x0A\x0A\x06ACTIVE\x10\x01\x12\x0C\x0A\x08CREATING\x10\x02\x12\x0C\x0A\x08UPDATING\x10\x03\x12\x0C\x0A\x08DELETING\x10\x04\x12\x0F\x0A\x0BRECONCILING\x10\x05\x12\x0A\x0A\x06FAILED\x10\x06:\x7F\xEAA|\x0A\"vmwareengine.googleapis.com/Subnet\x12Vprojects/{project}/locations/{location}/privateClouds/{private_cloud}/subnets/{subnet}\"\xA5\x08\x0A\x12ExternalAccessRule\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x03\x124\x0A\x0Bcreate_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x03 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12\x13\x0A\x0Bdescription\x18\x05 \x01(\x09\x12\x10\x0A\x08priority\x18\x06 \x01(\x05\x12G\x0A\x06action\x18\x07 \x01(\x0E27.google.cloud.vmwareengine.v1.ExternalAccessRule.Action\x12\x13\x0A\x0Bip_protocol\x18\x08 \x01(\x09\x12R\x0A\x10source_ip_ranges\x18\x09 \x03(\x0B28.google.cloud.vmwareengine.v1.ExternalAccessRule.IpRange\x12\x14\x0A\x0Csource_ports\x18\x0A \x03(\x09\x12W\x0A\x15destination_ip_ranges\x18\x0B \x03(\x0B28.google.cloud.vmwareengine.v1.ExternalAccessRule.IpRange\x12\x19\x0A\x11destination_ports\x18\x0C \x03(\x09\x12J\x0A\x05state\x18\x0D \x01(\x0E26.google.cloud.vmwareengine.v1.ExternalAccessRule.StateB\x03\xE0A\x03\x12\x10\x0A\x03uid\x18\x0E \x01(\x09B\x03\xE0A\x03\x1A\x95\x01\x0A\x07IpRange\x12\x14\x0A\x0Aip_address\x18\x01 \x01(\x09H\x00\x12\x1A\x0A\x10ip_address_range\x18\x02 \x01(\x09H\x00\x12L\x0A\x10external_address\x18\x03 \x01(\x09B0\xFAA-\x0A+vmwareengine.googleapis.com/ExternalAddressH\x00B\x0A\x0A\x08ip_range\"5\x0A\x06Action\x12\x16\x0A\x12ACTION_UNSPECIFIED\x10\x00\x12\x09\x0A\x05ALLOW\x10\x01\x12\x08\x0A\x04DENY\x10\x02\"T\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x0A\x0A\x06ACTIVE\x10\x01\x12\x0C\x0A\x08CREATING\x10\x02\x12\x0C\x0A\x08UPDATING\x10\x03\x12\x0C\x0A\x08DELETING\x10\x04:\xA9\x01\xEAA\xA5\x01\x0A.vmwareengine.googleapis.com/ExternalAccessRule\x12sprojects/{project}/locations/{location}/networkPolicies/{network_policy}/externalAccessRules/{external_access_rule}\"\x95\x05\x0A\x0DLoggingServer\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x03\x124\x0A\x0Bcreate_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x03 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12\x15\x0A\x08hostname\x18\x05 \x01(\x09B\x03\xE0A\x02\x12\x11\x0A\x04port\x18\x07 \x01(\x05B\x03\xE0A\x02\x12K\x0A\x08protocol\x18\x06 \x01(\x0E24.google.cloud.vmwareengine.v1.LoggingServer.ProtocolB\x03\xE0A\x02\x12P\x0A\x0Bsource_type\x18\x0A \x01(\x0E26.google.cloud.vmwareengine.v1.LoggingServer.SourceTypeB\x03\xE0A\x02\x12\x10\x0A\x03uid\x18\x08 \x01(\x09B\x03\xE0A\x03\"R\x0A\x08Protocol\x12\x18\x0A\x14PROTOCOL_UNSPECIFIED\x10\x00\x12\x07\x0A\x03UDP\x10\x01\x12\x07\x0A\x03TCP\x10\x02\x12\x07\x0A\x03TLS\x10\x03\x12\x07\x0A\x03SSL\x10\x04\x12\x08\x0A\x04RELP\x10\x05\"=\x0A\x0ASourceType\x12\x1B\x0A\x17SOURCE_TYPE_UNSPECIFIED\x10\x00\x12\x08\x0A\x04ESXI\x10\x01\x12\x08\x0A\x04VCSA\x10\x02:\x96\x01\xEAA\x92\x01\x0A)vmwareengine.googleapis.com/LoggingServer\x12eprojects/{project}/locations/{location}/privateClouds/{private_cloud}/loggingServers/{logging_server}\"\xFF\x04\x0A\x08NodeType\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x03\x12\x19\x0A\x0Cnode_type_id\x18\x02 \x01(\x09B\x03\xE0A\x03\x12\x19\x0A\x0Cdisplay_name\x18\x03 \x01(\x09B\x03\xE0A\x03\x12\x1E\x0A\x11virtual_cpu_count\x18\x04 \x01(\x05B\x03\xE0A\x03\x12\x1D\x0A\x10total_core_count\x18\x05 \x01(\x05B\x03\xE0A\x03\x12\x16\x0A\x09memory_gb\x18\x07 \x01(\x05B\x03\xE0A\x03\x12\x19\x0A\x0Cdisk_size_gb\x18\x08 \x01(\x05B\x03\xE0A\x03\x12)\x0A\x1Cavailable_custom_core_counts\x18\x0B \x03(\x05B\x03\xE0A\x03\x12>\x0A\x04kind\x18\x0C \x01(\x0E2+.google.cloud.vmwareengine.v1.NodeType.KindB\x03\xE0A\x03\x12\x15\x0A\x08families\x18\x0D \x03(\x09B\x03\xE0A\x03\x12L\x0A\x0Ccapabilities\x18\x0E \x03(\x0E21.google.cloud.vmwareengine.v1.NodeType.CapabilityB\x03\xE0A\x03\"<\x0A\x04Kind\x12\x14\x0A\x10KIND_UNSPECIFIED\x10\x00\x12\x0C\x0A\x08STANDARD\x10\x01\x12\x10\x0A\x0CSTORAGE_ONLY\x10\x02\"@\x0A\x0ACapability\x12\x1A\x0A\x16CAPABILITY_UNSPECIFIED\x10\x00\x12\x16\x0A\x12STRETCHED_CLUSTERS\x10\x01:h\xEAAe\x0A\$vmwareengine.googleapis.com/NodeType\x12=projects/{project}/locations/{location}/nodeTypes/{node_type}\"1\x0A\x0BCredentials\x12\x10\x0A\x08username\x18\x01 \x01(\x09\x12\x10\x0A\x08password\x18\x02 \x01(\x09\"\xC2\x03\x0A\x10HcxActivationKey\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x03\x124\x0A\x0Bcreate_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12H\x0A\x05state\x18\x03 \x01(\x0E24.google.cloud.vmwareengine.v1.HcxActivationKey.StateB\x03\xE0A\x03\x12\x1B\x0A\x0Eactivation_key\x18\x04 \x01(\x09B\x03\xE0A\x03\x12\x10\x0A\x03uid\x18\x05 \x01(\x09B\x03\xE0A\x03\"I\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x0D\x0A\x09AVAILABLE\x10\x01\x12\x0C\x0A\x08CONSUMED\x10\x02\x12\x0C\x0A\x08CREATING\x10\x03:\xA0\x01\xEAA\x9C\x01\x0A,vmwareengine.googleapis.com/HcxActivationKey\x12lprojects/{project}/locations/{location}/privateClouds/{private_cloud}/hcxActivationKeys/{hcx_activation_key}\"\xC0\x01\x0A\x03Hcx\x12\x13\x0A\x0Binternal_ip\x18\x02 \x01(\x09\x12\x0F\x0A\x07version\x18\x04 \x01(\x09\x12;\x0A\x05state\x18\x05 \x01(\x0E2'.google.cloud.vmwareengine.v1.Hcx.StateB\x03\xE0A\x03\x12\x0C\x0A\x04fqdn\x18\x06 \x01(\x09\"H\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x0A\x0A\x06ACTIVE\x10\x01\x12\x0C\x0A\x08CREATING\x10\x02\x12\x0E\x0A\x0AACTIVATING\x10\x03\"\xB0\x01\x0A\x03Nsx\x12\x13\x0A\x0Binternal_ip\x18\x02 \x01(\x09\x12\x0F\x0A\x07version\x18\x04 \x01(\x09\x12;\x0A\x05state\x18\x05 \x01(\x0E2'.google.cloud.vmwareengine.v1.Nsx.StateB\x03\xE0A\x03\x12\x0C\x0A\x04fqdn\x18\x06 \x01(\x09\"8\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x0A\x0A\x06ACTIVE\x10\x01\x12\x0C\x0A\x08CREATING\x10\x02\"\xB8\x01\x0A\x07Vcenter\x12\x13\x0A\x0Binternal_ip\x18\x02 \x01(\x09\x12\x0F\x0A\x07version\x18\x04 \x01(\x09\x12?\x0A\x05state\x18\x05 \x01(\x0E2+.google.cloud.vmwareengine.v1.Vcenter.StateB\x03\xE0A\x03\x12\x0C\x0A\x04fqdn\x18\x06 \x01(\x09\"8\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x0A\x0A\x06ACTIVE\x10\x01\x12\x0C\x0A\x08CREATING\x10\x02\"\x9B\x07\x0A\x13AutoscalingSettings\x12m\x0A\x14autoscaling_policies\x18\x01 \x03(\x0B2J.google.cloud.vmwareengine.v1.AutoscalingSettings.AutoscalingPoliciesEntryB\x03\xE0A\x02\x12#\x0A\x16min_cluster_node_count\x18\x02 \x01(\x05B\x03\xE0A\x01\x12#\x0A\x16max_cluster_node_count\x18\x03 \x01(\x05B\x03\xE0A\x01\x128\x0A\x10cool_down_period\x18\x04 \x01(\x0B2\x19.google.protobuf.DurationB\x03\xE0A\x01\x1A;\x0A\x0AThresholds\x12\x16\x0A\x09scale_out\x18\x01 \x01(\x05B\x03\xE0A\x02\x12\x15\x0A\x08scale_in\x18\x02 \x01(\x05B\x03\xE0A\x02\x1A\xD2\x03\x0A\x11AutoscalingPolicy\x12\x19\x0A\x0Cnode_type_id\x18\x01 \x01(\x09B\x03\xE0A\x02\x12\x1B\x0A\x0Escale_out_size\x18\x02 \x01(\x05B\x03\xE0A\x02\x12Y\x0A\x0Ecpu_thresholds\x18\x0B \x01(\x0B2<.google.cloud.vmwareengine.v1.AutoscalingSettings.ThresholdsB\x03\xE0A\x01\x12d\x0A\x19granted_memory_thresholds\x18\x0C \x01(\x0B2<.google.cloud.vmwareengine.v1.AutoscalingSettings.ThresholdsB\x03\xE0A\x01\x12e\x0A\x1Aconsumed_memory_thresholds\x18\x0D \x01(\x0B2<.google.cloud.vmwareengine.v1.AutoscalingSettings.ThresholdsB\x03\xE0A\x01\x12]\x0A\x12storage_thresholds\x18\x0E \x01(\x0B2<.google.cloud.vmwareengine.v1.AutoscalingSettings.ThresholdsB\x03\xE0A\x01\x1A\x7F\x0A\x18AutoscalingPoliciesEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12R\x0A\x05value\x18\x02 \x01(\x0B2C.google.cloud.vmwareengine.v1.AutoscalingSettings.AutoscalingPolicy:\x028\x01\"\xB2\x03\x0A\x0DDnsForwarding\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x03\x124\x0A\x0Bcreate_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x03 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12Y\x0A\x10forwarding_rules\x18\x04 \x03(\x0B2:.google.cloud.vmwareengine.v1.DnsForwarding.ForwardingRuleB\x03\xE0A\x02\x1A@\x0A\x0EForwardingRule\x12\x13\x0A\x06domain\x18\x01 \x01(\x09B\x03\xE0A\x02\x12\x19\x0A\x0Cname_servers\x18\x02 \x03(\x09B\x03\xE0A\x02:\x84\x01\xEAA\x80\x01\x0A)vmwareengine.googleapis.com/DnsForwarding\x12Sprojects/{project}/locations/{location}/privateClouds/{private_cloud}/dnsForwarding\"\xC4\x0A\x0A\x0ENetworkPeering\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x03\x124\x0A\x0Bcreate_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x03 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12\x19\x0A\x0Cpeer_network\x18\x05 \x01(\x09B\x03\xE0A\x02\x12&\x0A\x14export_custom_routes\x18\x08 \x01(\x08B\x03\xE0A\x01H\x00\x88\x01\x01\x12&\x0A\x14import_custom_routes\x18\x09 \x01(\x08B\x03\xE0A\x01H\x01\x88\x01\x01\x12(\x0A\x16exchange_subnet_routes\x18\x0A \x01(\x08B\x03\xE0A\x01H\x02\x88\x01\x01\x125\x0A#export_custom_routes_with_public_ip\x18\x0B \x01(\x08B\x03\xE0A\x01H\x03\x88\x01\x01\x125\x0A#import_custom_routes_with_public_ip\x18\x0C \x01(\x08B\x03\xE0A\x01H\x04\x88\x01\x01\x12F\x0A\x05state\x18\x0D \x01(\x0E22.google.cloud.vmwareengine.v1.NetworkPeering.StateB\x03\xE0A\x03\x12\x1A\x0A\x0Dstate_details\x18\x07 \x01(\x09B\x03\xE0A\x03\x12\x15\x0A\x08peer_mtu\x18\x0E \x01(\x05B\x03\xE0A\x01\x12\\\x0A\x11peer_network_type\x18\x10 \x01(\x0E2<.google.cloud.vmwareengine.v1.NetworkPeering.PeerNetworkTypeB\x03\xE0A\x02\x12\x10\x0A\x03uid\x18\x11 \x01(\x09B\x03\xE0A\x03\x12V\x0A\x15vmware_engine_network\x18\x14 \x01(\x09B7\xE0A\x02\xFAA1\x0A/vmwareengine.googleapis.com/VmwareEngineNetwork\x12\x18\x0A\x0Bdescription\x18\x15 \x01(\x09B\x03\xE0A\x01\"T\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x0C\x0A\x08INACTIVE\x10\x01\x12\x0A\x0A\x06ACTIVE\x10\x02\x12\x0C\x0A\x08CREATING\x10\x03\x12\x0C\x0A\x08DELETING\x10\x04\"\xE3\x01\x0A\x0FPeerNetworkType\x12!\x0A\x1DPEER_NETWORK_TYPE_UNSPECIFIED\x10\x00\x12\x0C\x0A\x08STANDARD\x10\x01\x12\x19\x0A\x15VMWARE_ENGINE_NETWORK\x10\x02\x12\x1B\x0A\x17PRIVATE_SERVICES_ACCESS\x10\x03\x12\x18\x0A\x14NETAPP_CLOUD_VOLUMES\x10\x04\x12\x17\x0A\x13THIRD_PARTY_SERVICE\x10\x05\x12\x13\x0A\x0FDELL_POWERSCALE\x10\x06\x12\x1F\x0A\x1BGOOGLE_CLOUD_NETAPP_VOLUMES\x10\x07:z\xEAAw\x0A*vmwareengine.googleapis.com/NetworkPeering\x12Iprojects/{project}/locations/{location}/networkPeerings/{network_peering}B\x17\x0A\x15_export_custom_routesB\x17\x0A\x15_import_custom_routesB\x19\x0A\x17_exchange_subnet_routesB&\x0A\$_export_custom_routes_with_public_ipB&\x0A\$_import_custom_routes_with_public_ip\"\xB6\x03\x0A\x0CPeeringRoute\x12\x17\x0A\x0Adest_range\x18\x01 \x01(\x09B\x03\xE0A\x03\x12B\x0A\x04type\x18\x02 \x01(\x0E2/.google.cloud.vmwareengine.v1.PeeringRoute.TypeB\x03\xE0A\x03\x12\x1C\x0A\x0Fnext_hop_region\x18\x03 \x01(\x09B\x03\xE0A\x03\x12\x15\x0A\x08priority\x18\x04 \x01(\x03B\x03\xE0A\x03\x12\x15\x0A\x08imported\x18\x05 \x01(\x08B\x03\xE0A\x03\x12L\x0A\x09direction\x18\x06 \x01(\x0E24.google.cloud.vmwareengine.v1.PeeringRoute.DirectionB\x03\xE0A\x03\"k\x0A\x04Type\x12\x14\x0A\x10TYPE_UNSPECIFIED\x10\x00\x12\x19\x0A\x15DYNAMIC_PEERING_ROUTE\x10\x01\x12\x18\x0A\x14STATIC_PEERING_ROUTE\x10\x02\x12\x18\x0A\x14SUBNET_PEERING_ROUTE\x10\x03\"B\x0A\x09Direction\x12\x19\x0A\x15DIRECTION_UNSPECIFIED\x10\x00\x12\x0C\x0A\x08INCOMING\x10\x01\x12\x0C\x0A\x08OUTGOING\x10\x02\"\xFF\x06\x0A\x0DNetworkPolicy\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x03\x124\x0A\x0Bcreate_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x03 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12S\x0A\x0Finternet_access\x18\x06 \x01(\x0B2:.google.cloud.vmwareengine.v1.NetworkPolicy.NetworkService\x12O\x0A\x0Bexternal_ip\x18\x07 \x01(\x0B2:.google.cloud.vmwareengine.v1.NetworkPolicy.NetworkService\x12\x1F\x0A\x12edge_services_cidr\x18\x09 \x01(\x09B\x03\xE0A\x02\x12\x10\x0A\x03uid\x18\x0A \x01(\x09B\x03\xE0A\x03\x12V\x0A\x15vmware_engine_network\x18\x0C \x01(\x09B7\xE0A\x01\xFAA1\x0A/vmwareengine.googleapis.com/VmwareEngineNetwork\x12\x18\x0A\x0Bdescription\x18\x0D \x01(\x09B\x03\xE0A\x01\x12`\x0A\x1Fvmware_engine_network_canonical\x18\x0E \x01(\x09B7\xE0A\x03\xFAA1\x0A/vmwareengine.googleapis.com/VmwareEngineNetwork\x1A\xC7\x01\x0A\x0ENetworkService\x12\x0F\x0A\x07enabled\x18\x01 \x01(\x08\x12T\x0A\x05state\x18\x02 \x01(\x0E2@.google.cloud.vmwareengine.v1.NetworkPolicy.NetworkService.StateB\x03\xE0A\x03\"N\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x11\x0A\x0DUNPROVISIONED\x10\x01\x12\x0F\x0A\x0BRECONCILING\x10\x02\x12\x0A\x0A\x06ACTIVE\x10\x03:x\xEAAu\x0A)vmwareengine.googleapis.com/NetworkPolicy\x12Hprojects/{project}/locations/{location}/networkPolicies/{network_policy}\"\xD3\x05\x0A\x18ManagementDnsZoneBinding\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x03\x124\x0A\x0Bcreate_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x03 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12P\x0A\x05state\x18\x08 \x01(\x0E2<.google.cloud.vmwareengine.v1.ManagementDnsZoneBinding.StateB\x03\xE0A\x03\x12\x13\x0A\x0Bdescription\x18\x0D \x01(\x09\x12:\x0A\x0Bvpc_network\x18\x0E \x01(\x09B#\xFAA \x0A\x1Ecompute.googleapis.com/NetworkH\x00\x12U\x0A\x15vmware_engine_network\x18\x0F \x01(\x09B4\xFAA1\x0A/vmwareengine.googleapis.com/VmwareEngineNetworkH\x00\x12\x10\x0A\x03uid\x18\x09 \x01(\x09B\x03\xE0A\x03\"`\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x0A\x0A\x06ACTIVE\x10\x01\x12\x0C\x0A\x08CREATING\x10\x02\x12\x0C\x0A\x08UPDATING\x10\x03\x12\x0C\x0A\x08DELETING\x10\x04\x12\x0A\x0A\x06FAILED\x10\x05:\xB9\x01\xEAA\xB5\x01\x0A4vmwareengine.googleapis.com/ManagementDnsZoneBinding\x12}projects/{project}/locations/{location}/privateClouds/{private_cloud}/managementDnsZoneBindings/{management_dns_zone_binding}B\x0E\x0A\x0Cbind_network\"\xC0\x07\x0A\x13VmwareEngineNetwork\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x03\x124\x0A\x0Bcreate_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x03 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12\x13\x0A\x0Bdescription\x18\x05 \x01(\x09\x12W\x0A\x0Cvpc_networks\x18\x06 \x03(\x0B2<.google.cloud.vmwareengine.v1.VmwareEngineNetwork.VpcNetworkB\x03\xE0A\x03\x12K\x0A\x05state\x18\x07 \x01(\x0E27.google.cloud.vmwareengine.v1.VmwareEngineNetwork.StateB\x03\xE0A\x03\x12I\x0A\x04type\x18\x08 \x01(\x0E26.google.cloud.vmwareengine.v1.VmwareEngineNetwork.TypeB\x03\xE0A\x02\x12\x10\x0A\x03uid\x18\x09 \x01(\x09B\x03\xE0A\x03\x12\x0C\x0A\x04etag\x18\x0A \x01(\x09\x1A\xE7\x01\x0A\x0AVpcNetwork\x12T\x0A\x04type\x18\x01 \x01(\x0E2A.google.cloud.vmwareengine.v1.VmwareEngineNetwork.VpcNetwork.TypeB\x03\xE0A\x03\x127\x0A\x07network\x18\x02 \x01(\x09B&\xE0A\x03\xFAA \x0A\x1Ecompute.googleapis.com/Network\"J\x0A\x04Type\x12\x14\x0A\x10TYPE_UNSPECIFIED\x10\x00\x12\x0C\x0A\x08INTRANET\x10\x01\x12\x0C\x0A\x08INTERNET\x10\x02\x12\x10\x0A\x0CGOOGLE_CLOUD\x10\x03\"T\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x0C\x0A\x08CREATING\x10\x01\x12\x0A\x0A\x06ACTIVE\x10\x02\x12\x0C\x0A\x08UPDATING\x10\x03\x12\x0C\x0A\x08DELETING\x10\x04\"6\x0A\x04Type\x12\x14\x0A\x10TYPE_UNSPECIFIED\x10\x00\x12\x0A\x0A\x06LEGACY\x10\x01\x12\x0C\x0A\x08STANDARD\x10\x02:\x8B\x01\xEAA\x87\x01\x0A/vmwareengine.googleapis.com/VmwareEngineNetwork\x12Tprojects/{project}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network}\"\xB7\x0A\x0A\x11PrivateConnection\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x03\x124\x0A\x0Bcreate_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x03 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12\x18\x0A\x0Bdescription\x18\x04 \x01(\x09B\x03\xE0A\x01\x12I\x0A\x05state\x18\x05 \x01(\x0E25.google.cloud.vmwareengine.v1.PrivateConnection.StateB\x03\xE0A\x03\x12V\x0A\x15vmware_engine_network\x18\x08 \x01(\x09B7\xE0A\x02\xFAA1\x0A/vmwareengine.googleapis.com/VmwareEngineNetwork\x12`\x0A\x1Fvmware_engine_network_canonical\x18\x09 \x01(\x09B7\xE0A\x03\xFAA1\x0A/vmwareengine.googleapis.com/VmwareEngineNetwork\x12G\x0A\x04type\x18\x0A \x01(\x0E24.google.cloud.vmwareengine.v1.PrivateConnection.TypeB\x03\xE0A\x02\x12\x17\x0A\x0Apeering_id\x18\x0C \x01(\x09B\x03\xE0A\x03\x12V\x0A\x0Crouting_mode\x18\x0D \x01(\x0E2;.google.cloud.vmwareengine.v1.PrivateConnection.RoutingModeB\x03\xE0A\x01\x12\x10\x0A\x03uid\x18\x0E \x01(\x09B\x03\xE0A\x03\x12?\x0A\x0Fservice_network\x18\x10 \x01(\x09B&\xE0A\x02\xFAA \x0A\x1Ecompute.googleapis.com/Network\x12X\x0A\x0Dpeering_state\x18\x11 \x01(\x0E2<.google.cloud.vmwareengine.v1.PrivateConnection.PeeringStateB\x03\xE0A\x03\"s\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x0C\x0A\x08CREATING\x10\x01\x12\x0A\x0A\x06ACTIVE\x10\x02\x12\x0C\x0A\x08UPDATING\x10\x03\x12\x0C\x0A\x08DELETING\x10\x04\x12\x11\x0A\x0DUNPROVISIONED\x10\x05\x12\x0A\x0A\x06FAILED\x10\x06\"\x80\x01\x0A\x04Type\x12\x14\x0A\x10TYPE_UNSPECIFIED\x10\x00\x12\x1A\x0A\x16PRIVATE_SERVICE_ACCESS\x10\x01\x12\x18\x0A\x14NETAPP_CLOUD_VOLUMES\x10\x02\x12\x13\x0A\x0FDELL_POWERSCALE\x10\x03\x12\x17\x0A\x13THIRD_PARTY_SERVICE\x10\x04\"E\x0A\x0BRoutingMode\x12\x1C\x0A\x18ROUTING_MODE_UNSPECIFIED\x10\x00\x12\x0A\x0A\x06GLOBAL\x10\x01\x12\x0C\x0A\x08REGIONAL\x10\x02\"W\x0A\x0CPeeringState\x12\x1D\x0A\x19PEERING_STATE_UNSPECIFIED\x10\x00\x12\x12\x0A\x0EPEERING_ACTIVE\x10\x01\x12\x14\x0A\x10PEERING_INACTIVE\x10\x02:\x84\x01\xEAA\x80\x01\x0A-vmwareengine.googleapis.com/PrivateConnection\x12Oprojects/{project}/locations/{location}/privateConnections/{private_connection}\"\xAA\x01\x0A\x10LocationMetadata\x12T\x0A\x0Ccapabilities\x18\x01 \x03(\x0E29.google.cloud.vmwareengine.v1.LocationMetadata.CapabilityB\x03\xE0A\x03\"@\x0A\x0ACapability\x12\x1A\x0A\x16CAPABILITY_UNSPECIFIED\x10\x00\x12\x16\x0A\x12STRETCHED_CLUSTERS\x10\x01\"\xD7\x01\x0A\x11DnsBindPermission\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x03\x12@\x0A\x0Aprincipals\x18\x02 \x03(\x0B2'.google.cloud.vmwareengine.v1.PrincipalB\x03\xE0A\x03:m\xEAAj\x0A-vmwareengine.googleapis.com/DnsBindPermission\x129projects/{project}/locations/{location}/dnsBindPermission\"C\x0A\x09Principal\x12\x0E\x0A\x04user\x18\x01 \x01(\x09H\x00\x12\x19\x0A\x0Fservice_account\x18\x02 \x01(\x09H\x00B\x0B\x0A\x09principalB\xE6\x01\x0A com.google.cloud.vmwareengine.v1B\x1AVmwareengineResourcesProtoP\x01ZDcloud.google.com/go/vmwareengine/apiv1/vmwareenginepb;vmwareenginepb\xAA\x02\x1CGoogle.Cloud.VmwareEngine.V1\xCA\x02\x1CGoogle\\Cloud\\VmwareEngine\\V1\xEA\x02\x1FGoogle::Cloud::VmwareEngine::V1b\x06proto3" + , true); + + static::$is_initialized = true; + } +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/AutoscalingSettings.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/AutoscalingSettings.php new file mode 100644 index 000000000000..b66fb8fcf96b --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/AutoscalingSettings.php @@ -0,0 +1,240 @@ +google.cloud.vmwareengine.v1.AutoscalingSettings + */ +class AutoscalingSettings extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The map with autoscaling policies applied to the cluster. + * The key is the identifier of the policy. + * It must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC + * 1034](https://datatracker.ietf.org/doc/html/rfc1034) (section 3.5) + * Currently there map must contain only one element + * that describes the autoscaling policy for compute nodes. + * + * Generated from protobuf field map autoscaling_policies = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + private $autoscaling_policies; + /** + * Optional. Minimum number of nodes of any type in a cluster. + * If not specified the default limits apply. + * + * Generated from protobuf field int32 min_cluster_node_count = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $min_cluster_node_count = 0; + /** + * Optional. Maximum number of nodes of any type in a cluster. + * If not specified the default limits apply. + * + * Generated from protobuf field int32 max_cluster_node_count = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $max_cluster_node_count = 0; + /** + * Optional. The minimum duration between consecutive autoscale operations. + * It starts once addition or removal of nodes is fully completed. + * Defaults to 30 minutes if not specified. Cool down period must be in whole + * minutes (for example, 30, 31, 50, 180 minutes). + * + * Generated from protobuf field .google.protobuf.Duration cool_down_period = 4 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $cool_down_period = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array|\Google\Protobuf\Internal\MapField $autoscaling_policies + * Required. The map with autoscaling policies applied to the cluster. + * The key is the identifier of the policy. + * It must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC + * 1034](https://datatracker.ietf.org/doc/html/rfc1034) (section 3.5) + * Currently there map must contain only one element + * that describes the autoscaling policy for compute nodes. + * @type int $min_cluster_node_count + * Optional. Minimum number of nodes of any type in a cluster. + * If not specified the default limits apply. + * @type int $max_cluster_node_count + * Optional. Maximum number of nodes of any type in a cluster. + * If not specified the default limits apply. + * @type \Google\Protobuf\Duration $cool_down_period + * Optional. The minimum duration between consecutive autoscale operations. + * It starts once addition or removal of nodes is fully completed. + * Defaults to 30 minutes if not specified. Cool down period must be in whole + * minutes (for example, 30, 31, 50, 180 minutes). + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); + parent::__construct($data); + } + + /** + * Required. The map with autoscaling policies applied to the cluster. + * The key is the identifier of the policy. + * It must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC + * 1034](https://datatracker.ietf.org/doc/html/rfc1034) (section 3.5) + * Currently there map must contain only one element + * that describes the autoscaling policy for compute nodes. + * + * Generated from protobuf field map autoscaling_policies = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Protobuf\Internal\MapField + */ + public function getAutoscalingPolicies() + { + return $this->autoscaling_policies; + } + + /** + * Required. The map with autoscaling policies applied to the cluster. + * The key is the identifier of the policy. + * It must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC + * 1034](https://datatracker.ietf.org/doc/html/rfc1034) (section 3.5) + * Currently there map must contain only one element + * that describes the autoscaling policy for compute nodes. + * + * Generated from protobuf field map autoscaling_policies = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param array|\Google\Protobuf\Internal\MapField $var + * @return $this + */ + public function setAutoscalingPolicies($var) + { + $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\AutoscalingSettings\AutoscalingPolicy::class); + $this->autoscaling_policies = $arr; + + return $this; + } + + /** + * Optional. Minimum number of nodes of any type in a cluster. + * If not specified the default limits apply. + * + * Generated from protobuf field int32 min_cluster_node_count = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return int + */ + public function getMinClusterNodeCount() + { + return $this->min_cluster_node_count; + } + + /** + * Optional. Minimum number of nodes of any type in a cluster. + * If not specified the default limits apply. + * + * Generated from protobuf field int32 min_cluster_node_count = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @param int $var + * @return $this + */ + public function setMinClusterNodeCount($var) + { + GPBUtil::checkInt32($var); + $this->min_cluster_node_count = $var; + + return $this; + } + + /** + * Optional. Maximum number of nodes of any type in a cluster. + * If not specified the default limits apply. + * + * Generated from protobuf field int32 max_cluster_node_count = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return int + */ + public function getMaxClusterNodeCount() + { + return $this->max_cluster_node_count; + } + + /** + * Optional. Maximum number of nodes of any type in a cluster. + * If not specified the default limits apply. + * + * Generated from protobuf field int32 max_cluster_node_count = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @param int $var + * @return $this + */ + public function setMaxClusterNodeCount($var) + { + GPBUtil::checkInt32($var); + $this->max_cluster_node_count = $var; + + return $this; + } + + /** + * Optional. The minimum duration between consecutive autoscale operations. + * It starts once addition or removal of nodes is fully completed. + * Defaults to 30 minutes if not specified. Cool down period must be in whole + * minutes (for example, 30, 31, 50, 180 minutes). + * + * Generated from protobuf field .google.protobuf.Duration cool_down_period = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Protobuf\Duration|null + */ + public function getCoolDownPeriod() + { + return $this->cool_down_period; + } + + public function hasCoolDownPeriod() + { + return isset($this->cool_down_period); + } + + public function clearCoolDownPeriod() + { + unset($this->cool_down_period); + } + + /** + * Optional. The minimum duration between consecutive autoscale operations. + * It starts once addition or removal of nodes is fully completed. + * Defaults to 30 minutes if not specified. Cool down period must be in whole + * minutes (for example, 30, 31, 50, 180 minutes). + * + * Generated from protobuf field .google.protobuf.Duration cool_down_period = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Protobuf\Duration $var + * @return $this + */ + public function setCoolDownPeriod($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); + $this->cool_down_period = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/AutoscalingSettings/AutoscalingPolicy.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/AutoscalingSettings/AutoscalingPolicy.php new file mode 100644 index 000000000000..ce22510f7520 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/AutoscalingSettings/AutoscalingPolicy.php @@ -0,0 +1,302 @@ +google.cloud.vmwareengine.v1.AutoscalingSettings.AutoscalingPolicy + */ +class AutoscalingPolicy extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The canonical identifier of the node type to add or remove. + * Corresponds to the `NodeType`. + * + * Generated from protobuf field string node_type_id = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $node_type_id = ''; + /** + * Required. Number of nodes to add to a cluster during a scale-out + * operation. Must be divisible by 2 for stretched clusters. During a + * scale-in operation only one node (or 2 for stretched clusters) are + * removed in a single iteration. + * + * Generated from protobuf field int32 scale_out_size = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $scale_out_size = 0; + /** + * Optional. Utilization thresholds pertaining to CPU utilization. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.AutoscalingSettings.Thresholds cpu_thresholds = 11 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $cpu_thresholds = null; + /** + * Optional. Utilization thresholds pertaining to amount of granted memory. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.AutoscalingSettings.Thresholds granted_memory_thresholds = 12 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $granted_memory_thresholds = null; + /** + * Optional. Utilization thresholds pertaining to amount of consumed memory. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.AutoscalingSettings.Thresholds consumed_memory_thresholds = 13 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $consumed_memory_thresholds = null; + /** + * Optional. Utilization thresholds pertaining to amount of consumed + * storage. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.AutoscalingSettings.Thresholds storage_thresholds = 14 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $storage_thresholds = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $node_type_id + * Required. The canonical identifier of the node type to add or remove. + * Corresponds to the `NodeType`. + * @type int $scale_out_size + * Required. Number of nodes to add to a cluster during a scale-out + * operation. Must be divisible by 2 for stretched clusters. During a + * scale-in operation only one node (or 2 for stretched clusters) are + * removed in a single iteration. + * @type \Google\Cloud\VmwareEngine\V1\AutoscalingSettings\Thresholds $cpu_thresholds + * Optional. Utilization thresholds pertaining to CPU utilization. + * @type \Google\Cloud\VmwareEngine\V1\AutoscalingSettings\Thresholds $granted_memory_thresholds + * Optional. Utilization thresholds pertaining to amount of granted memory. + * @type \Google\Cloud\VmwareEngine\V1\AutoscalingSettings\Thresholds $consumed_memory_thresholds + * Optional. Utilization thresholds pertaining to amount of consumed memory. + * @type \Google\Cloud\VmwareEngine\V1\AutoscalingSettings\Thresholds $storage_thresholds + * Optional. Utilization thresholds pertaining to amount of consumed + * storage. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); + parent::__construct($data); + } + + /** + * Required. The canonical identifier of the node type to add or remove. + * Corresponds to the `NodeType`. + * + * Generated from protobuf field string node_type_id = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getNodeTypeId() + { + return $this->node_type_id; + } + + /** + * Required. The canonical identifier of the node type to add or remove. + * Corresponds to the `NodeType`. + * + * Generated from protobuf field string node_type_id = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setNodeTypeId($var) + { + GPBUtil::checkString($var, True); + $this->node_type_id = $var; + + return $this; + } + + /** + * Required. Number of nodes to add to a cluster during a scale-out + * operation. Must be divisible by 2 for stretched clusters. During a + * scale-in operation only one node (or 2 for stretched clusters) are + * removed in a single iteration. + * + * Generated from protobuf field int32 scale_out_size = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return int + */ + public function getScaleOutSize() + { + return $this->scale_out_size; + } + + /** + * Required. Number of nodes to add to a cluster during a scale-out + * operation. Must be divisible by 2 for stretched clusters. During a + * scale-in operation only one node (or 2 for stretched clusters) are + * removed in a single iteration. + * + * Generated from protobuf field int32 scale_out_size = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param int $var + * @return $this + */ + public function setScaleOutSize($var) + { + GPBUtil::checkInt32($var); + $this->scale_out_size = $var; + + return $this; + } + + /** + * Optional. Utilization thresholds pertaining to CPU utilization. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.AutoscalingSettings.Thresholds cpu_thresholds = 11 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\VmwareEngine\V1\AutoscalingSettings\Thresholds|null + */ + public function getCpuThresholds() + { + return $this->cpu_thresholds; + } + + public function hasCpuThresholds() + { + return isset($this->cpu_thresholds); + } + + public function clearCpuThresholds() + { + unset($this->cpu_thresholds); + } + + /** + * Optional. Utilization thresholds pertaining to CPU utilization. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.AutoscalingSettings.Thresholds cpu_thresholds = 11 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\VmwareEngine\V1\AutoscalingSettings\Thresholds $var + * @return $this + */ + public function setCpuThresholds($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\AutoscalingSettings\Thresholds::class); + $this->cpu_thresholds = $var; + + return $this; + } + + /** + * Optional. Utilization thresholds pertaining to amount of granted memory. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.AutoscalingSettings.Thresholds granted_memory_thresholds = 12 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\VmwareEngine\V1\AutoscalingSettings\Thresholds|null + */ + public function getGrantedMemoryThresholds() + { + return $this->granted_memory_thresholds; + } + + public function hasGrantedMemoryThresholds() + { + return isset($this->granted_memory_thresholds); + } + + public function clearGrantedMemoryThresholds() + { + unset($this->granted_memory_thresholds); + } + + /** + * Optional. Utilization thresholds pertaining to amount of granted memory. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.AutoscalingSettings.Thresholds granted_memory_thresholds = 12 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\VmwareEngine\V1\AutoscalingSettings\Thresholds $var + * @return $this + */ + public function setGrantedMemoryThresholds($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\AutoscalingSettings\Thresholds::class); + $this->granted_memory_thresholds = $var; + + return $this; + } + + /** + * Optional. Utilization thresholds pertaining to amount of consumed memory. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.AutoscalingSettings.Thresholds consumed_memory_thresholds = 13 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\VmwareEngine\V1\AutoscalingSettings\Thresholds|null + */ + public function getConsumedMemoryThresholds() + { + return $this->consumed_memory_thresholds; + } + + public function hasConsumedMemoryThresholds() + { + return isset($this->consumed_memory_thresholds); + } + + public function clearConsumedMemoryThresholds() + { + unset($this->consumed_memory_thresholds); + } + + /** + * Optional. Utilization thresholds pertaining to amount of consumed memory. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.AutoscalingSettings.Thresholds consumed_memory_thresholds = 13 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\VmwareEngine\V1\AutoscalingSettings\Thresholds $var + * @return $this + */ + public function setConsumedMemoryThresholds($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\AutoscalingSettings\Thresholds::class); + $this->consumed_memory_thresholds = $var; + + return $this; + } + + /** + * Optional. Utilization thresholds pertaining to amount of consumed + * storage. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.AutoscalingSettings.Thresholds storage_thresholds = 14 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\VmwareEngine\V1\AutoscalingSettings\Thresholds|null + */ + public function getStorageThresholds() + { + return $this->storage_thresholds; + } + + public function hasStorageThresholds() + { + return isset($this->storage_thresholds); + } + + public function clearStorageThresholds() + { + unset($this->storage_thresholds); + } + + /** + * Optional. Utilization thresholds pertaining to amount of consumed + * storage. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.AutoscalingSettings.Thresholds storage_thresholds = 14 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\VmwareEngine\V1\AutoscalingSettings\Thresholds $var + * @return $this + */ + public function setStorageThresholds($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\AutoscalingSettings\Thresholds::class); + $this->storage_thresholds = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/AutoscalingSettings/Thresholds.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/AutoscalingSettings/Thresholds.php new file mode 100644 index 000000000000..cd63eb0853bb --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/AutoscalingSettings/Thresholds.php @@ -0,0 +1,102 @@ +google.cloud.vmwareengine.v1.AutoscalingSettings.Thresholds + */ +class Thresholds extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The utilization triggering the scale-out operation in percent. + * + * Generated from protobuf field int32 scale_out = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $scale_out = 0; + /** + * Required. The utilization triggering the scale-in operation in percent. + * + * Generated from protobuf field int32 scale_in = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $scale_in = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $scale_out + * Required. The utilization triggering the scale-out operation in percent. + * @type int $scale_in + * Required. The utilization triggering the scale-in operation in percent. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); + parent::__construct($data); + } + + /** + * Required. The utilization triggering the scale-out operation in percent. + * + * Generated from protobuf field int32 scale_out = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return int + */ + public function getScaleOut() + { + return $this->scale_out; + } + + /** + * Required. The utilization triggering the scale-out operation in percent. + * + * Generated from protobuf field int32 scale_out = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param int $var + * @return $this + */ + public function setScaleOut($var) + { + GPBUtil::checkInt32($var); + $this->scale_out = $var; + + return $this; + } + + /** + * Required. The utilization triggering the scale-in operation in percent. + * + * Generated from protobuf field int32 scale_in = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return int + */ + public function getScaleIn() + { + return $this->scale_in; + } + + /** + * Required. The utilization triggering the scale-in operation in percent. + * + * Generated from protobuf field int32 scale_in = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param int $var + * @return $this + */ + public function setScaleIn($var) + { + GPBUtil::checkInt32($var); + $this->scale_in = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Cluster.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Cluster.php new file mode 100644 index 000000000000..fd38ab8ff230 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Cluster.php @@ -0,0 +1,411 @@ +google.cloud.vmwareengine.v1.Cluster + */ +class Cluster extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. The resource name of this cluster. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $name = ''; + /** + * Output only. Creation time of this resource. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $create_time = null; + /** + * Output only. Last update time of this resource. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $update_time = null; + /** + * Output only. State of the resource. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.Cluster.State state = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $state = 0; + /** + * Output only. True if the cluster is a management cluster; false otherwise. + * There can only be one management cluster in a private cloud + * and it has to be the first one. + * + * Generated from protobuf field bool management = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $management = false; + /** + * Optional. Configuration of the autoscaling applied to this cluster. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.AutoscalingSettings autoscaling_settings = 18 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $autoscaling_settings = null; + /** + * Output only. System-generated unique identifier for the resource. + * + * Generated from protobuf field string uid = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $uid = ''; + /** + * Required. The map of cluster node types in this cluster, where the key is + * canonical identifier of the node type (corresponds to the `NodeType`). + * + * Generated from protobuf field map node_type_configs = 16 [(.google.api.field_behavior) = REQUIRED]; + */ + private $node_type_configs; + /** + * Optional. Configuration of a stretched cluster. Required for clusters that + * belong to a STRETCHED private cloud. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.StretchedClusterConfig stretched_cluster_config = 17 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $stretched_cluster_config = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Output only. The resource name of this cluster. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster` + * @type \Google\Protobuf\Timestamp $create_time + * Output only. Creation time of this resource. + * @type \Google\Protobuf\Timestamp $update_time + * Output only. Last update time of this resource. + * @type int $state + * Output only. State of the resource. + * @type bool $management + * Output only. True if the cluster is a management cluster; false otherwise. + * There can only be one management cluster in a private cloud + * and it has to be the first one. + * @type \Google\Cloud\VmwareEngine\V1\AutoscalingSettings $autoscaling_settings + * Optional. Configuration of the autoscaling applied to this cluster. + * @type string $uid + * Output only. System-generated unique identifier for the resource. + * @type array|\Google\Protobuf\Internal\MapField $node_type_configs + * Required. The map of cluster node types in this cluster, where the key is + * canonical identifier of the node type (corresponds to the `NodeType`). + * @type \Google\Cloud\VmwareEngine\V1\StretchedClusterConfig $stretched_cluster_config + * Optional. Configuration of a stretched cluster. Required for clusters that + * belong to a STRETCHED private cloud. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); + parent::__construct($data); + } + + /** + * Output only. The resource name of this cluster. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster` + * + * 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 cluster. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster` + * + * 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. Creation time of this resource. + * + * 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 time of this resource. + * + * 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 time of this resource. + * + * 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 time of this resource. + * + * 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. State of the resource. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.Cluster.State state = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getState() + { + return $this->state; + } + + /** + * Output only. State of the resource. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.Cluster.State state = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setState($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\Cluster\State::class); + $this->state = $var; + + return $this; + } + + /** + * Output only. True if the cluster is a management cluster; false otherwise. + * There can only be one management cluster in a private cloud + * and it has to be the first one. + * + * Generated from protobuf field bool management = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return bool + */ + public function getManagement() + { + return $this->management; + } + + /** + * Output only. True if the cluster is a management cluster; false otherwise. + * There can only be one management cluster in a private cloud + * and it has to be the first one. + * + * Generated from protobuf field bool management = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param bool $var + * @return $this + */ + public function setManagement($var) + { + GPBUtil::checkBool($var); + $this->management = $var; + + return $this; + } + + /** + * Optional. Configuration of the autoscaling applied to this cluster. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.AutoscalingSettings autoscaling_settings = 18 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\VmwareEngine\V1\AutoscalingSettings|null + */ + public function getAutoscalingSettings() + { + return $this->autoscaling_settings; + } + + public function hasAutoscalingSettings() + { + return isset($this->autoscaling_settings); + } + + public function clearAutoscalingSettings() + { + unset($this->autoscaling_settings); + } + + /** + * Optional. Configuration of the autoscaling applied to this cluster. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.AutoscalingSettings autoscaling_settings = 18 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\VmwareEngine\V1\AutoscalingSettings $var + * @return $this + */ + public function setAutoscalingSettings($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\AutoscalingSettings::class); + $this->autoscaling_settings = $var; + + return $this; + } + + /** + * Output only. System-generated unique identifier for the resource. + * + * Generated from protobuf field string uid = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getUid() + { + return $this->uid; + } + + /** + * Output only. System-generated unique identifier for the resource. + * + * Generated from protobuf field string uid = 14 [(.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 map of cluster node types in this cluster, where the key is + * canonical identifier of the node type (corresponds to the `NodeType`). + * + * Generated from protobuf field map node_type_configs = 16 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Protobuf\Internal\MapField + */ + public function getNodeTypeConfigs() + { + return $this->node_type_configs; + } + + /** + * Required. The map of cluster node types in this cluster, where the key is + * canonical identifier of the node type (corresponds to the `NodeType`). + * + * Generated from protobuf field map node_type_configs = 16 [(.google.api.field_behavior) = REQUIRED]; + * @param array|\Google\Protobuf\Internal\MapField $var + * @return $this + */ + public function setNodeTypeConfigs($var) + { + $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\NodeTypeConfig::class); + $this->node_type_configs = $arr; + + return $this; + } + + /** + * Optional. Configuration of a stretched cluster. Required for clusters that + * belong to a STRETCHED private cloud. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.StretchedClusterConfig stretched_cluster_config = 17 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\VmwareEngine\V1\StretchedClusterConfig|null + */ + public function getStretchedClusterConfig() + { + return $this->stretched_cluster_config; + } + + public function hasStretchedClusterConfig() + { + return isset($this->stretched_cluster_config); + } + + public function clearStretchedClusterConfig() + { + unset($this->stretched_cluster_config); + } + + /** + * Optional. Configuration of a stretched cluster. Required for clusters that + * belong to a STRETCHED private cloud. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.StretchedClusterConfig stretched_cluster_config = 17 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\VmwareEngine\V1\StretchedClusterConfig $var + * @return $this + */ + public function setStretchedClusterConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\StretchedClusterConfig::class); + $this->stretched_cluster_config = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Cluster/State.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Cluster/State.php new file mode 100644 index 000000000000..f95198a8435b --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Cluster/State.php @@ -0,0 +1,84 @@ +google.cloud.vmwareengine.v1.Cluster.State + */ +class State +{ + /** + * The default value. This value should never be used. + * + * Generated from protobuf enum STATE_UNSPECIFIED = 0; + */ + const STATE_UNSPECIFIED = 0; + /** + * The Cluster is operational and can be used by the user. + * + * Generated from protobuf enum ACTIVE = 1; + */ + const ACTIVE = 1; + /** + * The Cluster is being deployed. + * + * Generated from protobuf enum CREATING = 2; + */ + const CREATING = 2; + /** + * Adding or removing of a node to the cluster, any other cluster specific + * updates. + * + * Generated from protobuf enum UPDATING = 3; + */ + const UPDATING = 3; + /** + * The Cluster is being deleted. + * + * Generated from protobuf enum DELETING = 4; + */ + const DELETING = 4; + /** + * The Cluster is undergoing maintenance, for example: a failed node is + * getting replaced. + * + * Generated from protobuf enum REPAIRING = 5; + */ + const REPAIRING = 5; + + private static $valueToName = [ + self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', + self::ACTIVE => 'ACTIVE', + self::CREATING => 'CREATING', + self::UPDATING => 'UPDATING', + self::DELETING => 'DELETING', + self::REPAIRING => 'REPAIRING', + ]; + + 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateClusterRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateClusterRequest.php new file mode 100644 index 000000000000..27b345cf2581 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateClusterRequest.php @@ -0,0 +1,306 @@ +google.cloud.vmwareengine.v1.CreateClusterRequest + */ +class CreateClusterRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the private cloud to create a new cluster + * in. Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. The user-provided identifier of the new `Cluster`. + * This identifier must be unique among clusters within the parent and becomes + * the final token in the name URI. + * The identifier must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * Generated from protobuf field string cluster_id = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $cluster_id = ''; + /** + * Required. The initial description of the new cluster. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.Cluster cluster = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $cluster = null; + /** + * Optional. 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. True if you want the request to be validated and not executed; + * false otherwise. + * + * Generated from protobuf field bool validate_only = 5 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $validate_only = false; + + /** + * @param string $parent Required. The resource name of the private cloud to create a new cluster + * in. Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * Please see {@see VmwareEngineClient::privateCloudName()} for help formatting this field. + * @param \Google\Cloud\VmwareEngine\V1\Cluster $cluster Required. The initial description of the new cluster. + * @param string $clusterId Required. The user-provided identifier of the new `Cluster`. + * This identifier must be unique among clusters within the parent and becomes + * the final token in the name URI. + * The identifier must meet the following requirements: + * + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * @return \Google\Cloud\VmwareEngine\V1\CreateClusterRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\VmwareEngine\V1\Cluster $cluster, string $clusterId): self + { + return (new self()) + ->setParent($parent) + ->setCluster($cluster) + ->setClusterId($clusterId); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. The resource name of the private cloud to create a new cluster + * in. Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * @type string $cluster_id + * Required. The user-provided identifier of the new `Cluster`. + * This identifier must be unique among clusters within the parent and becomes + * the final token in the name URI. + * The identifier must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * @type \Google\Cloud\VmwareEngine\V1\Cluster $cluster + * Required. The initial description of the new cluster. + * @type string $request_id + * Optional. 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. True if you want the request to be validated and not executed; + * false otherwise. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the private cloud to create a new cluster + * in. Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * 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 private cloud to create a new cluster + * in. Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * 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 user-provided identifier of the new `Cluster`. + * This identifier must be unique among clusters within the parent and becomes + * the final token in the name URI. + * The identifier must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * Generated from protobuf field string cluster_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getClusterId() + { + return $this->cluster_id; + } + + /** + * Required. The user-provided identifier of the new `Cluster`. + * This identifier must be unique among clusters within the parent and becomes + * the final token in the name URI. + * The identifier must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * Generated from protobuf field string cluster_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setClusterId($var) + { + GPBUtil::checkString($var, True); + $this->cluster_id = $var; + + return $this; + } + + /** + * Required. The initial description of the new cluster. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.Cluster cluster = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\VmwareEngine\V1\Cluster|null + */ + public function getCluster() + { + return $this->cluster; + } + + public function hasCluster() + { + return isset($this->cluster); + } + + public function clearCluster() + { + unset($this->cluster); + } + + /** + * Required. The initial description of the new cluster. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.Cluster cluster = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\VmwareEngine\V1\Cluster $var + * @return $this + */ + public function setCluster($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\Cluster::class); + $this->cluster = $var; + + return $this; + } + + /** + * Optional. 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. 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. True if you want the request to be validated and not executed; + * false otherwise. + * + * Generated from protobuf field bool validate_only = 5 [(.google.api.field_behavior) = OPTIONAL]; + * @return bool + */ + public function getValidateOnly() + { + return $this->validate_only; + } + + /** + * Optional. True if you want the request to be validated and not executed; + * false otherwise. + * + * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateExternalAccessRuleRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateExternalAccessRuleRequest.php new file mode 100644 index 000000000000..cc97d6cdf78f --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateExternalAccessRuleRequest.php @@ -0,0 +1,313 @@ +google.cloud.vmwareengine.v1.CreateExternalAccessRuleRequest + */ +class CreateExternalAccessRuleRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the network policy + * to create a new external access firewall rule in. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/networkPolicies/my-policy` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. The initial description of a new external access rule. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.ExternalAccessRule external_access_rule = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $external_access_rule = null; + /** + * Required. The user-provided identifier of the `ExternalAccessRule` to be + * created. This identifier must be unique among `ExternalAccessRule` + * resources within the parent and becomes the final token in the name URI. + * The identifier must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * Generated from protobuf field string external_access_rule_id = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $external_access_rule_id = ''; + /** + * A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 the 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; + */ + protected $request_id = ''; + + /** + * @param string $parent Required. The resource name of the network policy + * to create a new external access firewall rule in. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/networkPolicies/my-policy` + * Please see {@see VmwareEngineClient::networkPolicyName()} for help formatting this field. + * @param \Google\Cloud\VmwareEngine\V1\ExternalAccessRule $externalAccessRule Required. The initial description of a new external access rule. + * @param string $externalAccessRuleId Required. The user-provided identifier of the `ExternalAccessRule` to be + * created. This identifier must be unique among `ExternalAccessRule` + * resources within the parent and becomes the final token in the name URI. + * The identifier must meet the following requirements: + * + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * @return \Google\Cloud\VmwareEngine\V1\CreateExternalAccessRuleRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\VmwareEngine\V1\ExternalAccessRule $externalAccessRule, string $externalAccessRuleId): self + { + return (new self()) + ->setParent($parent) + ->setExternalAccessRule($externalAccessRule) + ->setExternalAccessRuleId($externalAccessRuleId); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. The resource name of the network policy + * to create a new external access firewall rule in. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/networkPolicies/my-policy` + * @type \Google\Cloud\VmwareEngine\V1\ExternalAccessRule $external_access_rule + * Required. The initial description of a new external access rule. + * @type string $external_access_rule_id + * Required. The user-provided identifier of the `ExternalAccessRule` to be + * created. This identifier must be unique among `ExternalAccessRule` + * resources within the parent and becomes the final token in the name URI. + * The identifier must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * @type string $request_id + * A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 the 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\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the network policy + * to create a new external access firewall rule in. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/networkPolicies/my-policy` + * + * 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 network policy + * to create a new external access firewall rule in. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/networkPolicies/my-policy` + * + * 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 initial description of a new external access rule. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.ExternalAccessRule external_access_rule = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\VmwareEngine\V1\ExternalAccessRule|null + */ + public function getExternalAccessRule() + { + return $this->external_access_rule; + } + + public function hasExternalAccessRule() + { + return isset($this->external_access_rule); + } + + public function clearExternalAccessRule() + { + unset($this->external_access_rule); + } + + /** + * Required. The initial description of a new external access rule. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.ExternalAccessRule external_access_rule = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\VmwareEngine\V1\ExternalAccessRule $var + * @return $this + */ + public function setExternalAccessRule($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\ExternalAccessRule::class); + $this->external_access_rule = $var; + + return $this; + } + + /** + * Required. The user-provided identifier of the `ExternalAccessRule` to be + * created. This identifier must be unique among `ExternalAccessRule` + * resources within the parent and becomes the final token in the name URI. + * The identifier must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * Generated from protobuf field string external_access_rule_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getExternalAccessRuleId() + { + return $this->external_access_rule_id; + } + + /** + * Required. The user-provided identifier of the `ExternalAccessRule` to be + * created. This identifier must be unique among `ExternalAccessRule` + * resources within the parent and becomes the final token in the name URI. + * The identifier must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * Generated from protobuf field string external_access_rule_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setExternalAccessRuleId($var) + { + GPBUtil::checkString($var, True); + $this->external_access_rule_id = $var; + + return $this; + } + + /** + * A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 the 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; + * @return string + */ + public function getRequestId() + { + return $this->request_id; + } + + /** + * A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 the 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; + * @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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateExternalAddressRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateExternalAddressRequest.php new file mode 100644 index 000000000000..19541a175e24 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateExternalAddressRequest.php @@ -0,0 +1,313 @@ +google.cloud.vmwareengine.v1.CreateExternalAddressRequest + */ +class CreateExternalAddressRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the private cloud + * to create a new external IP address in. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. The initial description of a new external IP address. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.ExternalAddress external_address = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $external_address = null; + /** + * Required. The user-provided identifier of the `ExternalAddress` to be + * created. This identifier must be unique among `ExternalAddress` resources + * within the parent and becomes the final token in the name URI. The + * identifier must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * Generated from protobuf field string external_address_id = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $external_address_id = ''; + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 the 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 resource name of the private cloud + * to create a new external IP address in. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * Please see {@see VmwareEngineClient::privateCloudName()} for help formatting this field. + * @param \Google\Cloud\VmwareEngine\V1\ExternalAddress $externalAddress Required. The initial description of a new external IP address. + * @param string $externalAddressId Required. The user-provided identifier of the `ExternalAddress` to be + * created. This identifier must be unique among `ExternalAddress` resources + * within the parent and becomes the final token in the name URI. The + * identifier must meet the following requirements: + * + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * @return \Google\Cloud\VmwareEngine\V1\CreateExternalAddressRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\VmwareEngine\V1\ExternalAddress $externalAddress, string $externalAddressId): self + { + return (new self()) + ->setParent($parent) + ->setExternalAddress($externalAddress) + ->setExternalAddressId($externalAddressId); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. The resource name of the private cloud + * to create a new external IP address in. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * @type \Google\Cloud\VmwareEngine\V1\ExternalAddress $external_address + * Required. The initial description of a new external IP address. + * @type string $external_address_id + * Required. The user-provided identifier of the `ExternalAddress` to be + * created. This identifier must be unique among `ExternalAddress` resources + * within the parent and becomes the final token in the name URI. The + * identifier must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * @type string $request_id + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 the 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\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the private cloud + * to create a new external IP address in. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * 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 private cloud + * to create a new external IP address in. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * 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 initial description of a new external IP address. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.ExternalAddress external_address = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\VmwareEngine\V1\ExternalAddress|null + */ + public function getExternalAddress() + { + return $this->external_address; + } + + public function hasExternalAddress() + { + return isset($this->external_address); + } + + public function clearExternalAddress() + { + unset($this->external_address); + } + + /** + * Required. The initial description of a new external IP address. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.ExternalAddress external_address = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\VmwareEngine\V1\ExternalAddress $var + * @return $this + */ + public function setExternalAddress($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\ExternalAddress::class); + $this->external_address = $var; + + return $this; + } + + /** + * Required. The user-provided identifier of the `ExternalAddress` to be + * created. This identifier must be unique among `ExternalAddress` resources + * within the parent and becomes the final token in the name URI. The + * identifier must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * Generated from protobuf field string external_address_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getExternalAddressId() + { + return $this->external_address_id; + } + + /** + * Required. The user-provided identifier of the `ExternalAddress` to be + * created. This identifier must be unique among `ExternalAddress` resources + * within the parent and becomes the final token in the name URI. The + * identifier must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * Generated from protobuf field string external_address_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setExternalAddressId($var) + { + GPBUtil::checkString($var, True); + $this->external_address_id = $var; + + return $this; + } + + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 the 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. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 the 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateHcxActivationKeyRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateHcxActivationKeyRequest.php new file mode 100644 index 000000000000..c5fb6bc649ca --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateHcxActivationKeyRequest.php @@ -0,0 +1,313 @@ +google.cloud.vmwareengine.v1.CreateHcxActivationKeyRequest + */ +class CreateHcxActivationKeyRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the private cloud to create the key for. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/privateClouds/my-cloud` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. The initial description of a new HCX activation key. When + * creating a new key, this field must be an empty object. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.HcxActivationKey hcx_activation_key = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $hcx_activation_key = null; + /** + * Required. The user-provided identifier of the `HcxActivationKey` to be + * created. This identifier must be unique among `HcxActivationKey` resources + * within the parent and becomes the final token in the name URI. + * The identifier must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * Generated from protobuf field string hcx_activation_key_id = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $hcx_activation_key_id = ''; + /** + * A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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; + */ + protected $request_id = ''; + + /** + * @param string $parent Required. The resource name of the private cloud to create the key for. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/privateClouds/my-cloud` + * Please see {@see VmwareEngineClient::privateCloudName()} for help formatting this field. + * @param \Google\Cloud\VmwareEngine\V1\HcxActivationKey $hcxActivationKey Required. The initial description of a new HCX activation key. When + * creating a new key, this field must be an empty object. + * @param string $hcxActivationKeyId Required. The user-provided identifier of the `HcxActivationKey` to be + * created. This identifier must be unique among `HcxActivationKey` resources + * within the parent and becomes the final token in the name URI. + * The identifier must meet the following requirements: + * + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * @return \Google\Cloud\VmwareEngine\V1\CreateHcxActivationKeyRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\VmwareEngine\V1\HcxActivationKey $hcxActivationKey, string $hcxActivationKeyId): self + { + return (new self()) + ->setParent($parent) + ->setHcxActivationKey($hcxActivationKey) + ->setHcxActivationKeyId($hcxActivationKeyId); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. The resource name of the private cloud to create the key for. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/privateClouds/my-cloud` + * @type \Google\Cloud\VmwareEngine\V1\HcxActivationKey $hcx_activation_key + * Required. The initial description of a new HCX activation key. When + * creating a new key, this field must be an empty object. + * @type string $hcx_activation_key_id + * Required. The user-provided identifier of the `HcxActivationKey` to be + * created. This identifier must be unique among `HcxActivationKey` resources + * within the parent and becomes the final token in the name URI. + * The identifier must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * @type string $request_id + * A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the private cloud to create the key for. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/privateClouds/my-cloud` + * + * 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 private cloud to create the key for. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/privateClouds/my-cloud` + * + * 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 initial description of a new HCX activation key. When + * creating a new key, this field must be an empty object. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.HcxActivationKey hcx_activation_key = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\VmwareEngine\V1\HcxActivationKey|null + */ + public function getHcxActivationKey() + { + return $this->hcx_activation_key; + } + + public function hasHcxActivationKey() + { + return isset($this->hcx_activation_key); + } + + public function clearHcxActivationKey() + { + unset($this->hcx_activation_key); + } + + /** + * Required. The initial description of a new HCX activation key. When + * creating a new key, this field must be an empty object. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.HcxActivationKey hcx_activation_key = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\VmwareEngine\V1\HcxActivationKey $var + * @return $this + */ + public function setHcxActivationKey($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\HcxActivationKey::class); + $this->hcx_activation_key = $var; + + return $this; + } + + /** + * Required. The user-provided identifier of the `HcxActivationKey` to be + * created. This identifier must be unique among `HcxActivationKey` resources + * within the parent and becomes the final token in the name URI. + * The identifier must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * Generated from protobuf field string hcx_activation_key_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getHcxActivationKeyId() + { + return $this->hcx_activation_key_id; + } + + /** + * Required. The user-provided identifier of the `HcxActivationKey` to be + * created. This identifier must be unique among `HcxActivationKey` resources + * within the parent and becomes the final token in the name URI. + * The identifier must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * Generated from protobuf field string hcx_activation_key_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setHcxActivationKeyId($var) + { + GPBUtil::checkString($var, True); + $this->hcx_activation_key_id = $var; + + return $this; + } + + /** + * A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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; + * @return string + */ + public function getRequestId() + { + return $this->request_id; + } + + /** + * A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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; + * @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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateLoggingServerRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateLoggingServerRequest.php new file mode 100644 index 000000000000..23fa5f500e60 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateLoggingServerRequest.php @@ -0,0 +1,313 @@ +google.cloud.vmwareengine.v1.CreateLoggingServerRequest + */ +class CreateLoggingServerRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the private cloud + * to create a new Logging Server in. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. The initial description of a new logging server. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.LoggingServer logging_server = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $logging_server = null; + /** + * Required. The user-provided identifier of the `LoggingServer` to be + * created. This identifier must be unique among `LoggingServer` resources + * within the parent and becomes the final token in the name URI. + * The identifier must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * Generated from protobuf field string logging_server_id = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $logging_server_id = ''; + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 resource name of the private cloud + * to create a new Logging Server in. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * Please see {@see VmwareEngineClient::privateCloudName()} for help formatting this field. + * @param \Google\Cloud\VmwareEngine\V1\LoggingServer $loggingServer Required. The initial description of a new logging server. + * @param string $loggingServerId Required. The user-provided identifier of the `LoggingServer` to be + * created. This identifier must be unique among `LoggingServer` resources + * within the parent and becomes the final token in the name URI. + * The identifier must meet the following requirements: + * + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * @return \Google\Cloud\VmwareEngine\V1\CreateLoggingServerRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\VmwareEngine\V1\LoggingServer $loggingServer, string $loggingServerId): self + { + return (new self()) + ->setParent($parent) + ->setLoggingServer($loggingServer) + ->setLoggingServerId($loggingServerId); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. The resource name of the private cloud + * to create a new Logging Server in. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * @type \Google\Cloud\VmwareEngine\V1\LoggingServer $logging_server + * Required. The initial description of a new logging server. + * @type string $logging_server_id + * Required. The user-provided identifier of the `LoggingServer` to be + * created. This identifier must be unique among `LoggingServer` resources + * within the parent and becomes the final token in the name URI. + * The identifier must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * @type string $request_id + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the private cloud + * to create a new Logging Server in. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * 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 private cloud + * to create a new Logging Server in. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * 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 initial description of a new logging server. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.LoggingServer logging_server = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\VmwareEngine\V1\LoggingServer|null + */ + public function getLoggingServer() + { + return $this->logging_server; + } + + public function hasLoggingServer() + { + return isset($this->logging_server); + } + + public function clearLoggingServer() + { + unset($this->logging_server); + } + + /** + * Required. The initial description of a new logging server. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.LoggingServer logging_server = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\VmwareEngine\V1\LoggingServer $var + * @return $this + */ + public function setLoggingServer($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\LoggingServer::class); + $this->logging_server = $var; + + return $this; + } + + /** + * Required. The user-provided identifier of the `LoggingServer` to be + * created. This identifier must be unique among `LoggingServer` resources + * within the parent and becomes the final token in the name URI. + * The identifier must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * Generated from protobuf field string logging_server_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getLoggingServerId() + { + return $this->logging_server_id; + } + + /** + * Required. The user-provided identifier of the `LoggingServer` to be + * created. This identifier must be unique among `LoggingServer` resources + * within the parent and becomes the final token in the name URI. + * The identifier must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * Generated from protobuf field string logging_server_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setLoggingServerId($var) + { + GPBUtil::checkString($var, True); + $this->logging_server_id = $var; + + return $this; + } + + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateManagementDnsZoneBindingRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateManagementDnsZoneBindingRequest.php new file mode 100644 index 000000000000..28fd5cd0a7b2 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateManagementDnsZoneBindingRequest.php @@ -0,0 +1,317 @@ +google.cloud.vmwareengine.v1.CreateManagementDnsZoneBindingRequest + */ +class CreateManagementDnsZoneBindingRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the private cloud + * to create a new management DNS zone binding for. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. The initial values for a new management DNS zone binding. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.ManagementDnsZoneBinding management_dns_zone_binding = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $management_dns_zone_binding = null; + /** + * Required. The user-provided identifier of the `ManagementDnsZoneBinding` + * resource to be created. This identifier must be unique among + * `ManagementDnsZoneBinding` resources within the parent and becomes the + * final token in the name URI. The identifier must meet the following + * requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * Generated from protobuf field string management_dns_zone_binding_id = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $management_dns_zone_binding_id = ''; + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 the 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 resource name of the private cloud + * to create a new management DNS zone binding for. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * Please see {@see VmwareEngineClient::privateCloudName()} for help formatting this field. + * @param \Google\Cloud\VmwareEngine\V1\ManagementDnsZoneBinding $managementDnsZoneBinding Required. The initial values for a new management DNS zone binding. + * @param string $managementDnsZoneBindingId Required. The user-provided identifier of the `ManagementDnsZoneBinding` + * resource to be created. This identifier must be unique among + * `ManagementDnsZoneBinding` resources within the parent and becomes the + * final token in the name URI. The identifier must meet the following + * requirements: + * + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * @return \Google\Cloud\VmwareEngine\V1\CreateManagementDnsZoneBindingRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\VmwareEngine\V1\ManagementDnsZoneBinding $managementDnsZoneBinding, string $managementDnsZoneBindingId): self + { + return (new self()) + ->setParent($parent) + ->setManagementDnsZoneBinding($managementDnsZoneBinding) + ->setManagementDnsZoneBindingId($managementDnsZoneBindingId); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. The resource name of the private cloud + * to create a new management DNS zone binding for. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * @type \Google\Cloud\VmwareEngine\V1\ManagementDnsZoneBinding $management_dns_zone_binding + * Required. The initial values for a new management DNS zone binding. + * @type string $management_dns_zone_binding_id + * Required. The user-provided identifier of the `ManagementDnsZoneBinding` + * resource to be created. This identifier must be unique among + * `ManagementDnsZoneBinding` resources within the parent and becomes the + * final token in the name URI. The identifier must meet the following + * requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * @type string $request_id + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 the 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\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the private cloud + * to create a new management DNS zone binding for. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * 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 private cloud + * to create a new management DNS zone binding for. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * 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 initial values for a new management DNS zone binding. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.ManagementDnsZoneBinding management_dns_zone_binding = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\VmwareEngine\V1\ManagementDnsZoneBinding|null + */ + public function getManagementDnsZoneBinding() + { + return $this->management_dns_zone_binding; + } + + public function hasManagementDnsZoneBinding() + { + return isset($this->management_dns_zone_binding); + } + + public function clearManagementDnsZoneBinding() + { + unset($this->management_dns_zone_binding); + } + + /** + * Required. The initial values for a new management DNS zone binding. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.ManagementDnsZoneBinding management_dns_zone_binding = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\VmwareEngine\V1\ManagementDnsZoneBinding $var + * @return $this + */ + public function setManagementDnsZoneBinding($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\ManagementDnsZoneBinding::class); + $this->management_dns_zone_binding = $var; + + return $this; + } + + /** + * Required. The user-provided identifier of the `ManagementDnsZoneBinding` + * resource to be created. This identifier must be unique among + * `ManagementDnsZoneBinding` resources within the parent and becomes the + * final token in the name URI. The identifier must meet the following + * requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * Generated from protobuf field string management_dns_zone_binding_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getManagementDnsZoneBindingId() + { + return $this->management_dns_zone_binding_id; + } + + /** + * Required. The user-provided identifier of the `ManagementDnsZoneBinding` + * resource to be created. This identifier must be unique among + * `ManagementDnsZoneBinding` resources within the parent and becomes the + * final token in the name URI. The identifier must meet the following + * requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * Generated from protobuf field string management_dns_zone_binding_id = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setManagementDnsZoneBindingId($var) + { + GPBUtil::checkString($var, True); + $this->management_dns_zone_binding_id = $var; + + return $this; + } + + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 the 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. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 the 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateNetworkPeeringRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateNetworkPeeringRequest.php new file mode 100644 index 000000000000..bb3d32182c96 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateNetworkPeeringRequest.php @@ -0,0 +1,308 @@ +google.cloud.vmwareengine.v1.CreateNetworkPeeringRequest + */ +class CreateNetworkPeeringRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the location to create the new network + * peering in. This value is always `global`, because `NetworkPeering` is a + * global resource. Resource names are schemeless URIs that follow the + * conventions in https://cloud.google.com/apis/design/resource_names. For + * example: `projects/my-project/locations/global` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. The user-provided identifier of the new `NetworkPeering`. + * This identifier must be unique among `NetworkPeering` resources within the + * parent and becomes the final token in the name URI. + * The identifier must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * Generated from protobuf field string network_peering_id = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $network_peering_id = ''; + /** + * Required. The initial description of the new network peering. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPeering network_peering = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $network_peering = null; + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 resource name of the location to create the new network + * peering in. This value is always `global`, because `NetworkPeering` is a + * global resource. Resource names are schemeless URIs that follow the + * conventions in https://cloud.google.com/apis/design/resource_names. For + * example: `projects/my-project/locations/global` + * Please see {@see VmwareEngineClient::locationName()} for help formatting this field. + * @param \Google\Cloud\VmwareEngine\V1\NetworkPeering $networkPeering Required. The initial description of the new network peering. + * @param string $networkPeeringId Required. The user-provided identifier of the new `NetworkPeering`. + * This identifier must be unique among `NetworkPeering` resources within the + * parent and becomes the final token in the name URI. + * The identifier must meet the following requirements: + * + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * @return \Google\Cloud\VmwareEngine\V1\CreateNetworkPeeringRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\VmwareEngine\V1\NetworkPeering $networkPeering, string $networkPeeringId): self + { + return (new self()) + ->setParent($parent) + ->setNetworkPeering($networkPeering) + ->setNetworkPeeringId($networkPeeringId); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. The resource name of the location to create the new network + * peering in. This value is always `global`, because `NetworkPeering` is a + * global resource. Resource names are schemeless URIs that follow the + * conventions in https://cloud.google.com/apis/design/resource_names. For + * example: `projects/my-project/locations/global` + * @type string $network_peering_id + * Required. The user-provided identifier of the new `NetworkPeering`. + * This identifier must be unique among `NetworkPeering` resources within the + * parent and becomes the final token in the name URI. + * The identifier must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * @type \Google\Cloud\VmwareEngine\V1\NetworkPeering $network_peering + * Required. The initial description of the new network peering. + * @type string $request_id + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the location to create the new network + * peering in. This value is always `global`, because `NetworkPeering` is a + * global resource. Resource names are schemeless URIs that follow the + * conventions in https://cloud.google.com/apis/design/resource_names. For + * example: `projects/my-project/locations/global` + * + * 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 to create the new network + * peering in. This value is always `global`, because `NetworkPeering` is a + * global resource. Resource names are schemeless URIs that follow the + * conventions in https://cloud.google.com/apis/design/resource_names. For + * example: `projects/my-project/locations/global` + * + * 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 user-provided identifier of the new `NetworkPeering`. + * This identifier must be unique among `NetworkPeering` resources within the + * parent and becomes the final token in the name URI. + * The identifier must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * Generated from protobuf field string network_peering_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getNetworkPeeringId() + { + return $this->network_peering_id; + } + + /** + * Required. The user-provided identifier of the new `NetworkPeering`. + * This identifier must be unique among `NetworkPeering` resources within the + * parent and becomes the final token in the name URI. + * The identifier must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * Generated from protobuf field string network_peering_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setNetworkPeeringId($var) + { + GPBUtil::checkString($var, True); + $this->network_peering_id = $var; + + return $this; + } + + /** + * Required. The initial description of the new network peering. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPeering network_peering = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\VmwareEngine\V1\NetworkPeering|null + */ + public function getNetworkPeering() + { + return $this->network_peering; + } + + public function hasNetworkPeering() + { + return isset($this->network_peering); + } + + public function clearNetworkPeering() + { + unset($this->network_peering); + } + + /** + * Required. The initial description of the new network peering. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPeering network_peering = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\VmwareEngine\V1\NetworkPeering $var + * @return $this + */ + public function setNetworkPeering($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\NetworkPeering::class); + $this->network_peering = $var; + + return $this; + } + + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateNetworkPolicyRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateNetworkPolicyRequest.php new file mode 100644 index 000000000000..e347120fa827 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateNetworkPolicyRequest.php @@ -0,0 +1,318 @@ +google.cloud.vmwareengine.v1.CreateNetworkPolicyRequest + */ +class CreateNetworkPolicyRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the location (region) + * to create the new network policy in. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. The user-provided identifier of the network policy to be created. + * This identifier must be unique within parent + * `projects/{my-project}/locations/{us-central1}/networkPolicies` and becomes + * the final token in the name URI. + * The identifier must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * Generated from protobuf field string network_policy_id = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $network_policy_id = ''; + /** + * Required. The network policy configuration to use in the request. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPolicy network_policy = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $network_policy = null; + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 resource name of the location (region) + * to create the new network policy in. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1` + * Please see {@see VmwareEngineClient::locationName()} for help formatting this field. + * @param \Google\Cloud\VmwareEngine\V1\NetworkPolicy $networkPolicy Required. The network policy configuration to use in the request. + * @param string $networkPolicyId Required. The user-provided identifier of the network policy to be created. + * This identifier must be unique within parent + * `projects/{my-project}/locations/{us-central1}/networkPolicies` and becomes + * the final token in the name URI. + * The identifier must meet the following requirements: + * + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * @return \Google\Cloud\VmwareEngine\V1\CreateNetworkPolicyRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\VmwareEngine\V1\NetworkPolicy $networkPolicy, string $networkPolicyId): self + { + return (new self()) + ->setParent($parent) + ->setNetworkPolicy($networkPolicy) + ->setNetworkPolicyId($networkPolicyId); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. The resource name of the location (region) + * to create the new network policy in. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1` + * @type string $network_policy_id + * Required. The user-provided identifier of the network policy to be created. + * This identifier must be unique within parent + * `projects/{my-project}/locations/{us-central1}/networkPolicies` and becomes + * the final token in the name URI. + * The identifier must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * @type \Google\Cloud\VmwareEngine\V1\NetworkPolicy $network_policy + * Required. The network policy configuration to use in the request. + * @type string $request_id + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the location (region) + * to create the new network policy in. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1` + * + * 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 (region) + * to create the new network policy in. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1` + * + * 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 user-provided identifier of the network policy to be created. + * This identifier must be unique within parent + * `projects/{my-project}/locations/{us-central1}/networkPolicies` and becomes + * the final token in the name URI. + * The identifier must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * Generated from protobuf field string network_policy_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getNetworkPolicyId() + { + return $this->network_policy_id; + } + + /** + * Required. The user-provided identifier of the network policy to be created. + * This identifier must be unique within parent + * `projects/{my-project}/locations/{us-central1}/networkPolicies` and becomes + * the final token in the name URI. + * The identifier must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * Generated from protobuf field string network_policy_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setNetworkPolicyId($var) + { + GPBUtil::checkString($var, True); + $this->network_policy_id = $var; + + return $this; + } + + /** + * Required. The network policy configuration to use in the request. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPolicy network_policy = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\VmwareEngine\V1\NetworkPolicy|null + */ + public function getNetworkPolicy() + { + return $this->network_policy; + } + + public function hasNetworkPolicy() + { + return isset($this->network_policy); + } + + public function clearNetworkPolicy() + { + unset($this->network_policy); + } + + /** + * Required. The network policy configuration to use in the request. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPolicy network_policy = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\VmwareEngine\V1\NetworkPolicy $var + * @return $this + */ + public function setNetworkPolicy($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\NetworkPolicy::class); + $this->network_policy = $var; + + return $this; + } + + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreatePrivateCloudRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreatePrivateCloudRequest.php new file mode 100644 index 000000000000..b83a8b03ac8d --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreatePrivateCloudRequest.php @@ -0,0 +1,306 @@ +google.cloud.vmwareengine.v1.CreatePrivateCloudRequest + */ +class CreatePrivateCloudRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the location to create the new + * private cloud in. Resource names are schemeless URIs that follow the + * conventions in https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. The user-provided identifier of the private cloud to be created. + * This identifier must be unique among each `PrivateCloud` within the parent + * and becomes the final token in the name URI. + * The identifier must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * Generated from protobuf field string private_cloud_id = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $private_cloud_id = ''; + /** + * Required. The initial description of the new private cloud. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateCloud private_cloud = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $private_cloud = null; + /** + * Optional. 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. True if you want the request to be validated and not executed; + * false otherwise. + * + * Generated from protobuf field bool validate_only = 5 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $validate_only = false; + + /** + * @param string $parent Required. The resource name of the location to create the new + * private cloud in. Resource names are schemeless URIs that follow the + * conventions in https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a` + * Please see {@see VmwareEngineClient::locationName()} for help formatting this field. + * @param \Google\Cloud\VmwareEngine\V1\PrivateCloud $privateCloud Required. The initial description of the new private cloud. + * @param string $privateCloudId Required. The user-provided identifier of the private cloud to be created. + * This identifier must be unique among each `PrivateCloud` within the parent + * and becomes the final token in the name URI. + * The identifier must meet the following requirements: + * + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * @return \Google\Cloud\VmwareEngine\V1\CreatePrivateCloudRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\VmwareEngine\V1\PrivateCloud $privateCloud, string $privateCloudId): self + { + return (new self()) + ->setParent($parent) + ->setPrivateCloud($privateCloud) + ->setPrivateCloudId($privateCloudId); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. The resource name of the location to create the new + * private cloud in. Resource names are schemeless URIs that follow the + * conventions in https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a` + * @type string $private_cloud_id + * Required. The user-provided identifier of the private cloud to be created. + * This identifier must be unique among each `PrivateCloud` within the parent + * and becomes the final token in the name URI. + * The identifier must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * @type \Google\Cloud\VmwareEngine\V1\PrivateCloud $private_cloud + * Required. The initial description of the new private cloud. + * @type string $request_id + * Optional. 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. True if you want the request to be validated and not executed; + * false otherwise. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the location to create the new + * private cloud in. Resource names are schemeless URIs that follow the + * conventions in https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a` + * + * 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 to create the new + * private cloud in. Resource names are schemeless URIs that follow the + * conventions in https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a` + * + * 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 user-provided identifier of the private cloud to be created. + * This identifier must be unique among each `PrivateCloud` within the parent + * and becomes the final token in the name URI. + * The identifier must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * Generated from protobuf field string private_cloud_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getPrivateCloudId() + { + return $this->private_cloud_id; + } + + /** + * Required. The user-provided identifier of the private cloud to be created. + * This identifier must be unique among each `PrivateCloud` within the parent + * and becomes the final token in the name URI. + * The identifier must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * Generated from protobuf field string private_cloud_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setPrivateCloudId($var) + { + GPBUtil::checkString($var, True); + $this->private_cloud_id = $var; + + return $this; + } + + /** + * Required. The initial description of the new private cloud. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateCloud private_cloud = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\VmwareEngine\V1\PrivateCloud|null + */ + public function getPrivateCloud() + { + return $this->private_cloud; + } + + public function hasPrivateCloud() + { + return isset($this->private_cloud); + } + + public function clearPrivateCloud() + { + unset($this->private_cloud); + } + + /** + * Required. The initial description of the new private cloud. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateCloud private_cloud = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\VmwareEngine\V1\PrivateCloud $var + * @return $this + */ + public function setPrivateCloud($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\PrivateCloud::class); + $this->private_cloud = $var; + + return $this; + } + + /** + * Optional. 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. 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. True if you want the request to be validated and not executed; + * false otherwise. + * + * Generated from protobuf field bool validate_only = 5 [(.google.api.field_behavior) = OPTIONAL]; + * @return bool + */ + public function getValidateOnly() + { + return $this->validate_only; + } + + /** + * Optional. True if you want the request to be validated and not executed; + * false otherwise. + * + * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreatePrivateConnectionRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreatePrivateConnectionRequest.php new file mode 100644 index 000000000000..6210d15244f2 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreatePrivateConnectionRequest.php @@ -0,0 +1,308 @@ +google.cloud.vmwareengine.v1.CreatePrivateConnectionRequest + */ +class CreatePrivateConnectionRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the location to create the new private + * connection in. Private connection is a regional resource. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. For example: + * `projects/my-project/locations/us-central1` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. The user-provided identifier of the new private connection. + * This identifier must be unique among private connection resources + * within the parent and becomes the final token in the name URI. The + * identifier must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * Generated from protobuf field string private_connection_id = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $private_connection_id = ''; + /** + * Required. The initial description of the new private connection. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateConnection private_connection = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $private_connection = null; + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 resource name of the location to create the new private + * connection in. Private connection is a regional resource. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. For example: + * `projects/my-project/locations/us-central1` + * Please see {@see VmwareEngineClient::locationName()} for help formatting this field. + * @param \Google\Cloud\VmwareEngine\V1\PrivateConnection $privateConnection Required. The initial description of the new private connection. + * @param string $privateConnectionId Required. The user-provided identifier of the new private connection. + * This identifier must be unique among private connection resources + * within the parent and becomes the final token in the name URI. The + * identifier must meet the following requirements: + * + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * @return \Google\Cloud\VmwareEngine\V1\CreatePrivateConnectionRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\VmwareEngine\V1\PrivateConnection $privateConnection, string $privateConnectionId): self + { + return (new self()) + ->setParent($parent) + ->setPrivateConnection($privateConnection) + ->setPrivateConnectionId($privateConnectionId); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. The resource name of the location to create the new private + * connection in. Private connection is a regional resource. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. For example: + * `projects/my-project/locations/us-central1` + * @type string $private_connection_id + * Required. The user-provided identifier of the new private connection. + * This identifier must be unique among private connection resources + * within the parent and becomes the final token in the name URI. The + * identifier must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * @type \Google\Cloud\VmwareEngine\V1\PrivateConnection $private_connection + * Required. The initial description of the new private connection. + * @type string $request_id + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the location to create the new private + * connection in. Private connection is a regional resource. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. For example: + * `projects/my-project/locations/us-central1` + * + * 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 to create the new private + * connection in. Private connection is a regional resource. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. For example: + * `projects/my-project/locations/us-central1` + * + * 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 user-provided identifier of the new private connection. + * This identifier must be unique among private connection resources + * within the parent and becomes the final token in the name URI. The + * identifier must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * Generated from protobuf field string private_connection_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getPrivateConnectionId() + { + return $this->private_connection_id; + } + + /** + * Required. The user-provided identifier of the new private connection. + * This identifier must be unique among private connection resources + * within the parent and becomes the final token in the name URI. The + * identifier must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * Generated from protobuf field string private_connection_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setPrivateConnectionId($var) + { + GPBUtil::checkString($var, True); + $this->private_connection_id = $var; + + return $this; + } + + /** + * Required. The initial description of the new private connection. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateConnection private_connection = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\VmwareEngine\V1\PrivateConnection|null + */ + public function getPrivateConnection() + { + return $this->private_connection; + } + + public function hasPrivateConnection() + { + return isset($this->private_connection); + } + + public function clearPrivateConnection() + { + unset($this->private_connection); + } + + /** + * Required. The initial description of the new private connection. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateConnection private_connection = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\VmwareEngine\V1\PrivateConnection $var + * @return $this + */ + public function setPrivateConnection($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\PrivateConnection::class); + $this->private_connection = $var; + + return $this; + } + + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateVmwareEngineNetworkRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateVmwareEngineNetworkRequest.php new file mode 100644 index 000000000000..525b849b4e6b --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateVmwareEngineNetworkRequest.php @@ -0,0 +1,333 @@ +google.cloud.vmwareengine.v1.CreateVmwareEngineNetworkRequest + */ +class CreateVmwareEngineNetworkRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the location to create the new VMware Engine + * network in. A VMware Engine network of type + * `LEGACY` is a regional resource, and a VMware + * Engine network of type `STANDARD` is a global resource. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. For example: + * `projects/my-project/locations/global` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * Required. The user-provided identifier of the new VMware Engine network. + * This identifier must be unique among VMware Engine network resources + * within the parent and becomes the final token in the name URI. The + * identifier must meet the following requirements: + * * For networks of type LEGACY, adheres to the format: + * `{region-id}-default`. Replace `{region-id}` with the region where you want + * to create the VMware Engine network. For example, "us-central1-default". + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * Generated from protobuf field string vmware_engine_network_id = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $vmware_engine_network_id = ''; + /** + * Required. The initial description of the new VMware Engine network. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.VmwareEngineNetwork vmware_engine_network = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $vmware_engine_network = null; + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 resource name of the location to create the new VMware Engine + * network in. A VMware Engine network of type + * `LEGACY` is a regional resource, and a VMware + * Engine network of type `STANDARD` is a global resource. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. For example: + * `projects/my-project/locations/global` + * Please see {@see VmwareEngineClient::locationName()} for help formatting this field. + * @param \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork $vmwareEngineNetwork Required. The initial description of the new VMware Engine network. + * @param string $vmwareEngineNetworkId Required. The user-provided identifier of the new VMware Engine network. + * This identifier must be unique among VMware Engine network resources + * within the parent and becomes the final token in the name URI. The + * identifier must meet the following requirements: + * + * * For networks of type LEGACY, adheres to the format: + * `{region-id}-default`. Replace `{region-id}` with the region where you want + * to create the VMware Engine network. For example, "us-central1-default". + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * @return \Google\Cloud\VmwareEngine\V1\CreateVmwareEngineNetworkRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork $vmwareEngineNetwork, string $vmwareEngineNetworkId): self + { + return (new self()) + ->setParent($parent) + ->setVmwareEngineNetwork($vmwareEngineNetwork) + ->setVmwareEngineNetworkId($vmwareEngineNetworkId); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. The resource name of the location to create the new VMware Engine + * network in. A VMware Engine network of type + * `LEGACY` is a regional resource, and a VMware + * Engine network of type `STANDARD` is a global resource. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. For example: + * `projects/my-project/locations/global` + * @type string $vmware_engine_network_id + * Required. The user-provided identifier of the new VMware Engine network. + * This identifier must be unique among VMware Engine network resources + * within the parent and becomes the final token in the name URI. The + * identifier must meet the following requirements: + * * For networks of type LEGACY, adheres to the format: + * `{region-id}-default`. Replace `{region-id}` with the region where you want + * to create the VMware Engine network. For example, "us-central1-default". + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * @type \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork $vmware_engine_network + * Required. The initial description of the new VMware Engine network. + * @type string $request_id + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the location to create the new VMware Engine + * network in. A VMware Engine network of type + * `LEGACY` is a regional resource, and a VMware + * Engine network of type `STANDARD` is a global resource. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. For example: + * `projects/my-project/locations/global` + * + * 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 to create the new VMware Engine + * network in. A VMware Engine network of type + * `LEGACY` is a regional resource, and a VMware + * Engine network of type `STANDARD` is a global resource. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. For example: + * `projects/my-project/locations/global` + * + * 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 user-provided identifier of the new VMware Engine network. + * This identifier must be unique among VMware Engine network resources + * within the parent and becomes the final token in the name URI. The + * identifier must meet the following requirements: + * * For networks of type LEGACY, adheres to the format: + * `{region-id}-default`. Replace `{region-id}` with the region where you want + * to create the VMware Engine network. For example, "us-central1-default". + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * Generated from protobuf field string vmware_engine_network_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getVmwareEngineNetworkId() + { + return $this->vmware_engine_network_id; + } + + /** + * Required. The user-provided identifier of the new VMware Engine network. + * This identifier must be unique among VMware Engine network resources + * within the parent and becomes the final token in the name URI. The + * identifier must meet the following requirements: + * * For networks of type LEGACY, adheres to the format: + * `{region-id}-default`. Replace `{region-id}` with the region where you want + * to create the VMware Engine network. For example, "us-central1-default". + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) + * (section 3.5) + * + * Generated from protobuf field string vmware_engine_network_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setVmwareEngineNetworkId($var) + { + GPBUtil::checkString($var, True); + $this->vmware_engine_network_id = $var; + + return $this; + } + + /** + * Required. The initial description of the new VMware Engine network. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.VmwareEngineNetwork vmware_engine_network = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork|null + */ + public function getVmwareEngineNetwork() + { + return $this->vmware_engine_network; + } + + public function hasVmwareEngineNetwork() + { + return isset($this->vmware_engine_network); + } + + public function clearVmwareEngineNetwork() + { + unset($this->vmware_engine_network); + } + + /** + * Required. The initial description of the new VMware Engine network. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.VmwareEngineNetwork vmware_engine_network = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork $var + * @return $this + */ + public function setVmwareEngineNetwork($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork::class); + $this->vmware_engine_network = $var; + + return $this; + } + + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Credentials.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Credentials.php new file mode 100644 index 000000000000..330a9a4558f3 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Credentials.php @@ -0,0 +1,101 @@ +google.cloud.vmwareengine.v1.Credentials + */ +class Credentials extends \Google\Protobuf\Internal\Message +{ + /** + * Initial username. + * + * Generated from protobuf field string username = 1; + */ + protected $username = ''; + /** + * Initial password. + * + * Generated from protobuf field string password = 2; + */ + protected $password = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $username + * Initial username. + * @type string $password + * Initial password. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); + parent::__construct($data); + } + + /** + * Initial username. + * + * Generated from protobuf field string username = 1; + * @return string + */ + public function getUsername() + { + return $this->username; + } + + /** + * Initial username. + * + * Generated from protobuf field string username = 1; + * @param string $var + * @return $this + */ + public function setUsername($var) + { + GPBUtil::checkString($var, True); + $this->username = $var; + + return $this; + } + + /** + * Initial password. + * + * Generated from protobuf field string password = 2; + * @return string + */ + public function getPassword() + { + return $this->password; + } + + /** + * Initial password. + * + * Generated from protobuf field string password = 2; + * @param string $var + * @return $this + */ + public function setPassword($var) + { + GPBUtil::checkString($var, True); + $this->password = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteClusterRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteClusterRequest.php new file mode 100644 index 000000000000..20cec6ac10fd --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteClusterRequest.php @@ -0,0 +1,140 @@ +google.cloud.vmwareengine.v1.DeleteClusterRequest + */ +class DeleteClusterRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the cluster to delete. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * Optional. 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 = ''; + + /** + * @param string $name Required. The resource name of the cluster to delete. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster` + * Please see {@see VmwareEngineClient::clusterName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\DeleteClusterRequest + * + * @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 cluster to delete. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster` + * @type string $request_id + * Optional. 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\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the cluster to delete. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster` + * + * 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 cluster to delete. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster` + * + * 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 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. 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; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteExternalAccessRuleRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteExternalAccessRuleRequest.php new file mode 100644 index 000000000000..454591e21d3f --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteExternalAccessRuleRequest.php @@ -0,0 +1,180 @@ +google.cloud.vmwareengine.v1.DeleteExternalAccessRuleRequest + */ +class DeleteExternalAccessRuleRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the external access firewall rule to delete. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/networkPolicies/my-policy/externalAccessRules/my-rule` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 the 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 = ''; + + /** + * @param string $name Required. The resource name of the external access firewall rule to delete. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/networkPolicies/my-policy/externalAccessRules/my-rule` + * Please see {@see VmwareEngineClient::externalAccessRuleName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\DeleteExternalAccessRuleRequest + * + * @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 external access firewall rule to delete. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/networkPolicies/my-policy/externalAccessRules/my-rule` + * @type string $request_id + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 the 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\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the external access firewall rule to delete. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/networkPolicies/my-policy/externalAccessRules/my-rule` + * + * 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 external access firewall rule to delete. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/networkPolicies/my-policy/externalAccessRules/my-rule` + * + * 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. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 the 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. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 the 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; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteExternalAddressRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteExternalAddressRequest.php new file mode 100644 index 000000000000..1b2035b496db --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteExternalAddressRequest.php @@ -0,0 +1,180 @@ +google.cloud.vmwareengine.v1.DeleteExternalAddressRequest + */ +class DeleteExternalAddressRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the external IP address to delete. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/externalAddresses/my-ip` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 the 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 = ''; + + /** + * @param string $name Required. The resource name of the external IP address to delete. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/externalAddresses/my-ip` + * Please see {@see VmwareEngineClient::externalAddressName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\DeleteExternalAddressRequest + * + * @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 external IP address to delete. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/externalAddresses/my-ip` + * @type string $request_id + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 the 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\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the external IP address to delete. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/externalAddresses/my-ip` + * + * 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 external IP address to delete. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/externalAddresses/my-ip` + * + * 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. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 the 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. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 the 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; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteLoggingServerRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteLoggingServerRequest.php new file mode 100644 index 000000000000..e383258aeaf8 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteLoggingServerRequest.php @@ -0,0 +1,180 @@ +google.cloud.vmwareengine.v1.DeleteLoggingServerRequest + */ +class DeleteLoggingServerRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the logging server to delete. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/loggingServers/my-logging-server` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $request_id = ''; + + /** + * @param string $name Required. The resource name of the logging server to delete. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/loggingServers/my-logging-server` + * Please see {@see VmwareEngineClient::loggingServerName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\DeleteLoggingServerRequest + * + * @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 logging server to delete. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/loggingServers/my-logging-server` + * @type string $request_id + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the logging server to delete. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/loggingServers/my-logging-server` + * + * 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 logging server to delete. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/loggingServers/my-logging-server` + * + * 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. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getRequestId() + { + return $this->request_id; + } + + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 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; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteManagementDnsZoneBindingRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteManagementDnsZoneBindingRequest.php new file mode 100644 index 000000000000..a3d0fd65140e --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteManagementDnsZoneBindingRequest.php @@ -0,0 +1,180 @@ +google.cloud.vmwareengine.v1.DeleteManagementDnsZoneBindingRequest + */ +class DeleteManagementDnsZoneBindingRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the management DNS zone binding to delete. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/managementDnsZoneBindings/my-management-dns-zone-binding` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 the 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 = ''; + + /** + * @param string $name Required. The resource name of the management DNS zone binding to delete. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/managementDnsZoneBindings/my-management-dns-zone-binding` + * Please see {@see VmwareEngineClient::managementDnsZoneBindingName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\DeleteManagementDnsZoneBindingRequest + * + * @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 management DNS zone binding to delete. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/managementDnsZoneBindings/my-management-dns-zone-binding` + * @type string $request_id + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 the 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\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the management DNS zone binding to delete. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/managementDnsZoneBindings/my-management-dns-zone-binding` + * + * 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 management DNS zone binding to delete. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/managementDnsZoneBindings/my-management-dns-zone-binding` + * + * 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. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 the 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. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 the 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; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteNetworkPeeringRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteNetworkPeeringRequest.php new file mode 100644 index 000000000000..be442e7f5f22 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteNetworkPeeringRequest.php @@ -0,0 +1,180 @@ +google.cloud.vmwareengine.v1.DeleteNetworkPeeringRequest + */ +class DeleteNetworkPeeringRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the network peering to be deleted. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/global/networkPeerings/my-peering` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $request_id = ''; + + /** + * @param string $name Required. The resource name of the network peering to be deleted. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/global/networkPeerings/my-peering` + * Please see {@see VmwareEngineClient::networkPeeringName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\DeleteNetworkPeeringRequest + * + * @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 network peering to be deleted. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/global/networkPeerings/my-peering` + * @type string $request_id + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the network peering to be deleted. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/global/networkPeerings/my-peering` + * + * 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 network peering to be deleted. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/global/networkPeerings/my-peering` + * + * 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. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getRequestId() + { + return $this->request_id; + } + + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 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; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteNetworkPolicyRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteNetworkPolicyRequest.php new file mode 100644 index 000000000000..e0962e320717 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteNetworkPolicyRequest.php @@ -0,0 +1,180 @@ +google.cloud.vmwareengine.v1.DeleteNetworkPolicyRequest + */ +class DeleteNetworkPolicyRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the network policy to delete. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/networkPolicies/my-network-policy` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $request_id = ''; + + /** + * @param string $name Required. The resource name of the network policy to delete. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/networkPolicies/my-network-policy` + * Please see {@see VmwareEngineClient::networkPolicyName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\DeleteNetworkPolicyRequest + * + * @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 network policy to delete. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/networkPolicies/my-network-policy` + * @type string $request_id + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the network policy to delete. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/networkPolicies/my-network-policy` + * + * 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 network policy to delete. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/networkPolicies/my-network-policy` + * + * 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. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getRequestId() + { + return $this->request_id; + } + + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 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; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeletePrivateCloudRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeletePrivateCloudRequest.php new file mode 100644 index 000000000000..6a0d40bcbdc3 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeletePrivateCloudRequest.php @@ -0,0 +1,262 @@ +google.cloud.vmwareengine.v1.DeletePrivateCloudRequest + */ +class DeletePrivateCloudRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the private cloud to delete. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * Optional. 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 to true, cascade delete is enabled and all children of + * this private cloud resource are also deleted. When this flag is set to + * false, the private cloud will not be deleted if there are any children + * other than the management cluster. The management cluster is always + * deleted. + * + * Generated from protobuf field bool force = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $force = false; + /** + * Optional. Time delay of the deletion specified in hours. The default value + * is `3`. Specifying a non-zero value for this field changes the value of + * `PrivateCloud.state` to `DELETED` and sets `expire_time` to the planned + * deletion time. Deletion can be cancelled before `expire_time` elapses using + * [VmwareEngine.UndeletePrivateCloud][google.cloud.vmwareengine.v1.VmwareEngine.UndeletePrivateCloud]. + * Specifying a value of `0` for this field instead begins the deletion + * process and ceases billing immediately. During the final deletion process, + * the value of `PrivateCloud.state` becomes `PURGING`. + * + * Generated from protobuf field optional int32 delay_hours = 4 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $delay_hours = null; + + /** + * @param string $name Required. The resource name of the private cloud to delete. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * Please see {@see VmwareEngineClient::privateCloudName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\DeletePrivateCloudRequest + * + * @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 private cloud to delete. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * @type string $request_id + * Optional. The request ID must be a valid UUID with the exception that zero + * UUID is not supported (00000000-0000-0000-0000-000000000000). + * @type bool $force + * Optional. If set to true, cascade delete is enabled and all children of + * this private cloud resource are also deleted. When this flag is set to + * false, the private cloud will not be deleted if there are any children + * other than the management cluster. The management cluster is always + * deleted. + * @type int $delay_hours + * Optional. Time delay of the deletion specified in hours. The default value + * is `3`. Specifying a non-zero value for this field changes the value of + * `PrivateCloud.state` to `DELETED` and sets `expire_time` to the planned + * deletion time. Deletion can be cancelled before `expire_time` elapses using + * [VmwareEngine.UndeletePrivateCloud][google.cloud.vmwareengine.v1.VmwareEngine.UndeletePrivateCloud]. + * Specifying a value of `0` for this field instead begins the deletion + * process and ceases billing immediately. During the final deletion process, + * the value of `PrivateCloud.state` becomes `PURGING`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the private cloud to delete. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * 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 private cloud to delete. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * 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 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. 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 to true, cascade delete is enabled and all children of + * this private cloud resource are also deleted. When this flag is set to + * false, the private cloud will not be deleted if there are any children + * other than the management cluster. The management cluster is always + * deleted. + * + * Generated from protobuf field bool force = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return bool + */ + public function getForce() + { + return $this->force; + } + + /** + * Optional. If set to true, cascade delete is enabled and all children of + * this private cloud resource are also deleted. When this flag is set to + * false, the private cloud will not be deleted if there are any children + * other than the management cluster. The management cluster is always + * deleted. + * + * Generated from protobuf field bool force = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @param bool $var + * @return $this + */ + public function setForce($var) + { + GPBUtil::checkBool($var); + $this->force = $var; + + return $this; + } + + /** + * Optional. Time delay of the deletion specified in hours. The default value + * is `3`. Specifying a non-zero value for this field changes the value of + * `PrivateCloud.state` to `DELETED` and sets `expire_time` to the planned + * deletion time. Deletion can be cancelled before `expire_time` elapses using + * [VmwareEngine.UndeletePrivateCloud][google.cloud.vmwareengine.v1.VmwareEngine.UndeletePrivateCloud]. + * Specifying a value of `0` for this field instead begins the deletion + * process and ceases billing immediately. During the final deletion process, + * the value of `PrivateCloud.state` becomes `PURGING`. + * + * Generated from protobuf field optional int32 delay_hours = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @return int + */ + public function getDelayHours() + { + return isset($this->delay_hours) ? $this->delay_hours : 0; + } + + public function hasDelayHours() + { + return isset($this->delay_hours); + } + + public function clearDelayHours() + { + unset($this->delay_hours); + } + + /** + * Optional. Time delay of the deletion specified in hours. The default value + * is `3`. Specifying a non-zero value for this field changes the value of + * `PrivateCloud.state` to `DELETED` and sets `expire_time` to the planned + * deletion time. Deletion can be cancelled before `expire_time` elapses using + * [VmwareEngine.UndeletePrivateCloud][google.cloud.vmwareengine.v1.VmwareEngine.UndeletePrivateCloud]. + * Specifying a value of `0` for this field instead begins the deletion + * process and ceases billing immediately. During the final deletion process, + * the value of `PrivateCloud.state` becomes `PURGING`. + * + * Generated from protobuf field optional int32 delay_hours = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @param int $var + * @return $this + */ + public function setDelayHours($var) + { + GPBUtil::checkInt32($var); + $this->delay_hours = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeletePrivateConnectionRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeletePrivateConnectionRequest.php new file mode 100644 index 000000000000..98108687d10d --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeletePrivateConnectionRequest.php @@ -0,0 +1,180 @@ +google.cloud.vmwareengine.v1.DeletePrivateConnectionRequest + */ +class DeletePrivateConnectionRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the private connection to be deleted. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/privateConnections/my-connection` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $request_id = ''; + + /** + * @param string $name Required. The resource name of the private connection to be deleted. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/privateConnections/my-connection` + * Please see {@see VmwareEngineClient::privateConnectionName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\DeletePrivateConnectionRequest + * + * @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 private connection to be deleted. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/privateConnections/my-connection` + * @type string $request_id + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the private connection to be deleted. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/privateConnections/my-connection` + * + * 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 private connection to be deleted. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/privateConnections/my-connection` + * + * 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. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getRequestId() + { + return $this->request_id; + } + + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 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; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteVmwareEngineNetworkRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteVmwareEngineNetworkRequest.php new file mode 100644 index 000000000000..ff792e953240 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteVmwareEngineNetworkRequest.php @@ -0,0 +1,226 @@ +google.cloud.vmwareengine.v1.DeleteVmwareEngineNetworkRequest + */ +class DeleteVmwareEngineNetworkRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the VMware Engine network to be deleted. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/global/vmwareEngineNetworks/my-network` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $request_id = ''; + /** + * Optional. Checksum used to ensure that the user-provided value is up to + * date before the server processes the request. The server compares provided + * checksum with the current checksum of the resource. If the user-provided + * value is out of date, this request returns an `ABORTED` error. + * + * Generated from protobuf field string etag = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $etag = ''; + + /** + * @param string $name Required. The resource name of the VMware Engine network to be deleted. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/global/vmwareEngineNetworks/my-network` + * Please see {@see VmwareEngineClient::vmwareEngineNetworkName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\DeleteVmwareEngineNetworkRequest + * + * @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 VMware Engine network to be deleted. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/global/vmwareEngineNetworks/my-network` + * @type string $request_id + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 string $etag + * Optional. Checksum used to ensure that the user-provided value is up to + * date before the server processes the request. The server compares provided + * checksum with the current checksum of the resource. If the user-provided + * value is out of date, this request returns an `ABORTED` error. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the VMware Engine network to be deleted. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/global/vmwareEngineNetworks/my-network` + * + * 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 VMware Engine network to be deleted. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/global/vmwareEngineNetworks/my-network` + * + * 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. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getRequestId() + { + return $this->request_id; + } + + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 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. Checksum used to ensure that the user-provided value is up to + * date before the server processes the request. The server compares provided + * checksum with the current checksum of the resource. If the user-provided + * value is out of date, this request returns an `ABORTED` error. + * + * Generated from protobuf field string etag = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getEtag() + { + return $this->etag; + } + + /** + * Optional. Checksum used to ensure that the user-provided value is up to + * date before the server processes the request. The server compares provided + * checksum with the current checksum of the resource. If the user-provided + * value is out of date, this request returns an `ABORTED` error. + * + * Generated from protobuf field string etag = 3 [(.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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DnsBindPermission.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DnsBindPermission.php new file mode 100644 index 000000000000..fd658e066f26 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DnsBindPermission.php @@ -0,0 +1,130 @@ +google.cloud.vmwareengine.v1.DnsBindPermission + */ +class DnsBindPermission extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Output only. The name of the resource which stores the + * users/service accounts having the permission to bind to the corresponding + * intranet VPC of the consumer project. DnsBindPermission is a global + * resource and location can only be global. Resource names are schemeless + * URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. For example: + * `projects/my-project/locations/global/dnsBindPermission` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $name = ''; + /** + * Output only. Users/Service accounts which have access for binding on the + * intranet VPC project corresponding to the consumer project. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.Principal principals = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + private $principals; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. Output only. The name of the resource which stores the + * users/service accounts having the permission to bind to the corresponding + * intranet VPC of the consumer project. DnsBindPermission is a global + * resource and location can only be global. Resource names are schemeless + * URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. For example: + * `projects/my-project/locations/global/dnsBindPermission` + * @type \Google\Cloud\VmwareEngine\V1\Principal[] $principals + * Output only. Users/Service accounts which have access for binding on the + * intranet VPC project corresponding to the consumer project. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); + parent::__construct($data); + } + + /** + * Required. Output only. The name of the resource which stores the + * users/service accounts having the permission to bind to the corresponding + * intranet VPC of the consumer project. DnsBindPermission is a global + * resource and location can only be global. Resource names are schemeless + * URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. For example: + * `projects/my-project/locations/global/dnsBindPermission` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Required. Output only. The name of the resource which stores the + * users/service accounts having the permission to bind to the corresponding + * intranet VPC of the consumer project. DnsBindPermission is a global + * resource and location can only be global. Resource names are schemeless + * URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. For example: + * `projects/my-project/locations/global/dnsBindPermission` + * + * 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. Users/Service accounts which have access for binding on the + * intranet VPC project corresponding to the consumer project. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.Principal principals = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\Principal> + */ + public function getPrincipals() + { + return $this->principals; + } + + /** + * Output only. Users/Service accounts which have access for binding on the + * intranet VPC project corresponding to the consumer project. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.Principal principals = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Cloud\VmwareEngine\V1\Principal[] $var + * @return $this + */ + public function setPrincipals($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\Principal::class); + $this->principals = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DnsForwarding.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DnsForwarding.php new file mode 100644 index 000000000000..7163e44ee86c --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DnsForwarding.php @@ -0,0 +1,207 @@ +google.cloud.vmwareengine.v1.DnsForwarding + */ +class DnsForwarding extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. The resource name of this DNS profile. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/dnsForwarding` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $name = ''; + /** + * Output only. Creation time of this resource. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $create_time = null; + /** + * Output only. Last update time of this resource. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $update_time = null; + /** + * Required. List of domain mappings to configure + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.DnsForwarding.ForwardingRule forwarding_rules = 4 [(.google.api.field_behavior) = REQUIRED]; + */ + private $forwarding_rules; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Output only. The resource name of this DNS profile. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/dnsForwarding` + * @type \Google\Protobuf\Timestamp $create_time + * Output only. Creation time of this resource. + * @type \Google\Protobuf\Timestamp $update_time + * Output only. Last update time of this resource. + * @type \Google\Cloud\VmwareEngine\V1\DnsForwarding\ForwardingRule[] $forwarding_rules + * Required. List of domain mappings to configure + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); + parent::__construct($data); + } + + /** + * Output only. The resource name of this DNS profile. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/dnsForwarding` + * + * 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 DNS profile. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/dnsForwarding` + * + * 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. Creation time of this resource. + * + * 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 time of this resource. + * + * 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 time of this resource. + * + * 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 time of this resource. + * + * 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; + } + + /** + * Required. List of domain mappings to configure + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.DnsForwarding.ForwardingRule forwarding_rules = 4 [(.google.api.field_behavior) = REQUIRED]; + * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\DnsForwarding\ForwardingRule> + */ + public function getForwardingRules() + { + return $this->forwarding_rules; + } + + /** + * Required. List of domain mappings to configure + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.DnsForwarding.ForwardingRule forwarding_rules = 4 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\VmwareEngine\V1\DnsForwarding\ForwardingRule[] $var + * @return $this + */ + public function setForwardingRules($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\DnsForwarding\ForwardingRule::class); + $this->forwarding_rules = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DnsForwarding/ForwardingRule.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DnsForwarding/ForwardingRule.php new file mode 100644 index 000000000000..69ffc594750d --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DnsForwarding/ForwardingRule.php @@ -0,0 +1,104 @@ +google.cloud.vmwareengine.v1.DnsForwarding.ForwardingRule + */ +class ForwardingRule extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Domain used to resolve a `name_servers` list. + * + * Generated from protobuf field string domain = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $domain = ''; + /** + * Required. List of DNS servers to use for domain resolution + * + * Generated from protobuf field repeated string name_servers = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + private $name_servers; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $domain + * Required. Domain used to resolve a `name_servers` list. + * @type string[] $name_servers + * Required. List of DNS servers to use for domain resolution + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); + parent::__construct($data); + } + + /** + * Required. Domain used to resolve a `name_servers` list. + * + * Generated from protobuf field string domain = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getDomain() + { + return $this->domain; + } + + /** + * Required. Domain used to resolve a `name_servers` list. + * + * Generated from protobuf field string domain = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setDomain($var) + { + GPBUtil::checkString($var, True); + $this->domain = $var; + + return $this; + } + + /** + * Required. List of DNS servers to use for domain resolution + * + * Generated from protobuf field repeated string name_servers = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return RepeatedField + */ + public function getNameServers() + { + return $this->name_servers; + } + + /** + * Required. List of DNS servers to use for domain resolution + * + * Generated from protobuf field repeated string name_servers = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param string[] $var + * @return $this + */ + public function setNameServers($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->name_servers = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAccessRule.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAccessRule.php new file mode 100644 index 000000000000..2b1a319b365b --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAccessRule.php @@ -0,0 +1,620 @@ +google.cloud.vmwareengine.v1.ExternalAccessRule + */ +class ExternalAccessRule extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. The resource name of this external access rule. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/networkPolicies/my-policy/externalAccessRules/my-rule` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $name = ''; + /** + * Output only. Creation time of this resource. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $create_time = null; + /** + * Output only. Last update time of this resource. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $update_time = null; + /** + * User-provided description for this external access rule. + * + * Generated from protobuf field string description = 5; + */ + protected $description = ''; + /** + * External access rule priority, which determines the external access rule to + * use when multiple rules apply. If multiple rules have the same priority, + * their ordering is non-deterministic. If specific ordering is required, + * assign unique priorities to enforce such ordering. The external access rule + * priority is an integer from 100 to 4096, both inclusive. Lower integers + * indicate higher precedence. For example, a rule with priority `100` has + * higher precedence than a rule with priority `101`. + * + * Generated from protobuf field int32 priority = 6; + */ + protected $priority = 0; + /** + * The action that the external access rule performs. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.ExternalAccessRule.Action action = 7; + */ + protected $action = 0; + /** + * The IP protocol to which the external access rule applies. This value can + * be one of the following three protocol strings (not case-sensitive): + * `tcp`, `udp`, or `icmp`. + * + * Generated from protobuf field string ip_protocol = 8; + */ + protected $ip_protocol = ''; + /** + * If source ranges are specified, the external access rule applies only to + * traffic that has a source IP address in these ranges. These ranges can + * either be expressed in the CIDR format or as an IP address. As only inbound + * rules are supported, `ExternalAddress` resources cannot be the source IP + * addresses of an external access rule. To match all source addresses, + * specify `0.0.0.0/0`. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.ExternalAccessRule.IpRange source_ip_ranges = 9; + */ + private $source_ip_ranges; + /** + * A list of source ports to which the external access rule applies. This + * field is only applicable for the UDP or TCP protocol. + * Each entry must be either an integer or a range. For example: `["22"]`, + * `["80","443"]`, or `["12345-12349"]`. To match all source ports, specify + * `["0-65535"]`. + * + * Generated from protobuf field repeated string source_ports = 10; + */ + private $source_ports; + /** + * If destination ranges are specified, the external access rule applies only + * to the traffic that has a destination IP address in these ranges. The + * specified IP addresses must have reserved external IP addresses in the + * scope of the parent network policy. To match all external IP addresses in + * the scope of the parent network policy, specify `0.0.0.0/0`. To match a + * specific external IP address, specify it using the + * `IpRange.external_address` property. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.ExternalAccessRule.IpRange destination_ip_ranges = 11; + */ + private $destination_ip_ranges; + /** + * A list of destination ports to which the external access rule applies. This + * field is only applicable for the UDP or TCP protocol. + * Each entry must be either an integer or a range. For example: `["22"]`, + * `["80","443"]`, or `["12345-12349"]`. To match all destination ports, + * specify `["0-65535"]`. + * + * Generated from protobuf field repeated string destination_ports = 12; + */ + private $destination_ports; + /** + * Output only. The state of the resource. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.ExternalAccessRule.State state = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $state = 0; + /** + * Output only. System-generated unique identifier for the resource. + * + * Generated from protobuf field string uid = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $uid = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Output only. The resource name of this external access rule. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/networkPolicies/my-policy/externalAccessRules/my-rule` + * @type \Google\Protobuf\Timestamp $create_time + * Output only. Creation time of this resource. + * @type \Google\Protobuf\Timestamp $update_time + * Output only. Last update time of this resource. + * @type string $description + * User-provided description for this external access rule. + * @type int $priority + * External access rule priority, which determines the external access rule to + * use when multiple rules apply. If multiple rules have the same priority, + * their ordering is non-deterministic. If specific ordering is required, + * assign unique priorities to enforce such ordering. The external access rule + * priority is an integer from 100 to 4096, both inclusive. Lower integers + * indicate higher precedence. For example, a rule with priority `100` has + * higher precedence than a rule with priority `101`. + * @type int $action + * The action that the external access rule performs. + * @type string $ip_protocol + * The IP protocol to which the external access rule applies. This value can + * be one of the following three protocol strings (not case-sensitive): + * `tcp`, `udp`, or `icmp`. + * @type \Google\Cloud\VmwareEngine\V1\ExternalAccessRule\IpRange[] $source_ip_ranges + * If source ranges are specified, the external access rule applies only to + * traffic that has a source IP address in these ranges. These ranges can + * either be expressed in the CIDR format or as an IP address. As only inbound + * rules are supported, `ExternalAddress` resources cannot be the source IP + * addresses of an external access rule. To match all source addresses, + * specify `0.0.0.0/0`. + * @type string[] $source_ports + * A list of source ports to which the external access rule applies. This + * field is only applicable for the UDP or TCP protocol. + * Each entry must be either an integer or a range. For example: `["22"]`, + * `["80","443"]`, or `["12345-12349"]`. To match all source ports, specify + * `["0-65535"]`. + * @type \Google\Cloud\VmwareEngine\V1\ExternalAccessRule\IpRange[] $destination_ip_ranges + * If destination ranges are specified, the external access rule applies only + * to the traffic that has a destination IP address in these ranges. The + * specified IP addresses must have reserved external IP addresses in the + * scope of the parent network policy. To match all external IP addresses in + * the scope of the parent network policy, specify `0.0.0.0/0`. To match a + * specific external IP address, specify it using the + * `IpRange.external_address` property. + * @type string[] $destination_ports + * A list of destination ports to which the external access rule applies. This + * field is only applicable for the UDP or TCP protocol. + * Each entry must be either an integer or a range. For example: `["22"]`, + * `["80","443"]`, or `["12345-12349"]`. To match all destination ports, + * specify `["0-65535"]`. + * @type int $state + * Output only. The state of the resource. + * @type string $uid + * Output only. System-generated unique identifier for the resource. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); + parent::__construct($data); + } + + /** + * Output only. The resource name of this external access rule. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/networkPolicies/my-policy/externalAccessRules/my-rule` + * + * 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 external access rule. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/networkPolicies/my-policy/externalAccessRules/my-rule` + * + * 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. Creation time of this resource. + * + * 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 time of this resource. + * + * 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 time of this resource. + * + * 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 time of this resource. + * + * 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; + } + + /** + * User-provided description for this external access rule. + * + * Generated from protobuf field string description = 5; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * User-provided description for this external access rule. + * + * 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; + } + + /** + * External access rule priority, which determines the external access rule to + * use when multiple rules apply. If multiple rules have the same priority, + * their ordering is non-deterministic. If specific ordering is required, + * assign unique priorities to enforce such ordering. The external access rule + * priority is an integer from 100 to 4096, both inclusive. Lower integers + * indicate higher precedence. For example, a rule with priority `100` has + * higher precedence than a rule with priority `101`. + * + * Generated from protobuf field int32 priority = 6; + * @return int + */ + public function getPriority() + { + return $this->priority; + } + + /** + * External access rule priority, which determines the external access rule to + * use when multiple rules apply. If multiple rules have the same priority, + * their ordering is non-deterministic. If specific ordering is required, + * assign unique priorities to enforce such ordering. The external access rule + * priority is an integer from 100 to 4096, both inclusive. Lower integers + * indicate higher precedence. For example, a rule with priority `100` has + * higher precedence than a rule with priority `101`. + * + * Generated from protobuf field int32 priority = 6; + * @param int $var + * @return $this + */ + public function setPriority($var) + { + GPBUtil::checkInt32($var); + $this->priority = $var; + + return $this; + } + + /** + * The action that the external access rule performs. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.ExternalAccessRule.Action action = 7; + * @return int + */ + public function getAction() + { + return $this->action; + } + + /** + * The action that the external access rule performs. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.ExternalAccessRule.Action action = 7; + * @param int $var + * @return $this + */ + public function setAction($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\ExternalAccessRule\Action::class); + $this->action = $var; + + return $this; + } + + /** + * The IP protocol to which the external access rule applies. This value can + * be one of the following three protocol strings (not case-sensitive): + * `tcp`, `udp`, or `icmp`. + * + * Generated from protobuf field string ip_protocol = 8; + * @return string + */ + public function getIpProtocol() + { + return $this->ip_protocol; + } + + /** + * The IP protocol to which the external access rule applies. This value can + * be one of the following three protocol strings (not case-sensitive): + * `tcp`, `udp`, or `icmp`. + * + * Generated from protobuf field string ip_protocol = 8; + * @param string $var + * @return $this + */ + public function setIpProtocol($var) + { + GPBUtil::checkString($var, True); + $this->ip_protocol = $var; + + return $this; + } + + /** + * If source ranges are specified, the external access rule applies only to + * traffic that has a source IP address in these ranges. These ranges can + * either be expressed in the CIDR format or as an IP address. As only inbound + * rules are supported, `ExternalAddress` resources cannot be the source IP + * addresses of an external access rule. To match all source addresses, + * specify `0.0.0.0/0`. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.ExternalAccessRule.IpRange source_ip_ranges = 9; + * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\ExternalAccessRule\IpRange> + */ + public function getSourceIpRanges() + { + return $this->source_ip_ranges; + } + + /** + * If source ranges are specified, the external access rule applies only to + * traffic that has a source IP address in these ranges. These ranges can + * either be expressed in the CIDR format or as an IP address. As only inbound + * rules are supported, `ExternalAddress` resources cannot be the source IP + * addresses of an external access rule. To match all source addresses, + * specify `0.0.0.0/0`. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.ExternalAccessRule.IpRange source_ip_ranges = 9; + * @param \Google\Cloud\VmwareEngine\V1\ExternalAccessRule\IpRange[] $var + * @return $this + */ + public function setSourceIpRanges($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\ExternalAccessRule\IpRange::class); + $this->source_ip_ranges = $arr; + + return $this; + } + + /** + * A list of source ports to which the external access rule applies. This + * field is only applicable for the UDP or TCP protocol. + * Each entry must be either an integer or a range. For example: `["22"]`, + * `["80","443"]`, or `["12345-12349"]`. To match all source ports, specify + * `["0-65535"]`. + * + * Generated from protobuf field repeated string source_ports = 10; + * @return RepeatedField + */ + public function getSourcePorts() + { + return $this->source_ports; + } + + /** + * A list of source ports to which the external access rule applies. This + * field is only applicable for the UDP or TCP protocol. + * Each entry must be either an integer or a range. For example: `["22"]`, + * `["80","443"]`, or `["12345-12349"]`. To match all source ports, specify + * `["0-65535"]`. + * + * Generated from protobuf field repeated string source_ports = 10; + * @param string[] $var + * @return $this + */ + public function setSourcePorts($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->source_ports = $arr; + + return $this; + } + + /** + * If destination ranges are specified, the external access rule applies only + * to the traffic that has a destination IP address in these ranges. The + * specified IP addresses must have reserved external IP addresses in the + * scope of the parent network policy. To match all external IP addresses in + * the scope of the parent network policy, specify `0.0.0.0/0`. To match a + * specific external IP address, specify it using the + * `IpRange.external_address` property. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.ExternalAccessRule.IpRange destination_ip_ranges = 11; + * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\ExternalAccessRule\IpRange> + */ + public function getDestinationIpRanges() + { + return $this->destination_ip_ranges; + } + + /** + * If destination ranges are specified, the external access rule applies only + * to the traffic that has a destination IP address in these ranges. The + * specified IP addresses must have reserved external IP addresses in the + * scope of the parent network policy. To match all external IP addresses in + * the scope of the parent network policy, specify `0.0.0.0/0`. To match a + * specific external IP address, specify it using the + * `IpRange.external_address` property. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.ExternalAccessRule.IpRange destination_ip_ranges = 11; + * @param \Google\Cloud\VmwareEngine\V1\ExternalAccessRule\IpRange[] $var + * @return $this + */ + public function setDestinationIpRanges($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\ExternalAccessRule\IpRange::class); + $this->destination_ip_ranges = $arr; + + return $this; + } + + /** + * A list of destination ports to which the external access rule applies. This + * field is only applicable for the UDP or TCP protocol. + * Each entry must be either an integer or a range. For example: `["22"]`, + * `["80","443"]`, or `["12345-12349"]`. To match all destination ports, + * specify `["0-65535"]`. + * + * Generated from protobuf field repeated string destination_ports = 12; + * @return RepeatedField + */ + public function getDestinationPorts() + { + return $this->destination_ports; + } + + /** + * A list of destination ports to which the external access rule applies. This + * field is only applicable for the UDP or TCP protocol. + * Each entry must be either an integer or a range. For example: `["22"]`, + * `["80","443"]`, or `["12345-12349"]`. To match all destination ports, + * specify `["0-65535"]`. + * + * Generated from protobuf field repeated string destination_ports = 12; + * @param string[] $var + * @return $this + */ + public function setDestinationPorts($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->destination_ports = $arr; + + return $this; + } + + /** + * Output only. The state of the resource. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.ExternalAccessRule.State state = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getState() + { + return $this->state; + } + + /** + * Output only. The state of the resource. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.ExternalAccessRule.State state = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setState($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\ExternalAccessRule\State::class); + $this->state = $var; + + return $this; + } + + /** + * Output only. System-generated unique identifier for the resource. + * + * Generated from protobuf field string uid = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getUid() + { + return $this->uid; + } + + /** + * Output only. System-generated unique identifier for the resource. + * + * Generated from protobuf field string uid = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setUid($var) + { + GPBUtil::checkString($var, True); + $this->uid = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAccessRule/Action.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAccessRule/Action.php new file mode 100644 index 000000000000..5334d921d686 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAccessRule/Action.php @@ -0,0 +1,62 @@ +google.cloud.vmwareengine.v1.ExternalAccessRule.Action + */ +class Action +{ + /** + * Defaults to allow. + * + * Generated from protobuf enum ACTION_UNSPECIFIED = 0; + */ + const ACTION_UNSPECIFIED = 0; + /** + * Allows connections that match the other specified components. + * + * Generated from protobuf enum ALLOW = 1; + */ + const ALLOW = 1; + /** + * Blocks connections that match the other specified components. + * + * Generated from protobuf enum DENY = 2; + */ + const DENY = 2; + + private static $valueToName = [ + self::ACTION_UNSPECIFIED => 'ACTION_UNSPECIFIED', + self::ALLOW => 'ALLOW', + self::DENY => 'DENY', + ]; + + 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAccessRule/IpRange.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAccessRule/IpRange.php new file mode 100644 index 000000000000..44ef1af0a579 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAccessRule/IpRange.php @@ -0,0 +1,156 @@ +google.cloud.vmwareengine.v1.ExternalAccessRule.IpRange + */ +class IpRange extends \Google\Protobuf\Internal\Message +{ + protected $ip_range; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $ip_address + * A single IP address. For example: `10.0.0.5`. + * @type string $ip_address_range + * An IP address range in the CIDR format. For example: `10.0.0.0/24`. + * @type string $external_address + * The name of an `ExternalAddress` resource. The external address must + * have been reserved in the scope of this external access rule's parent + * network policy. Provide the external address name in the form of + * `projects/{project}/locations/{location}/privateClouds/{private_cloud}/externalAddresses/{external_address}`. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/externalAddresses/my-address`. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); + parent::__construct($data); + } + + /** + * A single IP address. For example: `10.0.0.5`. + * + * Generated from protobuf field string ip_address = 1; + * @return string + */ + public function getIpAddress() + { + return $this->readOneof(1); + } + + public function hasIpAddress() + { + return $this->hasOneof(1); + } + + /** + * A single IP address. For example: `10.0.0.5`. + * + * Generated from protobuf field string ip_address = 1; + * @param string $var + * @return $this + */ + public function setIpAddress($var) + { + GPBUtil::checkString($var, True); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * An IP address range in the CIDR format. For example: `10.0.0.0/24`. + * + * Generated from protobuf field string ip_address_range = 2; + * @return string + */ + public function getIpAddressRange() + { + return $this->readOneof(2); + } + + public function hasIpAddressRange() + { + return $this->hasOneof(2); + } + + /** + * An IP address range in the CIDR format. For example: `10.0.0.0/24`. + * + * Generated from protobuf field string ip_address_range = 2; + * @param string $var + * @return $this + */ + public function setIpAddressRange($var) + { + GPBUtil::checkString($var, True); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * The name of an `ExternalAddress` resource. The external address must + * have been reserved in the scope of this external access rule's parent + * network policy. Provide the external address name in the form of + * `projects/{project}/locations/{location}/privateClouds/{private_cloud}/externalAddresses/{external_address}`. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/externalAddresses/my-address`. + * + * Generated from protobuf field string external_address = 3 [(.google.api.resource_reference) = { + * @return string + */ + public function getExternalAddress() + { + return $this->readOneof(3); + } + + public function hasExternalAddress() + { + return $this->hasOneof(3); + } + + /** + * The name of an `ExternalAddress` resource. The external address must + * have been reserved in the scope of this external access rule's parent + * network policy. Provide the external address name in the form of + * `projects/{project}/locations/{location}/privateClouds/{private_cloud}/externalAddresses/{external_address}`. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/externalAddresses/my-address`. + * + * Generated from protobuf field string external_address = 3 [(.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setExternalAddress($var) + { + GPBUtil::checkString($var, True); + $this->writeOneof(3, $var); + + return $this; + } + + /** + * @return string + */ + public function getIpRange() + { + return $this->whichOneof("ip_range"); + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAccessRule/State.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAccessRule/State.php new file mode 100644 index 000000000000..1b8614cc51df --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAccessRule/State.php @@ -0,0 +1,75 @@ +google.cloud.vmwareengine.v1.ExternalAccessRule.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 rule is ready. + * + * Generated from protobuf enum ACTIVE = 1; + */ + const ACTIVE = 1; + /** + * The rule is being created. + * + * Generated from protobuf enum CREATING = 2; + */ + const CREATING = 2; + /** + * The rule is being updated. + * + * Generated from protobuf enum UPDATING = 3; + */ + const UPDATING = 3; + /** + * The rule is being deleted. + * + * Generated from protobuf enum DELETING = 4; + */ + const DELETING = 4; + + private static $valueToName = [ + self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', + self::ACTIVE => 'ACTIVE', + self::CREATING => 'CREATING', + self::UPDATING => 'UPDATING', + 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); + } +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAddress.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAddress.php new file mode 100644 index 000000000000..2cc27215b61e --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAddress.php @@ -0,0 +1,342 @@ +google.cloud.vmwareengine.v1.ExternalAddress + */ +class ExternalAddress extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. The resource name of this external IP address. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/externalAddresses/my-address` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $name = ''; + /** + * Output only. Creation time of this resource. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $create_time = null; + /** + * Output only. Last update time of this resource. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $update_time = null; + /** + * The internal IP address of a workload VM. + * + * Generated from protobuf field string internal_ip = 6; + */ + protected $internal_ip = ''; + /** + * Output only. The external IP address of a workload VM. + * + * Generated from protobuf field string external_ip = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $external_ip = ''; + /** + * Output only. The state of the resource. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.ExternalAddress.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $state = 0; + /** + * Output only. System-generated unique identifier for the resource. + * + * Generated from protobuf field string uid = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $uid = ''; + /** + * User-provided description for this resource. + * + * Generated from protobuf field string description = 11; + */ + protected $description = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Output only. The resource name of this external IP address. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/externalAddresses/my-address` + * @type \Google\Protobuf\Timestamp $create_time + * Output only. Creation time of this resource. + * @type \Google\Protobuf\Timestamp $update_time + * Output only. Last update time of this resource. + * @type string $internal_ip + * The internal IP address of a workload VM. + * @type string $external_ip + * Output only. The external IP address of a workload VM. + * @type int $state + * Output only. The state of the resource. + * @type string $uid + * Output only. System-generated unique identifier for the resource. + * @type string $description + * User-provided description for this resource. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); + parent::__construct($data); + } + + /** + * Output only. The resource name of this external IP address. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/externalAddresses/my-address` + * + * 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 external IP address. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/externalAddresses/my-address` + * + * 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. Creation time of this resource. + * + * 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 time of this resource. + * + * 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 time of this resource. + * + * 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 time of this resource. + * + * 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 internal IP address of a workload VM. + * + * Generated from protobuf field string internal_ip = 6; + * @return string + */ + public function getInternalIp() + { + return $this->internal_ip; + } + + /** + * The internal IP address of a workload VM. + * + * Generated from protobuf field string internal_ip = 6; + * @param string $var + * @return $this + */ + public function setInternalIp($var) + { + GPBUtil::checkString($var, True); + $this->internal_ip = $var; + + return $this; + } + + /** + * Output only. The external IP address of a workload VM. + * + * Generated from protobuf field string external_ip = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getExternalIp() + { + return $this->external_ip; + } + + /** + * Output only. The external IP address of a workload VM. + * + * Generated from protobuf field string external_ip = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setExternalIp($var) + { + GPBUtil::checkString($var, True); + $this->external_ip = $var; + + return $this; + } + + /** + * Output only. The state of the resource. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.ExternalAddress.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getState() + { + return $this->state; + } + + /** + * Output only. The state of the resource. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.ExternalAddress.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setState($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\ExternalAddress\State::class); + $this->state = $var; + + return $this; + } + + /** + * Output only. System-generated unique identifier for the resource. + * + * Generated from protobuf field string uid = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getUid() + { + return $this->uid; + } + + /** + * Output only. System-generated unique identifier for the resource. + * + * Generated from protobuf field string uid = 9 [(.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-provided description for this resource. + * + * Generated from protobuf field string description = 11; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * User-provided description for this resource. + * + * Generated from protobuf field string description = 11; + * @param string $var + * @return $this + */ + public function setDescription($var) + { + GPBUtil::checkString($var, True); + $this->description = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAddress/State.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAddress/State.php new file mode 100644 index 000000000000..808ba3a62c3e --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAddress/State.php @@ -0,0 +1,75 @@ +google.cloud.vmwareengine.v1.ExternalAddress.State + */ +class State +{ + /** + * The default value. This value should never be used. + * + * Generated from protobuf enum STATE_UNSPECIFIED = 0; + */ + const STATE_UNSPECIFIED = 0; + /** + * The address is ready. + * + * Generated from protobuf enum ACTIVE = 1; + */ + const ACTIVE = 1; + /** + * The address is being created. + * + * Generated from protobuf enum CREATING = 2; + */ + const CREATING = 2; + /** + * The address is being updated. + * + * Generated from protobuf enum UPDATING = 3; + */ + const UPDATING = 3; + /** + * The address is being deleted. + * + * Generated from protobuf enum DELETING = 4; + */ + const DELETING = 4; + + private static $valueToName = [ + self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', + self::ACTIVE => 'ACTIVE', + self::CREATING => 'CREATING', + self::UPDATING => 'UPDATING', + 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); + } +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/FetchNetworkPolicyExternalAddressesRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/FetchNetworkPolicyExternalAddressesRequest.php new file mode 100644 index 000000000000..c8a6ce1fc904 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/FetchNetworkPolicyExternalAddressesRequest.php @@ -0,0 +1,202 @@ +google.cloud.vmwareengine.v1.FetchNetworkPolicyExternalAddressesRequest + */ +class FetchNetworkPolicyExternalAddressesRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the network policy to query for assigned + * external IP addresses. Resource names are schemeless URIs that follow the + * conventions in https://cloud.google.com/apis/design/resource_names. For + * example: + * `projects/my-project/locations/us-central1/networkPolicies/my-policy` + * + * Generated from protobuf field string network_policy = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $network_policy = ''; + /** + * The maximum number of external IP addresses to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * Generated from protobuf field int32 page_size = 2; + */ + protected $page_size = 0; + /** + * A page token, received from a previous + * `FetchNetworkPolicyExternalAddresses` call. Provide this to retrieve the + * subsequent page. + * When paginating, all parameters provided to + * `FetchNetworkPolicyExternalAddresses`, except for `page_size` and + * `page_token`, must match the call that provided the page token. + * + * Generated from protobuf field string page_token = 3; + */ + protected $page_token = ''; + + /** + * @param string $networkPolicy Required. The resource name of the network policy to query for assigned + * external IP addresses. Resource names are schemeless URIs that follow the + * conventions in https://cloud.google.com/apis/design/resource_names. For + * example: + * `projects/my-project/locations/us-central1/networkPolicies/my-policy` + * Please see {@see VmwareEngineClient::networkPolicyName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\FetchNetworkPolicyExternalAddressesRequest + * + * @experimental + */ + public static function build(string $networkPolicy): self + { + return (new self()) + ->setNetworkPolicy($networkPolicy); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $network_policy + * Required. The resource name of the network policy to query for assigned + * external IP addresses. Resource names are schemeless URIs that follow the + * conventions in https://cloud.google.com/apis/design/resource_names. For + * example: + * `projects/my-project/locations/us-central1/networkPolicies/my-policy` + * @type int $page_size + * The maximum number of external IP addresses to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * @type string $page_token + * A page token, received from a previous + * `FetchNetworkPolicyExternalAddresses` call. Provide this to retrieve the + * subsequent page. + * When paginating, all parameters provided to + * `FetchNetworkPolicyExternalAddresses`, except for `page_size` and + * `page_token`, must match the call that provided the page token. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the network policy to query for assigned + * external IP addresses. Resource names are schemeless URIs that follow the + * conventions in https://cloud.google.com/apis/design/resource_names. For + * example: + * `projects/my-project/locations/us-central1/networkPolicies/my-policy` + * + * Generated from protobuf field string network_policy = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getNetworkPolicy() + { + return $this->network_policy; + } + + /** + * Required. The resource name of the network policy to query for assigned + * external IP addresses. Resource names are schemeless URIs that follow the + * conventions in https://cloud.google.com/apis/design/resource_names. For + * example: + * `projects/my-project/locations/us-central1/networkPolicies/my-policy` + * + * Generated from protobuf field string network_policy = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setNetworkPolicy($var) + { + GPBUtil::checkString($var, True); + $this->network_policy = $var; + + return $this; + } + + /** + * The maximum number of external IP addresses to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * Generated from protobuf field int32 page_size = 2; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of external IP addresses to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * 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 + * `FetchNetworkPolicyExternalAddresses` call. Provide this to retrieve the + * subsequent page. + * When paginating, all parameters provided to + * `FetchNetworkPolicyExternalAddresses`, except for `page_size` and + * `page_token`, 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 + * `FetchNetworkPolicyExternalAddresses` call. Provide this to retrieve the + * subsequent page. + * When paginating, all parameters provided to + * `FetchNetworkPolicyExternalAddresses`, except for `page_size` and + * `page_token`, 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; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/FetchNetworkPolicyExternalAddressesResponse.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/FetchNetworkPolicyExternalAddressesResponse.php new file mode 100644 index 000000000000..0ded235008ed --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/FetchNetworkPolicyExternalAddressesResponse.php @@ -0,0 +1,110 @@ +google.cloud.vmwareengine.v1.FetchNetworkPolicyExternalAddressesResponse + */ +class FetchNetworkPolicyExternalAddressesResponse extends \Google\Protobuf\Internal\Message +{ + /** + * A list of external IP addresses assigned to VMware workload VMs within the + * scope of the given network policy. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.ExternalAddress external_addresses = 1; + */ + private $external_addresses; + /** + * 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 \Google\Cloud\VmwareEngine\V1\ExternalAddress[] $external_addresses + * A list of external IP addresses assigned to VMware workload VMs within the + * scope of the given network policy. + * @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\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * A list of external IP addresses assigned to VMware workload VMs within the + * scope of the given network policy. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.ExternalAddress external_addresses = 1; + * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\ExternalAddress> + */ + public function getExternalAddresses() + { + return $this->external_addresses; + } + + /** + * A list of external IP addresses assigned to VMware workload VMs within the + * scope of the given network policy. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.ExternalAddress external_addresses = 1; + * @param \Google\Cloud\VmwareEngine\V1\ExternalAddress[] $var + * @return $this + */ + public function setExternalAddresses($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\ExternalAddress::class); + $this->external_addresses = $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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetClusterRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetClusterRequest.php new file mode 100644 index 000000000000..2215db732e3e --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetClusterRequest.php @@ -0,0 +1,102 @@ +google.cloud.vmwareengine.v1.GetClusterRequest + */ +class GetClusterRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The cluster resource name to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + + /** + * @param string $name Required. The cluster resource name to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster` + * Please see {@see VmwareEngineClient::clusterName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\GetClusterRequest + * + * @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 cluster resource name to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster` + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The cluster resource name to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster` + * + * 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 cluster resource name to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster` + * + * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetDnsBindPermissionRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetDnsBindPermissionRequest.php new file mode 100644 index 000000000000..de2977a08173 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetDnsBindPermissionRequest.php @@ -0,0 +1,107 @@ +google.cloud.vmwareengine.v1.GetDnsBindPermissionRequest + */ +class GetDnsBindPermissionRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the resource which stores the users/service accounts + * having the permission to bind to the corresponding intranet VPC of the + * consumer project. DnsBindPermission is a global resource. Resource names + * are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. For example: + * `projects/my-project/locations/global/dnsBindPermission` + * + * 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 resource which stores the users/service accounts + * having the permission to bind to the corresponding intranet VPC of the + * consumer project. DnsBindPermission is a global resource. Resource names + * are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. For example: + * `projects/my-project/locations/global/dnsBindPermission` + * Please see {@see VmwareEngineClient::dnsBindPermissionName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\GetDnsBindPermissionRequest + * + * @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 resource which stores the users/service accounts + * having the permission to bind to the corresponding intranet VPC of the + * consumer project. DnsBindPermission is a global resource. Resource names + * are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. For example: + * `projects/my-project/locations/global/dnsBindPermission` + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the resource which stores the users/service accounts + * having the permission to bind to the corresponding intranet VPC of the + * consumer project. DnsBindPermission is a global resource. Resource names + * are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. For example: + * `projects/my-project/locations/global/dnsBindPermission` + * + * 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 resource which stores the users/service accounts + * having the permission to bind to the corresponding intranet VPC of the + * consumer project. DnsBindPermission is a global resource. Resource names + * are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. For example: + * `projects/my-project/locations/global/dnsBindPermission` + * + * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetDnsForwardingRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetDnsForwardingRequest.php new file mode 100644 index 000000000000..8439208cddad --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetDnsForwardingRequest.php @@ -0,0 +1,102 @@ +google.cloud.vmwareengine.v1.GetDnsForwardingRequest + */ +class GetDnsForwardingRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of a `DnsForwarding` to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/dnsForwarding` + * + * 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 a `DnsForwarding` to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/dnsForwarding` + * Please see {@see VmwareEngineClient::dnsForwardingName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\GetDnsForwardingRequest + * + * @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 a `DnsForwarding` to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/dnsForwarding` + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of a `DnsForwarding` to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/dnsForwarding` + * + * 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 a `DnsForwarding` to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/dnsForwarding` + * + * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetExternalAccessRuleRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetExternalAccessRuleRequest.php new file mode 100644 index 000000000000..5df34dbd5f46 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetExternalAccessRuleRequest.php @@ -0,0 +1,102 @@ +google.cloud.vmwareengine.v1.GetExternalAccessRuleRequest + */ +class GetExternalAccessRuleRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the external access firewall rule to + * retrieve. Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/networkPolicies/my-policy/externalAccessRules/my-rule` + * + * 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 external access firewall rule to + * retrieve. Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/networkPolicies/my-policy/externalAccessRules/my-rule` + * Please see {@see VmwareEngineClient::externalAccessRuleName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\GetExternalAccessRuleRequest + * + * @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 external access firewall rule to + * retrieve. Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/networkPolicies/my-policy/externalAccessRules/my-rule` + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the external access firewall rule to + * retrieve. Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/networkPolicies/my-policy/externalAccessRules/my-rule` + * + * 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 external access firewall rule to + * retrieve. Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/networkPolicies/my-policy/externalAccessRules/my-rule` + * + * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetExternalAddressRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetExternalAddressRequest.php new file mode 100644 index 000000000000..0a03b77025bb --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetExternalAddressRequest.php @@ -0,0 +1,102 @@ +google.cloud.vmwareengine.v1.GetExternalAddressRequest + */ +class GetExternalAddressRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the external IP address to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/externalAddresses/my-ip` + * + * 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 external IP address to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/externalAddresses/my-ip` + * Please see {@see VmwareEngineClient::externalAddressName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\GetExternalAddressRequest + * + * @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 external IP address to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/externalAddresses/my-ip` + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the external IP address to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/externalAddresses/my-ip` + * + * 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 external IP address to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/externalAddresses/my-ip` + * + * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetHcxActivationKeyRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetHcxActivationKeyRequest.php new file mode 100644 index 000000000000..5ca1f84b8233 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetHcxActivationKeyRequest.php @@ -0,0 +1,101 @@ +google.cloud.vmwareengine.v1.GetHcxActivationKeyRequest + */ +class GetHcxActivationKeyRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the HCX activation key to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/privateClouds/my-cloud/hcxActivationKeys/my-key` + * + * 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 HCX activation key to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/privateClouds/my-cloud/hcxActivationKeys/my-key` + * Please see {@see VmwareEngineClient::hcxActivationKeyName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\GetHcxActivationKeyRequest + * + * @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 HCX activation key to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/privateClouds/my-cloud/hcxActivationKeys/my-key` + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the HCX activation key to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/privateClouds/my-cloud/hcxActivationKeys/my-key` + * + * 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 HCX activation key to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/privateClouds/my-cloud/hcxActivationKeys/my-key` + * + * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetLoggingServerRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetLoggingServerRequest.php new file mode 100644 index 000000000000..50f13b0de8a5 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetLoggingServerRequest.php @@ -0,0 +1,102 @@ +google.cloud.vmwareengine.v1.GetLoggingServerRequest + */ +class GetLoggingServerRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the Logging Server to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/loggingServers/my-logging-server` + * + * 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 Logging Server to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/loggingServers/my-logging-server` + * Please see {@see VmwareEngineClient::loggingServerName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\GetLoggingServerRequest + * + * @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 Logging Server to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/loggingServers/my-logging-server` + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the Logging Server to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/loggingServers/my-logging-server` + * + * 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 Logging Server to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/loggingServers/my-logging-server` + * + * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetManagementDnsZoneBindingRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetManagementDnsZoneBindingRequest.php new file mode 100644 index 000000000000..c4be8a09029d --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetManagementDnsZoneBindingRequest.php @@ -0,0 +1,102 @@ +google.cloud.vmwareengine.v1.GetManagementDnsZoneBindingRequest + */ +class GetManagementDnsZoneBindingRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the management DNS zone binding to + * retrieve. Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/managementDnsZoneBindings/my-management-dns-zone-binding` + * + * 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 management DNS zone binding to + * retrieve. Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/managementDnsZoneBindings/my-management-dns-zone-binding` + * Please see {@see VmwareEngineClient::managementDnsZoneBindingName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\GetManagementDnsZoneBindingRequest + * + * @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 management DNS zone binding to + * retrieve. Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/managementDnsZoneBindings/my-management-dns-zone-binding` + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the management DNS zone binding to + * retrieve. Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/managementDnsZoneBindings/my-management-dns-zone-binding` + * + * 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 management DNS zone binding to + * retrieve. Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/managementDnsZoneBindings/my-management-dns-zone-binding` + * + * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetNetworkPeeringRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetNetworkPeeringRequest.php new file mode 100644 index 000000000000..0024412b3c9c --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetNetworkPeeringRequest.php @@ -0,0 +1,102 @@ +google.cloud.vmwareengine.v1.GetNetworkPeeringRequest + */ +class GetNetworkPeeringRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the network peering to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/global/networkPeerings/my-peering` + * + * 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 network peering to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/global/networkPeerings/my-peering` + * Please see {@see VmwareEngineClient::networkPeeringName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\GetNetworkPeeringRequest + * + * @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 network peering to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/global/networkPeerings/my-peering` + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the network peering to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/global/networkPeerings/my-peering` + * + * 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 network peering to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/global/networkPeerings/my-peering` + * + * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetNetworkPolicyRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetNetworkPolicyRequest.php new file mode 100644 index 000000000000..5d9ef4f3c147 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetNetworkPolicyRequest.php @@ -0,0 +1,102 @@ +google.cloud.vmwareengine.v1.GetNetworkPolicyRequest + */ +class GetNetworkPolicyRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the network policy to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/networkPolicies/my-network-policy` + * + * 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 network policy to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/networkPolicies/my-network-policy` + * Please see {@see VmwareEngineClient::networkPolicyName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\GetNetworkPolicyRequest + * + * @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 network policy to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/networkPolicies/my-network-policy` + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the network policy to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/networkPolicies/my-network-policy` + * + * 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 network policy to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/networkPolicies/my-network-policy` + * + * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetNodeRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetNodeRequest.php new file mode 100644 index 000000000000..a44732cfde7c --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetNodeRequest.php @@ -0,0 +1,92 @@ +google.cloud.vmwareengine.v1.GetNodeRequest + */ +class GetNodeRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the node to retrieve. + * For example: + * `projects/{project}/locations/{location}/privateClouds/{private_cloud}/clusters/{cluster}/nodes/{node}` + * + * 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 node to retrieve. + * For example: + * `projects/{project}/locations/{location}/privateClouds/{private_cloud}/clusters/{cluster}/nodes/{node}` + * Please see {@see VmwareEngineClient::nodeName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\GetNodeRequest + * + * @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 node to retrieve. + * For example: + * `projects/{project}/locations/{location}/privateClouds/{private_cloud}/clusters/{cluster}/nodes/{node}` + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the node to retrieve. + * For example: + * `projects/{project}/locations/{location}/privateClouds/{private_cloud}/clusters/{cluster}/nodes/{node}` + * + * 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 node to retrieve. + * For example: + * `projects/{project}/locations/{location}/privateClouds/{private_cloud}/clusters/{cluster}/nodes/{node}` + * + * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetNodeTypeRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetNodeTypeRequest.php new file mode 100644 index 000000000000..f50cf89a2e16 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetNodeTypeRequest.php @@ -0,0 +1,102 @@ +google.cloud.vmwareengine.v1.GetNodeTypeRequest + */ +class GetNodeTypeRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the node type to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-proj/locations/us-central1-a/nodeTypes/standard-72` + * + * 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 node type to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-proj/locations/us-central1-a/nodeTypes/standard-72` + * Please see {@see VmwareEngineClient::nodeTypeName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\GetNodeTypeRequest + * + * @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 node type to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-proj/locations/us-central1-a/nodeTypes/standard-72` + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the node type to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-proj/locations/us-central1-a/nodeTypes/standard-72` + * + * 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 node type to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-proj/locations/us-central1-a/nodeTypes/standard-72` + * + * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetPrivateCloudRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetPrivateCloudRequest.php new file mode 100644 index 000000000000..dc71556ca70c --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetPrivateCloudRequest.php @@ -0,0 +1,102 @@ +google.cloud.vmwareengine.v1.GetPrivateCloudRequest + */ +class GetPrivateCloudRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the private cloud to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * 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 private cloud to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * Please see {@see VmwareEngineClient::privateCloudName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\GetPrivateCloudRequest + * + * @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 private cloud to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the private cloud to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * 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 private cloud to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetPrivateConnectionRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetPrivateConnectionRequest.php new file mode 100644 index 000000000000..74cdaca7d052 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetPrivateConnectionRequest.php @@ -0,0 +1,102 @@ +google.cloud.vmwareengine.v1.GetPrivateConnectionRequest + */ +class GetPrivateConnectionRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the private connection to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/privateConnections/my-connection` + * + * 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 private connection to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/privateConnections/my-connection` + * Please see {@see VmwareEngineClient::privateConnectionName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\GetPrivateConnectionRequest + * + * @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 private connection to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/privateConnections/my-connection` + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the private connection to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/privateConnections/my-connection` + * + * 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 private connection to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/privateConnections/my-connection` + * + * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetSubnetRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetSubnetRequest.php new file mode 100644 index 000000000000..24616dbc5328 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetSubnetRequest.php @@ -0,0 +1,102 @@ +google.cloud.vmwareengine.v1.GetSubnetRequest + */ +class GetSubnetRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the subnet to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/subnets/my-subnet` + * + * 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 subnet to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/subnets/my-subnet` + * Please see {@see VmwareEngineClient::subnetName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\GetSubnetRequest + * + * @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 subnet to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/subnets/my-subnet` + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the subnet to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/subnets/my-subnet` + * + * 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 subnet to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/subnets/my-subnet` + * + * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetVmwareEngineNetworkRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetVmwareEngineNetworkRequest.php new file mode 100644 index 000000000000..fe7249832e5e --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetVmwareEngineNetworkRequest.php @@ -0,0 +1,102 @@ +google.cloud.vmwareengine.v1.GetVmwareEngineNetworkRequest + */ +class GetVmwareEngineNetworkRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the VMware Engine network to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/global/vmwareEngineNetworks/my-network` + * + * 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 VMware Engine network to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/global/vmwareEngineNetworks/my-network` + * Please see {@see VmwareEngineClient::vmwareEngineNetworkName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\GetVmwareEngineNetworkRequest + * + * @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 VMware Engine network to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/global/vmwareEngineNetworks/my-network` + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the VMware Engine network to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/global/vmwareEngineNetworks/my-network` + * + * 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 VMware Engine network to retrieve. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/global/vmwareEngineNetworks/my-network` + * + * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GrantDnsBindPermissionRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GrantDnsBindPermissionRequest.php new file mode 100644 index 000000000000..53afee6055af --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GrantDnsBindPermissionRequest.php @@ -0,0 +1,241 @@ +google.cloud.vmwareengine.v1.GrantDnsBindPermissionRequest + */ +class GrantDnsBindPermissionRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the resource which stores the users/service accounts + * having the permission to bind to the corresponding intranet VPC of the + * consumer project. DnsBindPermission is a global resource. Resource names + * are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. For example: + * `projects/my-project/locations/global/dnsBindPermission` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * Required. The consumer provided user/service account which needs to be + * granted permission to bind with the intranet VPC corresponding to the + * consumer project. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.Principal principal = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $principal = null; + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $request_id = ''; + + /** + * @param string $name Required. The name of the resource which stores the users/service accounts + * having the permission to bind to the corresponding intranet VPC of the + * consumer project. DnsBindPermission is a global resource. Resource names + * are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. For example: + * `projects/my-project/locations/global/dnsBindPermission` + * Please see {@see VmwareEngineClient::dnsBindPermissionName()} for help formatting this field. + * @param \Google\Cloud\VmwareEngine\V1\Principal $principal Required. The consumer provided user/service account which needs to be + * granted permission to bind with the intranet VPC corresponding to the + * consumer project. + * + * @return \Google\Cloud\VmwareEngine\V1\GrantDnsBindPermissionRequest + * + * @experimental + */ + public static function build(string $name, \Google\Cloud\VmwareEngine\V1\Principal $principal): self + { + return (new self()) + ->setName($name) + ->setPrincipal($principal); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. The name of the resource which stores the users/service accounts + * having the permission to bind to the corresponding intranet VPC of the + * consumer project. DnsBindPermission is a global resource. Resource names + * are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. For example: + * `projects/my-project/locations/global/dnsBindPermission` + * @type \Google\Cloud\VmwareEngine\V1\Principal $principal + * Required. The consumer provided user/service account which needs to be + * granted permission to bind with the intranet VPC corresponding to the + * consumer project. + * @type string $request_id + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the resource which stores the users/service accounts + * having the permission to bind to the corresponding intranet VPC of the + * consumer project. DnsBindPermission is a global resource. Resource names + * are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. For example: + * `projects/my-project/locations/global/dnsBindPermission` + * + * 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 resource which stores the users/service accounts + * having the permission to bind to the corresponding intranet VPC of the + * consumer project. DnsBindPermission is a global resource. Resource names + * are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. For example: + * `projects/my-project/locations/global/dnsBindPermission` + * + * 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 consumer provided user/service account which needs to be + * granted permission to bind with the intranet VPC corresponding to the + * consumer project. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.Principal principal = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\VmwareEngine\V1\Principal|null + */ + public function getPrincipal() + { + return $this->principal; + } + + public function hasPrincipal() + { + return isset($this->principal); + } + + public function clearPrincipal() + { + unset($this->principal); + } + + /** + * Required. The consumer provided user/service account which needs to be + * granted permission to bind with the intranet VPC corresponding to the + * consumer project. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.Principal principal = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\VmwareEngine\V1\Principal $var + * @return $this + */ + public function setPrincipal($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\Principal::class); + $this->principal = $var; + + return $this; + } + + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getRequestId() + { + return $this->request_id; + } + + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 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; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Hcx.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Hcx.php new file mode 100644 index 000000000000..216f6bd75705 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Hcx.php @@ -0,0 +1,169 @@ +google.cloud.vmwareengine.v1.Hcx + */ +class Hcx extends \Google\Protobuf\Internal\Message +{ + /** + * Internal IP address of the appliance. + * + * Generated from protobuf field string internal_ip = 2; + */ + protected $internal_ip = ''; + /** + * Version of the appliance. + * + * Generated from protobuf field string version = 4; + */ + protected $version = ''; + /** + * Output only. The state of the appliance. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.Hcx.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $state = 0; + /** + * Fully qualified domain name of the appliance. + * + * Generated from protobuf field string fqdn = 6; + */ + protected $fqdn = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $internal_ip + * Internal IP address of the appliance. + * @type string $version + * Version of the appliance. + * @type int $state + * Output only. The state of the appliance. + * @type string $fqdn + * Fully qualified domain name of the appliance. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); + parent::__construct($data); + } + + /** + * Internal IP address of the appliance. + * + * Generated from protobuf field string internal_ip = 2; + * @return string + */ + public function getInternalIp() + { + return $this->internal_ip; + } + + /** + * Internal IP address of the appliance. + * + * Generated from protobuf field string internal_ip = 2; + * @param string $var + * @return $this + */ + public function setInternalIp($var) + { + GPBUtil::checkString($var, True); + $this->internal_ip = $var; + + return $this; + } + + /** + * Version of the appliance. + * + * Generated from protobuf field string version = 4; + * @return string + */ + public function getVersion() + { + return $this->version; + } + + /** + * Version of the appliance. + * + * Generated from protobuf field string version = 4; + * @param string $var + * @return $this + */ + public function setVersion($var) + { + GPBUtil::checkString($var, True); + $this->version = $var; + + return $this; + } + + /** + * Output only. The state of the appliance. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.Hcx.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getState() + { + return $this->state; + } + + /** + * Output only. The state of the appliance. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.Hcx.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setState($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\Hcx\State::class); + $this->state = $var; + + return $this; + } + + /** + * Fully qualified domain name of the appliance. + * + * Generated from protobuf field string fqdn = 6; + * @return string + */ + public function getFqdn() + { + return $this->fqdn; + } + + /** + * Fully qualified domain name of the appliance. + * + * Generated from protobuf field string fqdn = 6; + * @param string $var + * @return $this + */ + public function setFqdn($var) + { + GPBUtil::checkString($var, True); + $this->fqdn = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Hcx/State.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Hcx/State.php new file mode 100644 index 000000000000..9d4ab1c43fcf --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Hcx/State.php @@ -0,0 +1,68 @@ +google.cloud.vmwareengine.v1.Hcx.State + */ +class State +{ + /** + * Unspecified appliance state. This is the default value. + * + * Generated from protobuf enum STATE_UNSPECIFIED = 0; + */ + const STATE_UNSPECIFIED = 0; + /** + * The appliance is operational and can be used. + * + * Generated from protobuf enum ACTIVE = 1; + */ + const ACTIVE = 1; + /** + * The appliance is being deployed. + * + * Generated from protobuf enum CREATING = 2; + */ + const CREATING = 2; + /** + * The appliance is being activated. + * + * Generated from protobuf enum ACTIVATING = 3; + */ + const ACTIVATING = 3; + + private static $valueToName = [ + self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', + self::ACTIVE => 'ACTIVE', + self::CREATING => 'CREATING', + self::ACTIVATING => 'ACTIVATING', + ]; + + 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/HcxActivationKey.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/HcxActivationKey.php new file mode 100644 index 000000000000..47e60f1b70d9 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/HcxActivationKey.php @@ -0,0 +1,236 @@ +google.cloud.vmwareengine.v1.HcxActivationKey + */ +class HcxActivationKey extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. The resource name of this HcxActivationKey. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/privateClouds/my-cloud/hcxActivationKeys/my-key` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $name = ''; + /** + * Output only. Creation time of HCX activation key. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $create_time = null; + /** + * Output only. State of HCX activation key. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.HcxActivationKey.State state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $state = 0; + /** + * Output only. HCX activation key. + * + * Generated from protobuf field string activation_key = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $activation_key = ''; + /** + * Output only. System-generated unique identifier for the resource. + * + * Generated from protobuf field string uid = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $uid = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Output only. The resource name of this HcxActivationKey. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/privateClouds/my-cloud/hcxActivationKeys/my-key` + * @type \Google\Protobuf\Timestamp $create_time + * Output only. Creation time of HCX activation key. + * @type int $state + * Output only. State of HCX activation key. + * @type string $activation_key + * Output only. HCX activation key. + * @type string $uid + * Output only. System-generated unique identifier for the resource. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); + parent::__construct($data); + } + + /** + * Output only. The resource name of this HcxActivationKey. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/privateClouds/my-cloud/hcxActivationKeys/my-key` + * + * 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 HcxActivationKey. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/privateClouds/my-cloud/hcxActivationKeys/my-key` + * + * 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. Creation time of HCX activation key. + * + * 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 time of HCX activation key. + * + * 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. State of HCX activation key. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.HcxActivationKey.State state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getState() + { + return $this->state; + } + + /** + * Output only. State of HCX activation key. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.HcxActivationKey.State state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setState($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\HcxActivationKey\State::class); + $this->state = $var; + + return $this; + } + + /** + * Output only. HCX activation key. + * + * Generated from protobuf field string activation_key = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getActivationKey() + { + return $this->activation_key; + } + + /** + * Output only. HCX activation key. + * + * Generated from protobuf field string activation_key = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setActivationKey($var) + { + GPBUtil::checkString($var, True); + $this->activation_key = $var; + + return $this; + } + + /** + * Output only. System-generated unique identifier for the resource. + * + * Generated from protobuf field string uid = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getUid() + { + return $this->uid; + } + + /** + * Output only. System-generated unique identifier for the resource. + * + * 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; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/HcxActivationKey/State.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/HcxActivationKey/State.php new file mode 100644 index 000000000000..78ed39482bb2 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/HcxActivationKey/State.php @@ -0,0 +1,68 @@ +google.cloud.vmwareengine.v1.HcxActivationKey.State + */ +class State +{ + /** + * Unspecified state. + * + * Generated from protobuf enum STATE_UNSPECIFIED = 0; + */ + const STATE_UNSPECIFIED = 0; + /** + * State of a newly generated activation key. + * + * Generated from protobuf enum AVAILABLE = 1; + */ + const AVAILABLE = 1; + /** + * State of key when it has been used to activate HCX appliance. + * + * Generated from protobuf enum CONSUMED = 2; + */ + const CONSUMED = 2; + /** + * State of key when it is being created. + * + * Generated from protobuf enum CREATING = 3; + */ + const CREATING = 3; + + private static $valueToName = [ + self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', + self::AVAILABLE => 'AVAILABLE', + self::CONSUMED => 'CONSUMED', + self::CREATING => 'CREATING', + ]; + + 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListClustersRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListClustersRequest.php new file mode 100644 index 000000000000..0436f6a8eefb --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListClustersRequest.php @@ -0,0 +1,322 @@ +google.cloud.vmwareengine.v1.ListClustersRequest + */ +class ListClustersRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the private cloud to query for clusters. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * The maximum number of clusters to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * Generated from protobuf field int32 page_size = 2; + */ + protected $page_size = 0; + /** + * A page token, received from a previous `ListClusters` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to `ListClusters` + * must match the call that provided the page token. + * + * Generated from protobuf field string page_token = 3; + */ + protected $page_token = ''; + /** + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "example-cluster") + * (nodeCount = "3") + * ``` + * By default, each expression is an `AND` expression. However, you can + * include `AND` and `OR` expressions explicitly. For example: + * ``` + * (name = "example-cluster-1") AND + * (createTime > "2021-04-12T08:15:10.40Z") OR + * (name = "example-cluster-2") + * ``` + * + * Generated from protobuf field string filter = 4; + */ + protected $filter = ''; + /** + * Sorts list results by a certain order. By default, returned results are + * ordered by `name` in ascending order. You can also sort results in + * descending order based on the `name` value using `orderBy="name desc"`. + * Currently, only ordering by `name` is supported. + * + * Generated from protobuf field string order_by = 5; + */ + protected $order_by = ''; + + /** + * @param string $parent Required. The resource name of the private cloud to query for clusters. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * Please see {@see VmwareEngineClient::privateCloudName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\ListClustersRequest + * + * @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 private cloud to query for clusters. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * @type int $page_size + * The maximum number of clusters to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * @type string $page_token + * A page token, received from a previous `ListClusters` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to `ListClusters` + * must match the call that provided the page token. + * @type string $filter + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "example-cluster") + * (nodeCount = "3") + * ``` + * By default, each expression is an `AND` expression. However, you can + * include `AND` and `OR` expressions explicitly. For example: + * ``` + * (name = "example-cluster-1") AND + * (createTime > "2021-04-12T08:15:10.40Z") OR + * (name = "example-cluster-2") + * ``` + * @type string $order_by + * Sorts list results by a certain order. By default, returned results are + * ordered by `name` in ascending order. You can also sort results in + * descending order based on the `name` value using `orderBy="name desc"`. + * Currently, only ordering by `name` is supported. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the private cloud to query for clusters. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * 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 private cloud to query for clusters. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * 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 clusters to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * Generated from protobuf field int32 page_size = 2; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of clusters to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * 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 `ListClusters` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to `ListClusters` + * 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 `ListClusters` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to `ListClusters` + * 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; + } + + /** + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "example-cluster") + * (nodeCount = "3") + * ``` + * By default, each expression is an `AND` expression. However, you can + * include `AND` and `OR` expressions explicitly. For example: + * ``` + * (name = "example-cluster-1") AND + * (createTime > "2021-04-12T08:15:10.40Z") OR + * (name = "example-cluster-2") + * ``` + * + * Generated from protobuf field string filter = 4; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "example-cluster") + * (nodeCount = "3") + * ``` + * By default, each expression is an `AND` expression. However, you can + * include `AND` and `OR` expressions explicitly. For example: + * ``` + * (name = "example-cluster-1") AND + * (createTime > "2021-04-12T08:15:10.40Z") OR + * (name = "example-cluster-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; + } + + /** + * Sorts list results by a certain order. By default, returned results are + * ordered by `name` in ascending order. You can also sort results in + * descending order based on the `name` value using `orderBy="name desc"`. + * Currently, only ordering by `name` is supported. + * + * Generated from protobuf field string order_by = 5; + * @return string + */ + public function getOrderBy() + { + return $this->order_by; + } + + /** + * Sorts list results by a certain order. By default, returned results are + * ordered by `name` in ascending order. You can also sort results in + * descending order based on the `name` value using `orderBy="name desc"`. + * Currently, only ordering by `name` is supported. + * + * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListClustersResponse.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListClustersResponse.php new file mode 100644 index 000000000000..89c4a4a3bf5c --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListClustersResponse.php @@ -0,0 +1,144 @@ +google.cloud.vmwareengine.v1.ListClustersResponse + */ +class ListClustersResponse extends \Google\Protobuf\Internal\Message +{ + /** + * A list of private cloud clusters. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.Cluster clusters = 1; + */ + private $clusters; + /** + * 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 = ''; + /** + * Locations that could not be reached when making an aggregated query using + * wildcards. + * + * Generated from protobuf field repeated string unreachable = 3; + */ + private $unreachable; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\VmwareEngine\V1\Cluster[] $clusters + * A list of private cloud clusters. + * @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. + * @type string[] $unreachable + * Locations that could not be reached when making an aggregated query using + * wildcards. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * A list of private cloud clusters. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.Cluster clusters = 1; + * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\Cluster> + */ + public function getClusters() + { + return $this->clusters; + } + + /** + * A list of private cloud clusters. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.Cluster clusters = 1; + * @param \Google\Cloud\VmwareEngine\V1\Cluster[] $var + * @return $this + */ + public function setClusters($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\Cluster::class); + $this->clusters = $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; + } + + /** + * Locations that could not be reached when making an aggregated query using + * wildcards. + * + * Generated from protobuf field repeated string unreachable = 3; + * @return RepeatedField + */ + public function getUnreachable() + { + return $this->unreachable; + } + + /** + * Locations that could not be reached when making an aggregated query using + * wildcards. + * + * Generated from protobuf field repeated string unreachable = 3; + * @param string[] $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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListExternalAccessRulesRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListExternalAccessRulesRequest.php new file mode 100644 index 000000000000..8604d8f65081 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListExternalAccessRulesRequest.php @@ -0,0 +1,366 @@ +google.cloud.vmwareengine.v1.ListExternalAccessRulesRequest + */ +class ListExternalAccessRulesRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the network policy to query for external + * access firewall rules. Resource names are schemeless URIs that follow the + * conventions in https://cloud.google.com/apis/design/resource_names. For + * example: + * `projects/my-project/locations/us-central1/networkPolicies/my-policy` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * The maximum number of external access rules to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * Generated from protobuf field int32 page_size = 2; + */ + protected $page_size = 0; + /** + * A page token, received from a previous `ListExternalAccessRulesRequest` + * call. Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListExternalAccessRulesRequest` must match the call that provided the page + * token. + * + * Generated from protobuf field string page_token = 3; + */ + protected $page_token = ''; + /** + * A filter expression that matches resources returned in the response. + * The expression must specify the field name, a comparison + * operator, and the value that you want to use for filtering. The value + * must be a string, a number, or a boolean. The comparison operator + * must be `=`, `!=`, `>`, or `<`. + * For example, if you are filtering a list of external access rules, you can + * exclude the ones named `example-rule` by specifying + * `name != "example-rule"`. + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "example-rule") + * (createTime > "2021-04-12T08:15:10.40Z") + * ``` + * By default, each expression is an `AND` expression. However, you + * can include `AND` and `OR` expressions explicitly. + * For example: + * ``` + * (name = "example-rule-1") AND + * (createTime > "2021-04-12T08:15:10.40Z") OR + * (name = "example-rule-2") + * ``` + * + * Generated from protobuf field string filter = 4; + */ + protected $filter = ''; + /** + * Sorts list results by a certain order. By default, returned results + * are ordered by `name` in ascending order. + * You can also sort results in descending order based on the `name` value + * using `orderBy="name desc"`. + * Currently, only ordering by `name` is supported. + * + * Generated from protobuf field string order_by = 5; + */ + protected $order_by = ''; + + /** + * @param string $parent Required. The resource name of the network policy to query for external + * access firewall rules. Resource names are schemeless URIs that follow the + * conventions in https://cloud.google.com/apis/design/resource_names. For + * example: + * `projects/my-project/locations/us-central1/networkPolicies/my-policy` + * Please see {@see VmwareEngineClient::networkPolicyName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\ListExternalAccessRulesRequest + * + * @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 network policy to query for external + * access firewall rules. Resource names are schemeless URIs that follow the + * conventions in https://cloud.google.com/apis/design/resource_names. For + * example: + * `projects/my-project/locations/us-central1/networkPolicies/my-policy` + * @type int $page_size + * The maximum number of external access rules to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * @type string $page_token + * A page token, received from a previous `ListExternalAccessRulesRequest` + * call. Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListExternalAccessRulesRequest` must match the call that provided the page + * token. + * @type string $filter + * A filter expression that matches resources returned in the response. + * The expression must specify the field name, a comparison + * operator, and the value that you want to use for filtering. The value + * must be a string, a number, or a boolean. The comparison operator + * must be `=`, `!=`, `>`, or `<`. + * For example, if you are filtering a list of external access rules, you can + * exclude the ones named `example-rule` by specifying + * `name != "example-rule"`. + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "example-rule") + * (createTime > "2021-04-12T08:15:10.40Z") + * ``` + * By default, each expression is an `AND` expression. However, you + * can include `AND` and `OR` expressions explicitly. + * For example: + * ``` + * (name = "example-rule-1") AND + * (createTime > "2021-04-12T08:15:10.40Z") OR + * (name = "example-rule-2") + * ``` + * @type string $order_by + * Sorts list results by a certain order. By default, returned results + * are ordered by `name` in ascending order. + * You can also sort results in descending order based on the `name` value + * using `orderBy="name desc"`. + * Currently, only ordering by `name` is supported. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the network policy to query for external + * access firewall rules. Resource names are schemeless URIs that follow the + * conventions in https://cloud.google.com/apis/design/resource_names. For + * example: + * `projects/my-project/locations/us-central1/networkPolicies/my-policy` + * + * 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 network policy to query for external + * access firewall rules. Resource names are schemeless URIs that follow the + * conventions in https://cloud.google.com/apis/design/resource_names. For + * example: + * `projects/my-project/locations/us-central1/networkPolicies/my-policy` + * + * 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 external access rules to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * Generated from protobuf field int32 page_size = 2; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of external access rules to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * 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 `ListExternalAccessRulesRequest` + * call. Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListExternalAccessRulesRequest` 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 `ListExternalAccessRulesRequest` + * call. Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListExternalAccessRulesRequest` 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; + } + + /** + * A filter expression that matches resources returned in the response. + * The expression must specify the field name, a comparison + * operator, and the value that you want to use for filtering. The value + * must be a string, a number, or a boolean. The comparison operator + * must be `=`, `!=`, `>`, or `<`. + * For example, if you are filtering a list of external access rules, you can + * exclude the ones named `example-rule` by specifying + * `name != "example-rule"`. + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "example-rule") + * (createTime > "2021-04-12T08:15:10.40Z") + * ``` + * By default, each expression is an `AND` expression. However, you + * can include `AND` and `OR` expressions explicitly. + * For example: + * ``` + * (name = "example-rule-1") AND + * (createTime > "2021-04-12T08:15:10.40Z") OR + * (name = "example-rule-2") + * ``` + * + * Generated from protobuf field string filter = 4; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * A filter expression that matches resources returned in the response. + * The expression must specify the field name, a comparison + * operator, and the value that you want to use for filtering. The value + * must be a string, a number, or a boolean. The comparison operator + * must be `=`, `!=`, `>`, or `<`. + * For example, if you are filtering a list of external access rules, you can + * exclude the ones named `example-rule` by specifying + * `name != "example-rule"`. + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "example-rule") + * (createTime > "2021-04-12T08:15:10.40Z") + * ``` + * By default, each expression is an `AND` expression. However, you + * can include `AND` and `OR` expressions explicitly. + * For example: + * ``` + * (name = "example-rule-1") AND + * (createTime > "2021-04-12T08:15:10.40Z") OR + * (name = "example-rule-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; + } + + /** + * Sorts list results by a certain order. By default, returned results + * are ordered by `name` in ascending order. + * You can also sort results in descending order based on the `name` value + * using `orderBy="name desc"`. + * Currently, only ordering by `name` is supported. + * + * Generated from protobuf field string order_by = 5; + * @return string + */ + public function getOrderBy() + { + return $this->order_by; + } + + /** + * Sorts list results by a certain order. By default, returned results + * are ordered by `name` in ascending order. + * You can also sort results in descending order based on the `name` value + * using `orderBy="name desc"`. + * Currently, only ordering by `name` is supported. + * + * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListExternalAccessRulesResponse.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListExternalAccessRulesResponse.php new file mode 100644 index 000000000000..453140127c84 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListExternalAccessRulesResponse.php @@ -0,0 +1,144 @@ +google.cloud.vmwareengine.v1.ListExternalAccessRulesResponse + */ +class ListExternalAccessRulesResponse extends \Google\Protobuf\Internal\Message +{ + /** + * A list of external access firewall rules. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.ExternalAccessRule external_access_rules = 1; + */ + private $external_access_rules; + /** + * 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 = ''; + /** + * Locations that could not be reached when making an aggregated query using + * wildcards. + * + * Generated from protobuf field repeated string unreachable = 3; + */ + private $unreachable; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\VmwareEngine\V1\ExternalAccessRule[] $external_access_rules + * A list of external access firewall rules. + * @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. + * @type string[] $unreachable + * Locations that could not be reached when making an aggregated query using + * wildcards. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * A list of external access firewall rules. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.ExternalAccessRule external_access_rules = 1; + * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\ExternalAccessRule> + */ + public function getExternalAccessRules() + { + return $this->external_access_rules; + } + + /** + * A list of external access firewall rules. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.ExternalAccessRule external_access_rules = 1; + * @param \Google\Cloud\VmwareEngine\V1\ExternalAccessRule[] $var + * @return $this + */ + public function setExternalAccessRules($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\ExternalAccessRule::class); + $this->external_access_rules = $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; + } + + /** + * Locations that could not be reached when making an aggregated query using + * wildcards. + * + * Generated from protobuf field repeated string unreachable = 3; + * @return RepeatedField + */ + public function getUnreachable() + { + return $this->unreachable; + } + + /** + * Locations that could not be reached when making an aggregated query using + * wildcards. + * + * Generated from protobuf field repeated string unreachable = 3; + * @param string[] $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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListExternalAddressesRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListExternalAddressesRequest.php new file mode 100644 index 000000000000..830b551193b8 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListExternalAddressesRequest.php @@ -0,0 +1,367 @@ +google.cloud.vmwareengine.v1.ListExternalAddressesRequest + */ +class ListExternalAddressesRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the private cloud to be queried for + * external IP addresses. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * The maximum number of external IP addresses to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * Generated from protobuf field int32 page_size = 2; + */ + protected $page_size = 0; + /** + * A page token, received from a previous `ListExternalAddresses` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListExternalAddresses` must match the call that provided the page token. + * + * Generated from protobuf field string page_token = 3; + */ + protected $page_token = ''; + /** + * A filter expression that matches resources returned in the response. + * The expression must specify the field name, a comparison + * operator, and the value that you want to use for filtering. The value + * must be a string, a number, or a boolean. The comparison operator + * must be `=`, `!=`, `>`, or `<`. + * For example, if you are filtering a list of IP addresses, you can + * exclude the ones named `example-ip` by specifying + * `name != "example-ip"`. + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "example-ip") + * (createTime > "2021-04-12T08:15:10.40Z") + * ``` + * By default, each expression is an `AND` expression. However, you + * can include `AND` and `OR` expressions explicitly. + * For example: + * ``` + * (name = "example-ip-1") AND + * (createTime > "2021-04-12T08:15:10.40Z") OR + * (name = "example-ip-2") + * ``` + * + * Generated from protobuf field string filter = 4; + */ + protected $filter = ''; + /** + * Sorts list results by a certain order. By default, returned results + * are ordered by `name` in ascending order. + * You can also sort results in descending order based on the `name` value + * using `orderBy="name desc"`. + * Currently, only ordering by `name` is supported. + * + * Generated from protobuf field string order_by = 5; + */ + protected $order_by = ''; + + /** + * @param string $parent Required. The resource name of the private cloud to be queried for + * external IP addresses. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * Please see {@see VmwareEngineClient::privateCloudName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\ListExternalAddressesRequest + * + * @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 private cloud to be queried for + * external IP addresses. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * @type int $page_size + * The maximum number of external IP addresses to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * @type string $page_token + * A page token, received from a previous `ListExternalAddresses` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListExternalAddresses` must match the call that provided the page token. + * @type string $filter + * A filter expression that matches resources returned in the response. + * The expression must specify the field name, a comparison + * operator, and the value that you want to use for filtering. The value + * must be a string, a number, or a boolean. The comparison operator + * must be `=`, `!=`, `>`, or `<`. + * For example, if you are filtering a list of IP addresses, you can + * exclude the ones named `example-ip` by specifying + * `name != "example-ip"`. + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "example-ip") + * (createTime > "2021-04-12T08:15:10.40Z") + * ``` + * By default, each expression is an `AND` expression. However, you + * can include `AND` and `OR` expressions explicitly. + * For example: + * ``` + * (name = "example-ip-1") AND + * (createTime > "2021-04-12T08:15:10.40Z") OR + * (name = "example-ip-2") + * ``` + * @type string $order_by + * Sorts list results by a certain order. By default, returned results + * are ordered by `name` in ascending order. + * You can also sort results in descending order based on the `name` value + * using `orderBy="name desc"`. + * Currently, only ordering by `name` is supported. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the private cloud to be queried for + * external IP addresses. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * 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 private cloud to be queried for + * external IP addresses. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * 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 external IP addresses to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * Generated from protobuf field int32 page_size = 2; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of external IP addresses to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * 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 `ListExternalAddresses` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListExternalAddresses` 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 `ListExternalAddresses` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListExternalAddresses` 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; + } + + /** + * A filter expression that matches resources returned in the response. + * The expression must specify the field name, a comparison + * operator, and the value that you want to use for filtering. The value + * must be a string, a number, or a boolean. The comparison operator + * must be `=`, `!=`, `>`, or `<`. + * For example, if you are filtering a list of IP addresses, you can + * exclude the ones named `example-ip` by specifying + * `name != "example-ip"`. + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "example-ip") + * (createTime > "2021-04-12T08:15:10.40Z") + * ``` + * By default, each expression is an `AND` expression. However, you + * can include `AND` and `OR` expressions explicitly. + * For example: + * ``` + * (name = "example-ip-1") AND + * (createTime > "2021-04-12T08:15:10.40Z") OR + * (name = "example-ip-2") + * ``` + * + * Generated from protobuf field string filter = 4; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * A filter expression that matches resources returned in the response. + * The expression must specify the field name, a comparison + * operator, and the value that you want to use for filtering. The value + * must be a string, a number, or a boolean. The comparison operator + * must be `=`, `!=`, `>`, or `<`. + * For example, if you are filtering a list of IP addresses, you can + * exclude the ones named `example-ip` by specifying + * `name != "example-ip"`. + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "example-ip") + * (createTime > "2021-04-12T08:15:10.40Z") + * ``` + * By default, each expression is an `AND` expression. However, you + * can include `AND` and `OR` expressions explicitly. + * For example: + * ``` + * (name = "example-ip-1") AND + * (createTime > "2021-04-12T08:15:10.40Z") OR + * (name = "example-ip-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; + } + + /** + * Sorts list results by a certain order. By default, returned results + * are ordered by `name` in ascending order. + * You can also sort results in descending order based on the `name` value + * using `orderBy="name desc"`. + * Currently, only ordering by `name` is supported. + * + * Generated from protobuf field string order_by = 5; + * @return string + */ + public function getOrderBy() + { + return $this->order_by; + } + + /** + * Sorts list results by a certain order. By default, returned results + * are ordered by `name` in ascending order. + * You can also sort results in descending order based on the `name` value + * using `orderBy="name desc"`. + * Currently, only ordering by `name` is supported. + * + * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListExternalAddressesResponse.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListExternalAddressesResponse.php new file mode 100644 index 000000000000..d6c7fe19077a --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListExternalAddressesResponse.php @@ -0,0 +1,144 @@ +google.cloud.vmwareengine.v1.ListExternalAddressesResponse + */ +class ListExternalAddressesResponse extends \Google\Protobuf\Internal\Message +{ + /** + * A list of external IP addresses. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.ExternalAddress external_addresses = 1; + */ + private $external_addresses; + /** + * 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 = ''; + /** + * Locations that could not be reached when making an aggregated query using + * wildcards. + * + * Generated from protobuf field repeated string unreachable = 3; + */ + private $unreachable; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\VmwareEngine\V1\ExternalAddress[] $external_addresses + * A list of external IP addresses. + * @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. + * @type string[] $unreachable + * Locations that could not be reached when making an aggregated query using + * wildcards. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * A list of external IP addresses. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.ExternalAddress external_addresses = 1; + * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\ExternalAddress> + */ + public function getExternalAddresses() + { + return $this->external_addresses; + } + + /** + * A list of external IP addresses. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.ExternalAddress external_addresses = 1; + * @param \Google\Cloud\VmwareEngine\V1\ExternalAddress[] $var + * @return $this + */ + public function setExternalAddresses($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\ExternalAddress::class); + $this->external_addresses = $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; + } + + /** + * Locations that could not be reached when making an aggregated query using + * wildcards. + * + * Generated from protobuf field repeated string unreachable = 3; + * @return RepeatedField + */ + public function getUnreachable() + { + return $this->unreachable; + } + + /** + * Locations that could not be reached when making an aggregated query using + * wildcards. + * + * Generated from protobuf field repeated string unreachable = 3; + * @param string[] $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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListHcxActivationKeysRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListHcxActivationKeysRequest.php new file mode 100644 index 000000000000..ba3606cd0322 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListHcxActivationKeysRequest.php @@ -0,0 +1,203 @@ +google.cloud.vmwareengine.v1.ListHcxActivationKeysRequest + */ +class ListHcxActivationKeysRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the private cloud + * to be queried for HCX activation keys. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/privateClouds/my-cloud` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * The maximum number of HCX activation keys to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * Generated from protobuf field int32 page_size = 2; + */ + protected $page_size = 0; + /** + * A page token, received from a previous `ListHcxActivationKeys` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListHcxActivationKeys` must match the call that provided the page + * token. + * + * Generated from protobuf field string page_token = 3; + */ + protected $page_token = ''; + + /** + * @param string $parent Required. The resource name of the private cloud + * to be queried for HCX activation keys. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/privateClouds/my-cloud` + * Please see {@see VmwareEngineClient::privateCloudName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\ListHcxActivationKeysRequest + * + * @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 private cloud + * to be queried for HCX activation keys. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/privateClouds/my-cloud` + * @type int $page_size + * The maximum number of HCX activation keys to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * @type string $page_token + * A page token, received from a previous `ListHcxActivationKeys` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListHcxActivationKeys` must match the call that provided the page + * token. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the private cloud + * to be queried for HCX activation keys. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/privateClouds/my-cloud` + * + * 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 private cloud + * to be queried for HCX activation keys. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/privateClouds/my-cloud` + * + * 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 HCX activation keys to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * Generated from protobuf field int32 page_size = 2; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of HCX activation keys to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * 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 `ListHcxActivationKeys` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListHcxActivationKeys` 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 `ListHcxActivationKeys` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListHcxActivationKeys` 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; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListHcxActivationKeysResponse.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListHcxActivationKeysResponse.php new file mode 100644 index 000000000000..7078df13358a --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListHcxActivationKeysResponse.php @@ -0,0 +1,144 @@ +google.cloud.vmwareengine.v1.ListHcxActivationKeysResponse + */ +class ListHcxActivationKeysResponse extends \Google\Protobuf\Internal\Message +{ + /** + * List of HCX activation keys. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.HcxActivationKey hcx_activation_keys = 1; + */ + private $hcx_activation_keys; + /** + * 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 = ''; + /** + * Locations that could not be reached when making an aggregated query using + * wildcards. + * + * Generated from protobuf field repeated string unreachable = 3; + */ + private $unreachable; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\VmwareEngine\V1\HcxActivationKey[] $hcx_activation_keys + * List of HCX activation keys. + * @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. + * @type string[] $unreachable + * Locations that could not be reached when making an aggregated query using + * wildcards. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * List of HCX activation keys. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.HcxActivationKey hcx_activation_keys = 1; + * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\HcxActivationKey> + */ + public function getHcxActivationKeys() + { + return $this->hcx_activation_keys; + } + + /** + * List of HCX activation keys. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.HcxActivationKey hcx_activation_keys = 1; + * @param \Google\Cloud\VmwareEngine\V1\HcxActivationKey[] $var + * @return $this + */ + public function setHcxActivationKeys($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\HcxActivationKey::class); + $this->hcx_activation_keys = $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; + } + + /** + * Locations that could not be reached when making an aggregated query using + * wildcards. + * + * Generated from protobuf field repeated string unreachable = 3; + * @return RepeatedField + */ + public function getUnreachable() + { + return $this->unreachable; + } + + /** + * Locations that could not be reached when making an aggregated query using + * wildcards. + * + * Generated from protobuf field repeated string unreachable = 3; + * @param string[] $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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListLoggingServersRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListLoggingServersRequest.php new file mode 100644 index 000000000000..bf5489610ed1 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListLoggingServersRequest.php @@ -0,0 +1,371 @@ +google.cloud.vmwareengine.v1.ListLoggingServersRequest + */ +class ListLoggingServersRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the private cloud to be queried for + * logging servers. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * The maximum number of logging servers to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * Generated from protobuf field int32 page_size = 2; + */ + protected $page_size = 0; + /** + * A page token, received from a previous `ListLoggingServersRequest` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListLoggingServersRequest` must match the call that provided the page + * token. + * + * Generated from protobuf field string page_token = 3; + */ + protected $page_token = ''; + /** + * A filter expression that matches resources returned in the response. + * The expression must specify the field name, a comparison + * operator, and the value that you want to use for filtering. The value + * must be a string, a number, or a boolean. The comparison operator + * must be `=`, `!=`, `>`, or `<`. + * For example, if you are filtering a list of logging servers, you can + * exclude the ones named `example-server` by specifying + * `name != "example-server"`. + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "example-server") + * (createTime > "2021-04-12T08:15:10.40Z") + * ``` + * By default, each expression is an `AND` expression. However, you + * can include `AND` and `OR` expressions explicitly. + * For example: + * ``` + * (name = "example-server-1") AND + * (createTime > "2021-04-12T08:15:10.40Z") OR + * (name = "example-server-2") + * ``` + * + * Generated from protobuf field string filter = 4; + */ + protected $filter = ''; + /** + * Sorts list results by a certain order. By default, returned results + * are ordered by `name` in ascending order. + * You can also sort results in descending order based on the `name` value + * using `orderBy="name desc"`. + * Currently, only ordering by `name` is supported. + * + * Generated from protobuf field string order_by = 5; + */ + protected $order_by = ''; + + /** + * @param string $parent Required. The resource name of the private cloud to be queried for + * logging servers. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * Please see {@see VmwareEngineClient::privateCloudName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\ListLoggingServersRequest + * + * @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 private cloud to be queried for + * logging servers. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * @type int $page_size + * The maximum number of logging servers to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * @type string $page_token + * A page token, received from a previous `ListLoggingServersRequest` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListLoggingServersRequest` must match the call that provided the page + * token. + * @type string $filter + * A filter expression that matches resources returned in the response. + * The expression must specify the field name, a comparison + * operator, and the value that you want to use for filtering. The value + * must be a string, a number, or a boolean. The comparison operator + * must be `=`, `!=`, `>`, or `<`. + * For example, if you are filtering a list of logging servers, you can + * exclude the ones named `example-server` by specifying + * `name != "example-server"`. + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "example-server") + * (createTime > "2021-04-12T08:15:10.40Z") + * ``` + * By default, each expression is an `AND` expression. However, you + * can include `AND` and `OR` expressions explicitly. + * For example: + * ``` + * (name = "example-server-1") AND + * (createTime > "2021-04-12T08:15:10.40Z") OR + * (name = "example-server-2") + * ``` + * @type string $order_by + * Sorts list results by a certain order. By default, returned results + * are ordered by `name` in ascending order. + * You can also sort results in descending order based on the `name` value + * using `orderBy="name desc"`. + * Currently, only ordering by `name` is supported. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the private cloud to be queried for + * logging servers. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * 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 private cloud to be queried for + * logging servers. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * 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 logging servers to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * Generated from protobuf field int32 page_size = 2; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of logging servers to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * 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 `ListLoggingServersRequest` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListLoggingServersRequest` 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 `ListLoggingServersRequest` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListLoggingServersRequest` 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; + } + + /** + * A filter expression that matches resources returned in the response. + * The expression must specify the field name, a comparison + * operator, and the value that you want to use for filtering. The value + * must be a string, a number, or a boolean. The comparison operator + * must be `=`, `!=`, `>`, or `<`. + * For example, if you are filtering a list of logging servers, you can + * exclude the ones named `example-server` by specifying + * `name != "example-server"`. + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "example-server") + * (createTime > "2021-04-12T08:15:10.40Z") + * ``` + * By default, each expression is an `AND` expression. However, you + * can include `AND` and `OR` expressions explicitly. + * For example: + * ``` + * (name = "example-server-1") AND + * (createTime > "2021-04-12T08:15:10.40Z") OR + * (name = "example-server-2") + * ``` + * + * Generated from protobuf field string filter = 4; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * A filter expression that matches resources returned in the response. + * The expression must specify the field name, a comparison + * operator, and the value that you want to use for filtering. The value + * must be a string, a number, or a boolean. The comparison operator + * must be `=`, `!=`, `>`, or `<`. + * For example, if you are filtering a list of logging servers, you can + * exclude the ones named `example-server` by specifying + * `name != "example-server"`. + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "example-server") + * (createTime > "2021-04-12T08:15:10.40Z") + * ``` + * By default, each expression is an `AND` expression. However, you + * can include `AND` and `OR` expressions explicitly. + * For example: + * ``` + * (name = "example-server-1") AND + * (createTime > "2021-04-12T08:15:10.40Z") OR + * (name = "example-server-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; + } + + /** + * Sorts list results by a certain order. By default, returned results + * are ordered by `name` in ascending order. + * You can also sort results in descending order based on the `name` value + * using `orderBy="name desc"`. + * Currently, only ordering by `name` is supported. + * + * Generated from protobuf field string order_by = 5; + * @return string + */ + public function getOrderBy() + { + return $this->order_by; + } + + /** + * Sorts list results by a certain order. By default, returned results + * are ordered by `name` in ascending order. + * You can also sort results in descending order based on the `name` value + * using `orderBy="name desc"`. + * Currently, only ordering by `name` is supported. + * + * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListLoggingServersResponse.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListLoggingServersResponse.php new file mode 100644 index 000000000000..bf033aea7733 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListLoggingServersResponse.php @@ -0,0 +1,144 @@ +google.cloud.vmwareengine.v1.ListLoggingServersResponse + */ +class ListLoggingServersResponse extends \Google\Protobuf\Internal\Message +{ + /** + * A list of Logging Servers. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.LoggingServer logging_servers = 1; + */ + private $logging_servers; + /** + * A token, which can be send 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 = ''; + /** + * Locations that could not be reached when making an aggregated query using + * wildcards. + * + * Generated from protobuf field repeated string unreachable = 3; + */ + private $unreachable; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\VmwareEngine\V1\LoggingServer[] $logging_servers + * A list of Logging Servers. + * @type string $next_page_token + * A token, which can be send as `page_token` to retrieve the next page. + * If this field is omitted, there are no subsequent pages. + * @type string[] $unreachable + * Locations that could not be reached when making an aggregated query using + * wildcards. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * A list of Logging Servers. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.LoggingServer logging_servers = 1; + * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\LoggingServer> + */ + public function getLoggingServers() + { + return $this->logging_servers; + } + + /** + * A list of Logging Servers. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.LoggingServer logging_servers = 1; + * @param \Google\Cloud\VmwareEngine\V1\LoggingServer[] $var + * @return $this + */ + public function setLoggingServers($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\LoggingServer::class); + $this->logging_servers = $arr; + + return $this; + } + + /** + * A token, which can be send 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 send 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; + } + + /** + * Locations that could not be reached when making an aggregated query using + * wildcards. + * + * Generated from protobuf field repeated string unreachable = 3; + * @return RepeatedField + */ + public function getUnreachable() + { + return $this->unreachable; + } + + /** + * Locations that could not be reached when making an aggregated query using + * wildcards. + * + * Generated from protobuf field repeated string unreachable = 3; + * @param string[] $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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListManagementDnsZoneBindingsRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListManagementDnsZoneBindingsRequest.php new file mode 100644 index 000000000000..e92925440d51 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListManagementDnsZoneBindingsRequest.php @@ -0,0 +1,371 @@ +google.cloud.vmwareengine.v1.ListManagementDnsZoneBindingsRequest + */ +class ListManagementDnsZoneBindingsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the private cloud to be queried for + * management DNS zone bindings. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * The maximum number of management DNS zone bindings to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * Generated from protobuf field int32 page_size = 2; + */ + protected $page_size = 0; + /** + * A page token, received from a previous `ListManagementDnsZoneBindings` + * call. Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListManagementDnsZoneBindings` must match the call that provided the page + * token. + * + * Generated from protobuf field string page_token = 3; + */ + protected $page_token = ''; + /** + * A filter expression that matches resources returned in the response. + * The expression must specify the field name, a comparison + * operator, and the value that you want to use for filtering. The value + * must be a string, a number, or a boolean. The comparison operator + * must be `=`, `!=`, `>`, or `<`. + * For example, if you are filtering a list of Management DNS Zone Bindings, + * you can exclude the ones named `example-management-dns-zone-binding` by + * specifying `name != "example-management-dns-zone-binding"`. + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "example-management-dns-zone-binding") + * (createTime > "2021-04-12T08:15:10.40Z") + * ``` + * By default, each expression is an `AND` expression. However, you + * can include `AND` and `OR` expressions explicitly. + * For example: + * ``` + * (name = "example-management-dns-zone-binding-1") AND + * (createTime > "2021-04-12T08:15:10.40Z") OR + * (name = "example-management-dns-zone-binding-2") + * ``` + * + * Generated from protobuf field string filter = 4; + */ + protected $filter = ''; + /** + * Sorts list results by a certain order. By default, returned results + * are ordered by `name` in ascending order. + * You can also sort results in descending order based on the `name` value + * using `orderBy="name desc"`. + * Currently, only ordering by `name` is supported. + * + * Generated from protobuf field string order_by = 5; + */ + protected $order_by = ''; + + /** + * @param string $parent Required. The resource name of the private cloud to be queried for + * management DNS zone bindings. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * Please see {@see VmwareEngineClient::privateCloudName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\ListManagementDnsZoneBindingsRequest + * + * @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 private cloud to be queried for + * management DNS zone bindings. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * @type int $page_size + * The maximum number of management DNS zone bindings to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * @type string $page_token + * A page token, received from a previous `ListManagementDnsZoneBindings` + * call. Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListManagementDnsZoneBindings` must match the call that provided the page + * token. + * @type string $filter + * A filter expression that matches resources returned in the response. + * The expression must specify the field name, a comparison + * operator, and the value that you want to use for filtering. The value + * must be a string, a number, or a boolean. The comparison operator + * must be `=`, `!=`, `>`, or `<`. + * For example, if you are filtering a list of Management DNS Zone Bindings, + * you can exclude the ones named `example-management-dns-zone-binding` by + * specifying `name != "example-management-dns-zone-binding"`. + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "example-management-dns-zone-binding") + * (createTime > "2021-04-12T08:15:10.40Z") + * ``` + * By default, each expression is an `AND` expression. However, you + * can include `AND` and `OR` expressions explicitly. + * For example: + * ``` + * (name = "example-management-dns-zone-binding-1") AND + * (createTime > "2021-04-12T08:15:10.40Z") OR + * (name = "example-management-dns-zone-binding-2") + * ``` + * @type string $order_by + * Sorts list results by a certain order. By default, returned results + * are ordered by `name` in ascending order. + * You can also sort results in descending order based on the `name` value + * using `orderBy="name desc"`. + * Currently, only ordering by `name` is supported. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the private cloud to be queried for + * management DNS zone bindings. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * 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 private cloud to be queried for + * management DNS zone bindings. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * 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 management DNS zone bindings to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * Generated from protobuf field int32 page_size = 2; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of management DNS zone bindings to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * 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 `ListManagementDnsZoneBindings` + * call. Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListManagementDnsZoneBindings` 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 `ListManagementDnsZoneBindings` + * call. Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListManagementDnsZoneBindings` 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; + } + + /** + * A filter expression that matches resources returned in the response. + * The expression must specify the field name, a comparison + * operator, and the value that you want to use for filtering. The value + * must be a string, a number, or a boolean. The comparison operator + * must be `=`, `!=`, `>`, or `<`. + * For example, if you are filtering a list of Management DNS Zone Bindings, + * you can exclude the ones named `example-management-dns-zone-binding` by + * specifying `name != "example-management-dns-zone-binding"`. + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "example-management-dns-zone-binding") + * (createTime > "2021-04-12T08:15:10.40Z") + * ``` + * By default, each expression is an `AND` expression. However, you + * can include `AND` and `OR` expressions explicitly. + * For example: + * ``` + * (name = "example-management-dns-zone-binding-1") AND + * (createTime > "2021-04-12T08:15:10.40Z") OR + * (name = "example-management-dns-zone-binding-2") + * ``` + * + * Generated from protobuf field string filter = 4; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * A filter expression that matches resources returned in the response. + * The expression must specify the field name, a comparison + * operator, and the value that you want to use for filtering. The value + * must be a string, a number, or a boolean. The comparison operator + * must be `=`, `!=`, `>`, or `<`. + * For example, if you are filtering a list of Management DNS Zone Bindings, + * you can exclude the ones named `example-management-dns-zone-binding` by + * specifying `name != "example-management-dns-zone-binding"`. + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "example-management-dns-zone-binding") + * (createTime > "2021-04-12T08:15:10.40Z") + * ``` + * By default, each expression is an `AND` expression. However, you + * can include `AND` and `OR` expressions explicitly. + * For example: + * ``` + * (name = "example-management-dns-zone-binding-1") AND + * (createTime > "2021-04-12T08:15:10.40Z") OR + * (name = "example-management-dns-zone-binding-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; + } + + /** + * Sorts list results by a certain order. By default, returned results + * are ordered by `name` in ascending order. + * You can also sort results in descending order based on the `name` value + * using `orderBy="name desc"`. + * Currently, only ordering by `name` is supported. + * + * Generated from protobuf field string order_by = 5; + * @return string + */ + public function getOrderBy() + { + return $this->order_by; + } + + /** + * Sorts list results by a certain order. By default, returned results + * are ordered by `name` in ascending order. + * You can also sort results in descending order based on the `name` value + * using `orderBy="name desc"`. + * Currently, only ordering by `name` is supported. + * + * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListManagementDnsZoneBindingsResponse.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListManagementDnsZoneBindingsResponse.php new file mode 100644 index 000000000000..286b729b0c0a --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListManagementDnsZoneBindingsResponse.php @@ -0,0 +1,144 @@ +google.cloud.vmwareengine.v1.ListManagementDnsZoneBindingsResponse + */ +class ListManagementDnsZoneBindingsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * A list of management DNS zone bindings. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.ManagementDnsZoneBinding management_dns_zone_bindings = 1; + */ + private $management_dns_zone_bindings; + /** + * 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 = ''; + /** + * Locations that could not be reached when making an aggregated query using + * wildcards. + * + * Generated from protobuf field repeated string unreachable = 3; + */ + private $unreachable; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\VmwareEngine\V1\ManagementDnsZoneBinding[] $management_dns_zone_bindings + * A list of management DNS zone bindings. + * @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. + * @type string[] $unreachable + * Locations that could not be reached when making an aggregated query using + * wildcards. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * A list of management DNS zone bindings. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.ManagementDnsZoneBinding management_dns_zone_bindings = 1; + * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\ManagementDnsZoneBinding> + */ + public function getManagementDnsZoneBindings() + { + return $this->management_dns_zone_bindings; + } + + /** + * A list of management DNS zone bindings. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.ManagementDnsZoneBinding management_dns_zone_bindings = 1; + * @param \Google\Cloud\VmwareEngine\V1\ManagementDnsZoneBinding[] $var + * @return $this + */ + public function setManagementDnsZoneBindings($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\ManagementDnsZoneBinding::class); + $this->management_dns_zone_bindings = $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; + } + + /** + * Locations that could not be reached when making an aggregated query using + * wildcards. + * + * Generated from protobuf field repeated string unreachable = 3; + * @return RepeatedField + */ + public function getUnreachable() + { + return $this->unreachable; + } + + /** + * Locations that could not be reached when making an aggregated query using + * wildcards. + * + * Generated from protobuf field repeated string unreachable = 3; + * @param string[] $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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNetworkPeeringsRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNetworkPeeringsRequest.php new file mode 100644 index 000000000000..c032a2e8957f --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNetworkPeeringsRequest.php @@ -0,0 +1,357 @@ +google.cloud.vmwareengine.v1.ListNetworkPeeringsRequest + */ +class ListNetworkPeeringsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the location (global) to query for + * network peerings. Resource names are schemeless URIs that follow the + * conventions in https://cloud.google.com/apis/design/resource_names. For + * example: `projects/my-project/locations/global` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * The maximum number of network peerings to return in one page. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * Generated from protobuf field int32 page_size = 2; + */ + protected $page_size = 0; + /** + * A page token, received from a previous `ListNetworkPeerings` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListNetworkPeerings` must match the call that provided the page + * token. + * + * Generated from protobuf field string page_token = 3; + */ + protected $page_token = ''; + /** + * A filter expression that matches resources returned in the response. + * The expression must specify the field name, a comparison + * operator, and the value that you want to use for filtering. The value + * must be a string, a number, or a boolean. The comparison operator + * must be `=`, `!=`, `>`, or `<`. + * For example, if you are filtering a list of network peerings, you can + * exclude the ones named `example-peering` by specifying + * `name != "example-peering"`. + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "example-peering") + * (createTime > "2021-04-12T08:15:10.40Z") + * ``` + * By default, each expression is an `AND` expression. However, you + * can include `AND` and `OR` expressions explicitly. + * For example: + * ``` + * (name = "example-peering-1") AND + * (createTime > "2021-04-12T08:15:10.40Z") OR + * (name = "example-peering-2") + * ``` + * + * Generated from protobuf field string filter = 4; + */ + protected $filter = ''; + /** + * Sorts list results by a certain order. By default, returned results + * are ordered by `name` in ascending order. + * You can also sort results in descending order based on the `name` value + * using `orderBy="name desc"`. + * Currently, only ordering by `name` is supported. + * + * Generated from protobuf field string order_by = 5; + */ + protected $order_by = ''; + + /** + * @param string $parent Required. The resource name of the location (global) to query for + * network peerings. Resource names are schemeless URIs that follow the + * conventions in https://cloud.google.com/apis/design/resource_names. For + * example: `projects/my-project/locations/global` + * Please see {@see VmwareEngineClient::locationName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\ListNetworkPeeringsRequest + * + * @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 location (global) to query for + * network peerings. Resource names are schemeless URIs that follow the + * conventions in https://cloud.google.com/apis/design/resource_names. For + * example: `projects/my-project/locations/global` + * @type int $page_size + * The maximum number of network peerings to return in one page. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * @type string $page_token + * A page token, received from a previous `ListNetworkPeerings` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListNetworkPeerings` must match the call that provided the page + * token. + * @type string $filter + * A filter expression that matches resources returned in the response. + * The expression must specify the field name, a comparison + * operator, and the value that you want to use for filtering. The value + * must be a string, a number, or a boolean. The comparison operator + * must be `=`, `!=`, `>`, or `<`. + * For example, if you are filtering a list of network peerings, you can + * exclude the ones named `example-peering` by specifying + * `name != "example-peering"`. + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "example-peering") + * (createTime > "2021-04-12T08:15:10.40Z") + * ``` + * By default, each expression is an `AND` expression. However, you + * can include `AND` and `OR` expressions explicitly. + * For example: + * ``` + * (name = "example-peering-1") AND + * (createTime > "2021-04-12T08:15:10.40Z") OR + * (name = "example-peering-2") + * ``` + * @type string $order_by + * Sorts list results by a certain order. By default, returned results + * are ordered by `name` in ascending order. + * You can also sort results in descending order based on the `name` value + * using `orderBy="name desc"`. + * Currently, only ordering by `name` is supported. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the location (global) to query for + * network peerings. Resource names are schemeless URIs that follow the + * conventions in https://cloud.google.com/apis/design/resource_names. For + * example: `projects/my-project/locations/global` + * + * 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 (global) to query for + * network peerings. Resource names are schemeless URIs that follow the + * conventions in https://cloud.google.com/apis/design/resource_names. For + * example: `projects/my-project/locations/global` + * + * 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 network peerings to return in one page. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * Generated from protobuf field int32 page_size = 2; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of network peerings to return in one page. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * 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 `ListNetworkPeerings` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListNetworkPeerings` 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 `ListNetworkPeerings` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListNetworkPeerings` 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; + } + + /** + * A filter expression that matches resources returned in the response. + * The expression must specify the field name, a comparison + * operator, and the value that you want to use for filtering. The value + * must be a string, a number, or a boolean. The comparison operator + * must be `=`, `!=`, `>`, or `<`. + * For example, if you are filtering a list of network peerings, you can + * exclude the ones named `example-peering` by specifying + * `name != "example-peering"`. + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "example-peering") + * (createTime > "2021-04-12T08:15:10.40Z") + * ``` + * By default, each expression is an `AND` expression. However, you + * can include `AND` and `OR` expressions explicitly. + * For example: + * ``` + * (name = "example-peering-1") AND + * (createTime > "2021-04-12T08:15:10.40Z") OR + * (name = "example-peering-2") + * ``` + * + * Generated from protobuf field string filter = 4; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * A filter expression that matches resources returned in the response. + * The expression must specify the field name, a comparison + * operator, and the value that you want to use for filtering. The value + * must be a string, a number, or a boolean. The comparison operator + * must be `=`, `!=`, `>`, or `<`. + * For example, if you are filtering a list of network peerings, you can + * exclude the ones named `example-peering` by specifying + * `name != "example-peering"`. + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "example-peering") + * (createTime > "2021-04-12T08:15:10.40Z") + * ``` + * By default, each expression is an `AND` expression. However, you + * can include `AND` and `OR` expressions explicitly. + * For example: + * ``` + * (name = "example-peering-1") AND + * (createTime > "2021-04-12T08:15:10.40Z") OR + * (name = "example-peering-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; + } + + /** + * Sorts list results by a certain order. By default, returned results + * are ordered by `name` in ascending order. + * You can also sort results in descending order based on the `name` value + * using `orderBy="name desc"`. + * Currently, only ordering by `name` is supported. + * + * Generated from protobuf field string order_by = 5; + * @return string + */ + public function getOrderBy() + { + return $this->order_by; + } + + /** + * Sorts list results by a certain order. By default, returned results + * are ordered by `name` in ascending order. + * You can also sort results in descending order based on the `name` value + * using `orderBy="name desc"`. + * Currently, only ordering by `name` is supported. + * + * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNetworkPeeringsResponse.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNetworkPeeringsResponse.php new file mode 100644 index 000000000000..82cb3042c8e1 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNetworkPeeringsResponse.php @@ -0,0 +1,140 @@ +google.cloud.vmwareengine.v1.ListNetworkPeeringsResponse + */ +class ListNetworkPeeringsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * A list of network peerings. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.NetworkPeering network_peerings = 1; + */ + private $network_peerings; + /** + * 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 = ''; + /** + * Unreachable resources. + * + * Generated from protobuf field repeated string unreachable = 3; + */ + private $unreachable; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\VmwareEngine\V1\NetworkPeering[] $network_peerings + * A list of network peerings. + * @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. + * @type string[] $unreachable + * Unreachable resources. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * A list of network peerings. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.NetworkPeering network_peerings = 1; + * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\NetworkPeering> + */ + public function getNetworkPeerings() + { + return $this->network_peerings; + } + + /** + * A list of network peerings. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.NetworkPeering network_peerings = 1; + * @param \Google\Cloud\VmwareEngine\V1\NetworkPeering[] $var + * @return $this + */ + public function setNetworkPeerings($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\NetworkPeering::class); + $this->network_peerings = $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; + } + + /** + * Unreachable resources. + * + * Generated from protobuf field repeated string unreachable = 3; + * @return RepeatedField + */ + public function getUnreachable() + { + return $this->unreachable; + } + + /** + * Unreachable resources. + * + * Generated from protobuf field repeated string unreachable = 3; + * @param string[] $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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNetworkPoliciesRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNetworkPoliciesRequest.php new file mode 100644 index 000000000000..45396e12ff7a --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNetworkPoliciesRequest.php @@ -0,0 +1,361 @@ +google.cloud.vmwareengine.v1.ListNetworkPoliciesRequest + */ +class ListNetworkPoliciesRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the location (region) to query for + * network policies. Resource names are schemeless URIs that follow the + * conventions in https://cloud.google.com/apis/design/resource_names. For + * example: `projects/my-project/locations/us-central1` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * The maximum number of network policies to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * Generated from protobuf field int32 page_size = 2; + */ + protected $page_size = 0; + /** + * A page token, received from a previous `ListNetworkPolicies` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListNetworkPolicies` must match the call that provided the page + * token. + * + * Generated from protobuf field string page_token = 3; + */ + protected $page_token = ''; + /** + * A filter expression that matches resources returned in the response. + * The expression must specify the field name, a comparison + * operator, and the value that you want to use for filtering. The value + * must be a string, a number, or a boolean. The comparison operator + * must be `=`, `!=`, `>`, or `<`. + * For example, if you are filtering a list of network policies, you can + * exclude the ones named `example-policy` by specifying + * `name != "example-policy"`. + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "example-policy") + * (createTime > "2021-04-12T08:15:10.40Z") + * ``` + * By default, each expression is an `AND` expression. However, you + * can include `AND` and `OR` expressions explicitly. + * For example: + * ``` + * (name = "example-policy-1") AND + * (createTime > "2021-04-12T08:15:10.40Z") OR + * (name = "example-policy-2") + * ``` + * + * Generated from protobuf field string filter = 4; + */ + protected $filter = ''; + /** + * Sorts list results by a certain order. By default, returned results + * are ordered by `name` in ascending order. + * You can also sort results in descending order based on the `name` value + * using `orderBy="name desc"`. + * Currently, only ordering by `name` is supported. + * + * Generated from protobuf field string order_by = 5; + */ + protected $order_by = ''; + + /** + * @param string $parent Required. The resource name of the location (region) to query for + * network policies. Resource names are schemeless URIs that follow the + * conventions in https://cloud.google.com/apis/design/resource_names. For + * example: `projects/my-project/locations/us-central1` + * Please see {@see VmwareEngineClient::locationName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\ListNetworkPoliciesRequest + * + * @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 location (region) to query for + * network policies. Resource names are schemeless URIs that follow the + * conventions in https://cloud.google.com/apis/design/resource_names. For + * example: `projects/my-project/locations/us-central1` + * @type int $page_size + * The maximum number of network policies to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * @type string $page_token + * A page token, received from a previous `ListNetworkPolicies` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListNetworkPolicies` must match the call that provided the page + * token. + * @type string $filter + * A filter expression that matches resources returned in the response. + * The expression must specify the field name, a comparison + * operator, and the value that you want to use for filtering. The value + * must be a string, a number, or a boolean. The comparison operator + * must be `=`, `!=`, `>`, or `<`. + * For example, if you are filtering a list of network policies, you can + * exclude the ones named `example-policy` by specifying + * `name != "example-policy"`. + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "example-policy") + * (createTime > "2021-04-12T08:15:10.40Z") + * ``` + * By default, each expression is an `AND` expression. However, you + * can include `AND` and `OR` expressions explicitly. + * For example: + * ``` + * (name = "example-policy-1") AND + * (createTime > "2021-04-12T08:15:10.40Z") OR + * (name = "example-policy-2") + * ``` + * @type string $order_by + * Sorts list results by a certain order. By default, returned results + * are ordered by `name` in ascending order. + * You can also sort results in descending order based on the `name` value + * using `orderBy="name desc"`. + * Currently, only ordering by `name` is supported. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the location (region) to query for + * network policies. Resource names are schemeless URIs that follow the + * conventions in https://cloud.google.com/apis/design/resource_names. For + * example: `projects/my-project/locations/us-central1` + * + * 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 (region) to query for + * network policies. Resource names are schemeless URIs that follow the + * conventions in https://cloud.google.com/apis/design/resource_names. For + * example: `projects/my-project/locations/us-central1` + * + * 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 network policies to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * Generated from protobuf field int32 page_size = 2; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of network policies to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * 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 `ListNetworkPolicies` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListNetworkPolicies` 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 `ListNetworkPolicies` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListNetworkPolicies` 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; + } + + /** + * A filter expression that matches resources returned in the response. + * The expression must specify the field name, a comparison + * operator, and the value that you want to use for filtering. The value + * must be a string, a number, or a boolean. The comparison operator + * must be `=`, `!=`, `>`, or `<`. + * For example, if you are filtering a list of network policies, you can + * exclude the ones named `example-policy` by specifying + * `name != "example-policy"`. + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "example-policy") + * (createTime > "2021-04-12T08:15:10.40Z") + * ``` + * By default, each expression is an `AND` expression. However, you + * can include `AND` and `OR` expressions explicitly. + * For example: + * ``` + * (name = "example-policy-1") AND + * (createTime > "2021-04-12T08:15:10.40Z") OR + * (name = "example-policy-2") + * ``` + * + * Generated from protobuf field string filter = 4; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * A filter expression that matches resources returned in the response. + * The expression must specify the field name, a comparison + * operator, and the value that you want to use for filtering. The value + * must be a string, a number, or a boolean. The comparison operator + * must be `=`, `!=`, `>`, or `<`. + * For example, if you are filtering a list of network policies, you can + * exclude the ones named `example-policy` by specifying + * `name != "example-policy"`. + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "example-policy") + * (createTime > "2021-04-12T08:15:10.40Z") + * ``` + * By default, each expression is an `AND` expression. However, you + * can include `AND` and `OR` expressions explicitly. + * For example: + * ``` + * (name = "example-policy-1") AND + * (createTime > "2021-04-12T08:15:10.40Z") OR + * (name = "example-policy-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; + } + + /** + * Sorts list results by a certain order. By default, returned results + * are ordered by `name` in ascending order. + * You can also sort results in descending order based on the `name` value + * using `orderBy="name desc"`. + * Currently, only ordering by `name` is supported. + * + * Generated from protobuf field string order_by = 5; + * @return string + */ + public function getOrderBy() + { + return $this->order_by; + } + + /** + * Sorts list results by a certain order. By default, returned results + * are ordered by `name` in ascending order. + * You can also sort results in descending order based on the `name` value + * using `orderBy="name desc"`. + * Currently, only ordering by `name` is supported. + * + * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNetworkPoliciesResponse.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNetworkPoliciesResponse.php new file mode 100644 index 000000000000..26651ec97a12 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNetworkPoliciesResponse.php @@ -0,0 +1,144 @@ +google.cloud.vmwareengine.v1.ListNetworkPoliciesResponse + */ +class ListNetworkPoliciesResponse extends \Google\Protobuf\Internal\Message +{ + /** + * A list of network policies. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.NetworkPolicy network_policies = 1; + */ + private $network_policies; + /** + * A token, which can be send 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 = ''; + /** + * Locations that could not be reached when making an aggregated query using + * wildcards. + * + * Generated from protobuf field repeated string unreachable = 3; + */ + private $unreachable; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\VmwareEngine\V1\NetworkPolicy[] $network_policies + * A list of network policies. + * @type string $next_page_token + * A token, which can be send as `page_token` to retrieve the next page. + * If this field is omitted, there are no subsequent pages. + * @type string[] $unreachable + * Locations that could not be reached when making an aggregated query using + * wildcards. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * A list of network policies. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.NetworkPolicy network_policies = 1; + * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\NetworkPolicy> + */ + public function getNetworkPolicies() + { + return $this->network_policies; + } + + /** + * A list of network policies. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.NetworkPolicy network_policies = 1; + * @param \Google\Cloud\VmwareEngine\V1\NetworkPolicy[] $var + * @return $this + */ + public function setNetworkPolicies($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\NetworkPolicy::class); + $this->network_policies = $arr; + + return $this; + } + + /** + * A token, which can be send 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 send 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; + } + + /** + * Locations that could not be reached when making an aggregated query using + * wildcards. + * + * Generated from protobuf field repeated string unreachable = 3; + * @return RepeatedField + */ + public function getUnreachable() + { + return $this->unreachable; + } + + /** + * Locations that could not be reached when making an aggregated query using + * wildcards. + * + * Generated from protobuf field repeated string unreachable = 3; + * @param string[] $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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNodeTypesRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNodeTypesRequest.php new file mode 100644 index 000000000000..670c0e546789 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNodeTypesRequest.php @@ -0,0 +1,312 @@ +google.cloud.vmwareengine.v1.ListNodeTypesRequest + */ +class ListNodeTypesRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the location to be queried for node types. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * The maximum number of node types to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * Generated from protobuf field int32 page_size = 2; + */ + protected $page_size = 0; + /** + * A page token, received from a previous `ListNodeTypes` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListNodeTypes` must match the call that provided the page token. + * + * Generated from protobuf field string page_token = 3; + */ + protected $page_token = ''; + /** + * A filter expression that matches resources returned in the response. + * The expression must specify the field name, a comparison + * operator, and the value that you want to use for filtering. The value + * must be a string, a number, or a boolean. The comparison operator + * must be `=`, `!=`, `>`, or `<`. + * For example, if you are filtering a list of node types, you can + * exclude the ones named `standard-72` by specifying + * `name != "standard-72"`. + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "standard-72") + * (virtual_cpu_count > 2) + * ``` + * By default, each expression is an `AND` expression. However, you + * can include `AND` and `OR` expressions explicitly. + * For example: + * ``` + * (name = "standard-96") AND + * (virtual_cpu_count > 2) OR + * (name = "standard-72") + * ``` + * + * Generated from protobuf field string filter = 4; + */ + protected $filter = ''; + + /** + * @param string $parent Required. The resource name of the location to be queried for node types. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a` + * Please see {@see VmwareEngineClient::locationName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\ListNodeTypesRequest + * + * @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 location to be queried for node types. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a` + * @type int $page_size + * The maximum number of node types to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * @type string $page_token + * A page token, received from a previous `ListNodeTypes` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListNodeTypes` must match the call that provided the page token. + * @type string $filter + * A filter expression that matches resources returned in the response. + * The expression must specify the field name, a comparison + * operator, and the value that you want to use for filtering. The value + * must be a string, a number, or a boolean. The comparison operator + * must be `=`, `!=`, `>`, or `<`. + * For example, if you are filtering a list of node types, you can + * exclude the ones named `standard-72` by specifying + * `name != "standard-72"`. + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "standard-72") + * (virtual_cpu_count > 2) + * ``` + * By default, each expression is an `AND` expression. However, you + * can include `AND` and `OR` expressions explicitly. + * For example: + * ``` + * (name = "standard-96") AND + * (virtual_cpu_count > 2) OR + * (name = "standard-72") + * ``` + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the location to be queried for node types. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a` + * + * 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 to be queried for node types. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a` + * + * 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 node types to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * Generated from protobuf field int32 page_size = 2; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of node types to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * 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 `ListNodeTypes` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListNodeTypes` 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 `ListNodeTypes` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListNodeTypes` 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; + } + + /** + * A filter expression that matches resources returned in the response. + * The expression must specify the field name, a comparison + * operator, and the value that you want to use for filtering. The value + * must be a string, a number, or a boolean. The comparison operator + * must be `=`, `!=`, `>`, or `<`. + * For example, if you are filtering a list of node types, you can + * exclude the ones named `standard-72` by specifying + * `name != "standard-72"`. + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "standard-72") + * (virtual_cpu_count > 2) + * ``` + * By default, each expression is an `AND` expression. However, you + * can include `AND` and `OR` expressions explicitly. + * For example: + * ``` + * (name = "standard-96") AND + * (virtual_cpu_count > 2) OR + * (name = "standard-72") + * ``` + * + * Generated from protobuf field string filter = 4; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * A filter expression that matches resources returned in the response. + * The expression must specify the field name, a comparison + * operator, and the value that you want to use for filtering. The value + * must be a string, a number, or a boolean. The comparison operator + * must be `=`, `!=`, `>`, or `<`. + * For example, if you are filtering a list of node types, you can + * exclude the ones named `standard-72` by specifying + * `name != "standard-72"`. + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "standard-72") + * (virtual_cpu_count > 2) + * ``` + * By default, each expression is an `AND` expression. However, you + * can include `AND` and `OR` expressions explicitly. + * For example: + * ``` + * (name = "standard-96") AND + * (virtual_cpu_count > 2) OR + * (name = "standard-72") + * ``` + * + * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNodeTypesResponse.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNodeTypesResponse.php new file mode 100644 index 000000000000..bc4d8851e9c0 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNodeTypesResponse.php @@ -0,0 +1,144 @@ +google.cloud.vmwareengine.v1.ListNodeTypesResponse + */ +class ListNodeTypesResponse extends \Google\Protobuf\Internal\Message +{ + /** + * A list of Node Types. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.NodeType node_types = 1; + */ + private $node_types; + /** + * 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 = ''; + /** + * Locations that could not be reached when making an aggregated query using + * wildcards. + * + * Generated from protobuf field repeated string unreachable = 3; + */ + private $unreachable; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\VmwareEngine\V1\NodeType[] $node_types + * A list of Node Types. + * @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. + * @type string[] $unreachable + * Locations that could not be reached when making an aggregated query using + * wildcards. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * A list of Node Types. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.NodeType node_types = 1; + * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\NodeType> + */ + public function getNodeTypes() + { + return $this->node_types; + } + + /** + * A list of Node Types. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.NodeType node_types = 1; + * @param \Google\Cloud\VmwareEngine\V1\NodeType[] $var + * @return $this + */ + public function setNodeTypes($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\NodeType::class); + $this->node_types = $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; + } + + /** + * Locations that could not be reached when making an aggregated query using + * wildcards. + * + * Generated from protobuf field repeated string unreachable = 3; + * @return RepeatedField + */ + public function getUnreachable() + { + return $this->unreachable; + } + + /** + * Locations that could not be reached when making an aggregated query using + * wildcards. + * + * Generated from protobuf field repeated string unreachable = 3; + * @param string[] $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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNodesRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNodesRequest.php new file mode 100644 index 000000000000..aa9bc6b99586 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNodesRequest.php @@ -0,0 +1,198 @@ +google.cloud.vmwareengine.v1.ListNodesRequest + */ +class ListNodesRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the cluster to be queried for nodes. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * The maximum number of nodes to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * Generated from protobuf field int32 page_size = 2; + */ + protected $page_size = 0; + /** + * A page token, received from a previous `ListNodes` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListNodes` must match the call that provided the page + * token. + * + * Generated from protobuf field string page_token = 3; + */ + protected $page_token = ''; + + /** + * @param string $parent Required. The resource name of the cluster to be queried for nodes. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster` + * Please see {@see VmwareEngineClient::clusterName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\ListNodesRequest + * + * @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 cluster to be queried for nodes. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster` + * @type int $page_size + * The maximum number of nodes to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * @type string $page_token + * A page token, received from a previous `ListNodes` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListNodes` must match the call that provided the page + * token. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the cluster to be queried for nodes. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster` + * + * 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 cluster to be queried for nodes. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster` + * + * 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 nodes to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * Generated from protobuf field int32 page_size = 2; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of nodes to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * 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 `ListNodes` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListNodes` 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 `ListNodes` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListNodes` 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; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNodesResponse.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNodesResponse.php new file mode 100644 index 000000000000..1cd1fe3b8e7f --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNodesResponse.php @@ -0,0 +1,106 @@ +google.cloud.vmwareengine.v1.ListNodesResponse + */ +class ListNodesResponse extends \Google\Protobuf\Internal\Message +{ + /** + * The nodes. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.Node nodes = 1; + */ + private $nodes; + /** + * 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 \Google\Cloud\VmwareEngine\V1\Node[] $nodes + * The nodes. + * @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\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * The nodes. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.Node nodes = 1; + * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\Node> + */ + public function getNodes() + { + return $this->nodes; + } + + /** + * The nodes. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.Node nodes = 1; + * @param \Google\Cloud\VmwareEngine\V1\Node[] $var + * @return $this + */ + public function setNodes($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\Node::class); + $this->nodes = $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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPeeringRoutesRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPeeringRoutesRequest.php new file mode 100644 index 000000000000..43d7c8486300 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPeeringRoutesRequest.php @@ -0,0 +1,239 @@ +google.cloud.vmwareengine.v1.ListPeeringRoutesRequest + */ +class ListPeeringRoutesRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the network peering to retrieve peering + * routes from. Resource names are schemeless URIs that follow the conventions + * in https://cloud.google.com/apis/design/resource_names. For example: + * `projects/my-project/locations/global/networkPeerings/my-peering` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * The maximum number of peering routes to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * Generated from protobuf field int32 page_size = 2; + */ + protected $page_size = 0; + /** + * A page token, received from a previous `ListPeeringRoutes` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to `ListPeeringRoutes` must + * match the call that provided the page token. + * + * Generated from protobuf field string page_token = 3; + */ + protected $page_token = ''; + /** + * A filter expression that matches resources returned in the response. + * Currently, only filtering on the `direction` field is supported. To return + * routes imported from the peer network, provide "direction=INCOMING". To + * return routes exported from the VMware Engine network, provide + * "direction=OUTGOING". Other filter expressions return an error. + * + * Generated from protobuf field string filter = 6; + */ + protected $filter = ''; + + /** + * @param string $parent Required. The resource name of the network peering to retrieve peering + * routes from. Resource names are schemeless URIs that follow the conventions + * in https://cloud.google.com/apis/design/resource_names. For example: + * `projects/my-project/locations/global/networkPeerings/my-peering` + * Please see {@see VmwareEngineClient::networkPeeringName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\ListPeeringRoutesRequest + * + * @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 network peering to retrieve peering + * routes from. Resource names are schemeless URIs that follow the conventions + * in https://cloud.google.com/apis/design/resource_names. For example: + * `projects/my-project/locations/global/networkPeerings/my-peering` + * @type int $page_size + * The maximum number of peering routes to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * @type string $page_token + * A page token, received from a previous `ListPeeringRoutes` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to `ListPeeringRoutes` must + * match the call that provided the page token. + * @type string $filter + * A filter expression that matches resources returned in the response. + * Currently, only filtering on the `direction` field is supported. To return + * routes imported from the peer network, provide "direction=INCOMING". To + * return routes exported from the VMware Engine network, provide + * "direction=OUTGOING". Other filter expressions return an error. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the network peering to retrieve peering + * routes from. Resource names are schemeless URIs that follow the conventions + * in https://cloud.google.com/apis/design/resource_names. For example: + * `projects/my-project/locations/global/networkPeerings/my-peering` + * + * 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 network peering to retrieve peering + * routes from. Resource names are schemeless URIs that follow the conventions + * in https://cloud.google.com/apis/design/resource_names. For example: + * `projects/my-project/locations/global/networkPeerings/my-peering` + * + * 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 peering routes to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * Generated from protobuf field int32 page_size = 2; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of peering routes to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * 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 `ListPeeringRoutes` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to `ListPeeringRoutes` 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 `ListPeeringRoutes` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to `ListPeeringRoutes` 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; + } + + /** + * A filter expression that matches resources returned in the response. + * Currently, only filtering on the `direction` field is supported. To return + * routes imported from the peer network, provide "direction=INCOMING". To + * return routes exported from the VMware Engine network, provide + * "direction=OUTGOING". Other filter expressions return an error. + * + * Generated from protobuf field string filter = 6; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * A filter expression that matches resources returned in the response. + * Currently, only filtering on the `direction` field is supported. To return + * routes imported from the peer network, provide "direction=INCOMING". To + * return routes exported from the VMware Engine network, provide + * "direction=OUTGOING". Other filter expressions return an error. + * + * Generated from protobuf field string filter = 6; + * @param string $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkString($var, True); + $this->filter = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPeeringRoutesResponse.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPeeringRoutesResponse.php new file mode 100644 index 000000000000..93aecb6ae180 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPeeringRoutesResponse.php @@ -0,0 +1,106 @@ +google.cloud.vmwareengine.v1.ListPeeringRoutesResponse + */ +class ListPeeringRoutesResponse extends \Google\Protobuf\Internal\Message +{ + /** + * A list of peering routes. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.PeeringRoute peering_routes = 1; + */ + private $peering_routes; + /** + * 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 \Google\Cloud\VmwareEngine\V1\PeeringRoute[] $peering_routes + * A list of peering routes. + * @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\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * A list of peering routes. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.PeeringRoute peering_routes = 1; + * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\PeeringRoute> + */ + public function getPeeringRoutes() + { + return $this->peering_routes; + } + + /** + * A list of peering routes. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.PeeringRoute peering_routes = 1; + * @param \Google\Cloud\VmwareEngine\V1\PeeringRoute[] $var + * @return $this + */ + public function setPeeringRoutes($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\PeeringRoute::class); + $this->peering_routes = $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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateCloudsRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateCloudsRequest.php new file mode 100644 index 000000000000..94a3f7bf545a --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateCloudsRequest.php @@ -0,0 +1,362 @@ +google.cloud.vmwareengine.v1.ListPrivateCloudsRequest + */ +class ListPrivateCloudsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the private cloud to be queried for + * clusters. Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * The maximum number of private clouds to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * Generated from protobuf field int32 page_size = 2; + */ + protected $page_size = 0; + /** + * A page token, received from a previous `ListPrivateClouds` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to `ListPrivateClouds` must + * match the call that provided the page token. + * + * Generated from protobuf field string page_token = 3; + */ + protected $page_token = ''; + /** + * A filter expression that matches resources returned in the response. + * The expression must specify the field name, a comparison operator, and the + * value that you want to use for filtering. The value must be a string, a + * number, or a boolean. The comparison operator must be `=`, `!=`, `>`, or + * `<`. + * For example, if you are filtering a list of private clouds, you can exclude + * the ones named `example-pc` by specifying `name != "example-pc"`. + * You can also filter nested fields. For example, you could specify + * `networkConfig.managementCidr = "192.168.0.0/24"` to include private clouds + * only if they have a matching address in their network configuration. + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "example-pc") + * (createTime > "2021-04-12T08:15:10.40Z") + * ``` + * By default, each expression is an `AND` expression. However, you can + * include `AND` and `OR` expressions explicitly. For example: + * ``` + * (name = "private-cloud-1") AND + * (createTime > "2021-04-12T08:15:10.40Z") OR + * (name = "private-cloud-2") + * ``` + * + * Generated from protobuf field string filter = 4; + */ + protected $filter = ''; + /** + * Sorts list results by a certain order. By default, returned results are + * ordered by `name` in ascending order. You can also sort results in + * descending order based on the `name` value using `orderBy="name desc"`. + * Currently, only ordering by `name` is supported. + * + * Generated from protobuf field string order_by = 5; + */ + protected $order_by = ''; + + /** + * @param string $parent Required. The resource name of the private cloud to be queried for + * clusters. Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a` + * Please see {@see VmwareEngineClient::locationName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\ListPrivateCloudsRequest + * + * @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 private cloud to be queried for + * clusters. Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a` + * @type int $page_size + * The maximum number of private clouds to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * @type string $page_token + * A page token, received from a previous `ListPrivateClouds` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to `ListPrivateClouds` must + * match the call that provided the page token. + * @type string $filter + * A filter expression that matches resources returned in the response. + * The expression must specify the field name, a comparison operator, and the + * value that you want to use for filtering. The value must be a string, a + * number, or a boolean. The comparison operator must be `=`, `!=`, `>`, or + * `<`. + * For example, if you are filtering a list of private clouds, you can exclude + * the ones named `example-pc` by specifying `name != "example-pc"`. + * You can also filter nested fields. For example, you could specify + * `networkConfig.managementCidr = "192.168.0.0/24"` to include private clouds + * only if they have a matching address in their network configuration. + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "example-pc") + * (createTime > "2021-04-12T08:15:10.40Z") + * ``` + * By default, each expression is an `AND` expression. However, you can + * include `AND` and `OR` expressions explicitly. For example: + * ``` + * (name = "private-cloud-1") AND + * (createTime > "2021-04-12T08:15:10.40Z") OR + * (name = "private-cloud-2") + * ``` + * @type string $order_by + * Sorts list results by a certain order. By default, returned results are + * ordered by `name` in ascending order. You can also sort results in + * descending order based on the `name` value using `orderBy="name desc"`. + * Currently, only ordering by `name` is supported. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the private cloud to be queried for + * clusters. Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a` + * + * 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 private cloud to be queried for + * clusters. Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a` + * + * 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 private clouds to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * Generated from protobuf field int32 page_size = 2; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of private clouds to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * 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 `ListPrivateClouds` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to `ListPrivateClouds` 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 `ListPrivateClouds` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to `ListPrivateClouds` 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; + } + + /** + * A filter expression that matches resources returned in the response. + * The expression must specify the field name, a comparison operator, and the + * value that you want to use for filtering. The value must be a string, a + * number, or a boolean. The comparison operator must be `=`, `!=`, `>`, or + * `<`. + * For example, if you are filtering a list of private clouds, you can exclude + * the ones named `example-pc` by specifying `name != "example-pc"`. + * You can also filter nested fields. For example, you could specify + * `networkConfig.managementCidr = "192.168.0.0/24"` to include private clouds + * only if they have a matching address in their network configuration. + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "example-pc") + * (createTime > "2021-04-12T08:15:10.40Z") + * ``` + * By default, each expression is an `AND` expression. However, you can + * include `AND` and `OR` expressions explicitly. For example: + * ``` + * (name = "private-cloud-1") AND + * (createTime > "2021-04-12T08:15:10.40Z") OR + * (name = "private-cloud-2") + * ``` + * + * Generated from protobuf field string filter = 4; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * A filter expression that matches resources returned in the response. + * The expression must specify the field name, a comparison operator, and the + * value that you want to use for filtering. The value must be a string, a + * number, or a boolean. The comparison operator must be `=`, `!=`, `>`, or + * `<`. + * For example, if you are filtering a list of private clouds, you can exclude + * the ones named `example-pc` by specifying `name != "example-pc"`. + * You can also filter nested fields. For example, you could specify + * `networkConfig.managementCidr = "192.168.0.0/24"` to include private clouds + * only if they have a matching address in their network configuration. + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "example-pc") + * (createTime > "2021-04-12T08:15:10.40Z") + * ``` + * By default, each expression is an `AND` expression. However, you can + * include `AND` and `OR` expressions explicitly. For example: + * ``` + * (name = "private-cloud-1") AND + * (createTime > "2021-04-12T08:15:10.40Z") OR + * (name = "private-cloud-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; + } + + /** + * Sorts list results by a certain order. By default, returned results are + * ordered by `name` in ascending order. You can also sort results in + * descending order based on the `name` value using `orderBy="name desc"`. + * Currently, only ordering by `name` is supported. + * + * Generated from protobuf field string order_by = 5; + * @return string + */ + public function getOrderBy() + { + return $this->order_by; + } + + /** + * Sorts list results by a certain order. By default, returned results are + * ordered by `name` in ascending order. You can also sort results in + * descending order based on the `name` value using `orderBy="name desc"`. + * Currently, only ordering by `name` is supported. + * + * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateCloudsResponse.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateCloudsResponse.php new file mode 100644 index 000000000000..d8c40de7920b --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateCloudsResponse.php @@ -0,0 +1,144 @@ +google.cloud.vmwareengine.v1.ListPrivateCloudsResponse + */ +class ListPrivateCloudsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * A list of private clouds. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.PrivateCloud private_clouds = 1; + */ + private $private_clouds; + /** + * 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 = ''; + /** + * Locations that could not be reached when making an aggregated query using + * wildcards. + * + * Generated from protobuf field repeated string unreachable = 3; + */ + private $unreachable; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\VmwareEngine\V1\PrivateCloud[] $private_clouds + * A list of private clouds. + * @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. + * @type string[] $unreachable + * Locations that could not be reached when making an aggregated query using + * wildcards. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * A list of private clouds. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.PrivateCloud private_clouds = 1; + * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\PrivateCloud> + */ + public function getPrivateClouds() + { + return $this->private_clouds; + } + + /** + * A list of private clouds. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.PrivateCloud private_clouds = 1; + * @param \Google\Cloud\VmwareEngine\V1\PrivateCloud[] $var + * @return $this + */ + public function setPrivateClouds($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\PrivateCloud::class); + $this->private_clouds = $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; + } + + /** + * Locations that could not be reached when making an aggregated query using + * wildcards. + * + * Generated from protobuf field repeated string unreachable = 3; + * @return RepeatedField + */ + public function getUnreachable() + { + return $this->unreachable; + } + + /** + * Locations that could not be reached when making an aggregated query using + * wildcards. + * + * Generated from protobuf field repeated string unreachable = 3; + * @param string[] $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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateConnectionPeeringRoutesRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateConnectionPeeringRoutesRequest.php new file mode 100644 index 000000000000..6ad78b75cf5b --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateConnectionPeeringRoutesRequest.php @@ -0,0 +1,189 @@ +google.cloud.vmwareengine.v1.ListPrivateConnectionPeeringRoutesRequest + */ +class ListPrivateConnectionPeeringRoutesRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the private connection to retrieve peering + * routes from. Resource names are schemeless URIs that follow the conventions + * in https://cloud.google.com/apis/design/resource_names. For example: + * `projects/my-project/locations/us-west1/privateConnections/my-connection` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * The maximum number of peering routes to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * Generated from protobuf field int32 page_size = 2; + */ + protected $page_size = 0; + /** + * A page token, received from a previous `ListPrivateConnectionPeeringRoutes` + * call. Provide this to retrieve the subsequent page. When paginating, all + * other parameters provided to `ListPrivateConnectionPeeringRoutes` must + * match the call that provided the page token. + * + * Generated from protobuf field string page_token = 3; + */ + protected $page_token = ''; + + /** + * @param string $parent Required. The resource name of the private connection to retrieve peering + * routes from. Resource names are schemeless URIs that follow the conventions + * in https://cloud.google.com/apis/design/resource_names. For example: + * `projects/my-project/locations/us-west1/privateConnections/my-connection` + * Please see {@see VmwareEngineClient::privateConnectionName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\ListPrivateConnectionPeeringRoutesRequest + * + * @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 private connection to retrieve peering + * routes from. Resource names are schemeless URIs that follow the conventions + * in https://cloud.google.com/apis/design/resource_names. For example: + * `projects/my-project/locations/us-west1/privateConnections/my-connection` + * @type int $page_size + * The maximum number of peering routes to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * @type string $page_token + * A page token, received from a previous `ListPrivateConnectionPeeringRoutes` + * call. Provide this to retrieve the subsequent page. When paginating, all + * other parameters provided to `ListPrivateConnectionPeeringRoutes` must + * match the call that provided the page token. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the private connection to retrieve peering + * routes from. Resource names are schemeless URIs that follow the conventions + * in https://cloud.google.com/apis/design/resource_names. For example: + * `projects/my-project/locations/us-west1/privateConnections/my-connection` + * + * 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 private connection to retrieve peering + * routes from. Resource names are schemeless URIs that follow the conventions + * in https://cloud.google.com/apis/design/resource_names. For example: + * `projects/my-project/locations/us-west1/privateConnections/my-connection` + * + * 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 peering routes to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * Generated from protobuf field int32 page_size = 2; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of peering routes to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * 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 `ListPrivateConnectionPeeringRoutes` + * call. Provide this to retrieve the subsequent page. When paginating, all + * other parameters provided to `ListPrivateConnectionPeeringRoutes` 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 `ListPrivateConnectionPeeringRoutes` + * call. Provide this to retrieve the subsequent page. When paginating, all + * other parameters provided to `ListPrivateConnectionPeeringRoutes` 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; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateConnectionPeeringRoutesResponse.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateConnectionPeeringRoutesResponse.php new file mode 100644 index 000000000000..819633fd4674 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateConnectionPeeringRoutesResponse.php @@ -0,0 +1,106 @@ +google.cloud.vmwareengine.v1.ListPrivateConnectionPeeringRoutesResponse + */ +class ListPrivateConnectionPeeringRoutesResponse extends \Google\Protobuf\Internal\Message +{ + /** + * A list of peering routes. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.PeeringRoute peering_routes = 1; + */ + private $peering_routes; + /** + * 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 \Google\Cloud\VmwareEngine\V1\PeeringRoute[] $peering_routes + * A list of peering routes. + * @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\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * A list of peering routes. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.PeeringRoute peering_routes = 1; + * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\PeeringRoute> + */ + public function getPeeringRoutes() + { + return $this->peering_routes; + } + + /** + * A list of peering routes. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.PeeringRoute peering_routes = 1; + * @param \Google\Cloud\VmwareEngine\V1\PeeringRoute[] $var + * @return $this + */ + public function setPeeringRoutes($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\PeeringRoute::class); + $this->peering_routes = $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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateConnectionsRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateConnectionsRequest.php new file mode 100644 index 000000000000..359db89ccd66 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateConnectionsRequest.php @@ -0,0 +1,357 @@ +google.cloud.vmwareengine.v1.ListPrivateConnectionsRequest + */ +class ListPrivateConnectionsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the location to query for + * private connections. Resource names are schemeless URIs that follow the + * conventions in https://cloud.google.com/apis/design/resource_names. For + * example: `projects/my-project/locations/us-central1` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * The maximum number of private connections to return in one page. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * Generated from protobuf field int32 page_size = 2; + */ + protected $page_size = 0; + /** + * A page token, received from a previous `ListPrivateConnections` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListPrivateConnections` must match the call that provided the page + * token. + * + * Generated from protobuf field string page_token = 3; + */ + protected $page_token = ''; + /** + * A filter expression that matches resources returned in the response. + * The expression must specify the field name, a comparison + * operator, and the value that you want to use for filtering. The value + * must be a string, a number, or a boolean. The comparison operator + * must be `=`, `!=`, `>`, or `<`. + * For example, if you are filtering a list of private connections, you can + * exclude the ones named `example-connection` by specifying + * `name != "example-connection"`. + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "example-connection") + * (createTime > "2022-09-22T08:15:10.40Z") + * ``` + * By default, each expression is an `AND` expression. However, you + * can include `AND` and `OR` expressions explicitly. + * For example: + * ``` + * (name = "example-connection-1") AND + * (createTime > "2021-04-12T08:15:10.40Z") OR + * (name = "example-connection-2") + * ``` + * + * Generated from protobuf field string filter = 4; + */ + protected $filter = ''; + /** + * Sorts list results by a certain order. By default, returned results + * are ordered by `name` in ascending order. + * You can also sort results in descending order based on the `name` value + * using `orderBy="name desc"`. + * Currently, only ordering by `name` is supported. + * + * Generated from protobuf field string order_by = 5; + */ + protected $order_by = ''; + + /** + * @param string $parent Required. The resource name of the location to query for + * private connections. Resource names are schemeless URIs that follow the + * conventions in https://cloud.google.com/apis/design/resource_names. For + * example: `projects/my-project/locations/us-central1` + * Please see {@see VmwareEngineClient::locationName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\ListPrivateConnectionsRequest + * + * @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 location to query for + * private connections. Resource names are schemeless URIs that follow the + * conventions in https://cloud.google.com/apis/design/resource_names. For + * example: `projects/my-project/locations/us-central1` + * @type int $page_size + * The maximum number of private connections to return in one page. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * @type string $page_token + * A page token, received from a previous `ListPrivateConnections` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListPrivateConnections` must match the call that provided the page + * token. + * @type string $filter + * A filter expression that matches resources returned in the response. + * The expression must specify the field name, a comparison + * operator, and the value that you want to use for filtering. The value + * must be a string, a number, or a boolean. The comparison operator + * must be `=`, `!=`, `>`, or `<`. + * For example, if you are filtering a list of private connections, you can + * exclude the ones named `example-connection` by specifying + * `name != "example-connection"`. + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "example-connection") + * (createTime > "2022-09-22T08:15:10.40Z") + * ``` + * By default, each expression is an `AND` expression. However, you + * can include `AND` and `OR` expressions explicitly. + * For example: + * ``` + * (name = "example-connection-1") AND + * (createTime > "2021-04-12T08:15:10.40Z") OR + * (name = "example-connection-2") + * ``` + * @type string $order_by + * Sorts list results by a certain order. By default, returned results + * are ordered by `name` in ascending order. + * You can also sort results in descending order based on the `name` value + * using `orderBy="name desc"`. + * Currently, only ordering by `name` is supported. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the location to query for + * private connections. Resource names are schemeless URIs that follow the + * conventions in https://cloud.google.com/apis/design/resource_names. For + * example: `projects/my-project/locations/us-central1` + * + * 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 to query for + * private connections. Resource names are schemeless URIs that follow the + * conventions in https://cloud.google.com/apis/design/resource_names. For + * example: `projects/my-project/locations/us-central1` + * + * 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 private connections to return in one page. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * Generated from protobuf field int32 page_size = 2; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of private connections to return in one page. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * 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 `ListPrivateConnections` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListPrivateConnections` 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 `ListPrivateConnections` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListPrivateConnections` 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; + } + + /** + * A filter expression that matches resources returned in the response. + * The expression must specify the field name, a comparison + * operator, and the value that you want to use for filtering. The value + * must be a string, a number, or a boolean. The comparison operator + * must be `=`, `!=`, `>`, or `<`. + * For example, if you are filtering a list of private connections, you can + * exclude the ones named `example-connection` by specifying + * `name != "example-connection"`. + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "example-connection") + * (createTime > "2022-09-22T08:15:10.40Z") + * ``` + * By default, each expression is an `AND` expression. However, you + * can include `AND` and `OR` expressions explicitly. + * For example: + * ``` + * (name = "example-connection-1") AND + * (createTime > "2021-04-12T08:15:10.40Z") OR + * (name = "example-connection-2") + * ``` + * + * Generated from protobuf field string filter = 4; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * A filter expression that matches resources returned in the response. + * The expression must specify the field name, a comparison + * operator, and the value that you want to use for filtering. The value + * must be a string, a number, or a boolean. The comparison operator + * must be `=`, `!=`, `>`, or `<`. + * For example, if you are filtering a list of private connections, you can + * exclude the ones named `example-connection` by specifying + * `name != "example-connection"`. + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "example-connection") + * (createTime > "2022-09-22T08:15:10.40Z") + * ``` + * By default, each expression is an `AND` expression. However, you + * can include `AND` and `OR` expressions explicitly. + * For example: + * ``` + * (name = "example-connection-1") AND + * (createTime > "2021-04-12T08:15:10.40Z") OR + * (name = "example-connection-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; + } + + /** + * Sorts list results by a certain order. By default, returned results + * are ordered by `name` in ascending order. + * You can also sort results in descending order based on the `name` value + * using `orderBy="name desc"`. + * Currently, only ordering by `name` is supported. + * + * Generated from protobuf field string order_by = 5; + * @return string + */ + public function getOrderBy() + { + return $this->order_by; + } + + /** + * Sorts list results by a certain order. By default, returned results + * are ordered by `name` in ascending order. + * You can also sort results in descending order based on the `name` value + * using `orderBy="name desc"`. + * Currently, only ordering by `name` is supported. + * + * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateConnectionsResponse.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateConnectionsResponse.php new file mode 100644 index 000000000000..896051d2d01f --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateConnectionsResponse.php @@ -0,0 +1,140 @@ +google.cloud.vmwareengine.v1.ListPrivateConnectionsResponse + */ +class ListPrivateConnectionsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * A list of private connections. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.PrivateConnection private_connections = 1; + */ + private $private_connections; + /** + * 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 = ''; + /** + * Unreachable resources. + * + * Generated from protobuf field repeated string unreachable = 3; + */ + private $unreachable; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\VmwareEngine\V1\PrivateConnection[] $private_connections + * A list of private connections. + * @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. + * @type string[] $unreachable + * Unreachable resources. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * A list of private connections. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.PrivateConnection private_connections = 1; + * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\PrivateConnection> + */ + public function getPrivateConnections() + { + return $this->private_connections; + } + + /** + * A list of private connections. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.PrivateConnection private_connections = 1; + * @param \Google\Cloud\VmwareEngine\V1\PrivateConnection[] $var + * @return $this + */ + public function setPrivateConnections($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\PrivateConnection::class); + $this->private_connections = $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; + } + + /** + * Unreachable resources. + * + * Generated from protobuf field repeated string unreachable = 3; + * @return RepeatedField + */ + public function getUnreachable() + { + return $this->unreachable; + } + + /** + * Unreachable resources. + * + * Generated from protobuf field repeated string unreachable = 3; + * @param string[] $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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListSubnetsRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListSubnetsRequest.php new file mode 100644 index 000000000000..bc4d382af8a1 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListSubnetsRequest.php @@ -0,0 +1,199 @@ +google.cloud.vmwareengine.v1.ListSubnetsRequest + */ +class ListSubnetsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the private cloud to be queried for + * subnets. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $parent = ''; + /** + * The maximum number of subnets to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * Generated from protobuf field int32 page_size = 2; + */ + protected $page_size = 0; + /** + * A page token, received from a previous `ListSubnetsRequest` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListSubnetsRequest` must match the call that provided the page token. + * + * Generated from protobuf field string page_token = 3; + */ + protected $page_token = ''; + + /** + * @param string $parent Required. The resource name of the private cloud to be queried for + * subnets. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * Please see {@see VmwareEngineClient::privateCloudName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\ListSubnetsRequest + * + * @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 private cloud to be queried for + * subnets. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * @type int $page_size + * The maximum number of subnets to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * @type string $page_token + * A page token, received from a previous `ListSubnetsRequest` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListSubnetsRequest` must match the call that provided the page token. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the private cloud to be queried for + * subnets. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * 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 private cloud to be queried for + * subnets. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * 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 subnets to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * Generated from protobuf field int32 page_size = 2; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * The maximum number of subnets to return in one page. + * The service may return fewer than this value. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * 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 `ListSubnetsRequest` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListSubnetsRequest` 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 `ListSubnetsRequest` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListSubnetsRequest` 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; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListSubnetsResponse.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListSubnetsResponse.php new file mode 100644 index 000000000000..b45bff4cb13f --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListSubnetsResponse.php @@ -0,0 +1,144 @@ +google.cloud.vmwareengine.v1.ListSubnetsResponse + */ +class ListSubnetsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * A list of subnets. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.Subnet subnets = 1; + */ + private $subnets; + /** + * 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 = ''; + /** + * Locations that could not be reached when making an aggregated query using + * wildcards. + * + * Generated from protobuf field repeated string unreachable = 3; + */ + private $unreachable; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\VmwareEngine\V1\Subnet[] $subnets + * A list of subnets. + * @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. + * @type string[] $unreachable + * Locations that could not be reached when making an aggregated query using + * wildcards. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * A list of subnets. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.Subnet subnets = 1; + * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\Subnet> + */ + public function getSubnets() + { + return $this->subnets; + } + + /** + * A list of subnets. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.Subnet subnets = 1; + * @param \Google\Cloud\VmwareEngine\V1\Subnet[] $var + * @return $this + */ + public function setSubnets($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\Subnet::class); + $this->subnets = $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; + } + + /** + * Locations that could not be reached when making an aggregated query using + * wildcards. + * + * Generated from protobuf field repeated string unreachable = 3; + * @return RepeatedField + */ + public function getUnreachable() + { + return $this->unreachable; + } + + /** + * Locations that could not be reached when making an aggregated query using + * wildcards. + * + * Generated from protobuf field repeated string unreachable = 3; + * @param string[] $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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListVmwareEngineNetworksRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListVmwareEngineNetworksRequest.php new file mode 100644 index 000000000000..53e40b5677ae --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListVmwareEngineNetworksRequest.php @@ -0,0 +1,357 @@ +google.cloud.vmwareengine.v1.ListVmwareEngineNetworksRequest + */ +class ListVmwareEngineNetworksRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the location to query for + * VMware Engine networks. Resource names are schemeless URIs that follow the + * conventions in https://cloud.google.com/apis/design/resource_names. For + * example: `projects/my-project/locations/global` + * + * 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 one page. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * Generated from protobuf field int32 page_size = 2; + */ + protected $page_size = 0; + /** + * A page token, received from a previous `ListVmwareEngineNetworks` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListVmwareEngineNetworks` must match the call that provided the page + * token. + * + * Generated from protobuf field string page_token = 3; + */ + protected $page_token = ''; + /** + * A filter expression that matches resources returned in the response. + * The expression must specify the field name, a comparison + * operator, and the value that you want to use for filtering. The value + * must be a string, a number, or a boolean. The comparison operator + * must be `=`, `!=`, `>`, or `<`. + * For example, if you are filtering a list of network peerings, you can + * exclude the ones named `example-network` by specifying + * `name != "example-network"`. + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "example-network") + * (createTime > "2021-04-12T08:15:10.40Z") + * ``` + * By default, each expression is an `AND` expression. However, you + * can include `AND` and `OR` expressions explicitly. + * For example: + * ``` + * (name = "example-network-1") AND + * (createTime > "2021-04-12T08:15:10.40Z") OR + * (name = "example-network-2") + * ``` + * + * Generated from protobuf field string filter = 4; + */ + protected $filter = ''; + /** + * Sorts list results by a certain order. By default, returned results + * are ordered by `name` in ascending order. + * You can also sort results in descending order based on the `name` value + * using `orderBy="name desc"`. + * Currently, only ordering by `name` is supported. + * + * Generated from protobuf field string order_by = 5; + */ + protected $order_by = ''; + + /** + * @param string $parent Required. The resource name of the location to query for + * VMware Engine networks. Resource names are schemeless URIs that follow the + * conventions in https://cloud.google.com/apis/design/resource_names. For + * example: `projects/my-project/locations/global` + * Please see {@see VmwareEngineClient::locationName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\ListVmwareEngineNetworksRequest + * + * @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 location to query for + * VMware Engine networks. Resource names are schemeless URIs that follow the + * conventions in https://cloud.google.com/apis/design/resource_names. For + * example: `projects/my-project/locations/global` + * @type int $page_size + * The maximum number of results to return in one page. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * @type string $page_token + * A page token, received from a previous `ListVmwareEngineNetworks` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListVmwareEngineNetworks` must match the call that provided the page + * token. + * @type string $filter + * A filter expression that matches resources returned in the response. + * The expression must specify the field name, a comparison + * operator, and the value that you want to use for filtering. The value + * must be a string, a number, or a boolean. The comparison operator + * must be `=`, `!=`, `>`, or `<`. + * For example, if you are filtering a list of network peerings, you can + * exclude the ones named `example-network` by specifying + * `name != "example-network"`. + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "example-network") + * (createTime > "2021-04-12T08:15:10.40Z") + * ``` + * By default, each expression is an `AND` expression. However, you + * can include `AND` and `OR` expressions explicitly. + * For example: + * ``` + * (name = "example-network-1") AND + * (createTime > "2021-04-12T08:15:10.40Z") OR + * (name = "example-network-2") + * ``` + * @type string $order_by + * Sorts list results by a certain order. By default, returned results + * are ordered by `name` in ascending order. + * You can also sort results in descending order based on the `name` value + * using `orderBy="name desc"`. + * Currently, only ordering by `name` is supported. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the location to query for + * VMware Engine networks. Resource names are schemeless URIs that follow the + * conventions in https://cloud.google.com/apis/design/resource_names. For + * example: `projects/my-project/locations/global` + * + * 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 to query for + * VMware Engine networks. Resource names are schemeless URIs that follow the + * conventions in https://cloud.google.com/apis/design/resource_names. For + * example: `projects/my-project/locations/global` + * + * 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 one page. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * 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 one page. + * The maximum value is coerced to 1000. + * The default value of this field is 500. + * + * 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 `ListVmwareEngineNetworks` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListVmwareEngineNetworks` 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 `ListVmwareEngineNetworks` call. + * Provide this to retrieve the subsequent page. + * When paginating, all other parameters provided to + * `ListVmwareEngineNetworks` 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; + } + + /** + * A filter expression that matches resources returned in the response. + * The expression must specify the field name, a comparison + * operator, and the value that you want to use for filtering. The value + * must be a string, a number, or a boolean. The comparison operator + * must be `=`, `!=`, `>`, or `<`. + * For example, if you are filtering a list of network peerings, you can + * exclude the ones named `example-network` by specifying + * `name != "example-network"`. + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "example-network") + * (createTime > "2021-04-12T08:15:10.40Z") + * ``` + * By default, each expression is an `AND` expression. However, you + * can include `AND` and `OR` expressions explicitly. + * For example: + * ``` + * (name = "example-network-1") AND + * (createTime > "2021-04-12T08:15:10.40Z") OR + * (name = "example-network-2") + * ``` + * + * Generated from protobuf field string filter = 4; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * A filter expression that matches resources returned in the response. + * The expression must specify the field name, a comparison + * operator, and the value that you want to use for filtering. The value + * must be a string, a number, or a boolean. The comparison operator + * must be `=`, `!=`, `>`, or `<`. + * For example, if you are filtering a list of network peerings, you can + * exclude the ones named `example-network` by specifying + * `name != "example-network"`. + * To filter on multiple expressions, provide each separate expression within + * parentheses. For example: + * ``` + * (name = "example-network") + * (createTime > "2021-04-12T08:15:10.40Z") + * ``` + * By default, each expression is an `AND` expression. However, you + * can include `AND` and `OR` expressions explicitly. + * For example: + * ``` + * (name = "example-network-1") AND + * (createTime > "2021-04-12T08:15:10.40Z") OR + * (name = "example-network-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; + } + + /** + * Sorts list results by a certain order. By default, returned results + * are ordered by `name` in ascending order. + * You can also sort results in descending order based on the `name` value + * using `orderBy="name desc"`. + * Currently, only ordering by `name` is supported. + * + * Generated from protobuf field string order_by = 5; + * @return string + */ + public function getOrderBy() + { + return $this->order_by; + } + + /** + * Sorts list results by a certain order. By default, returned results + * are ordered by `name` in ascending order. + * You can also sort results in descending order based on the `name` value + * using `orderBy="name desc"`. + * Currently, only ordering by `name` is supported. + * + * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListVmwareEngineNetworksResponse.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListVmwareEngineNetworksResponse.php new file mode 100644 index 000000000000..545b85498aec --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListVmwareEngineNetworksResponse.php @@ -0,0 +1,140 @@ +google.cloud.vmwareengine.v1.ListVmwareEngineNetworksResponse + */ +class ListVmwareEngineNetworksResponse extends \Google\Protobuf\Internal\Message +{ + /** + * A list of VMware Engine networks. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.VmwareEngineNetwork vmware_engine_networks = 1; + */ + private $vmware_engine_networks; + /** + * 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 = ''; + /** + * Unreachable resources. + * + * Generated from protobuf field repeated string unreachable = 3; + */ + private $unreachable; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork[] $vmware_engine_networks + * A list of VMware Engine networks. + * @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. + * @type string[] $unreachable + * Unreachable resources. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * A list of VMware Engine networks. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.VmwareEngineNetwork vmware_engine_networks = 1; + * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork> + */ + public function getVmwareEngineNetworks() + { + return $this->vmware_engine_networks; + } + + /** + * A list of VMware Engine networks. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.VmwareEngineNetwork vmware_engine_networks = 1; + * @param \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork[] $var + * @return $this + */ + public function setVmwareEngineNetworks($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork::class); + $this->vmware_engine_networks = $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; + } + + /** + * Unreachable resources. + * + * Generated from protobuf field repeated string unreachable = 3; + * @return RepeatedField + */ + public function getUnreachable() + { + return $this->unreachable; + } + + /** + * Unreachable resources. + * + * Generated from protobuf field repeated string unreachable = 3; + * @param string[] $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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/LocationMetadata.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/LocationMetadata.php new file mode 100644 index 000000000000..a7d4e18c47bd --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/LocationMetadata.php @@ -0,0 +1,69 @@ +google.cloud.vmwareengine.v1.LocationMetadata + */ +class LocationMetadata extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. Capabilities of this location. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.LocationMetadata.Capability capabilities = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + private $capabilities; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int[] $capabilities + * Output only. Capabilities of this location. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); + parent::__construct($data); + } + + /** + * Output only. Capabilities of this location. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.LocationMetadata.Capability capabilities = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return RepeatedField + */ + public function getCapabilities() + { + return $this->capabilities; + } + + /** + * Output only. Capabilities of this location. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.LocationMetadata.Capability capabilities = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int[] $var + * @return $this + */ + public function setCapabilities($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\VmwareEngine\V1\LocationMetadata\Capability::class); + $this->capabilities = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/LocationMetadata/Capability.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/LocationMetadata/Capability.php new file mode 100644 index 000000000000..5281e51d1173 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/LocationMetadata/Capability.php @@ -0,0 +1,55 @@ +google.cloud.vmwareengine.v1.LocationMetadata.Capability + */ +class Capability +{ + /** + * The default value. This value is used if the capability is omitted or + * unknown. + * + * Generated from protobuf enum CAPABILITY_UNSPECIFIED = 0; + */ + const CAPABILITY_UNSPECIFIED = 0; + /** + * Stretch clusters are supported in this location. + * + * Generated from protobuf enum STRETCHED_CLUSTERS = 1; + */ + const STRETCHED_CLUSTERS = 1; + + private static $valueToName = [ + self::CAPABILITY_UNSPECIFIED => 'CAPABILITY_UNSPECIFIED', + self::STRETCHED_CLUSTERS => 'STRETCHED_CLUSTERS', + ]; + + 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/LoggingServer.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/LoggingServer.php new file mode 100644 index 000000000000..0e8f6b86a56a --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/LoggingServer.php @@ -0,0 +1,349 @@ +google.cloud.vmwareengine.v1.LoggingServer + */ +class LoggingServer extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. The resource name of this logging server. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/loggingServers/my-logging-server` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $name = ''; + /** + * Output only. Creation time of this resource. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $create_time = null; + /** + * Output only. Last update time of this resource. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $update_time = null; + /** + * Required. Fully-qualified domain name (FQDN) or IP Address of the logging + * server. + * + * Generated from protobuf field string hostname = 5 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $hostname = ''; + /** + * Required. Port number at which the logging server receives logs. + * + * Generated from protobuf field int32 port = 7 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $port = 0; + /** + * Required. Protocol used by vCenter to send logs to a logging server. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.LoggingServer.Protocol protocol = 6 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $protocol = 0; + /** + * Required. The type of component that produces logs that will be forwarded + * to this logging server. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.LoggingServer.SourceType source_type = 10 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $source_type = 0; + /** + * Output only. System-generated unique identifier for the resource. + * + * Generated from protobuf field string uid = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $uid = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Output only. The resource name of this logging server. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/loggingServers/my-logging-server` + * @type \Google\Protobuf\Timestamp $create_time + * Output only. Creation time of this resource. + * @type \Google\Protobuf\Timestamp $update_time + * Output only. Last update time of this resource. + * @type string $hostname + * Required. Fully-qualified domain name (FQDN) or IP Address of the logging + * server. + * @type int $port + * Required. Port number at which the logging server receives logs. + * @type int $protocol + * Required. Protocol used by vCenter to send logs to a logging server. + * @type int $source_type + * Required. The type of component that produces logs that will be forwarded + * to this logging server. + * @type string $uid + * Output only. System-generated unique identifier for the resource. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); + parent::__construct($data); + } + + /** + * Output only. The resource name of this logging server. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/loggingServers/my-logging-server` + * + * 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 logging server. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/loggingServers/my-logging-server` + * + * 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. Creation time of this resource. + * + * 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 time of this resource. + * + * 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 time of this resource. + * + * 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 time of this resource. + * + * 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; + } + + /** + * Required. Fully-qualified domain name (FQDN) or IP Address of the logging + * server. + * + * Generated from protobuf field string hostname = 5 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getHostname() + { + return $this->hostname; + } + + /** + * Required. Fully-qualified domain name (FQDN) or IP Address of the logging + * server. + * + * Generated from protobuf field string hostname = 5 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setHostname($var) + { + GPBUtil::checkString($var, True); + $this->hostname = $var; + + return $this; + } + + /** + * Required. Port number at which the logging server receives logs. + * + * Generated from protobuf field int32 port = 7 [(.google.api.field_behavior) = REQUIRED]; + * @return int + */ + public function getPort() + { + return $this->port; + } + + /** + * Required. Port number at which the logging server receives logs. + * + * Generated from protobuf field int32 port = 7 [(.google.api.field_behavior) = REQUIRED]; + * @param int $var + * @return $this + */ + public function setPort($var) + { + GPBUtil::checkInt32($var); + $this->port = $var; + + return $this; + } + + /** + * Required. Protocol used by vCenter to send logs to a logging server. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.LoggingServer.Protocol protocol = 6 [(.google.api.field_behavior) = REQUIRED]; + * @return int + */ + public function getProtocol() + { + return $this->protocol; + } + + /** + * Required. Protocol used by vCenter to send logs to a logging server. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.LoggingServer.Protocol protocol = 6 [(.google.api.field_behavior) = REQUIRED]; + * @param int $var + * @return $this + */ + public function setProtocol($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\LoggingServer\Protocol::class); + $this->protocol = $var; + + return $this; + } + + /** + * Required. The type of component that produces logs that will be forwarded + * to this logging server. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.LoggingServer.SourceType source_type = 10 [(.google.api.field_behavior) = REQUIRED]; + * @return int + */ + public function getSourceType() + { + return $this->source_type; + } + + /** + * Required. The type of component that produces logs that will be forwarded + * to this logging server. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.LoggingServer.SourceType source_type = 10 [(.google.api.field_behavior) = REQUIRED]; + * @param int $var + * @return $this + */ + public function setSourceType($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\LoggingServer\SourceType::class); + $this->source_type = $var; + + return $this; + } + + /** + * Output only. System-generated unique identifier for the resource. + * + * Generated from protobuf field string uid = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getUid() + { + return $this->uid; + } + + /** + * Output only. System-generated unique identifier for the resource. + * + * Generated from protobuf field string uid = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setUid($var) + { + GPBUtil::checkString($var, True); + $this->uid = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/LoggingServer/Protocol.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/LoggingServer/Protocol.php new file mode 100644 index 000000000000..a60562691b80 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/LoggingServer/Protocol.php @@ -0,0 +1,83 @@ +google.cloud.vmwareengine.v1.LoggingServer.Protocol + */ +class Protocol +{ + /** + * Unspecified communications protocol. This is the default value. + * + * Generated from protobuf enum PROTOCOL_UNSPECIFIED = 0; + */ + const PROTOCOL_UNSPECIFIED = 0; + /** + * UDP + * + * Generated from protobuf enum UDP = 1; + */ + const UDP = 1; + /** + * TCP + * + * Generated from protobuf enum TCP = 2; + */ + const TCP = 2; + /** + * TLS + * + * Generated from protobuf enum TLS = 3; + */ + const TLS = 3; + /** + * SSL + * + * Generated from protobuf enum SSL = 4; + */ + const SSL = 4; + /** + * RELP + * + * Generated from protobuf enum RELP = 5; + */ + const RELP = 5; + + private static $valueToName = [ + self::PROTOCOL_UNSPECIFIED => 'PROTOCOL_UNSPECIFIED', + self::UDP => 'UDP', + self::TCP => 'TCP', + self::TLS => 'TLS', + self::SSL => 'SSL', + self::RELP => 'RELP', + ]; + + 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/LoggingServer/SourceType.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/LoggingServer/SourceType.php new file mode 100644 index 000000000000..41cf7665c85a --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/LoggingServer/SourceType.php @@ -0,0 +1,61 @@ +google.cloud.vmwareengine.v1.LoggingServer.SourceType + */ +class SourceType +{ + /** + * The default value. This value should never be used. + * + * Generated from protobuf enum SOURCE_TYPE_UNSPECIFIED = 0; + */ + const SOURCE_TYPE_UNSPECIFIED = 0; + /** + * Logs produced by ESXI hosts + * + * Generated from protobuf enum ESXI = 1; + */ + const ESXI = 1; + /** + * Logs produced by vCenter server + * + * Generated from protobuf enum VCSA = 2; + */ + const VCSA = 2; + + private static $valueToName = [ + self::SOURCE_TYPE_UNSPECIFIED => 'SOURCE_TYPE_UNSPECIFIED', + self::ESXI => 'ESXI', + self::VCSA => 'VCSA', + ]; + + 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ManagementDnsZoneBinding.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ManagementDnsZoneBinding.php new file mode 100644 index 000000000000..4a48628993fa --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ManagementDnsZoneBinding.php @@ -0,0 +1,370 @@ +google.cloud.vmwareengine.v1.ManagementDnsZoneBinding + */ +class ManagementDnsZoneBinding extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. The resource name of this binding. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/managementDnsZoneBindings/my-management-dns-zone-binding` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $name = ''; + /** + * Output only. Creation time of this resource. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $create_time = null; + /** + * Output only. Last update time of this resource. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $update_time = null; + /** + * Output only. The state of the resource. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.ManagementDnsZoneBinding.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $state = 0; + /** + * User-provided description for this resource. + * + * Generated from protobuf field string description = 13; + */ + protected $description = ''; + /** + * Output only. System-generated unique identifier for the resource. + * + * Generated from protobuf field string uid = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $uid = ''; + protected $bind_network; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Output only. The resource name of this binding. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/managementDnsZoneBindings/my-management-dns-zone-binding` + * @type \Google\Protobuf\Timestamp $create_time + * Output only. Creation time of this resource. + * @type \Google\Protobuf\Timestamp $update_time + * Output only. Last update time of this resource. + * @type int $state + * Output only. The state of the resource. + * @type string $description + * User-provided description for this resource. + * @type string $vpc_network + * Network to bind is a standard consumer VPC. + * Specify the name in the following form for consumer + * VPC network: `projects/{project}/global/networks/{network_id}`. + * `{project}` can either be a project number or a project ID. + * @type string $vmware_engine_network + * Network to bind is a VMware Engine network. + * Specify the name in the following form for VMware engine network: + * `projects/{project}/locations/global/vmwareEngineNetworks/{vmware_engine_network_id}`. + * `{project}` can either be a project number or a project ID. + * @type string $uid + * Output only. System-generated unique identifier for the resource. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); + parent::__construct($data); + } + + /** + * Output only. The resource name of this binding. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/managementDnsZoneBindings/my-management-dns-zone-binding` + * + * 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 binding. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/managementDnsZoneBindings/my-management-dns-zone-binding` + * + * 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. Creation time of this resource. + * + * 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 time of this resource. + * + * 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 time of this resource. + * + * 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 time of this resource. + * + * 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 state of the resource. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.ManagementDnsZoneBinding.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getState() + { + return $this->state; + } + + /** + * Output only. The state of the resource. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.ManagementDnsZoneBinding.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setState($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\ManagementDnsZoneBinding\State::class); + $this->state = $var; + + return $this; + } + + /** + * User-provided description for this resource. + * + * Generated from protobuf field string description = 13; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * User-provided description for this resource. + * + * Generated from protobuf field string description = 13; + * @param string $var + * @return $this + */ + public function setDescription($var) + { + GPBUtil::checkString($var, True); + $this->description = $var; + + return $this; + } + + /** + * Network to bind is a standard consumer VPC. + * Specify the name in the following form for consumer + * VPC network: `projects/{project}/global/networks/{network_id}`. + * `{project}` can either be a project number or a project ID. + * + * Generated from protobuf field string vpc_network = 14 [(.google.api.resource_reference) = { + * @return string + */ + public function getVpcNetwork() + { + return $this->readOneof(14); + } + + public function hasVpcNetwork() + { + return $this->hasOneof(14); + } + + /** + * Network to bind is a standard consumer VPC. + * Specify the name in the following form for consumer + * VPC network: `projects/{project}/global/networks/{network_id}`. + * `{project}` can either be a project number or a project ID. + * + * Generated from protobuf field string vpc_network = 14 [(.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setVpcNetwork($var) + { + GPBUtil::checkString($var, True); + $this->writeOneof(14, $var); + + return $this; + } + + /** + * Network to bind is a VMware Engine network. + * Specify the name in the following form for VMware engine network: + * `projects/{project}/locations/global/vmwareEngineNetworks/{vmware_engine_network_id}`. + * `{project}` can either be a project number or a project ID. + * + * Generated from protobuf field string vmware_engine_network = 15 [(.google.api.resource_reference) = { + * @return string + */ + public function getVmwareEngineNetwork() + { + return $this->readOneof(15); + } + + public function hasVmwareEngineNetwork() + { + return $this->hasOneof(15); + } + + /** + * Network to bind is a VMware Engine network. + * Specify the name in the following form for VMware engine network: + * `projects/{project}/locations/global/vmwareEngineNetworks/{vmware_engine_network_id}`. + * `{project}` can either be a project number or a project ID. + * + * Generated from protobuf field string vmware_engine_network = 15 [(.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setVmwareEngineNetwork($var) + { + GPBUtil::checkString($var, True); + $this->writeOneof(15, $var); + + return $this; + } + + /** + * Output only. System-generated unique identifier for the resource. + * + * Generated from protobuf field string uid = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getUid() + { + return $this->uid; + } + + /** + * Output only. System-generated unique identifier for the resource. + * + * Generated from protobuf field string uid = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setUid($var) + { + GPBUtil::checkString($var, True); + $this->uid = $var; + + return $this; + } + + /** + * @return string + */ + public function getBindNetwork() + { + return $this->whichOneof("bind_network"); + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ManagementDnsZoneBinding/State.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ManagementDnsZoneBinding/State.php new file mode 100644 index 000000000000..266e357e393b --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ManagementDnsZoneBinding/State.php @@ -0,0 +1,83 @@ +google.cloud.vmwareengine.v1.ManagementDnsZoneBinding.State + */ +class State +{ + /** + * The default value. This value should never be used. + * + * Generated from protobuf enum STATE_UNSPECIFIED = 0; + */ + const STATE_UNSPECIFIED = 0; + /** + * The binding is ready. + * + * Generated from protobuf enum ACTIVE = 1; + */ + const ACTIVE = 1; + /** + * The binding is being created. + * + * Generated from protobuf enum CREATING = 2; + */ + const CREATING = 2; + /** + * The binding is being updated. + * + * Generated from protobuf enum UPDATING = 3; + */ + const UPDATING = 3; + /** + * The binding is being deleted. + * + * Generated from protobuf enum DELETING = 4; + */ + const DELETING = 4; + /** + * The binding has failed. + * + * Generated from protobuf enum FAILED = 5; + */ + const FAILED = 5; + + private static $valueToName = [ + self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', + self::ACTIVE => 'ACTIVE', + self::CREATING => 'CREATING', + 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); + } +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkConfig.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkConfig.php new file mode 100644 index 000000000000..da1e9832d563 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkConfig.php @@ -0,0 +1,260 @@ +google.cloud.vmwareengine.v1.NetworkConfig + */ +class NetworkConfig extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Management CIDR used by VMware management appliances. + * + * Generated from protobuf field string management_cidr = 4 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $management_cidr = ''; + /** + * Optional. The relative resource name of the VMware Engine network attached + * to the private cloud. Specify the name in the following form: + * `projects/{project}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` + * where `{project}` can either be a project number or a project ID. + * + * Generated from protobuf field string vmware_engine_network = 5 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { + */ + protected $vmware_engine_network = ''; + /** + * Output only. The canonical name of the VMware Engine network in the form: + * `projects/{project_number}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` + * + * Generated from protobuf field string vmware_engine_network_canonical = 6 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { + */ + protected $vmware_engine_network_canonical = ''; + /** + * Output only. The IP address layout version of the management IP address + * range. Possible versions include: + * * `managementIpAddressLayoutVersion=1`: Indicates the legacy IP address + * layout used by some existing private clouds. This is no longer supported + * for new private clouds as it does not support all features. + * * `managementIpAddressLayoutVersion=2`: Indicates the latest IP address + * layout used by all newly created private clouds. This version supports all + * current features. + * + * Generated from protobuf field int32 management_ip_address_layout_version = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $management_ip_address_layout_version = 0; + /** + * Output only. DNS Server IP of the Private Cloud. + * All DNS queries can be forwarded to this address for name resolution of + * Private Cloud's management entities like vCenter, NSX-T Manager and + * ESXi hosts. + * + * Generated from protobuf field string dns_server_ip = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $dns_server_ip = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $management_cidr + * Required. Management CIDR used by VMware management appliances. + * @type string $vmware_engine_network + * Optional. The relative resource name of the VMware Engine network attached + * to the private cloud. Specify the name in the following form: + * `projects/{project}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` + * where `{project}` can either be a project number or a project ID. + * @type string $vmware_engine_network_canonical + * Output only. The canonical name of the VMware Engine network in the form: + * `projects/{project_number}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` + * @type int $management_ip_address_layout_version + * Output only. The IP address layout version of the management IP address + * range. Possible versions include: + * * `managementIpAddressLayoutVersion=1`: Indicates the legacy IP address + * layout used by some existing private clouds. This is no longer supported + * for new private clouds as it does not support all features. + * * `managementIpAddressLayoutVersion=2`: Indicates the latest IP address + * layout used by all newly created private clouds. This version supports all + * current features. + * @type string $dns_server_ip + * Output only. DNS Server IP of the Private Cloud. + * All DNS queries can be forwarded to this address for name resolution of + * Private Cloud's management entities like vCenter, NSX-T Manager and + * ESXi hosts. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); + parent::__construct($data); + } + + /** + * Required. Management CIDR used by VMware management appliances. + * + * Generated from protobuf field string management_cidr = 4 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getManagementCidr() + { + return $this->management_cidr; + } + + /** + * Required. Management CIDR used by VMware management appliances. + * + * Generated from protobuf field string management_cidr = 4 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setManagementCidr($var) + { + GPBUtil::checkString($var, True); + $this->management_cidr = $var; + + return $this; + } + + /** + * Optional. The relative resource name of the VMware Engine network attached + * to the private cloud. Specify the name in the following form: + * `projects/{project}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` + * where `{project}` can either be a project number or a project ID. + * + * Generated from protobuf field string vmware_engine_network = 5 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { + * @return string + */ + public function getVmwareEngineNetwork() + { + return $this->vmware_engine_network; + } + + /** + * Optional. The relative resource name of the VMware Engine network attached + * to the private cloud. Specify the name in the following form: + * `projects/{project}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` + * where `{project}` can either be a project number or a project ID. + * + * Generated from protobuf field string vmware_engine_network = 5 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setVmwareEngineNetwork($var) + { + GPBUtil::checkString($var, True); + $this->vmware_engine_network = $var; + + return $this; + } + + /** + * Output only. The canonical name of the VMware Engine network in the form: + * `projects/{project_number}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` + * + * Generated from protobuf field string vmware_engine_network_canonical = 6 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { + * @return string + */ + public function getVmwareEngineNetworkCanonical() + { + return $this->vmware_engine_network_canonical; + } + + /** + * Output only. The canonical name of the VMware Engine network in the form: + * `projects/{project_number}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` + * + * Generated from protobuf field string vmware_engine_network_canonical = 6 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setVmwareEngineNetworkCanonical($var) + { + GPBUtil::checkString($var, True); + $this->vmware_engine_network_canonical = $var; + + return $this; + } + + /** + * Output only. The IP address layout version of the management IP address + * range. Possible versions include: + * * `managementIpAddressLayoutVersion=1`: Indicates the legacy IP address + * layout used by some existing private clouds. This is no longer supported + * for new private clouds as it does not support all features. + * * `managementIpAddressLayoutVersion=2`: Indicates the latest IP address + * layout used by all newly created private clouds. This version supports all + * current features. + * + * Generated from protobuf field int32 management_ip_address_layout_version = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getManagementIpAddressLayoutVersion() + { + return $this->management_ip_address_layout_version; + } + + /** + * Output only. The IP address layout version of the management IP address + * range. Possible versions include: + * * `managementIpAddressLayoutVersion=1`: Indicates the legacy IP address + * layout used by some existing private clouds. This is no longer supported + * for new private clouds as it does not support all features. + * * `managementIpAddressLayoutVersion=2`: Indicates the latest IP address + * layout used by all newly created private clouds. This version supports all + * current features. + * + * Generated from protobuf field int32 management_ip_address_layout_version = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setManagementIpAddressLayoutVersion($var) + { + GPBUtil::checkInt32($var); + $this->management_ip_address_layout_version = $var; + + return $this; + } + + /** + * Output only. DNS Server IP of the Private Cloud. + * All DNS queries can be forwarded to this address for name resolution of + * Private Cloud's management entities like vCenter, NSX-T Manager and + * ESXi hosts. + * + * Generated from protobuf field string dns_server_ip = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getDnsServerIp() + { + return $this->dns_server_ip; + } + + /** + * Output only. DNS Server IP of the Private Cloud. + * All DNS queries can be forwarded to this address for name resolution of + * Private Cloud's management entities like vCenter, NSX-T Manager and + * ESXi hosts. + * + * Generated from protobuf field string dns_server_ip = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setDnsServerIp($var) + { + GPBUtil::checkString($var, True); + $this->dns_server_ip = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPeering.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPeering.php new file mode 100644 index 000000000000..2f041ffc4656 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPeering.php @@ -0,0 +1,775 @@ +google.cloud.vmwareengine.v1.NetworkPeering + */ +class NetworkPeering extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. The resource name of the network peering. NetworkPeering is a + * global resource and location can only be global. Resource names are + * scheme-less URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/global/networkPeerings/my-peering` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $name = ''; + /** + * Output only. Creation time of this resource. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $create_time = null; + /** + * Output only. Last update time of this resource. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $update_time = null; + /** + * Required. The relative resource name of the network to peer with + * a standard VMware Engine network. The provided network can be a + * consumer VPC network or another standard VMware Engine network. If the + * `peer_network_type` is VMWARE_ENGINE_NETWORK, specify the name in the form: + * `projects/{project}/locations/global/vmwareEngineNetworks/{vmware_engine_network_id}`. + * Otherwise specify the name in the form: + * `projects/{project}/global/networks/{network_id}`, where + * `{project}` can either be a project number or a project ID. + * + * Generated from protobuf field string peer_network = 5 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $peer_network = ''; + /** + * Optional. True if custom routes are exported to the peered network; + * false otherwise. The default value is true. + * + * Generated from protobuf field optional bool export_custom_routes = 8 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $export_custom_routes = null; + /** + * Optional. True if custom routes are imported from the peered network; + * false otherwise. The default value is true. + * + * Generated from protobuf field optional bool import_custom_routes = 9 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $import_custom_routes = null; + /** + * Optional. True if full mesh connectivity is created and managed + * automatically between peered networks; false otherwise. Currently this + * field is always true because Google Compute Engine automatically creates + * and manages subnetwork routes between two VPC networks when peering state + * is 'ACTIVE'. + * + * Generated from protobuf field optional bool exchange_subnet_routes = 10 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $exchange_subnet_routes = null; + /** + * Optional. True if all subnet routes with a public IP address range are + * exported; false otherwise. The default value is true. IPv4 special-use + * ranges (https://en.wikipedia.org/wiki/IPv4#Special_addresses) are always + * exported to peers and are not controlled by this field. + * + * Generated from protobuf field optional bool export_custom_routes_with_public_ip = 11 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $export_custom_routes_with_public_ip = null; + /** + * Optional. True if all subnet routes with public IP address range are + * imported; false otherwise. The default value is true. IPv4 special-use + * ranges (https://en.wikipedia.org/wiki/IPv4#Special_addresses) are always + * imported to peers and are not controlled by this field. + * + * Generated from protobuf field optional bool import_custom_routes_with_public_ip = 12 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $import_custom_routes_with_public_ip = null; + /** + * Output only. State of the network peering. This field + * has a value of 'ACTIVE' when there's a matching configuration in the peer + * network. New values may be added to this enum when appropriate. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPeering.State state = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $state = 0; + /** + * Output only. Output Only. Details about the current state of the network + * peering. + * + * Generated from protobuf field string state_details = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $state_details = ''; + /** + * Optional. Maximum transmission unit (MTU) in bytes. + * The default value is `1500`. If a value of `0` is provided for this field, + * VMware Engine uses the default value instead. + * + * Generated from protobuf field int32 peer_mtu = 14 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $peer_mtu = 0; + /** + * Required. The type of the network to peer with the VMware Engine network. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPeering.PeerNetworkType peer_network_type = 16 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $peer_network_type = 0; + /** + * Output only. System-generated unique identifier for the resource. + * + * Generated from protobuf field string uid = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $uid = ''; + /** + * Required. The relative resource name of the VMware Engine network. + * Specify the name in the following form: + * `projects/{project}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` + * where `{project}` can either be a project number or a project ID. + * + * Generated from protobuf field string vmware_engine_network = 20 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $vmware_engine_network = ''; + /** + * Optional. User-provided description for this network peering. + * + * Generated from protobuf field string description = 21 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $description = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Output only. The resource name of the network peering. NetworkPeering is a + * global resource and location can only be global. Resource names are + * scheme-less URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/global/networkPeerings/my-peering` + * @type \Google\Protobuf\Timestamp $create_time + * Output only. Creation time of this resource. + * @type \Google\Protobuf\Timestamp $update_time + * Output only. Last update time of this resource. + * @type string $peer_network + * Required. The relative resource name of the network to peer with + * a standard VMware Engine network. The provided network can be a + * consumer VPC network or another standard VMware Engine network. If the + * `peer_network_type` is VMWARE_ENGINE_NETWORK, specify the name in the form: + * `projects/{project}/locations/global/vmwareEngineNetworks/{vmware_engine_network_id}`. + * Otherwise specify the name in the form: + * `projects/{project}/global/networks/{network_id}`, where + * `{project}` can either be a project number or a project ID. + * @type bool $export_custom_routes + * Optional. True if custom routes are exported to the peered network; + * false otherwise. The default value is true. + * @type bool $import_custom_routes + * Optional. True if custom routes are imported from the peered network; + * false otherwise. The default value is true. + * @type bool $exchange_subnet_routes + * Optional. True if full mesh connectivity is created and managed + * automatically between peered networks; false otherwise. Currently this + * field is always true because Google Compute Engine automatically creates + * and manages subnetwork routes between two VPC networks when peering state + * is 'ACTIVE'. + * @type bool $export_custom_routes_with_public_ip + * Optional. True if all subnet routes with a public IP address range are + * exported; false otherwise. The default value is true. IPv4 special-use + * ranges (https://en.wikipedia.org/wiki/IPv4#Special_addresses) are always + * exported to peers and are not controlled by this field. + * @type bool $import_custom_routes_with_public_ip + * Optional. True if all subnet routes with public IP address range are + * imported; false otherwise. The default value is true. IPv4 special-use + * ranges (https://en.wikipedia.org/wiki/IPv4#Special_addresses) are always + * imported to peers and are not controlled by this field. + * @type int $state + * Output only. State of the network peering. This field + * has a value of 'ACTIVE' when there's a matching configuration in the peer + * network. New values may be added to this enum when appropriate. + * @type string $state_details + * Output only. Output Only. Details about the current state of the network + * peering. + * @type int $peer_mtu + * Optional. Maximum transmission unit (MTU) in bytes. + * The default value is `1500`. If a value of `0` is provided for this field, + * VMware Engine uses the default value instead. + * @type int $peer_network_type + * Required. The type of the network to peer with the VMware Engine network. + * @type string $uid + * Output only. System-generated unique identifier for the resource. + * @type string $vmware_engine_network + * Required. The relative resource name of the VMware Engine network. + * Specify the name in the following form: + * `projects/{project}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` + * where `{project}` can either be a project number or a project ID. + * @type string $description + * Optional. User-provided description for this network peering. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); + parent::__construct($data); + } + + /** + * Output only. The resource name of the network peering. NetworkPeering is a + * global resource and location can only be global. Resource names are + * scheme-less URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/global/networkPeerings/my-peering` + * + * 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 network peering. NetworkPeering is a + * global resource and location can only be global. Resource names are + * scheme-less URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/global/networkPeerings/my-peering` + * + * 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. Creation time of this resource. + * + * 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 time of this resource. + * + * 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 time of this resource. + * + * 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 time of this resource. + * + * 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; + } + + /** + * Required. The relative resource name of the network to peer with + * a standard VMware Engine network. The provided network can be a + * consumer VPC network or another standard VMware Engine network. If the + * `peer_network_type` is VMWARE_ENGINE_NETWORK, specify the name in the form: + * `projects/{project}/locations/global/vmwareEngineNetworks/{vmware_engine_network_id}`. + * Otherwise specify the name in the form: + * `projects/{project}/global/networks/{network_id}`, where + * `{project}` can either be a project number or a project ID. + * + * Generated from protobuf field string peer_network = 5 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getPeerNetwork() + { + return $this->peer_network; + } + + /** + * Required. The relative resource name of the network to peer with + * a standard VMware Engine network. The provided network can be a + * consumer VPC network or another standard VMware Engine network. If the + * `peer_network_type` is VMWARE_ENGINE_NETWORK, specify the name in the form: + * `projects/{project}/locations/global/vmwareEngineNetworks/{vmware_engine_network_id}`. + * Otherwise specify the name in the form: + * `projects/{project}/global/networks/{network_id}`, where + * `{project}` can either be a project number or a project ID. + * + * Generated from protobuf field string peer_network = 5 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setPeerNetwork($var) + { + GPBUtil::checkString($var, True); + $this->peer_network = $var; + + return $this; + } + + /** + * Optional. True if custom routes are exported to the peered network; + * false otherwise. The default value is true. + * + * Generated from protobuf field optional bool export_custom_routes = 8 [(.google.api.field_behavior) = OPTIONAL]; + * @return bool + */ + public function getExportCustomRoutes() + { + return isset($this->export_custom_routes) ? $this->export_custom_routes : false; + } + + public function hasExportCustomRoutes() + { + return isset($this->export_custom_routes); + } + + public function clearExportCustomRoutes() + { + unset($this->export_custom_routes); + } + + /** + * Optional. True if custom routes are exported to the peered network; + * false otherwise. The default value is true. + * + * Generated from protobuf field optional bool export_custom_routes = 8 [(.google.api.field_behavior) = OPTIONAL]; + * @param bool $var + * @return $this + */ + public function setExportCustomRoutes($var) + { + GPBUtil::checkBool($var); + $this->export_custom_routes = $var; + + return $this; + } + + /** + * Optional. True if custom routes are imported from the peered network; + * false otherwise. The default value is true. + * + * Generated from protobuf field optional bool import_custom_routes = 9 [(.google.api.field_behavior) = OPTIONAL]; + * @return bool + */ + public function getImportCustomRoutes() + { + return isset($this->import_custom_routes) ? $this->import_custom_routes : false; + } + + public function hasImportCustomRoutes() + { + return isset($this->import_custom_routes); + } + + public function clearImportCustomRoutes() + { + unset($this->import_custom_routes); + } + + /** + * Optional. True if custom routes are imported from the peered network; + * false otherwise. The default value is true. + * + * Generated from protobuf field optional bool import_custom_routes = 9 [(.google.api.field_behavior) = OPTIONAL]; + * @param bool $var + * @return $this + */ + public function setImportCustomRoutes($var) + { + GPBUtil::checkBool($var); + $this->import_custom_routes = $var; + + return $this; + } + + /** + * Optional. True if full mesh connectivity is created and managed + * automatically between peered networks; false otherwise. Currently this + * field is always true because Google Compute Engine automatically creates + * and manages subnetwork routes between two VPC networks when peering state + * is 'ACTIVE'. + * + * Generated from protobuf field optional bool exchange_subnet_routes = 10 [(.google.api.field_behavior) = OPTIONAL]; + * @return bool + */ + public function getExchangeSubnetRoutes() + { + return isset($this->exchange_subnet_routes) ? $this->exchange_subnet_routes : false; + } + + public function hasExchangeSubnetRoutes() + { + return isset($this->exchange_subnet_routes); + } + + public function clearExchangeSubnetRoutes() + { + unset($this->exchange_subnet_routes); + } + + /** + * Optional. True if full mesh connectivity is created and managed + * automatically between peered networks; false otherwise. Currently this + * field is always true because Google Compute Engine automatically creates + * and manages subnetwork routes between two VPC networks when peering state + * is 'ACTIVE'. + * + * Generated from protobuf field optional bool exchange_subnet_routes = 10 [(.google.api.field_behavior) = OPTIONAL]; + * @param bool $var + * @return $this + */ + public function setExchangeSubnetRoutes($var) + { + GPBUtil::checkBool($var); + $this->exchange_subnet_routes = $var; + + return $this; + } + + /** + * Optional. True if all subnet routes with a public IP address range are + * exported; false otherwise. The default value is true. IPv4 special-use + * ranges (https://en.wikipedia.org/wiki/IPv4#Special_addresses) are always + * exported to peers and are not controlled by this field. + * + * Generated from protobuf field optional bool export_custom_routes_with_public_ip = 11 [(.google.api.field_behavior) = OPTIONAL]; + * @return bool + */ + public function getExportCustomRoutesWithPublicIp() + { + return isset($this->export_custom_routes_with_public_ip) ? $this->export_custom_routes_with_public_ip : false; + } + + public function hasExportCustomRoutesWithPublicIp() + { + return isset($this->export_custom_routes_with_public_ip); + } + + public function clearExportCustomRoutesWithPublicIp() + { + unset($this->export_custom_routes_with_public_ip); + } + + /** + * Optional. True if all subnet routes with a public IP address range are + * exported; false otherwise. The default value is true. IPv4 special-use + * ranges (https://en.wikipedia.org/wiki/IPv4#Special_addresses) are always + * exported to peers and are not controlled by this field. + * + * Generated from protobuf field optional bool export_custom_routes_with_public_ip = 11 [(.google.api.field_behavior) = OPTIONAL]; + * @param bool $var + * @return $this + */ + public function setExportCustomRoutesWithPublicIp($var) + { + GPBUtil::checkBool($var); + $this->export_custom_routes_with_public_ip = $var; + + return $this; + } + + /** + * Optional. True if all subnet routes with public IP address range are + * imported; false otherwise. The default value is true. IPv4 special-use + * ranges (https://en.wikipedia.org/wiki/IPv4#Special_addresses) are always + * imported to peers and are not controlled by this field. + * + * Generated from protobuf field optional bool import_custom_routes_with_public_ip = 12 [(.google.api.field_behavior) = OPTIONAL]; + * @return bool + */ + public function getImportCustomRoutesWithPublicIp() + { + return isset($this->import_custom_routes_with_public_ip) ? $this->import_custom_routes_with_public_ip : false; + } + + public function hasImportCustomRoutesWithPublicIp() + { + return isset($this->import_custom_routes_with_public_ip); + } + + public function clearImportCustomRoutesWithPublicIp() + { + unset($this->import_custom_routes_with_public_ip); + } + + /** + * Optional. True if all subnet routes with public IP address range are + * imported; false otherwise. The default value is true. IPv4 special-use + * ranges (https://en.wikipedia.org/wiki/IPv4#Special_addresses) are always + * imported to peers and are not controlled by this field. + * + * Generated from protobuf field optional bool import_custom_routes_with_public_ip = 12 [(.google.api.field_behavior) = OPTIONAL]; + * @param bool $var + * @return $this + */ + public function setImportCustomRoutesWithPublicIp($var) + { + GPBUtil::checkBool($var); + $this->import_custom_routes_with_public_ip = $var; + + return $this; + } + + /** + * Output only. State of the network peering. This field + * has a value of 'ACTIVE' when there's a matching configuration in the peer + * network. New values may be added to this enum when appropriate. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPeering.State state = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getState() + { + return $this->state; + } + + /** + * Output only. State of the network peering. This field + * has a value of 'ACTIVE' when there's a matching configuration in the peer + * network. New values may be added to this enum when appropriate. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPeering.State state = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setState($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\NetworkPeering\State::class); + $this->state = $var; + + return $this; + } + + /** + * Output only. Output Only. Details about the current state of the network + * peering. + * + * Generated from protobuf field string state_details = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getStateDetails() + { + return $this->state_details; + } + + /** + * Output only. Output Only. Details about the current state of the network + * peering. + * + * Generated from protobuf field string state_details = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setStateDetails($var) + { + GPBUtil::checkString($var, True); + $this->state_details = $var; + + return $this; + } + + /** + * Optional. Maximum transmission unit (MTU) in bytes. + * The default value is `1500`. If a value of `0` is provided for this field, + * VMware Engine uses the default value instead. + * + * Generated from protobuf field int32 peer_mtu = 14 [(.google.api.field_behavior) = OPTIONAL]; + * @return int + */ + public function getPeerMtu() + { + return $this->peer_mtu; + } + + /** + * Optional. Maximum transmission unit (MTU) in bytes. + * The default value is `1500`. If a value of `0` is provided for this field, + * VMware Engine uses the default value instead. + * + * Generated from protobuf field int32 peer_mtu = 14 [(.google.api.field_behavior) = OPTIONAL]; + * @param int $var + * @return $this + */ + public function setPeerMtu($var) + { + GPBUtil::checkInt32($var); + $this->peer_mtu = $var; + + return $this; + } + + /** + * Required. The type of the network to peer with the VMware Engine network. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPeering.PeerNetworkType peer_network_type = 16 [(.google.api.field_behavior) = REQUIRED]; + * @return int + */ + public function getPeerNetworkType() + { + return $this->peer_network_type; + } + + /** + * Required. The type of the network to peer with the VMware Engine network. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPeering.PeerNetworkType peer_network_type = 16 [(.google.api.field_behavior) = REQUIRED]; + * @param int $var + * @return $this + */ + public function setPeerNetworkType($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\NetworkPeering\PeerNetworkType::class); + $this->peer_network_type = $var; + + return $this; + } + + /** + * Output only. System-generated unique identifier for the resource. + * + * Generated from protobuf field string uid = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getUid() + { + return $this->uid; + } + + /** + * Output only. System-generated unique identifier for the resource. + * + * Generated from protobuf field string uid = 17 [(.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 relative resource name of the VMware Engine network. + * Specify the name in the following form: + * `projects/{project}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` + * where `{project}` can either be a project number or a project ID. + * + * Generated from protobuf field string vmware_engine_network = 20 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getVmwareEngineNetwork() + { + return $this->vmware_engine_network; + } + + /** + * Required. The relative resource name of the VMware Engine network. + * Specify the name in the following form: + * `projects/{project}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` + * where `{project}` can either be a project number or a project ID. + * + * Generated from protobuf field string vmware_engine_network = 20 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setVmwareEngineNetwork($var) + { + GPBUtil::checkString($var, True); + $this->vmware_engine_network = $var; + + return $this; + } + + /** + * Optional. User-provided description for this network peering. + * + * Generated from protobuf field string description = 21 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * Optional. User-provided description for this network peering. + * + * Generated from protobuf field string description = 21 [(.google.api.field_behavior) = OPTIONAL]; + * @param string $var + * @return $this + */ + public function setDescription($var) + { + GPBUtil::checkString($var, True); + $this->description = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPeering/PeerNetworkType.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPeering/PeerNetworkType.php new file mode 100644 index 000000000000..d3019ab08ef8 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPeering/PeerNetworkType.php @@ -0,0 +1,101 @@ +google.cloud.vmwareengine.v1.NetworkPeering.PeerNetworkType + */ +class PeerNetworkType +{ + /** + * Unspecified + * + * Generated from protobuf enum PEER_NETWORK_TYPE_UNSPECIFIED = 0; + */ + const PEER_NETWORK_TYPE_UNSPECIFIED = 0; + /** + * Peering connection used for connecting to another VPC network established + * by the same user. For example, a peering connection to another VPC + * network in the same project or to an on-premises network. + * + * Generated from protobuf enum STANDARD = 1; + */ + const STANDARD = 1; + /** + * Peering connection used for connecting to another VMware Engine network. + * + * Generated from protobuf enum VMWARE_ENGINE_NETWORK = 2; + */ + const VMWARE_ENGINE_NETWORK = 2; + /** + * Peering connection used for establishing [private services + * access](https://cloud.google.com/vpc/docs/private-services-access). + * + * Generated from protobuf enum PRIVATE_SERVICES_ACCESS = 3; + */ + const PRIVATE_SERVICES_ACCESS = 3; + /** + * Peering connection used for connecting to NetApp Cloud Volumes. + * + * Generated from protobuf enum NETAPP_CLOUD_VOLUMES = 4; + */ + const NETAPP_CLOUD_VOLUMES = 4; + /** + * Peering connection used for connecting to third-party services. Most + * third-party services require manual setup of reverse peering on the VPC + * network associated with the third-party service. + * + * Generated from protobuf enum THIRD_PARTY_SERVICE = 5; + */ + const THIRD_PARTY_SERVICE = 5; + /** + * Peering connection used for connecting to Dell PowerScale Filers + * + * Generated from protobuf enum DELL_POWERSCALE = 6; + */ + const DELL_POWERSCALE = 6; + /** + * Peering connection used for connecting to Google Cloud NetApp Volumes. + * + * Generated from protobuf enum GOOGLE_CLOUD_NETAPP_VOLUMES = 7; + */ + const GOOGLE_CLOUD_NETAPP_VOLUMES = 7; + + private static $valueToName = [ + self::PEER_NETWORK_TYPE_UNSPECIFIED => 'PEER_NETWORK_TYPE_UNSPECIFIED', + self::STANDARD => 'STANDARD', + self::VMWARE_ENGINE_NETWORK => 'VMWARE_ENGINE_NETWORK', + self::PRIVATE_SERVICES_ACCESS => 'PRIVATE_SERVICES_ACCESS', + self::NETAPP_CLOUD_VOLUMES => 'NETAPP_CLOUD_VOLUMES', + self::THIRD_PARTY_SERVICE => 'THIRD_PARTY_SERVICE', + self::DELL_POWERSCALE => 'DELL_POWERSCALE', + self::GOOGLE_CLOUD_NETAPP_VOLUMES => 'GOOGLE_CLOUD_NETAPP_VOLUMES', + ]; + + 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPeering/State.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPeering/State.php new file mode 100644 index 000000000000..da07bce71cde --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPeering/State.php @@ -0,0 +1,75 @@ +google.cloud.vmwareengine.v1.NetworkPeering.State + */ +class State +{ + /** + * Unspecified network peering state. This is the default value. + * + * Generated from protobuf enum STATE_UNSPECIFIED = 0; + */ + const STATE_UNSPECIFIED = 0; + /** + * The peering is not active. + * + * Generated from protobuf enum INACTIVE = 1; + */ + const INACTIVE = 1; + /** + * The peering is active. + * + * Generated from protobuf enum ACTIVE = 2; + */ + const ACTIVE = 2; + /** + * The peering is being created. + * + * Generated from protobuf enum CREATING = 3; + */ + const CREATING = 3; + /** + * The peering is being deleted. + * + * Generated from protobuf enum DELETING = 4; + */ + const DELETING = 4; + + private static $valueToName = [ + self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', + self::INACTIVE => 'INACTIVE', + self::ACTIVE => 'ACTIVE', + self::CREATING => 'CREATING', + 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); + } +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPolicy.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPolicy.php new file mode 100644 index 000000000000..d9d552c009e8 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPolicy.php @@ -0,0 +1,470 @@ +google.cloud.vmwareengine.v1.NetworkPolicy + */ +class NetworkPolicy extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. The resource name of this network policy. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/networkPolicies/my-network-policy` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $name = ''; + /** + * Output only. Creation time of this resource. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $create_time = null; + /** + * Output only. Last update time of this resource. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $update_time = null; + /** + * Network service that allows VMware workloads to access the internet. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPolicy.NetworkService internet_access = 6; + */ + protected $internet_access = null; + /** + * Network service that allows External IP addresses to be assigned to VMware + * workloads. This service can only be enabled when `internet_access` is also + * enabled. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPolicy.NetworkService external_ip = 7; + */ + protected $external_ip = null; + /** + * Required. IP address range in CIDR notation used to create internet access + * and external IP access. An RFC 1918 CIDR block, with a "/26" prefix, is + * required. The range cannot overlap with any prefixes either in the consumer + * VPC network or in use by the private clouds attached to that VPC network. + * + * Generated from protobuf field string edge_services_cidr = 9 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $edge_services_cidr = ''; + /** + * Output only. System-generated unique identifier for the resource. + * + * Generated from protobuf field string uid = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $uid = ''; + /** + * Optional. The relative resource name of the VMware Engine network. + * Specify the name in the following form: + * `projects/{project}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` + * where `{project}` can either be a project number or a project ID. + * + * Generated from protobuf field string vmware_engine_network = 12 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { + */ + protected $vmware_engine_network = ''; + /** + * Optional. User-provided description for this network policy. + * + * Generated from protobuf field string description = 13 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $description = ''; + /** + * Output only. The canonical name of the VMware Engine network in the form: + * `projects/{project_number}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` + * + * Generated from protobuf field string vmware_engine_network_canonical = 14 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { + */ + protected $vmware_engine_network_canonical = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Output only. The resource name of this network policy. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/networkPolicies/my-network-policy` + * @type \Google\Protobuf\Timestamp $create_time + * Output only. Creation time of this resource. + * @type \Google\Protobuf\Timestamp $update_time + * Output only. Last update time of this resource. + * @type \Google\Cloud\VmwareEngine\V1\NetworkPolicy\NetworkService $internet_access + * Network service that allows VMware workloads to access the internet. + * @type \Google\Cloud\VmwareEngine\V1\NetworkPolicy\NetworkService $external_ip + * Network service that allows External IP addresses to be assigned to VMware + * workloads. This service can only be enabled when `internet_access` is also + * enabled. + * @type string $edge_services_cidr + * Required. IP address range in CIDR notation used to create internet access + * and external IP access. An RFC 1918 CIDR block, with a "/26" prefix, is + * required. The range cannot overlap with any prefixes either in the consumer + * VPC network or in use by the private clouds attached to that VPC network. + * @type string $uid + * Output only. System-generated unique identifier for the resource. + * @type string $vmware_engine_network + * Optional. The relative resource name of the VMware Engine network. + * Specify the name in the following form: + * `projects/{project}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` + * where `{project}` can either be a project number or a project ID. + * @type string $description + * Optional. User-provided description for this network policy. + * @type string $vmware_engine_network_canonical + * Output only. The canonical name of the VMware Engine network in the form: + * `projects/{project_number}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); + parent::__construct($data); + } + + /** + * Output only. The resource name of this network policy. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/networkPolicies/my-network-policy` + * + * 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 network policy. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/networkPolicies/my-network-policy` + * + * 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. Creation time of this resource. + * + * 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 time of this resource. + * + * 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 time of this resource. + * + * 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 time of this resource. + * + * 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; + } + + /** + * Network service that allows VMware workloads to access the internet. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPolicy.NetworkService internet_access = 6; + * @return \Google\Cloud\VmwareEngine\V1\NetworkPolicy\NetworkService|null + */ + public function getInternetAccess() + { + return $this->internet_access; + } + + public function hasInternetAccess() + { + return isset($this->internet_access); + } + + public function clearInternetAccess() + { + unset($this->internet_access); + } + + /** + * Network service that allows VMware workloads to access the internet. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPolicy.NetworkService internet_access = 6; + * @param \Google\Cloud\VmwareEngine\V1\NetworkPolicy\NetworkService $var + * @return $this + */ + public function setInternetAccess($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\NetworkPolicy\NetworkService::class); + $this->internet_access = $var; + + return $this; + } + + /** + * Network service that allows External IP addresses to be assigned to VMware + * workloads. This service can only be enabled when `internet_access` is also + * enabled. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPolicy.NetworkService external_ip = 7; + * @return \Google\Cloud\VmwareEngine\V1\NetworkPolicy\NetworkService|null + */ + public function getExternalIp() + { + return $this->external_ip; + } + + public function hasExternalIp() + { + return isset($this->external_ip); + } + + public function clearExternalIp() + { + unset($this->external_ip); + } + + /** + * Network service that allows External IP addresses to be assigned to VMware + * workloads. This service can only be enabled when `internet_access` is also + * enabled. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPolicy.NetworkService external_ip = 7; + * @param \Google\Cloud\VmwareEngine\V1\NetworkPolicy\NetworkService $var + * @return $this + */ + public function setExternalIp($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\NetworkPolicy\NetworkService::class); + $this->external_ip = $var; + + return $this; + } + + /** + * Required. IP address range in CIDR notation used to create internet access + * and external IP access. An RFC 1918 CIDR block, with a "/26" prefix, is + * required. The range cannot overlap with any prefixes either in the consumer + * VPC network or in use by the private clouds attached to that VPC network. + * + * Generated from protobuf field string edge_services_cidr = 9 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getEdgeServicesCidr() + { + return $this->edge_services_cidr; + } + + /** + * Required. IP address range in CIDR notation used to create internet access + * and external IP access. An RFC 1918 CIDR block, with a "/26" prefix, is + * required. The range cannot overlap with any prefixes either in the consumer + * VPC network or in use by the private clouds attached to that VPC network. + * + * Generated from protobuf field string edge_services_cidr = 9 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setEdgeServicesCidr($var) + { + GPBUtil::checkString($var, True); + $this->edge_services_cidr = $var; + + return $this; + } + + /** + * Output only. System-generated unique identifier for the resource. + * + * Generated from protobuf field string uid = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getUid() + { + return $this->uid; + } + + /** + * Output only. System-generated unique identifier for the resource. + * + * Generated from protobuf field string uid = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setUid($var) + { + GPBUtil::checkString($var, True); + $this->uid = $var; + + return $this; + } + + /** + * Optional. The relative resource name of the VMware Engine network. + * Specify the name in the following form: + * `projects/{project}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` + * where `{project}` can either be a project number or a project ID. + * + * Generated from protobuf field string vmware_engine_network = 12 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { + * @return string + */ + public function getVmwareEngineNetwork() + { + return $this->vmware_engine_network; + } + + /** + * Optional. The relative resource name of the VMware Engine network. + * Specify the name in the following form: + * `projects/{project}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` + * where `{project}` can either be a project number or a project ID. + * + * Generated from protobuf field string vmware_engine_network = 12 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setVmwareEngineNetwork($var) + { + GPBUtil::checkString($var, True); + $this->vmware_engine_network = $var; + + return $this; + } + + /** + * Optional. User-provided description for this network policy. + * + * Generated from protobuf field string description = 13 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * Optional. User-provided description for this network policy. + * + * Generated from protobuf field string description = 13 [(.google.api.field_behavior) = OPTIONAL]; + * @param string $var + * @return $this + */ + public function setDescription($var) + { + GPBUtil::checkString($var, True); + $this->description = $var; + + return $this; + } + + /** + * Output only. The canonical name of the VMware Engine network in the form: + * `projects/{project_number}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` + * + * Generated from protobuf field string vmware_engine_network_canonical = 14 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { + * @return string + */ + public function getVmwareEngineNetworkCanonical() + { + return $this->vmware_engine_network_canonical; + } + + /** + * Output only. The canonical name of the VMware Engine network in the form: + * `projects/{project_number}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` + * + * Generated from protobuf field string vmware_engine_network_canonical = 14 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setVmwareEngineNetworkCanonical($var) + { + GPBUtil::checkString($var, True); + $this->vmware_engine_network_canonical = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPolicy/NetworkService.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPolicy/NetworkService.php new file mode 100644 index 000000000000..7c346b1c96a1 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPolicy/NetworkService.php @@ -0,0 +1,109 @@ +google.cloud.vmwareengine.v1.NetworkPolicy.NetworkService + */ +class NetworkService extends \Google\Protobuf\Internal\Message +{ + /** + * True if the service is enabled; false otherwise. + * + * Generated from protobuf field bool enabled = 1; + */ + protected $enabled = false; + /** + * Output only. State of the service. New values may be added to this enum + * when appropriate. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPolicy.NetworkService.State state = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $state = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type bool $enabled + * True if the service is enabled; false otherwise. + * @type int $state + * Output only. State of the service. New values may be added to this enum + * when appropriate. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); + parent::__construct($data); + } + + /** + * True if the service is enabled; false otherwise. + * + * Generated from protobuf field bool enabled = 1; + * @return bool + */ + public function getEnabled() + { + return $this->enabled; + } + + /** + * True if the service is enabled; false otherwise. + * + * Generated from protobuf field bool enabled = 1; + * @param bool $var + * @return $this + */ + public function setEnabled($var) + { + GPBUtil::checkBool($var); + $this->enabled = $var; + + return $this; + } + + /** + * Output only. State of the service. New values may be added to this enum + * when appropriate. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPolicy.NetworkService.State state = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getState() + { + return $this->state; + } + + /** + * Output only. State of the service. New values may be added to this enum + * when appropriate. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPolicy.NetworkService.State state = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setState($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\NetworkPolicy\NetworkService\State::class); + $this->state = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPolicy/NetworkService/State.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPolicy/NetworkService/State.php new file mode 100644 index 000000000000..d6de8dc94e59 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPolicy/NetworkService/State.php @@ -0,0 +1,69 @@ +google.cloud.vmwareengine.v1.NetworkPolicy.NetworkService.State + */ +class State +{ + /** + * Unspecified service state. This is the default value. + * + * Generated from protobuf enum STATE_UNSPECIFIED = 0; + */ + const STATE_UNSPECIFIED = 0; + /** + * Service is not provisioned. + * + * Generated from protobuf enum UNPROVISIONED = 1; + */ + const UNPROVISIONED = 1; + /** + * Service is in the process of being provisioned/deprovisioned. + * + * Generated from protobuf enum RECONCILING = 2; + */ + const RECONCILING = 2; + /** + * Service is active. + * + * Generated from protobuf enum ACTIVE = 3; + */ + const ACTIVE = 3; + + private static $valueToName = [ + self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', + self::UNPROVISIONED => 'UNPROVISIONED', + self::RECONCILING => 'RECONCILING', + 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); + } +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Node.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Node.php new file mode 100644 index 000000000000..ccd3d2b2e735 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Node.php @@ -0,0 +1,299 @@ +google.cloud.vmwareengine.v1.Node + */ +class Node extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. The resource name of this node. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster/nodes/my-node + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $name = ''; + /** + * Output only. Fully qualified domain name of the node. + * + * Generated from protobuf field string fqdn = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $fqdn = ''; + /** + * Output only. Internal IP address of the node. + * + * Generated from protobuf field string internal_ip = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $internal_ip = ''; + /** + * Output only. The canonical identifier of the node type (corresponds to the + * `NodeType`). + * For example: standard-72. + * + * Generated from protobuf field string node_type_id = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $node_type_id = ''; + /** + * Output only. The version number of the VMware ESXi + * management component in this cluster. + * + * Generated from protobuf field string version = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $version = ''; + /** + * Output only. Customized number of cores + * + * Generated from protobuf field int64 custom_core_count = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $custom_core_count = 0; + /** + * Output only. The state of the appliance. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.Node.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $state = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Output only. The resource name of this node. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster/nodes/my-node + * @type string $fqdn + * Output only. Fully qualified domain name of the node. + * @type string $internal_ip + * Output only. Internal IP address of the node. + * @type string $node_type_id + * Output only. The canonical identifier of the node type (corresponds to the + * `NodeType`). + * For example: standard-72. + * @type string $version + * Output only. The version number of the VMware ESXi + * management component in this cluster. + * @type int|string $custom_core_count + * Output only. Customized number of cores + * @type int $state + * Output only. The state of the appliance. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); + parent::__construct($data); + } + + /** + * Output only. The resource name of this node. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster/nodes/my-node + * + * 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 node. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster/nodes/my-node + * + * 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. Fully qualified domain name of the node. + * + * Generated from protobuf field string fqdn = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getFqdn() + { + return $this->fqdn; + } + + /** + * Output only. Fully qualified domain name of the node. + * + * Generated from protobuf field string fqdn = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setFqdn($var) + { + GPBUtil::checkString($var, True); + $this->fqdn = $var; + + return $this; + } + + /** + * Output only. Internal IP address of the node. + * + * Generated from protobuf field string internal_ip = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getInternalIp() + { + return $this->internal_ip; + } + + /** + * Output only. Internal IP address of the node. + * + * Generated from protobuf field string internal_ip = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setInternalIp($var) + { + GPBUtil::checkString($var, True); + $this->internal_ip = $var; + + return $this; + } + + /** + * Output only. The canonical identifier of the node type (corresponds to the + * `NodeType`). + * For example: standard-72. + * + * Generated from protobuf field string node_type_id = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getNodeTypeId() + { + return $this->node_type_id; + } + + /** + * Output only. The canonical identifier of the node type (corresponds to the + * `NodeType`). + * For example: standard-72. + * + * Generated from protobuf field string node_type_id = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setNodeTypeId($var) + { + GPBUtil::checkString($var, True); + $this->node_type_id = $var; + + return $this; + } + + /** + * Output only. The version number of the VMware ESXi + * management component in this cluster. + * + * Generated from protobuf field string version = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getVersion() + { + return $this->version; + } + + /** + * Output only. The version number of the VMware ESXi + * management component in this cluster. + * + * Generated from protobuf field string version = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setVersion($var) + { + GPBUtil::checkString($var, True); + $this->version = $var; + + return $this; + } + + /** + * Output only. Customized number of cores + * + * Generated from protobuf field int64 custom_core_count = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int|string + */ + public function getCustomCoreCount() + { + return $this->custom_core_count; + } + + /** + * Output only. Customized number of cores + * + * Generated from protobuf field int64 custom_core_count = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int|string $var + * @return $this + */ + public function setCustomCoreCount($var) + { + GPBUtil::checkInt64($var); + $this->custom_core_count = $var; + + return $this; + } + + /** + * Output only. The state of the appliance. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.Node.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getState() + { + return $this->state; + } + + /** + * Output only. The state of the appliance. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.Node.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setState($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\Node\State::class); + $this->state = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Node/State.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Node/State.php new file mode 100644 index 000000000000..67a6d5115860 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Node/State.php @@ -0,0 +1,75 @@ +google.cloud.vmwareengine.v1.Node.State + */ +class State +{ + /** + * The default value. This value should never be used. + * + * Generated from protobuf enum STATE_UNSPECIFIED = 0; + */ + const STATE_UNSPECIFIED = 0; + /** + * Node is operational and can be used by the user. + * + * Generated from protobuf enum ACTIVE = 1; + */ + const ACTIVE = 1; + /** + * Node is being provisioned. + * + * Generated from protobuf enum CREATING = 2; + */ + const CREATING = 2; + /** + * Node is in a failed state. + * + * Generated from protobuf enum FAILED = 3; + */ + const FAILED = 3; + /** + * Node is undergoing maintenance, e.g.: during private cloud upgrade. + * + * Generated from protobuf enum UPGRADING = 4; + */ + const UPGRADING = 4; + + private static $valueToName = [ + self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', + self::ACTIVE => 'ACTIVE', + self::CREATING => 'CREATING', + self::FAILED => 'FAILED', + self::UPGRADING => 'UPGRADING', + ]; + + 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NodeType.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NodeType.php new file mode 100644 index 000000000000..665cf3177190 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NodeType.php @@ -0,0 +1,439 @@ +google.cloud.vmwareengine.v1.NodeType + */ +class NodeType extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. The resource name of this node type. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-proj/locations/us-central1-a/nodeTypes/standard-72` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $name = ''; + /** + * Output only. The canonical identifier of the node type + * (corresponds to the `NodeType`). For example: standard-72. + * + * Generated from protobuf field string node_type_id = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $node_type_id = ''; + /** + * Output only. The friendly name for this node type. + * For example: ve1-standard-72 + * + * Generated from protobuf field string display_name = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $display_name = ''; + /** + * Output only. The total number of virtual CPUs in a single node. + * + * Generated from protobuf field int32 virtual_cpu_count = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $virtual_cpu_count = 0; + /** + * Output only. The total number of CPU cores in a single node. + * + * Generated from protobuf field int32 total_core_count = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $total_core_count = 0; + /** + * Output only. The amount of physical memory available, defined in GB. + * + * Generated from protobuf field int32 memory_gb = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $memory_gb = 0; + /** + * Output only. The amount of storage available, defined in GB. + * + * Generated from protobuf field int32 disk_size_gb = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $disk_size_gb = 0; + /** + * Output only. List of possible values of custom core count. + * + * Generated from protobuf field repeated int32 available_custom_core_counts = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + private $available_custom_core_counts; + /** + * Output only. The type of the resource. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.NodeType.Kind kind = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $kind = 0; + /** + * Output only. Families of the node type. + * For node types to be in the same cluster + * they must share at least one element in the `families`. + * + * Generated from protobuf field repeated string families = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + private $families; + /** + * Output only. Capabilities of this node type. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.NodeType.Capability capabilities = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + private $capabilities; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Output only. The resource name of this node type. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-proj/locations/us-central1-a/nodeTypes/standard-72` + * @type string $node_type_id + * Output only. The canonical identifier of the node type + * (corresponds to the `NodeType`). For example: standard-72. + * @type string $display_name + * Output only. The friendly name for this node type. + * For example: ve1-standard-72 + * @type int $virtual_cpu_count + * Output only. The total number of virtual CPUs in a single node. + * @type int $total_core_count + * Output only. The total number of CPU cores in a single node. + * @type int $memory_gb + * Output only. The amount of physical memory available, defined in GB. + * @type int $disk_size_gb + * Output only. The amount of storage available, defined in GB. + * @type int[] $available_custom_core_counts + * Output only. List of possible values of custom core count. + * @type int $kind + * Output only. The type of the resource. + * @type string[] $families + * Output only. Families of the node type. + * For node types to be in the same cluster + * they must share at least one element in the `families`. + * @type int[] $capabilities + * Output only. Capabilities of this node type. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); + parent::__construct($data); + } + + /** + * Output only. The resource name of this node type. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-proj/locations/us-central1-a/nodeTypes/standard-72` + * + * 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 node type. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-proj/locations/us-central1-a/nodeTypes/standard-72` + * + * 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 canonical identifier of the node type + * (corresponds to the `NodeType`). For example: standard-72. + * + * Generated from protobuf field string node_type_id = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getNodeTypeId() + { + return $this->node_type_id; + } + + /** + * Output only. The canonical identifier of the node type + * (corresponds to the `NodeType`). For example: standard-72. + * + * Generated from protobuf field string node_type_id = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setNodeTypeId($var) + { + GPBUtil::checkString($var, True); + $this->node_type_id = $var; + + return $this; + } + + /** + * Output only. The friendly name for this node type. + * For example: ve1-standard-72 + * + * Generated from protobuf field string display_name = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getDisplayName() + { + return $this->display_name; + } + + /** + * Output only. The friendly name for this node type. + * For example: ve1-standard-72 + * + * Generated from protobuf field string display_name = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->display_name = $var; + + return $this; + } + + /** + * Output only. The total number of virtual CPUs in a single node. + * + * Generated from protobuf field int32 virtual_cpu_count = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getVirtualCpuCount() + { + return $this->virtual_cpu_count; + } + + /** + * Output only. The total number of virtual CPUs in a single node. + * + * Generated from protobuf field int32 virtual_cpu_count = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setVirtualCpuCount($var) + { + GPBUtil::checkInt32($var); + $this->virtual_cpu_count = $var; + + return $this; + } + + /** + * Output only. The total number of CPU cores in a single node. + * + * Generated from protobuf field int32 total_core_count = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getTotalCoreCount() + { + return $this->total_core_count; + } + + /** + * Output only. The total number of CPU cores in a single node. + * + * Generated from protobuf field int32 total_core_count = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setTotalCoreCount($var) + { + GPBUtil::checkInt32($var); + $this->total_core_count = $var; + + return $this; + } + + /** + * Output only. The amount of physical memory available, defined in GB. + * + * Generated from protobuf field int32 memory_gb = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getMemoryGb() + { + return $this->memory_gb; + } + + /** + * Output only. The amount of physical memory available, defined in GB. + * + * Generated from protobuf field int32 memory_gb = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setMemoryGb($var) + { + GPBUtil::checkInt32($var); + $this->memory_gb = $var; + + return $this; + } + + /** + * Output only. The amount of storage available, defined in GB. + * + * Generated from protobuf field int32 disk_size_gb = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getDiskSizeGb() + { + return $this->disk_size_gb; + } + + /** + * Output only. The amount of storage available, defined in GB. + * + * Generated from protobuf field int32 disk_size_gb = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setDiskSizeGb($var) + { + GPBUtil::checkInt32($var); + $this->disk_size_gb = $var; + + return $this; + } + + /** + * Output only. List of possible values of custom core count. + * + * Generated from protobuf field repeated int32 available_custom_core_counts = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return RepeatedField + */ + public function getAvailableCustomCoreCounts() + { + return $this->available_custom_core_counts; + } + + /** + * Output only. List of possible values of custom core count. + * + * Generated from protobuf field repeated int32 available_custom_core_counts = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int[] $var + * @return $this + */ + public function setAvailableCustomCoreCounts($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::INT32); + $this->available_custom_core_counts = $arr; + + return $this; + } + + /** + * Output only. The type of the resource. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.NodeType.Kind kind = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getKind() + { + return $this->kind; + } + + /** + * Output only. The type of the resource. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.NodeType.Kind kind = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setKind($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\NodeType\Kind::class); + $this->kind = $var; + + return $this; + } + + /** + * Output only. Families of the node type. + * For node types to be in the same cluster + * they must share at least one element in the `families`. + * + * Generated from protobuf field repeated string families = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return RepeatedField + */ + public function getFamilies() + { + return $this->families; + } + + /** + * Output only. Families of the node type. + * For node types to be in the same cluster + * they must share at least one element in the `families`. + * + * Generated from protobuf field repeated string families = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string[] $var + * @return $this + */ + public function setFamilies($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->families = $arr; + + return $this; + } + + /** + * Output only. Capabilities of this node type. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.NodeType.Capability capabilities = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return RepeatedField + */ + public function getCapabilities() + { + return $this->capabilities; + } + + /** + * Output only. Capabilities of this node type. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.NodeType.Capability capabilities = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int[] $var + * @return $this + */ + public function setCapabilities($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\VmwareEngine\V1\NodeType\Capability::class); + $this->capabilities = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NodeType/Capability.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NodeType/Capability.php new file mode 100644 index 000000000000..f01cf73118ce --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NodeType/Capability.php @@ -0,0 +1,55 @@ +google.cloud.vmwareengine.v1.NodeType.Capability + */ +class Capability +{ + /** + * The default value. This value is used if the capability is omitted or + * unknown. + * + * Generated from protobuf enum CAPABILITY_UNSPECIFIED = 0; + */ + const CAPABILITY_UNSPECIFIED = 0; + /** + * This node type supports stretch clusters. + * + * Generated from protobuf enum STRETCHED_CLUSTERS = 1; + */ + const STRETCHED_CLUSTERS = 1; + + private static $valueToName = [ + self::CAPABILITY_UNSPECIFIED => 'CAPABILITY_UNSPECIFIED', + self::STRETCHED_CLUSTERS => 'STRETCHED_CLUSTERS', + ]; + + 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NodeType/Kind.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NodeType/Kind.php new file mode 100644 index 000000000000..8dc3c2a8c852 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NodeType/Kind.php @@ -0,0 +1,61 @@ +google.cloud.vmwareengine.v1.NodeType.Kind + */ +class Kind +{ + /** + * The default value. This value should never be used. + * + * Generated from protobuf enum KIND_UNSPECIFIED = 0; + */ + const KIND_UNSPECIFIED = 0; + /** + * Standard HCI node. + * + * Generated from protobuf enum STANDARD = 1; + */ + const STANDARD = 1; + /** + * Storage only Node. + * + * Generated from protobuf enum STORAGE_ONLY = 2; + */ + const STORAGE_ONLY = 2; + + private static $valueToName = [ + self::KIND_UNSPECIFIED => 'KIND_UNSPECIFIED', + self::STANDARD => 'STANDARD', + self::STORAGE_ONLY => 'STORAGE_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); + } +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NodeTypeConfig.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NodeTypeConfig.php new file mode 100644 index 000000000000..e69b0585e5b7 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NodeTypeConfig.php @@ -0,0 +1,113 @@ +google.cloud.vmwareengine.v1.NodeTypeConfig + */ +class NodeTypeConfig extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The number of nodes of this type in the cluster + * + * Generated from protobuf field int32 node_count = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $node_count = 0; + /** + * Optional. Customized number of cores available to each node of the type. + * This number must always be one of `nodeType.availableCustomCoreCounts`. + * If zero is provided max value from `nodeType.availableCustomCoreCounts` + * will be used. + * + * Generated from protobuf field int32 custom_core_count = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $custom_core_count = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $node_count + * Required. The number of nodes of this type in the cluster + * @type int $custom_core_count + * Optional. Customized number of cores available to each node of the type. + * This number must always be one of `nodeType.availableCustomCoreCounts`. + * If zero is provided max value from `nodeType.availableCustomCoreCounts` + * will be used. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); + parent::__construct($data); + } + + /** + * Required. The number of nodes of this type in the cluster + * + * Generated from protobuf field int32 node_count = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return int + */ + public function getNodeCount() + { + return $this->node_count; + } + + /** + * Required. The number of nodes of this type in the cluster + * + * Generated from protobuf field int32 node_count = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param int $var + * @return $this + */ + public function setNodeCount($var) + { + GPBUtil::checkInt32($var); + $this->node_count = $var; + + return $this; + } + + /** + * Optional. Customized number of cores available to each node of the type. + * This number must always be one of `nodeType.availableCustomCoreCounts`. + * If zero is provided max value from `nodeType.availableCustomCoreCounts` + * will be used. + * + * Generated from protobuf field int32 custom_core_count = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return int + */ + public function getCustomCoreCount() + { + return $this->custom_core_count; + } + + /** + * Optional. Customized number of cores available to each node of the type. + * This number must always be one of `nodeType.availableCustomCoreCounts`. + * If zero is provided max value from `nodeType.availableCustomCoreCounts` + * will be used. + * + * Generated from protobuf field int32 custom_core_count = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @param int $var + * @return $this + */ + public function setCustomCoreCount($var) + { + GPBUtil::checkInt32($var); + $this->custom_core_count = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Nsx.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Nsx.php new file mode 100644 index 000000000000..8527b1083f52 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Nsx.php @@ -0,0 +1,169 @@ +google.cloud.vmwareengine.v1.Nsx + */ +class Nsx extends \Google\Protobuf\Internal\Message +{ + /** + * Internal IP address of the appliance. + * + * Generated from protobuf field string internal_ip = 2; + */ + protected $internal_ip = ''; + /** + * Version of the appliance. + * + * Generated from protobuf field string version = 4; + */ + protected $version = ''; + /** + * Output only. The state of the appliance. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.Nsx.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $state = 0; + /** + * Fully qualified domain name of the appliance. + * + * Generated from protobuf field string fqdn = 6; + */ + protected $fqdn = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $internal_ip + * Internal IP address of the appliance. + * @type string $version + * Version of the appliance. + * @type int $state + * Output only. The state of the appliance. + * @type string $fqdn + * Fully qualified domain name of the appliance. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); + parent::__construct($data); + } + + /** + * Internal IP address of the appliance. + * + * Generated from protobuf field string internal_ip = 2; + * @return string + */ + public function getInternalIp() + { + return $this->internal_ip; + } + + /** + * Internal IP address of the appliance. + * + * Generated from protobuf field string internal_ip = 2; + * @param string $var + * @return $this + */ + public function setInternalIp($var) + { + GPBUtil::checkString($var, True); + $this->internal_ip = $var; + + return $this; + } + + /** + * Version of the appliance. + * + * Generated from protobuf field string version = 4; + * @return string + */ + public function getVersion() + { + return $this->version; + } + + /** + * Version of the appliance. + * + * Generated from protobuf field string version = 4; + * @param string $var + * @return $this + */ + public function setVersion($var) + { + GPBUtil::checkString($var, True); + $this->version = $var; + + return $this; + } + + /** + * Output only. The state of the appliance. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.Nsx.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getState() + { + return $this->state; + } + + /** + * Output only. The state of the appliance. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.Nsx.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setState($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\Nsx\State::class); + $this->state = $var; + + return $this; + } + + /** + * Fully qualified domain name of the appliance. + * + * Generated from protobuf field string fqdn = 6; + * @return string + */ + public function getFqdn() + { + return $this->fqdn; + } + + /** + * Fully qualified domain name of the appliance. + * + * Generated from protobuf field string fqdn = 6; + * @param string $var + * @return $this + */ + public function setFqdn($var) + { + GPBUtil::checkString($var, True); + $this->fqdn = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Nsx/State.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Nsx/State.php new file mode 100644 index 000000000000..9993128a8f71 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Nsx/State.php @@ -0,0 +1,61 @@ +google.cloud.vmwareengine.v1.Nsx.State + */ +class State +{ + /** + * Unspecified appliance state. This is the default value. + * + * Generated from protobuf enum STATE_UNSPECIFIED = 0; + */ + const STATE_UNSPECIFIED = 0; + /** + * The appliance is operational and can be used. + * + * Generated from protobuf enum ACTIVE = 1; + */ + const ACTIVE = 1; + /** + * The appliance is being deployed. + * + * Generated from protobuf enum CREATING = 2; + */ + const CREATING = 2; + + private static $valueToName = [ + self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', + self::ACTIVE => 'ACTIVE', + self::CREATING => 'CREATING', + ]; + + 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/OperationMetadata.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/OperationMetadata.php new file mode 100644 index 000000000000..3cf2dca10ff5 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/OperationMetadata.php @@ -0,0 +1,311 @@ +google.cloud.vmwareengine.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. True if the user has requested cancellation + * of the operation; false otherwise. + * 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. True if the user has requested cancellation + * of the operation; false otherwise. + * 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\Vmwareengine\V1\Vmwareengine::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. True if the user has requested cancellation + * of the operation; false otherwise. + * 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. True if the user has requested cancellation + * of the operation; false otherwise. + * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PeeringRoute.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PeeringRoute.php new file mode 100644 index 000000000000..b3b461952293 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PeeringRoute.php @@ -0,0 +1,273 @@ +google.cloud.vmwareengine.v1.PeeringRoute + */ +class PeeringRoute extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. Destination range of the peering route in CIDR notation. + * + * Generated from protobuf field string dest_range = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $dest_range = ''; + /** + * Output only. Type of the route in the peer VPC network. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.PeeringRoute.Type type = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $type = 0; + /** + * Output only. Region containing the next hop of the peering route. This + * field only applies to dynamic routes in the peer VPC network. + * + * Generated from protobuf field string next_hop_region = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $next_hop_region = ''; + /** + * Output only. The priority of the peering route. + * + * Generated from protobuf field int64 priority = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $priority = 0; + /** + * Output only. True if the peering route has been imported from a peered + * VPC network; false otherwise. The import happens if the field + * `NetworkPeering.importCustomRoutes` is true for this network, + * `NetworkPeering.exportCustomRoutes` is true for the peer VPC network, and + * the import does not result in a route conflict. + * + * Generated from protobuf field bool imported = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $imported = false; + /** + * Output only. Direction of the routes exchanged with the peer network, from + * the VMware Engine network perspective: + * * Routes of direction `INCOMING` are imported from the peer network. + * * Routes of direction `OUTGOING` are exported from the intranet VPC network + * of the VMware Engine network. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.PeeringRoute.Direction direction = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $direction = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $dest_range + * Output only. Destination range of the peering route in CIDR notation. + * @type int $type + * Output only. Type of the route in the peer VPC network. + * @type string $next_hop_region + * Output only. Region containing the next hop of the peering route. This + * field only applies to dynamic routes in the peer VPC network. + * @type int|string $priority + * Output only. The priority of the peering route. + * @type bool $imported + * Output only. True if the peering route has been imported from a peered + * VPC network; false otherwise. The import happens if the field + * `NetworkPeering.importCustomRoutes` is true for this network, + * `NetworkPeering.exportCustomRoutes` is true for the peer VPC network, and + * the import does not result in a route conflict. + * @type int $direction + * Output only. Direction of the routes exchanged with the peer network, from + * the VMware Engine network perspective: + * * Routes of direction `INCOMING` are imported from the peer network. + * * Routes of direction `OUTGOING` are exported from the intranet VPC network + * of the VMware Engine network. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); + parent::__construct($data); + } + + /** + * Output only. Destination range of the peering route in CIDR notation. + * + * Generated from protobuf field string dest_range = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getDestRange() + { + return $this->dest_range; + } + + /** + * Output only. Destination range of the peering route in CIDR notation. + * + * Generated from protobuf field string dest_range = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setDestRange($var) + { + GPBUtil::checkString($var, True); + $this->dest_range = $var; + + return $this; + } + + /** + * Output only. Type of the route in the peer VPC network. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.PeeringRoute.Type type = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getType() + { + return $this->type; + } + + /** + * Output only. Type of the route in the peer VPC network. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.PeeringRoute.Type type = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setType($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\PeeringRoute\Type::class); + $this->type = $var; + + return $this; + } + + /** + * Output only. Region containing the next hop of the peering route. This + * field only applies to dynamic routes in the peer VPC network. + * + * Generated from protobuf field string next_hop_region = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getNextHopRegion() + { + return $this->next_hop_region; + } + + /** + * Output only. Region containing the next hop of the peering route. This + * field only applies to dynamic routes in the peer VPC network. + * + * Generated from protobuf field string next_hop_region = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setNextHopRegion($var) + { + GPBUtil::checkString($var, True); + $this->next_hop_region = $var; + + return $this; + } + + /** + * Output only. The priority of the peering route. + * + * Generated from protobuf field int64 priority = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int|string + */ + public function getPriority() + { + return $this->priority; + } + + /** + * Output only. The priority of the peering route. + * + * Generated from protobuf field int64 priority = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int|string $var + * @return $this + */ + public function setPriority($var) + { + GPBUtil::checkInt64($var); + $this->priority = $var; + + return $this; + } + + /** + * Output only. True if the peering route has been imported from a peered + * VPC network; false otherwise. The import happens if the field + * `NetworkPeering.importCustomRoutes` is true for this network, + * `NetworkPeering.exportCustomRoutes` is true for the peer VPC network, and + * the import does not result in a route conflict. + * + * Generated from protobuf field bool imported = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return bool + */ + public function getImported() + { + return $this->imported; + } + + /** + * Output only. True if the peering route has been imported from a peered + * VPC network; false otherwise. The import happens if the field + * `NetworkPeering.importCustomRoutes` is true for this network, + * `NetworkPeering.exportCustomRoutes` is true for the peer VPC network, and + * the import does not result in a route conflict. + * + * Generated from protobuf field bool imported = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param bool $var + * @return $this + */ + public function setImported($var) + { + GPBUtil::checkBool($var); + $this->imported = $var; + + return $this; + } + + /** + * Output only. Direction of the routes exchanged with the peer network, from + * the VMware Engine network perspective: + * * Routes of direction `INCOMING` are imported from the peer network. + * * Routes of direction `OUTGOING` are exported from the intranet VPC network + * of the VMware Engine network. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.PeeringRoute.Direction direction = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getDirection() + { + return $this->direction; + } + + /** + * Output only. Direction of the routes exchanged with the peer network, from + * the VMware Engine network perspective: + * * Routes of direction `INCOMING` are imported from the peer network. + * * Routes of direction `OUTGOING` are exported from the intranet VPC network + * of the VMware Engine network. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.PeeringRoute.Direction direction = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setDirection($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\PeeringRoute\Direction::class); + $this->direction = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PeeringRoute/Direction.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PeeringRoute/Direction.php new file mode 100644 index 000000000000..23cd5efbf13c --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PeeringRoute/Direction.php @@ -0,0 +1,61 @@ +google.cloud.vmwareengine.v1.PeeringRoute.Direction + */ +class Direction +{ + /** + * Unspecified exchanged routes direction. This is default. + * + * Generated from protobuf enum DIRECTION_UNSPECIFIED = 0; + */ + const DIRECTION_UNSPECIFIED = 0; + /** + * Routes imported from the peer network. + * + * Generated from protobuf enum INCOMING = 1; + */ + const INCOMING = 1; + /** + * Routes exported to the peer network. + * + * Generated from protobuf enum OUTGOING = 2; + */ + const OUTGOING = 2; + + private static $valueToName = [ + self::DIRECTION_UNSPECIFIED => 'DIRECTION_UNSPECIFIED', + self::INCOMING => 'INCOMING', + self::OUTGOING => 'OUTGOING', + ]; + + 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PeeringRoute/Type.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PeeringRoute/Type.php new file mode 100644 index 000000000000..60e15b1025ff --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PeeringRoute/Type.php @@ -0,0 +1,69 @@ +google.cloud.vmwareengine.v1.PeeringRoute.Type + */ +class Type +{ + /** + * Unspecified peering route type. This is the default value. + * + * Generated from protobuf enum TYPE_UNSPECIFIED = 0; + */ + const TYPE_UNSPECIFIED = 0; + /** + * Dynamic routes in the peer network. + * + * Generated from protobuf enum DYNAMIC_PEERING_ROUTE = 1; + */ + const DYNAMIC_PEERING_ROUTE = 1; + /** + * Static routes in the peer network. + * + * Generated from protobuf enum STATIC_PEERING_ROUTE = 2; + */ + const STATIC_PEERING_ROUTE = 2; + /** + * Created, updated, and removed automatically by Google Cloud when subnets + * are created, modified, or deleted in the peer network. + * + * Generated from protobuf enum SUBNET_PEERING_ROUTE = 3; + */ + const SUBNET_PEERING_ROUTE = 3; + + private static $valueToName = [ + self::TYPE_UNSPECIFIED => 'TYPE_UNSPECIFIED', + self::DYNAMIC_PEERING_ROUTE => 'DYNAMIC_PEERING_ROUTE', + self::STATIC_PEERING_ROUTE => 'STATIC_PEERING_ROUTE', + self::SUBNET_PEERING_ROUTE => 'SUBNET_PEERING_ROUTE', + ]; + + 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Principal.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Principal.php new file mode 100644 index 000000000000..7eb8388e7217 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Principal.php @@ -0,0 +1,109 @@ +google.cloud.vmwareengine.v1.Principal + */ +class Principal extends \Google\Protobuf\Internal\Message +{ + protected $principal; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $user + * The user who needs to be granted permission. + * @type string $service_account + * The service account which needs to be granted the permission. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); + parent::__construct($data); + } + + /** + * The user who needs to be granted permission. + * + * Generated from protobuf field string user = 1; + * @return string + */ + public function getUser() + { + return $this->readOneof(1); + } + + public function hasUser() + { + return $this->hasOneof(1); + } + + /** + * The user who needs to be granted permission. + * + * Generated from protobuf field string user = 1; + * @param string $var + * @return $this + */ + public function setUser($var) + { + GPBUtil::checkString($var, True); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * The service account which needs to be granted the permission. + * + * Generated from protobuf field string service_account = 2; + * @return string + */ + public function getServiceAccount() + { + return $this->readOneof(2); + } + + public function hasServiceAccount() + { + return $this->hasOneof(2); + } + + /** + * The service account which needs to be granted the permission. + * + * Generated from protobuf field string service_account = 2; + * @param string $var + * @return $this + */ + public function setServiceAccount($var) + { + GPBUtil::checkString($var, True); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * @return string + */ + public function getPrincipal() + { + return $this->whichOneof("principal"); + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateCloud.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateCloud.php new file mode 100644 index 000000000000..978f9d15a52a --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateCloud.php @@ -0,0 +1,637 @@ +google.cloud.vmwareengine.v1.PrivateCloud + */ +class PrivateCloud extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. The resource name of this private cloud. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $name = ''; + /** + * Output only. Creation time of this resource. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $create_time = null; + /** + * Output only. Last update time of this resource. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $update_time = null; + /** + * Output only. Time when the resource was scheduled for deletion. + * + * Generated from protobuf field .google.protobuf.Timestamp delete_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $delete_time = null; + /** + * Output only. Time when the resource will be irreversibly deleted. + * + * Generated from protobuf field .google.protobuf.Timestamp expire_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $expire_time = null; + /** + * Output only. State of the resource. New values may be added to this enum + * when appropriate. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateCloud.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $state = 0; + /** + * Required. Network configuration of the private cloud. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkConfig network_config = 9 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $network_config = null; + /** + * Required. Input only. The management cluster for this private cloud. + * This field is required during creation of the private cloud to provide + * details for the default cluster. + * The following fields can't be changed after private cloud creation: + * `ManagementCluster.clusterId`, `ManagementCluster.nodeTypeId`. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateCloud.ManagementCluster management_cluster = 10 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = REQUIRED]; + */ + protected $management_cluster = null; + /** + * User-provided description for this private cloud. + * + * Generated from protobuf field string description = 11; + */ + protected $description = ''; + /** + * Output only. HCX appliance. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.Hcx hcx = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $hcx = null; + /** + * Output only. NSX appliance. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.Nsx nsx = 18 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $nsx = null; + /** + * Output only. Vcenter appliance. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.Vcenter vcenter = 19 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $vcenter = null; + /** + * Output only. System-generated unique identifier for the resource. + * + * Generated from protobuf field string uid = 20 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $uid = ''; + /** + * Optional. Type of the private cloud. Defaults to STANDARD. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateCloud.Type type = 22 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $type = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Output only. The resource name of this private cloud. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * @type \Google\Protobuf\Timestamp $create_time + * Output only. Creation time of this resource. + * @type \Google\Protobuf\Timestamp $update_time + * Output only. Last update time of this resource. + * @type \Google\Protobuf\Timestamp $delete_time + * Output only. Time when the resource was scheduled for deletion. + * @type \Google\Protobuf\Timestamp $expire_time + * Output only. Time when the resource will be irreversibly deleted. + * @type int $state + * Output only. State of the resource. New values may be added to this enum + * when appropriate. + * @type \Google\Cloud\VmwareEngine\V1\NetworkConfig $network_config + * Required. Network configuration of the private cloud. + * @type \Google\Cloud\VmwareEngine\V1\PrivateCloud\ManagementCluster $management_cluster + * Required. Input only. The management cluster for this private cloud. + * This field is required during creation of the private cloud to provide + * details for the default cluster. + * The following fields can't be changed after private cloud creation: + * `ManagementCluster.clusterId`, `ManagementCluster.nodeTypeId`. + * @type string $description + * User-provided description for this private cloud. + * @type \Google\Cloud\VmwareEngine\V1\Hcx $hcx + * Output only. HCX appliance. + * @type \Google\Cloud\VmwareEngine\V1\Nsx $nsx + * Output only. NSX appliance. + * @type \Google\Cloud\VmwareEngine\V1\Vcenter $vcenter + * Output only. Vcenter appliance. + * @type string $uid + * Output only. System-generated unique identifier for the resource. + * @type int $type + * Optional. Type of the private cloud. Defaults to STANDARD. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); + parent::__construct($data); + } + + /** + * Output only. The resource name of this private cloud. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * 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 private cloud. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * 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. Creation time of this resource. + * + * 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 time of this resource. + * + * 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 time of this resource. + * + * 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 time of this resource. + * + * 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. Time when the resource was scheduled for deletion. + * + * Generated from protobuf field .google.protobuf.Timestamp delete_time = 4 [(.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 when the resource was scheduled for deletion. + * + * Generated from protobuf field .google.protobuf.Timestamp delete_time = 4 [(.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. Time when the resource will be irreversibly deleted. + * + * Generated from protobuf field .google.protobuf.Timestamp expire_time = 5 [(.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. Time when the resource will be irreversibly deleted. + * + * Generated from protobuf field .google.protobuf.Timestamp expire_time = 5 [(.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. State of the resource. New values may be added to this enum + * when appropriate. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateCloud.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getState() + { + return $this->state; + } + + /** + * Output only. State of the resource. New values may be added to this enum + * when appropriate. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateCloud.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setState($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\PrivateCloud\State::class); + $this->state = $var; + + return $this; + } + + /** + * Required. Network configuration of the private cloud. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkConfig network_config = 9 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\VmwareEngine\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); + } + + /** + * Required. Network configuration of the private cloud. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkConfig network_config = 9 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\VmwareEngine\V1\NetworkConfig $var + * @return $this + */ + public function setNetworkConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\NetworkConfig::class); + $this->network_config = $var; + + return $this; + } + + /** + * Required. Input only. The management cluster for this private cloud. + * This field is required during creation of the private cloud to provide + * details for the default cluster. + * The following fields can't be changed after private cloud creation: + * `ManagementCluster.clusterId`, `ManagementCluster.nodeTypeId`. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateCloud.ManagementCluster management_cluster = 10 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\VmwareEngine\V1\PrivateCloud\ManagementCluster|null + */ + public function getManagementCluster() + { + return $this->management_cluster; + } + + public function hasManagementCluster() + { + return isset($this->management_cluster); + } + + public function clearManagementCluster() + { + unset($this->management_cluster); + } + + /** + * Required. Input only. The management cluster for this private cloud. + * This field is required during creation of the private cloud to provide + * details for the default cluster. + * The following fields can't be changed after private cloud creation: + * `ManagementCluster.clusterId`, `ManagementCluster.nodeTypeId`. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateCloud.ManagementCluster management_cluster = 10 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\VmwareEngine\V1\PrivateCloud\ManagementCluster $var + * @return $this + */ + public function setManagementCluster($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\PrivateCloud\ManagementCluster::class); + $this->management_cluster = $var; + + return $this; + } + + /** + * User-provided description for this private cloud. + * + * Generated from protobuf field string description = 11; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * User-provided description for this private cloud. + * + * Generated from protobuf field string description = 11; + * @param string $var + * @return $this + */ + public function setDescription($var) + { + GPBUtil::checkString($var, True); + $this->description = $var; + + return $this; + } + + /** + * Output only. HCX appliance. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.Hcx hcx = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Cloud\VmwareEngine\V1\Hcx|null + */ + public function getHcx() + { + return $this->hcx; + } + + public function hasHcx() + { + return isset($this->hcx); + } + + public function clearHcx() + { + unset($this->hcx); + } + + /** + * Output only. HCX appliance. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.Hcx hcx = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Cloud\VmwareEngine\V1\Hcx $var + * @return $this + */ + public function setHcx($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\Hcx::class); + $this->hcx = $var; + + return $this; + } + + /** + * Output only. NSX appliance. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.Nsx nsx = 18 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Cloud\VmwareEngine\V1\Nsx|null + */ + public function getNsx() + { + return $this->nsx; + } + + public function hasNsx() + { + return isset($this->nsx); + } + + public function clearNsx() + { + unset($this->nsx); + } + + /** + * Output only. NSX appliance. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.Nsx nsx = 18 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Cloud\VmwareEngine\V1\Nsx $var + * @return $this + */ + public function setNsx($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\Nsx::class); + $this->nsx = $var; + + return $this; + } + + /** + * Output only. Vcenter appliance. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.Vcenter vcenter = 19 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Cloud\VmwareEngine\V1\Vcenter|null + */ + public function getVcenter() + { + return $this->vcenter; + } + + public function hasVcenter() + { + return isset($this->vcenter); + } + + public function clearVcenter() + { + unset($this->vcenter); + } + + /** + * Output only. Vcenter appliance. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.Vcenter vcenter = 19 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Cloud\VmwareEngine\V1\Vcenter $var + * @return $this + */ + public function setVcenter($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\Vcenter::class); + $this->vcenter = $var; + + return $this; + } + + /** + * Output only. System-generated unique identifier for the resource. + * + * Generated from protobuf field string uid = 20 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getUid() + { + return $this->uid; + } + + /** + * Output only. System-generated unique identifier for the resource. + * + * Generated from protobuf field string uid = 20 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setUid($var) + { + GPBUtil::checkString($var, True); + $this->uid = $var; + + return $this; + } + + /** + * Optional. Type of the private cloud. Defaults to STANDARD. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateCloud.Type type = 22 [(.google.api.field_behavior) = OPTIONAL]; + * @return int + */ + public function getType() + { + return $this->type; + } + + /** + * Optional. Type of the private cloud. Defaults to STANDARD. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateCloud.Type type = 22 [(.google.api.field_behavior) = OPTIONAL]; + * @param int $var + * @return $this + */ + public function setType($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\PrivateCloud\Type::class); + $this->type = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateCloud/ManagementCluster.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateCloud/ManagementCluster.php new file mode 100644 index 000000000000..04ac33651a47 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateCloud/ManagementCluster.php @@ -0,0 +1,181 @@ +google.cloud.vmwareengine.v1.PrivateCloud.ManagementCluster + */ +class ManagementCluster extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The user-provided identifier of the new `Cluster`. + * The identifier must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC + * 1034](https://datatracker.ietf.org/doc/html/rfc1034) (section 3.5) + * + * Generated from protobuf field string cluster_id = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $cluster_id = ''; + /** + * Required. The map of cluster node types in this cluster, where the key is + * canonical identifier of the node type (corresponds to the `NodeType`). + * + * Generated from protobuf field map node_type_configs = 7 [(.google.api.field_behavior) = REQUIRED]; + */ + private $node_type_configs; + /** + * Optional. Configuration of a stretched cluster. Required for STRETCHED + * private clouds. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.StretchedClusterConfig stretched_cluster_config = 8 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $stretched_cluster_config = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $cluster_id + * Required. The user-provided identifier of the new `Cluster`. + * The identifier must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC + * 1034](https://datatracker.ietf.org/doc/html/rfc1034) (section 3.5) + * @type array|\Google\Protobuf\Internal\MapField $node_type_configs + * Required. The map of cluster node types in this cluster, where the key is + * canonical identifier of the node type (corresponds to the `NodeType`). + * @type \Google\Cloud\VmwareEngine\V1\StretchedClusterConfig $stretched_cluster_config + * Optional. Configuration of a stretched cluster. Required for STRETCHED + * private clouds. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); + parent::__construct($data); + } + + /** + * Required. The user-provided identifier of the new `Cluster`. + * The identifier must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC + * 1034](https://datatracker.ietf.org/doc/html/rfc1034) (section 3.5) + * + * Generated from protobuf field string cluster_id = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getClusterId() + { + return $this->cluster_id; + } + + /** + * Required. The user-provided identifier of the new `Cluster`. + * The identifier must meet the following requirements: + * * Only contains 1-63 alphanumeric characters and hyphens + * * Begins with an alphabetical character + * * Ends with a non-hyphen character + * * Not formatted as a UUID + * * Complies with [RFC + * 1034](https://datatracker.ietf.org/doc/html/rfc1034) (section 3.5) + * + * Generated from protobuf field string cluster_id = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setClusterId($var) + { + GPBUtil::checkString($var, True); + $this->cluster_id = $var; + + return $this; + } + + /** + * Required. The map of cluster node types in this cluster, where the key is + * canonical identifier of the node type (corresponds to the `NodeType`). + * + * Generated from protobuf field map node_type_configs = 7 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Protobuf\Internal\MapField + */ + public function getNodeTypeConfigs() + { + return $this->node_type_configs; + } + + /** + * Required. The map of cluster node types in this cluster, where the key is + * canonical identifier of the node type (corresponds to the `NodeType`). + * + * Generated from protobuf field map node_type_configs = 7 [(.google.api.field_behavior) = REQUIRED]; + * @param array|\Google\Protobuf\Internal\MapField $var + * @return $this + */ + public function setNodeTypeConfigs($var) + { + $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\NodeTypeConfig::class); + $this->node_type_configs = $arr; + + return $this; + } + + /** + * Optional. Configuration of a stretched cluster. Required for STRETCHED + * private clouds. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.StretchedClusterConfig stretched_cluster_config = 8 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\VmwareEngine\V1\StretchedClusterConfig|null + */ + public function getStretchedClusterConfig() + { + return $this->stretched_cluster_config; + } + + public function hasStretchedClusterConfig() + { + return isset($this->stretched_cluster_config); + } + + public function clearStretchedClusterConfig() + { + unset($this->stretched_cluster_config); + } + + /** + * Optional. Configuration of a stretched cluster. Required for STRETCHED + * private clouds. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.StretchedClusterConfig stretched_cluster_config = 8 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\VmwareEngine\V1\StretchedClusterConfig $var + * @return $this + */ + public function setStretchedClusterConfig($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\StretchedClusterConfig::class); + $this->stretched_cluster_config = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateCloud/State.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateCloud/State.php new file mode 100644 index 000000000000..4d9eedfbdb73 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateCloud/State.php @@ -0,0 +1,91 @@ +google.cloud.vmwareengine.v1.PrivateCloud.State + */ +class State +{ + /** + * The default value. This value should never be used. + * + * Generated from protobuf enum STATE_UNSPECIFIED = 0; + */ + const STATE_UNSPECIFIED = 0; + /** + * The private cloud is ready. + * + * Generated from protobuf enum ACTIVE = 1; + */ + const ACTIVE = 1; + /** + * The private cloud is being created. + * + * Generated from protobuf enum CREATING = 2; + */ + const CREATING = 2; + /** + * The private cloud is being updated. + * + * Generated from protobuf enum UPDATING = 3; + */ + const UPDATING = 3; + /** + * The private cloud is in failed state. + * + * Generated from protobuf enum FAILED = 5; + */ + const FAILED = 5; + /** + * The private cloud is scheduled for deletion. The deletion process can be + * cancelled by using the corresponding undelete method. + * + * Generated from protobuf enum DELETED = 6; + */ + const DELETED = 6; + /** + * The private cloud is irreversibly deleted and is being removed from the + * system. + * + * Generated from protobuf enum PURGING = 7; + */ + const PURGING = 7; + + private static $valueToName = [ + self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', + self::ACTIVE => 'ACTIVE', + self::CREATING => 'CREATING', + self::UPDATING => 'UPDATING', + self::FAILED => 'FAILED', + self::DELETED => 'DELETED', + self::PURGING => 'PURGING', + ]; + + 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateCloud/Type.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateCloud/Type.php new file mode 100644 index 000000000000..12765c323a8e --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateCloud/Type.php @@ -0,0 +1,65 @@ +google.cloud.vmwareengine.v1.PrivateCloud.Type + */ +class Type +{ + /** + * Standard private is a zonal resource, with 3+ nodes. Default type. + * + * Generated from protobuf enum STANDARD = 0; + */ + const STANDARD = 0; + /** + * Time limited private cloud is a zonal resource, can have only 1 node and + * has limited life span. Will be deleted after defined period of time, + * can be converted into standard private cloud by expanding it up to 3 + * or more nodes. + * + * Generated from protobuf enum TIME_LIMITED = 1; + */ + const TIME_LIMITED = 1; + /** + * Stretched private cloud is a regional resource with redundancy, + * with a minimum of 6 nodes, nodes count has to be even. + * + * Generated from protobuf enum STRETCHED = 2; + */ + const STRETCHED = 2; + + private static $valueToName = [ + self::STANDARD => 'STANDARD', + self::TIME_LIMITED => 'TIME_LIMITED', + self::STRETCHED => 'STRETCHED', + ]; + + 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateConnection.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateConnection.php new file mode 100644 index 000000000000..5ee125dfa695 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateConnection.php @@ -0,0 +1,604 @@ +google.cloud.vmwareengine.v1.PrivateConnection + */ +class PrivateConnection extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. The resource name of the private connection. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/privateConnections/my-connection` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $name = ''; + /** + * Output only. Creation time of this resource. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $create_time = null; + /** + * Output only. Last update time of this resource. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $update_time = null; + /** + * Optional. User-provided description for this private connection. + * + * Generated from protobuf field string description = 4 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $description = ''; + /** + * Output only. State of the private connection. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateConnection.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $state = 0; + /** + * Required. The relative resource name of Legacy VMware Engine network. + * Specify the name in the following form: + * `projects/{project}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` + * where `{project}`, `{location}` will be same as specified in private + * connection resource name and `{vmware_engine_network_id}` will be in the + * form of `{location}`-default e.g. + * projects/project/locations/us-central1/vmwareEngineNetworks/us-central1-default. + * + * Generated from protobuf field string vmware_engine_network = 8 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $vmware_engine_network = ''; + /** + * Output only. The canonical name of the VMware Engine network in the form: + * `projects/{project_number}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` + * + * Generated from protobuf field string vmware_engine_network_canonical = 9 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { + */ + protected $vmware_engine_network_canonical = ''; + /** + * Required. Private connection type. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateConnection.Type type = 10 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $type = 0; + /** + * Output only. VPC network peering id between given network VPC and + * VMwareEngineNetwork. + * + * Generated from protobuf field string peering_id = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $peering_id = ''; + /** + * Optional. Routing Mode. + * Default value is set to GLOBAL. + * For type = PRIVATE_SERVICE_ACCESS, this field can be set to GLOBAL or + * REGIONAL, for other types only GLOBAL is supported. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateConnection.RoutingMode routing_mode = 13 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $routing_mode = 0; + /** + * Output only. System-generated unique identifier for the resource. + * + * Generated from protobuf field string uid = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $uid = ''; + /** + * Required. Service network to create private connection. + * Specify the name in the following form: + * `projects/{project}/global/networks/{network_id}` + * For type = PRIVATE_SERVICE_ACCESS, this field represents servicenetworking + * VPC, e.g. projects/project-tp/global/networks/servicenetworking. + * For type = NETAPP_CLOUD_VOLUME, this field represents NetApp service VPC, + * e.g. projects/project-tp/global/networks/netapp-tenant-vpc. + * For type = DELL_POWERSCALE, this field represent Dell service VPC, e.g. + * projects/project-tp/global/networks/dell-tenant-vpc. + * For type= THIRD_PARTY_SERVICE, this field could represent a consumer VPC or + * any other producer VPC to which the VMware Engine Network needs to be + * connected, e.g. projects/project/global/networks/vpc. + * + * Generated from protobuf field string service_network = 16 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $service_network = ''; + /** + * Output only. Peering state between service network and VMware Engine + * network. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateConnection.PeeringState peering_state = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $peering_state = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Output only. The resource name of the private connection. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/privateConnections/my-connection` + * @type \Google\Protobuf\Timestamp $create_time + * Output only. Creation time of this resource. + * @type \Google\Protobuf\Timestamp $update_time + * Output only. Last update time of this resource. + * @type string $description + * Optional. User-provided description for this private connection. + * @type int $state + * Output only. State of the private connection. + * @type string $vmware_engine_network + * Required. The relative resource name of Legacy VMware Engine network. + * Specify the name in the following form: + * `projects/{project}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` + * where `{project}`, `{location}` will be same as specified in private + * connection resource name and `{vmware_engine_network_id}` will be in the + * form of `{location}`-default e.g. + * projects/project/locations/us-central1/vmwareEngineNetworks/us-central1-default. + * @type string $vmware_engine_network_canonical + * Output only. The canonical name of the VMware Engine network in the form: + * `projects/{project_number}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` + * @type int $type + * Required. Private connection type. + * @type string $peering_id + * Output only. VPC network peering id between given network VPC and + * VMwareEngineNetwork. + * @type int $routing_mode + * Optional. Routing Mode. + * Default value is set to GLOBAL. + * For type = PRIVATE_SERVICE_ACCESS, this field can be set to GLOBAL or + * REGIONAL, for other types only GLOBAL is supported. + * @type string $uid + * Output only. System-generated unique identifier for the resource. + * @type string $service_network + * Required. Service network to create private connection. + * Specify the name in the following form: + * `projects/{project}/global/networks/{network_id}` + * For type = PRIVATE_SERVICE_ACCESS, this field represents servicenetworking + * VPC, e.g. projects/project-tp/global/networks/servicenetworking. + * For type = NETAPP_CLOUD_VOLUME, this field represents NetApp service VPC, + * e.g. projects/project-tp/global/networks/netapp-tenant-vpc. + * For type = DELL_POWERSCALE, this field represent Dell service VPC, e.g. + * projects/project-tp/global/networks/dell-tenant-vpc. + * For type= THIRD_PARTY_SERVICE, this field could represent a consumer VPC or + * any other producer VPC to which the VMware Engine Network needs to be + * connected, e.g. projects/project/global/networks/vpc. + * @type int $peering_state + * Output only. Peering state between service network and VMware Engine + * network. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); + parent::__construct($data); + } + + /** + * Output only. The resource name of the private connection. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/privateConnections/my-connection` + * + * 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 private connection. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1/privateConnections/my-connection` + * + * 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. Creation time of this resource. + * + * 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 time of this resource. + * + * 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 time of this resource. + * + * 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 time of this resource. + * + * 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 description for this private connection. + * + * Generated from protobuf field string description = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * Optional. User-provided description for this private connection. + * + * Generated from protobuf field string description = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @param string $var + * @return $this + */ + public function setDescription($var) + { + GPBUtil::checkString($var, True); + $this->description = $var; + + return $this; + } + + /** + * Output only. State of the private connection. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateConnection.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getState() + { + return $this->state; + } + + /** + * Output only. State of the private connection. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateConnection.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setState($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\PrivateConnection\State::class); + $this->state = $var; + + return $this; + } + + /** + * Required. The relative resource name of Legacy VMware Engine network. + * Specify the name in the following form: + * `projects/{project}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` + * where `{project}`, `{location}` will be same as specified in private + * connection resource name and `{vmware_engine_network_id}` will be in the + * form of `{location}`-default e.g. + * projects/project/locations/us-central1/vmwareEngineNetworks/us-central1-default. + * + * Generated from protobuf field string vmware_engine_network = 8 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getVmwareEngineNetwork() + { + return $this->vmware_engine_network; + } + + /** + * Required. The relative resource name of Legacy VMware Engine network. + * Specify the name in the following form: + * `projects/{project}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` + * where `{project}`, `{location}` will be same as specified in private + * connection resource name and `{vmware_engine_network_id}` will be in the + * form of `{location}`-default e.g. + * projects/project/locations/us-central1/vmwareEngineNetworks/us-central1-default. + * + * Generated from protobuf field string vmware_engine_network = 8 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setVmwareEngineNetwork($var) + { + GPBUtil::checkString($var, True); + $this->vmware_engine_network = $var; + + return $this; + } + + /** + * Output only. The canonical name of the VMware Engine network in the form: + * `projects/{project_number}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` + * + * Generated from protobuf field string vmware_engine_network_canonical = 9 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { + * @return string + */ + public function getVmwareEngineNetworkCanonical() + { + return $this->vmware_engine_network_canonical; + } + + /** + * Output only. The canonical name of the VMware Engine network in the form: + * `projects/{project_number}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` + * + * Generated from protobuf field string vmware_engine_network_canonical = 9 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setVmwareEngineNetworkCanonical($var) + { + GPBUtil::checkString($var, True); + $this->vmware_engine_network_canonical = $var; + + return $this; + } + + /** + * Required. Private connection type. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateConnection.Type type = 10 [(.google.api.field_behavior) = REQUIRED]; + * @return int + */ + public function getType() + { + return $this->type; + } + + /** + * Required. Private connection type. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateConnection.Type type = 10 [(.google.api.field_behavior) = REQUIRED]; + * @param int $var + * @return $this + */ + public function setType($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\PrivateConnection\Type::class); + $this->type = $var; + + return $this; + } + + /** + * Output only. VPC network peering id between given network VPC and + * VMwareEngineNetwork. + * + * Generated from protobuf field string peering_id = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getPeeringId() + { + return $this->peering_id; + } + + /** + * Output only. VPC network peering id between given network VPC and + * VMwareEngineNetwork. + * + * Generated from protobuf field string peering_id = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setPeeringId($var) + { + GPBUtil::checkString($var, True); + $this->peering_id = $var; + + return $this; + } + + /** + * Optional. Routing Mode. + * Default value is set to GLOBAL. + * For type = PRIVATE_SERVICE_ACCESS, this field can be set to GLOBAL or + * REGIONAL, for other types only GLOBAL is supported. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateConnection.RoutingMode routing_mode = 13 [(.google.api.field_behavior) = OPTIONAL]; + * @return int + */ + public function getRoutingMode() + { + return $this->routing_mode; + } + + /** + * Optional. Routing Mode. + * Default value is set to GLOBAL. + * For type = PRIVATE_SERVICE_ACCESS, this field can be set to GLOBAL or + * REGIONAL, for other types only GLOBAL is supported. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateConnection.RoutingMode routing_mode = 13 [(.google.api.field_behavior) = OPTIONAL]; + * @param int $var + * @return $this + */ + public function setRoutingMode($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\PrivateConnection\RoutingMode::class); + $this->routing_mode = $var; + + return $this; + } + + /** + * Output only. System-generated unique identifier for the resource. + * + * Generated from protobuf field string uid = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getUid() + { + return $this->uid; + } + + /** + * Output only. System-generated unique identifier for the resource. + * + * Generated from protobuf field string uid = 14 [(.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. Service network to create private connection. + * Specify the name in the following form: + * `projects/{project}/global/networks/{network_id}` + * For type = PRIVATE_SERVICE_ACCESS, this field represents servicenetworking + * VPC, e.g. projects/project-tp/global/networks/servicenetworking. + * For type = NETAPP_CLOUD_VOLUME, this field represents NetApp service VPC, + * e.g. projects/project-tp/global/networks/netapp-tenant-vpc. + * For type = DELL_POWERSCALE, this field represent Dell service VPC, e.g. + * projects/project-tp/global/networks/dell-tenant-vpc. + * For type= THIRD_PARTY_SERVICE, this field could represent a consumer VPC or + * any other producer VPC to which the VMware Engine Network needs to be + * connected, e.g. projects/project/global/networks/vpc. + * + * Generated from protobuf field string service_network = 16 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getServiceNetwork() + { + return $this->service_network; + } + + /** + * Required. Service network to create private connection. + * Specify the name in the following form: + * `projects/{project}/global/networks/{network_id}` + * For type = PRIVATE_SERVICE_ACCESS, this field represents servicenetworking + * VPC, e.g. projects/project-tp/global/networks/servicenetworking. + * For type = NETAPP_CLOUD_VOLUME, this field represents NetApp service VPC, + * e.g. projects/project-tp/global/networks/netapp-tenant-vpc. + * For type = DELL_POWERSCALE, this field represent Dell service VPC, e.g. + * projects/project-tp/global/networks/dell-tenant-vpc. + * For type= THIRD_PARTY_SERVICE, this field could represent a consumer VPC or + * any other producer VPC to which the VMware Engine Network needs to be + * connected, e.g. projects/project/global/networks/vpc. + * + * Generated from protobuf field string service_network = 16 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setServiceNetwork($var) + { + GPBUtil::checkString($var, True); + $this->service_network = $var; + + return $this; + } + + /** + * Output only. Peering state between service network and VMware Engine + * network. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateConnection.PeeringState peering_state = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getPeeringState() + { + return $this->peering_state; + } + + /** + * Output only. Peering state between service network and VMware Engine + * network. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateConnection.PeeringState peering_state = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setPeeringState($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\PrivateConnection\PeeringState::class); + $this->peering_state = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateConnection/PeeringState.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateConnection/PeeringState.php new file mode 100644 index 000000000000..611bf6fa8853 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateConnection/PeeringState.php @@ -0,0 +1,63 @@ +google.cloud.vmwareengine.v1.PrivateConnection.PeeringState + */ +class PeeringState +{ + /** + * The default value. This value is used if the peering state is omitted or + * unknown. + * + * Generated from protobuf enum PEERING_STATE_UNSPECIFIED = 0; + */ + const PEERING_STATE_UNSPECIFIED = 0; + /** + * The peering is in active state. + * + * Generated from protobuf enum PEERING_ACTIVE = 1; + */ + const PEERING_ACTIVE = 1; + /** + * The peering is in inactive state. + * + * Generated from protobuf enum PEERING_INACTIVE = 2; + */ + const PEERING_INACTIVE = 2; + + private static $valueToName = [ + self::PEERING_STATE_UNSPECIFIED => 'PEERING_STATE_UNSPECIFIED', + self::PEERING_ACTIVE => 'PEERING_ACTIVE', + self::PEERING_INACTIVE => 'PEERING_INACTIVE', + ]; + + 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateConnection/RoutingMode.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateConnection/RoutingMode.php new file mode 100644 index 000000000000..da082ba9590f --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateConnection/RoutingMode.php @@ -0,0 +1,65 @@ +google.cloud.vmwareengine.v1.PrivateConnection.RoutingMode + */ +class RoutingMode +{ + /** + * The default value. This value should never be used. + * + * Generated from protobuf enum ROUTING_MODE_UNSPECIFIED = 0; + */ + const ROUTING_MODE_UNSPECIFIED = 0; + /** + * Global Routing Mode + * + * Generated from protobuf enum GLOBAL = 1; + */ + const PBGLOBAL = 1; + /** + * Regional Routing Mode + * + * Generated from protobuf enum REGIONAL = 2; + */ + const REGIONAL = 2; + + private static $valueToName = [ + self::ROUTING_MODE_UNSPECIFIED => 'ROUTING_MODE_UNSPECIFIED', + self::PBGLOBAL => 'GLOBAL', + self::REGIONAL => 'REGIONAL', + ]; + + 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); + } +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateConnection/State.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateConnection/State.php new file mode 100644 index 000000000000..8a495a9ed4ee --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateConnection/State.php @@ -0,0 +1,90 @@ +google.cloud.vmwareengine.v1.PrivateConnection.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 private connection is being created. + * + * Generated from protobuf enum CREATING = 1; + */ + const CREATING = 1; + /** + * The private connection is ready. + * + * Generated from protobuf enum ACTIVE = 2; + */ + const ACTIVE = 2; + /** + * The private connection is being updated. + * + * Generated from protobuf enum UPDATING = 3; + */ + const UPDATING = 3; + /** + * The private connection is being deleted. + * + * Generated from protobuf enum DELETING = 4; + */ + const DELETING = 4; + /** + * The private connection is not provisioned, since no private cloud is + * present for which this private connection is needed. + * + * Generated from protobuf enum UNPROVISIONED = 5; + */ + const UNPROVISIONED = 5; + /** + * The private connection is in failed state. + * + * Generated from protobuf enum FAILED = 6; + */ + const FAILED = 6; + + private static $valueToName = [ + self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', + self::CREATING => 'CREATING', + self::ACTIVE => 'ACTIVE', + self::UPDATING => 'UPDATING', + self::DELETING => 'DELETING', + self::UNPROVISIONED => 'UNPROVISIONED', + 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); + } +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateConnection/Type.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateConnection/Type.php new file mode 100644 index 000000000000..f69dcc844e7a --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateConnection/Type.php @@ -0,0 +1,76 @@ +google.cloud.vmwareengine.v1.PrivateConnection.Type + */ +class Type +{ + /** + * The default value. This value should never be used. + * + * Generated from protobuf enum TYPE_UNSPECIFIED = 0; + */ + const TYPE_UNSPECIFIED = 0; + /** + * Connection used for establishing [private services + * access](https://cloud.google.com/vpc/docs/private-services-access). + * + * Generated from protobuf enum PRIVATE_SERVICE_ACCESS = 1; + */ + const PRIVATE_SERVICE_ACCESS = 1; + /** + * Connection used for connecting to NetApp Cloud Volumes. + * + * Generated from protobuf enum NETAPP_CLOUD_VOLUMES = 2; + */ + const NETAPP_CLOUD_VOLUMES = 2; + /** + * Connection used for connecting to Dell PowerScale. + * + * Generated from protobuf enum DELL_POWERSCALE = 3; + */ + const DELL_POWERSCALE = 3; + /** + * Connection used for connecting to third-party services. + * + * Generated from protobuf enum THIRD_PARTY_SERVICE = 4; + */ + const THIRD_PARTY_SERVICE = 4; + + private static $valueToName = [ + self::TYPE_UNSPECIFIED => 'TYPE_UNSPECIFIED', + self::PRIVATE_SERVICE_ACCESS => 'PRIVATE_SERVICE_ACCESS', + self::NETAPP_CLOUD_VOLUMES => 'NETAPP_CLOUD_VOLUMES', + self::DELL_POWERSCALE => 'DELL_POWERSCALE', + self::THIRD_PARTY_SERVICE => 'THIRD_PARTY_SERVICE', + ]; + + 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/RepairManagementDnsZoneBindingRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/RepairManagementDnsZoneBindingRequest.php new file mode 100644 index 000000000000..2ffb1f84dae5 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/RepairManagementDnsZoneBindingRequest.php @@ -0,0 +1,179 @@ +google.cloud.vmwareengine.v1.RepairManagementDnsZoneBindingRequest + */ +class RepairManagementDnsZoneBindingRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the management DNS zone binding to repair. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/managementDnsZoneBindings/my-management-dns-zone-binding` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 the 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 = ''; + + /** + * @param string $name Required. The resource name of the management DNS zone binding to repair. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/managementDnsZoneBindings/my-management-dns-zone-binding` + * Please see {@see VmwareEngineClient::managementDnsZoneBindingName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\RepairManagementDnsZoneBindingRequest + * + * @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 management DNS zone binding to repair. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/managementDnsZoneBindings/my-management-dns-zone-binding` + * @type string $request_id + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 the 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\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the management DNS zone binding to repair. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/managementDnsZoneBindings/my-management-dns-zone-binding` + * + * 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 management DNS zone binding to repair. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/managementDnsZoneBindings/my-management-dns-zone-binding` + * + * 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. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 the 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. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 the 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; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ResetNsxCredentialsRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ResetNsxCredentialsRequest.php new file mode 100644 index 000000000000..9b7312ac0f3b --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ResetNsxCredentialsRequest.php @@ -0,0 +1,185 @@ +google.cloud.vmwareengine.v1.ResetNsxCredentialsRequest + */ +class ResetNsxCredentialsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the private cloud + * to reset credentials for. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * Generated from protobuf field string private_cloud = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $private_cloud = ''; + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $request_id = ''; + + /** + * @param string $privateCloud Required. The resource name of the private cloud + * to reset credentials for. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * Please see {@see VmwareEngineClient::privateCloudName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\ResetNsxCredentialsRequest + * + * @experimental + */ + public static function build(string $privateCloud): self + { + return (new self()) + ->setPrivateCloud($privateCloud); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $private_cloud + * Required. The resource name of the private cloud + * to reset credentials for. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * @type string $request_id + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the private cloud + * to reset credentials for. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * Generated from protobuf field string private_cloud = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getPrivateCloud() + { + return $this->private_cloud; + } + + /** + * Required. The resource name of the private cloud + * to reset credentials for. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * Generated from protobuf field string private_cloud = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setPrivateCloud($var) + { + GPBUtil::checkString($var, True); + $this->private_cloud = $var; + + return $this; + } + + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getRequestId() + { + return $this->request_id; + } + + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 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; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ResetVcenterCredentialsRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ResetVcenterCredentialsRequest.php new file mode 100644 index 000000000000..6d297c139b99 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ResetVcenterCredentialsRequest.php @@ -0,0 +1,251 @@ +google.cloud.vmwareengine.v1.ResetVcenterCredentialsRequest + */ +class ResetVcenterCredentialsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the private cloud + * to reset credentials for. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * Generated from protobuf field string private_cloud = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $private_cloud = ''; + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $request_id = ''; + /** + * Optional. The username of the user to be to reset the credentials. + * The default value of this field is CloudOwner\@gve.local. + * The provided value should be one of the following: + * solution-user-01\@gve.local, + * solution-user-02\@gve.local, + * solution-user-03\@gve.local, + * solution-user-04\@gve.local, + * solution-user-05\@gve.local, + * zertoadmin\@gve.local. + * + * Generated from protobuf field string username = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $username = ''; + + /** + * @param string $privateCloud Required. The resource name of the private cloud + * to reset credentials for. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * Please see {@see VmwareEngineClient::privateCloudName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\ResetVcenterCredentialsRequest + * + * @experimental + */ + public static function build(string $privateCloud): self + { + return (new self()) + ->setPrivateCloud($privateCloud); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $private_cloud + * Required. The resource name of the private cloud + * to reset credentials for. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * @type string $request_id + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 string $username + * Optional. The username of the user to be to reset the credentials. + * The default value of this field is CloudOwner\@gve.local. + * The provided value should be one of the following: + * solution-user-01\@gve.local, + * solution-user-02\@gve.local, + * solution-user-03\@gve.local, + * solution-user-04\@gve.local, + * solution-user-05\@gve.local, + * zertoadmin\@gve.local. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the private cloud + * to reset credentials for. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * Generated from protobuf field string private_cloud = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getPrivateCloud() + { + return $this->private_cloud; + } + + /** + * Required. The resource name of the private cloud + * to reset credentials for. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * Generated from protobuf field string private_cloud = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setPrivateCloud($var) + { + GPBUtil::checkString($var, True); + $this->private_cloud = $var; + + return $this; + } + + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getRequestId() + { + return $this->request_id; + } + + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 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. The username of the user to be to reset the credentials. + * The default value of this field is CloudOwner\@gve.local. + * The provided value should be one of the following: + * solution-user-01\@gve.local, + * solution-user-02\@gve.local, + * solution-user-03\@gve.local, + * solution-user-04\@gve.local, + * solution-user-05\@gve.local, + * zertoadmin\@gve.local. + * + * Generated from protobuf field string username = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getUsername() + { + return $this->username; + } + + /** + * Optional. The username of the user to be to reset the credentials. + * The default value of this field is CloudOwner\@gve.local. + * The provided value should be one of the following: + * solution-user-01\@gve.local, + * solution-user-02\@gve.local, + * solution-user-03\@gve.local, + * solution-user-04\@gve.local, + * solution-user-05\@gve.local, + * zertoadmin\@gve.local. + * + * Generated from protobuf field string username = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @param string $var + * @return $this + */ + public function setUsername($var) + { + GPBUtil::checkString($var, True); + $this->username = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/RevokeDnsBindPermissionRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/RevokeDnsBindPermissionRequest.php new file mode 100644 index 000000000000..17821053a5d5 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/RevokeDnsBindPermissionRequest.php @@ -0,0 +1,241 @@ +google.cloud.vmwareengine.v1.RevokeDnsBindPermissionRequest + */ +class RevokeDnsBindPermissionRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The name of the resource which stores the users/service accounts + * having the permission to bind to the corresponding intranet VPC of the + * consumer project. DnsBindPermission is a global resource. Resource names + * are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. For example: + * `projects/my-project/locations/global/dnsBindPermission` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * Required. The consumer provided user/service account which needs to be + * granted permission to bind with the intranet VPC corresponding to the + * consumer project. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.Principal principal = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $principal = null; + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $request_id = ''; + + /** + * @param string $name Required. The name of the resource which stores the users/service accounts + * having the permission to bind to the corresponding intranet VPC of the + * consumer project. DnsBindPermission is a global resource. Resource names + * are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. For example: + * `projects/my-project/locations/global/dnsBindPermission` + * Please see {@see VmwareEngineClient::dnsBindPermissionName()} for help formatting this field. + * @param \Google\Cloud\VmwareEngine\V1\Principal $principal Required. The consumer provided user/service account which needs to be + * granted permission to bind with the intranet VPC corresponding to the + * consumer project. + * + * @return \Google\Cloud\VmwareEngine\V1\RevokeDnsBindPermissionRequest + * + * @experimental + */ + public static function build(string $name, \Google\Cloud\VmwareEngine\V1\Principal $principal): self + { + return (new self()) + ->setName($name) + ->setPrincipal($principal); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. The name of the resource which stores the users/service accounts + * having the permission to bind to the corresponding intranet VPC of the + * consumer project. DnsBindPermission is a global resource. Resource names + * are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. For example: + * `projects/my-project/locations/global/dnsBindPermission` + * @type \Google\Cloud\VmwareEngine\V1\Principal $principal + * Required. The consumer provided user/service account which needs to be + * granted permission to bind with the intranet VPC corresponding to the + * consumer project. + * @type string $request_id + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The name of the resource which stores the users/service accounts + * having the permission to bind to the corresponding intranet VPC of the + * consumer project. DnsBindPermission is a global resource. Resource names + * are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. For example: + * `projects/my-project/locations/global/dnsBindPermission` + * + * 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 resource which stores the users/service accounts + * having the permission to bind to the corresponding intranet VPC of the + * consumer project. DnsBindPermission is a global resource. Resource names + * are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. For example: + * `projects/my-project/locations/global/dnsBindPermission` + * + * 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 consumer provided user/service account which needs to be + * granted permission to bind with the intranet VPC corresponding to the + * consumer project. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.Principal principal = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\VmwareEngine\V1\Principal|null + */ + public function getPrincipal() + { + return $this->principal; + } + + public function hasPrincipal() + { + return isset($this->principal); + } + + public function clearPrincipal() + { + unset($this->principal); + } + + /** + * Required. The consumer provided user/service account which needs to be + * granted permission to bind with the intranet VPC corresponding to the + * consumer project. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.Principal principal = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\VmwareEngine\V1\Principal $var + * @return $this + */ + public function setPrincipal($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\Principal::class); + $this->principal = $var; + + return $this; + } + + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getRequestId() + { + return $this->request_id; + } + + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 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; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ShowNsxCredentialsRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ShowNsxCredentialsRequest.php new file mode 100644 index 000000000000..9b21d7406f66 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ShowNsxCredentialsRequest.php @@ -0,0 +1,107 @@ +google.cloud.vmwareengine.v1.ShowNsxCredentialsRequest + */ +class ShowNsxCredentialsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the private cloud + * to be queried for credentials. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * Generated from protobuf field string private_cloud = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $private_cloud = ''; + + /** + * @param string $privateCloud Required. The resource name of the private cloud + * to be queried for credentials. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * Please see {@see VmwareEngineClient::privateCloudName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\ShowNsxCredentialsRequest + * + * @experimental + */ + public static function build(string $privateCloud): self + { + return (new self()) + ->setPrivateCloud($privateCloud); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $private_cloud + * Required. The resource name of the private cloud + * to be queried for credentials. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the private cloud + * to be queried for credentials. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * Generated from protobuf field string private_cloud = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getPrivateCloud() + { + return $this->private_cloud; + } + + /** + * Required. The resource name of the private cloud + * to be queried for credentials. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * Generated from protobuf field string private_cloud = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setPrivateCloud($var) + { + GPBUtil::checkString($var, True); + $this->private_cloud = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ShowVcenterCredentialsRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ShowVcenterCredentialsRequest.php new file mode 100644 index 000000000000..2ad8e46ca47c --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ShowVcenterCredentialsRequest.php @@ -0,0 +1,177 @@ +google.cloud.vmwareengine.v1.ShowVcenterCredentialsRequest + */ +class ShowVcenterCredentialsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the private cloud + * to be queried for credentials. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * Generated from protobuf field string private_cloud = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $private_cloud = ''; + /** + * Optional. The username of the user to be queried for credentials. + * The default value of this field is CloudOwner\@gve.local. + * The provided value must be one of the following: + * CloudOwner\@gve.local, + * solution-user-01\@gve.local, + * solution-user-02\@gve.local, + * solution-user-03\@gve.local, + * solution-user-04\@gve.local, + * solution-user-05\@gve.local, + * zertoadmin\@gve.local. + * + * Generated from protobuf field string username = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $username = ''; + + /** + * @param string $privateCloud Required. The resource name of the private cloud + * to be queried for credentials. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * Please see {@see VmwareEngineClient::privateCloudName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\ShowVcenterCredentialsRequest + * + * @experimental + */ + public static function build(string $privateCloud): self + { + return (new self()) + ->setPrivateCloud($privateCloud); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $private_cloud + * Required. The resource name of the private cloud + * to be queried for credentials. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * @type string $username + * Optional. The username of the user to be queried for credentials. + * The default value of this field is CloudOwner\@gve.local. + * The provided value must be one of the following: + * CloudOwner\@gve.local, + * solution-user-01\@gve.local, + * solution-user-02\@gve.local, + * solution-user-03\@gve.local, + * solution-user-04\@gve.local, + * solution-user-05\@gve.local, + * zertoadmin\@gve.local. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the private cloud + * to be queried for credentials. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * Generated from protobuf field string private_cloud = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getPrivateCloud() + { + return $this->private_cloud; + } + + /** + * Required. The resource name of the private cloud + * to be queried for credentials. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * Generated from protobuf field string private_cloud = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setPrivateCloud($var) + { + GPBUtil::checkString($var, True); + $this->private_cloud = $var; + + return $this; + } + + /** + * Optional. The username of the user to be queried for credentials. + * The default value of this field is CloudOwner\@gve.local. + * The provided value must be one of the following: + * CloudOwner\@gve.local, + * solution-user-01\@gve.local, + * solution-user-02\@gve.local, + * solution-user-03\@gve.local, + * solution-user-04\@gve.local, + * solution-user-05\@gve.local, + * zertoadmin\@gve.local. + * + * Generated from protobuf field string username = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getUsername() + { + return $this->username; + } + + /** + * Optional. The username of the user to be queried for credentials. + * The default value of this field is CloudOwner\@gve.local. + * The provided value must be one of the following: + * CloudOwner\@gve.local, + * solution-user-01\@gve.local, + * solution-user-02\@gve.local, + * solution-user-03\@gve.local, + * solution-user-04\@gve.local, + * solution-user-05\@gve.local, + * zertoadmin\@gve.local. + * + * Generated from protobuf field string username = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @param string $var + * @return $this + */ + public function setUsername($var) + { + GPBUtil::checkString($var, True); + $this->username = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/StretchedClusterConfig.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/StretchedClusterConfig.php new file mode 100644 index 000000000000..088a2fdc96c8 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/StretchedClusterConfig.php @@ -0,0 +1,133 @@ +google.cloud.vmwareengine.v1.StretchedClusterConfig + */ +class StretchedClusterConfig extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Zone that will remain operational when connection between the two + * zones is lost. Specify the resource name of a zone that belongs to the + * region of the private cloud. For example: + * `projects/{project}/locations/europe-west3-a` where `{project}` can either + * be a project number or a project ID. + * + * Generated from protobuf field string preferred_location = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $preferred_location = ''; + /** + * Required. Additional zone for a higher level of availability and load + * balancing. Specify the resource name of a zone that belongs to the region + * of the private cloud. For example: + * `projects/{project}/locations/europe-west3-b` where `{project}` can either + * be a project number or a project ID. + * + * Generated from protobuf field string secondary_location = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $secondary_location = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $preferred_location + * Required. Zone that will remain operational when connection between the two + * zones is lost. Specify the resource name of a zone that belongs to the + * region of the private cloud. For example: + * `projects/{project}/locations/europe-west3-a` where `{project}` can either + * be a project number or a project ID. + * @type string $secondary_location + * Required. Additional zone for a higher level of availability and load + * balancing. Specify the resource name of a zone that belongs to the region + * of the private cloud. For example: + * `projects/{project}/locations/europe-west3-b` where `{project}` can either + * be a project number or a project ID. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); + parent::__construct($data); + } + + /** + * Required. Zone that will remain operational when connection between the two + * zones is lost. Specify the resource name of a zone that belongs to the + * region of the private cloud. For example: + * `projects/{project}/locations/europe-west3-a` where `{project}` can either + * be a project number or a project ID. + * + * Generated from protobuf field string preferred_location = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getPreferredLocation() + { + return $this->preferred_location; + } + + /** + * Required. Zone that will remain operational when connection between the two + * zones is lost. Specify the resource name of a zone that belongs to the + * region of the private cloud. For example: + * `projects/{project}/locations/europe-west3-a` where `{project}` can either + * be a project number or a project ID. + * + * Generated from protobuf field string preferred_location = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setPreferredLocation($var) + { + GPBUtil::checkString($var, True); + $this->preferred_location = $var; + + return $this; + } + + /** + * Required. Additional zone for a higher level of availability and load + * balancing. Specify the resource name of a zone that belongs to the region + * of the private cloud. For example: + * `projects/{project}/locations/europe-west3-b` where `{project}` can either + * be a project number or a project ID. + * + * Generated from protobuf field string secondary_location = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @return string + */ + public function getSecondaryLocation() + { + return $this->secondary_location; + } + + /** + * Required. Additional zone for a higher level of availability and load + * balancing. Specify the resource name of a zone that belongs to the region + * of the private cloud. For example: + * `projects/{project}/locations/europe-west3-b` where `{project}` can either + * be a project number or a project ID. + * + * Generated from protobuf field string secondary_location = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setSecondaryLocation($var) + { + GPBUtil::checkString($var, True); + $this->secondary_location = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Subnet.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Subnet.php new file mode 100644 index 000000000000..3a48feaa3a0f --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Subnet.php @@ -0,0 +1,262 @@ +google.cloud.vmwareengine.v1.Subnet + */ +class Subnet extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. The resource name of this subnet. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/subnets/my-subnet` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $name = ''; + /** + * The IP address range of the subnet in CIDR format '10.0.0.0/24'. + * + * Generated from protobuf field string ip_cidr_range = 7; + */ + protected $ip_cidr_range = ''; + /** + * The IP address of the gateway of this subnet. + * Must fall within the IP prefix defined above. + * + * Generated from protobuf field string gateway_ip = 8; + */ + protected $gateway_ip = ''; + /** + * Output only. The type of the subnet. For example "management" or + * "userDefined". + * + * Generated from protobuf field string type = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $type = ''; + /** + * Output only. The state of the resource. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.Subnet.State state = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $state = 0; + /** + * Output only. VLAN ID of the VLAN on which the subnet is configured + * + * Generated from protobuf field int32 vlan_id = 16 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $vlan_id = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Output only. The resource name of this subnet. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/subnets/my-subnet` + * @type string $ip_cidr_range + * The IP address range of the subnet in CIDR format '10.0.0.0/24'. + * @type string $gateway_ip + * The IP address of the gateway of this subnet. + * Must fall within the IP prefix defined above. + * @type string $type + * Output only. The type of the subnet. For example "management" or + * "userDefined". + * @type int $state + * Output only. The state of the resource. + * @type int $vlan_id + * Output only. VLAN ID of the VLAN on which the subnet is configured + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); + parent::__construct($data); + } + + /** + * Output only. The resource name of this subnet. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/subnets/my-subnet` + * + * 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 subnet. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/subnets/my-subnet` + * + * 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; + } + + /** + * The IP address range of the subnet in CIDR format '10.0.0.0/24'. + * + * Generated from protobuf field string ip_cidr_range = 7; + * @return string + */ + public function getIpCidrRange() + { + return $this->ip_cidr_range; + } + + /** + * The IP address range of the subnet in CIDR format '10.0.0.0/24'. + * + * Generated from protobuf field string ip_cidr_range = 7; + * @param string $var + * @return $this + */ + public function setIpCidrRange($var) + { + GPBUtil::checkString($var, True); + $this->ip_cidr_range = $var; + + return $this; + } + + /** + * The IP address of the gateway of this subnet. + * Must fall within the IP prefix defined above. + * + * Generated from protobuf field string gateway_ip = 8; + * @return string + */ + public function getGatewayIp() + { + return $this->gateway_ip; + } + + /** + * The IP address of the gateway of this subnet. + * Must fall within the IP prefix defined above. + * + * Generated from protobuf field string gateway_ip = 8; + * @param string $var + * @return $this + */ + public function setGatewayIp($var) + { + GPBUtil::checkString($var, True); + $this->gateway_ip = $var; + + return $this; + } + + /** + * Output only. The type of the subnet. For example "management" or + * "userDefined". + * + * Generated from protobuf field string type = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getType() + { + return $this->type; + } + + /** + * Output only. The type of the subnet. For example "management" or + * "userDefined". + * + * Generated from protobuf field string type = 11 [(.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. The state of the resource. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.Subnet.State state = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getState() + { + return $this->state; + } + + /** + * Output only. The state of the resource. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.Subnet.State state = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setState($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\Subnet\State::class); + $this->state = $var; + + return $this; + } + + /** + * Output only. VLAN ID of the VLAN on which the subnet is configured + * + * Generated from protobuf field int32 vlan_id = 16 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getVlanId() + { + return $this->vlan_id; + } + + /** + * Output only. VLAN ID of the VLAN on which the subnet is configured + * + * Generated from protobuf field int32 vlan_id = 16 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setVlanId($var) + { + GPBUtil::checkInt32($var); + $this->vlan_id = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Subnet/State.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Subnet/State.php new file mode 100644 index 000000000000..92cf3e454561 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Subnet/State.php @@ -0,0 +1,90 @@ +google.cloud.vmwareengine.v1.Subnet.State + */ +class State +{ + /** + * The default value. This value should never be used. + * + * Generated from protobuf enum STATE_UNSPECIFIED = 0; + */ + const STATE_UNSPECIFIED = 0; + /** + * The subnet is ready. + * + * Generated from protobuf enum ACTIVE = 1; + */ + const ACTIVE = 1; + /** + * The subnet is being created. + * + * Generated from protobuf enum CREATING = 2; + */ + const CREATING = 2; + /** + * The subnet is being updated. + * + * Generated from protobuf enum UPDATING = 3; + */ + const UPDATING = 3; + /** + * The subnet is being deleted. + * + * Generated from protobuf enum DELETING = 4; + */ + const DELETING = 4; + /** + * Changes requested in the last operation are being propagated. + * + * Generated from protobuf enum RECONCILING = 5; + */ + const RECONCILING = 5; + /** + * Last operation on the subnet did not succeed. Subnet's payload is + * reverted back to its most recent working state. + * + * Generated from protobuf enum FAILED = 6; + */ + const FAILED = 6; + + private static $valueToName = [ + self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', + self::ACTIVE => 'ACTIVE', + self::CREATING => 'CREATING', + self::UPDATING => 'UPDATING', + self::DELETING => 'DELETING', + self::RECONCILING => 'RECONCILING', + 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); + } +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UndeletePrivateCloudRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UndeletePrivateCloudRequest.php new file mode 100644 index 000000000000..f4704b080b50 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UndeletePrivateCloudRequest.php @@ -0,0 +1,140 @@ +google.cloud.vmwareengine.v1.UndeletePrivateCloudRequest + */ +class UndeletePrivateCloudRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the private cloud scheduled for deletion. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * Optional. 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 = ''; + + /** + * @param string $name Required. The resource name of the private cloud scheduled for deletion. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * Please see {@see VmwareEngineClient::privateCloudName()} for help formatting this field. + * + * @return \Google\Cloud\VmwareEngine\V1\UndeletePrivateCloudRequest + * + * @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 private cloud scheduled for deletion. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * @type string $request_id + * Optional. 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\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the private cloud scheduled for deletion. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * 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 private cloud scheduled for deletion. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` + * + * 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 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. 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; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateClusterRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateClusterRequest.php new file mode 100644 index 000000000000..b11ad2d64297 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateClusterRequest.php @@ -0,0 +1,233 @@ +google.cloud.vmwareengine.v1.UpdateClusterRequest + */ +class UpdateClusterRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Field mask is used to specify the fields to be overwritten in the + * `Cluster` resource by the update. The fields specified in the `updateMask` + * 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. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $update_mask = null; + /** + * Required. The description of the cluster. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.Cluster cluster = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $cluster = null; + /** + * Optional. 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. True if you want the request to be validated and not executed; + * false otherwise. + * + * Generated from protobuf field bool validate_only = 4 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $validate_only = false; + + /** + * @param \Google\Cloud\VmwareEngine\V1\Cluster $cluster Required. The description of the cluster. + * @param \Google\Protobuf\FieldMask $updateMask Required. Field mask is used to specify the fields to be overwritten in the + * `Cluster` resource by the update. The fields specified in the `updateMask` + * 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. + * + * @return \Google\Cloud\VmwareEngine\V1\UpdateClusterRequest + * + * @experimental + */ + public static function build(\Google\Cloud\VmwareEngine\V1\Cluster $cluster, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setCluster($cluster) + ->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 + * `Cluster` resource by the update. The fields specified in the `updateMask` + * 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. + * @type \Google\Cloud\VmwareEngine\V1\Cluster $cluster + * Required. The description of the cluster. + * @type string $request_id + * Optional. 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. True if you want the request to be validated and not executed; + * false otherwise. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. Field mask is used to specify the fields to be overwritten in the + * `Cluster` resource by the update. The fields specified in the `updateMask` + * 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. + * + * 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 + * `Cluster` resource by the update. The fields specified in the `updateMask` + * 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. + * + * 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 description of the cluster. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.Cluster cluster = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\VmwareEngine\V1\Cluster|null + */ + public function getCluster() + { + return $this->cluster; + } + + public function hasCluster() + { + return isset($this->cluster); + } + + public function clearCluster() + { + unset($this->cluster); + } + + /** + * Required. The description of the cluster. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.Cluster cluster = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\VmwareEngine\V1\Cluster $var + * @return $this + */ + public function setCluster($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\Cluster::class); + $this->cluster = $var; + + return $this; + } + + /** + * Optional. 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. 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. True if you want the request to be validated and not executed; + * false otherwise. + * + * Generated from protobuf field bool validate_only = 4 [(.google.api.field_behavior) = OPTIONAL]; + * @return bool + */ + public function getValidateOnly() + { + return $this->validate_only; + } + + /** + * Optional. True if you want the request to be validated and not executed; + * false otherwise. + * + * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateDnsForwardingRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateDnsForwardingRequest.php new file mode 100644 index 000000000000..1087a4cf67d4 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateDnsForwardingRequest.php @@ -0,0 +1,235 @@ +google.cloud.vmwareengine.v1.UpdateDnsForwardingRequest + */ +class UpdateDnsForwardingRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. DnsForwarding config details. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.DnsForwarding dns_forwarding = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $dns_forwarding = null; + /** + * Required. Field mask is used to specify the fields to be overwritten in the + * `DnsForwarding` 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. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $update_mask = null; + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $request_id = ''; + + /** + * @param \Google\Cloud\VmwareEngine\V1\DnsForwarding $dnsForwarding Required. DnsForwarding config details. + * @param \Google\Protobuf\FieldMask $updateMask Required. Field mask is used to specify the fields to be overwritten in the + * `DnsForwarding` 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. + * + * @return \Google\Cloud\VmwareEngine\V1\UpdateDnsForwardingRequest + * + * @experimental + */ + public static function build(\Google\Cloud\VmwareEngine\V1\DnsForwarding $dnsForwarding, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setDnsForwarding($dnsForwarding) + ->setUpdateMask($updateMask); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\VmwareEngine\V1\DnsForwarding $dns_forwarding + * Required. DnsForwarding config details. + * @type \Google\Protobuf\FieldMask $update_mask + * Required. Field mask is used to specify the fields to be overwritten in the + * `DnsForwarding` 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. + * @type string $request_id + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. DnsForwarding config details. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.DnsForwarding dns_forwarding = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\VmwareEngine\V1\DnsForwarding|null + */ + public function getDnsForwarding() + { + return $this->dns_forwarding; + } + + public function hasDnsForwarding() + { + return isset($this->dns_forwarding); + } + + public function clearDnsForwarding() + { + unset($this->dns_forwarding); + } + + /** + * Required. DnsForwarding config details. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.DnsForwarding dns_forwarding = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\VmwareEngine\V1\DnsForwarding $var + * @return $this + */ + public function setDnsForwarding($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\DnsForwarding::class); + $this->dns_forwarding = $var; + + return $this; + } + + /** + * Required. Field mask is used to specify the fields to be overwritten in the + * `DnsForwarding` 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. + * + * 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. Field mask is used to specify the fields to be overwritten in the + * `DnsForwarding` 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. + * + * 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; + } + + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getRequestId() + { + return $this->request_id; + } + + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 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; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateExternalAccessRuleRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateExternalAccessRuleRequest.php new file mode 100644 index 000000000000..15daf8db744c --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateExternalAccessRuleRequest.php @@ -0,0 +1,235 @@ +google.cloud.vmwareengine.v1.UpdateExternalAccessRuleRequest + */ +class UpdateExternalAccessRuleRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Field mask is used to specify the fields to be overwritten in the + * `ExternalAccessRule` 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. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $update_mask = null; + /** + * Required. Description of the external access rule. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.ExternalAccessRule external_access_rule = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $external_access_rule = null; + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 the 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 = ''; + + /** + * @param \Google\Cloud\VmwareEngine\V1\ExternalAccessRule $externalAccessRule Required. Description of the external access rule. + * @param \Google\Protobuf\FieldMask $updateMask Required. Field mask is used to specify the fields to be overwritten in the + * `ExternalAccessRule` 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. + * + * @return \Google\Cloud\VmwareEngine\V1\UpdateExternalAccessRuleRequest + * + * @experimental + */ + public static function build(\Google\Cloud\VmwareEngine\V1\ExternalAccessRule $externalAccessRule, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setExternalAccessRule($externalAccessRule) + ->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 + * `ExternalAccessRule` 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. + * @type \Google\Cloud\VmwareEngine\V1\ExternalAccessRule $external_access_rule + * Required. Description of the external access rule. + * @type string $request_id + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 the 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\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. Field mask is used to specify the fields to be overwritten in the + * `ExternalAccessRule` 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. + * + * 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 + * `ExternalAccessRule` 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. + * + * 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. Description of the external access rule. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.ExternalAccessRule external_access_rule = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\VmwareEngine\V1\ExternalAccessRule|null + */ + public function getExternalAccessRule() + { + return $this->external_access_rule; + } + + public function hasExternalAccessRule() + { + return isset($this->external_access_rule); + } + + public function clearExternalAccessRule() + { + unset($this->external_access_rule); + } + + /** + * Required. Description of the external access rule. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.ExternalAccessRule external_access_rule = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\VmwareEngine\V1\ExternalAccessRule $var + * @return $this + */ + public function setExternalAccessRule($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\ExternalAccessRule::class); + $this->external_access_rule = $var; + + return $this; + } + + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 the 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. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 the 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; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateExternalAddressRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateExternalAddressRequest.php new file mode 100644 index 000000000000..3d42ce8e05b7 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateExternalAddressRequest.php @@ -0,0 +1,235 @@ +google.cloud.vmwareengine.v1.UpdateExternalAddressRequest + */ +class UpdateExternalAddressRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Field mask is used to specify the fields to be overwritten in the + * `ExternalAddress` 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. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $update_mask = null; + /** + * Required. External IP address description. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.ExternalAddress external_address = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $external_address = null; + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 the 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 = ''; + + /** + * @param \Google\Cloud\VmwareEngine\V1\ExternalAddress $externalAddress Required. External IP address description. + * @param \Google\Protobuf\FieldMask $updateMask Required. Field mask is used to specify the fields to be overwritten in the + * `ExternalAddress` 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. + * + * @return \Google\Cloud\VmwareEngine\V1\UpdateExternalAddressRequest + * + * @experimental + */ + public static function build(\Google\Cloud\VmwareEngine\V1\ExternalAddress $externalAddress, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setExternalAddress($externalAddress) + ->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 + * `ExternalAddress` 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. + * @type \Google\Cloud\VmwareEngine\V1\ExternalAddress $external_address + * Required. External IP address description. + * @type string $request_id + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 the 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\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. Field mask is used to specify the fields to be overwritten in the + * `ExternalAddress` 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. + * + * 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 + * `ExternalAddress` 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. + * + * 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. External IP address description. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.ExternalAddress external_address = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\VmwareEngine\V1\ExternalAddress|null + */ + public function getExternalAddress() + { + return $this->external_address; + } + + public function hasExternalAddress() + { + return isset($this->external_address); + } + + public function clearExternalAddress() + { + unset($this->external_address); + } + + /** + * Required. External IP address description. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.ExternalAddress external_address = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\VmwareEngine\V1\ExternalAddress $var + * @return $this + */ + public function setExternalAddress($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\ExternalAddress::class); + $this->external_address = $var; + + return $this; + } + + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 the 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. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 the 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; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateLoggingServerRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateLoggingServerRequest.php new file mode 100644 index 000000000000..4e9feaa73fbd --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateLoggingServerRequest.php @@ -0,0 +1,235 @@ +google.cloud.vmwareengine.v1.UpdateLoggingServerRequest + */ +class UpdateLoggingServerRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Field mask is used to specify the fields to be overwritten in the + * `LoggingServer` 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. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $update_mask = null; + /** + * Required. Logging server description. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.LoggingServer logging_server = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $logging_server = null; + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $request_id = ''; + + /** + * @param \Google\Cloud\VmwareEngine\V1\LoggingServer $loggingServer Required. Logging server description. + * @param \Google\Protobuf\FieldMask $updateMask Required. Field mask is used to specify the fields to be overwritten in the + * `LoggingServer` 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. + * + * @return \Google\Cloud\VmwareEngine\V1\UpdateLoggingServerRequest + * + * @experimental + */ + public static function build(\Google\Cloud\VmwareEngine\V1\LoggingServer $loggingServer, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setLoggingServer($loggingServer) + ->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 + * `LoggingServer` 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. + * @type \Google\Cloud\VmwareEngine\V1\LoggingServer $logging_server + * Required. Logging server description. + * @type string $request_id + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. Field mask is used to specify the fields to be overwritten in the + * `LoggingServer` 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. + * + * 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 + * `LoggingServer` 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. + * + * 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. Logging server description. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.LoggingServer logging_server = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\VmwareEngine\V1\LoggingServer|null + */ + public function getLoggingServer() + { + return $this->logging_server; + } + + public function hasLoggingServer() + { + return isset($this->logging_server); + } + + public function clearLoggingServer() + { + unset($this->logging_server); + } + + /** + * Required. Logging server description. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.LoggingServer logging_server = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\VmwareEngine\V1\LoggingServer $var + * @return $this + */ + public function setLoggingServer($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\LoggingServer::class); + $this->logging_server = $var; + + return $this; + } + + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getRequestId() + { + return $this->request_id; + } + + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 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; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateManagementDnsZoneBindingRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateManagementDnsZoneBindingRequest.php new file mode 100644 index 000000000000..d2b66cf147ea --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateManagementDnsZoneBindingRequest.php @@ -0,0 +1,235 @@ +google.cloud.vmwareengine.v1.UpdateManagementDnsZoneBindingRequest + */ +class UpdateManagementDnsZoneBindingRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Field mask is used to specify the fields to be overwritten in the + * `ManagementDnsZoneBinding` 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. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $update_mask = null; + /** + * Required. New values to update the management DNS zone binding with. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.ManagementDnsZoneBinding management_dns_zone_binding = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $management_dns_zone_binding = null; + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 the 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 = ''; + + /** + * @param \Google\Cloud\VmwareEngine\V1\ManagementDnsZoneBinding $managementDnsZoneBinding Required. New values to update the management DNS zone binding with. + * @param \Google\Protobuf\FieldMask $updateMask Required. Field mask is used to specify the fields to be overwritten in the + * `ManagementDnsZoneBinding` 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. + * + * @return \Google\Cloud\VmwareEngine\V1\UpdateManagementDnsZoneBindingRequest + * + * @experimental + */ + public static function build(\Google\Cloud\VmwareEngine\V1\ManagementDnsZoneBinding $managementDnsZoneBinding, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setManagementDnsZoneBinding($managementDnsZoneBinding) + ->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 + * `ManagementDnsZoneBinding` 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. + * @type \Google\Cloud\VmwareEngine\V1\ManagementDnsZoneBinding $management_dns_zone_binding + * Required. New values to update the management DNS zone binding with. + * @type string $request_id + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 the 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\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. Field mask is used to specify the fields to be overwritten in the + * `ManagementDnsZoneBinding` 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. + * + * 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 + * `ManagementDnsZoneBinding` 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. + * + * 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. New values to update the management DNS zone binding with. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.ManagementDnsZoneBinding management_dns_zone_binding = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\VmwareEngine\V1\ManagementDnsZoneBinding|null + */ + public function getManagementDnsZoneBinding() + { + return $this->management_dns_zone_binding; + } + + public function hasManagementDnsZoneBinding() + { + return isset($this->management_dns_zone_binding); + } + + public function clearManagementDnsZoneBinding() + { + unset($this->management_dns_zone_binding); + } + + /** + * Required. New values to update the management DNS zone binding with. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.ManagementDnsZoneBinding management_dns_zone_binding = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\VmwareEngine\V1\ManagementDnsZoneBinding $var + * @return $this + */ + public function setManagementDnsZoneBinding($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\ManagementDnsZoneBinding::class); + $this->management_dns_zone_binding = $var; + + return $this; + } + + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 the 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. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 the 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; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateNetworkPeeringRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateNetworkPeeringRequest.php new file mode 100644 index 000000000000..642bed6a5167 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateNetworkPeeringRequest.php @@ -0,0 +1,235 @@ +google.cloud.vmwareengine.v1.UpdateNetworkPeeringRequest + */ +class UpdateNetworkPeeringRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Network peering description. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPeering network_peering = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $network_peering = null; + /** + * Required. Field mask is used to specify the fields to be overwritten in the + * `NetworkPeering` 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. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $update_mask = null; + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $request_id = ''; + + /** + * @param \Google\Cloud\VmwareEngine\V1\NetworkPeering $networkPeering Required. Network peering description. + * @param \Google\Protobuf\FieldMask $updateMask Required. Field mask is used to specify the fields to be overwritten in the + * `NetworkPeering` 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. + * + * @return \Google\Cloud\VmwareEngine\V1\UpdateNetworkPeeringRequest + * + * @experimental + */ + public static function build(\Google\Cloud\VmwareEngine\V1\NetworkPeering $networkPeering, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setNetworkPeering($networkPeering) + ->setUpdateMask($updateMask); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\VmwareEngine\V1\NetworkPeering $network_peering + * Required. Network peering description. + * @type \Google\Protobuf\FieldMask $update_mask + * Required. Field mask is used to specify the fields to be overwritten in the + * `NetworkPeering` 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. + * @type string $request_id + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. Network peering description. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPeering network_peering = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\VmwareEngine\V1\NetworkPeering|null + */ + public function getNetworkPeering() + { + return $this->network_peering; + } + + public function hasNetworkPeering() + { + return isset($this->network_peering); + } + + public function clearNetworkPeering() + { + unset($this->network_peering); + } + + /** + * Required. Network peering description. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPeering network_peering = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\VmwareEngine\V1\NetworkPeering $var + * @return $this + */ + public function setNetworkPeering($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\NetworkPeering::class); + $this->network_peering = $var; + + return $this; + } + + /** + * Required. Field mask is used to specify the fields to be overwritten in the + * `NetworkPeering` 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. + * + * 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. Field mask is used to specify the fields to be overwritten in the + * `NetworkPeering` 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. + * + * 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; + } + + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getRequestId() + { + return $this->request_id; + } + + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 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; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateNetworkPolicyRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateNetworkPolicyRequest.php new file mode 100644 index 000000000000..2ec762dc531e --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateNetworkPolicyRequest.php @@ -0,0 +1,235 @@ +google.cloud.vmwareengine.v1.UpdateNetworkPolicyRequest + */ +class UpdateNetworkPolicyRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Network policy description. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPolicy network_policy = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $network_policy = null; + /** + * Required. Field mask is used to specify the fields to be overwritten in the + * `NetworkPolicy` 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. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $update_mask = null; + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $request_id = ''; + + /** + * @param \Google\Cloud\VmwareEngine\V1\NetworkPolicy $networkPolicy Required. Network policy description. + * @param \Google\Protobuf\FieldMask $updateMask Required. Field mask is used to specify the fields to be overwritten in the + * `NetworkPolicy` 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. + * + * @return \Google\Cloud\VmwareEngine\V1\UpdateNetworkPolicyRequest + * + * @experimental + */ + public static function build(\Google\Cloud\VmwareEngine\V1\NetworkPolicy $networkPolicy, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setNetworkPolicy($networkPolicy) + ->setUpdateMask($updateMask); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\VmwareEngine\V1\NetworkPolicy $network_policy + * Required. Network policy description. + * @type \Google\Protobuf\FieldMask $update_mask + * Required. Field mask is used to specify the fields to be overwritten in the + * `NetworkPolicy` 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. + * @type string $request_id + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. Network policy description. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPolicy network_policy = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\VmwareEngine\V1\NetworkPolicy|null + */ + public function getNetworkPolicy() + { + return $this->network_policy; + } + + public function hasNetworkPolicy() + { + return isset($this->network_policy); + } + + public function clearNetworkPolicy() + { + unset($this->network_policy); + } + + /** + * Required. Network policy description. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPolicy network_policy = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\VmwareEngine\V1\NetworkPolicy $var + * @return $this + */ + public function setNetworkPolicy($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\NetworkPolicy::class); + $this->network_policy = $var; + + return $this; + } + + /** + * Required. Field mask is used to specify the fields to be overwritten in the + * `NetworkPolicy` 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. + * + * 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. Field mask is used to specify the fields to be overwritten in the + * `NetworkPolicy` 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. + * + * 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; + } + + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getRequestId() + { + return $this->request_id; + } + + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 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; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdatePrivateCloudRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdatePrivateCloudRequest.php new file mode 100644 index 000000000000..0304fc6978ce --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdatePrivateCloudRequest.php @@ -0,0 +1,195 @@ +google.cloud.vmwareengine.v1.UpdatePrivateCloudRequest + */ +class UpdatePrivateCloudRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Private cloud description. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateCloud private_cloud = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $private_cloud = null; + /** + * Required. Field mask is used to specify the fields to be overwritten in the + * `PrivateCloud` resource by the update. The fields specified in `updateMask` + * 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. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $update_mask = null; + /** + * Optional. 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 = ''; + + /** + * @param \Google\Cloud\VmwareEngine\V1\PrivateCloud $privateCloud Required. Private cloud description. + * @param \Google\Protobuf\FieldMask $updateMask Required. Field mask is used to specify the fields to be overwritten in the + * `PrivateCloud` resource by the update. The fields specified in `updateMask` + * 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. + * + * @return \Google\Cloud\VmwareEngine\V1\UpdatePrivateCloudRequest + * + * @experimental + */ + public static function build(\Google\Cloud\VmwareEngine\V1\PrivateCloud $privateCloud, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setPrivateCloud($privateCloud) + ->setUpdateMask($updateMask); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\VmwareEngine\V1\PrivateCloud $private_cloud + * Required. Private cloud description. + * @type \Google\Protobuf\FieldMask $update_mask + * Required. Field mask is used to specify the fields to be overwritten in the + * `PrivateCloud` resource by the update. The fields specified in `updateMask` + * 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. + * @type string $request_id + * Optional. 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\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. Private cloud description. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateCloud private_cloud = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\VmwareEngine\V1\PrivateCloud|null + */ + public function getPrivateCloud() + { + return $this->private_cloud; + } + + public function hasPrivateCloud() + { + return isset($this->private_cloud); + } + + public function clearPrivateCloud() + { + unset($this->private_cloud); + } + + /** + * Required. Private cloud description. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateCloud private_cloud = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\VmwareEngine\V1\PrivateCloud $var + * @return $this + */ + public function setPrivateCloud($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\PrivateCloud::class); + $this->private_cloud = $var; + + return $this; + } + + /** + * Required. Field mask is used to specify the fields to be overwritten in the + * `PrivateCloud` resource by the update. The fields specified in `updateMask` + * 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. + * + * 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. Field mask is used to specify the fields to be overwritten in the + * `PrivateCloud` resource by the update. The fields specified in `updateMask` + * 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. + * + * 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; + } + + /** + * Optional. 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. 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; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdatePrivateConnectionRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdatePrivateConnectionRequest.php new file mode 100644 index 000000000000..46ee4128d3f1 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdatePrivateConnectionRequest.php @@ -0,0 +1,235 @@ +google.cloud.vmwareengine.v1.UpdatePrivateConnectionRequest + */ +class UpdatePrivateConnectionRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Private connection description. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateConnection private_connection = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $private_connection = null; + /** + * Required. Field mask is used to specify the fields to be overwritten in the + * `PrivateConnection` 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. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $update_mask = null; + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $request_id = ''; + + /** + * @param \Google\Cloud\VmwareEngine\V1\PrivateConnection $privateConnection Required. Private connection description. + * @param \Google\Protobuf\FieldMask $updateMask Required. Field mask is used to specify the fields to be overwritten in the + * `PrivateConnection` 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. + * + * @return \Google\Cloud\VmwareEngine\V1\UpdatePrivateConnectionRequest + * + * @experimental + */ + public static function build(\Google\Cloud\VmwareEngine\V1\PrivateConnection $privateConnection, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setPrivateConnection($privateConnection) + ->setUpdateMask($updateMask); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\VmwareEngine\V1\PrivateConnection $private_connection + * Required. Private connection description. + * @type \Google\Protobuf\FieldMask $update_mask + * Required. Field mask is used to specify the fields to be overwritten in the + * `PrivateConnection` 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. + * @type string $request_id + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. Private connection description. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateConnection private_connection = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\VmwareEngine\V1\PrivateConnection|null + */ + public function getPrivateConnection() + { + return $this->private_connection; + } + + public function hasPrivateConnection() + { + return isset($this->private_connection); + } + + public function clearPrivateConnection() + { + unset($this->private_connection); + } + + /** + * Required. Private connection description. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateConnection private_connection = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\VmwareEngine\V1\PrivateConnection $var + * @return $this + */ + public function setPrivateConnection($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\PrivateConnection::class); + $this->private_connection = $var; + + return $this; + } + + /** + * Required. Field mask is used to specify the fields to be overwritten in the + * `PrivateConnection` 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. + * + * 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. Field mask is used to specify the fields to be overwritten in the + * `PrivateConnection` 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. + * + * 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; + } + + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getRequestId() + { + return $this->request_id; + } + + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 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; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateSubnetRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateSubnetRequest.php new file mode 100644 index 000000000000..b37a82ae16b4 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateSubnetRequest.php @@ -0,0 +1,157 @@ +google.cloud.vmwareengine.v1.UpdateSubnetRequest + */ +class UpdateSubnetRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Field mask is used to specify the fields to be overwritten in the + * `Subnet` 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. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $update_mask = null; + /** + * Required. Subnet description. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.Subnet subnet = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $subnet = null; + + /** + * @param \Google\Cloud\VmwareEngine\V1\Subnet $subnet Required. Subnet description. + * @param \Google\Protobuf\FieldMask $updateMask Required. Field mask is used to specify the fields to be overwritten in the + * `Subnet` 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. + * + * @return \Google\Cloud\VmwareEngine\V1\UpdateSubnetRequest + * + * @experimental + */ + public static function build(\Google\Cloud\VmwareEngine\V1\Subnet $subnet, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setSubnet($subnet) + ->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 + * `Subnet` 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. + * @type \Google\Cloud\VmwareEngine\V1\Subnet $subnet + * Required. Subnet description. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. Field mask is used to specify the fields to be overwritten in the + * `Subnet` 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. + * + * 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 + * `Subnet` 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. + * + * 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. Subnet description. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.Subnet subnet = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\VmwareEngine\V1\Subnet|null + */ + public function getSubnet() + { + return $this->subnet; + } + + public function hasSubnet() + { + return isset($this->subnet); + } + + public function clearSubnet() + { + unset($this->subnet); + } + + /** + * Required. Subnet description. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.Subnet subnet = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\VmwareEngine\V1\Subnet $var + * @return $this + */ + public function setSubnet($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\Subnet::class); + $this->subnet = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateVmwareEngineNetworkRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateVmwareEngineNetworkRequest.php new file mode 100644 index 000000000000..2994f4021cc2 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateVmwareEngineNetworkRequest.php @@ -0,0 +1,240 @@ +google.cloud.vmwareengine.v1.UpdateVmwareEngineNetworkRequest + */ +class UpdateVmwareEngineNetworkRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. VMware Engine network description. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.VmwareEngineNetwork vmware_engine_network = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $vmware_engine_network = null; + /** + * Required. Field mask is used to specify the fields to be overwritten in the + * VMware Engine network 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. Only the + * following fields can be updated: `description`. + * + * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $update_mask = null; + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $request_id = ''; + + /** + * @param \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork $vmwareEngineNetwork Required. VMware Engine network description. + * @param \Google\Protobuf\FieldMask $updateMask Required. Field mask is used to specify the fields to be overwritten in the + * VMware Engine network 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. Only the + * following fields can be updated: `description`. + * + * @return \Google\Cloud\VmwareEngine\V1\UpdateVmwareEngineNetworkRequest + * + * @experimental + */ + public static function build(\Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork $vmwareEngineNetwork, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setVmwareEngineNetwork($vmwareEngineNetwork) + ->setUpdateMask($updateMask); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork $vmware_engine_network + * Required. VMware Engine network description. + * @type \Google\Protobuf\FieldMask $update_mask + * Required. Field mask is used to specify the fields to be overwritten in the + * VMware Engine network 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. Only the + * following fields can be updated: `description`. + * @type string $request_id + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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\Vmwareengine\V1\Vmwareengine::initOnce(); + parent::__construct($data); + } + + /** + * Required. VMware Engine network description. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.VmwareEngineNetwork vmware_engine_network = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork|null + */ + public function getVmwareEngineNetwork() + { + return $this->vmware_engine_network; + } + + public function hasVmwareEngineNetwork() + { + return isset($this->vmware_engine_network); + } + + public function clearVmwareEngineNetwork() + { + unset($this->vmware_engine_network); + } + + /** + * Required. VMware Engine network description. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.VmwareEngineNetwork vmware_engine_network = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork $var + * @return $this + */ + public function setVmwareEngineNetwork($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork::class); + $this->vmware_engine_network = $var; + + return $this; + } + + /** + * Required. Field mask is used to specify the fields to be overwritten in the + * VMware Engine network 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. Only the + * following fields can be updated: `description`. + * + * 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. Field mask is used to specify the fields to be overwritten in the + * VMware Engine network 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. Only the + * following fields can be updated: `description`. + * + * 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; + } + + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getRequestId() + { + return $this->request_id; + } + + /** + * Optional. A 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 guarantees that a + * request doesn't result in creation of duplicate commitments for at least 60 + * minutes. + * 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 = 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; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Vcenter.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Vcenter.php new file mode 100644 index 000000000000..b9d9c5b0aac2 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Vcenter.php @@ -0,0 +1,169 @@ +google.cloud.vmwareengine.v1.Vcenter + */ +class Vcenter extends \Google\Protobuf\Internal\Message +{ + /** + * Internal IP address of the appliance. + * + * Generated from protobuf field string internal_ip = 2; + */ + protected $internal_ip = ''; + /** + * Version of the appliance. + * + * Generated from protobuf field string version = 4; + */ + protected $version = ''; + /** + * Output only. The state of the appliance. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.Vcenter.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $state = 0; + /** + * Fully qualified domain name of the appliance. + * + * Generated from protobuf field string fqdn = 6; + */ + protected $fqdn = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $internal_ip + * Internal IP address of the appliance. + * @type string $version + * Version of the appliance. + * @type int $state + * Output only. The state of the appliance. + * @type string $fqdn + * Fully qualified domain name of the appliance. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); + parent::__construct($data); + } + + /** + * Internal IP address of the appliance. + * + * Generated from protobuf field string internal_ip = 2; + * @return string + */ + public function getInternalIp() + { + return $this->internal_ip; + } + + /** + * Internal IP address of the appliance. + * + * Generated from protobuf field string internal_ip = 2; + * @param string $var + * @return $this + */ + public function setInternalIp($var) + { + GPBUtil::checkString($var, True); + $this->internal_ip = $var; + + return $this; + } + + /** + * Version of the appliance. + * + * Generated from protobuf field string version = 4; + * @return string + */ + public function getVersion() + { + return $this->version; + } + + /** + * Version of the appliance. + * + * Generated from protobuf field string version = 4; + * @param string $var + * @return $this + */ + public function setVersion($var) + { + GPBUtil::checkString($var, True); + $this->version = $var; + + return $this; + } + + /** + * Output only. The state of the appliance. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.Vcenter.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getState() + { + return $this->state; + } + + /** + * Output only. The state of the appliance. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.Vcenter.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setState($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\Vcenter\State::class); + $this->state = $var; + + return $this; + } + + /** + * Fully qualified domain name of the appliance. + * + * Generated from protobuf field string fqdn = 6; + * @return string + */ + public function getFqdn() + { + return $this->fqdn; + } + + /** + * Fully qualified domain name of the appliance. + * + * Generated from protobuf field string fqdn = 6; + * @param string $var + * @return $this + */ + public function setFqdn($var) + { + GPBUtil::checkString($var, True); + $this->fqdn = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Vcenter/State.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Vcenter/State.php new file mode 100644 index 000000000000..eb444491b18d --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Vcenter/State.php @@ -0,0 +1,61 @@ +google.cloud.vmwareengine.v1.Vcenter.State + */ +class State +{ + /** + * Unspecified appliance state. This is the default value. + * + * Generated from protobuf enum STATE_UNSPECIFIED = 0; + */ + const STATE_UNSPECIFIED = 0; + /** + * The appliance is operational and can be used. + * + * Generated from protobuf enum ACTIVE = 1; + */ + const ACTIVE = 1; + /** + * The appliance is being deployed. + * + * Generated from protobuf enum CREATING = 2; + */ + const CREATING = 2; + + private static $valueToName = [ + self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', + self::ACTIVE => 'ACTIVE', + self::CREATING => 'CREATING', + ]; + + 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/VmwareEngineNetwork.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/VmwareEngineNetwork.php new file mode 100644 index 000000000000..300e0b940f7e --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/VmwareEngineNetwork.php @@ -0,0 +1,396 @@ +google.cloud.vmwareengine.v1.VmwareEngineNetwork + */ +class VmwareEngineNetwork extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. The resource name of the VMware Engine network. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/global/vmwareEngineNetworks/my-network` + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $name = ''; + /** + * Output only. Creation time of this resource. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $create_time = null; + /** + * Output only. Last update time of this resource. + * + * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $update_time = null; + /** + * User-provided description for this VMware Engine network. + * + * Generated from protobuf field string description = 5; + */ + protected $description = ''; + /** + * Output only. VMware Engine service VPC networks that provide connectivity + * from a private cloud to customer projects, the internet, and other Google + * Cloud services. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.VmwareEngineNetwork.VpcNetwork vpc_networks = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + private $vpc_networks; + /** + * Output only. State of the VMware Engine network. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.VmwareEngineNetwork.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $state = 0; + /** + * Required. VMware Engine network type. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.VmwareEngineNetwork.Type type = 8 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $type = 0; + /** + * Output only. System-generated unique identifier for the resource. + * + * Generated from protobuf field string uid = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $uid = ''; + /** + * Checksum that may be sent on update and delete requests to ensure that the + * user-provided value is up to date before the server processes a request. + * The server computes checksums based on the value of other fields in the + * request. + * + * Generated from protobuf field string etag = 10; + */ + protected $etag = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Output only. The resource name of the VMware Engine network. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/global/vmwareEngineNetworks/my-network` + * @type \Google\Protobuf\Timestamp $create_time + * Output only. Creation time of this resource. + * @type \Google\Protobuf\Timestamp $update_time + * Output only. Last update time of this resource. + * @type string $description + * User-provided description for this VMware Engine network. + * @type \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork\VpcNetwork[] $vpc_networks + * Output only. VMware Engine service VPC networks that provide connectivity + * from a private cloud to customer projects, the internet, and other Google + * Cloud services. + * @type int $state + * Output only. State of the VMware Engine network. + * @type int $type + * Required. VMware Engine network type. + * @type string $uid + * Output only. System-generated unique identifier for the resource. + * @type string $etag + * Checksum that may be sent on update and delete requests to ensure that the + * user-provided value is up to date before the server processes a request. + * The server computes checksums based on the value of other fields in the + * request. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); + parent::__construct($data); + } + + /** + * Output only. The resource name of the VMware Engine network. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/global/vmwareEngineNetworks/my-network` + * + * 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 VMware Engine network. + * Resource names are schemeless URIs that follow the conventions in + * https://cloud.google.com/apis/design/resource_names. + * For example: + * `projects/my-project/locations/global/vmwareEngineNetworks/my-network` + * + * 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. Creation time of this resource. + * + * 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 time of this resource. + * + * 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 time of this resource. + * + * 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 time of this resource. + * + * 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; + } + + /** + * User-provided description for this VMware Engine network. + * + * Generated from protobuf field string description = 5; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * User-provided description for this VMware Engine network. + * + * 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. VMware Engine service VPC networks that provide connectivity + * from a private cloud to customer projects, the internet, and other Google + * Cloud services. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.VmwareEngineNetwork.VpcNetwork vpc_networks = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork\VpcNetwork> + */ + public function getVpcNetworks() + { + return $this->vpc_networks; + } + + /** + * Output only. VMware Engine service VPC networks that provide connectivity + * from a private cloud to customer projects, the internet, and other Google + * Cloud services. + * + * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.VmwareEngineNetwork.VpcNetwork vpc_networks = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork\VpcNetwork[] $var + * @return $this + */ + public function setVpcNetworks($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork\VpcNetwork::class); + $this->vpc_networks = $arr; + + return $this; + } + + /** + * Output only. State of the VMware Engine network. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.VmwareEngineNetwork.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getState() + { + return $this->state; + } + + /** + * Output only. State of the VMware Engine network. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.VmwareEngineNetwork.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setState($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork\State::class); + $this->state = $var; + + return $this; + } + + /** + * Required. VMware Engine network type. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.VmwareEngineNetwork.Type type = 8 [(.google.api.field_behavior) = REQUIRED]; + * @return int + */ + public function getType() + { + return $this->type; + } + + /** + * Required. VMware Engine network type. + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.VmwareEngineNetwork.Type type = 8 [(.google.api.field_behavior) = REQUIRED]; + * @param int $var + * @return $this + */ + public function setType($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork\Type::class); + $this->type = $var; + + return $this; + } + + /** + * Output only. System-generated unique identifier for the resource. + * + * Generated from protobuf field string uid = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getUid() + { + return $this->uid; + } + + /** + * Output only. System-generated unique identifier for the resource. + * + * Generated from protobuf field string uid = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setUid($var) + { + GPBUtil::checkString($var, True); + $this->uid = $var; + + return $this; + } + + /** + * Checksum that may be sent on update and delete requests to ensure that the + * user-provided value is up to date before the server processes a request. + * The server computes checksums based on the value of other fields in the + * request. + * + * Generated from protobuf field string etag = 10; + * @return string + */ + public function getEtag() + { + return $this->etag; + } + + /** + * Checksum that may be sent on update and delete requests to ensure that the + * user-provided value is up to date before the server processes a request. + * The server computes checksums based on the value of other fields in the + * request. + * + * Generated from protobuf field string etag = 10; + * @param string $var + * @return $this + */ + public function setEtag($var) + { + GPBUtil::checkString($var, True); + $this->etag = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/VmwareEngineNetwork/State.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/VmwareEngineNetwork/State.php new file mode 100644 index 000000000000..a20e89ebef11 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/VmwareEngineNetwork/State.php @@ -0,0 +1,75 @@ +google.cloud.vmwareengine.v1.VmwareEngineNetwork.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 VMware Engine network is being created. + * + * Generated from protobuf enum CREATING = 1; + */ + const CREATING = 1; + /** + * The VMware Engine network is ready. + * + * Generated from protobuf enum ACTIVE = 2; + */ + const ACTIVE = 2; + /** + * The VMware Engine network is being updated. + * + * Generated from protobuf enum UPDATING = 3; + */ + const UPDATING = 3; + /** + * The VMware Engine network is being deleted. + * + * Generated from protobuf enum DELETING = 4; + */ + const DELETING = 4; + + private static $valueToName = [ + self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', + self::CREATING => 'CREATING', + self::ACTIVE => 'ACTIVE', + self::UPDATING => 'UPDATING', + 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); + } +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/VmwareEngineNetwork/Type.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/VmwareEngineNetwork/Type.php new file mode 100644 index 000000000000..02b2e4490642 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/VmwareEngineNetwork/Type.php @@ -0,0 +1,63 @@ +google.cloud.vmwareengine.v1.VmwareEngineNetwork.Type + */ +class Type +{ + /** + * The default value. This value should never be used. + * + * Generated from protobuf enum TYPE_UNSPECIFIED = 0; + */ + const TYPE_UNSPECIFIED = 0; + /** + * Network type used by private clouds created in projects without a network + * of type `STANDARD`. This network type is no longer used for new VMware + * Engine private cloud deployments. + * + * Generated from protobuf enum LEGACY = 1; + */ + const LEGACY = 1; + /** + * Standard network type used for private cloud connectivity. + * + * Generated from protobuf enum STANDARD = 2; + */ + const STANDARD = 2; + + private static $valueToName = [ + self::TYPE_UNSPECIFIED => 'TYPE_UNSPECIFIED', + self::LEGACY => 'LEGACY', + self::STANDARD => 'STANDARD', + ]; + + 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/VmwareEngineNetwork/VpcNetwork.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/VmwareEngineNetwork/VpcNetwork.php new file mode 100644 index 000000000000..e223d6a569ec --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/VmwareEngineNetwork/VpcNetwork.php @@ -0,0 +1,114 @@ +google.cloud.vmwareengine.v1.VmwareEngineNetwork.VpcNetwork + */ +class VpcNetwork extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. Type of VPC network (INTRANET, INTERNET, or + * GOOGLE_CLOUD) + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.VmwareEngineNetwork.VpcNetwork.Type type = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $type = 0; + /** + * Output only. The relative resource name of the service VPC network this + * VMware Engine network is attached to. For example: + * `projects/123123/global/networks/my-network` + * + * Generated from protobuf field string network = 2 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { + */ + protected $network = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $type + * Output only. Type of VPC network (INTRANET, INTERNET, or + * GOOGLE_CLOUD) + * @type string $network + * Output only. The relative resource name of the service VPC network this + * VMware Engine network is attached to. For example: + * `projects/123123/global/networks/my-network` + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); + parent::__construct($data); + } + + /** + * Output only. Type of VPC network (INTRANET, INTERNET, or + * GOOGLE_CLOUD) + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.VmwareEngineNetwork.VpcNetwork.Type type = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getType() + { + return $this->type; + } + + /** + * Output only. Type of VPC network (INTRANET, INTERNET, or + * GOOGLE_CLOUD) + * + * Generated from protobuf field .google.cloud.vmwareengine.v1.VmwareEngineNetwork.VpcNetwork.Type type = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setType($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork\VpcNetwork\Type::class); + $this->type = $var; + + return $this; + } + + /** + * Output only. The relative resource name of the service VPC network this + * VMware Engine network is attached to. For example: + * `projects/123123/global/networks/my-network` + * + * Generated from protobuf field string network = 2 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { + * @return string + */ + public function getNetwork() + { + return $this->network; + } + + /** + * Output only. The relative resource name of the service VPC network this + * VMware Engine network is attached to. For example: + * `projects/123123/global/networks/my-network` + * + * Generated from protobuf field string network = 2 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setNetwork($var) + { + GPBUtil::checkString($var, True); + $this->network = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/VmwareEngineNetwork/VpcNetwork/Type.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/VmwareEngineNetwork/VpcNetwork/Type.php new file mode 100644 index 000000000000..8ac68c237aa8 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/VmwareEngineNetwork/VpcNetwork/Type.php @@ -0,0 +1,73 @@ +google.cloud.vmwareengine.v1.VmwareEngineNetwork.VpcNetwork.Type + */ +class Type +{ + /** + * The default value. This value should never be used. + * + * Generated from protobuf enum TYPE_UNSPECIFIED = 0; + */ + const TYPE_UNSPECIFIED = 0; + /** + * VPC network that will be peered with a consumer VPC network or the + * intranet VPC of another VMware Engine network. Access a private cloud + * through Compute Engine VMs on a peered VPC network or an on-premises + * resource connected to a peered consumer VPC network. + * + * Generated from protobuf enum INTRANET = 1; + */ + const INTRANET = 1; + /** + * VPC network used for internet access to and from a private cloud. + * + * Generated from protobuf enum INTERNET = 2; + */ + const INTERNET = 2; + /** + * VPC network used for access to Google Cloud services like + * Cloud Storage. + * + * Generated from protobuf enum GOOGLE_CLOUD = 3; + */ + const GOOGLE_CLOUD = 3; + + private static $valueToName = [ + self::TYPE_UNSPECIFIED => 'TYPE_UNSPECIFIED', + self::INTRANET => 'INTRANET', + self::INTERNET => 'INTERNET', + self::GOOGLE_CLOUD => 'GOOGLE_CLOUD', + ]; + + 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/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_cluster.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_cluster.php new file mode 100644 index 000000000000..3c5c13790d00 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_cluster.php @@ -0,0 +1,111 @@ +setNodeTypeConfigs($clusterNodeTypeConfigs); + $request = (new CreateClusterRequest()) + ->setParent($formattedParent) + ->setClusterId($clusterId) + ->setCluster($cluster); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vmwareEngineClient->createCluster($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var Cluster $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 = VmwareEngineClient::privateCloudName( + '[PROJECT]', + '[LOCATION]', + '[PRIVATE_CLOUD]' + ); + $clusterId = '[CLUSTER_ID]'; + + create_cluster_sample($formattedParent, $clusterId); +} +// [END vmwareengine_v1_generated_VmwareEngine_CreateCluster_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_external_access_rule.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_external_access_rule.php new file mode 100644 index 000000000000..8a18f02c5f94 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_external_access_rule.php @@ -0,0 +1,109 @@ +setParent($formattedParent) + ->setExternalAccessRule($externalAccessRule) + ->setExternalAccessRuleId($externalAccessRuleId); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vmwareEngineClient->createExternalAccessRule($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var ExternalAccessRule $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 = VmwareEngineClient::networkPolicyName( + '[PROJECT]', + '[LOCATION]', + '[NETWORK_POLICY]' + ); + $externalAccessRuleId = '[EXTERNAL_ACCESS_RULE_ID]'; + + create_external_access_rule_sample($formattedParent, $externalAccessRuleId); +} +// [END vmwareengine_v1_generated_VmwareEngine_CreateExternalAccessRule_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_external_address.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_external_address.php new file mode 100644 index 000000000000..847381723e90 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_external_address.php @@ -0,0 +1,109 @@ +setParent($formattedParent) + ->setExternalAddress($externalAddress) + ->setExternalAddressId($externalAddressId); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vmwareEngineClient->createExternalAddress($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var ExternalAddress $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 = VmwareEngineClient::privateCloudName( + '[PROJECT]', + '[LOCATION]', + '[PRIVATE_CLOUD]' + ); + $externalAddressId = '[EXTERNAL_ADDRESS_ID]'; + + create_external_address_sample($formattedParent, $externalAddressId); +} +// [END vmwareengine_v1_generated_VmwareEngine_CreateExternalAddress_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_hcx_activation_key.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_hcx_activation_key.php new file mode 100644 index 000000000000..b1719637eb0b --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_hcx_activation_key.php @@ -0,0 +1,108 @@ +setParent($formattedParent) + ->setHcxActivationKey($hcxActivationKey) + ->setHcxActivationKeyId($hcxActivationKeyId); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vmwareEngineClient->createHcxActivationKey($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var HcxActivationKey $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 = VmwareEngineClient::privateCloudName( + '[PROJECT]', + '[LOCATION]', + '[PRIVATE_CLOUD]' + ); + $hcxActivationKeyId = '[HCX_ACTIVATION_KEY_ID]'; + + create_hcx_activation_key_sample($formattedParent, $hcxActivationKeyId); +} +// [END vmwareengine_v1_generated_VmwareEngine_CreateHcxActivationKey_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_logging_server.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_logging_server.php new file mode 100644 index 000000000000..51f2f18d9288 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_logging_server.php @@ -0,0 +1,136 @@ +setHostname($loggingServerHostname) + ->setPort($loggingServerPort) + ->setProtocol($loggingServerProtocol) + ->setSourceType($loggingServerSourceType); + $request = (new CreateLoggingServerRequest()) + ->setParent($formattedParent) + ->setLoggingServer($loggingServer) + ->setLoggingServerId($loggingServerId); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vmwareEngineClient->createLoggingServer($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var LoggingServer $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 = VmwareEngineClient::privateCloudName( + '[PROJECT]', + '[LOCATION]', + '[PRIVATE_CLOUD]' + ); + $loggingServerHostname = '[HOSTNAME]'; + $loggingServerPort = 0; + $loggingServerProtocol = Protocol::PROTOCOL_UNSPECIFIED; + $loggingServerSourceType = SourceType::SOURCE_TYPE_UNSPECIFIED; + $loggingServerId = '[LOGGING_SERVER_ID]'; + + create_logging_server_sample( + $formattedParent, + $loggingServerHostname, + $loggingServerPort, + $loggingServerProtocol, + $loggingServerSourceType, + $loggingServerId + ); +} +// [END vmwareengine_v1_generated_VmwareEngine_CreateLoggingServer_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_management_dns_zone_binding.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_management_dns_zone_binding.php new file mode 100644 index 000000000000..3a988bbd9eff --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_management_dns_zone_binding.php @@ -0,0 +1,116 @@ +setParent($formattedParent) + ->setManagementDnsZoneBinding($managementDnsZoneBinding) + ->setManagementDnsZoneBindingId($managementDnsZoneBindingId); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vmwareEngineClient->createManagementDnsZoneBinding($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var ManagementDnsZoneBinding $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 = VmwareEngineClient::privateCloudName( + '[PROJECT]', + '[LOCATION]', + '[PRIVATE_CLOUD]' + ); + $managementDnsZoneBindingId = '[MANAGEMENT_DNS_ZONE_BINDING_ID]'; + + create_management_dns_zone_binding_sample($formattedParent, $managementDnsZoneBindingId); +} +// [END vmwareengine_v1_generated_VmwareEngine_CreateManagementDnsZoneBinding_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_network_peering.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_network_peering.php new file mode 100644 index 000000000000..6b4cd697429f --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_network_peering.php @@ -0,0 +1,140 @@ +setPeerNetwork($networkPeeringPeerNetwork) + ->setPeerNetworkType($networkPeeringPeerNetworkType) + ->setVmwareEngineNetwork($formattedNetworkPeeringVmwareEngineNetwork); + $request = (new CreateNetworkPeeringRequest()) + ->setParent($formattedParent) + ->setNetworkPeeringId($networkPeeringId) + ->setNetworkPeering($networkPeering); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vmwareEngineClient->createNetworkPeering($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var NetworkPeering $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 = VmwareEngineClient::locationName('[PROJECT]', '[LOCATION]'); + $networkPeeringId = '[NETWORK_PEERING_ID]'; + $networkPeeringPeerNetwork = '[PEER_NETWORK]'; + $networkPeeringPeerNetworkType = PeerNetworkType::PEER_NETWORK_TYPE_UNSPECIFIED; + $formattedNetworkPeeringVmwareEngineNetwork = VmwareEngineClient::vmwareEngineNetworkName( + '[PROJECT]', + '[LOCATION]', + '[VMWARE_ENGINE_NETWORK]' + ); + + create_network_peering_sample( + $formattedParent, + $networkPeeringId, + $networkPeeringPeerNetwork, + $networkPeeringPeerNetworkType, + $formattedNetworkPeeringVmwareEngineNetwork + ); +} +// [END vmwareengine_v1_generated_VmwareEngine_CreateNetworkPeering_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_network_policy.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_network_policy.php new file mode 100644 index 000000000000..f15be3f399c7 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_network_policy.php @@ -0,0 +1,115 @@ +setEdgeServicesCidr($networkPolicyEdgeServicesCidr); + $request = (new CreateNetworkPolicyRequest()) + ->setParent($formattedParent) + ->setNetworkPolicyId($networkPolicyId) + ->setNetworkPolicy($networkPolicy); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vmwareEngineClient->createNetworkPolicy($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var NetworkPolicy $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 = VmwareEngineClient::locationName('[PROJECT]', '[LOCATION]'); + $networkPolicyId = '[NETWORK_POLICY_ID]'; + $networkPolicyEdgeServicesCidr = '[EDGE_SERVICES_CIDR]'; + + create_network_policy_sample($formattedParent, $networkPolicyId, $networkPolicyEdgeServicesCidr); +} +// [END vmwareengine_v1_generated_VmwareEngine_CreateNetworkPolicy_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_private_cloud.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_private_cloud.php new file mode 100644 index 000000000000..82e975c3daf0 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_private_cloud.php @@ -0,0 +1,139 @@ +setManagementCidr($privateCloudNetworkConfigManagementCidr); + $privateCloudManagementClusterNodeTypeConfigs = []; + $privateCloudManagementCluster = (new ManagementCluster()) + ->setClusterId($privateCloudManagementClusterClusterId) + ->setNodeTypeConfigs($privateCloudManagementClusterNodeTypeConfigs); + $privateCloud = (new PrivateCloud()) + ->setNetworkConfig($privateCloudNetworkConfig) + ->setManagementCluster($privateCloudManagementCluster); + $request = (new CreatePrivateCloudRequest()) + ->setParent($formattedParent) + ->setPrivateCloudId($privateCloudId) + ->setPrivateCloud($privateCloud); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vmwareEngineClient->createPrivateCloud($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var PrivateCloud $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 = VmwareEngineClient::locationName('[PROJECT]', '[LOCATION]'); + $privateCloudId = '[PRIVATE_CLOUD_ID]'; + $privateCloudNetworkConfigManagementCidr = '[MANAGEMENT_CIDR]'; + $privateCloudManagementClusterClusterId = '[CLUSTER_ID]'; + + create_private_cloud_sample( + $formattedParent, + $privateCloudId, + $privateCloudNetworkConfigManagementCidr, + $privateCloudManagementClusterClusterId + ); +} +// [END vmwareengine_v1_generated_VmwareEngine_CreatePrivateCloud_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_private_connection.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_private_connection.php new file mode 100644 index 000000000000..07886cb7aba0 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_private_connection.php @@ -0,0 +1,150 @@ +setVmwareEngineNetwork($formattedPrivateConnectionVmwareEngineNetwork) + ->setType($privateConnectionType) + ->setServiceNetwork($formattedPrivateConnectionServiceNetwork); + $request = (new CreatePrivateConnectionRequest()) + ->setParent($formattedParent) + ->setPrivateConnectionId($privateConnectionId) + ->setPrivateConnection($privateConnection); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vmwareEngineClient->createPrivateConnection($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var PrivateConnection $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 = VmwareEngineClient::locationName('[PROJECT]', '[LOCATION]'); + $privateConnectionId = '[PRIVATE_CONNECTION_ID]'; + $formattedPrivateConnectionVmwareEngineNetwork = VmwareEngineClient::vmwareEngineNetworkName( + '[PROJECT]', + '[LOCATION]', + '[VMWARE_ENGINE_NETWORK]' + ); + $privateConnectionType = Type::TYPE_UNSPECIFIED; + $formattedPrivateConnectionServiceNetwork = VmwareEngineClient::networkName( + '[PROJECT]', + '[NETWORK]' + ); + + create_private_connection_sample( + $formattedParent, + $privateConnectionId, + $formattedPrivateConnectionVmwareEngineNetwork, + $privateConnectionType, + $formattedPrivateConnectionServiceNetwork + ); +} +// [END vmwareengine_v1_generated_VmwareEngine_CreatePrivateConnection_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_vmware_engine_network.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_vmware_engine_network.php new file mode 100644 index 000000000000..a6341f8c1c21 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_vmware_engine_network.php @@ -0,0 +1,118 @@ +setType($vmwareEngineNetworkType); + $request = (new CreateVmwareEngineNetworkRequest()) + ->setParent($formattedParent) + ->setVmwareEngineNetworkId($vmwareEngineNetworkId) + ->setVmwareEngineNetwork($vmwareEngineNetwork); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vmwareEngineClient->createVmwareEngineNetwork($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var VmwareEngineNetwork $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 = VmwareEngineClient::locationName('[PROJECT]', '[LOCATION]'); + $vmwareEngineNetworkId = '[VMWARE_ENGINE_NETWORK_ID]'; + $vmwareEngineNetworkType = Type::TYPE_UNSPECIFIED; + + create_vmware_engine_network_sample( + $formattedParent, + $vmwareEngineNetworkId, + $vmwareEngineNetworkType + ); +} +// [END vmwareengine_v1_generated_VmwareEngine_CreateVmwareEngineNetwork_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_cluster.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_cluster.php new file mode 100644 index 000000000000..8b52ee95d96c --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_cluster.php @@ -0,0 +1,92 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vmwareEngineClient->deleteCluster($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 = VmwareEngineClient::clusterName( + '[PROJECT]', + '[LOCATION]', + '[PRIVATE_CLOUD]', + '[CLUSTER]' + ); + + delete_cluster_sample($formattedName); +} +// [END vmwareengine_v1_generated_VmwareEngine_DeleteCluster_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_external_access_rule.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_external_access_rule.php new file mode 100644 index 000000000000..698ef6e0513e --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_external_access_rule.php @@ -0,0 +1,89 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vmwareEngineClient->deleteExternalAccessRule($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 = VmwareEngineClient::externalAccessRuleName( + '[PROJECT]', + '[LOCATION]', + '[NETWORK_POLICY]', + '[EXTERNAL_ACCESS_RULE]' + ); + + delete_external_access_rule_sample($formattedName); +} +// [END vmwareengine_v1_generated_VmwareEngine_DeleteExternalAccessRule_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_external_address.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_external_address.php new file mode 100644 index 000000000000..05a16494102e --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_external_address.php @@ -0,0 +1,91 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vmwareEngineClient->deleteExternalAddress($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 = VmwareEngineClient::externalAddressName( + '[PROJECT]', + '[LOCATION]', + '[PRIVATE_CLOUD]', + '[EXTERNAL_ADDRESS]' + ); + + delete_external_address_sample($formattedName); +} +// [END vmwareengine_v1_generated_VmwareEngine_DeleteExternalAddress_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_logging_server.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_logging_server.php new file mode 100644 index 000000000000..f0925c4a3122 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_logging_server.php @@ -0,0 +1,89 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vmwareEngineClient->deleteLoggingServer($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 = VmwareEngineClient::loggingServerName( + '[PROJECT]', + '[LOCATION]', + '[PRIVATE_CLOUD]', + '[LOGGING_SERVER]' + ); + + delete_logging_server_sample($formattedName); +} +// [END vmwareengine_v1_generated_VmwareEngine_DeleteLoggingServer_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_management_dns_zone_binding.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_management_dns_zone_binding.php new file mode 100644 index 000000000000..f468098c83a1 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_management_dns_zone_binding.php @@ -0,0 +1,91 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vmwareEngineClient->deleteManagementDnsZoneBinding($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 = VmwareEngineClient::managementDnsZoneBindingName( + '[PROJECT]', + '[LOCATION]', + '[PRIVATE_CLOUD]', + '[MANAGEMENT_DNS_ZONE_BINDING]' + ); + + delete_management_dns_zone_binding_sample($formattedName); +} +// [END vmwareengine_v1_generated_VmwareEngine_DeleteManagementDnsZoneBinding_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_network_peering.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_network_peering.php new file mode 100644 index 000000000000..f7d05f9ea5b9 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_network_peering.php @@ -0,0 +1,91 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vmwareEngineClient->deleteNetworkPeering($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 = VmwareEngineClient::networkPeeringName( + '[PROJECT]', + '[LOCATION]', + '[NETWORK_PEERING]' + ); + + delete_network_peering_sample($formattedName); +} +// [END vmwareengine_v1_generated_VmwareEngine_DeleteNetworkPeering_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_network_policy.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_network_policy.php new file mode 100644 index 000000000000..91ff032245c4 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_network_policy.php @@ -0,0 +1,90 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vmwareEngineClient->deleteNetworkPolicy($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 = VmwareEngineClient::networkPolicyName( + '[PROJECT]', + '[LOCATION]', + '[NETWORK_POLICY]' + ); + + delete_network_policy_sample($formattedName); +} +// [END vmwareengine_v1_generated_VmwareEngine_DeleteNetworkPolicy_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_private_cloud.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_private_cloud.php new file mode 100644 index 000000000000..617474ba14b2 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_private_cloud.php @@ -0,0 +1,101 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vmwareEngineClient->deletePrivateCloud($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var PrivateCloud $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 = VmwareEngineClient::privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); + + delete_private_cloud_sample($formattedName); +} +// [END vmwareengine_v1_generated_VmwareEngine_DeletePrivateCloud_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_private_connection.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_private_connection.php new file mode 100644 index 000000000000..d2bf7afb7b8a --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_private_connection.php @@ -0,0 +1,90 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vmwareEngineClient->deletePrivateConnection($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 = VmwareEngineClient::privateConnectionName( + '[PROJECT]', + '[LOCATION]', + '[PRIVATE_CONNECTION]' + ); + + delete_private_connection_sample($formattedName); +} +// [END vmwareengine_v1_generated_VmwareEngine_DeletePrivateConnection_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_vmware_engine_network.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_vmware_engine_network.php new file mode 100644 index 000000000000..bf2516710177 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_vmware_engine_network.php @@ -0,0 +1,91 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vmwareEngineClient->deleteVmwareEngineNetwork($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 = VmwareEngineClient::vmwareEngineNetworkName( + '[PROJECT]', + '[LOCATION]', + '[VMWARE_ENGINE_NETWORK]' + ); + + delete_vmware_engine_network_sample($formattedName); +} +// [END vmwareengine_v1_generated_VmwareEngine_DeleteVmwareEngineNetwork_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/fetch_network_policy_external_addresses.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/fetch_network_policy_external_addresses.php new file mode 100644 index 000000000000..7b3012a15ab6 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/fetch_network_policy_external_addresses.php @@ -0,0 +1,85 @@ +setNetworkPolicy($formattedNetworkPolicy); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $vmwareEngineClient->fetchNetworkPolicyExternalAddresses($request); + + /** @var ExternalAddress $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 +{ + $formattedNetworkPolicy = VmwareEngineClient::networkPolicyName( + '[PROJECT]', + '[LOCATION]', + '[NETWORK_POLICY]' + ); + + fetch_network_policy_external_addresses_sample($formattedNetworkPolicy); +} +// [END vmwareengine_v1_generated_VmwareEngine_FetchNetworkPolicyExternalAddresses_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_cluster.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_cluster.php new file mode 100644 index 000000000000..dbfceec11a84 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_cluster.php @@ -0,0 +1,80 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var Cluster $response */ + $response = $vmwareEngineClient->getCluster($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 = VmwareEngineClient::clusterName( + '[PROJECT]', + '[LOCATION]', + '[PRIVATE_CLOUD]', + '[CLUSTER]' + ); + + get_cluster_sample($formattedName); +} +// [END vmwareengine_v1_generated_VmwareEngine_GetCluster_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_dns_bind_permission.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_dns_bind_permission.php new file mode 100644 index 000000000000..b8bd0cfe9f5e --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_dns_bind_permission.php @@ -0,0 +1,78 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var DnsBindPermission $response */ + $response = $vmwareEngineClient->getDnsBindPermission($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 = VmwareEngineClient::dnsBindPermissionName('[PROJECT]', '[LOCATION]'); + + get_dns_bind_permission_sample($formattedName); +} +// [END vmwareengine_v1_generated_VmwareEngine_GetDnsBindPermission_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_dns_forwarding.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_dns_forwarding.php new file mode 100644 index 000000000000..c296fa15e107 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_dns_forwarding.php @@ -0,0 +1,79 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var DnsForwarding $response */ + $response = $vmwareEngineClient->getDnsForwarding($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 = VmwareEngineClient::dnsForwardingName( + '[PROJECT]', + '[LOCATION]', + '[PRIVATE_CLOUD]' + ); + + get_dns_forwarding_sample($formattedName); +} +// [END vmwareengine_v1_generated_VmwareEngine_GetDnsForwarding_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_external_access_rule.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_external_access_rule.php new file mode 100644 index 000000000000..4956f4f39764 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_external_access_rule.php @@ -0,0 +1,80 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var ExternalAccessRule $response */ + $response = $vmwareEngineClient->getExternalAccessRule($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 = VmwareEngineClient::externalAccessRuleName( + '[PROJECT]', + '[LOCATION]', + '[NETWORK_POLICY]', + '[EXTERNAL_ACCESS_RULE]' + ); + + get_external_access_rule_sample($formattedName); +} +// [END vmwareengine_v1_generated_VmwareEngine_GetExternalAccessRule_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_external_address.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_external_address.php new file mode 100644 index 000000000000..e03eaeeec78c --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_external_address.php @@ -0,0 +1,80 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var ExternalAddress $response */ + $response = $vmwareEngineClient->getExternalAddress($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 = VmwareEngineClient::externalAddressName( + '[PROJECT]', + '[LOCATION]', + '[PRIVATE_CLOUD]', + '[EXTERNAL_ADDRESS]' + ); + + get_external_address_sample($formattedName); +} +// [END vmwareengine_v1_generated_VmwareEngine_GetExternalAddress_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_hcx_activation_key.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_hcx_activation_key.php new file mode 100644 index 000000000000..977eb9e46998 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_hcx_activation_key.php @@ -0,0 +1,80 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var HcxActivationKey $response */ + $response = $vmwareEngineClient->getHcxActivationKey($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 = VmwareEngineClient::hcxActivationKeyName( + '[PROJECT]', + '[LOCATION]', + '[PRIVATE_CLOUD]', + '[HCX_ACTIVATION_KEY]' + ); + + get_hcx_activation_key_sample($formattedName); +} +// [END vmwareengine_v1_generated_VmwareEngine_GetHcxActivationKey_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_iam_policy.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_iam_policy.php new file mode 100644 index 000000000000..218de3f0f81a --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_iam_policy.php @@ -0,0 +1,72 @@ +setResource($resource); + + // Call the API and handle any network failures. + try { + /** @var Policy $response */ + $response = $vmwareEngineClient->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 vmwareengine_v1_generated_VmwareEngine_GetIamPolicy_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_location.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_location.php new file mode 100644 index 000000000000..ac8afb52a829 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_location.php @@ -0,0 +1,57 @@ +getLocation($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} +// [END vmwareengine_v1_generated_VmwareEngine_GetLocation_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_logging_server.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_logging_server.php new file mode 100644 index 000000000000..d1ad1d3d5670 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_logging_server.php @@ -0,0 +1,80 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var LoggingServer $response */ + $response = $vmwareEngineClient->getLoggingServer($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 = VmwareEngineClient::loggingServerName( + '[PROJECT]', + '[LOCATION]', + '[PRIVATE_CLOUD]', + '[LOGGING_SERVER]' + ); + + get_logging_server_sample($formattedName); +} +// [END vmwareengine_v1_generated_VmwareEngine_GetLoggingServer_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_management_dns_zone_binding.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_management_dns_zone_binding.php new file mode 100644 index 000000000000..141b5705d3d5 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_management_dns_zone_binding.php @@ -0,0 +1,80 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var ManagementDnsZoneBinding $response */ + $response = $vmwareEngineClient->getManagementDnsZoneBinding($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 = VmwareEngineClient::managementDnsZoneBindingName( + '[PROJECT]', + '[LOCATION]', + '[PRIVATE_CLOUD]', + '[MANAGEMENT_DNS_ZONE_BINDING]' + ); + + get_management_dns_zone_binding_sample($formattedName); +} +// [END vmwareengine_v1_generated_VmwareEngine_GetManagementDnsZoneBinding_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_network_peering.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_network_peering.php new file mode 100644 index 000000000000..9f67d8a9023d --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_network_peering.php @@ -0,0 +1,82 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var NetworkPeering $response */ + $response = $vmwareEngineClient->getNetworkPeering($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 = VmwareEngineClient::networkPeeringName( + '[PROJECT]', + '[LOCATION]', + '[NETWORK_PEERING]' + ); + + get_network_peering_sample($formattedName); +} +// [END vmwareengine_v1_generated_VmwareEngine_GetNetworkPeering_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_network_policy.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_network_policy.php new file mode 100644 index 000000000000..1858a6bb51b4 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_network_policy.php @@ -0,0 +1,79 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var NetworkPolicy $response */ + $response = $vmwareEngineClient->getNetworkPolicy($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 = VmwareEngineClient::networkPolicyName( + '[PROJECT]', + '[LOCATION]', + '[NETWORK_POLICY]' + ); + + get_network_policy_sample($formattedName); +} +// [END vmwareengine_v1_generated_VmwareEngine_GetNetworkPolicy_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_node.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_node.php new file mode 100644 index 000000000000..606068f1bd00 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_node.php @@ -0,0 +1,79 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var Node $response */ + $response = $vmwareEngineClient->getNode($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 = VmwareEngineClient::nodeName( + '[PROJECT]', + '[LOCATION]', + '[PRIVATE_CLOUD]', + '[CLUSTER]', + '[NODE]' + ); + + get_node_sample($formattedName); +} +// [END vmwareengine_v1_generated_VmwareEngine_GetNode_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_node_type.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_node_type.php new file mode 100644 index 000000000000..bf314f1c3ca7 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_node_type.php @@ -0,0 +1,75 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var NodeType $response */ + $response = $vmwareEngineClient->getNodeType($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 = VmwareEngineClient::nodeTypeName('[PROJECT]', '[LOCATION]', '[NODE_TYPE]'); + + get_node_type_sample($formattedName); +} +// [END vmwareengine_v1_generated_VmwareEngine_GetNodeType_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_private_cloud.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_private_cloud.php new file mode 100644 index 000000000000..aea564280e7b --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_private_cloud.php @@ -0,0 +1,75 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var PrivateCloud $response */ + $response = $vmwareEngineClient->getPrivateCloud($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 = VmwareEngineClient::privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); + + get_private_cloud_sample($formattedName); +} +// [END vmwareengine_v1_generated_VmwareEngine_GetPrivateCloud_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_private_connection.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_private_connection.php new file mode 100644 index 000000000000..5e93253c5144 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_private_connection.php @@ -0,0 +1,81 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var PrivateConnection $response */ + $response = $vmwareEngineClient->getPrivateConnection($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 = VmwareEngineClient::privateConnectionName( + '[PROJECT]', + '[LOCATION]', + '[PRIVATE_CONNECTION]' + ); + + get_private_connection_sample($formattedName); +} +// [END vmwareengine_v1_generated_VmwareEngine_GetPrivateConnection_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_subnet.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_subnet.php new file mode 100644 index 000000000000..3400ca7377a3 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_subnet.php @@ -0,0 +1,80 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var Subnet $response */ + $response = $vmwareEngineClient->getSubnet($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 = VmwareEngineClient::subnetName( + '[PROJECT]', + '[LOCATION]', + '[PRIVATE_CLOUD]', + '[SUBNET]' + ); + + get_subnet_sample($formattedName); +} +// [END vmwareengine_v1_generated_VmwareEngine_GetSubnet_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_vmware_engine_network.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_vmware_engine_network.php new file mode 100644 index 000000000000..0000f359e144 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_vmware_engine_network.php @@ -0,0 +1,82 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var VmwareEngineNetwork $response */ + $response = $vmwareEngineClient->getVmwareEngineNetwork($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 = VmwareEngineClient::vmwareEngineNetworkName( + '[PROJECT]', + '[LOCATION]', + '[VMWARE_ENGINE_NETWORK]' + ); + + get_vmware_engine_network_sample($formattedName); +} +// [END vmwareengine_v1_generated_VmwareEngine_GetVmwareEngineNetwork_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/grant_dns_bind_permission.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/grant_dns_bind_permission.php new file mode 100644 index 000000000000..9f2f39f426fb --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/grant_dns_bind_permission.php @@ -0,0 +1,94 @@ +setName($formattedName) + ->setPrincipal($principal); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vmwareEngineClient->grantDnsBindPermission($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var DnsBindPermission $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 = VmwareEngineClient::dnsBindPermissionName('[PROJECT]', '[LOCATION]'); + + grant_dns_bind_permission_sample($formattedName); +} +// [END vmwareengine_v1_generated_VmwareEngine_GrantDnsBindPermission_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_clusters.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_clusters.php new file mode 100644 index 000000000000..189100b2a36d --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_clusters.php @@ -0,0 +1,84 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $vmwareEngineClient->listClusters($request); + + /** @var Cluster $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 = VmwareEngineClient::privateCloudName( + '[PROJECT]', + '[LOCATION]', + '[PRIVATE_CLOUD]' + ); + + list_clusters_sample($formattedParent); +} +// [END vmwareengine_v1_generated_VmwareEngine_ListClusters_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_external_access_rules.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_external_access_rules.php new file mode 100644 index 000000000000..7baf8030d44c --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_external_access_rules.php @@ -0,0 +1,84 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $vmwareEngineClient->listExternalAccessRules($request); + + /** @var ExternalAccessRule $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 = VmwareEngineClient::networkPolicyName( + '[PROJECT]', + '[LOCATION]', + '[NETWORK_POLICY]' + ); + + list_external_access_rules_sample($formattedParent); +} +// [END vmwareengine_v1_generated_VmwareEngine_ListExternalAccessRules_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_external_addresses.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_external_addresses.php new file mode 100644 index 000000000000..ff1e309f4c08 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_external_addresses.php @@ -0,0 +1,86 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $vmwareEngineClient->listExternalAddresses($request); + + /** @var ExternalAddress $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 = VmwareEngineClient::privateCloudName( + '[PROJECT]', + '[LOCATION]', + '[PRIVATE_CLOUD]' + ); + + list_external_addresses_sample($formattedParent); +} +// [END vmwareengine_v1_generated_VmwareEngine_ListExternalAddresses_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_hcx_activation_keys.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_hcx_activation_keys.php new file mode 100644 index 000000000000..590b1edf06bb --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_hcx_activation_keys.php @@ -0,0 +1,85 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $vmwareEngineClient->listHcxActivationKeys($request); + + /** @var HcxActivationKey $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 = VmwareEngineClient::privateCloudName( + '[PROJECT]', + '[LOCATION]', + '[PRIVATE_CLOUD]' + ); + + list_hcx_activation_keys_sample($formattedParent); +} +// [END vmwareengine_v1_generated_VmwareEngine_ListHcxActivationKeys_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_locations.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_locations.php new file mode 100644 index 000000000000..07ea876ceb92 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_locations.php @@ -0,0 +1,62 @@ +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 vmwareengine_v1_generated_VmwareEngine_ListLocations_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_logging_servers.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_logging_servers.php new file mode 100644 index 000000000000..84f00b97e71c --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_logging_servers.php @@ -0,0 +1,86 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $vmwareEngineClient->listLoggingServers($request); + + /** @var LoggingServer $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 = VmwareEngineClient::privateCloudName( + '[PROJECT]', + '[LOCATION]', + '[PRIVATE_CLOUD]' + ); + + list_logging_servers_sample($formattedParent); +} +// [END vmwareengine_v1_generated_VmwareEngine_ListLoggingServers_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_management_dns_zone_bindings.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_management_dns_zone_bindings.php new file mode 100644 index 000000000000..9f9c978459a8 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_management_dns_zone_bindings.php @@ -0,0 +1,85 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $vmwareEngineClient->listManagementDnsZoneBindings($request); + + /** @var ManagementDnsZoneBinding $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 = VmwareEngineClient::privateCloudName( + '[PROJECT]', + '[LOCATION]', + '[PRIVATE_CLOUD]' + ); + + list_management_dns_zone_bindings_sample($formattedParent); +} +// [END vmwareengine_v1_generated_VmwareEngine_ListManagementDnsZoneBindings_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_network_peerings.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_network_peerings.php new file mode 100644 index 000000000000..9935aac17f4c --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_network_peerings.php @@ -0,0 +1,80 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $vmwareEngineClient->listNetworkPeerings($request); + + /** @var NetworkPeering $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 = VmwareEngineClient::locationName('[PROJECT]', '[LOCATION]'); + + list_network_peerings_sample($formattedParent); +} +// [END vmwareengine_v1_generated_VmwareEngine_ListNetworkPeerings_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_network_policies.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_network_policies.php new file mode 100644 index 000000000000..4db6647a7f66 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_network_policies.php @@ -0,0 +1,79 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $vmwareEngineClient->listNetworkPolicies($request); + + /** @var NetworkPolicy $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 = VmwareEngineClient::locationName('[PROJECT]', '[LOCATION]'); + + list_network_policies_sample($formattedParent); +} +// [END vmwareengine_v1_generated_VmwareEngine_ListNetworkPolicies_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_node_types.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_node_types.php new file mode 100644 index 000000000000..210d752a2c2e --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_node_types.php @@ -0,0 +1,80 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $vmwareEngineClient->listNodeTypes($request); + + /** @var NodeType $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 = VmwareEngineClient::locationName('[PROJECT]', '[LOCATION]'); + + list_node_types_sample($formattedParent); +} +// [END vmwareengine_v1_generated_VmwareEngine_ListNodeTypes_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_nodes.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_nodes.php new file mode 100644 index 000000000000..1993040a46cd --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_nodes.php @@ -0,0 +1,85 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $vmwareEngineClient->listNodes($request); + + /** @var Node $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 = VmwareEngineClient::clusterName( + '[PROJECT]', + '[LOCATION]', + '[PRIVATE_CLOUD]', + '[CLUSTER]' + ); + + list_nodes_sample($formattedParent); +} +// [END vmwareengine_v1_generated_VmwareEngine_ListNodes_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_peering_routes.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_peering_routes.php new file mode 100644 index 000000000000..930f29bc3bbd --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_peering_routes.php @@ -0,0 +1,84 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $vmwareEngineClient->listPeeringRoutes($request); + + /** @var PeeringRoute $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 = VmwareEngineClient::networkPeeringName( + '[PROJECT]', + '[LOCATION]', + '[NETWORK_PEERING]' + ); + + list_peering_routes_sample($formattedParent); +} +// [END vmwareengine_v1_generated_VmwareEngine_ListPeeringRoutes_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_private_clouds.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_private_clouds.php new file mode 100644 index 000000000000..fdf995492516 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_private_clouds.php @@ -0,0 +1,80 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $vmwareEngineClient->listPrivateClouds($request); + + /** @var PrivateCloud $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 = VmwareEngineClient::locationName('[PROJECT]', '[LOCATION]'); + + list_private_clouds_sample($formattedParent); +} +// [END vmwareengine_v1_generated_VmwareEngine_ListPrivateClouds_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_private_connection_peering_routes.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_private_connection_peering_routes.php new file mode 100644 index 000000000000..323d453f543f --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_private_connection_peering_routes.php @@ -0,0 +1,83 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $vmwareEngineClient->listPrivateConnectionPeeringRoutes($request); + + /** @var PeeringRoute $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 = VmwareEngineClient::privateConnectionName( + '[PROJECT]', + '[LOCATION]', + '[PRIVATE_CONNECTION]' + ); + + list_private_connection_peering_routes_sample($formattedParent); +} +// [END vmwareengine_v1_generated_VmwareEngine_ListPrivateConnectionPeeringRoutes_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_private_connections.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_private_connections.php new file mode 100644 index 000000000000..48da41e3ed40 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_private_connections.php @@ -0,0 +1,79 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $vmwareEngineClient->listPrivateConnections($request); + + /** @var PrivateConnection $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 = VmwareEngineClient::locationName('[PROJECT]', '[LOCATION]'); + + list_private_connections_sample($formattedParent); +} +// [END vmwareengine_v1_generated_VmwareEngine_ListPrivateConnections_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_subnets.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_subnets.php new file mode 100644 index 000000000000..92c76d17c3eb --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_subnets.php @@ -0,0 +1,85 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $vmwareEngineClient->listSubnets($request); + + /** @var Subnet $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 = VmwareEngineClient::privateCloudName( + '[PROJECT]', + '[LOCATION]', + '[PRIVATE_CLOUD]' + ); + + list_subnets_sample($formattedParent); +} +// [END vmwareengine_v1_generated_VmwareEngine_ListSubnets_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_vmware_engine_networks.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_vmware_engine_networks.php new file mode 100644 index 000000000000..6d9b5d6c6211 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_vmware_engine_networks.php @@ -0,0 +1,79 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $vmwareEngineClient->listVmwareEngineNetworks($request); + + /** @var VmwareEngineNetwork $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 = VmwareEngineClient::locationName('[PROJECT]', '[LOCATION]'); + + list_vmware_engine_networks_sample($formattedParent); +} +// [END vmwareengine_v1_generated_VmwareEngine_ListVmwareEngineNetworks_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/repair_management_dns_zone_binding.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/repair_management_dns_zone_binding.php new file mode 100644 index 000000000000..c28b6ea8229c --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/repair_management_dns_zone_binding.php @@ -0,0 +1,93 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vmwareEngineClient->repairManagementDnsZoneBinding($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var ManagementDnsZoneBinding $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 = VmwareEngineClient::managementDnsZoneBindingName( + '[PROJECT]', + '[LOCATION]', + '[PRIVATE_CLOUD]', + '[MANAGEMENT_DNS_ZONE_BINDING]' + ); + + repair_management_dns_zone_binding_sample($formattedName); +} +// [END vmwareengine_v1_generated_VmwareEngine_RepairManagementDnsZoneBinding_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/reset_nsx_credentials.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/reset_nsx_credentials.php new file mode 100644 index 000000000000..0f53ba78c338 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/reset_nsx_credentials.php @@ -0,0 +1,92 @@ +setPrivateCloud($formattedPrivateCloud); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vmwareEngineClient->resetNsxCredentials($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var PrivateCloud $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 +{ + $formattedPrivateCloud = VmwareEngineClient::privateCloudName( + '[PROJECT]', + '[LOCATION]', + '[PRIVATE_CLOUD]' + ); + + reset_nsx_credentials_sample($formattedPrivateCloud); +} +// [END vmwareengine_v1_generated_VmwareEngine_ResetNsxCredentials_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/reset_vcenter_credentials.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/reset_vcenter_credentials.php new file mode 100644 index 000000000000..b65e64903ea9 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/reset_vcenter_credentials.php @@ -0,0 +1,92 @@ +setPrivateCloud($formattedPrivateCloud); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vmwareEngineClient->resetVcenterCredentials($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var PrivateCloud $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 +{ + $formattedPrivateCloud = VmwareEngineClient::privateCloudName( + '[PROJECT]', + '[LOCATION]', + '[PRIVATE_CLOUD]' + ); + + reset_vcenter_credentials_sample($formattedPrivateCloud); +} +// [END vmwareengine_v1_generated_VmwareEngine_ResetVcenterCredentials_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/revoke_dns_bind_permission.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/revoke_dns_bind_permission.php new file mode 100644 index 000000000000..a42c8d26fa98 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/revoke_dns_bind_permission.php @@ -0,0 +1,93 @@ +setName($formattedName) + ->setPrincipal($principal); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vmwareEngineClient->revokeDnsBindPermission($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var DnsBindPermission $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 = VmwareEngineClient::dnsBindPermissionName('[PROJECT]', '[LOCATION]'); + + revoke_dns_bind_permission_sample($formattedName); +} +// [END vmwareengine_v1_generated_VmwareEngine_RevokeDnsBindPermission_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/set_iam_policy.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/set_iam_policy.php new file mode 100644 index 000000000000..013961cc1ad4 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/set_iam_policy.php @@ -0,0 +1,77 @@ +setResource($resource) + ->setPolicy($policy); + + // Call the API and handle any network failures. + try { + /** @var Policy $response */ + $response = $vmwareEngineClient->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 vmwareengine_v1_generated_VmwareEngine_SetIamPolicy_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/show_nsx_credentials.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/show_nsx_credentials.php new file mode 100644 index 000000000000..000aa3d51ecb --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/show_nsx_credentials.php @@ -0,0 +1,80 @@ +setPrivateCloud($formattedPrivateCloud); + + // Call the API and handle any network failures. + try { + /** @var Credentials $response */ + $response = $vmwareEngineClient->showNsxCredentials($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 +{ + $formattedPrivateCloud = VmwareEngineClient::privateCloudName( + '[PROJECT]', + '[LOCATION]', + '[PRIVATE_CLOUD]' + ); + + show_nsx_credentials_sample($formattedPrivateCloud); +} +// [END vmwareengine_v1_generated_VmwareEngine_ShowNsxCredentials_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/show_vcenter_credentials.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/show_vcenter_credentials.php new file mode 100644 index 000000000000..c050051193c2 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/show_vcenter_credentials.php @@ -0,0 +1,80 @@ +setPrivateCloud($formattedPrivateCloud); + + // Call the API and handle any network failures. + try { + /** @var Credentials $response */ + $response = $vmwareEngineClient->showVcenterCredentials($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 +{ + $formattedPrivateCloud = VmwareEngineClient::privateCloudName( + '[PROJECT]', + '[LOCATION]', + '[PRIVATE_CLOUD]' + ); + + show_vcenter_credentials_sample($formattedPrivateCloud); +} +// [END vmwareengine_v1_generated_VmwareEngine_ShowVcenterCredentials_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/test_iam_permissions.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/test_iam_permissions.php new file mode 100644 index 000000000000..afe66a91da5c --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/test_iam_permissions.php @@ -0,0 +1,84 @@ +setResource($resource) + ->setPermissions($permissions); + + // Call the API and handle any network failures. + try { + /** @var TestIamPermissionsResponse $response */ + $response = $vmwareEngineClient->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 vmwareengine_v1_generated_VmwareEngine_TestIamPermissions_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/undelete_private_cloud.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/undelete_private_cloud.php new file mode 100644 index 000000000000..3163b084b6e3 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/undelete_private_cloud.php @@ -0,0 +1,90 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vmwareEngineClient->undeletePrivateCloud($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var PrivateCloud $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 = VmwareEngineClient::privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); + + undelete_private_cloud_sample($formattedName); +} +// [END vmwareengine_v1_generated_VmwareEngine_UndeletePrivateCloud_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_cluster.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_cluster.php new file mode 100644 index 000000000000..8c772d60d635 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_cluster.php @@ -0,0 +1,82 @@ +setNodeTypeConfigs($clusterNodeTypeConfigs); + $request = (new UpdateClusterRequest()) + ->setUpdateMask($updateMask) + ->setCluster($cluster); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vmwareEngineClient->updateCluster($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var Cluster $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 vmwareengine_v1_generated_VmwareEngine_UpdateCluster_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_dns_forwarding.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_dns_forwarding.php new file mode 100644 index 000000000000..ec1f793a6d48 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_dns_forwarding.php @@ -0,0 +1,101 @@ +setDomain($dnsForwardingForwardingRulesDomain) + ->setNameServers($dnsForwardingForwardingRulesNameServers); + $dnsForwardingForwardingRules = [$forwardingRule,]; + $dnsForwarding = (new DnsForwarding()) + ->setForwardingRules($dnsForwardingForwardingRules); + $updateMask = new FieldMask(); + $request = (new UpdateDnsForwardingRequest()) + ->setDnsForwarding($dnsForwarding) + ->setUpdateMask($updateMask); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vmwareEngineClient->updateDnsForwarding($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var DnsForwarding $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 +{ + $dnsForwardingForwardingRulesDomain = '[DOMAIN]'; + $dnsForwardingForwardingRulesNameServersElement = '[NAME_SERVERS]'; + + update_dns_forwarding_sample( + $dnsForwardingForwardingRulesDomain, + $dnsForwardingForwardingRulesNameServersElement + ); +} +// [END vmwareengine_v1_generated_VmwareEngine_UpdateDnsForwarding_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_external_access_rule.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_external_access_rule.php new file mode 100644 index 000000000000..e396f90fc681 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_external_access_rule.php @@ -0,0 +1,75 @@ +setUpdateMask($updateMask) + ->setExternalAccessRule($externalAccessRule); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vmwareEngineClient->updateExternalAccessRule($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var ExternalAccessRule $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 vmwareengine_v1_generated_VmwareEngine_UpdateExternalAccessRule_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_external_address.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_external_address.php new file mode 100644 index 000000000000..248968f2a981 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_external_address.php @@ -0,0 +1,80 @@ +setUpdateMask($updateMask) + ->setExternalAddress($externalAddress); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vmwareEngineClient->updateExternalAddress($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var ExternalAddress $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 vmwareengine_v1_generated_VmwareEngine_UpdateExternalAddress_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_logging_server.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_logging_server.php new file mode 100644 index 000000000000..165fcdd8f615 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_logging_server.php @@ -0,0 +1,110 @@ +setHostname($loggingServerHostname) + ->setPort($loggingServerPort) + ->setProtocol($loggingServerProtocol) + ->setSourceType($loggingServerSourceType); + $request = (new UpdateLoggingServerRequest()) + ->setUpdateMask($updateMask) + ->setLoggingServer($loggingServer); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vmwareEngineClient->updateLoggingServer($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var LoggingServer $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 +{ + $loggingServerHostname = '[HOSTNAME]'; + $loggingServerPort = 0; + $loggingServerProtocol = Protocol::PROTOCOL_UNSPECIFIED; + $loggingServerSourceType = SourceType::SOURCE_TYPE_UNSPECIFIED; + + update_logging_server_sample( + $loggingServerHostname, + $loggingServerPort, + $loggingServerProtocol, + $loggingServerSourceType + ); +} +// [END vmwareengine_v1_generated_VmwareEngine_UpdateLoggingServer_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_management_dns_zone_binding.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_management_dns_zone_binding.php new file mode 100644 index 000000000000..66d0f4ec9867 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_management_dns_zone_binding.php @@ -0,0 +1,75 @@ +setUpdateMask($updateMask) + ->setManagementDnsZoneBinding($managementDnsZoneBinding); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vmwareEngineClient->updateManagementDnsZoneBinding($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var ManagementDnsZoneBinding $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 vmwareengine_v1_generated_VmwareEngine_UpdateManagementDnsZoneBinding_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_network_peering.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_network_peering.php new file mode 100644 index 000000000000..2777034651b3 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_network_peering.php @@ -0,0 +1,118 @@ +setPeerNetwork($networkPeeringPeerNetwork) + ->setPeerNetworkType($networkPeeringPeerNetworkType) + ->setVmwareEngineNetwork($formattedNetworkPeeringVmwareEngineNetwork); + $updateMask = new FieldMask(); + $request = (new UpdateNetworkPeeringRequest()) + ->setNetworkPeering($networkPeering) + ->setUpdateMask($updateMask); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vmwareEngineClient->updateNetworkPeering($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var NetworkPeering $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 +{ + $networkPeeringPeerNetwork = '[PEER_NETWORK]'; + $networkPeeringPeerNetworkType = PeerNetworkType::PEER_NETWORK_TYPE_UNSPECIFIED; + $formattedNetworkPeeringVmwareEngineNetwork = VmwareEngineClient::vmwareEngineNetworkName( + '[PROJECT]', + '[LOCATION]', + '[VMWARE_ENGINE_NETWORK]' + ); + + update_network_peering_sample( + $networkPeeringPeerNetwork, + $networkPeeringPeerNetworkType, + $formattedNetworkPeeringVmwareEngineNetwork + ); +} +// [END vmwareengine_v1_generated_VmwareEngine_UpdateNetworkPeering_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_network_policy.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_network_policy.php new file mode 100644 index 000000000000..e9f9c71536b2 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_network_policy.php @@ -0,0 +1,101 @@ +setEdgeServicesCidr($networkPolicyEdgeServicesCidr); + $updateMask = new FieldMask(); + $request = (new UpdateNetworkPolicyRequest()) + ->setNetworkPolicy($networkPolicy) + ->setUpdateMask($updateMask); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vmwareEngineClient->updateNetworkPolicy($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var NetworkPolicy $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 +{ + $networkPolicyEdgeServicesCidr = '[EDGE_SERVICES_CIDR]'; + + update_network_policy_sample($networkPolicyEdgeServicesCidr); +} +// [END vmwareengine_v1_generated_VmwareEngine_UpdateNetworkPolicy_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_private_cloud.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_private_cloud.php new file mode 100644 index 000000000000..aec482998832 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_private_cloud.php @@ -0,0 +1,118 @@ +setManagementCidr($privateCloudNetworkConfigManagementCidr); + $privateCloudManagementClusterNodeTypeConfigs = []; + $privateCloudManagementCluster = (new ManagementCluster()) + ->setClusterId($privateCloudManagementClusterClusterId) + ->setNodeTypeConfigs($privateCloudManagementClusterNodeTypeConfigs); + $privateCloud = (new PrivateCloud()) + ->setNetworkConfig($privateCloudNetworkConfig) + ->setManagementCluster($privateCloudManagementCluster); + $updateMask = new FieldMask(); + $request = (new UpdatePrivateCloudRequest()) + ->setPrivateCloud($privateCloud) + ->setUpdateMask($updateMask); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vmwareEngineClient->updatePrivateCloud($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var PrivateCloud $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 +{ + $privateCloudNetworkConfigManagementCidr = '[MANAGEMENT_CIDR]'; + $privateCloudManagementClusterClusterId = '[CLUSTER_ID]'; + + update_private_cloud_sample( + $privateCloudNetworkConfigManagementCidr, + $privateCloudManagementClusterClusterId + ); +} +// [END vmwareengine_v1_generated_VmwareEngine_UpdatePrivateCloud_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_private_connection.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_private_connection.php new file mode 100644 index 000000000000..e8b68cb69618 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_private_connection.php @@ -0,0 +1,129 @@ +setVmwareEngineNetwork($formattedPrivateConnectionVmwareEngineNetwork) + ->setType($privateConnectionType) + ->setServiceNetwork($formattedPrivateConnectionServiceNetwork); + $updateMask = new FieldMask(); + $request = (new UpdatePrivateConnectionRequest()) + ->setPrivateConnection($privateConnection) + ->setUpdateMask($updateMask); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vmwareEngineClient->updatePrivateConnection($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var PrivateConnection $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 +{ + $formattedPrivateConnectionVmwareEngineNetwork = VmwareEngineClient::vmwareEngineNetworkName( + '[PROJECT]', + '[LOCATION]', + '[VMWARE_ENGINE_NETWORK]' + ); + $privateConnectionType = Type::TYPE_UNSPECIFIED; + $formattedPrivateConnectionServiceNetwork = VmwareEngineClient::networkName( + '[PROJECT]', + '[NETWORK]' + ); + + update_private_connection_sample( + $formattedPrivateConnectionVmwareEngineNetwork, + $privateConnectionType, + $formattedPrivateConnectionServiceNetwork + ); +} +// [END vmwareengine_v1_generated_VmwareEngine_UpdatePrivateConnection_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_subnet.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_subnet.php new file mode 100644 index 000000000000..36369c95e426 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_subnet.php @@ -0,0 +1,79 @@ +setUpdateMask($updateMask) + ->setSubnet($subnet); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vmwareEngineClient->updateSubnet($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var Subnet $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 vmwareengine_v1_generated_VmwareEngine_UpdateSubnet_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_vmware_engine_network.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_vmware_engine_network.php new file mode 100644 index 000000000000..c2fac6587ec0 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_vmware_engine_network.php @@ -0,0 +1,90 @@ +setType($vmwareEngineNetworkType); + $updateMask = new FieldMask(); + $request = (new UpdateVmwareEngineNetworkRequest()) + ->setVmwareEngineNetwork($vmwareEngineNetwork) + ->setUpdateMask($updateMask); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $vmwareEngineClient->updateVmwareEngineNetwork($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var VmwareEngineNetwork $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 +{ + $vmwareEngineNetworkType = Type::TYPE_UNSPECIFIED; + + update_vmware_engine_network_sample($vmwareEngineNetworkType); +} +// [END vmwareengine_v1_generated_VmwareEngine_UpdateVmwareEngineNetwork_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/src/V1/Client/VmwareEngineClient.php b/owl-bot-staging/VmwareEngine/v1/src/V1/Client/VmwareEngineClient.php new file mode 100644 index 000000000000..a3ce75d15f20 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/src/V1/Client/VmwareEngineClient.php @@ -0,0 +1,3013 @@ + createClusterAsync(CreateClusterRequest $request, array $optionalArgs = []) + * @method PromiseInterface createExternalAccessRuleAsync(CreateExternalAccessRuleRequest $request, array $optionalArgs = []) + * @method PromiseInterface createExternalAddressAsync(CreateExternalAddressRequest $request, array $optionalArgs = []) + * @method PromiseInterface createHcxActivationKeyAsync(CreateHcxActivationKeyRequest $request, array $optionalArgs = []) + * @method PromiseInterface createLoggingServerAsync(CreateLoggingServerRequest $request, array $optionalArgs = []) + * @method PromiseInterface createManagementDnsZoneBindingAsync(CreateManagementDnsZoneBindingRequest $request, array $optionalArgs = []) + * @method PromiseInterface createNetworkPeeringAsync(CreateNetworkPeeringRequest $request, array $optionalArgs = []) + * @method PromiseInterface createNetworkPolicyAsync(CreateNetworkPolicyRequest $request, array $optionalArgs = []) + * @method PromiseInterface createPrivateCloudAsync(CreatePrivateCloudRequest $request, array $optionalArgs = []) + * @method PromiseInterface createPrivateConnectionAsync(CreatePrivateConnectionRequest $request, array $optionalArgs = []) + * @method PromiseInterface createVmwareEngineNetworkAsync(CreateVmwareEngineNetworkRequest $request, array $optionalArgs = []) + * @method PromiseInterface deleteClusterAsync(DeleteClusterRequest $request, array $optionalArgs = []) + * @method PromiseInterface deleteExternalAccessRuleAsync(DeleteExternalAccessRuleRequest $request, array $optionalArgs = []) + * @method PromiseInterface deleteExternalAddressAsync(DeleteExternalAddressRequest $request, array $optionalArgs = []) + * @method PromiseInterface deleteLoggingServerAsync(DeleteLoggingServerRequest $request, array $optionalArgs = []) + * @method PromiseInterface deleteManagementDnsZoneBindingAsync(DeleteManagementDnsZoneBindingRequest $request, array $optionalArgs = []) + * @method PromiseInterface deleteNetworkPeeringAsync(DeleteNetworkPeeringRequest $request, array $optionalArgs = []) + * @method PromiseInterface deleteNetworkPolicyAsync(DeleteNetworkPolicyRequest $request, array $optionalArgs = []) + * @method PromiseInterface deletePrivateCloudAsync(DeletePrivateCloudRequest $request, array $optionalArgs = []) + * @method PromiseInterface deletePrivateConnectionAsync(DeletePrivateConnectionRequest $request, array $optionalArgs = []) + * @method PromiseInterface deleteVmwareEngineNetworkAsync(DeleteVmwareEngineNetworkRequest $request, array $optionalArgs = []) + * @method PromiseInterface fetchNetworkPolicyExternalAddressesAsync(FetchNetworkPolicyExternalAddressesRequest $request, array $optionalArgs = []) + * @method PromiseInterface getClusterAsync(GetClusterRequest $request, array $optionalArgs = []) + * @method PromiseInterface getDnsBindPermissionAsync(GetDnsBindPermissionRequest $request, array $optionalArgs = []) + * @method PromiseInterface getDnsForwardingAsync(GetDnsForwardingRequest $request, array $optionalArgs = []) + * @method PromiseInterface getExternalAccessRuleAsync(GetExternalAccessRuleRequest $request, array $optionalArgs = []) + * @method PromiseInterface getExternalAddressAsync(GetExternalAddressRequest $request, array $optionalArgs = []) + * @method PromiseInterface getHcxActivationKeyAsync(GetHcxActivationKeyRequest $request, array $optionalArgs = []) + * @method PromiseInterface getLoggingServerAsync(GetLoggingServerRequest $request, array $optionalArgs = []) + * @method PromiseInterface getManagementDnsZoneBindingAsync(GetManagementDnsZoneBindingRequest $request, array $optionalArgs = []) + * @method PromiseInterface getNetworkPeeringAsync(GetNetworkPeeringRequest $request, array $optionalArgs = []) + * @method PromiseInterface getNetworkPolicyAsync(GetNetworkPolicyRequest $request, array $optionalArgs = []) + * @method PromiseInterface getNodeAsync(GetNodeRequest $request, array $optionalArgs = []) + * @method PromiseInterface getNodeTypeAsync(GetNodeTypeRequest $request, array $optionalArgs = []) + * @method PromiseInterface getPrivateCloudAsync(GetPrivateCloudRequest $request, array $optionalArgs = []) + * @method PromiseInterface getPrivateConnectionAsync(GetPrivateConnectionRequest $request, array $optionalArgs = []) + * @method PromiseInterface getSubnetAsync(GetSubnetRequest $request, array $optionalArgs = []) + * @method PromiseInterface getVmwareEngineNetworkAsync(GetVmwareEngineNetworkRequest $request, array $optionalArgs = []) + * @method PromiseInterface grantDnsBindPermissionAsync(GrantDnsBindPermissionRequest $request, array $optionalArgs = []) + * @method PromiseInterface listClustersAsync(ListClustersRequest $request, array $optionalArgs = []) + * @method PromiseInterface listExternalAccessRulesAsync(ListExternalAccessRulesRequest $request, array $optionalArgs = []) + * @method PromiseInterface listExternalAddressesAsync(ListExternalAddressesRequest $request, array $optionalArgs = []) + * @method PromiseInterface listHcxActivationKeysAsync(ListHcxActivationKeysRequest $request, array $optionalArgs = []) + * @method PromiseInterface listLoggingServersAsync(ListLoggingServersRequest $request, array $optionalArgs = []) + * @method PromiseInterface listManagementDnsZoneBindingsAsync(ListManagementDnsZoneBindingsRequest $request, array $optionalArgs = []) + * @method PromiseInterface listNetworkPeeringsAsync(ListNetworkPeeringsRequest $request, array $optionalArgs = []) + * @method PromiseInterface listNetworkPoliciesAsync(ListNetworkPoliciesRequest $request, array $optionalArgs = []) + * @method PromiseInterface listNodeTypesAsync(ListNodeTypesRequest $request, array $optionalArgs = []) + * @method PromiseInterface listNodesAsync(ListNodesRequest $request, array $optionalArgs = []) + * @method PromiseInterface listPeeringRoutesAsync(ListPeeringRoutesRequest $request, array $optionalArgs = []) + * @method PromiseInterface listPrivateCloudsAsync(ListPrivateCloudsRequest $request, array $optionalArgs = []) + * @method PromiseInterface listPrivateConnectionPeeringRoutesAsync(ListPrivateConnectionPeeringRoutesRequest $request, array $optionalArgs = []) + * @method PromiseInterface listPrivateConnectionsAsync(ListPrivateConnectionsRequest $request, array $optionalArgs = []) + * @method PromiseInterface listSubnetsAsync(ListSubnetsRequest $request, array $optionalArgs = []) + * @method PromiseInterface listVmwareEngineNetworksAsync(ListVmwareEngineNetworksRequest $request, array $optionalArgs = []) + * @method PromiseInterface repairManagementDnsZoneBindingAsync(RepairManagementDnsZoneBindingRequest $request, array $optionalArgs = []) + * @method PromiseInterface resetNsxCredentialsAsync(ResetNsxCredentialsRequest $request, array $optionalArgs = []) + * @method PromiseInterface resetVcenterCredentialsAsync(ResetVcenterCredentialsRequest $request, array $optionalArgs = []) + * @method PromiseInterface revokeDnsBindPermissionAsync(RevokeDnsBindPermissionRequest $request, array $optionalArgs = []) + * @method PromiseInterface showNsxCredentialsAsync(ShowNsxCredentialsRequest $request, array $optionalArgs = []) + * @method PromiseInterface showVcenterCredentialsAsync(ShowVcenterCredentialsRequest $request, array $optionalArgs = []) + * @method PromiseInterface undeletePrivateCloudAsync(UndeletePrivateCloudRequest $request, array $optionalArgs = []) + * @method PromiseInterface updateClusterAsync(UpdateClusterRequest $request, array $optionalArgs = []) + * @method PromiseInterface updateDnsForwardingAsync(UpdateDnsForwardingRequest $request, array $optionalArgs = []) + * @method PromiseInterface updateExternalAccessRuleAsync(UpdateExternalAccessRuleRequest $request, array $optionalArgs = []) + * @method PromiseInterface updateExternalAddressAsync(UpdateExternalAddressRequest $request, array $optionalArgs = []) + * @method PromiseInterface updateLoggingServerAsync(UpdateLoggingServerRequest $request, array $optionalArgs = []) + * @method PromiseInterface updateManagementDnsZoneBindingAsync(UpdateManagementDnsZoneBindingRequest $request, array $optionalArgs = []) + * @method PromiseInterface updateNetworkPeeringAsync(UpdateNetworkPeeringRequest $request, array $optionalArgs = []) + * @method PromiseInterface updateNetworkPolicyAsync(UpdateNetworkPolicyRequest $request, array $optionalArgs = []) + * @method PromiseInterface updatePrivateCloudAsync(UpdatePrivateCloudRequest $request, array $optionalArgs = []) + * @method PromiseInterface updatePrivateConnectionAsync(UpdatePrivateConnectionRequest $request, array $optionalArgs = []) + * @method PromiseInterface updateSubnetAsync(UpdateSubnetRequest $request, array $optionalArgs = []) + * @method PromiseInterface updateVmwareEngineNetworkAsync(UpdateVmwareEngineNetworkRequest $request, array $optionalArgs = []) + * @method PromiseInterface getLocationAsync(GetLocationRequest $request, array $optionalArgs = []) + * @method PromiseInterface listLocationsAsync(ListLocationsRequest $request, array $optionalArgs = []) + * @method PromiseInterface getIamPolicyAsync(GetIamPolicyRequest $request, array $optionalArgs = []) + * @method PromiseInterface setIamPolicyAsync(SetIamPolicyRequest $request, array $optionalArgs = []) + * @method PromiseInterface testIamPermissionsAsync(TestIamPermissionsRequest $request, array $optionalArgs = []) + */ +final class VmwareEngineClient +{ + use GapicClientTrait; + use ResourceHelperTrait; + + /** The name of the service. */ + private const SERVICE_NAME = 'google.cloud.vmwareengine.v1.VmwareEngine'; + + /** + * The default address of the service. + * + * @deprecated SERVICE_ADDRESS_TEMPLATE should be used instead. + */ + private const SERVICE_ADDRESS = 'vmwareengine.googleapis.com'; + + /** The address template of the service. */ + private const SERVICE_ADDRESS_TEMPLATE = 'vmwareengine.UNIVERSE_DOMAIN'; + + /** The default port of the service. */ + private const DEFAULT_SERVICE_PORT = 443; + + /** The name of the code generator, to be included in the agent header. */ + private const CODEGEN_NAME = 'gapic'; + + /** The default scopes required by the service. */ + public static $serviceScopes = [ + 'https://www.googleapis.com/auth/cloud-platform', + ]; + + private $operationsClient; + + private static function getClientDefaults() + { + return [ + 'serviceName' => self::SERVICE_NAME, + 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, + 'clientConfig' => __DIR__ . '/../resources/vmware_engine_client_config.json', + 'descriptorsConfigPath' => __DIR__ . '/../resources/vmware_engine_descriptor_config.php', + 'gcpApiConfigPath' => __DIR__ . '/../resources/vmware_engine_grpc_config.json', + 'credentialsConfig' => [ + 'defaultScopes' => self::$serviceScopes, + ], + 'transportConfig' => [ + 'rest' => [ + 'restClientConfigPath' => __DIR__ . '/../resources/vmware_engine_rest_client_config.php', + ], + ], + ]; + } + + /** + * 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 = $this->descriptors[$methodName]['longRunning'] ?? []; + $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); + $operation->reload(); + return $operation; + } + + /** + * Create the default operation client for the service. + * + * @param array $options ClientOptions for the client. + * + * @return OperationsClient + */ + private function createOperationsClient(array $options) + { + // Unset client-specific configuration options + unset($options['serviceName'], $options['clientConfig'], $options['descriptorsConfigPath']); + + if (isset($options['operationsClient'])) { + return $options['operationsClient']; + } + + return new OperationsClient($options); + } + + /** + * Formats a string containing the fully-qualified path to represent a cluster + * resource. + * + * @param string $project + * @param string $location + * @param string $privateCloud + * @param string $cluster + * + * @return string The formatted cluster resource. + */ + public static function clusterName(string $project, string $location, string $privateCloud, string $cluster): string + { + return self::getPathTemplate('cluster')->render([ + 'project' => $project, + 'location' => $location, + 'private_cloud' => $privateCloud, + 'cluster' => $cluster, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * dns_bind_permission resource. + * + * @param string $project + * @param string $location + * + * @return string The formatted dns_bind_permission resource. + */ + public static function dnsBindPermissionName(string $project, string $location): string + { + return self::getPathTemplate('dnsBindPermission')->render([ + 'project' => $project, + 'location' => $location, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * dns_forwarding resource. + * + * @param string $project + * @param string $location + * @param string $privateCloud + * + * @return string The formatted dns_forwarding resource. + */ + public static function dnsForwardingName(string $project, string $location, string $privateCloud): string + { + return self::getPathTemplate('dnsForwarding')->render([ + 'project' => $project, + 'location' => $location, + 'private_cloud' => $privateCloud, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * external_access_rule resource. + * + * @param string $project + * @param string $location + * @param string $networkPolicy + * @param string $externalAccessRule + * + * @return string The formatted external_access_rule resource. + */ + public static function externalAccessRuleName(string $project, string $location, string $networkPolicy, string $externalAccessRule): string + { + return self::getPathTemplate('externalAccessRule')->render([ + 'project' => $project, + 'location' => $location, + 'network_policy' => $networkPolicy, + 'external_access_rule' => $externalAccessRule, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * external_address resource. + * + * @param string $project + * @param string $location + * @param string $privateCloud + * @param string $externalAddress + * + * @return string The formatted external_address resource. + */ + public static function externalAddressName(string $project, string $location, string $privateCloud, string $externalAddress): string + { + return self::getPathTemplate('externalAddress')->render([ + 'project' => $project, + 'location' => $location, + 'private_cloud' => $privateCloud, + 'external_address' => $externalAddress, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * hcx_activation_key resource. + * + * @param string $project + * @param string $location + * @param string $privateCloud + * @param string $hcxActivationKey + * + * @return string The formatted hcx_activation_key resource. + */ + public static function hcxActivationKeyName(string $project, string $location, string $privateCloud, string $hcxActivationKey): string + { + return self::getPathTemplate('hcxActivationKey')->render([ + 'project' => $project, + 'location' => $location, + 'private_cloud' => $privateCloud, + 'hcx_activation_key' => $hcxActivationKey, + ]); + } + + /** + * 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(string $project, string $location): string + { + return self::getPathTemplate('location')->render([ + 'project' => $project, + 'location' => $location, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * logging_server resource. + * + * @param string $project + * @param string $location + * @param string $privateCloud + * @param string $loggingServer + * + * @return string The formatted logging_server resource. + */ + public static function loggingServerName(string $project, string $location, string $privateCloud, string $loggingServer): string + { + return self::getPathTemplate('loggingServer')->render([ + 'project' => $project, + 'location' => $location, + 'private_cloud' => $privateCloud, + 'logging_server' => $loggingServer, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * management_dns_zone_binding resource. + * + * @param string $project + * @param string $location + * @param string $privateCloud + * @param string $managementDnsZoneBinding + * + * @return string The formatted management_dns_zone_binding resource. + */ + public static function managementDnsZoneBindingName(string $project, string $location, string $privateCloud, string $managementDnsZoneBinding): string + { + return self::getPathTemplate('managementDnsZoneBinding')->render([ + 'project' => $project, + 'location' => $location, + 'private_cloud' => $privateCloud, + 'management_dns_zone_binding' => $managementDnsZoneBinding, + ]); + } + + /** + * 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(string $project, string $network): string + { + return self::getPathTemplate('network')->render([ + 'project' => $project, + 'network' => $network, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * network_peering resource. + * + * @param string $project + * @param string $location + * @param string $networkPeering + * + * @return string The formatted network_peering resource. + */ + public static function networkPeeringName(string $project, string $location, string $networkPeering): string + { + return self::getPathTemplate('networkPeering')->render([ + 'project' => $project, + 'location' => $location, + 'network_peering' => $networkPeering, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * network_policy resource. + * + * @param string $project + * @param string $location + * @param string $networkPolicy + * + * @return string The formatted network_policy resource. + */ + public static function networkPolicyName(string $project, string $location, string $networkPolicy): string + { + return self::getPathTemplate('networkPolicy')->render([ + 'project' => $project, + 'location' => $location, + 'network_policy' => $networkPolicy, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a node + * resource. + * + * @param string $project + * @param string $location + * @param string $privateCloud + * @param string $cluster + * @param string $node + * + * @return string The formatted node resource. + */ + public static function nodeName(string $project, string $location, string $privateCloud, string $cluster, string $node): string + { + return self::getPathTemplate('node')->render([ + 'project' => $project, + 'location' => $location, + 'private_cloud' => $privateCloud, + 'cluster' => $cluster, + 'node' => $node, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a node_type + * resource. + * + * @param string $project + * @param string $location + * @param string $nodeType + * + * @return string The formatted node_type resource. + */ + public static function nodeTypeName(string $project, string $location, string $nodeType): string + { + return self::getPathTemplate('nodeType')->render([ + 'project' => $project, + 'location' => $location, + 'node_type' => $nodeType, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * private_cloud resource. + * + * @param string $project + * @param string $location + * @param string $privateCloud + * + * @return string The formatted private_cloud resource. + */ + public static function privateCloudName(string $project, string $location, string $privateCloud): string + { + return self::getPathTemplate('privateCloud')->render([ + 'project' => $project, + 'location' => $location, + 'private_cloud' => $privateCloud, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * private_connection resource. + * + * @param string $project + * @param string $location + * @param string $privateConnection + * + * @return string The formatted private_connection resource. + */ + public static function privateConnectionName(string $project, string $location, string $privateConnection): string + { + return self::getPathTemplate('privateConnection')->render([ + 'project' => $project, + 'location' => $location, + 'private_connection' => $privateConnection, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a subnet + * resource. + * + * @param string $project + * @param string $location + * @param string $privateCloud + * @param string $subnet + * + * @return string The formatted subnet resource. + */ + public static function subnetName(string $project, string $location, string $privateCloud, string $subnet): string + { + return self::getPathTemplate('subnet')->render([ + 'project' => $project, + 'location' => $location, + 'private_cloud' => $privateCloud, + 'subnet' => $subnet, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a + * vmware_engine_network resource. + * + * @param string $project + * @param string $location + * @param string $vmwareEngineNetwork + * + * @return string The formatted vmware_engine_network resource. + */ + public static function vmwareEngineNetworkName(string $project, string $location, string $vmwareEngineNetwork): string + { + return self::getPathTemplate('vmwareEngineNetwork')->render([ + 'project' => $project, + 'location' => $location, + 'vmware_engine_network' => $vmwareEngineNetwork, + ]); + } + + /** + * Parses a formatted name string and returns an associative array of the components in the name. + * The following name formats are supported: + * Template: Pattern + * - cluster: projects/{project}/locations/{location}/privateClouds/{private_cloud}/clusters/{cluster} + * - dnsBindPermission: projects/{project}/locations/{location}/dnsBindPermission + * - dnsForwarding: projects/{project}/locations/{location}/privateClouds/{private_cloud}/dnsForwarding + * - externalAccessRule: projects/{project}/locations/{location}/networkPolicies/{network_policy}/externalAccessRules/{external_access_rule} + * - externalAddress: projects/{project}/locations/{location}/privateClouds/{private_cloud}/externalAddresses/{external_address} + * - hcxActivationKey: projects/{project}/locations/{location}/privateClouds/{private_cloud}/hcxActivationKeys/{hcx_activation_key} + * - location: projects/{project}/locations/{location} + * - loggingServer: projects/{project}/locations/{location}/privateClouds/{private_cloud}/loggingServers/{logging_server} + * - managementDnsZoneBinding: projects/{project}/locations/{location}/privateClouds/{private_cloud}/managementDnsZoneBindings/{management_dns_zone_binding} + * - network: projects/{project}/global/networks/{network} + * - networkPeering: projects/{project}/locations/{location}/networkPeerings/{network_peering} + * - networkPolicy: projects/{project}/locations/{location}/networkPolicies/{network_policy} + * - node: projects/{project}/locations/{location}/privateClouds/{private_cloud}/clusters/{cluster}/nodes/{node} + * - nodeType: projects/{project}/locations/{location}/nodeTypes/{node_type} + * - privateCloud: projects/{project}/locations/{location}/privateClouds/{private_cloud} + * - privateConnection: projects/{project}/locations/{location}/privateConnections/{private_connection} + * - subnet: projects/{project}/locations/{location}/privateClouds/{private_cloud}/subnets/{subnet} + * - vmwareEngineNetwork: projects/{project}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network} + * + * 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(string $formattedName, ?string $template = null): array + { + return self::parseFormattedName($formattedName, $template); + } + + /** + * Constructor. + * + * @param array|ClientOptions $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 'vmwareengine.googleapis.com:443'. + * @type FetchAuthTokenInterface|CredentialsWrapper $credentials + * This option should only be used with a pre-constructed + * {@see FetchAuthTokenInterface} or {@see CredentialsWrapper} object. Note that + * when one of these objects are provided, any settings in $credentialsConfig will + * be ignored. + * **Important**: If you are providing a path to a credentials file, or a decoded + * credentials file as a PHP array, this usage is now DEPRECATED. Providing an + * unvalidated credential configuration to Google APIs can compromise the security + * of your systems and data. It is recommended to create the credentials explicitly + * ``` + * use Google\Auth\Credentials\ServiceAccountCredentials; + * use Google\Cloud\VmwareEngine\V1\VmwareEngineClient; + * $creds = new ServiceAccountCredentials($scopes, $json); + * $options = new VmwareEngineClient(['credentials' => $creds]); + * ``` + * {@see + * https://cloud.google.com/docs/authentication/external/externally-sourced-credentials} + * @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. + * @type false|LoggerInterface $logger + * A PSR-3 compliant logger. If set to false, logging is disabled, ignoring the + * 'GOOGLE_SDK_PHP_LOGGING' environment flag + * @type string $universeDomain + * The service domain for the client. Defaults to 'googleapis.com'. + * } + * + * @throws ValidationException + */ + public function __construct(array|ClientOptions $options = []) + { + $clientOptions = $this->buildClientOptions($options); + $this->setClientOptions($clientOptions); + $this->operationsClient = $this->createOperationsClient($clientOptions); + } + + /** Handles execution of the async variants for each documented method. */ + public function __call($method, $args) + { + if (substr($method, -5) !== 'Async') { + trigger_error('Call to undefined method ' . __CLASS__ . "::$method()", E_USER_ERROR); + } + + array_unshift($args, substr($method, 0, -5)); + return call_user_func_array([$this, 'startAsyncCall'], $args); + } + + /** + * Creates a new cluster in a given private cloud. + * Creating a new cluster provides additional nodes for + * use in the parent private cloud and requires sufficient [node + * quota](https://cloud.google.com/vmware-engine/quotas). + * + * The async variant is {@see VmwareEngineClient::createClusterAsync()} . + * + * @example samples/V1/VmwareEngineClient/create_cluster.php + * + * @param CreateClusterRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function createCluster(CreateClusterRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('CreateCluster', $request, $callOptions)->wait(); + } + + /** + * Creates a new external access rule in a given network policy. + * + * The async variant is {@see VmwareEngineClient::createExternalAccessRuleAsync()} + * . + * + * @example samples/V1/VmwareEngineClient/create_external_access_rule.php + * + * @param CreateExternalAccessRuleRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function createExternalAccessRule(CreateExternalAccessRuleRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('CreateExternalAccessRule', $request, $callOptions)->wait(); + } + + /** + * Creates a new `ExternalAddress` resource in a given private cloud. The + * network policy that corresponds to the private cloud must have the external + * IP address network service enabled (`NetworkPolicy.external_ip`). + * + * The async variant is {@see VmwareEngineClient::createExternalAddressAsync()} . + * + * @example samples/V1/VmwareEngineClient/create_external_address.php + * + * @param CreateExternalAddressRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function createExternalAddress(CreateExternalAddressRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('CreateExternalAddress', $request, $callOptions)->wait(); + } + + /** + * Creates a new HCX activation key in a given private cloud. + * + * The async variant is {@see VmwareEngineClient::createHcxActivationKeyAsync()} . + * + * @example samples/V1/VmwareEngineClient/create_hcx_activation_key.php + * + * @param CreateHcxActivationKeyRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function createHcxActivationKey(CreateHcxActivationKeyRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('CreateHcxActivationKey', $request, $callOptions)->wait(); + } + + /** + * Create a new logging server for a given private cloud. + * + * The async variant is {@see VmwareEngineClient::createLoggingServerAsync()} . + * + * @example samples/V1/VmwareEngineClient/create_logging_server.php + * + * @param CreateLoggingServerRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function createLoggingServer(CreateLoggingServerRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('CreateLoggingServer', $request, $callOptions)->wait(); + } + + /** + * Creates a new `ManagementDnsZoneBinding` resource in a private cloud. + * This RPC creates the DNS binding and the resource that represents the + * DNS binding of the consumer VPC network to the management DNS zone. A + * management DNS zone is the Cloud DNS cross-project binding zone that + * VMware Engine creates for each private cloud. It contains FQDNs and + * corresponding IP addresses for the private cloud's ESXi hosts and + * management VM appliances like vCenter and NSX Manager. + * + * The async variant is + * {@see VmwareEngineClient::createManagementDnsZoneBindingAsync()} . + * + * @example samples/V1/VmwareEngineClient/create_management_dns_zone_binding.php + * + * @param CreateManagementDnsZoneBindingRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function createManagementDnsZoneBinding(CreateManagementDnsZoneBindingRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('CreateManagementDnsZoneBinding', $request, $callOptions)->wait(); + } + + /** + * Creates a new network peering between the peer network and VMware Engine + * network provided in a `NetworkPeering` resource. NetworkPeering is a + * global resource and location can only be global. + * + * The async variant is {@see VmwareEngineClient::createNetworkPeeringAsync()} . + * + * @example samples/V1/VmwareEngineClient/create_network_peering.php + * + * @param CreateNetworkPeeringRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function createNetworkPeering(CreateNetworkPeeringRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('CreateNetworkPeering', $request, $callOptions)->wait(); + } + + /** + * Creates a new network policy in a given VMware Engine network of a + * project and location (region). A new network policy cannot be created if + * another network policy already exists in the same scope. + * + * The async variant is {@see VmwareEngineClient::createNetworkPolicyAsync()} . + * + * @example samples/V1/VmwareEngineClient/create_network_policy.php + * + * @param CreateNetworkPolicyRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function createNetworkPolicy(CreateNetworkPolicyRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('CreateNetworkPolicy', $request, $callOptions)->wait(); + } + + /** + * Creates a new `PrivateCloud` resource in a given project and location. + * Private clouds of type `STANDARD` and + * `TIME_LIMITED` are zonal resources, `STRETCHED` private clouds are + * regional. + * Creating a private cloud also creates a [management + * cluster](https://cloud.google.com/vmware-engine/docs/concepts-vmware-components) + * for that private cloud. + * + * The async variant is {@see VmwareEngineClient::createPrivateCloudAsync()} . + * + * @example samples/V1/VmwareEngineClient/create_private_cloud.php + * + * @param CreatePrivateCloudRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function createPrivateCloud(CreatePrivateCloudRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('CreatePrivateCloud', $request, $callOptions)->wait(); + } + + /** + * Creates a new private connection that can be used for accessing private + * Clouds. + * + * The async variant is {@see VmwareEngineClient::createPrivateConnectionAsync()} . + * + * @example samples/V1/VmwareEngineClient/create_private_connection.php + * + * @param CreatePrivateConnectionRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function createPrivateConnection(CreatePrivateConnectionRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('CreatePrivateConnection', $request, $callOptions)->wait(); + } + + /** + * Creates a new VMware Engine network that can be used by a private cloud. + * + * The async variant is {@see VmwareEngineClient::createVmwareEngineNetworkAsync()} + * . + * + * @example samples/V1/VmwareEngineClient/create_vmware_engine_network.php + * + * @param CreateVmwareEngineNetworkRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function createVmwareEngineNetwork(CreateVmwareEngineNetworkRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('CreateVmwareEngineNetwork', $request, $callOptions)->wait(); + } + + /** + * Deletes a `Cluster` resource. To avoid unintended data loss, migrate or + * gracefully shut down any workloads running on the cluster before deletion. + * You cannot delete the management cluster of a private cloud using this + * method. + * + * The async variant is {@see VmwareEngineClient::deleteClusterAsync()} . + * + * @example samples/V1/VmwareEngineClient/delete_cluster.php + * + * @param DeleteClusterRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function deleteCluster(DeleteClusterRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('DeleteCluster', $request, $callOptions)->wait(); + } + + /** + * Deletes a single external access rule. + * + * The async variant is {@see VmwareEngineClient::deleteExternalAccessRuleAsync()} + * . + * + * @example samples/V1/VmwareEngineClient/delete_external_access_rule.php + * + * @param DeleteExternalAccessRuleRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function deleteExternalAccessRule(DeleteExternalAccessRuleRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('DeleteExternalAccessRule', $request, $callOptions)->wait(); + } + + /** + * Deletes a single external IP address. When you delete an external IP + * address, connectivity between the external IP address and the corresponding + * internal IP address is lost. + * + * The async variant is {@see VmwareEngineClient::deleteExternalAddressAsync()} . + * + * @example samples/V1/VmwareEngineClient/delete_external_address.php + * + * @param DeleteExternalAddressRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function deleteExternalAddress(DeleteExternalAddressRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('DeleteExternalAddress', $request, $callOptions)->wait(); + } + + /** + * Deletes a single logging server. + * + * The async variant is {@see VmwareEngineClient::deleteLoggingServerAsync()} . + * + * @example samples/V1/VmwareEngineClient/delete_logging_server.php + * + * @param DeleteLoggingServerRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function deleteLoggingServer(DeleteLoggingServerRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('DeleteLoggingServer', $request, $callOptions)->wait(); + } + + /** + * Deletes a `ManagementDnsZoneBinding` resource. When a management DNS zone + * binding is deleted, the corresponding consumer VPC network is no longer + * bound to the management DNS zone. + * + * The async variant is + * {@see VmwareEngineClient::deleteManagementDnsZoneBindingAsync()} . + * + * @example samples/V1/VmwareEngineClient/delete_management_dns_zone_binding.php + * + * @param DeleteManagementDnsZoneBindingRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function deleteManagementDnsZoneBinding(DeleteManagementDnsZoneBindingRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('DeleteManagementDnsZoneBinding', $request, $callOptions)->wait(); + } + + /** + * Deletes a `NetworkPeering` resource. When a network peering is deleted for + * a VMware Engine network, the peer network becomes inaccessible to that + * VMware Engine network. NetworkPeering is a global resource and location can + * only be global. + * + * The async variant is {@see VmwareEngineClient::deleteNetworkPeeringAsync()} . + * + * @example samples/V1/VmwareEngineClient/delete_network_peering.php + * + * @param DeleteNetworkPeeringRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function deleteNetworkPeering(DeleteNetworkPeeringRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('DeleteNetworkPeering', $request, $callOptions)->wait(); + } + + /** + * Deletes a `NetworkPolicy` resource. A network policy cannot be deleted + * when `NetworkService.state` is set to `RECONCILING` for either its external + * IP or internet access service. + * + * The async variant is {@see VmwareEngineClient::deleteNetworkPolicyAsync()} . + * + * @example samples/V1/VmwareEngineClient/delete_network_policy.php + * + * @param DeleteNetworkPolicyRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function deleteNetworkPolicy(DeleteNetworkPolicyRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('DeleteNetworkPolicy', $request, $callOptions)->wait(); + } + + /** + * Schedules a `PrivateCloud` resource for deletion. + * + * A `PrivateCloud` resource scheduled for deletion has `PrivateCloud.state` + * set to `DELETED` and `expireTime` set to the time when deletion is final + * and can no longer be reversed. The delete operation is marked as done + * as soon as the `PrivateCloud` is successfully scheduled for deletion + * (this also applies when `delayHours` is set to zero), and the operation is + * not kept in pending state until `PrivateCloud` is purged. + * `PrivateCloud` can be restored using `UndeletePrivateCloud` method before + * the `expireTime` elapses. When `expireTime` is reached, deletion is final + * and all private cloud resources are irreversibly removed and billing stops. + * During the final removal process, `PrivateCloud.state` is set to `PURGING`. + * `PrivateCloud` can be polled using standard `GET` method for the whole + * period of deletion and purging. It will not be returned only + * when it is completely purged. + * + * The async variant is {@see VmwareEngineClient::deletePrivateCloudAsync()} . + * + * @example samples/V1/VmwareEngineClient/delete_private_cloud.php + * + * @param DeletePrivateCloudRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function deletePrivateCloud(DeletePrivateCloudRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('DeletePrivateCloud', $request, $callOptions)->wait(); + } + + /** + * Deletes a `PrivateConnection` resource. When a private connection is + * deleted for a VMware Engine network, the connected network becomes + * inaccessible to that VMware Engine network. + * + * The async variant is {@see VmwareEngineClient::deletePrivateConnectionAsync()} . + * + * @example samples/V1/VmwareEngineClient/delete_private_connection.php + * + * @param DeletePrivateConnectionRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function deletePrivateConnection(DeletePrivateConnectionRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('DeletePrivateConnection', $request, $callOptions)->wait(); + } + + /** + * Deletes a `VmwareEngineNetwork` resource. You can only delete a VMware + * Engine network after all resources that refer to it are deleted. For + * example, a private cloud, a network peering, and a network policy can all + * refer to the same VMware Engine network. + * + * The async variant is {@see VmwareEngineClient::deleteVmwareEngineNetworkAsync()} + * . + * + * @example samples/V1/VmwareEngineClient/delete_vmware_engine_network.php + * + * @param DeleteVmwareEngineNetworkRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function deleteVmwareEngineNetwork(DeleteVmwareEngineNetworkRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('DeleteVmwareEngineNetwork', $request, $callOptions)->wait(); + } + + /** + * Lists external IP addresses assigned to VMware workload VMs within the + * scope of the given network policy. + * + * The async variant is + * {@see VmwareEngineClient::fetchNetworkPolicyExternalAddressesAsync()} . + * + * @example samples/V1/VmwareEngineClient/fetch_network_policy_external_addresses.php + * + * @param FetchNetworkPolicyExternalAddressesRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function fetchNetworkPolicyExternalAddresses(FetchNetworkPolicyExternalAddressesRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('FetchNetworkPolicyExternalAddresses', $request, $callOptions); + } + + /** + * Retrieves a `Cluster` resource by its resource name. + * + * The async variant is {@see VmwareEngineClient::getClusterAsync()} . + * + * @example samples/V1/VmwareEngineClient/get_cluster.php + * + * @param GetClusterRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Cluster + * + * @throws ApiException Thrown if the API call fails. + */ + public function getCluster(GetClusterRequest $request, array $callOptions = []): Cluster + { + return $this->startApiCall('GetCluster', $request, $callOptions)->wait(); + } + + /** + * Gets all the principals having bind permission on the intranet VPC + * associated with the consumer project granted by the Grant API. + * DnsBindPermission is a global resource and location can only be global. + * + * The async variant is {@see VmwareEngineClient::getDnsBindPermissionAsync()} . + * + * @example samples/V1/VmwareEngineClient/get_dns_bind_permission.php + * + * @param GetDnsBindPermissionRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 DnsBindPermission + * + * @throws ApiException Thrown if the API call fails. + */ + public function getDnsBindPermission(GetDnsBindPermissionRequest $request, array $callOptions = []): DnsBindPermission + { + return $this->startApiCall('GetDnsBindPermission', $request, $callOptions)->wait(); + } + + /** + * Gets details of the `DnsForwarding` config. + * + * The async variant is {@see VmwareEngineClient::getDnsForwardingAsync()} . + * + * @example samples/V1/VmwareEngineClient/get_dns_forwarding.php + * + * @param GetDnsForwardingRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 DnsForwarding + * + * @throws ApiException Thrown if the API call fails. + */ + public function getDnsForwarding(GetDnsForwardingRequest $request, array $callOptions = []): DnsForwarding + { + return $this->startApiCall('GetDnsForwarding', $request, $callOptions)->wait(); + } + + /** + * Gets details of a single external access rule. + * + * The async variant is {@see VmwareEngineClient::getExternalAccessRuleAsync()} . + * + * @example samples/V1/VmwareEngineClient/get_external_access_rule.php + * + * @param GetExternalAccessRuleRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 ExternalAccessRule + * + * @throws ApiException Thrown if the API call fails. + */ + public function getExternalAccessRule(GetExternalAccessRuleRequest $request, array $callOptions = []): ExternalAccessRule + { + return $this->startApiCall('GetExternalAccessRule', $request, $callOptions)->wait(); + } + + /** + * Gets details of a single external IP address. + * + * The async variant is {@see VmwareEngineClient::getExternalAddressAsync()} . + * + * @example samples/V1/VmwareEngineClient/get_external_address.php + * + * @param GetExternalAddressRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 ExternalAddress + * + * @throws ApiException Thrown if the API call fails. + */ + public function getExternalAddress(GetExternalAddressRequest $request, array $callOptions = []): ExternalAddress + { + return $this->startApiCall('GetExternalAddress', $request, $callOptions)->wait(); + } + + /** + * Retrieves a `HcxActivationKey` resource by its resource name. + * + * The async variant is {@see VmwareEngineClient::getHcxActivationKeyAsync()} . + * + * @example samples/V1/VmwareEngineClient/get_hcx_activation_key.php + * + * @param GetHcxActivationKeyRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 HcxActivationKey + * + * @throws ApiException Thrown if the API call fails. + */ + public function getHcxActivationKey(GetHcxActivationKeyRequest $request, array $callOptions = []): HcxActivationKey + { + return $this->startApiCall('GetHcxActivationKey', $request, $callOptions)->wait(); + } + + /** + * Gets details of a logging server. + * + * The async variant is {@see VmwareEngineClient::getLoggingServerAsync()} . + * + * @example samples/V1/VmwareEngineClient/get_logging_server.php + * + * @param GetLoggingServerRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 LoggingServer + * + * @throws ApiException Thrown if the API call fails. + */ + public function getLoggingServer(GetLoggingServerRequest $request, array $callOptions = []): LoggingServer + { + return $this->startApiCall('GetLoggingServer', $request, $callOptions)->wait(); + } + + /** + * Retrieves a 'ManagementDnsZoneBinding' resource by its resource name. + * + * The async variant is + * {@see VmwareEngineClient::getManagementDnsZoneBindingAsync()} . + * + * @example samples/V1/VmwareEngineClient/get_management_dns_zone_binding.php + * + * @param GetManagementDnsZoneBindingRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 ManagementDnsZoneBinding + * + * @throws ApiException Thrown if the API call fails. + */ + public function getManagementDnsZoneBinding(GetManagementDnsZoneBindingRequest $request, array $callOptions = []): ManagementDnsZoneBinding + { + return $this->startApiCall('GetManagementDnsZoneBinding', $request, $callOptions)->wait(); + } + + /** + * Retrieves a `NetworkPeering` resource by its resource name. The resource + * contains details of the network peering, such as peered + * networks, import and export custom route configurations, and peering state. + * NetworkPeering is a global resource and location can only be global. + * + * The async variant is {@see VmwareEngineClient::getNetworkPeeringAsync()} . + * + * @example samples/V1/VmwareEngineClient/get_network_peering.php + * + * @param GetNetworkPeeringRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 NetworkPeering + * + * @throws ApiException Thrown if the API call fails. + */ + public function getNetworkPeering(GetNetworkPeeringRequest $request, array $callOptions = []): NetworkPeering + { + return $this->startApiCall('GetNetworkPeering', $request, $callOptions)->wait(); + } + + /** + * Retrieves a `NetworkPolicy` resource by its resource name. + * + * The async variant is {@see VmwareEngineClient::getNetworkPolicyAsync()} . + * + * @example samples/V1/VmwareEngineClient/get_network_policy.php + * + * @param GetNetworkPolicyRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 NetworkPolicy + * + * @throws ApiException Thrown if the API call fails. + */ + public function getNetworkPolicy(GetNetworkPolicyRequest $request, array $callOptions = []): NetworkPolicy + { + return $this->startApiCall('GetNetworkPolicy', $request, $callOptions)->wait(); + } + + /** + * Gets details of a single node. + * + * The async variant is {@see VmwareEngineClient::getNodeAsync()} . + * + * @example samples/V1/VmwareEngineClient/get_node.php + * + * @param GetNodeRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Node + * + * @throws ApiException Thrown if the API call fails. + */ + public function getNode(GetNodeRequest $request, array $callOptions = []): Node + { + return $this->startApiCall('GetNode', $request, $callOptions)->wait(); + } + + /** + * Gets details of a single `NodeType`. + * + * The async variant is {@see VmwareEngineClient::getNodeTypeAsync()} . + * + * @example samples/V1/VmwareEngineClient/get_node_type.php + * + * @param GetNodeTypeRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 NodeType + * + * @throws ApiException Thrown if the API call fails. + */ + public function getNodeType(GetNodeTypeRequest $request, array $callOptions = []): NodeType + { + return $this->startApiCall('GetNodeType', $request, $callOptions)->wait(); + } + + /** + * Retrieves a `PrivateCloud` resource by its resource name. + * + * The async variant is {@see VmwareEngineClient::getPrivateCloudAsync()} . + * + * @example samples/V1/VmwareEngineClient/get_private_cloud.php + * + * @param GetPrivateCloudRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PrivateCloud + * + * @throws ApiException Thrown if the API call fails. + */ + public function getPrivateCloud(GetPrivateCloudRequest $request, array $callOptions = []): PrivateCloud + { + return $this->startApiCall('GetPrivateCloud', $request, $callOptions)->wait(); + } + + /** + * Retrieves a `PrivateConnection` resource by its resource name. The resource + * contains details of the private connection, such as connected + * network, routing mode and state. + * + * The async variant is {@see VmwareEngineClient::getPrivateConnectionAsync()} . + * + * @example samples/V1/VmwareEngineClient/get_private_connection.php + * + * @param GetPrivateConnectionRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PrivateConnection + * + * @throws ApiException Thrown if the API call fails. + */ + public function getPrivateConnection(GetPrivateConnectionRequest $request, array $callOptions = []): PrivateConnection + { + return $this->startApiCall('GetPrivateConnection', $request, $callOptions)->wait(); + } + + /** + * Gets details of a single subnet. + * + * The async variant is {@see VmwareEngineClient::getSubnetAsync()} . + * + * @example samples/V1/VmwareEngineClient/get_subnet.php + * + * @param GetSubnetRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Subnet + * + * @throws ApiException Thrown if the API call fails. + */ + public function getSubnet(GetSubnetRequest $request, array $callOptions = []): Subnet + { + return $this->startApiCall('GetSubnet', $request, $callOptions)->wait(); + } + + /** + * Retrieves a `VmwareEngineNetwork` resource by its resource name. The + * resource contains details of the VMware Engine network, such as its VMware + * Engine network type, peered networks in a service project, and state + * (for example, `CREATING`, `ACTIVE`, `DELETING`). + * + * The async variant is {@see VmwareEngineClient::getVmwareEngineNetworkAsync()} . + * + * @example samples/V1/VmwareEngineClient/get_vmware_engine_network.php + * + * @param GetVmwareEngineNetworkRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 VmwareEngineNetwork + * + * @throws ApiException Thrown if the API call fails. + */ + public function getVmwareEngineNetwork(GetVmwareEngineNetworkRequest $request, array $callOptions = []): VmwareEngineNetwork + { + return $this->startApiCall('GetVmwareEngineNetwork', $request, $callOptions)->wait(); + } + + /** + * Grants the bind permission to the customer provided principal(user / + * service account) to bind their DNS zone with the intranet VPC associated + * with the project. DnsBindPermission is a global resource and location can + * only be global. + * + * The async variant is {@see VmwareEngineClient::grantDnsBindPermissionAsync()} . + * + * @example samples/V1/VmwareEngineClient/grant_dns_bind_permission.php + * + * @param GrantDnsBindPermissionRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function grantDnsBindPermission(GrantDnsBindPermissionRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('GrantDnsBindPermission', $request, $callOptions)->wait(); + } + + /** + * Lists `Cluster` resources in a given private cloud. + * + * The async variant is {@see VmwareEngineClient::listClustersAsync()} . + * + * @example samples/V1/VmwareEngineClient/list_clusters.php + * + * @param ListClustersRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listClusters(ListClustersRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListClusters', $request, $callOptions); + } + + /** + * Lists `ExternalAccessRule` resources in the specified network policy. + * + * The async variant is {@see VmwareEngineClient::listExternalAccessRulesAsync()} . + * + * @example samples/V1/VmwareEngineClient/list_external_access_rules.php + * + * @param ListExternalAccessRulesRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listExternalAccessRules(ListExternalAccessRulesRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListExternalAccessRules', $request, $callOptions); + } + + /** + * Lists external IP addresses assigned to VMware workload VMs in a given + * private cloud. + * + * The async variant is {@see VmwareEngineClient::listExternalAddressesAsync()} . + * + * @example samples/V1/VmwareEngineClient/list_external_addresses.php + * + * @param ListExternalAddressesRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listExternalAddresses(ListExternalAddressesRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListExternalAddresses', $request, $callOptions); + } + + /** + * Lists `HcxActivationKey` resources in a given private cloud. + * + * The async variant is {@see VmwareEngineClient::listHcxActivationKeysAsync()} . + * + * @example samples/V1/VmwareEngineClient/list_hcx_activation_keys.php + * + * @param ListHcxActivationKeysRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listHcxActivationKeys(ListHcxActivationKeysRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListHcxActivationKeys', $request, $callOptions); + } + + /** + * Lists logging servers configured for a given private + * cloud. + * + * The async variant is {@see VmwareEngineClient::listLoggingServersAsync()} . + * + * @example samples/V1/VmwareEngineClient/list_logging_servers.php + * + * @param ListLoggingServersRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listLoggingServers(ListLoggingServersRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListLoggingServers', $request, $callOptions); + } + + /** + * Lists Consumer VPCs bound to Management DNS Zone of a given private cloud. + * + * The async variant is + * {@see VmwareEngineClient::listManagementDnsZoneBindingsAsync()} . + * + * @example samples/V1/VmwareEngineClient/list_management_dns_zone_bindings.php + * + * @param ListManagementDnsZoneBindingsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listManagementDnsZoneBindings(ListManagementDnsZoneBindingsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListManagementDnsZoneBindings', $request, $callOptions); + } + + /** + * Lists `NetworkPeering` resources in a given project. NetworkPeering is a + * global resource and location can only be global. + * + * The async variant is {@see VmwareEngineClient::listNetworkPeeringsAsync()} . + * + * @example samples/V1/VmwareEngineClient/list_network_peerings.php + * + * @param ListNetworkPeeringsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listNetworkPeerings(ListNetworkPeeringsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListNetworkPeerings', $request, $callOptions); + } + + /** + * Lists `NetworkPolicy` resources in a specified project and location. + * + * The async variant is {@see VmwareEngineClient::listNetworkPoliciesAsync()} . + * + * @example samples/V1/VmwareEngineClient/list_network_policies.php + * + * @param ListNetworkPoliciesRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listNetworkPolicies(ListNetworkPoliciesRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListNetworkPolicies', $request, $callOptions); + } + + /** + * Lists node types + * + * The async variant is {@see VmwareEngineClient::listNodeTypesAsync()} . + * + * @example samples/V1/VmwareEngineClient/list_node_types.php + * + * @param ListNodeTypesRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listNodeTypes(ListNodeTypesRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListNodeTypes', $request, $callOptions); + } + + /** + * Lists nodes in a given cluster. + * + * The async variant is {@see VmwareEngineClient::listNodesAsync()} . + * + * @example samples/V1/VmwareEngineClient/list_nodes.php + * + * @param ListNodesRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listNodes(ListNodesRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListNodes', $request, $callOptions); + } + + /** + * Lists the network peering routes exchanged over a peering connection. + * NetworkPeering is a global resource and location can only be global. + * + * The async variant is {@see VmwareEngineClient::listPeeringRoutesAsync()} . + * + * @example samples/V1/VmwareEngineClient/list_peering_routes.php + * + * @param ListPeeringRoutesRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listPeeringRoutes(ListPeeringRoutesRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListPeeringRoutes', $request, $callOptions); + } + + /** + * Lists `PrivateCloud` resources in a given project and location. + * + * The async variant is {@see VmwareEngineClient::listPrivateCloudsAsync()} . + * + * @example samples/V1/VmwareEngineClient/list_private_clouds.php + * + * @param ListPrivateCloudsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listPrivateClouds(ListPrivateCloudsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListPrivateClouds', $request, $callOptions); + } + + /** + * Lists the private connection routes exchanged over a peering connection. + * + * The async variant is + * {@see VmwareEngineClient::listPrivateConnectionPeeringRoutesAsync()} . + * + * @example samples/V1/VmwareEngineClient/list_private_connection_peering_routes.php + * + * @param ListPrivateConnectionPeeringRoutesRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listPrivateConnectionPeeringRoutes(ListPrivateConnectionPeeringRoutesRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListPrivateConnectionPeeringRoutes', $request, $callOptions); + } + + /** + * Lists `PrivateConnection` resources in a given project and location. + * + * The async variant is {@see VmwareEngineClient::listPrivateConnectionsAsync()} . + * + * @example samples/V1/VmwareEngineClient/list_private_connections.php + * + * @param ListPrivateConnectionsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listPrivateConnections(ListPrivateConnectionsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListPrivateConnections', $request, $callOptions); + } + + /** + * Lists subnets in a given private cloud. + * + * The async variant is {@see VmwareEngineClient::listSubnetsAsync()} . + * + * @example samples/V1/VmwareEngineClient/list_subnets.php + * + * @param ListSubnetsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listSubnets(ListSubnetsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListSubnets', $request, $callOptions); + } + + /** + * Lists `VmwareEngineNetwork` resources in a given project and location. + * + * The async variant is {@see VmwareEngineClient::listVmwareEngineNetworksAsync()} + * . + * + * @example samples/V1/VmwareEngineClient/list_vmware_engine_networks.php + * + * @param ListVmwareEngineNetworksRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listVmwareEngineNetworks(ListVmwareEngineNetworksRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListVmwareEngineNetworks', $request, $callOptions); + } + + /** + * Retries to create a `ManagementDnsZoneBinding` resource that is + * in failed state. + * + * The async variant is + * {@see VmwareEngineClient::repairManagementDnsZoneBindingAsync()} . + * + * @example samples/V1/VmwareEngineClient/repair_management_dns_zone_binding.php + * + * @param RepairManagementDnsZoneBindingRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function repairManagementDnsZoneBinding(RepairManagementDnsZoneBindingRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('RepairManagementDnsZoneBinding', $request, $callOptions)->wait(); + } + + /** + * Resets credentials of the NSX appliance. + * + * The async variant is {@see VmwareEngineClient::resetNsxCredentialsAsync()} . + * + * @example samples/V1/VmwareEngineClient/reset_nsx_credentials.php + * + * @param ResetNsxCredentialsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function resetNsxCredentials(ResetNsxCredentialsRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('ResetNsxCredentials', $request, $callOptions)->wait(); + } + + /** + * Resets credentials of the Vcenter appliance. + * + * The async variant is {@see VmwareEngineClient::resetVcenterCredentialsAsync()} . + * + * @example samples/V1/VmwareEngineClient/reset_vcenter_credentials.php + * + * @param ResetVcenterCredentialsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function resetVcenterCredentials(ResetVcenterCredentialsRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('ResetVcenterCredentials', $request, $callOptions)->wait(); + } + + /** + * Revokes the bind permission from the customer provided principal(user / + * service account) on the intranet VPC associated with the consumer project. + * DnsBindPermission is a global resource and location can only be global. + * + * The async variant is {@see VmwareEngineClient::revokeDnsBindPermissionAsync()} . + * + * @example samples/V1/VmwareEngineClient/revoke_dns_bind_permission.php + * + * @param RevokeDnsBindPermissionRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function revokeDnsBindPermission(RevokeDnsBindPermissionRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('RevokeDnsBindPermission', $request, $callOptions)->wait(); + } + + /** + * Gets details of credentials for NSX appliance. + * + * The async variant is {@see VmwareEngineClient::showNsxCredentialsAsync()} . + * + * @example samples/V1/VmwareEngineClient/show_nsx_credentials.php + * + * @param ShowNsxCredentialsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Credentials + * + * @throws ApiException Thrown if the API call fails. + */ + public function showNsxCredentials(ShowNsxCredentialsRequest $request, array $callOptions = []): Credentials + { + return $this->startApiCall('ShowNsxCredentials', $request, $callOptions)->wait(); + } + + /** + * Gets details of credentials for Vcenter appliance. + * + * The async variant is {@see VmwareEngineClient::showVcenterCredentialsAsync()} . + * + * @example samples/V1/VmwareEngineClient/show_vcenter_credentials.php + * + * @param ShowVcenterCredentialsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Credentials + * + * @throws ApiException Thrown if the API call fails. + */ + public function showVcenterCredentials(ShowVcenterCredentialsRequest $request, array $callOptions = []): Credentials + { + return $this->startApiCall('ShowVcenterCredentials', $request, $callOptions)->wait(); + } + + /** + * Restores a private cloud that was previously scheduled for deletion by + * `DeletePrivateCloud`. A `PrivateCloud` resource scheduled for deletion has + * `PrivateCloud.state` set to `DELETED` and `PrivateCloud.expireTime` set to + * the time when deletion can no longer be reversed. + * + * The async variant is {@see VmwareEngineClient::undeletePrivateCloudAsync()} . + * + * @example samples/V1/VmwareEngineClient/undelete_private_cloud.php + * + * @param UndeletePrivateCloudRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function undeletePrivateCloud(UndeletePrivateCloudRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('UndeletePrivateCloud', $request, $callOptions)->wait(); + } + + /** + * Modifies a `Cluster` resource. Only fields specified in `updateMask` are + * applied. + * + * During operation processing, the resource is temporarily in the `ACTIVE` + * state before the operation fully completes. For that period of time, you + * can't update the resource. Use the operation status to determine when the + * processing fully completes. + * + * The async variant is {@see VmwareEngineClient::updateClusterAsync()} . + * + * @example samples/V1/VmwareEngineClient/update_cluster.php + * + * @param UpdateClusterRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateCluster(UpdateClusterRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('UpdateCluster', $request, $callOptions)->wait(); + } + + /** + * Updates the parameters of the `DnsForwarding` config, like associated + * domains. Only fields specified in `update_mask` are applied. + * + * The async variant is {@see VmwareEngineClient::updateDnsForwardingAsync()} . + * + * @example samples/V1/VmwareEngineClient/update_dns_forwarding.php + * + * @param UpdateDnsForwardingRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateDnsForwarding(UpdateDnsForwardingRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('UpdateDnsForwarding', $request, $callOptions)->wait(); + } + + /** + * Updates the parameters of a single external access rule. + * Only fields specified in `update_mask` are applied. + * + * The async variant is {@see VmwareEngineClient::updateExternalAccessRuleAsync()} + * . + * + * @example samples/V1/VmwareEngineClient/update_external_access_rule.php + * + * @param UpdateExternalAccessRuleRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateExternalAccessRule(UpdateExternalAccessRuleRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('UpdateExternalAccessRule', $request, $callOptions)->wait(); + } + + /** + * Updates the parameters of a single external IP address. + * Only fields specified in `update_mask` are applied. + * + * During operation processing, the resource is temporarily in the `ACTIVE` + * state before the operation fully completes. For that period of time, you + * can't update the resource. Use the operation status to determine when the + * processing fully completes. + * + * The async variant is {@see VmwareEngineClient::updateExternalAddressAsync()} . + * + * @example samples/V1/VmwareEngineClient/update_external_address.php + * + * @param UpdateExternalAddressRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateExternalAddress(UpdateExternalAddressRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('UpdateExternalAddress', $request, $callOptions)->wait(); + } + + /** + * Updates the parameters of a single logging server. + * Only fields specified in `update_mask` are applied. + * + * The async variant is {@see VmwareEngineClient::updateLoggingServerAsync()} . + * + * @example samples/V1/VmwareEngineClient/update_logging_server.php + * + * @param UpdateLoggingServerRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateLoggingServer(UpdateLoggingServerRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('UpdateLoggingServer', $request, $callOptions)->wait(); + } + + /** + * Updates a `ManagementDnsZoneBinding` resource. + * Only fields specified in `update_mask` are applied. + * + * The async variant is + * {@see VmwareEngineClient::updateManagementDnsZoneBindingAsync()} . + * + * @example samples/V1/VmwareEngineClient/update_management_dns_zone_binding.php + * + * @param UpdateManagementDnsZoneBindingRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateManagementDnsZoneBinding(UpdateManagementDnsZoneBindingRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('UpdateManagementDnsZoneBinding', $request, $callOptions)->wait(); + } + + /** + * Modifies a `NetworkPeering` resource. Only the `description` field can be + * updated. Only fields specified in `updateMask` are applied. NetworkPeering + * is a global resource and location can only be global. + * + * The async variant is {@see VmwareEngineClient::updateNetworkPeeringAsync()} . + * + * @example samples/V1/VmwareEngineClient/update_network_peering.php + * + * @param UpdateNetworkPeeringRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateNetworkPeering(UpdateNetworkPeeringRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('UpdateNetworkPeering', $request, $callOptions)->wait(); + } + + /** + * Modifies a `NetworkPolicy` resource. Only the following fields can be + * updated: `internet_access`, `external_ip`, `edge_services_cidr`. + * Only fields specified in `updateMask` are applied. When updating a network + * policy, the external IP network service can only be disabled if there are + * no external IP addresses present in the scope of the policy. Also, a + * `NetworkService` cannot be updated when `NetworkService.state` is set + * to `RECONCILING`. + * + * During operation processing, the resource is temporarily in the `ACTIVE` + * state before the operation fully completes. For that period of time, you + * can't update the resource. Use the operation status to determine when the + * processing fully completes. + * + * The async variant is {@see VmwareEngineClient::updateNetworkPolicyAsync()} . + * + * @example samples/V1/VmwareEngineClient/update_network_policy.php + * + * @param UpdateNetworkPolicyRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateNetworkPolicy(UpdateNetworkPolicyRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('UpdateNetworkPolicy', $request, $callOptions)->wait(); + } + + /** + * Modifies a `PrivateCloud` resource. Only the following fields can be + * updated: `description`. + * Only fields specified in `updateMask` are applied. + * + * During operation processing, the resource is temporarily in the `ACTIVE` + * state before the operation fully completes. For that period of time, you + * can't update the resource. Use the operation status to determine when the + * processing fully completes. + * + * The async variant is {@see VmwareEngineClient::updatePrivateCloudAsync()} . + * + * @example samples/V1/VmwareEngineClient/update_private_cloud.php + * + * @param UpdatePrivateCloudRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function updatePrivateCloud(UpdatePrivateCloudRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('UpdatePrivateCloud', $request, $callOptions)->wait(); + } + + /** + * Modifies a `PrivateConnection` resource. Only `description` and + * `routing_mode` fields can be updated. Only fields specified in `updateMask` + * are applied. + * + * The async variant is {@see VmwareEngineClient::updatePrivateConnectionAsync()} . + * + * @example samples/V1/VmwareEngineClient/update_private_connection.php + * + * @param UpdatePrivateConnectionRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function updatePrivateConnection(UpdatePrivateConnectionRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('UpdatePrivateConnection', $request, $callOptions)->wait(); + } + + /** + * Updates the parameters of a single subnet. Only fields specified in + * `update_mask` are applied. + * + * *Note*: This API is synchronous and always returns a successful + * `google.longrunning.Operation` (LRO). The returned LRO will only have + * `done` and `response` fields. + * + * The async variant is {@see VmwareEngineClient::updateSubnetAsync()} . + * + * @example samples/V1/VmwareEngineClient/update_subnet.php + * + * @param UpdateSubnetRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateSubnet(UpdateSubnetRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('UpdateSubnet', $request, $callOptions)->wait(); + } + + /** + * Modifies a VMware Engine network resource. Only the following fields can be + * updated: `description`. Only fields specified in `updateMask` are + * applied. + * + * The async variant is {@see VmwareEngineClient::updateVmwareEngineNetworkAsync()} + * . + * + * @example samples/V1/VmwareEngineClient/update_vmware_engine_network.php + * + * @param UpdateVmwareEngineNetworkRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateVmwareEngineNetwork(UpdateVmwareEngineNetworkRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('UpdateVmwareEngineNetwork', $request, $callOptions)->wait(); + } + + /** + * Gets information about a location. + * + * The async variant is {@see VmwareEngineClient::getLocationAsync()} . + * + * @example samples/V1/VmwareEngineClient/get_location.php + * + * @param GetLocationRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Location + * + * @throws ApiException Thrown if the API call fails. + */ + public function getLocation(GetLocationRequest $request, array $callOptions = []): Location + { + return $this->startApiCall('GetLocation', $request, $callOptions)->wait(); + } + + /** + * Lists information about the supported locations for this service. + * + * The async variant is {@see VmwareEngineClient::listLocationsAsync()} . + * + * @example samples/V1/VmwareEngineClient/list_locations.php + * + * @param ListLocationsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listLocations(ListLocationsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListLocations', $request, $callOptions); + } + + /** + * Gets the access control policy for a resource. Returns an empty policy + * if the resource exists and does not have a policy set. + * + * The async variant is {@see VmwareEngineClient::getIamPolicyAsync()} . + * + * @example samples/V1/VmwareEngineClient/get_iam_policy.php + * + * @param GetIamPolicyRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Policy + * + * @throws ApiException Thrown if the API call fails. + */ + public function getIamPolicy(GetIamPolicyRequest $request, array $callOptions = []): Policy + { + return $this->startApiCall('GetIamPolicy', $request, $callOptions)->wait(); + } + + /** + * Sets the access control policy on the specified resource. Replaces + * any existing policy. + * + * Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` + * errors. + * + * The async variant is {@see VmwareEngineClient::setIamPolicyAsync()} . + * + * @example samples/V1/VmwareEngineClient/set_iam_policy.php + * + * @param SetIamPolicyRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Policy + * + * @throws ApiException Thrown if the API call fails. + */ + public function setIamPolicy(SetIamPolicyRequest $request, array $callOptions = []): Policy + { + return $this->startApiCall('SetIamPolicy', $request, $callOptions)->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. + * + * The async variant is {@see VmwareEngineClient::testIamPermissionsAsync()} . + * + * @example samples/V1/VmwareEngineClient/test_iam_permissions.php + * + * @param TestIamPermissionsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 TestIamPermissionsResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function testIamPermissions(TestIamPermissionsRequest $request, array $callOptions = []): TestIamPermissionsResponse + { + return $this->startApiCall('TestIamPermissions', $request, $callOptions)->wait(); + } +} diff --git a/owl-bot-staging/VmwareEngine/v1/src/V1/gapic_metadata.json b/owl-bot-staging/VmwareEngine/v1/src/V1/gapic_metadata.json new file mode 100644 index 000000000000..f3559962a01c --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/src/V1/gapic_metadata.json @@ -0,0 +1,413 @@ +{ + "schema": "1.0", + "comment": "This file maps proto services\/RPCs to the corresponding library clients\/methods", + "language": "php", + "protoPackage": "google.cloud.vmwareengine.v1", + "libraryPackage": "Google\\Cloud\\VmwareEngine\\V1", + "services": { + "VmwareEngine": { + "clients": { + "grpc": { + "libraryClient": "VmwareEngineGapicClient", + "rpcs": { + "CreateCluster": { + "methods": [ + "createCluster" + ] + }, + "CreateExternalAccessRule": { + "methods": [ + "createExternalAccessRule" + ] + }, + "CreateExternalAddress": { + "methods": [ + "createExternalAddress" + ] + }, + "CreateHcxActivationKey": { + "methods": [ + "createHcxActivationKey" + ] + }, + "CreateLoggingServer": { + "methods": [ + "createLoggingServer" + ] + }, + "CreateManagementDnsZoneBinding": { + "methods": [ + "createManagementDnsZoneBinding" + ] + }, + "CreateNetworkPeering": { + "methods": [ + "createNetworkPeering" + ] + }, + "CreateNetworkPolicy": { + "methods": [ + "createNetworkPolicy" + ] + }, + "CreatePrivateCloud": { + "methods": [ + "createPrivateCloud" + ] + }, + "CreatePrivateConnection": { + "methods": [ + "createPrivateConnection" + ] + }, + "CreateVmwareEngineNetwork": { + "methods": [ + "createVmwareEngineNetwork" + ] + }, + "DeleteCluster": { + "methods": [ + "deleteCluster" + ] + }, + "DeleteExternalAccessRule": { + "methods": [ + "deleteExternalAccessRule" + ] + }, + "DeleteExternalAddress": { + "methods": [ + "deleteExternalAddress" + ] + }, + "DeleteLoggingServer": { + "methods": [ + "deleteLoggingServer" + ] + }, + "DeleteManagementDnsZoneBinding": { + "methods": [ + "deleteManagementDnsZoneBinding" + ] + }, + "DeleteNetworkPeering": { + "methods": [ + "deleteNetworkPeering" + ] + }, + "DeleteNetworkPolicy": { + "methods": [ + "deleteNetworkPolicy" + ] + }, + "DeletePrivateCloud": { + "methods": [ + "deletePrivateCloud" + ] + }, + "DeletePrivateConnection": { + "methods": [ + "deletePrivateConnection" + ] + }, + "DeleteVmwareEngineNetwork": { + "methods": [ + "deleteVmwareEngineNetwork" + ] + }, + "FetchNetworkPolicyExternalAddresses": { + "methods": [ + "fetchNetworkPolicyExternalAddresses" + ] + }, + "GetCluster": { + "methods": [ + "getCluster" + ] + }, + "GetDnsBindPermission": { + "methods": [ + "getDnsBindPermission" + ] + }, + "GetDnsForwarding": { + "methods": [ + "getDnsForwarding" + ] + }, + "GetExternalAccessRule": { + "methods": [ + "getExternalAccessRule" + ] + }, + "GetExternalAddress": { + "methods": [ + "getExternalAddress" + ] + }, + "GetHcxActivationKey": { + "methods": [ + "getHcxActivationKey" + ] + }, + "GetLoggingServer": { + "methods": [ + "getLoggingServer" + ] + }, + "GetManagementDnsZoneBinding": { + "methods": [ + "getManagementDnsZoneBinding" + ] + }, + "GetNetworkPeering": { + "methods": [ + "getNetworkPeering" + ] + }, + "GetNetworkPolicy": { + "methods": [ + "getNetworkPolicy" + ] + }, + "GetNode": { + "methods": [ + "getNode" + ] + }, + "GetNodeType": { + "methods": [ + "getNodeType" + ] + }, + "GetPrivateCloud": { + "methods": [ + "getPrivateCloud" + ] + }, + "GetPrivateConnection": { + "methods": [ + "getPrivateConnection" + ] + }, + "GetSubnet": { + "methods": [ + "getSubnet" + ] + }, + "GetVmwareEngineNetwork": { + "methods": [ + "getVmwareEngineNetwork" + ] + }, + "GrantDnsBindPermission": { + "methods": [ + "grantDnsBindPermission" + ] + }, + "ListClusters": { + "methods": [ + "listClusters" + ] + }, + "ListExternalAccessRules": { + "methods": [ + "listExternalAccessRules" + ] + }, + "ListExternalAddresses": { + "methods": [ + "listExternalAddresses" + ] + }, + "ListHcxActivationKeys": { + "methods": [ + "listHcxActivationKeys" + ] + }, + "ListLoggingServers": { + "methods": [ + "listLoggingServers" + ] + }, + "ListManagementDnsZoneBindings": { + "methods": [ + "listManagementDnsZoneBindings" + ] + }, + "ListNetworkPeerings": { + "methods": [ + "listNetworkPeerings" + ] + }, + "ListNetworkPolicies": { + "methods": [ + "listNetworkPolicies" + ] + }, + "ListNodeTypes": { + "methods": [ + "listNodeTypes" + ] + }, + "ListNodes": { + "methods": [ + "listNodes" + ] + }, + "ListPeeringRoutes": { + "methods": [ + "listPeeringRoutes" + ] + }, + "ListPrivateClouds": { + "methods": [ + "listPrivateClouds" + ] + }, + "ListPrivateConnectionPeeringRoutes": { + "methods": [ + "listPrivateConnectionPeeringRoutes" + ] + }, + "ListPrivateConnections": { + "methods": [ + "listPrivateConnections" + ] + }, + "ListSubnets": { + "methods": [ + "listSubnets" + ] + }, + "ListVmwareEngineNetworks": { + "methods": [ + "listVmwareEngineNetworks" + ] + }, + "RepairManagementDnsZoneBinding": { + "methods": [ + "repairManagementDnsZoneBinding" + ] + }, + "ResetNsxCredentials": { + "methods": [ + "resetNsxCredentials" + ] + }, + "ResetVcenterCredentials": { + "methods": [ + "resetVcenterCredentials" + ] + }, + "RevokeDnsBindPermission": { + "methods": [ + "revokeDnsBindPermission" + ] + }, + "ShowNsxCredentials": { + "methods": [ + "showNsxCredentials" + ] + }, + "ShowVcenterCredentials": { + "methods": [ + "showVcenterCredentials" + ] + }, + "UndeletePrivateCloud": { + "methods": [ + "undeletePrivateCloud" + ] + }, + "UpdateCluster": { + "methods": [ + "updateCluster" + ] + }, + "UpdateDnsForwarding": { + "methods": [ + "updateDnsForwarding" + ] + }, + "UpdateExternalAccessRule": { + "methods": [ + "updateExternalAccessRule" + ] + }, + "UpdateExternalAddress": { + "methods": [ + "updateExternalAddress" + ] + }, + "UpdateLoggingServer": { + "methods": [ + "updateLoggingServer" + ] + }, + "UpdateManagementDnsZoneBinding": { + "methods": [ + "updateManagementDnsZoneBinding" + ] + }, + "UpdateNetworkPeering": { + "methods": [ + "updateNetworkPeering" + ] + }, + "UpdateNetworkPolicy": { + "methods": [ + "updateNetworkPolicy" + ] + }, + "UpdatePrivateCloud": { + "methods": [ + "updatePrivateCloud" + ] + }, + "UpdatePrivateConnection": { + "methods": [ + "updatePrivateConnection" + ] + }, + "UpdateSubnet": { + "methods": [ + "updateSubnet" + ] + }, + "UpdateVmwareEngineNetwork": { + "methods": [ + "updateVmwareEngineNetwork" + ] + }, + "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/VmwareEngine/v1/src/V1/resources/vmware_engine_client_config.json b/owl-bot-staging/VmwareEngine/v1/src/V1/resources/vmware_engine_client_config.json new file mode 100644 index 000000000000..b669825592a5 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/src/V1/resources/vmware_engine_client_config.json @@ -0,0 +1,449 @@ +{ + "interfaces": { + "google.cloud.vmwareengine.v1.VmwareEngine": { + "retry_codes": { + "no_retry_codes": [], + "retry_policy_1_codes": [ + "UNAVAILABLE" + ], + "no_retry_1_codes": [], + "no_retry_2_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": 120000, + "rpc_timeout_multiplier": 1.0, + "max_rpc_timeout_millis": 120000, + "total_timeout_millis": 120000 + }, + "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 + }, + "no_retry_2_params": { + "initial_retry_delay_millis": 0, + "retry_delay_multiplier": 0.0, + "max_retry_delay_millis": 0, + "initial_rpc_timeout_millis": 120000, + "rpc_timeout_multiplier": 1.0, + "max_rpc_timeout_millis": 120000, + "total_timeout_millis": 120000 + } + }, + "methods": { + "CreateCluster": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "CreateExternalAccessRule": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "CreateExternalAddress": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "CreateHcxActivationKey": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "CreateLoggingServer": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "CreateManagementDnsZoneBinding": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "CreateNetworkPeering": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "CreateNetworkPolicy": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "CreatePrivateCloud": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "CreatePrivateConnection": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "CreateVmwareEngineNetwork": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "DeleteCluster": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "DeleteExternalAccessRule": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "DeleteExternalAddress": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "DeleteLoggingServer": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "DeleteManagementDnsZoneBinding": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "DeleteNetworkPeering": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "DeleteNetworkPolicy": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "DeletePrivateCloud": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "DeletePrivateConnection": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "DeleteVmwareEngineNetwork": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "FetchNetworkPolicyExternalAddresses": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "GetCluster": { + "timeout_millis": 120000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "GetDnsBindPermission": { + "timeout_millis": 120000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "GetDnsForwarding": { + "timeout_millis": 120000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "GetExternalAccessRule": { + "timeout_millis": 120000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "GetExternalAddress": { + "timeout_millis": 120000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "GetHcxActivationKey": { + "timeout_millis": 120000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "GetLoggingServer": { + "timeout_millis": 120000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "GetManagementDnsZoneBinding": { + "timeout_millis": 120000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "GetNetworkPeering": { + "timeout_millis": 120000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "GetNetworkPolicy": { + "timeout_millis": 120000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "GetNode": { + "timeout_millis": 120000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "GetNodeType": { + "timeout_millis": 120000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "GetPrivateCloud": { + "timeout_millis": 120000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "GetPrivateConnection": { + "timeout_millis": 120000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "GetSubnet": { + "timeout_millis": 120000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "GetVmwareEngineNetwork": { + "timeout_millis": 120000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "GrantDnsBindPermission": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "ListClusters": { + "timeout_millis": 120000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ListExternalAccessRules": { + "timeout_millis": 120000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ListExternalAddresses": { + "timeout_millis": 120000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ListHcxActivationKeys": { + "timeout_millis": 120000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ListLoggingServers": { + "timeout_millis": 120000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ListManagementDnsZoneBindings": { + "timeout_millis": 120000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ListNetworkPeerings": { + "timeout_millis": 120000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ListNetworkPolicies": { + "timeout_millis": 120000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ListNodeTypes": { + "timeout_millis": 120000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ListNodes": { + "timeout_millis": 120000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ListPeeringRoutes": { + "timeout_millis": 120000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ListPrivateClouds": { + "timeout_millis": 120000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ListPrivateConnectionPeeringRoutes": { + "timeout_millis": 120000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ListPrivateConnections": { + "timeout_millis": 120000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ListSubnets": { + "timeout_millis": 120000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ListVmwareEngineNetworks": { + "timeout_millis": 120000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "RepairManagementDnsZoneBinding": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "ResetNsxCredentials": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "ResetVcenterCredentials": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "RevokeDnsBindPermission": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "ShowNsxCredentials": { + "timeout_millis": 120000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ShowVcenterCredentials": { + "timeout_millis": 120000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "UndeletePrivateCloud": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "UpdateCluster": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "UpdateDnsForwarding": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "UpdateExternalAccessRule": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "UpdateExternalAddress": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "UpdateLoggingServer": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "UpdateManagementDnsZoneBinding": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "UpdateNetworkPeering": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "UpdateNetworkPolicy": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "UpdatePrivateCloud": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "UpdatePrivateConnection": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "UpdateSubnet": { + "timeout_millis": 60000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + }, + "UpdateVmwareEngineNetwork": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "GetLocation": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "ListLocations": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "GetIamPolicy": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "SetIamPolicy": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + }, + "TestIamPermissions": { + "timeout_millis": 120000, + "retry_codes_name": "no_retry_2_codes", + "retry_params_name": "no_retry_2_params" + } + } + } + } +} diff --git a/owl-bot-staging/VmwareEngine/v1/src/V1/resources/vmware_engine_descriptor_config.php b/owl-bot-staging/VmwareEngine/v1/src/V1/resources/vmware_engine_descriptor_config.php new file mode 100644 index 000000000000..6ca28d70250a --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/src/V1/resources/vmware_engine_descriptor_config.php @@ -0,0 +1,1430 @@ + [ + 'google.cloud.vmwareengine.v1.VmwareEngine' => [ + 'CreateCluster' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\Cluster', + 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateExternalAccessRule' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\ExternalAccessRule', + 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateExternalAddress' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\ExternalAddress', + 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateHcxActivationKey' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\HcxActivationKey', + 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateLoggingServer' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\LoggingServer', + 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateManagementDnsZoneBinding' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\ManagementDnsZoneBinding', + 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateNetworkPeering' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\NetworkPeering', + 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateNetworkPolicy' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\NetworkPolicy', + 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreatePrivateCloud' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\PrivateCloud', + 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreatePrivateConnection' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\PrivateConnection', + 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'CreateVmwareEngineNetwork' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork', + 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'DeleteCluster' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Protobuf\GPBEmpty', + 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'DeleteExternalAccessRule' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Protobuf\GPBEmpty', + 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'DeleteExternalAddress' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Protobuf\GPBEmpty', + 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'DeleteLoggingServer' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Protobuf\GPBEmpty', + 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'DeleteManagementDnsZoneBinding' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Protobuf\GPBEmpty', + 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'DeleteNetworkPeering' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Protobuf\GPBEmpty', + 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'DeleteNetworkPolicy' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Protobuf\GPBEmpty', + 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'DeletePrivateCloud' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\PrivateCloud', + 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'DeletePrivateConnection' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Protobuf\GPBEmpty', + 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'DeleteVmwareEngineNetwork' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Protobuf\GPBEmpty', + 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GrantDnsBindPermission' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\DnsBindPermission', + 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'RepairManagementDnsZoneBinding' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\ManagementDnsZoneBinding', + 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'ResetNsxCredentials' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\PrivateCloud', + 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'private_cloud', + 'fieldAccessors' => [ + 'getPrivateCloud', + ], + ], + ], + ], + 'ResetVcenterCredentials' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\PrivateCloud', + 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'private_cloud', + 'fieldAccessors' => [ + 'getPrivateCloud', + ], + ], + ], + ], + 'RevokeDnsBindPermission' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\DnsBindPermission', + 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'UndeletePrivateCloud' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\PrivateCloud', + 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'UpdateCluster' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\Cluster', + 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'cluster.name', + 'fieldAccessors' => [ + 'getCluster', + 'getName', + ], + ], + ], + ], + 'UpdateDnsForwarding' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\DnsForwarding', + 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'dns_forwarding.name', + 'fieldAccessors' => [ + 'getDnsForwarding', + 'getName', + ], + ], + ], + ], + 'UpdateExternalAccessRule' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\ExternalAccessRule', + 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'external_access_rule.name', + 'fieldAccessors' => [ + 'getExternalAccessRule', + 'getName', + ], + ], + ], + ], + 'UpdateExternalAddress' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\ExternalAddress', + 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'external_address.name', + 'fieldAccessors' => [ + 'getExternalAddress', + 'getName', + ], + ], + ], + ], + 'UpdateLoggingServer' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\LoggingServer', + 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'logging_server.name', + 'fieldAccessors' => [ + 'getLoggingServer', + 'getName', + ], + ], + ], + ], + 'UpdateManagementDnsZoneBinding' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\ManagementDnsZoneBinding', + 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'management_dns_zone_binding.name', + 'fieldAccessors' => [ + 'getManagementDnsZoneBinding', + 'getName', + ], + ], + ], + ], + 'UpdateNetworkPeering' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\NetworkPeering', + 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'network_peering.name', + 'fieldAccessors' => [ + 'getNetworkPeering', + 'getName', + ], + ], + ], + ], + 'UpdateNetworkPolicy' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\NetworkPolicy', + 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'network_policy.name', + 'fieldAccessors' => [ + 'getNetworkPolicy', + 'getName', + ], + ], + ], + ], + 'UpdatePrivateCloud' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\PrivateCloud', + 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'private_cloud.name', + 'fieldAccessors' => [ + 'getPrivateCloud', + 'getName', + ], + ], + ], + ], + 'UpdatePrivateConnection' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\PrivateConnection', + 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'private_connection.name', + 'fieldAccessors' => [ + 'getPrivateConnection', + 'getName', + ], + ], + ], + ], + 'UpdateSubnet' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\Subnet', + 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'subnet.name', + 'fieldAccessors' => [ + 'getSubnet', + 'getName', + ], + ], + ], + ], + 'UpdateVmwareEngineNetwork' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork', + 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'vmware_engine_network.name', + 'fieldAccessors' => [ + 'getVmwareEngineNetwork', + 'getName', + ], + ], + ], + ], + 'FetchNetworkPolicyExternalAddresses' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getExternalAddresses', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\VmwareEngine\V1\FetchNetworkPolicyExternalAddressesResponse', + 'headerParams' => [ + [ + 'keyName' => 'network_policy', + 'fieldAccessors' => [ + 'getNetworkPolicy', + ], + ], + ], + ], + 'GetCluster' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\VmwareEngine\V1\Cluster', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetDnsBindPermission' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\VmwareEngine\V1\DnsBindPermission', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetDnsForwarding' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\VmwareEngine\V1\DnsForwarding', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetExternalAccessRule' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\VmwareEngine\V1\ExternalAccessRule', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetExternalAddress' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\VmwareEngine\V1\ExternalAddress', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetHcxActivationKey' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\VmwareEngine\V1\HcxActivationKey', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetLoggingServer' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\VmwareEngine\V1\LoggingServer', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetManagementDnsZoneBinding' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\VmwareEngine\V1\ManagementDnsZoneBinding', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetNetworkPeering' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\VmwareEngine\V1\NetworkPeering', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetNetworkPolicy' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\VmwareEngine\V1\NetworkPolicy', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetNode' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\VmwareEngine\V1\Node', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetNodeType' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\VmwareEngine\V1\NodeType', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetPrivateCloud' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\VmwareEngine\V1\PrivateCloud', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetPrivateConnection' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\VmwareEngine\V1\PrivateConnection', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetSubnet' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\VmwareEngine\V1\Subnet', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetVmwareEngineNetwork' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'ListClusters' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getClusters', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\VmwareEngine\V1\ListClustersResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListExternalAccessRules' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getExternalAccessRules', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\VmwareEngine\V1\ListExternalAccessRulesResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListExternalAddresses' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getExternalAddresses', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\VmwareEngine\V1\ListExternalAddressesResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListHcxActivationKeys' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getHcxActivationKeys', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\VmwareEngine\V1\ListHcxActivationKeysResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListLoggingServers' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getLoggingServers', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\VmwareEngine\V1\ListLoggingServersResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListManagementDnsZoneBindings' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getManagementDnsZoneBindings', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\VmwareEngine\V1\ListManagementDnsZoneBindingsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListNetworkPeerings' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getNetworkPeerings', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\VmwareEngine\V1\ListNetworkPeeringsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListNetworkPolicies' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getNetworkPolicies', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\VmwareEngine\V1\ListNetworkPoliciesResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListNodeTypes' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getNodeTypes', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\VmwareEngine\V1\ListNodeTypesResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListNodes' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getNodes', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\VmwareEngine\V1\ListNodesResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListPeeringRoutes' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getPeeringRoutes', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\VmwareEngine\V1\ListPeeringRoutesResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListPrivateClouds' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getPrivateClouds', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\VmwareEngine\V1\ListPrivateCloudsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListPrivateConnectionPeeringRoutes' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getPeeringRoutes', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\VmwareEngine\V1\ListPrivateConnectionPeeringRoutesResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListPrivateConnections' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getPrivateConnections', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\VmwareEngine\V1\ListPrivateConnectionsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListSubnets' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getSubnets', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\VmwareEngine\V1\ListSubnetsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListVmwareEngineNetworks' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getVmwareEngineNetworks', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\VmwareEngine\V1\ListVmwareEngineNetworksResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ShowNsxCredentials' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\VmwareEngine\V1\Credentials', + 'headerParams' => [ + [ + 'keyName' => 'private_cloud', + 'fieldAccessors' => [ + 'getPrivateCloud', + ], + ], + ], + ], + 'ShowVcenterCredentials' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\VmwareEngine\V1\Credentials', + 'headerParams' => [ + [ + 'keyName' => 'private_cloud', + 'fieldAccessors' => [ + 'getPrivateCloud', + ], + ], + ], + ], + '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' => [ + 'cluster' => 'projects/{project}/locations/{location}/privateClouds/{private_cloud}/clusters/{cluster}', + 'dnsBindPermission' => 'projects/{project}/locations/{location}/dnsBindPermission', + 'dnsForwarding' => 'projects/{project}/locations/{location}/privateClouds/{private_cloud}/dnsForwarding', + 'externalAccessRule' => 'projects/{project}/locations/{location}/networkPolicies/{network_policy}/externalAccessRules/{external_access_rule}', + 'externalAddress' => 'projects/{project}/locations/{location}/privateClouds/{private_cloud}/externalAddresses/{external_address}', + 'hcxActivationKey' => 'projects/{project}/locations/{location}/privateClouds/{private_cloud}/hcxActivationKeys/{hcx_activation_key}', + 'location' => 'projects/{project}/locations/{location}', + 'loggingServer' => 'projects/{project}/locations/{location}/privateClouds/{private_cloud}/loggingServers/{logging_server}', + 'managementDnsZoneBinding' => 'projects/{project}/locations/{location}/privateClouds/{private_cloud}/managementDnsZoneBindings/{management_dns_zone_binding}', + 'network' => 'projects/{project}/global/networks/{network}', + 'networkPeering' => 'projects/{project}/locations/{location}/networkPeerings/{network_peering}', + 'networkPolicy' => 'projects/{project}/locations/{location}/networkPolicies/{network_policy}', + 'node' => 'projects/{project}/locations/{location}/privateClouds/{private_cloud}/clusters/{cluster}/nodes/{node}', + 'nodeType' => 'projects/{project}/locations/{location}/nodeTypes/{node_type}', + 'privateCloud' => 'projects/{project}/locations/{location}/privateClouds/{private_cloud}', + 'privateConnection' => 'projects/{project}/locations/{location}/privateConnections/{private_connection}', + 'subnet' => 'projects/{project}/locations/{location}/privateClouds/{private_cloud}/subnets/{subnet}', + 'vmwareEngineNetwork' => 'projects/{project}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network}', + ], + ], + ], +]; diff --git a/owl-bot-staging/VmwareEngine/v1/src/V1/resources/vmware_engine_rest_client_config.php b/owl-bot-staging/VmwareEngine/v1/src/V1/resources/vmware_engine_rest_client_config.php new file mode 100644 index 000000000000..c5a81f84f850 --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/src/V1/resources/vmware_engine_rest_client_config.php @@ -0,0 +1,1083 @@ + [ + '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.cloud.vmwareengine.v1.VmwareEngine' => [ + 'CreateCluster' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*/privateClouds/*}/clusters', + 'body' => 'cluster', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + 'queryParams' => [ + 'cluster_id', + ], + ], + 'CreateExternalAccessRule' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*/networkPolicies/*}/externalAccessRules', + 'body' => 'external_access_rule', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + 'queryParams' => [ + 'external_access_rule_id', + ], + ], + 'CreateExternalAddress' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*/privateClouds/*}/externalAddresses', + 'body' => 'external_address', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + 'queryParams' => [ + 'external_address_id', + ], + ], + 'CreateHcxActivationKey' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*/privateClouds/*}/hcxActivationKeys', + 'body' => 'hcx_activation_key', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + 'queryParams' => [ + 'hcx_activation_key_id', + ], + ], + 'CreateLoggingServer' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*/privateClouds/*}/loggingServers', + 'body' => 'logging_server', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + 'queryParams' => [ + 'logging_server_id', + ], + ], + 'CreateManagementDnsZoneBinding' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*/privateClouds/*}/managementDnsZoneBindings', + 'body' => 'management_dns_zone_binding', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + 'queryParams' => [ + 'management_dns_zone_binding_id', + ], + ], + 'CreateNetworkPeering' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/networkPeerings', + 'body' => 'network_peering', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + 'queryParams' => [ + 'network_peering_id', + ], + ], + 'CreateNetworkPolicy' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/networkPolicies', + 'body' => 'network_policy', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + 'queryParams' => [ + 'network_policy_id', + ], + ], + 'CreatePrivateCloud' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/privateClouds', + 'body' => 'private_cloud', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + 'queryParams' => [ + 'private_cloud_id', + ], + ], + 'CreatePrivateConnection' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/privateConnections', + 'body' => 'private_connection', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + 'queryParams' => [ + 'private_connection_id', + ], + ], + 'CreateVmwareEngineNetwork' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/vmwareEngineNetworks', + 'body' => 'vmware_engine_network', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + 'queryParams' => [ + 'vmware_engine_network_id', + ], + ], + 'DeleteCluster' => [ + 'method' => 'delete', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/privateClouds/*/clusters/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'DeleteExternalAccessRule' => [ + 'method' => 'delete', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/networkPolicies/*/externalAccessRules/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'DeleteExternalAddress' => [ + 'method' => 'delete', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/privateClouds/*/externalAddresses/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'DeleteLoggingServer' => [ + 'method' => 'delete', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/privateClouds/*/loggingServers/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'DeleteManagementDnsZoneBinding' => [ + 'method' => 'delete', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/privateClouds/*/managementDnsZoneBindings/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'DeleteNetworkPeering' => [ + 'method' => 'delete', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/networkPeerings/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'DeleteNetworkPolicy' => [ + 'method' => 'delete', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/networkPolicies/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'DeletePrivateCloud' => [ + 'method' => 'delete', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/privateClouds/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'DeletePrivateConnection' => [ + 'method' => 'delete', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/privateConnections/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'DeleteVmwareEngineNetwork' => [ + 'method' => 'delete', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/vmwareEngineNetworks/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'FetchNetworkPolicyExternalAddresses' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{network_policy=projects/*/locations/*/networkPolicies/*}:fetchExternalAddresses', + 'placeholders' => [ + 'network_policy' => [ + 'getters' => [ + 'getNetworkPolicy', + ], + ], + ], + ], + 'GetCluster' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/privateClouds/*/clusters/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetDnsBindPermission' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/dnsBindPermission}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetDnsForwarding' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/privateClouds/*/dnsForwarding}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetExternalAccessRule' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/networkPolicies/*/externalAccessRules/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetExternalAddress' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/privateClouds/*/externalAddresses/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetHcxActivationKey' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/privateClouds/*/hcxActivationKeys/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetLoggingServer' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/privateClouds/*/loggingServers/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetManagementDnsZoneBinding' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/privateClouds/*/managementDnsZoneBindings/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetNetworkPeering' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/networkPeerings/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetNetworkPolicy' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/networkPolicies/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetNode' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/privateClouds/*/clusters/*/nodes/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetNodeType' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/nodeTypes/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetPrivateCloud' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/privateClouds/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetPrivateConnection' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/privateConnections/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetSubnet' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/privateClouds/*/subnets/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetVmwareEngineNetwork' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/vmwareEngineNetworks/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GrantDnsBindPermission' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/dnsBindPermission}:grant', + 'body' => '*', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'ListClusters' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*/privateClouds/*}/clusters', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListExternalAccessRules' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*/networkPolicies/*}/externalAccessRules', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListExternalAddresses' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*/privateClouds/*}/externalAddresses', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListHcxActivationKeys' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*/privateClouds/*}/hcxActivationKeys', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListLoggingServers' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*/privateClouds/*}/loggingServers', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListManagementDnsZoneBindings' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*/privateClouds/*}/managementDnsZoneBindings', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListNetworkPeerings' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/networkPeerings', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListNetworkPolicies' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/networkPolicies', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListNodeTypes' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/nodeTypes', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListNodes' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*/privateClouds/*/clusters/*}/nodes', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListPeeringRoutes' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*/networkPeerings/*}/peeringRoutes', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListPrivateClouds' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/privateClouds', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListPrivateConnectionPeeringRoutes' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*/privateConnections/*}/peeringRoutes', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListPrivateConnections' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/privateConnections', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListSubnets' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*/privateClouds/*}/subnets', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListVmwareEngineNetworks' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/vmwareEngineNetworks', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'RepairManagementDnsZoneBinding' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/privateClouds/*/managementDnsZoneBindings/*}:repair', + 'body' => '*', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'ResetNsxCredentials' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{private_cloud=projects/*/locations/*/privateClouds/*}:resetNsxCredentials', + 'body' => '*', + 'placeholders' => [ + 'private_cloud' => [ + 'getters' => [ + 'getPrivateCloud', + ], + ], + ], + ], + 'ResetVcenterCredentials' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{private_cloud=projects/*/locations/*/privateClouds/*}:resetVcenterCredentials', + 'body' => '*', + 'placeholders' => [ + 'private_cloud' => [ + 'getters' => [ + 'getPrivateCloud', + ], + ], + ], + ], + 'RevokeDnsBindPermission' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/dnsBindPermission}:revoke', + 'body' => '*', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'ShowNsxCredentials' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{private_cloud=projects/*/locations/*/privateClouds/*}:showNsxCredentials', + 'placeholders' => [ + 'private_cloud' => [ + 'getters' => [ + 'getPrivateCloud', + ], + ], + ], + ], + 'ShowVcenterCredentials' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{private_cloud=projects/*/locations/*/privateClouds/*}:showVcenterCredentials', + 'placeholders' => [ + 'private_cloud' => [ + 'getters' => [ + 'getPrivateCloud', + ], + ], + ], + ], + 'UndeletePrivateCloud' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/privateClouds/*}:undelete', + 'body' => '*', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'UpdateCluster' => [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{cluster.name=projects/*/locations/*/privateClouds/*/clusters/*}', + 'body' => 'cluster', + 'placeholders' => [ + 'cluster.name' => [ + 'getters' => [ + 'getCluster', + 'getName', + ], + ], + ], + 'queryParams' => [ + 'update_mask', + ], + ], + 'UpdateDnsForwarding' => [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{dns_forwarding.name=projects/*/locations/*/privateClouds/*/dnsForwarding}', + 'body' => 'dns_forwarding', + 'placeholders' => [ + 'dns_forwarding.name' => [ + 'getters' => [ + 'getDnsForwarding', + 'getName', + ], + ], + ], + 'queryParams' => [ + 'update_mask', + ], + ], + 'UpdateExternalAccessRule' => [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{external_access_rule.name=projects/*/locations/*/networkPolicies/*/externalAccessRules/*}', + 'body' => 'external_access_rule', + 'placeholders' => [ + 'external_access_rule.name' => [ + 'getters' => [ + 'getExternalAccessRule', + 'getName', + ], + ], + ], + 'queryParams' => [ + 'update_mask', + ], + ], + 'UpdateExternalAddress' => [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{external_address.name=projects/*/locations/*/privateClouds/*/externalAddresses/*}', + 'body' => 'external_address', + 'placeholders' => [ + 'external_address.name' => [ + 'getters' => [ + 'getExternalAddress', + 'getName', + ], + ], + ], + 'queryParams' => [ + 'update_mask', + ], + ], + 'UpdateLoggingServer' => [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{logging_server.name=projects/*/locations/*/privateClouds/*/loggingServers/*}', + 'body' => 'logging_server', + 'placeholders' => [ + 'logging_server.name' => [ + 'getters' => [ + 'getLoggingServer', + 'getName', + ], + ], + ], + 'queryParams' => [ + 'update_mask', + ], + ], + 'UpdateManagementDnsZoneBinding' => [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{management_dns_zone_binding.name=projects/*/locations/*/privateClouds/*/managementDnsZoneBindings/*}', + 'body' => 'management_dns_zone_binding', + 'placeholders' => [ + 'management_dns_zone_binding.name' => [ + 'getters' => [ + 'getManagementDnsZoneBinding', + 'getName', + ], + ], + ], + 'queryParams' => [ + 'update_mask', + ], + ], + 'UpdateNetworkPeering' => [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{network_peering.name=projects/*/locations/*/networkPeerings/*}', + 'body' => 'network_peering', + 'placeholders' => [ + 'network_peering.name' => [ + 'getters' => [ + 'getNetworkPeering', + 'getName', + ], + ], + ], + 'queryParams' => [ + 'update_mask', + ], + ], + 'UpdateNetworkPolicy' => [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{network_policy.name=projects/*/locations/*/networkPolicies/*}', + 'body' => 'network_policy', + 'placeholders' => [ + 'network_policy.name' => [ + 'getters' => [ + 'getNetworkPolicy', + 'getName', + ], + ], + ], + 'queryParams' => [ + 'update_mask', + ], + ], + 'UpdatePrivateCloud' => [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{private_cloud.name=projects/*/locations/*/privateClouds/*}', + 'body' => 'private_cloud', + 'placeholders' => [ + 'private_cloud.name' => [ + 'getters' => [ + 'getPrivateCloud', + 'getName', + ], + ], + ], + 'queryParams' => [ + 'update_mask', + ], + ], + 'UpdatePrivateConnection' => [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{private_connection.name=projects/*/locations/*/privateConnections/*}', + 'body' => 'private_connection', + 'placeholders' => [ + 'private_connection.name' => [ + 'getters' => [ + 'getPrivateConnection', + 'getName', + ], + ], + ], + 'queryParams' => [ + 'update_mask', + ], + ], + 'UpdateSubnet' => [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{subnet.name=projects/*/locations/*/privateClouds/*/subnets/*}', + 'body' => 'subnet', + 'placeholders' => [ + 'subnet.name' => [ + 'getters' => [ + 'getSubnet', + 'getName', + ], + ], + ], + 'queryParams' => [ + 'update_mask', + ], + ], + 'UpdateVmwareEngineNetwork' => [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{vmware_engine_network.name=projects/*/locations/*/vmwareEngineNetworks/*}', + 'body' => 'vmware_engine_network', + 'placeholders' => [ + 'vmware_engine_network.name' => [ + 'getters' => [ + 'getVmwareEngineNetwork', + 'getName', + ], + ], + ], + 'queryParams' => [ + 'update_mask', + ], + ], + ], + 'google.iam.v1.IAMPolicy' => [ + 'GetIamPolicy' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{resource=projects/*/locations/*/privateClouds/*}:getIamPolicy', + 'additionalBindings' => [ + [ + 'method' => 'get', + 'uriTemplate' => '/v1/{resource=projects/*/locations/*/privateClouds/*/clusters/*}:getIamPolicy', + ], + [ + 'method' => 'get', + 'uriTemplate' => '/v1/{resource=projects/*/locations/*/privateClouds/*/hcxActivationKeys/*}:getIamPolicy', + ], + ], + 'placeholders' => [ + 'resource' => [ + 'getters' => [ + 'getResource', + ], + ], + ], + ], + 'SetIamPolicy' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{resource=projects/*/locations/*/privateClouds/*}:setIamPolicy', + 'body' => '*', + 'additionalBindings' => [ + [ + 'method' => 'post', + 'uriTemplate' => '/v1/{resource=projects/*/locations/*/privateClouds/*/clusters/*}:setIamPolicy', + 'body' => '*', + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v1/{resource=projects/*/locations/*/privateClouds/*/hcxActivationKeys/*}:setIamPolicy', + 'body' => '*', + ], + ], + 'placeholders' => [ + 'resource' => [ + 'getters' => [ + 'getResource', + ], + ], + ], + ], + 'TestIamPermissions' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{resource=projects/*/locations/*/privateClouds/*}:testIamPermissions', + 'body' => '*', + 'additionalBindings' => [ + [ + 'method' => 'post', + 'uriTemplate' => '/v1/{resource=projects/*/locations/*/privateClouds/*/clusters/*}:testIamPermissions', + 'body' => '*', + ], + [ + 'method' => 'post', + 'uriTemplate' => '/v1/{resource=projects/*/locations/*/privateClouds/*/hcxActivationKeys/*}:testIamPermissions', + 'body' => '*', + ], + ], + 'placeholders' => [ + 'resource' => [ + 'getters' => [ + 'getResource', + ], + ], + ], + ], + ], + 'google.longrunning.Operations' => [ + '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/VmwareEngine/v1/tests/Unit/V1/Client/VmwareEngineClientTest.php b/owl-bot-staging/VmwareEngine/v1/tests/Unit/V1/Client/VmwareEngineClientTest.php new file mode 100644 index 000000000000..5152911fa8be --- /dev/null +++ b/owl-bot-staging/VmwareEngine/v1/tests/Unit/V1/Client/VmwareEngineClientTest.php @@ -0,0 +1,8496 @@ +getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); + } + + /** @return VmwareEngineClient */ + private function createClient(array $options = []) + { + $options += [ + 'credentials' => $this->createCredentials(), + ]; + return new VmwareEngineClient($options); + } + + /** @test */ + public function createClusterTest() + { + $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/createClusterTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $management = false; + $uid = 'uid115792'; + $expectedResponse = new Cluster(); + $expectedResponse->setName($name); + $expectedResponse->setManagement($management); + $expectedResponse->setUid($uid); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/createClusterTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedParent = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); + $clusterId = 'clusterId240280960'; + $cluster = new Cluster(); + $nodeTypeConfigsValue = new NodeTypeConfig(); + $valueNodeCount = 1174748740; + $nodeTypeConfigsValue->setNodeCount($valueNodeCount); + $clusterNodeTypeConfigs = [ + 'nodeTypeConfigsKey' => $nodeTypeConfigsValue, + ]; + $cluster->setNodeTypeConfigs($clusterNodeTypeConfigs); + $request = (new CreateClusterRequest()) + ->setParent($formattedParent) + ->setClusterId($clusterId) + ->setCluster($cluster); + $response = $gapicClient->createCluster($request); + $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.vmwareengine.v1.VmwareEngine/CreateCluster', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualApiRequestObject->getClusterId(); + $this->assertProtobufEquals($clusterId, $actualValue); + $actualValue = $actualApiRequestObject->getCluster(); + $this->assertProtobufEquals($cluster, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createClusterTest'); + $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 createClusterExceptionTest() + { + $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/createClusterTest'); + $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->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); + $clusterId = 'clusterId240280960'; + $cluster = new Cluster(); + $nodeTypeConfigsValue = new NodeTypeConfig(); + $valueNodeCount = 1174748740; + $nodeTypeConfigsValue->setNodeCount($valueNodeCount); + $clusterNodeTypeConfigs = [ + 'nodeTypeConfigsKey' => $nodeTypeConfigsValue, + ]; + $cluster->setNodeTypeConfigs($clusterNodeTypeConfigs); + $request = (new CreateClusterRequest()) + ->setParent($formattedParent) + ->setClusterId($clusterId) + ->setCluster($cluster); + $response = $gapicClient->createCluster($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createClusterTest'); + 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 createExternalAccessRuleTest() + { + $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/createExternalAccessRuleTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $description = 'description-1724546052'; + $priority = 1165461084; + $ipProtocol = 'ipProtocol-1134653776'; + $uid = 'uid115792'; + $expectedResponse = new ExternalAccessRule(); + $expectedResponse->setName($name); + $expectedResponse->setDescription($description); + $expectedResponse->setPriority($priority); + $expectedResponse->setIpProtocol($ipProtocol); + $expectedResponse->setUid($uid); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/createExternalAccessRuleTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedParent = $gapicClient->networkPolicyName('[PROJECT]', '[LOCATION]', '[NETWORK_POLICY]'); + $externalAccessRule = new ExternalAccessRule(); + $externalAccessRuleId = 'externalAccessRuleId1434975319'; + $request = (new CreateExternalAccessRuleRequest()) + ->setParent($formattedParent) + ->setExternalAccessRule($externalAccessRule) + ->setExternalAccessRuleId($externalAccessRuleId); + $response = $gapicClient->createExternalAccessRule($request); + $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.vmwareengine.v1.VmwareEngine/CreateExternalAccessRule', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualApiRequestObject->getExternalAccessRule(); + $this->assertProtobufEquals($externalAccessRule, $actualValue); + $actualValue = $actualApiRequestObject->getExternalAccessRuleId(); + $this->assertProtobufEquals($externalAccessRuleId, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createExternalAccessRuleTest'); + $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 createExternalAccessRuleExceptionTest() + { + $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/createExternalAccessRuleTest'); + $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->networkPolicyName('[PROJECT]', '[LOCATION]', '[NETWORK_POLICY]'); + $externalAccessRule = new ExternalAccessRule(); + $externalAccessRuleId = 'externalAccessRuleId1434975319'; + $request = (new CreateExternalAccessRuleRequest()) + ->setParent($formattedParent) + ->setExternalAccessRule($externalAccessRule) + ->setExternalAccessRuleId($externalAccessRuleId); + $response = $gapicClient->createExternalAccessRule($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createExternalAccessRuleTest'); + 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 createExternalAddressTest() + { + $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/createExternalAddressTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $internalIp = 'internalIp-2080778775'; + $externalIp = 'externalIp-1153075685'; + $uid = 'uid115792'; + $description = 'description-1724546052'; + $expectedResponse = new ExternalAddress(); + $expectedResponse->setName($name); + $expectedResponse->setInternalIp($internalIp); + $expectedResponse->setExternalIp($externalIp); + $expectedResponse->setUid($uid); + $expectedResponse->setDescription($description); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/createExternalAddressTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedParent = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); + $externalAddress = new ExternalAddress(); + $externalAddressId = 'externalAddressId344331834'; + $request = (new CreateExternalAddressRequest()) + ->setParent($formattedParent) + ->setExternalAddress($externalAddress) + ->setExternalAddressId($externalAddressId); + $response = $gapicClient->createExternalAddress($request); + $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.vmwareengine.v1.VmwareEngine/CreateExternalAddress', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualApiRequestObject->getExternalAddress(); + $this->assertProtobufEquals($externalAddress, $actualValue); + $actualValue = $actualApiRequestObject->getExternalAddressId(); + $this->assertProtobufEquals($externalAddressId, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createExternalAddressTest'); + $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 createExternalAddressExceptionTest() + { + $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/createExternalAddressTest'); + $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->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); + $externalAddress = new ExternalAddress(); + $externalAddressId = 'externalAddressId344331834'; + $request = (new CreateExternalAddressRequest()) + ->setParent($formattedParent) + ->setExternalAddress($externalAddress) + ->setExternalAddressId($externalAddressId); + $response = $gapicClient->createExternalAddress($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createExternalAddressTest'); + 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 createHcxActivationKeyTest() + { + $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/createHcxActivationKeyTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $activationKey = 'activationKey-1343958090'; + $uid = 'uid115792'; + $expectedResponse = new HcxActivationKey(); + $expectedResponse->setName($name); + $expectedResponse->setActivationKey($activationKey); + $expectedResponse->setUid($uid); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/createHcxActivationKeyTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedParent = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); + $hcxActivationKey = new HcxActivationKey(); + $hcxActivationKeyId = 'hcxActivationKeyId26532194'; + $request = (new CreateHcxActivationKeyRequest()) + ->setParent($formattedParent) + ->setHcxActivationKey($hcxActivationKey) + ->setHcxActivationKeyId($hcxActivationKeyId); + $response = $gapicClient->createHcxActivationKey($request); + $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.vmwareengine.v1.VmwareEngine/CreateHcxActivationKey', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualApiRequestObject->getHcxActivationKey(); + $this->assertProtobufEquals($hcxActivationKey, $actualValue); + $actualValue = $actualApiRequestObject->getHcxActivationKeyId(); + $this->assertProtobufEquals($hcxActivationKeyId, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createHcxActivationKeyTest'); + $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 createHcxActivationKeyExceptionTest() + { + $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/createHcxActivationKeyTest'); + $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->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); + $hcxActivationKey = new HcxActivationKey(); + $hcxActivationKeyId = 'hcxActivationKeyId26532194'; + $request = (new CreateHcxActivationKeyRequest()) + ->setParent($formattedParent) + ->setHcxActivationKey($hcxActivationKey) + ->setHcxActivationKeyId($hcxActivationKeyId); + $response = $gapicClient->createHcxActivationKey($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createHcxActivationKeyTest'); + 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 createLoggingServerTest() + { + $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/createLoggingServerTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $hostname = 'hostname-299803597'; + $port = 3446913; + $uid = 'uid115792'; + $expectedResponse = new LoggingServer(); + $expectedResponse->setName($name); + $expectedResponse->setHostname($hostname); + $expectedResponse->setPort($port); + $expectedResponse->setUid($uid); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/createLoggingServerTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedParent = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); + $loggingServer = new LoggingServer(); + $loggingServerHostname = 'loggingServerHostname2082652629'; + $loggingServer->setHostname($loggingServerHostname); + $loggingServerPort = 243392733; + $loggingServer->setPort($loggingServerPort); + $loggingServerProtocol = Protocol::PROTOCOL_UNSPECIFIED; + $loggingServer->setProtocol($loggingServerProtocol); + $loggingServerSourceType = SourceType::SOURCE_TYPE_UNSPECIFIED; + $loggingServer->setSourceType($loggingServerSourceType); + $loggingServerId = 'loggingServerId-2097171785'; + $request = (new CreateLoggingServerRequest()) + ->setParent($formattedParent) + ->setLoggingServer($loggingServer) + ->setLoggingServerId($loggingServerId); + $response = $gapicClient->createLoggingServer($request); + $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.vmwareengine.v1.VmwareEngine/CreateLoggingServer', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualApiRequestObject->getLoggingServer(); + $this->assertProtobufEquals($loggingServer, $actualValue); + $actualValue = $actualApiRequestObject->getLoggingServerId(); + $this->assertProtobufEquals($loggingServerId, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createLoggingServerTest'); + $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 createLoggingServerExceptionTest() + { + $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/createLoggingServerTest'); + $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->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); + $loggingServer = new LoggingServer(); + $loggingServerHostname = 'loggingServerHostname2082652629'; + $loggingServer->setHostname($loggingServerHostname); + $loggingServerPort = 243392733; + $loggingServer->setPort($loggingServerPort); + $loggingServerProtocol = Protocol::PROTOCOL_UNSPECIFIED; + $loggingServer->setProtocol($loggingServerProtocol); + $loggingServerSourceType = SourceType::SOURCE_TYPE_UNSPECIFIED; + $loggingServer->setSourceType($loggingServerSourceType); + $loggingServerId = 'loggingServerId-2097171785'; + $request = (new CreateLoggingServerRequest()) + ->setParent($formattedParent) + ->setLoggingServer($loggingServer) + ->setLoggingServerId($loggingServerId); + $response = $gapicClient->createLoggingServer($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createLoggingServerTest'); + 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 createManagementDnsZoneBindingTest() + { + $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/createManagementDnsZoneBindingTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $description = 'description-1724546052'; + $vpcNetwork = 'vpcNetwork-764161832'; + $uid = 'uid115792'; + $expectedResponse = new ManagementDnsZoneBinding(); + $expectedResponse->setName($name); + $expectedResponse->setDescription($description); + $expectedResponse->setVpcNetwork($vpcNetwork); + $expectedResponse->setUid($uid); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/createManagementDnsZoneBindingTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedParent = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); + $managementDnsZoneBinding = new ManagementDnsZoneBinding(); + $managementDnsZoneBindingId = 'managementDnsZoneBindingId-1294625162'; + $request = (new CreateManagementDnsZoneBindingRequest()) + ->setParent($formattedParent) + ->setManagementDnsZoneBinding($managementDnsZoneBinding) + ->setManagementDnsZoneBindingId($managementDnsZoneBindingId); + $response = $gapicClient->createManagementDnsZoneBinding($request); + $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.vmwareengine.v1.VmwareEngine/CreateManagementDnsZoneBinding', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualApiRequestObject->getManagementDnsZoneBinding(); + $this->assertProtobufEquals($managementDnsZoneBinding, $actualValue); + $actualValue = $actualApiRequestObject->getManagementDnsZoneBindingId(); + $this->assertProtobufEquals($managementDnsZoneBindingId, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createManagementDnsZoneBindingTest'); + $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 createManagementDnsZoneBindingExceptionTest() + { + $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/createManagementDnsZoneBindingTest'); + $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->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); + $managementDnsZoneBinding = new ManagementDnsZoneBinding(); + $managementDnsZoneBindingId = 'managementDnsZoneBindingId-1294625162'; + $request = (new CreateManagementDnsZoneBindingRequest()) + ->setParent($formattedParent) + ->setManagementDnsZoneBinding($managementDnsZoneBinding) + ->setManagementDnsZoneBindingId($managementDnsZoneBindingId); + $response = $gapicClient->createManagementDnsZoneBinding($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createManagementDnsZoneBindingTest'); + 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 createNetworkPeeringTest() + { + $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/createNetworkPeeringTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $peerNetwork = 'peerNetwork2111238225'; + $exportCustomRoutes = false; + $importCustomRoutes = true; + $exchangeSubnetRoutes = true; + $exportCustomRoutesWithPublicIp = true; + $importCustomRoutesWithPublicIp = false; + $stateDetails = 'stateDetails632437908'; + $peerMtu = 69584721; + $uid = 'uid115792'; + $vmwareEngineNetwork = 'vmwareEngineNetwork-90899684'; + $description = 'description-1724546052'; + $expectedResponse = new NetworkPeering(); + $expectedResponse->setName($name); + $expectedResponse->setPeerNetwork($peerNetwork); + $expectedResponse->setExportCustomRoutes($exportCustomRoutes); + $expectedResponse->setImportCustomRoutes($importCustomRoutes); + $expectedResponse->setExchangeSubnetRoutes($exchangeSubnetRoutes); + $expectedResponse->setExportCustomRoutesWithPublicIp($exportCustomRoutesWithPublicIp); + $expectedResponse->setImportCustomRoutesWithPublicIp($importCustomRoutesWithPublicIp); + $expectedResponse->setStateDetails($stateDetails); + $expectedResponse->setPeerMtu($peerMtu); + $expectedResponse->setUid($uid); + $expectedResponse->setVmwareEngineNetwork($vmwareEngineNetwork); + $expectedResponse->setDescription($description); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/createNetworkPeeringTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); + $networkPeeringId = 'networkPeeringId-2057959125'; + $networkPeering = new NetworkPeering(); + $networkPeeringPeerNetwork = 'networkPeeringPeerNetwork-385302054'; + $networkPeering->setPeerNetwork($networkPeeringPeerNetwork); + $networkPeeringPeerNetworkType = PeerNetworkType::PEER_NETWORK_TYPE_UNSPECIFIED; + $networkPeering->setPeerNetworkType($networkPeeringPeerNetworkType); + $networkPeeringVmwareEngineNetwork = $gapicClient->vmwareEngineNetworkName('[PROJECT]', '[LOCATION]', '[VMWARE_ENGINE_NETWORK]'); + $networkPeering->setVmwareEngineNetwork($networkPeeringVmwareEngineNetwork); + $request = (new CreateNetworkPeeringRequest()) + ->setParent($formattedParent) + ->setNetworkPeeringId($networkPeeringId) + ->setNetworkPeering($networkPeering); + $response = $gapicClient->createNetworkPeering($request); + $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.vmwareengine.v1.VmwareEngine/CreateNetworkPeering', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualApiRequestObject->getNetworkPeeringId(); + $this->assertProtobufEquals($networkPeeringId, $actualValue); + $actualValue = $actualApiRequestObject->getNetworkPeering(); + $this->assertProtobufEquals($networkPeering, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createNetworkPeeringTest'); + $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 createNetworkPeeringExceptionTest() + { + $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/createNetworkPeeringTest'); + $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]'); + $networkPeeringId = 'networkPeeringId-2057959125'; + $networkPeering = new NetworkPeering(); + $networkPeeringPeerNetwork = 'networkPeeringPeerNetwork-385302054'; + $networkPeering->setPeerNetwork($networkPeeringPeerNetwork); + $networkPeeringPeerNetworkType = PeerNetworkType::PEER_NETWORK_TYPE_UNSPECIFIED; + $networkPeering->setPeerNetworkType($networkPeeringPeerNetworkType); + $networkPeeringVmwareEngineNetwork = $gapicClient->vmwareEngineNetworkName('[PROJECT]', '[LOCATION]', '[VMWARE_ENGINE_NETWORK]'); + $networkPeering->setVmwareEngineNetwork($networkPeeringVmwareEngineNetwork); + $request = (new CreateNetworkPeeringRequest()) + ->setParent($formattedParent) + ->setNetworkPeeringId($networkPeeringId) + ->setNetworkPeering($networkPeering); + $response = $gapicClient->createNetworkPeering($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createNetworkPeeringTest'); + 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 createNetworkPolicyTest() + { + $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/createNetworkPolicyTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $edgeServicesCidr = 'edgeServicesCidr-792872013'; + $uid = 'uid115792'; + $vmwareEngineNetwork = 'vmwareEngineNetwork-90899684'; + $description = 'description-1724546052'; + $vmwareEngineNetworkCanonical = 'vmwareEngineNetworkCanonical779839377'; + $expectedResponse = new NetworkPolicy(); + $expectedResponse->setName($name); + $expectedResponse->setEdgeServicesCidr($edgeServicesCidr); + $expectedResponse->setUid($uid); + $expectedResponse->setVmwareEngineNetwork($vmwareEngineNetwork); + $expectedResponse->setDescription($description); + $expectedResponse->setVmwareEngineNetworkCanonical($vmwareEngineNetworkCanonical); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/createNetworkPolicyTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); + $networkPolicyId = 'networkPolicyId173955703'; + $networkPolicy = new NetworkPolicy(); + $networkPolicyEdgeServicesCidr = 'networkPolicyEdgeServicesCidr-602005393'; + $networkPolicy->setEdgeServicesCidr($networkPolicyEdgeServicesCidr); + $request = (new CreateNetworkPolicyRequest()) + ->setParent($formattedParent) + ->setNetworkPolicyId($networkPolicyId) + ->setNetworkPolicy($networkPolicy); + $response = $gapicClient->createNetworkPolicy($request); + $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.vmwareengine.v1.VmwareEngine/CreateNetworkPolicy', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualApiRequestObject->getNetworkPolicyId(); + $this->assertProtobufEquals($networkPolicyId, $actualValue); + $actualValue = $actualApiRequestObject->getNetworkPolicy(); + $this->assertProtobufEquals($networkPolicy, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createNetworkPolicyTest'); + $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 createNetworkPolicyExceptionTest() + { + $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/createNetworkPolicyTest'); + $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]'); + $networkPolicyId = 'networkPolicyId173955703'; + $networkPolicy = new NetworkPolicy(); + $networkPolicyEdgeServicesCidr = 'networkPolicyEdgeServicesCidr-602005393'; + $networkPolicy->setEdgeServicesCidr($networkPolicyEdgeServicesCidr); + $request = (new CreateNetworkPolicyRequest()) + ->setParent($formattedParent) + ->setNetworkPolicyId($networkPolicyId) + ->setNetworkPolicy($networkPolicy); + $response = $gapicClient->createNetworkPolicy($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createNetworkPolicyTest'); + 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 createPrivateCloudTest() + { + $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/createPrivateCloudTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $description = 'description-1724546052'; + $uid = 'uid115792'; + $expectedResponse = new PrivateCloud(); + $expectedResponse->setName($name); + $expectedResponse->setDescription($description); + $expectedResponse->setUid($uid); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/createPrivateCloudTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); + $privateCloudId = 'privateCloudId1366391457'; + $privateCloud = new PrivateCloud(); + $privateCloudNetworkConfig = new NetworkConfig(); + $networkConfigManagementCidr = 'networkConfigManagementCidr2092091783'; + $privateCloudNetworkConfig->setManagementCidr($networkConfigManagementCidr); + $privateCloud->setNetworkConfig($privateCloudNetworkConfig); + $privateCloudManagementCluster = new ManagementCluster(); + $managementClusterClusterId = 'managementClusterClusterId311493182'; + $privateCloudManagementCluster->setClusterId($managementClusterClusterId); + $nodeTypeConfigsValue = new NodeTypeConfig(); + $valueNodeCount = 1174748740; + $nodeTypeConfigsValue->setNodeCount($valueNodeCount); + $managementClusterNodeTypeConfigs = [ + 'nodeTypeConfigsKey' => $nodeTypeConfigsValue, + ]; + $privateCloudManagementCluster->setNodeTypeConfigs($managementClusterNodeTypeConfigs); + $privateCloud->setManagementCluster($privateCloudManagementCluster); + $request = (new CreatePrivateCloudRequest()) + ->setParent($formattedParent) + ->setPrivateCloudId($privateCloudId) + ->setPrivateCloud($privateCloud); + $response = $gapicClient->createPrivateCloud($request); + $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.vmwareengine.v1.VmwareEngine/CreatePrivateCloud', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualApiRequestObject->getPrivateCloudId(); + $this->assertProtobufEquals($privateCloudId, $actualValue); + $actualValue = $actualApiRequestObject->getPrivateCloud(); + $this->assertProtobufEquals($privateCloud, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createPrivateCloudTest'); + $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 createPrivateCloudExceptionTest() + { + $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/createPrivateCloudTest'); + $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]'); + $privateCloudId = 'privateCloudId1366391457'; + $privateCloud = new PrivateCloud(); + $privateCloudNetworkConfig = new NetworkConfig(); + $networkConfigManagementCidr = 'networkConfigManagementCidr2092091783'; + $privateCloudNetworkConfig->setManagementCidr($networkConfigManagementCidr); + $privateCloud->setNetworkConfig($privateCloudNetworkConfig); + $privateCloudManagementCluster = new ManagementCluster(); + $managementClusterClusterId = 'managementClusterClusterId311493182'; + $privateCloudManagementCluster->setClusterId($managementClusterClusterId); + $nodeTypeConfigsValue = new NodeTypeConfig(); + $valueNodeCount = 1174748740; + $nodeTypeConfigsValue->setNodeCount($valueNodeCount); + $managementClusterNodeTypeConfigs = [ + 'nodeTypeConfigsKey' => $nodeTypeConfigsValue, + ]; + $privateCloudManagementCluster->setNodeTypeConfigs($managementClusterNodeTypeConfigs); + $privateCloud->setManagementCluster($privateCloudManagementCluster); + $request = (new CreatePrivateCloudRequest()) + ->setParent($formattedParent) + ->setPrivateCloudId($privateCloudId) + ->setPrivateCloud($privateCloud); + $response = $gapicClient->createPrivateCloud($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createPrivateCloudTest'); + 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 createPrivateConnectionTest() + { + $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/createPrivateConnectionTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $description = 'description-1724546052'; + $vmwareEngineNetwork = 'vmwareEngineNetwork-90899684'; + $vmwareEngineNetworkCanonical = 'vmwareEngineNetworkCanonical779839377'; + $peeringId = 'peeringId-1561749894'; + $uid = 'uid115792'; + $serviceNetwork = 'serviceNetwork1072775844'; + $expectedResponse = new PrivateConnection(); + $expectedResponse->setName($name); + $expectedResponse->setDescription($description); + $expectedResponse->setVmwareEngineNetwork($vmwareEngineNetwork); + $expectedResponse->setVmwareEngineNetworkCanonical($vmwareEngineNetworkCanonical); + $expectedResponse->setPeeringId($peeringId); + $expectedResponse->setUid($uid); + $expectedResponse->setServiceNetwork($serviceNetwork); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/createPrivateConnectionTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); + $privateConnectionId = 'privateConnectionId-1948601248'; + $privateConnection = new PrivateConnection(); + $privateConnectionVmwareEngineNetwork = $gapicClient->vmwareEngineNetworkName('[PROJECT]', '[LOCATION]', '[VMWARE_ENGINE_NETWORK]'); + $privateConnection->setVmwareEngineNetwork($privateConnectionVmwareEngineNetwork); + $privateConnectionType = Type::TYPE_UNSPECIFIED; + $privateConnection->setType($privateConnectionType); + $privateConnectionServiceNetwork = $gapicClient->networkName('[PROJECT]', '[NETWORK]'); + $privateConnection->setServiceNetwork($privateConnectionServiceNetwork); + $request = (new CreatePrivateConnectionRequest()) + ->setParent($formattedParent) + ->setPrivateConnectionId($privateConnectionId) + ->setPrivateConnection($privateConnection); + $response = $gapicClient->createPrivateConnection($request); + $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.vmwareengine.v1.VmwareEngine/CreatePrivateConnection', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualApiRequestObject->getPrivateConnectionId(); + $this->assertProtobufEquals($privateConnectionId, $actualValue); + $actualValue = $actualApiRequestObject->getPrivateConnection(); + $this->assertProtobufEquals($privateConnection, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createPrivateConnectionTest'); + $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 createPrivateConnectionExceptionTest() + { + $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/createPrivateConnectionTest'); + $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]'); + $privateConnectionId = 'privateConnectionId-1948601248'; + $privateConnection = new PrivateConnection(); + $privateConnectionVmwareEngineNetwork = $gapicClient->vmwareEngineNetworkName('[PROJECT]', '[LOCATION]', '[VMWARE_ENGINE_NETWORK]'); + $privateConnection->setVmwareEngineNetwork($privateConnectionVmwareEngineNetwork); + $privateConnectionType = Type::TYPE_UNSPECIFIED; + $privateConnection->setType($privateConnectionType); + $privateConnectionServiceNetwork = $gapicClient->networkName('[PROJECT]', '[NETWORK]'); + $privateConnection->setServiceNetwork($privateConnectionServiceNetwork); + $request = (new CreatePrivateConnectionRequest()) + ->setParent($formattedParent) + ->setPrivateConnectionId($privateConnectionId) + ->setPrivateConnection($privateConnection); + $response = $gapicClient->createPrivateConnection($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createPrivateConnectionTest'); + 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 createVmwareEngineNetworkTest() + { + $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/createVmwareEngineNetworkTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $description = 'description-1724546052'; + $uid = 'uid115792'; + $etag = 'etag3123477'; + $expectedResponse = new VmwareEngineNetwork(); + $expectedResponse->setName($name); + $expectedResponse->setDescription($description); + $expectedResponse->setUid($uid); + $expectedResponse->setEtag($etag); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/createVmwareEngineNetworkTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); + $vmwareEngineNetworkId = 'vmwareEngineNetworkId2131972382'; + $vmwareEngineNetwork = new VmwareEngineNetwork(); + $vmwareEngineNetworkType = \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork\Type::TYPE_UNSPECIFIED; + $vmwareEngineNetwork->setType($vmwareEngineNetworkType); + $request = (new CreateVmwareEngineNetworkRequest()) + ->setParent($formattedParent) + ->setVmwareEngineNetworkId($vmwareEngineNetworkId) + ->setVmwareEngineNetwork($vmwareEngineNetwork); + $response = $gapicClient->createVmwareEngineNetwork($request); + $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.vmwareengine.v1.VmwareEngine/CreateVmwareEngineNetwork', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualApiRequestObject->getVmwareEngineNetworkId(); + $this->assertProtobufEquals($vmwareEngineNetworkId, $actualValue); + $actualValue = $actualApiRequestObject->getVmwareEngineNetwork(); + $this->assertProtobufEquals($vmwareEngineNetwork, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createVmwareEngineNetworkTest'); + $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 createVmwareEngineNetworkExceptionTest() + { + $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/createVmwareEngineNetworkTest'); + $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]'); + $vmwareEngineNetworkId = 'vmwareEngineNetworkId2131972382'; + $vmwareEngineNetwork = new VmwareEngineNetwork(); + $vmwareEngineNetworkType = \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork\Type::TYPE_UNSPECIFIED; + $vmwareEngineNetwork->setType($vmwareEngineNetworkType); + $request = (new CreateVmwareEngineNetworkRequest()) + ->setParent($formattedParent) + ->setVmwareEngineNetworkId($vmwareEngineNetworkId) + ->setVmwareEngineNetwork($vmwareEngineNetwork); + $response = $gapicClient->createVmwareEngineNetwork($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createVmwareEngineNetworkTest'); + 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 deleteClusterTest() + { + $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/deleteClusterTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $expectedResponse = new GPBEmpty(); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/deleteClusterTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedName = $gapicClient->clusterName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[CLUSTER]'); + $request = (new DeleteClusterRequest()) + ->setName($formattedName); + $response = $gapicClient->deleteCluster($request); + $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.vmwareengine.v1.VmwareEngine/DeleteCluster', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/deleteClusterTest'); + $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 deleteClusterExceptionTest() + { + $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/deleteClusterTest'); + $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->clusterName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[CLUSTER]'); + $request = (new DeleteClusterRequest()) + ->setName($formattedName); + $response = $gapicClient->deleteCluster($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/deleteClusterTest'); + 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 deleteExternalAccessRuleTest() + { + $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/deleteExternalAccessRuleTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $expectedResponse = new GPBEmpty(); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/deleteExternalAccessRuleTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedName = $gapicClient->externalAccessRuleName('[PROJECT]', '[LOCATION]', '[NETWORK_POLICY]', '[EXTERNAL_ACCESS_RULE]'); + $request = (new DeleteExternalAccessRuleRequest()) + ->setName($formattedName); + $response = $gapicClient->deleteExternalAccessRule($request); + $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.vmwareengine.v1.VmwareEngine/DeleteExternalAccessRule', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/deleteExternalAccessRuleTest'); + $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 deleteExternalAccessRuleExceptionTest() + { + $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/deleteExternalAccessRuleTest'); + $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->externalAccessRuleName('[PROJECT]', '[LOCATION]', '[NETWORK_POLICY]', '[EXTERNAL_ACCESS_RULE]'); + $request = (new DeleteExternalAccessRuleRequest()) + ->setName($formattedName); + $response = $gapicClient->deleteExternalAccessRule($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/deleteExternalAccessRuleTest'); + 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 deleteExternalAddressTest() + { + $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/deleteExternalAddressTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $expectedResponse = new GPBEmpty(); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/deleteExternalAddressTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedName = $gapicClient->externalAddressName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[EXTERNAL_ADDRESS]'); + $request = (new DeleteExternalAddressRequest()) + ->setName($formattedName); + $response = $gapicClient->deleteExternalAddress($request); + $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.vmwareengine.v1.VmwareEngine/DeleteExternalAddress', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/deleteExternalAddressTest'); + $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 deleteExternalAddressExceptionTest() + { + $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/deleteExternalAddressTest'); + $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->externalAddressName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[EXTERNAL_ADDRESS]'); + $request = (new DeleteExternalAddressRequest()) + ->setName($formattedName); + $response = $gapicClient->deleteExternalAddress($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/deleteExternalAddressTest'); + 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 deleteLoggingServerTest() + { + $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/deleteLoggingServerTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $expectedResponse = new GPBEmpty(); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/deleteLoggingServerTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedName = $gapicClient->loggingServerName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[LOGGING_SERVER]'); + $request = (new DeleteLoggingServerRequest()) + ->setName($formattedName); + $response = $gapicClient->deleteLoggingServer($request); + $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.vmwareengine.v1.VmwareEngine/DeleteLoggingServer', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/deleteLoggingServerTest'); + $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 deleteLoggingServerExceptionTest() + { + $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/deleteLoggingServerTest'); + $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->loggingServerName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[LOGGING_SERVER]'); + $request = (new DeleteLoggingServerRequest()) + ->setName($formattedName); + $response = $gapicClient->deleteLoggingServer($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/deleteLoggingServerTest'); + 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 deleteManagementDnsZoneBindingTest() + { + $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/deleteManagementDnsZoneBindingTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $expectedResponse = new GPBEmpty(); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/deleteManagementDnsZoneBindingTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedName = $gapicClient->managementDnsZoneBindingName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[MANAGEMENT_DNS_ZONE_BINDING]'); + $request = (new DeleteManagementDnsZoneBindingRequest()) + ->setName($formattedName); + $response = $gapicClient->deleteManagementDnsZoneBinding($request); + $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.vmwareengine.v1.VmwareEngine/DeleteManagementDnsZoneBinding', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/deleteManagementDnsZoneBindingTest'); + $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 deleteManagementDnsZoneBindingExceptionTest() + { + $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/deleteManagementDnsZoneBindingTest'); + $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->managementDnsZoneBindingName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[MANAGEMENT_DNS_ZONE_BINDING]'); + $request = (new DeleteManagementDnsZoneBindingRequest()) + ->setName($formattedName); + $response = $gapicClient->deleteManagementDnsZoneBinding($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/deleteManagementDnsZoneBindingTest'); + 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 deleteNetworkPeeringTest() + { + $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/deleteNetworkPeeringTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $expectedResponse = new GPBEmpty(); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/deleteNetworkPeeringTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedName = $gapicClient->networkPeeringName('[PROJECT]', '[LOCATION]', '[NETWORK_PEERING]'); + $request = (new DeleteNetworkPeeringRequest()) + ->setName($formattedName); + $response = $gapicClient->deleteNetworkPeering($request); + $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.vmwareengine.v1.VmwareEngine/DeleteNetworkPeering', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/deleteNetworkPeeringTest'); + $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 deleteNetworkPeeringExceptionTest() + { + $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/deleteNetworkPeeringTest'); + $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->networkPeeringName('[PROJECT]', '[LOCATION]', '[NETWORK_PEERING]'); + $request = (new DeleteNetworkPeeringRequest()) + ->setName($formattedName); + $response = $gapicClient->deleteNetworkPeering($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/deleteNetworkPeeringTest'); + 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 deleteNetworkPolicyTest() + { + $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/deleteNetworkPolicyTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $expectedResponse = new GPBEmpty(); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/deleteNetworkPolicyTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedName = $gapicClient->networkPolicyName('[PROJECT]', '[LOCATION]', '[NETWORK_POLICY]'); + $request = (new DeleteNetworkPolicyRequest()) + ->setName($formattedName); + $response = $gapicClient->deleteNetworkPolicy($request); + $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.vmwareengine.v1.VmwareEngine/DeleteNetworkPolicy', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/deleteNetworkPolicyTest'); + $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 deleteNetworkPolicyExceptionTest() + { + $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/deleteNetworkPolicyTest'); + $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->networkPolicyName('[PROJECT]', '[LOCATION]', '[NETWORK_POLICY]'); + $request = (new DeleteNetworkPolicyRequest()) + ->setName($formattedName); + $response = $gapicClient->deleteNetworkPolicy($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/deleteNetworkPolicyTest'); + 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 deletePrivateCloudTest() + { + $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/deletePrivateCloudTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name2 = 'name2-1052831874'; + $description = 'description-1724546052'; + $uid = 'uid115792'; + $expectedResponse = new PrivateCloud(); + $expectedResponse->setName($name2); + $expectedResponse->setDescription($description); + $expectedResponse->setUid($uid); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/deletePrivateCloudTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedName = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); + $request = (new DeletePrivateCloudRequest()) + ->setName($formattedName); + $response = $gapicClient->deletePrivateCloud($request); + $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.vmwareengine.v1.VmwareEngine/DeletePrivateCloud', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/deletePrivateCloudTest'); + $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 deletePrivateCloudExceptionTest() + { + $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/deletePrivateCloudTest'); + $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->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); + $request = (new DeletePrivateCloudRequest()) + ->setName($formattedName); + $response = $gapicClient->deletePrivateCloud($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/deletePrivateCloudTest'); + 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 deletePrivateConnectionTest() + { + $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/deletePrivateConnectionTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $expectedResponse = new GPBEmpty(); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/deletePrivateConnectionTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedName = $gapicClient->privateConnectionName('[PROJECT]', '[LOCATION]', '[PRIVATE_CONNECTION]'); + $request = (new DeletePrivateConnectionRequest()) + ->setName($formattedName); + $response = $gapicClient->deletePrivateConnection($request); + $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.vmwareengine.v1.VmwareEngine/DeletePrivateConnection', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/deletePrivateConnectionTest'); + $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 deletePrivateConnectionExceptionTest() + { + $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/deletePrivateConnectionTest'); + $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->privateConnectionName('[PROJECT]', '[LOCATION]', '[PRIVATE_CONNECTION]'); + $request = (new DeletePrivateConnectionRequest()) + ->setName($formattedName); + $response = $gapicClient->deletePrivateConnection($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/deletePrivateConnectionTest'); + 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 deleteVmwareEngineNetworkTest() + { + $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/deleteVmwareEngineNetworkTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $expectedResponse = new GPBEmpty(); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/deleteVmwareEngineNetworkTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedName = $gapicClient->vmwareEngineNetworkName('[PROJECT]', '[LOCATION]', '[VMWARE_ENGINE_NETWORK]'); + $request = (new DeleteVmwareEngineNetworkRequest()) + ->setName($formattedName); + $response = $gapicClient->deleteVmwareEngineNetwork($request); + $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.vmwareengine.v1.VmwareEngine/DeleteVmwareEngineNetwork', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/deleteVmwareEngineNetworkTest'); + $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 deleteVmwareEngineNetworkExceptionTest() + { + $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/deleteVmwareEngineNetworkTest'); + $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->vmwareEngineNetworkName('[PROJECT]', '[LOCATION]', '[VMWARE_ENGINE_NETWORK]'); + $request = (new DeleteVmwareEngineNetworkRequest()) + ->setName($formattedName); + $response = $gapicClient->deleteVmwareEngineNetwork($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/deleteVmwareEngineNetworkTest'); + 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 fetchNetworkPolicyExternalAddressesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $externalAddressesElement = new ExternalAddress(); + $externalAddresses = [ + $externalAddressesElement, + ]; + $expectedResponse = new FetchNetworkPolicyExternalAddressesResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setExternalAddresses($externalAddresses); + $transport->addResponse($expectedResponse); + // Mock request + $formattedNetworkPolicy = $gapicClient->networkPolicyName('[PROJECT]', '[LOCATION]', '[NETWORK_POLICY]'); + $request = (new FetchNetworkPolicyExternalAddressesRequest()) + ->setNetworkPolicy($formattedNetworkPolicy); + $response = $gapicClient->fetchNetworkPolicyExternalAddresses($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getExternalAddresses()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/FetchNetworkPolicyExternalAddresses', $actualFuncCall); + $actualValue = $actualRequestObject->getNetworkPolicy(); + $this->assertProtobufEquals($formattedNetworkPolicy, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function fetchNetworkPolicyExternalAddressesExceptionTest() + { + $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 + $formattedNetworkPolicy = $gapicClient->networkPolicyName('[PROJECT]', '[LOCATION]', '[NETWORK_POLICY]'); + $request = (new FetchNetworkPolicyExternalAddressesRequest()) + ->setNetworkPolicy($formattedNetworkPolicy); + try { + $gapicClient->fetchNetworkPolicyExternalAddresses($request); + // 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 getClusterTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $management = false; + $uid = 'uid115792'; + $expectedResponse = new Cluster(); + $expectedResponse->setName($name2); + $expectedResponse->setManagement($management); + $expectedResponse->setUid($uid); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->clusterName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[CLUSTER]'); + $request = (new GetClusterRequest()) + ->setName($formattedName); + $response = $gapicClient->getCluster($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/GetCluster', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getClusterExceptionTest() + { + $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->clusterName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[CLUSTER]'); + $request = (new GetClusterRequest()) + ->setName($formattedName); + try { + $gapicClient->getCluster($request); + // 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 getDnsBindPermissionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $expectedResponse = new DnsBindPermission(); + $expectedResponse->setName($name2); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->dnsBindPermissionName('[PROJECT]', '[LOCATION]'); + $request = (new GetDnsBindPermissionRequest()) + ->setName($formattedName); + $response = $gapicClient->getDnsBindPermission($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/GetDnsBindPermission', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getDnsBindPermissionExceptionTest() + { + $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->dnsBindPermissionName('[PROJECT]', '[LOCATION]'); + $request = (new GetDnsBindPermissionRequest()) + ->setName($formattedName); + try { + $gapicClient->getDnsBindPermission($request); + // 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 getDnsForwardingTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $expectedResponse = new DnsForwarding(); + $expectedResponse->setName($name2); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->dnsForwardingName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); + $request = (new GetDnsForwardingRequest()) + ->setName($formattedName); + $response = $gapicClient->getDnsForwarding($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/GetDnsForwarding', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getDnsForwardingExceptionTest() + { + $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->dnsForwardingName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); + $request = (new GetDnsForwardingRequest()) + ->setName($formattedName); + try { + $gapicClient->getDnsForwarding($request); + // 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 getExternalAccessRuleTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $description = 'description-1724546052'; + $priority = 1165461084; + $ipProtocol = 'ipProtocol-1134653776'; + $uid = 'uid115792'; + $expectedResponse = new ExternalAccessRule(); + $expectedResponse->setName($name2); + $expectedResponse->setDescription($description); + $expectedResponse->setPriority($priority); + $expectedResponse->setIpProtocol($ipProtocol); + $expectedResponse->setUid($uid); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->externalAccessRuleName('[PROJECT]', '[LOCATION]', '[NETWORK_POLICY]', '[EXTERNAL_ACCESS_RULE]'); + $request = (new GetExternalAccessRuleRequest()) + ->setName($formattedName); + $response = $gapicClient->getExternalAccessRule($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/GetExternalAccessRule', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getExternalAccessRuleExceptionTest() + { + $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->externalAccessRuleName('[PROJECT]', '[LOCATION]', '[NETWORK_POLICY]', '[EXTERNAL_ACCESS_RULE]'); + $request = (new GetExternalAccessRuleRequest()) + ->setName($formattedName); + try { + $gapicClient->getExternalAccessRule($request); + // 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 getExternalAddressTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $internalIp = 'internalIp-2080778775'; + $externalIp = 'externalIp-1153075685'; + $uid = 'uid115792'; + $description = 'description-1724546052'; + $expectedResponse = new ExternalAddress(); + $expectedResponse->setName($name2); + $expectedResponse->setInternalIp($internalIp); + $expectedResponse->setExternalIp($externalIp); + $expectedResponse->setUid($uid); + $expectedResponse->setDescription($description); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->externalAddressName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[EXTERNAL_ADDRESS]'); + $request = (new GetExternalAddressRequest()) + ->setName($formattedName); + $response = $gapicClient->getExternalAddress($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/GetExternalAddress', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getExternalAddressExceptionTest() + { + $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->externalAddressName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[EXTERNAL_ADDRESS]'); + $request = (new GetExternalAddressRequest()) + ->setName($formattedName); + try { + $gapicClient->getExternalAddress($request); + // 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 getHcxActivationKeyTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $activationKey = 'activationKey-1343958090'; + $uid = 'uid115792'; + $expectedResponse = new HcxActivationKey(); + $expectedResponse->setName($name2); + $expectedResponse->setActivationKey($activationKey); + $expectedResponse->setUid($uid); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->hcxActivationKeyName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[HCX_ACTIVATION_KEY]'); + $request = (new GetHcxActivationKeyRequest()) + ->setName($formattedName); + $response = $gapicClient->getHcxActivationKey($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/GetHcxActivationKey', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getHcxActivationKeyExceptionTest() + { + $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->hcxActivationKeyName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[HCX_ACTIVATION_KEY]'); + $request = (new GetHcxActivationKeyRequest()) + ->setName($formattedName); + try { + $gapicClient->getHcxActivationKey($request); + // 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 getLoggingServerTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $hostname = 'hostname-299803597'; + $port = 3446913; + $uid = 'uid115792'; + $expectedResponse = new LoggingServer(); + $expectedResponse->setName($name2); + $expectedResponse->setHostname($hostname); + $expectedResponse->setPort($port); + $expectedResponse->setUid($uid); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->loggingServerName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[LOGGING_SERVER]'); + $request = (new GetLoggingServerRequest()) + ->setName($formattedName); + $response = $gapicClient->getLoggingServer($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/GetLoggingServer', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getLoggingServerExceptionTest() + { + $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->loggingServerName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[LOGGING_SERVER]'); + $request = (new GetLoggingServerRequest()) + ->setName($formattedName); + try { + $gapicClient->getLoggingServer($request); + // 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 getManagementDnsZoneBindingTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $description = 'description-1724546052'; + $vpcNetwork = 'vpcNetwork-764161832'; + $uid = 'uid115792'; + $expectedResponse = new ManagementDnsZoneBinding(); + $expectedResponse->setName($name2); + $expectedResponse->setDescription($description); + $expectedResponse->setVpcNetwork($vpcNetwork); + $expectedResponse->setUid($uid); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->managementDnsZoneBindingName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[MANAGEMENT_DNS_ZONE_BINDING]'); + $request = (new GetManagementDnsZoneBindingRequest()) + ->setName($formattedName); + $response = $gapicClient->getManagementDnsZoneBinding($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/GetManagementDnsZoneBinding', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getManagementDnsZoneBindingExceptionTest() + { + $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->managementDnsZoneBindingName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[MANAGEMENT_DNS_ZONE_BINDING]'); + $request = (new GetManagementDnsZoneBindingRequest()) + ->setName($formattedName); + try { + $gapicClient->getManagementDnsZoneBinding($request); + // 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 getNetworkPeeringTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $peerNetwork = 'peerNetwork2111238225'; + $exportCustomRoutes = false; + $importCustomRoutes = true; + $exchangeSubnetRoutes = true; + $exportCustomRoutesWithPublicIp = true; + $importCustomRoutesWithPublicIp = false; + $stateDetails = 'stateDetails632437908'; + $peerMtu = 69584721; + $uid = 'uid115792'; + $vmwareEngineNetwork = 'vmwareEngineNetwork-90899684'; + $description = 'description-1724546052'; + $expectedResponse = new NetworkPeering(); + $expectedResponse->setName($name2); + $expectedResponse->setPeerNetwork($peerNetwork); + $expectedResponse->setExportCustomRoutes($exportCustomRoutes); + $expectedResponse->setImportCustomRoutes($importCustomRoutes); + $expectedResponse->setExchangeSubnetRoutes($exchangeSubnetRoutes); + $expectedResponse->setExportCustomRoutesWithPublicIp($exportCustomRoutesWithPublicIp); + $expectedResponse->setImportCustomRoutesWithPublicIp($importCustomRoutesWithPublicIp); + $expectedResponse->setStateDetails($stateDetails); + $expectedResponse->setPeerMtu($peerMtu); + $expectedResponse->setUid($uid); + $expectedResponse->setVmwareEngineNetwork($vmwareEngineNetwork); + $expectedResponse->setDescription($description); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->networkPeeringName('[PROJECT]', '[LOCATION]', '[NETWORK_PEERING]'); + $request = (new GetNetworkPeeringRequest()) + ->setName($formattedName); + $response = $gapicClient->getNetworkPeering($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/GetNetworkPeering', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getNetworkPeeringExceptionTest() + { + $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->networkPeeringName('[PROJECT]', '[LOCATION]', '[NETWORK_PEERING]'); + $request = (new GetNetworkPeeringRequest()) + ->setName($formattedName); + try { + $gapicClient->getNetworkPeering($request); + // 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 getNetworkPolicyTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $edgeServicesCidr = 'edgeServicesCidr-792872013'; + $uid = 'uid115792'; + $vmwareEngineNetwork = 'vmwareEngineNetwork-90899684'; + $description = 'description-1724546052'; + $vmwareEngineNetworkCanonical = 'vmwareEngineNetworkCanonical779839377'; + $expectedResponse = new NetworkPolicy(); + $expectedResponse->setName($name2); + $expectedResponse->setEdgeServicesCidr($edgeServicesCidr); + $expectedResponse->setUid($uid); + $expectedResponse->setVmwareEngineNetwork($vmwareEngineNetwork); + $expectedResponse->setDescription($description); + $expectedResponse->setVmwareEngineNetworkCanonical($vmwareEngineNetworkCanonical); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->networkPolicyName('[PROJECT]', '[LOCATION]', '[NETWORK_POLICY]'); + $request = (new GetNetworkPolicyRequest()) + ->setName($formattedName); + $response = $gapicClient->getNetworkPolicy($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/GetNetworkPolicy', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getNetworkPolicyExceptionTest() + { + $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->networkPolicyName('[PROJECT]', '[LOCATION]', '[NETWORK_POLICY]'); + $request = (new GetNetworkPolicyRequest()) + ->setName($formattedName); + try { + $gapicClient->getNetworkPolicy($request); + // 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 getNodeTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $fqdn = 'fqdn3150485'; + $internalIp = 'internalIp-2080778775'; + $nodeTypeId = 'nodeTypeId585437955'; + $version = 'version351608024'; + $customCoreCount = 2091833853; + $expectedResponse = new Node(); + $expectedResponse->setName($name2); + $expectedResponse->setFqdn($fqdn); + $expectedResponse->setInternalIp($internalIp); + $expectedResponse->setNodeTypeId($nodeTypeId); + $expectedResponse->setVersion($version); + $expectedResponse->setCustomCoreCount($customCoreCount); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->nodeName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[CLUSTER]', '[NODE]'); + $request = (new GetNodeRequest()) + ->setName($formattedName); + $response = $gapicClient->getNode($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/GetNode', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getNodeExceptionTest() + { + $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->nodeName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[CLUSTER]', '[NODE]'); + $request = (new GetNodeRequest()) + ->setName($formattedName); + try { + $gapicClient->getNode($request); + // 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 getNodeTypeTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $nodeTypeId = 'nodeTypeId585437955'; + $displayName = 'displayName1615086568'; + $virtualCpuCount = 289038212; + $totalCoreCount = 282953654; + $memoryGb = 1726613721; + $diskSizeGb = 757478089; + $expectedResponse = new NodeType(); + $expectedResponse->setName($name2); + $expectedResponse->setNodeTypeId($nodeTypeId); + $expectedResponse->setDisplayName($displayName); + $expectedResponse->setVirtualCpuCount($virtualCpuCount); + $expectedResponse->setTotalCoreCount($totalCoreCount); + $expectedResponse->setMemoryGb($memoryGb); + $expectedResponse->setDiskSizeGb($diskSizeGb); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->nodeTypeName('[PROJECT]', '[LOCATION]', '[NODE_TYPE]'); + $request = (new GetNodeTypeRequest()) + ->setName($formattedName); + $response = $gapicClient->getNodeType($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/GetNodeType', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getNodeTypeExceptionTest() + { + $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->nodeTypeName('[PROJECT]', '[LOCATION]', '[NODE_TYPE]'); + $request = (new GetNodeTypeRequest()) + ->setName($formattedName); + try { + $gapicClient->getNodeType($request); + // 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 getPrivateCloudTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $description = 'description-1724546052'; + $uid = 'uid115792'; + $expectedResponse = new PrivateCloud(); + $expectedResponse->setName($name2); + $expectedResponse->setDescription($description); + $expectedResponse->setUid($uid); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); + $request = (new GetPrivateCloudRequest()) + ->setName($formattedName); + $response = $gapicClient->getPrivateCloud($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/GetPrivateCloud', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getPrivateCloudExceptionTest() + { + $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->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); + $request = (new GetPrivateCloudRequest()) + ->setName($formattedName); + try { + $gapicClient->getPrivateCloud($request); + // 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 getPrivateConnectionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $description = 'description-1724546052'; + $vmwareEngineNetwork = 'vmwareEngineNetwork-90899684'; + $vmwareEngineNetworkCanonical = 'vmwareEngineNetworkCanonical779839377'; + $peeringId = 'peeringId-1561749894'; + $uid = 'uid115792'; + $serviceNetwork = 'serviceNetwork1072775844'; + $expectedResponse = new PrivateConnection(); + $expectedResponse->setName($name2); + $expectedResponse->setDescription($description); + $expectedResponse->setVmwareEngineNetwork($vmwareEngineNetwork); + $expectedResponse->setVmwareEngineNetworkCanonical($vmwareEngineNetworkCanonical); + $expectedResponse->setPeeringId($peeringId); + $expectedResponse->setUid($uid); + $expectedResponse->setServiceNetwork($serviceNetwork); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->privateConnectionName('[PROJECT]', '[LOCATION]', '[PRIVATE_CONNECTION]'); + $request = (new GetPrivateConnectionRequest()) + ->setName($formattedName); + $response = $gapicClient->getPrivateConnection($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/GetPrivateConnection', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getPrivateConnectionExceptionTest() + { + $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->privateConnectionName('[PROJECT]', '[LOCATION]', '[PRIVATE_CONNECTION]'); + $request = (new GetPrivateConnectionRequest()) + ->setName($formattedName); + try { + $gapicClient->getPrivateConnection($request); + // 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 getSubnetTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $ipCidrRange = 'ipCidrRange-2049366326'; + $gatewayIp = 'gatewayIp955798786'; + $type = 'type3575610'; + $vlanId = 536153463; + $expectedResponse = new Subnet(); + $expectedResponse->setName($name2); + $expectedResponse->setIpCidrRange($ipCidrRange); + $expectedResponse->setGatewayIp($gatewayIp); + $expectedResponse->setType($type); + $expectedResponse->setVlanId($vlanId); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->subnetName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[SUBNET]'); + $request = (new GetSubnetRequest()) + ->setName($formattedName); + $response = $gapicClient->getSubnet($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/GetSubnet', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getSubnetExceptionTest() + { + $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->subnetName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[SUBNET]'); + $request = (new GetSubnetRequest()) + ->setName($formattedName); + try { + $gapicClient->getSubnet($request); + // 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 getVmwareEngineNetworkTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $description = 'description-1724546052'; + $uid = 'uid115792'; + $etag = 'etag3123477'; + $expectedResponse = new VmwareEngineNetwork(); + $expectedResponse->setName($name2); + $expectedResponse->setDescription($description); + $expectedResponse->setUid($uid); + $expectedResponse->setEtag($etag); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->vmwareEngineNetworkName('[PROJECT]', '[LOCATION]', '[VMWARE_ENGINE_NETWORK]'); + $request = (new GetVmwareEngineNetworkRequest()) + ->setName($formattedName); + $response = $gapicClient->getVmwareEngineNetwork($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/GetVmwareEngineNetwork', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getVmwareEngineNetworkExceptionTest() + { + $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->vmwareEngineNetworkName('[PROJECT]', '[LOCATION]', '[VMWARE_ENGINE_NETWORK]'); + $request = (new GetVmwareEngineNetworkRequest()) + ->setName($formattedName); + try { + $gapicClient->getVmwareEngineNetwork($request); + // 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 grantDnsBindPermissionTest() + { + $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/grantDnsBindPermissionTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name2 = 'name2-1052831874'; + $expectedResponse = new DnsBindPermission(); + $expectedResponse->setName($name2); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/grantDnsBindPermissionTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedName = $gapicClient->dnsBindPermissionName('[PROJECT]', '[LOCATION]'); + $principal = new Principal(); + $request = (new GrantDnsBindPermissionRequest()) + ->setName($formattedName) + ->setPrincipal($principal); + $response = $gapicClient->grantDnsBindPermission($request); + $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.vmwareengine.v1.VmwareEngine/GrantDnsBindPermission', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $actualValue = $actualApiRequestObject->getPrincipal(); + $this->assertProtobufEquals($principal, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/grantDnsBindPermissionTest'); + $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 grantDnsBindPermissionExceptionTest() + { + $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/grantDnsBindPermissionTest'); + $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->dnsBindPermissionName('[PROJECT]', '[LOCATION]'); + $principal = new Principal(); + $request = (new GrantDnsBindPermissionRequest()) + ->setName($formattedName) + ->setPrincipal($principal); + $response = $gapicClient->grantDnsBindPermission($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/grantDnsBindPermissionTest'); + 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 listClustersTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $clustersElement = new Cluster(); + $clusters = [ + $clustersElement, + ]; + $expectedResponse = new ListClustersResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setClusters($clusters); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); + $request = (new ListClustersRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listClusters($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getClusters()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/ListClusters', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listClustersExceptionTest() + { + $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->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); + $request = (new ListClustersRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listClusters($request); + // 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 listExternalAccessRulesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $externalAccessRulesElement = new ExternalAccessRule(); + $externalAccessRules = [ + $externalAccessRulesElement, + ]; + $expectedResponse = new ListExternalAccessRulesResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setExternalAccessRules($externalAccessRules); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->networkPolicyName('[PROJECT]', '[LOCATION]', '[NETWORK_POLICY]'); + $request = (new ListExternalAccessRulesRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listExternalAccessRules($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getExternalAccessRules()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/ListExternalAccessRules', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listExternalAccessRulesExceptionTest() + { + $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->networkPolicyName('[PROJECT]', '[LOCATION]', '[NETWORK_POLICY]'); + $request = (new ListExternalAccessRulesRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listExternalAccessRules($request); + // 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 listExternalAddressesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $externalAddressesElement = new ExternalAddress(); + $externalAddresses = [ + $externalAddressesElement, + ]; + $expectedResponse = new ListExternalAddressesResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setExternalAddresses($externalAddresses); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); + $request = (new ListExternalAddressesRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listExternalAddresses($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getExternalAddresses()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/ListExternalAddresses', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listExternalAddressesExceptionTest() + { + $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->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); + $request = (new ListExternalAddressesRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listExternalAddresses($request); + // 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 listHcxActivationKeysTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $hcxActivationKeysElement = new HcxActivationKey(); + $hcxActivationKeys = [ + $hcxActivationKeysElement, + ]; + $expectedResponse = new ListHcxActivationKeysResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setHcxActivationKeys($hcxActivationKeys); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); + $request = (new ListHcxActivationKeysRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listHcxActivationKeys($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getHcxActivationKeys()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/ListHcxActivationKeys', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listHcxActivationKeysExceptionTest() + { + $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->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); + $request = (new ListHcxActivationKeysRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listHcxActivationKeys($request); + // 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 listLoggingServersTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $loggingServersElement = new LoggingServer(); + $loggingServers = [ + $loggingServersElement, + ]; + $expectedResponse = new ListLoggingServersResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setLoggingServers($loggingServers); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); + $request = (new ListLoggingServersRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listLoggingServers($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getLoggingServers()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/ListLoggingServers', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listLoggingServersExceptionTest() + { + $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->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); + $request = (new ListLoggingServersRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listLoggingServers($request); + // 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 listManagementDnsZoneBindingsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $managementDnsZoneBindingsElement = new ManagementDnsZoneBinding(); + $managementDnsZoneBindings = [ + $managementDnsZoneBindingsElement, + ]; + $expectedResponse = new ListManagementDnsZoneBindingsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setManagementDnsZoneBindings($managementDnsZoneBindings); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); + $request = (new ListManagementDnsZoneBindingsRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listManagementDnsZoneBindings($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getManagementDnsZoneBindings()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/ListManagementDnsZoneBindings', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listManagementDnsZoneBindingsExceptionTest() + { + $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->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); + $request = (new ListManagementDnsZoneBindingsRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listManagementDnsZoneBindings($request); + // 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 listNetworkPeeringsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $networkPeeringsElement = new NetworkPeering(); + $networkPeerings = [ + $networkPeeringsElement, + ]; + $expectedResponse = new ListNetworkPeeringsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setNetworkPeerings($networkPeerings); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); + $request = (new ListNetworkPeeringsRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listNetworkPeerings($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getNetworkPeerings()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/ListNetworkPeerings', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listNetworkPeeringsExceptionTest() + { + $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]'); + $request = (new ListNetworkPeeringsRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listNetworkPeerings($request); + // 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 listNetworkPoliciesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $networkPoliciesElement = new NetworkPolicy(); + $networkPolicies = [ + $networkPoliciesElement, + ]; + $expectedResponse = new ListNetworkPoliciesResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setNetworkPolicies($networkPolicies); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); + $request = (new ListNetworkPoliciesRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listNetworkPolicies($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getNetworkPolicies()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/ListNetworkPolicies', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listNetworkPoliciesExceptionTest() + { + $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]'); + $request = (new ListNetworkPoliciesRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listNetworkPolicies($request); + // 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 listNodeTypesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $nodeTypesElement = new NodeType(); + $nodeTypes = [ + $nodeTypesElement, + ]; + $expectedResponse = new ListNodeTypesResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setNodeTypes($nodeTypes); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); + $request = (new ListNodeTypesRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listNodeTypes($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getNodeTypes()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/ListNodeTypes', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listNodeTypesExceptionTest() + { + $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]'); + $request = (new ListNodeTypesRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listNodeTypes($request); + // 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 listNodesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $nodesElement = new Node(); + $nodes = [ + $nodesElement, + ]; + $expectedResponse = new ListNodesResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setNodes($nodes); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->clusterName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[CLUSTER]'); + $request = (new ListNodesRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listNodes($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getNodes()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/ListNodes', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listNodesExceptionTest() + { + $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->clusterName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[CLUSTER]'); + $request = (new ListNodesRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listNodes($request); + // 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 listPeeringRoutesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $peeringRoutesElement = new PeeringRoute(); + $peeringRoutes = [ + $peeringRoutesElement, + ]; + $expectedResponse = new ListPeeringRoutesResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setPeeringRoutes($peeringRoutes); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->networkPeeringName('[PROJECT]', '[LOCATION]', '[NETWORK_PEERING]'); + $request = (new ListPeeringRoutesRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listPeeringRoutes($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getPeeringRoutes()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/ListPeeringRoutes', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listPeeringRoutesExceptionTest() + { + $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->networkPeeringName('[PROJECT]', '[LOCATION]', '[NETWORK_PEERING]'); + $request = (new ListPeeringRoutesRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listPeeringRoutes($request); + // 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 listPrivateCloudsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $privateCloudsElement = new PrivateCloud(); + $privateClouds = [ + $privateCloudsElement, + ]; + $expectedResponse = new ListPrivateCloudsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setPrivateClouds($privateClouds); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); + $request = (new ListPrivateCloudsRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listPrivateClouds($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getPrivateClouds()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/ListPrivateClouds', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listPrivateCloudsExceptionTest() + { + $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]'); + $request = (new ListPrivateCloudsRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listPrivateClouds($request); + // 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 listPrivateConnectionPeeringRoutesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $peeringRoutesElement = new PeeringRoute(); + $peeringRoutes = [ + $peeringRoutesElement, + ]; + $expectedResponse = new ListPrivateConnectionPeeringRoutesResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setPeeringRoutes($peeringRoutes); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->privateConnectionName('[PROJECT]', '[LOCATION]', '[PRIVATE_CONNECTION]'); + $request = (new ListPrivateConnectionPeeringRoutesRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listPrivateConnectionPeeringRoutes($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getPeeringRoutes()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/ListPrivateConnectionPeeringRoutes', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listPrivateConnectionPeeringRoutesExceptionTest() + { + $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->privateConnectionName('[PROJECT]', '[LOCATION]', '[PRIVATE_CONNECTION]'); + $request = (new ListPrivateConnectionPeeringRoutesRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listPrivateConnectionPeeringRoutes($request); + // 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 listPrivateConnectionsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $privateConnectionsElement = new PrivateConnection(); + $privateConnections = [ + $privateConnectionsElement, + ]; + $expectedResponse = new ListPrivateConnectionsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setPrivateConnections($privateConnections); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); + $request = (new ListPrivateConnectionsRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listPrivateConnections($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getPrivateConnections()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/ListPrivateConnections', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listPrivateConnectionsExceptionTest() + { + $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]'); + $request = (new ListPrivateConnectionsRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listPrivateConnections($request); + // 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 listSubnetsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $subnetsElement = new Subnet(); + $subnets = [ + $subnetsElement, + ]; + $expectedResponse = new ListSubnetsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setSubnets($subnets); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); + $request = (new ListSubnetsRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listSubnets($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getSubnets()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/ListSubnets', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listSubnetsExceptionTest() + { + $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->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); + $request = (new ListSubnetsRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listSubnets($request); + // 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 listVmwareEngineNetworksTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $vmwareEngineNetworksElement = new VmwareEngineNetwork(); + $vmwareEngineNetworks = [ + $vmwareEngineNetworksElement, + ]; + $expectedResponse = new ListVmwareEngineNetworksResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setVmwareEngineNetworks($vmwareEngineNetworks); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); + $request = (new ListVmwareEngineNetworksRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listVmwareEngineNetworks($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getVmwareEngineNetworks()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/ListVmwareEngineNetworks', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listVmwareEngineNetworksExceptionTest() + { + $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]'); + $request = (new ListVmwareEngineNetworksRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listVmwareEngineNetworks($request); + // 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 repairManagementDnsZoneBindingTest() + { + $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/repairManagementDnsZoneBindingTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name2 = 'name2-1052831874'; + $description = 'description-1724546052'; + $vpcNetwork = 'vpcNetwork-764161832'; + $uid = 'uid115792'; + $expectedResponse = new ManagementDnsZoneBinding(); + $expectedResponse->setName($name2); + $expectedResponse->setDescription($description); + $expectedResponse->setVpcNetwork($vpcNetwork); + $expectedResponse->setUid($uid); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/repairManagementDnsZoneBindingTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedName = $gapicClient->managementDnsZoneBindingName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[MANAGEMENT_DNS_ZONE_BINDING]'); + $request = (new RepairManagementDnsZoneBindingRequest()) + ->setName($formattedName); + $response = $gapicClient->repairManagementDnsZoneBinding($request); + $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.vmwareengine.v1.VmwareEngine/RepairManagementDnsZoneBinding', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/repairManagementDnsZoneBindingTest'); + $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 repairManagementDnsZoneBindingExceptionTest() + { + $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/repairManagementDnsZoneBindingTest'); + $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->managementDnsZoneBindingName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[MANAGEMENT_DNS_ZONE_BINDING]'); + $request = (new RepairManagementDnsZoneBindingRequest()) + ->setName($formattedName); + $response = $gapicClient->repairManagementDnsZoneBinding($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/repairManagementDnsZoneBindingTest'); + 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 resetNsxCredentialsTest() + { + $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/resetNsxCredentialsTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $description = 'description-1724546052'; + $uid = 'uid115792'; + $expectedResponse = new PrivateCloud(); + $expectedResponse->setName($name); + $expectedResponse->setDescription($description); + $expectedResponse->setUid($uid); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/resetNsxCredentialsTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedPrivateCloud = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); + $request = (new ResetNsxCredentialsRequest()) + ->setPrivateCloud($formattedPrivateCloud); + $response = $gapicClient->resetNsxCredentials($request); + $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.vmwareengine.v1.VmwareEngine/ResetNsxCredentials', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getPrivateCloud(); + $this->assertProtobufEquals($formattedPrivateCloud, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/resetNsxCredentialsTest'); + $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 resetNsxCredentialsExceptionTest() + { + $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/resetNsxCredentialsTest'); + $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 + $formattedPrivateCloud = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); + $request = (new ResetNsxCredentialsRequest()) + ->setPrivateCloud($formattedPrivateCloud); + $response = $gapicClient->resetNsxCredentials($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/resetNsxCredentialsTest'); + 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 resetVcenterCredentialsTest() + { + $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/resetVcenterCredentialsTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $description = 'description-1724546052'; + $uid = 'uid115792'; + $expectedResponse = new PrivateCloud(); + $expectedResponse->setName($name); + $expectedResponse->setDescription($description); + $expectedResponse->setUid($uid); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/resetVcenterCredentialsTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedPrivateCloud = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); + $request = (new ResetVcenterCredentialsRequest()) + ->setPrivateCloud($formattedPrivateCloud); + $response = $gapicClient->resetVcenterCredentials($request); + $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.vmwareengine.v1.VmwareEngine/ResetVcenterCredentials', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getPrivateCloud(); + $this->assertProtobufEquals($formattedPrivateCloud, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/resetVcenterCredentialsTest'); + $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 resetVcenterCredentialsExceptionTest() + { + $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/resetVcenterCredentialsTest'); + $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 + $formattedPrivateCloud = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); + $request = (new ResetVcenterCredentialsRequest()) + ->setPrivateCloud($formattedPrivateCloud); + $response = $gapicClient->resetVcenterCredentials($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/resetVcenterCredentialsTest'); + 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 revokeDnsBindPermissionTest() + { + $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/revokeDnsBindPermissionTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name2 = 'name2-1052831874'; + $expectedResponse = new DnsBindPermission(); + $expectedResponse->setName($name2); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/revokeDnsBindPermissionTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedName = $gapicClient->dnsBindPermissionName('[PROJECT]', '[LOCATION]'); + $principal = new Principal(); + $request = (new RevokeDnsBindPermissionRequest()) + ->setName($formattedName) + ->setPrincipal($principal); + $response = $gapicClient->revokeDnsBindPermission($request); + $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.vmwareengine.v1.VmwareEngine/RevokeDnsBindPermission', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $actualValue = $actualApiRequestObject->getPrincipal(); + $this->assertProtobufEquals($principal, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/revokeDnsBindPermissionTest'); + $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 revokeDnsBindPermissionExceptionTest() + { + $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/revokeDnsBindPermissionTest'); + $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->dnsBindPermissionName('[PROJECT]', '[LOCATION]'); + $principal = new Principal(); + $request = (new RevokeDnsBindPermissionRequest()) + ->setName($formattedName) + ->setPrincipal($principal); + $response = $gapicClient->revokeDnsBindPermission($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/revokeDnsBindPermissionTest'); + 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 showNsxCredentialsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $username = 'username-265713450'; + $password = 'password1216985755'; + $expectedResponse = new Credentials(); + $expectedResponse->setUsername($username); + $expectedResponse->setPassword($password); + $transport->addResponse($expectedResponse); + // Mock request + $formattedPrivateCloud = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); + $request = (new ShowNsxCredentialsRequest()) + ->setPrivateCloud($formattedPrivateCloud); + $response = $gapicClient->showNsxCredentials($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/ShowNsxCredentials', $actualFuncCall); + $actualValue = $actualRequestObject->getPrivateCloud(); + $this->assertProtobufEquals($formattedPrivateCloud, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function showNsxCredentialsExceptionTest() + { + $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 + $formattedPrivateCloud = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); + $request = (new ShowNsxCredentialsRequest()) + ->setPrivateCloud($formattedPrivateCloud); + try { + $gapicClient->showNsxCredentials($request); + // 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 showVcenterCredentialsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $username2 = 'username2-1947551991'; + $password = 'password1216985755'; + $expectedResponse = new Credentials(); + $expectedResponse->setUsername($username2); + $expectedResponse->setPassword($password); + $transport->addResponse($expectedResponse); + // Mock request + $formattedPrivateCloud = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); + $request = (new ShowVcenterCredentialsRequest()) + ->setPrivateCloud($formattedPrivateCloud); + $response = $gapicClient->showVcenterCredentials($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/ShowVcenterCredentials', $actualFuncCall); + $actualValue = $actualRequestObject->getPrivateCloud(); + $this->assertProtobufEquals($formattedPrivateCloud, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function showVcenterCredentialsExceptionTest() + { + $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 + $formattedPrivateCloud = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); + $request = (new ShowVcenterCredentialsRequest()) + ->setPrivateCloud($formattedPrivateCloud); + try { + $gapicClient->showVcenterCredentials($request); + // 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 undeletePrivateCloudTest() + { + $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/undeletePrivateCloudTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name2 = 'name2-1052831874'; + $description = 'description-1724546052'; + $uid = 'uid115792'; + $expectedResponse = new PrivateCloud(); + $expectedResponse->setName($name2); + $expectedResponse->setDescription($description); + $expectedResponse->setUid($uid); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/undeletePrivateCloudTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedName = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); + $request = (new UndeletePrivateCloudRequest()) + ->setName($formattedName); + $response = $gapicClient->undeletePrivateCloud($request); + $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.vmwareengine.v1.VmwareEngine/UndeletePrivateCloud', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/undeletePrivateCloudTest'); + $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 undeletePrivateCloudExceptionTest() + { + $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/undeletePrivateCloudTest'); + $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->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); + $request = (new UndeletePrivateCloudRequest()) + ->setName($formattedName); + $response = $gapicClient->undeletePrivateCloud($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/undeletePrivateCloudTest'); + 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 updateClusterTest() + { + $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/updateClusterTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $management = false; + $uid = 'uid115792'; + $expectedResponse = new Cluster(); + $expectedResponse->setName($name); + $expectedResponse->setManagement($management); + $expectedResponse->setUid($uid); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/updateClusterTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $updateMask = new FieldMask(); + $cluster = new Cluster(); + $nodeTypeConfigsValue = new NodeTypeConfig(); + $valueNodeCount = 1174748740; + $nodeTypeConfigsValue->setNodeCount($valueNodeCount); + $clusterNodeTypeConfigs = [ + 'nodeTypeConfigsKey' => $nodeTypeConfigsValue, + ]; + $cluster->setNodeTypeConfigs($clusterNodeTypeConfigs); + $request = (new UpdateClusterRequest()) + ->setUpdateMask($updateMask) + ->setCluster($cluster); + $response = $gapicClient->updateCluster($request); + $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.vmwareengine.v1.VmwareEngine/UpdateCluster', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getUpdateMask(); + $this->assertProtobufEquals($updateMask, $actualValue); + $actualValue = $actualApiRequestObject->getCluster(); + $this->assertProtobufEquals($cluster, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updateClusterTest'); + $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 updateClusterExceptionTest() + { + $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/updateClusterTest'); + $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(); + $cluster = new Cluster(); + $nodeTypeConfigsValue = new NodeTypeConfig(); + $valueNodeCount = 1174748740; + $nodeTypeConfigsValue->setNodeCount($valueNodeCount); + $clusterNodeTypeConfigs = [ + 'nodeTypeConfigsKey' => $nodeTypeConfigsValue, + ]; + $cluster->setNodeTypeConfigs($clusterNodeTypeConfigs); + $request = (new UpdateClusterRequest()) + ->setUpdateMask($updateMask) + ->setCluster($cluster); + $response = $gapicClient->updateCluster($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updateClusterTest'); + 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 updateDnsForwardingTest() + { + $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/updateDnsForwardingTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $expectedResponse = new DnsForwarding(); + $expectedResponse->setName($name); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/updateDnsForwardingTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $dnsForwarding = new DnsForwarding(); + $dnsForwardingForwardingRules = []; + $dnsForwarding->setForwardingRules($dnsForwardingForwardingRules); + $updateMask = new FieldMask(); + $request = (new UpdateDnsForwardingRequest()) + ->setDnsForwarding($dnsForwarding) + ->setUpdateMask($updateMask); + $response = $gapicClient->updateDnsForwarding($request); + $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.vmwareengine.v1.VmwareEngine/UpdateDnsForwarding', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getDnsForwarding(); + $this->assertProtobufEquals($dnsForwarding, $actualValue); + $actualValue = $actualApiRequestObject->getUpdateMask(); + $this->assertProtobufEquals($updateMask, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updateDnsForwardingTest'); + $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 updateDnsForwardingExceptionTest() + { + $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/updateDnsForwardingTest'); + $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 + $dnsForwarding = new DnsForwarding(); + $dnsForwardingForwardingRules = []; + $dnsForwarding->setForwardingRules($dnsForwardingForwardingRules); + $updateMask = new FieldMask(); + $request = (new UpdateDnsForwardingRequest()) + ->setDnsForwarding($dnsForwarding) + ->setUpdateMask($updateMask); + $response = $gapicClient->updateDnsForwarding($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updateDnsForwardingTest'); + 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 updateExternalAccessRuleTest() + { + $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/updateExternalAccessRuleTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $description = 'description-1724546052'; + $priority = 1165461084; + $ipProtocol = 'ipProtocol-1134653776'; + $uid = 'uid115792'; + $expectedResponse = new ExternalAccessRule(); + $expectedResponse->setName($name); + $expectedResponse->setDescription($description); + $expectedResponse->setPriority($priority); + $expectedResponse->setIpProtocol($ipProtocol); + $expectedResponse->setUid($uid); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/updateExternalAccessRuleTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $updateMask = new FieldMask(); + $externalAccessRule = new ExternalAccessRule(); + $request = (new UpdateExternalAccessRuleRequest()) + ->setUpdateMask($updateMask) + ->setExternalAccessRule($externalAccessRule); + $response = $gapicClient->updateExternalAccessRule($request); + $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.vmwareengine.v1.VmwareEngine/UpdateExternalAccessRule', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getUpdateMask(); + $this->assertProtobufEquals($updateMask, $actualValue); + $actualValue = $actualApiRequestObject->getExternalAccessRule(); + $this->assertProtobufEquals($externalAccessRule, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updateExternalAccessRuleTest'); + $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 updateExternalAccessRuleExceptionTest() + { + $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/updateExternalAccessRuleTest'); + $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(); + $externalAccessRule = new ExternalAccessRule(); + $request = (new UpdateExternalAccessRuleRequest()) + ->setUpdateMask($updateMask) + ->setExternalAccessRule($externalAccessRule); + $response = $gapicClient->updateExternalAccessRule($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updateExternalAccessRuleTest'); + 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 updateExternalAddressTest() + { + $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/updateExternalAddressTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $internalIp = 'internalIp-2080778775'; + $externalIp = 'externalIp-1153075685'; + $uid = 'uid115792'; + $description = 'description-1724546052'; + $expectedResponse = new ExternalAddress(); + $expectedResponse->setName($name); + $expectedResponse->setInternalIp($internalIp); + $expectedResponse->setExternalIp($externalIp); + $expectedResponse->setUid($uid); + $expectedResponse->setDescription($description); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/updateExternalAddressTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $updateMask = new FieldMask(); + $externalAddress = new ExternalAddress(); + $request = (new UpdateExternalAddressRequest()) + ->setUpdateMask($updateMask) + ->setExternalAddress($externalAddress); + $response = $gapicClient->updateExternalAddress($request); + $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.vmwareengine.v1.VmwareEngine/UpdateExternalAddress', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getUpdateMask(); + $this->assertProtobufEquals($updateMask, $actualValue); + $actualValue = $actualApiRequestObject->getExternalAddress(); + $this->assertProtobufEquals($externalAddress, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updateExternalAddressTest'); + $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 updateExternalAddressExceptionTest() + { + $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/updateExternalAddressTest'); + $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(); + $externalAddress = new ExternalAddress(); + $request = (new UpdateExternalAddressRequest()) + ->setUpdateMask($updateMask) + ->setExternalAddress($externalAddress); + $response = $gapicClient->updateExternalAddress($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updateExternalAddressTest'); + 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 updateLoggingServerTest() + { + $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/updateLoggingServerTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $hostname = 'hostname-299803597'; + $port = 3446913; + $uid = 'uid115792'; + $expectedResponse = new LoggingServer(); + $expectedResponse->setName($name); + $expectedResponse->setHostname($hostname); + $expectedResponse->setPort($port); + $expectedResponse->setUid($uid); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/updateLoggingServerTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $updateMask = new FieldMask(); + $loggingServer = new LoggingServer(); + $loggingServerHostname = 'loggingServerHostname2082652629'; + $loggingServer->setHostname($loggingServerHostname); + $loggingServerPort = 243392733; + $loggingServer->setPort($loggingServerPort); + $loggingServerProtocol = Protocol::PROTOCOL_UNSPECIFIED; + $loggingServer->setProtocol($loggingServerProtocol); + $loggingServerSourceType = SourceType::SOURCE_TYPE_UNSPECIFIED; + $loggingServer->setSourceType($loggingServerSourceType); + $request = (new UpdateLoggingServerRequest()) + ->setUpdateMask($updateMask) + ->setLoggingServer($loggingServer); + $response = $gapicClient->updateLoggingServer($request); + $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.vmwareengine.v1.VmwareEngine/UpdateLoggingServer', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getUpdateMask(); + $this->assertProtobufEquals($updateMask, $actualValue); + $actualValue = $actualApiRequestObject->getLoggingServer(); + $this->assertProtobufEquals($loggingServer, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updateLoggingServerTest'); + $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 updateLoggingServerExceptionTest() + { + $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/updateLoggingServerTest'); + $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(); + $loggingServer = new LoggingServer(); + $loggingServerHostname = 'loggingServerHostname2082652629'; + $loggingServer->setHostname($loggingServerHostname); + $loggingServerPort = 243392733; + $loggingServer->setPort($loggingServerPort); + $loggingServerProtocol = Protocol::PROTOCOL_UNSPECIFIED; + $loggingServer->setProtocol($loggingServerProtocol); + $loggingServerSourceType = SourceType::SOURCE_TYPE_UNSPECIFIED; + $loggingServer->setSourceType($loggingServerSourceType); + $request = (new UpdateLoggingServerRequest()) + ->setUpdateMask($updateMask) + ->setLoggingServer($loggingServer); + $response = $gapicClient->updateLoggingServer($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updateLoggingServerTest'); + 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 updateManagementDnsZoneBindingTest() + { + $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/updateManagementDnsZoneBindingTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $description = 'description-1724546052'; + $vpcNetwork = 'vpcNetwork-764161832'; + $uid = 'uid115792'; + $expectedResponse = new ManagementDnsZoneBinding(); + $expectedResponse->setName($name); + $expectedResponse->setDescription($description); + $expectedResponse->setVpcNetwork($vpcNetwork); + $expectedResponse->setUid($uid); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/updateManagementDnsZoneBindingTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $updateMask = new FieldMask(); + $managementDnsZoneBinding = new ManagementDnsZoneBinding(); + $request = (new UpdateManagementDnsZoneBindingRequest()) + ->setUpdateMask($updateMask) + ->setManagementDnsZoneBinding($managementDnsZoneBinding); + $response = $gapicClient->updateManagementDnsZoneBinding($request); + $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.vmwareengine.v1.VmwareEngine/UpdateManagementDnsZoneBinding', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getUpdateMask(); + $this->assertProtobufEquals($updateMask, $actualValue); + $actualValue = $actualApiRequestObject->getManagementDnsZoneBinding(); + $this->assertProtobufEquals($managementDnsZoneBinding, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updateManagementDnsZoneBindingTest'); + $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 updateManagementDnsZoneBindingExceptionTest() + { + $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/updateManagementDnsZoneBindingTest'); + $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(); + $managementDnsZoneBinding = new ManagementDnsZoneBinding(); + $request = (new UpdateManagementDnsZoneBindingRequest()) + ->setUpdateMask($updateMask) + ->setManagementDnsZoneBinding($managementDnsZoneBinding); + $response = $gapicClient->updateManagementDnsZoneBinding($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updateManagementDnsZoneBindingTest'); + 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 updateNetworkPeeringTest() + { + $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/updateNetworkPeeringTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $peerNetwork = 'peerNetwork2111238225'; + $exportCustomRoutes = false; + $importCustomRoutes = true; + $exchangeSubnetRoutes = true; + $exportCustomRoutesWithPublicIp = true; + $importCustomRoutesWithPublicIp = false; + $stateDetails = 'stateDetails632437908'; + $peerMtu = 69584721; + $uid = 'uid115792'; + $vmwareEngineNetwork = 'vmwareEngineNetwork-90899684'; + $description = 'description-1724546052'; + $expectedResponse = new NetworkPeering(); + $expectedResponse->setName($name); + $expectedResponse->setPeerNetwork($peerNetwork); + $expectedResponse->setExportCustomRoutes($exportCustomRoutes); + $expectedResponse->setImportCustomRoutes($importCustomRoutes); + $expectedResponse->setExchangeSubnetRoutes($exchangeSubnetRoutes); + $expectedResponse->setExportCustomRoutesWithPublicIp($exportCustomRoutesWithPublicIp); + $expectedResponse->setImportCustomRoutesWithPublicIp($importCustomRoutesWithPublicIp); + $expectedResponse->setStateDetails($stateDetails); + $expectedResponse->setPeerMtu($peerMtu); + $expectedResponse->setUid($uid); + $expectedResponse->setVmwareEngineNetwork($vmwareEngineNetwork); + $expectedResponse->setDescription($description); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/updateNetworkPeeringTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $networkPeering = new NetworkPeering(); + $networkPeeringPeerNetwork = 'networkPeeringPeerNetwork-385302054'; + $networkPeering->setPeerNetwork($networkPeeringPeerNetwork); + $networkPeeringPeerNetworkType = PeerNetworkType::PEER_NETWORK_TYPE_UNSPECIFIED; + $networkPeering->setPeerNetworkType($networkPeeringPeerNetworkType); + $networkPeeringVmwareEngineNetwork = $gapicClient->vmwareEngineNetworkName('[PROJECT]', '[LOCATION]', '[VMWARE_ENGINE_NETWORK]'); + $networkPeering->setVmwareEngineNetwork($networkPeeringVmwareEngineNetwork); + $updateMask = new FieldMask(); + $request = (new UpdateNetworkPeeringRequest()) + ->setNetworkPeering($networkPeering) + ->setUpdateMask($updateMask); + $response = $gapicClient->updateNetworkPeering($request); + $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.vmwareengine.v1.VmwareEngine/UpdateNetworkPeering', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getNetworkPeering(); + $this->assertProtobufEquals($networkPeering, $actualValue); + $actualValue = $actualApiRequestObject->getUpdateMask(); + $this->assertProtobufEquals($updateMask, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updateNetworkPeeringTest'); + $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 updateNetworkPeeringExceptionTest() + { + $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/updateNetworkPeeringTest'); + $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 + $networkPeering = new NetworkPeering(); + $networkPeeringPeerNetwork = 'networkPeeringPeerNetwork-385302054'; + $networkPeering->setPeerNetwork($networkPeeringPeerNetwork); + $networkPeeringPeerNetworkType = PeerNetworkType::PEER_NETWORK_TYPE_UNSPECIFIED; + $networkPeering->setPeerNetworkType($networkPeeringPeerNetworkType); + $networkPeeringVmwareEngineNetwork = $gapicClient->vmwareEngineNetworkName('[PROJECT]', '[LOCATION]', '[VMWARE_ENGINE_NETWORK]'); + $networkPeering->setVmwareEngineNetwork($networkPeeringVmwareEngineNetwork); + $updateMask = new FieldMask(); + $request = (new UpdateNetworkPeeringRequest()) + ->setNetworkPeering($networkPeering) + ->setUpdateMask($updateMask); + $response = $gapicClient->updateNetworkPeering($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updateNetworkPeeringTest'); + 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 updateNetworkPolicyTest() + { + $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/updateNetworkPolicyTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $edgeServicesCidr = 'edgeServicesCidr-792872013'; + $uid = 'uid115792'; + $vmwareEngineNetwork = 'vmwareEngineNetwork-90899684'; + $description = 'description-1724546052'; + $vmwareEngineNetworkCanonical = 'vmwareEngineNetworkCanonical779839377'; + $expectedResponse = new NetworkPolicy(); + $expectedResponse->setName($name); + $expectedResponse->setEdgeServicesCidr($edgeServicesCidr); + $expectedResponse->setUid($uid); + $expectedResponse->setVmwareEngineNetwork($vmwareEngineNetwork); + $expectedResponse->setDescription($description); + $expectedResponse->setVmwareEngineNetworkCanonical($vmwareEngineNetworkCanonical); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/updateNetworkPolicyTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $networkPolicy = new NetworkPolicy(); + $networkPolicyEdgeServicesCidr = 'networkPolicyEdgeServicesCidr-602005393'; + $networkPolicy->setEdgeServicesCidr($networkPolicyEdgeServicesCidr); + $updateMask = new FieldMask(); + $request = (new UpdateNetworkPolicyRequest()) + ->setNetworkPolicy($networkPolicy) + ->setUpdateMask($updateMask); + $response = $gapicClient->updateNetworkPolicy($request); + $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.vmwareengine.v1.VmwareEngine/UpdateNetworkPolicy', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getNetworkPolicy(); + $this->assertProtobufEquals($networkPolicy, $actualValue); + $actualValue = $actualApiRequestObject->getUpdateMask(); + $this->assertProtobufEquals($updateMask, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updateNetworkPolicyTest'); + $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 updateNetworkPolicyExceptionTest() + { + $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/updateNetworkPolicyTest'); + $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 + $networkPolicy = new NetworkPolicy(); + $networkPolicyEdgeServicesCidr = 'networkPolicyEdgeServicesCidr-602005393'; + $networkPolicy->setEdgeServicesCidr($networkPolicyEdgeServicesCidr); + $updateMask = new FieldMask(); + $request = (new UpdateNetworkPolicyRequest()) + ->setNetworkPolicy($networkPolicy) + ->setUpdateMask($updateMask); + $response = $gapicClient->updateNetworkPolicy($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updateNetworkPolicyTest'); + 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 updatePrivateCloudTest() + { + $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/updatePrivateCloudTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $description = 'description-1724546052'; + $uid = 'uid115792'; + $expectedResponse = new PrivateCloud(); + $expectedResponse->setName($name); + $expectedResponse->setDescription($description); + $expectedResponse->setUid($uid); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/updatePrivateCloudTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $privateCloud = new PrivateCloud(); + $privateCloudNetworkConfig = new NetworkConfig(); + $networkConfigManagementCidr = 'networkConfigManagementCidr2092091783'; + $privateCloudNetworkConfig->setManagementCidr($networkConfigManagementCidr); + $privateCloud->setNetworkConfig($privateCloudNetworkConfig); + $privateCloudManagementCluster = new ManagementCluster(); + $managementClusterClusterId = 'managementClusterClusterId311493182'; + $privateCloudManagementCluster->setClusterId($managementClusterClusterId); + $nodeTypeConfigsValue = new NodeTypeConfig(); + $valueNodeCount = 1174748740; + $nodeTypeConfigsValue->setNodeCount($valueNodeCount); + $managementClusterNodeTypeConfigs = [ + 'nodeTypeConfigsKey' => $nodeTypeConfigsValue, + ]; + $privateCloudManagementCluster->setNodeTypeConfigs($managementClusterNodeTypeConfigs); + $privateCloud->setManagementCluster($privateCloudManagementCluster); + $updateMask = new FieldMask(); + $request = (new UpdatePrivateCloudRequest()) + ->setPrivateCloud($privateCloud) + ->setUpdateMask($updateMask); + $response = $gapicClient->updatePrivateCloud($request); + $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.vmwareengine.v1.VmwareEngine/UpdatePrivateCloud', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getPrivateCloud(); + $this->assertProtobufEquals($privateCloud, $actualValue); + $actualValue = $actualApiRequestObject->getUpdateMask(); + $this->assertProtobufEquals($updateMask, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updatePrivateCloudTest'); + $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 updatePrivateCloudExceptionTest() + { + $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/updatePrivateCloudTest'); + $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 + $privateCloud = new PrivateCloud(); + $privateCloudNetworkConfig = new NetworkConfig(); + $networkConfigManagementCidr = 'networkConfigManagementCidr2092091783'; + $privateCloudNetworkConfig->setManagementCidr($networkConfigManagementCidr); + $privateCloud->setNetworkConfig($privateCloudNetworkConfig); + $privateCloudManagementCluster = new ManagementCluster(); + $managementClusterClusterId = 'managementClusterClusterId311493182'; + $privateCloudManagementCluster->setClusterId($managementClusterClusterId); + $nodeTypeConfigsValue = new NodeTypeConfig(); + $valueNodeCount = 1174748740; + $nodeTypeConfigsValue->setNodeCount($valueNodeCount); + $managementClusterNodeTypeConfigs = [ + 'nodeTypeConfigsKey' => $nodeTypeConfigsValue, + ]; + $privateCloudManagementCluster->setNodeTypeConfigs($managementClusterNodeTypeConfigs); + $privateCloud->setManagementCluster($privateCloudManagementCluster); + $updateMask = new FieldMask(); + $request = (new UpdatePrivateCloudRequest()) + ->setPrivateCloud($privateCloud) + ->setUpdateMask($updateMask); + $response = $gapicClient->updatePrivateCloud($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updatePrivateCloudTest'); + 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 updatePrivateConnectionTest() + { + $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/updatePrivateConnectionTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $description = 'description-1724546052'; + $vmwareEngineNetwork = 'vmwareEngineNetwork-90899684'; + $vmwareEngineNetworkCanonical = 'vmwareEngineNetworkCanonical779839377'; + $peeringId = 'peeringId-1561749894'; + $uid = 'uid115792'; + $serviceNetwork = 'serviceNetwork1072775844'; + $expectedResponse = new PrivateConnection(); + $expectedResponse->setName($name); + $expectedResponse->setDescription($description); + $expectedResponse->setVmwareEngineNetwork($vmwareEngineNetwork); + $expectedResponse->setVmwareEngineNetworkCanonical($vmwareEngineNetworkCanonical); + $expectedResponse->setPeeringId($peeringId); + $expectedResponse->setUid($uid); + $expectedResponse->setServiceNetwork($serviceNetwork); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/updatePrivateConnectionTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $privateConnection = new PrivateConnection(); + $privateConnectionVmwareEngineNetwork = $gapicClient->vmwareEngineNetworkName('[PROJECT]', '[LOCATION]', '[VMWARE_ENGINE_NETWORK]'); + $privateConnection->setVmwareEngineNetwork($privateConnectionVmwareEngineNetwork); + $privateConnectionType = Type::TYPE_UNSPECIFIED; + $privateConnection->setType($privateConnectionType); + $privateConnectionServiceNetwork = $gapicClient->networkName('[PROJECT]', '[NETWORK]'); + $privateConnection->setServiceNetwork($privateConnectionServiceNetwork); + $updateMask = new FieldMask(); + $request = (new UpdatePrivateConnectionRequest()) + ->setPrivateConnection($privateConnection) + ->setUpdateMask($updateMask); + $response = $gapicClient->updatePrivateConnection($request); + $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.vmwareengine.v1.VmwareEngine/UpdatePrivateConnection', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getPrivateConnection(); + $this->assertProtobufEquals($privateConnection, $actualValue); + $actualValue = $actualApiRequestObject->getUpdateMask(); + $this->assertProtobufEquals($updateMask, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updatePrivateConnectionTest'); + $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 updatePrivateConnectionExceptionTest() + { + $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/updatePrivateConnectionTest'); + $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 + $privateConnection = new PrivateConnection(); + $privateConnectionVmwareEngineNetwork = $gapicClient->vmwareEngineNetworkName('[PROJECT]', '[LOCATION]', '[VMWARE_ENGINE_NETWORK]'); + $privateConnection->setVmwareEngineNetwork($privateConnectionVmwareEngineNetwork); + $privateConnectionType = Type::TYPE_UNSPECIFIED; + $privateConnection->setType($privateConnectionType); + $privateConnectionServiceNetwork = $gapicClient->networkName('[PROJECT]', '[NETWORK]'); + $privateConnection->setServiceNetwork($privateConnectionServiceNetwork); + $updateMask = new FieldMask(); + $request = (new UpdatePrivateConnectionRequest()) + ->setPrivateConnection($privateConnection) + ->setUpdateMask($updateMask); + $response = $gapicClient->updatePrivateConnection($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updatePrivateConnectionTest'); + 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 updateSubnetTest() + { + $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/updateSubnetTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $ipCidrRange = 'ipCidrRange-2049366326'; + $gatewayIp = 'gatewayIp955798786'; + $type = 'type3575610'; + $vlanId = 536153463; + $expectedResponse = new Subnet(); + $expectedResponse->setName($name); + $expectedResponse->setIpCidrRange($ipCidrRange); + $expectedResponse->setGatewayIp($gatewayIp); + $expectedResponse->setType($type); + $expectedResponse->setVlanId($vlanId); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/updateSubnetTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $updateMask = new FieldMask(); + $subnet = new Subnet(); + $request = (new UpdateSubnetRequest()) + ->setUpdateMask($updateMask) + ->setSubnet($subnet); + $response = $gapicClient->updateSubnet($request); + $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.vmwareengine.v1.VmwareEngine/UpdateSubnet', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getUpdateMask(); + $this->assertProtobufEquals($updateMask, $actualValue); + $actualValue = $actualApiRequestObject->getSubnet(); + $this->assertProtobufEquals($subnet, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updateSubnetTest'); + $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 updateSubnetExceptionTest() + { + $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/updateSubnetTest'); + $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(); + $subnet = new Subnet(); + $request = (new UpdateSubnetRequest()) + ->setUpdateMask($updateMask) + ->setSubnet($subnet); + $response = $gapicClient->updateSubnet($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updateSubnetTest'); + 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 updateVmwareEngineNetworkTest() + { + $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/updateVmwareEngineNetworkTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $description = 'description-1724546052'; + $uid = 'uid115792'; + $etag = 'etag3123477'; + $expectedResponse = new VmwareEngineNetwork(); + $expectedResponse->setName($name); + $expectedResponse->setDescription($description); + $expectedResponse->setUid($uid); + $expectedResponse->setEtag($etag); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/updateVmwareEngineNetworkTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $vmwareEngineNetwork = new VmwareEngineNetwork(); + $vmwareEngineNetworkType = \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork\Type::TYPE_UNSPECIFIED; + $vmwareEngineNetwork->setType($vmwareEngineNetworkType); + $updateMask = new FieldMask(); + $request = (new UpdateVmwareEngineNetworkRequest()) + ->setVmwareEngineNetwork($vmwareEngineNetwork) + ->setUpdateMask($updateMask); + $response = $gapicClient->updateVmwareEngineNetwork($request); + $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.vmwareengine.v1.VmwareEngine/UpdateVmwareEngineNetwork', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getVmwareEngineNetwork(); + $this->assertProtobufEquals($vmwareEngineNetwork, $actualValue); + $actualValue = $actualApiRequestObject->getUpdateMask(); + $this->assertProtobufEquals($updateMask, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updateVmwareEngineNetworkTest'); + $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 updateVmwareEngineNetworkExceptionTest() + { + $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/updateVmwareEngineNetworkTest'); + $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 + $vmwareEngineNetwork = new VmwareEngineNetwork(); + $vmwareEngineNetworkType = \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork\Type::TYPE_UNSPECIFIED; + $vmwareEngineNetwork->setType($vmwareEngineNetworkType); + $updateMask = new FieldMask(); + $request = (new UpdateVmwareEngineNetworkRequest()) + ->setVmwareEngineNetwork($vmwareEngineNetwork) + ->setUpdateMask($updateMask); + $response = $gapicClient->updateVmwareEngineNetwork($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updateVmwareEngineNetworkTest'); + 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); + $request = new GetLocationRequest(); + $response = $gapicClient->getLocation($request); + $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); + $request = new GetLocationRequest(); + try { + $gapicClient->getLocation($request); + // 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); + $request = new ListLocationsRequest(); + $response = $gapicClient->listLocations($request); + $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); + $request = new ListLocationsRequest(); + try { + $gapicClient->listLocations($request); + // 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'; + $request = (new GetIamPolicyRequest()) + ->setResource($resource); + $response = $gapicClient->getIamPolicy($request); + $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'; + $request = (new GetIamPolicyRequest()) + ->setResource($resource); + try { + $gapicClient->getIamPolicy($request); + // 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(); + $request = (new SetIamPolicyRequest()) + ->setResource($resource) + ->setPolicy($policy); + $response = $gapicClient->setIamPolicy($request); + $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(); + $request = (new SetIamPolicyRequest()) + ->setResource($resource) + ->setPolicy($policy); + try { + $gapicClient->setIamPolicy($request); + // 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 = []; + $request = (new TestIamPermissionsRequest()) + ->setResource($resource) + ->setPermissions($permissions); + $response = $gapicClient->testIamPermissions($request); + $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 = []; + $request = (new TestIamPermissionsRequest()) + ->setResource($resource) + ->setPermissions($permissions); + try { + $gapicClient->testIamPermissions($request); + // 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 createClusterAsyncTest() + { + $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/createClusterTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $management = false; + $uid = 'uid115792'; + $expectedResponse = new Cluster(); + $expectedResponse->setName($name); + $expectedResponse->setManagement($management); + $expectedResponse->setUid($uid); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/createClusterTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedParent = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); + $clusterId = 'clusterId240280960'; + $cluster = new Cluster(); + $nodeTypeConfigsValue = new NodeTypeConfig(); + $valueNodeCount = 1174748740; + $nodeTypeConfigsValue->setNodeCount($valueNodeCount); + $clusterNodeTypeConfigs = [ + 'nodeTypeConfigsKey' => $nodeTypeConfigsValue, + ]; + $cluster->setNodeTypeConfigs($clusterNodeTypeConfigs); + $request = (new CreateClusterRequest()) + ->setParent($formattedParent) + ->setClusterId($clusterId) + ->setCluster($cluster); + $response = $gapicClient->createClusterAsync($request)->wait(); + $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.vmwareengine.v1.VmwareEngine/CreateCluster', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualApiRequestObject->getClusterId(); + $this->assertProtobufEquals($clusterId, $actualValue); + $actualValue = $actualApiRequestObject->getCluster(); + $this->assertProtobufEquals($cluster, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createClusterTest'); + $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()); + } +} diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/GPBMetadata/Google/Cloud/Workloadmanager/V1/Service.php b/owl-bot-staging/WorkloadManager/v1/proto/src/GPBMetadata/Google/Cloud/Workloadmanager/V1/Service.php new file mode 100644 index 000000000000..d48b9b6684bd --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/GPBMetadata/Google/Cloud/Workloadmanager/V1/Service.php @@ -0,0 +1,32 @@ +internalAddGeneratedFile( + "\x0A\x9CZ\x0A-google/cloud/workloadmanager/v1/service.proto\x12\x1Fgoogle.cloud.workloadmanager.v1\x1A\x17google/api/client.proto\x1A\x1Fgoogle/api/field_behavior.proto\x1A\x19google/api/resource.proto\x1A#google/longrunning/operations.proto\x1A\x1Bgoogle/protobuf/empty.proto\x1A google/protobuf/field_mask.proto\x1A\x1Fgoogle/protobuf/timestamp.proto\"\xD0\x07\x0A\x0AEvaluation\x12\x0C\x0A\x04name\x18\x01 \x01(\x09\x12\x13\x0A\x0Bdescription\x18\x02 \x01(\x09\x12H\x0A\x0Fresource_filter\x18\x03 \x01(\x0B2/.google.cloud.workloadmanager.v1.ResourceFilter\x12\x12\x0A\x0Arule_names\x18\x04 \x03(\x09\x12M\x0A\x0Fresource_status\x18\x06 \x01(\x0B2/.google.cloud.workloadmanager.v1.ResourceStatusB\x03\xE0A\x03\x124\x0A\x0Bcreate_time\x18\x07 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x08 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12G\x0A\x06labels\x18\x09 \x03(\x0B27.google.cloud.workloadmanager.v1.Evaluation.LabelsEntry\x12\x15\x0A\x08schedule\x18\x0A \x01(\x09H\x00\x88\x01\x01\x12\x1B\x0A\x13custom_rules_bucket\x18\x0B \x01(\x09\x12S\x0A\x0Fevaluation_type\x18\x0C \x01(\x0E2:.google.cloud.workloadmanager.v1.Evaluation.EvaluationType\x12X\x0A\x15big_query_destination\x18\x0D \x01(\x0B24.google.cloud.workloadmanager.v1.BigQueryDestinationB\x03\xE0A\x01\x12:\x0A\x07kms_key\x18\x0F \x01(\x09B)\xE0A\x05\xFAA#\x0A!cloudkms.googleapis.com/CryptoKey\x1A-\x0A\x0BLabelsEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12\x0D\x0A\x05value\x18\x02 \x01(\x09:\x028\x01\"U\x0A\x0EEvaluationType\x12\x1F\x0A\x1BEVALUATION_TYPE_UNSPECIFIED\x10\x00\x12\x07\x0A\x03SAP\x10\x01\x12\x0E\x0A\x0ASQL_SERVER\x10\x02\x12\x09\x0A\x05OTHER\x10\x03:\x8A\x01\xEAA\x86\x01\x0A)workloadmanager.googleapis.com/Evaluation\x12@projects/{project}/locations/{location}/evaluations/{evaluation}*\x0Bevaluations2\x0AevaluationB\x0B\x0A\x09_schedule\"\xA7\x02\x0A\x0EResourceFilter\x12\x0E\x0A\x06scopes\x18\x01 \x03(\x09\x12\x1C\x0A\x14resource_id_patterns\x18\x02 \x03(\x09\x12^\x0A\x10inclusion_labels\x18\x03 \x03(\x0B2D.google.cloud.workloadmanager.v1.ResourceFilter.InclusionLabelsEntry\x12O\x0A\x13gce_instance_filter\x18\x04 \x01(\x0B22.google.cloud.workloadmanager.v1.GceInstanceFilter\x1A6\x0A\x14InclusionLabelsEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12\x0D\x0A\x05value\x18\x02 \x01(\x09:\x028\x01\"-\x0A\x11GceInstanceFilter\x12\x18\x0A\x10service_accounts\x18\x04 \x03(\x09\"\x9E\x01\x0A\x0EResourceStatus\x12D\x0A\x05state\x18\x02 \x01(\x0E25.google.cloud.workloadmanager.v1.ResourceStatus.State\"F\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x0C\x0A\x08CREATING\x10\x01\x12\x0A\x0A\x06ACTIVE\x10\x02\x12\x0C\x0A\x08DELETING\x10\x03\"^\x0A\x13BigQueryDestination\x12 \x0A\x13destination_dataset\x18\x01 \x01(\x09B\x03\xE0A\x01\x12%\x0A\x18create_new_results_table\x18\x02 \x01(\x08B\x03\xE0A\x01\"\xA4\x01\x0A\x16ListEvaluationsRequest\x12A\x0A\x06parent\x18\x01 \x01(\x09B1\xE0A\x02\xFAA+\x12)workloadmanager.googleapis.com/Evaluation\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\x12\x0E\x0A\x06filter\x18\x04 \x01(\x09\x12\x10\x0A\x08order_by\x18\x05 \x01(\x09\"\x89\x01\x0A\x17ListEvaluationsResponse\x12@\x0A\x0Bevaluations\x18\x01 \x03(\x0B2+.google.cloud.workloadmanager.v1.Evaluation\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\x12\x13\x0A\x0Bunreachable\x18\x03 \x03(\x09\"W\x0A\x14GetEvaluationRequest\x12?\x0A\x04name\x18\x01 \x01(\x09B1\xE0A\x02\xFAA+\x0A)workloadmanager.googleapis.com/Evaluation\"\xD7\x01\x0A\x17CreateEvaluationRequest\x12A\x0A\x06parent\x18\x01 \x01(\x09B1\xE0A\x02\xFAA+\x12)workloadmanager.googleapis.com/Evaluation\x12\x1A\x0A\x0Devaluation_id\x18\x02 \x01(\x09B\x03\xE0A\x02\x12D\x0A\x0Aevaluation\x18\x03 \x01(\x0B2+.google.cloud.workloadmanager.v1.EvaluationB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x04 \x01(\x09B\x03\xE0A\x01\"\xAE\x01\x0A\x17UpdateEvaluationRequest\x124\x0A\x0Bupdate_mask\x18\x01 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x02\x12D\x0A\x0Aevaluation\x18\x02 \x01(\x0B2+.google.cloud.workloadmanager.v1.EvaluationB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x03\xE0A\x01\"\x87\x01\x0A\x17DeleteEvaluationRequest\x12?\x0A\x04name\x18\x01 \x01(\x09B1\xE0A\x02\xFAA+\x0A)workloadmanager.googleapis.com/Evaluation\x12\x17\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x03\xE0A\x01\x12\x12\x0A\x05force\x18\x03 \x01(\x08B\x03\xE0A\x01\"\xA5\x0C\x0A\x09Execution\x12\x0C\x0A\x04name\x18\x01 \x01(\x09\x123\x0A\x0Astart_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x121\x0A\x08end_time\x18\x03 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x127\x0A\x0Einventory_time\x18\x04 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12D\x0A\x05state\x18\x05 \x01(\x0E20.google.cloud.workloadmanager.v1.Execution.StateB\x03\xE0A\x03\x12\x1A\x0A\x0Devaluation_id\x18\x06 \x01(\x09B\x03\xE0A\x03\x12F\x0A\x06labels\x18\x07 \x03(\x0B26.google.cloud.workloadmanager.v1.Execution.LabelsEntry\x12A\x0A\x08run_type\x18\x08 \x01(\x0E2/.google.cloud.workloadmanager.v1.Execution.Type\x12O\x0A\x0Crule_results\x18\x09 \x03(\x0B24.google.cloud.workloadmanager.v1.RuleExecutionResultB\x03\xE0A\x03\x12b\x0A\x15external_data_sources\x18\x0A \x03(\x0B2>.google.cloud.workloadmanager.v1.Execution.ExternalDataSourcesB\x03\xE0A\x01\x12G\x0A\x07notices\x18\x0B \x03(\x0B21.google.cloud.workloadmanager.v1.Execution.NoticeB\x03\xE0A\x03\x12F\x0A\x06engine\x18\x0C \x01(\x0E21.google.cloud.workloadmanager.v1.Execution.EngineB\x03\xE0A\x01\x12O\x0A\x0Eresult_summary\x18\x0D \x01(\x0B22.google.cloud.workloadmanager.v1.Execution.SummaryB\x03\xE0A\x03\x1A\xDE\x01\x0A\x13ExternalDataSources\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x01\x12\x10\x0A\x03uri\x18\x02 \x01(\x09B\x03\xE0A\x02\x12V\x0A\x04type\x18\x03 \x01(\x0E2C.google.cloud.workloadmanager.v1.Execution.ExternalDataSources.TypeB\x03\xE0A\x02\x12\x17\x0A\x0Aasset_type\x18\x04 \x01(\x09B\x03\xE0A\x02\"1\x0A\x04Type\x12\x14\x0A\x10TYPE_UNSPECIFIED\x10\x00\x12\x13\x0A\x0FBIG_QUERY_TABLE\x10\x01\x1A\x1E\x0A\x06Notice\x12\x14\x0A\x07message\x18\x01 \x01(\x09B\x03\xE0A\x03\x1AS\x0A\x07Summary\x12\x15\x0A\x08failures\x18\x01 \x01(\x03B\x03\xE0A\x03\x12\x19\x0A\x0Cnew_failures\x18\x02 \x01(\x03B\x03\xE0A\x03\x12\x16\x0A\x09new_fixes\x18\x03 \x01(\x03B\x03\xE0A\x03\x1A-\x0A\x0BLabelsEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12\x0D\x0A\x05value\x18\x02 \x01(\x09:\x028\x01\"F\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x0B\x0A\x07RUNNING\x10\x01\x12\x0D\x0A\x09SUCCEEDED\x10\x02\x12\x0A\x0A\x06FAILED\x10\x03\"9\x0A\x04Type\x12\x14\x0A\x10TYPE_UNSPECIFIED\x10\x00\x12\x0C\x0A\x08ONE_TIME\x10\x01\x12\x0D\x0A\x09SCHEDULED\x10\x02\"<\x0A\x06Engine\x12\x16\x0A\x12ENGINE_UNSPECIFIED\x10\x00\x12\x12\x0A\x0EENGINE_SCANNER\x10\x01\x12\x06\x0A\x02V2\x10\x02:\x9E\x01\xEAA\x9A\x01\x0A(workloadmanager.googleapis.com/Execution\x12Wprojects/{project}/locations/{location}/evaluations/{evaluation}/executions/{execution}*\x0Aexecutions2\x09execution\"\x93\x02\x0A\x13RuleExecutionResult\x12\x0C\x0A\x04rule\x18\x01 \x01(\x09\x12N\x0A\x05state\x18\x02 \x01(\x0E2:.google.cloud.workloadmanager.v1.RuleExecutionResult.StateB\x03\xE0A\x03\x12\x0F\x0A\x07message\x18\x03 \x01(\x09\x12\x14\x0A\x0Cresult_count\x18\x04 \x01(\x03\x12\x1E\x0A\x16scanned_resource_count\x18\x05 \x01(\x03\"W\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x11\x0A\x0DSTATE_SUCCESS\x10\x01\x12\x11\x0A\x0DSTATE_FAILURE\x10\x02\x12\x11\x0A\x0DSTATE_SKIPPED\x10\x03\"\xA2\x01\x0A\x15ListExecutionsRequest\x12@\x0A\x06parent\x18\x01 \x01(\x09B0\xE0A\x02\xFAA*\x12(workloadmanager.googleapis.com/Execution\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\x12\x0E\x0A\x06filter\x18\x04 \x01(\x09\x12\x10\x0A\x08order_by\x18\x05 \x01(\x09\"\x86\x01\x0A\x16ListExecutionsResponse\x12>\x0A\x0Aexecutions\x18\x01 \x03(\x0B2*.google.cloud.workloadmanager.v1.Execution\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\x12\x13\x0A\x0Bunreachable\x18\x03 \x03(\x09\"U\x0A\x13GetExecutionRequest\x12>\x0A\x04name\x18\x01 \x01(\x09B0\xE0A\x02\xFAA*\x0A(workloadmanager.googleapis.com/Execution\"\xCF\x01\x0A\x14RunEvaluationRequest\x12?\x0A\x04name\x18\x01 \x01(\x09B1\xE0A\x02\xFAA+\x0A)workloadmanager.googleapis.com/Evaluation\x12\x19\x0A\x0Cexecution_id\x18\x02 \x01(\x09B\x03\xE0A\x02\x12B\x0A\x09execution\x18\x03 \x01(\x0B2*.google.cloud.workloadmanager.v1.ExecutionB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x04 \x01(\x09B\x03\xE0A\x01\"q\x0A\x16DeleteExecutionRequest\x12>\x0A\x04name\x18\x01 \x01(\x09B0\xE0A\x02\xFAA*\x0A(workloadmanager.googleapis.com/Execution\x12\x17\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x03\xE0A\x01\"i\x0A\x1BListExecutionResultsRequest\x12\x13\x0A\x06parent\x18\x01 \x01(\x09B\x03\xE0A\x02\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\x12\x0E\x0A\x06filter\x18\x04 \x01(\x09\"\x84\x01\x0A\x1CListExecutionResultsResponse\x12K\x0A\x11execution_results\x18\x01 \x03(\x0B20.google.cloud.workloadmanager.v1.ExecutionResult\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\"\xDF\x03\x0A\x0FExecutionResult\x12\x19\x0A\x11violation_message\x18\x01 \x01(\x09\x12\x10\x0A\x08severity\x18\x02 \x01(\x09\x126\x0A\x04rule\x18\x03 \x01(\x09B(\xFAA%\x0A#workloadmanager.googleapis.com/Rule\x12\x19\x0A\x11documentation_url\x18\x04 \x01(\x09\x12;\x0A\x08resource\x18\x05 \x01(\x0B2).google.cloud.workloadmanager.v1.Resource\x12L\x0A\x11violation_details\x18\x06 \x01(\x0B21.google.cloud.workloadmanager.v1.ViolationDetails\x12:\x0A\x08commands\x18\x07 \x03(\x0B2(.google.cloud.workloadmanager.v1.Command\x12C\x0A\x04type\x18\x08 \x01(\x0E25.google.cloud.workloadmanager.v1.ExecutionResult.Type\"@\x0A\x04Type\x12\x14\x0A\x10TYPE_UNSPECIFIED\x10\x00\x12\x0F\x0A\x0BTYPE_PASSED\x10\x01\x12\x11\x0A\x0DTYPE_VIOLATED\x10\x02\"\xA9\x01\x0A\x07Command\x12F\x0A\x0Dagent_command\x18\x01 \x01(\x0B2-.google.cloud.workloadmanager.v1.AgentCommandH\x00\x12F\x0A\x0Dshell_command\x18\x02 \x01(\x0B2-.google.cloud.workloadmanager.v1.ShellCommandH\x00B\x0E\x0A\x0Ccommand_type\"\xA5\x01\x0A\x0CAgentCommand\x12\x0F\x0A\x07command\x18\x01 \x01(\x09\x12Q\x0A\x0Aparameters\x18\x02 \x03(\x0B2=.google.cloud.workloadmanager.v1.AgentCommand.ParametersEntry\x1A1\x0A\x0FParametersEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12\x0D\x0A\x05value\x18\x02 \x01(\x09:\x028\x01\"F\x0A\x0CShellCommand\x12\x0F\x0A\x07command\x18\x01 \x01(\x09\x12\x0C\x0A\x04args\x18\x02 \x01(\x09\x12\x17\x0A\x0Ftimeout_seconds\x18\x03 \x01(\x05\"\xA2\x01\x0A\x0ARuleOutput\x12N\x0A\x07details\x18\x01 \x03(\x0B28.google.cloud.workloadmanager.v1.RuleOutput.DetailsEntryB\x03\xE0A\x03\x12\x14\x0A\x07message\x18\x02 \x01(\x09B\x03\xE0A\x03\x1A.\x0A\x0CDetailsEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12\x0D\x0A\x05value\x18\x02 \x01(\x09:\x028\x01\"\x85\x02\x0A\x10ViolationDetails\x12\x0D\x0A\x05asset\x18\x01 \x01(\x09\x12\x17\x0A\x0Fservice_account\x18\x02 \x01(\x09\x12Q\x0A\x08observed\x18\x03 \x03(\x0B2?.google.cloud.workloadmanager.v1.ViolationDetails.ObservedEntry\x12E\x0A\x0Brule_output\x18\x04 \x03(\x0B2+.google.cloud.workloadmanager.v1.RuleOutputB\x03\xE0A\x03\x1A/\x0A\x0DObservedEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12\x0D\x0A\x05value\x18\x02 \x01(\x09:\x028\x01\"?\x0A\x08Resource\x12\x0C\x0A\x04type\x18\x01 \x01(\x09\x12\x0C\x0A\x04name\x18\x02 \x01(\x09\x12\x17\x0A\x0Fservice_account\x18\x03 \x01(\x09\"\x80\x02\x0A\x11OperationMetadata\x124\x0A\x0Bcreate_time\x18\x01 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x121\x0A\x08end_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12\x13\x0A\x06target\x18\x03 \x01(\x09B\x03\xE0A\x03\x12\x11\x0A\x04verb\x18\x04 \x01(\x09B\x03\xE0A\x03\x12\x1B\x0A\x0Estatus_message\x18\x05 \x01(\x09B\x03\xE0A\x03\x12#\x0A\x16requested_cancellation\x18\x06 \x01(\x08B\x03\xE0A\x03\x12\x18\x0A\x0Bapi_version\x18\x07 \x01(\x09B\x03\xE0A\x03\"\xED\x03\x0A\x04Rule\x12\x0C\x0A\x04name\x18\x01 \x01(\x09\x12\x18\x0A\x0Brevision_id\x18\x02 \x01(\x09B\x03\xE0A\x03\x12\x14\x0A\x0Cdisplay_name\x18\x03 \x01(\x09\x12\x13\x0A\x0Bdescription\x18\x04 \x01(\x09\x12\x10\x0A\x08severity\x18\x05 \x01(\x09\x12\x18\x0A\x10primary_category\x18\x06 \x01(\x09\x12\x1A\x0A\x12secondary_category\x18\x07 \x01(\x09\x12\x15\x0A\x0Derror_message\x18\x08 \x01(\x09\x12\x0B\x0A\x03uri\x18\x09 \x01(\x09\x12\x13\x0A\x0Bremediation\x18\x0A \x01(\x09\x12\x0C\x0A\x04tags\x18\x0B \x03(\x09\x12A\x0A\x09rule_type\x18\x0C \x01(\x0E2..google.cloud.workloadmanager.v1.Rule.RuleType\x12\x12\x0A\x0Aasset_type\x18\x0D \x01(\x09\"?\x0A\x08RuleType\x12\x19\x0A\x15RULE_TYPE_UNSPECIFIED\x10\x00\x12\x0C\x0A\x08BASELINE\x10\x01\x12\x0A\x0A\x06CUSTOM\x10\x02:k\xEAAh\x0A#workloadmanager.googleapis.com/Rule\x124projects/{project}/locations/{location}/rules/{rule}*\x05rules2\x04rule\"\xFD\x01\x0A\x10ListRulesRequest\x12;\x0A\x06parent\x18\x01 \x01(\x09B+\xE0A\x02\xFAA%\x12#workloadmanager.googleapis.com/Rule\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\x12\x0E\x0A\x06filter\x18\x04 \x01(\x09\x12\x1B\x0A\x13custom_rules_bucket\x18\x05 \x01(\x09\x12X\x0A\x0Fevaluation_type\x18\x06 \x01(\x0E2:.google.cloud.workloadmanager.v1.Evaluation.EvaluationTypeB\x03\xE0A\x01\"I\x0A\x11ListRulesResponse\x124\x0A\x05rules\x18\x01 \x03(\x0B2%.google.cloud.workloadmanager.v1.Rule\"\x89\x01\x0A\x1BListScannedResourcesRequest\x12\x13\x0A\x06parent\x18\x01 \x01(\x09B\x03\xE0A\x02\x12\x0C\x0A\x04rule\x18\x02 \x01(\x09\x12\x11\x0A\x09page_size\x18\x03 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x04 \x01(\x09\x12\x0E\x0A\x06filter\x18\x05 \x01(\x09\x12\x10\x0A\x08order_by\x18\x06 \x01(\x09\"\x84\x01\x0A\x1CListScannedResourcesResponse\x12K\x0A\x11scanned_resources\x18\x01 \x03(\x0B20.google.cloud.workloadmanager.v1.ScannedResource\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\"1\x0A\x0FScannedResource\x12\x10\x0A\x08resource\x18\x01 \x01(\x09\x12\x0C\x0A\x04type\x18\x02 \x01(\x092\xB5\x15\x0A\x0FWorkloadManager\x12\xC6\x01\x0A\x0FListEvaluations\x127.google.cloud.workloadmanager.v1.ListEvaluationsRequest\x1A8.google.cloud.workloadmanager.v1.ListEvaluationsResponse\"@\xDAA\x06parent\x82\xD3\xE4\x93\x021\x12//v1/{parent=projects/*/locations/*}/evaluations\x12\xB3\x01\x0A\x0DGetEvaluation\x125.google.cloud.workloadmanager.v1.GetEvaluationRequest\x1A+.google.cloud.workloadmanager.v1.Evaluation\">\xDAA\x04name\x82\xD3\xE4\x93\x021\x12//v1/{name=projects/*/locations/*/evaluations/*}\x12\xF5\x01\x0A\x10CreateEvaluation\x128.google.cloud.workloadmanager.v1.CreateEvaluationRequest\x1A\x1D.google.longrunning.Operation\"\x87\x01\xCAA\x1F\x0A\x0AEvaluation\x12\x11OperationMetadata\xDAA\x1Fparent,evaluation,evaluation_id\x82\xD3\xE4\x93\x02=\"//v1/{parent=projects/*/locations/*}/evaluations:\x0Aevaluation\x12\xF7\x01\x0A\x10UpdateEvaluation\x128.google.cloud.workloadmanager.v1.UpdateEvaluationRequest\x1A\x1D.google.longrunning.Operation\"\x89\x01\xCAA\x1F\x0A\x0AEvaluation\x12\x11OperationMetadata\xDAA\x16evaluation,update_mask\x82\xD3\xE4\x93\x02H2:/v1/{evaluation.name=projects/*/locations/*/evaluations/*}:\x0Aevaluation\x12\xD8\x01\x0A\x10DeleteEvaluation\x128.google.cloud.workloadmanager.v1.DeleteEvaluationRequest\x1A\x1D.google.longrunning.Operation\"k\xCAA*\x0A\x15google.protobuf.Empty\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x021*//v1/{name=projects/*/locations/*/evaluations/*}\x12\xD0\x01\x0A\x0EListExecutions\x126.google.cloud.workloadmanager.v1.ListExecutionsRequest\x1A7.google.cloud.workloadmanager.v1.ListExecutionsResponse\"M\xDAA\x06parent\x82\xD3\xE4\x93\x02>\x12\x12/v1/{name=projects/*/locations/*/evaluations/*}/executions:run:\x01*\x12\xE3\x01\x0A\x0FDeleteExecution\x127.google.cloud.workloadmanager.v1.DeleteExecutionRequest\x1A\x1D.google.longrunning.Operation\"x\xCAA*\x0A\x15google.protobuf.Empty\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x02>*google.cloud.workloadmanager.v1.AgentCommand + */ +class AgentCommand extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the agent one-time executable that will be invoked. + * + * Generated from protobuf field string command = 1; + */ + protected $command = ''; + /** + * A map of key/value pairs that can be used to specify + * additional one-time executable settings. + * + * Generated from protobuf field map parameters = 2; + */ + private $parameters; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $command + * The name of the agent one-time executable that will be invoked. + * @type array|\Google\Protobuf\Internal\MapField $parameters + * A map of key/value pairs that can be used to specify + * additional one-time executable settings. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * The name of the agent one-time executable that will be invoked. + * + * Generated from protobuf field string command = 1; + * @return string + */ + public function getCommand() + { + return $this->command; + } + + /** + * The name of the agent one-time executable that will be invoked. + * + * Generated from protobuf field string command = 1; + * @param string $var + * @return $this + */ + public function setCommand($var) + { + GPBUtil::checkString($var, True); + $this->command = $var; + + return $this; + } + + /** + * A map of key/value pairs that can be used to specify + * additional one-time executable settings. + * + * Generated from protobuf field map parameters = 2; + * @return \Google\Protobuf\Internal\MapField + */ + public function getParameters() + { + return $this->parameters; + } + + /** + * A map of key/value pairs that can be used to specify + * additional one-time executable settings. + * + * Generated from protobuf field map parameters = 2; + * @param array|\Google\Protobuf\Internal\MapField $var + * @return $this + */ + public function setParameters($var) + { + $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); + $this->parameters = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/BigQueryDestination.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/BigQueryDestination.php new file mode 100644 index 000000000000..0fb323100ffb --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/BigQueryDestination.php @@ -0,0 +1,105 @@ +google.cloud.workloadmanager.v1.BigQueryDestination + */ +class BigQueryDestination extends \Google\Protobuf\Internal\Message +{ + /** + * Optional. Destination dataset to save evaluation results. + * + * Generated from protobuf field string destination_dataset = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $destination_dataset = ''; + /** + * Optional. Determines if a new results table will be created when an + * Execution is created. + * + * Generated from protobuf field bool create_new_results_table = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $create_new_results_table = false; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $destination_dataset + * Optional. Destination dataset to save evaluation results. + * @type bool $create_new_results_table + * Optional. Determines if a new results table will be created when an + * Execution is created. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Optional. Destination dataset to save evaluation results. + * + * Generated from protobuf field string destination_dataset = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getDestinationDataset() + { + return $this->destination_dataset; + } + + /** + * Optional. Destination dataset to save evaluation results. + * + * Generated from protobuf field string destination_dataset = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @param string $var + * @return $this + */ + public function setDestinationDataset($var) + { + GPBUtil::checkString($var, True); + $this->destination_dataset = $var; + + return $this; + } + + /** + * Optional. Determines if a new results table will be created when an + * Execution is created. + * + * Generated from protobuf field bool create_new_results_table = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @return bool + */ + public function getCreateNewResultsTable() + { + return $this->create_new_results_table; + } + + /** + * Optional. Determines if a new results table will be created when an + * Execution is created. + * + * Generated from protobuf field bool create_new_results_table = 2 [(.google.api.field_behavior) = OPTIONAL]; + * @param bool $var + * @return $this + */ + public function setCreateNewResultsTable($var) + { + GPBUtil::checkBool($var); + $this->create_new_results_table = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Command.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Command.php new file mode 100644 index 000000000000..a50557e163fb --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Command.php @@ -0,0 +1,111 @@ +google.cloud.workloadmanager.v1.Command + */ +class Command extends \Google\Protobuf\Internal\Message +{ + protected $command_type; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\WorkloadManager\V1\AgentCommand $agent_command + * AgentCommand specifies a one-time executable program for the agent to + * run. + * @type \Google\Cloud\WorkloadManager\V1\ShellCommand $shell_command + * ShellCommand is invoked via the agent's command line executor. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * AgentCommand specifies a one-time executable program for the agent to + * run. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.AgentCommand agent_command = 1; + * @return \Google\Cloud\WorkloadManager\V1\AgentCommand|null + */ + public function getAgentCommand() + { + return $this->readOneof(1); + } + + public function hasAgentCommand() + { + return $this->hasOneof(1); + } + + /** + * AgentCommand specifies a one-time executable program for the agent to + * run. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.AgentCommand agent_command = 1; + * @param \Google\Cloud\WorkloadManager\V1\AgentCommand $var + * @return $this + */ + public function setAgentCommand($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\WorkloadManager\V1\AgentCommand::class); + $this->writeOneof(1, $var); + + return $this; + } + + /** + * ShellCommand is invoked via the agent's command line executor. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.ShellCommand shell_command = 2; + * @return \Google\Cloud\WorkloadManager\V1\ShellCommand|null + */ + public function getShellCommand() + { + return $this->readOneof(2); + } + + public function hasShellCommand() + { + return $this->hasOneof(2); + } + + /** + * ShellCommand is invoked via the agent's command line executor. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.ShellCommand shell_command = 2; + * @param \Google\Cloud\WorkloadManager\V1\ShellCommand $var + * @return $this + */ + public function setShellCommand($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\WorkloadManager\V1\ShellCommand::class); + $this->writeOneof(2, $var); + + return $this; + } + + /** + * @return string + */ + public function getCommandType() + { + return $this->whichOneof("command_type"); + } + +} + diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/CreateEvaluationRequest.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/CreateEvaluationRequest.php new file mode 100644 index 000000000000..885e93c8e5b0 --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/CreateEvaluationRequest.php @@ -0,0 +1,242 @@ +google.cloud.workloadmanager.v1.CreateEvaluationRequest + */ +class CreateEvaluationRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource prefix of the evaluation 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. Id of the requesting object. + * + * Generated from protobuf field string evaluation_id = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $evaluation_id = ''; + /** + * Required. The resource being created. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.Evaluation evaluation = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $evaluation = 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 resource prefix of the evaluation location using the form: + * `projects/{project_id}/locations/{location_id}`. Please see + * {@see WorkloadManagerClient::locationName()} for help formatting this field. + * @param \Google\Cloud\WorkloadManager\V1\Evaluation $evaluation Required. The resource being created. + * @param string $evaluationId Required. Id of the requesting object. + * + * @return \Google\Cloud\WorkloadManager\V1\CreateEvaluationRequest + * + * @experimental + */ + public static function build(string $parent, \Google\Cloud\WorkloadManager\V1\Evaluation $evaluation, string $evaluationId): self + { + return (new self()) + ->setParent($parent) + ->setEvaluation($evaluation) + ->setEvaluationId($evaluationId); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $parent + * Required. The resource prefix of the evaluation location using the form: + * `projects/{project_id}/locations/{location_id}`. + * @type string $evaluation_id + * Required. Id of the requesting object. + * @type \Google\Cloud\WorkloadManager\V1\Evaluation $evaluation + * 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 + * 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\Workloadmanager\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource prefix of the evaluation 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 prefix of the evaluation 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. Id of the requesting object. + * + * Generated from protobuf field string evaluation_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getEvaluationId() + { + return $this->evaluation_id; + } + + /** + * Required. Id of the requesting object. + * + * Generated from protobuf field string evaluation_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setEvaluationId($var) + { + GPBUtil::checkString($var, True); + $this->evaluation_id = $var; + + return $this; + } + + /** + * Required. The resource being created. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.Evaluation evaluation = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\WorkloadManager\V1\Evaluation|null + */ + public function getEvaluation() + { + return $this->evaluation; + } + + public function hasEvaluation() + { + return isset($this->evaluation); + } + + public function clearEvaluation() + { + unset($this->evaluation); + } + + /** + * Required. The resource being created. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.Evaluation evaluation = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\WorkloadManager\V1\Evaluation $var + * @return $this + */ + public function setEvaluation($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\WorkloadManager\V1\Evaluation::class); + $this->evaluation = $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/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/DeleteEvaluationRequest.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/DeleteEvaluationRequest.php new file mode 100644 index 000000000000..682f6569f1c4 --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/DeleteEvaluationRequest.php @@ -0,0 +1,193 @@ +google.cloud.workloadmanager.v1.DeleteEvaluationRequest + */ +class DeleteEvaluationRequest 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 + * 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 = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $request_id = ''; + /** + * Optional. Followed the best practice from + * https://aip.dev/135#cascading-delete. + * + * Generated from protobuf field bool force = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $force = false; + + /** + * @param string $name Required. Name of the resource. Please see + * {@see WorkloadManagerClient::evaluationName()} for help formatting this field. + * + * @return \Google\Cloud\WorkloadManager\V1\DeleteEvaluationRequest + * + * @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 + * 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 bool $force + * Optional. Followed the best practice from + * https://aip.dev/135#cascading-delete. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::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 + * 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 = 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 + * 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 = 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. Followed the best practice from + * https://aip.dev/135#cascading-delete. + * + * Generated from protobuf field bool force = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @return bool + */ + public function getForce() + { + return $this->force; + } + + /** + * Optional. Followed the best practice from + * https://aip.dev/135#cascading-delete. + * + * Generated from protobuf field bool force = 3 [(.google.api.field_behavior) = OPTIONAL]; + * @param bool $var + * @return $this + */ + public function setForce($var) + { + GPBUtil::checkBool($var); + $this->force = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/DeleteExecutionRequest.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/DeleteExecutionRequest.php new file mode 100644 index 000000000000..3f317ed1d3f6 --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/DeleteExecutionRequest.php @@ -0,0 +1,155 @@ +google.cloud.workloadmanager.v1.DeleteExecutionRequest + */ +class DeleteExecutionRequest 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 + * 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 = 2 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $request_id = ''; + + /** + * @param string $name Required. Name of the resource. Please see + * {@see WorkloadManagerClient::executionName()} for help formatting this field. + * + * @return \Google\Cloud\WorkloadManager\V1\DeleteExecutionRequest + * + * @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 + * 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\Workloadmanager\V1\Service::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 + * 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 = 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 + * 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 = 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; + } + +} + diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Evaluation.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Evaluation.php new file mode 100644 index 000000000000..aa4cd8a7ef2e --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Evaluation.php @@ -0,0 +1,597 @@ +google.cloud.workloadmanager.v1.Evaluation + */ +class Evaluation extends \Google\Protobuf\Internal\Message +{ + /** + * Name of resource that has the form + * `projects/{project_id}/locations/{location_id}/evaluations/{evaluation_id}`. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * Description of the Evaluation. + * + * Generated from protobuf field string description = 2; + */ + protected $description = ''; + /** + * Resource filter for an evaluation defining the scope of resources to be + * evaluated. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.ResourceFilter resource_filter = 3; + */ + protected $resource_filter = null; + /** + * The names of the rules used for this evaluation. + * + * Generated from protobuf field repeated string rule_names = 4; + */ + private $rule_names; + /** + * Output only. [Output only] The current lifecycle state of the evaluation + * resource. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.ResourceStatus resource_status = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $resource_status = null; + /** + * Output only. [Output only] Create time stamp. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 7 [(.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 = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $update_time = null; + /** + * Labels as key value pairs. + * + * Generated from protobuf field map labels = 9; + */ + private $labels; + /** + * Crontab format schedule for scheduled evaluation, currently only supports + * the following fixed schedules: + * * `0 {@*}1 * * *` # Hourly + * * `0 {@*}6 * * *` # Every 6 hours + * * `0 {@*}12 * * *` # Every 12 hours + * * `0 0 {@*}1 * *` # Daily + * * `0 0 {@*}7 * *` # Weekly + * * `0 0 {@*}14 * *` # Every 14 days + * * `0 0 1 {@*}1 *` # Monthly + * + * Generated from protobuf field optional string schedule = 10; + */ + protected $schedule = null; + /** + * The Cloud Storage bucket name for custom rules. + * + * Generated from protobuf field string custom_rules_bucket = 11; + */ + protected $custom_rules_bucket = ''; + /** + * Evaluation type. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.Evaluation.EvaluationType evaluation_type = 12; + */ + protected $evaluation_type = 0; + /** + * Optional. The BigQuery destination for detailed evaluation results. + * If this field is specified, the results of each evaluation execution are + * exported to BigQuery. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.BigQueryDestination big_query_destination = 13 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $big_query_destination = null; + /** + * Optional. Immutable. Customer-managed encryption key name, in the format + * projects/{@*}locations/{@*}keyRings/{@*}cryptoKeys/*. + * The key will be used for CMEK encryption of the evaluation resource. + * + * Generated from protobuf field string kms_key = 15 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { + */ + protected $kms_key = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Name of resource that has the form + * `projects/{project_id}/locations/{location_id}/evaluations/{evaluation_id}`. + * @type string $description + * Description of the Evaluation. + * @type \Google\Cloud\WorkloadManager\V1\ResourceFilter $resource_filter + * Resource filter for an evaluation defining the scope of resources to be + * evaluated. + * @type string[] $rule_names + * The names of the rules used for this evaluation. + * @type \Google\Cloud\WorkloadManager\V1\ResourceStatus $resource_status + * Output only. [Output only] The current lifecycle state of the evaluation + * resource. + * @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 array|\Google\Protobuf\Internal\MapField $labels + * Labels as key value pairs. + * @type string $schedule + * Crontab format schedule for scheduled evaluation, currently only supports + * the following fixed schedules: + * * `0 {@*}1 * * *` # Hourly + * * `0 {@*}6 * * *` # Every 6 hours + * * `0 {@*}12 * * *` # Every 12 hours + * * `0 0 {@*}1 * *` # Daily + * * `0 0 {@*}7 * *` # Weekly + * * `0 0 {@*}14 * *` # Every 14 days + * * `0 0 1 {@*}1 *` # Monthly + * @type string $custom_rules_bucket + * The Cloud Storage bucket name for custom rules. + * @type int $evaluation_type + * Evaluation type. + * @type \Google\Cloud\WorkloadManager\V1\BigQueryDestination $big_query_destination + * Optional. The BigQuery destination for detailed evaluation results. + * If this field is specified, the results of each evaluation execution are + * exported to BigQuery. + * @type string $kms_key + * Optional. Immutable. Customer-managed encryption key name, in the format + * projects/{@*}locations/{@*}keyRings/{@*}cryptoKeys/*. + * The key will be used for CMEK encryption of the evaluation resource. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Name of resource that has the form + * `projects/{project_id}/locations/{location_id}/evaluations/{evaluation_id}`. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Name of resource that has the form + * `projects/{project_id}/locations/{location_id}/evaluations/{evaluation_id}`. + * + * 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; + } + + /** + * Description of the Evaluation. + * + * Generated from protobuf field string description = 2; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * Description of the Evaluation. + * + * 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; + } + + /** + * Resource filter for an evaluation defining the scope of resources to be + * evaluated. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.ResourceFilter resource_filter = 3; + * @return \Google\Cloud\WorkloadManager\V1\ResourceFilter|null + */ + public function getResourceFilter() + { + return $this->resource_filter; + } + + public function hasResourceFilter() + { + return isset($this->resource_filter); + } + + public function clearResourceFilter() + { + unset($this->resource_filter); + } + + /** + * Resource filter for an evaluation defining the scope of resources to be + * evaluated. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.ResourceFilter resource_filter = 3; + * @param \Google\Cloud\WorkloadManager\V1\ResourceFilter $var + * @return $this + */ + public function setResourceFilter($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\WorkloadManager\V1\ResourceFilter::class); + $this->resource_filter = $var; + + return $this; + } + + /** + * The names of the rules used for this evaluation. + * + * Generated from protobuf field repeated string rule_names = 4; + * @return RepeatedField + */ + public function getRuleNames() + { + return $this->rule_names; + } + + /** + * The names of the rules used for this evaluation. + * + * Generated from protobuf field repeated string rule_names = 4; + * @param string[] $var + * @return $this + */ + public function setRuleNames($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->rule_names = $arr; + + return $this; + } + + /** + * Output only. [Output only] The current lifecycle state of the evaluation + * resource. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.ResourceStatus resource_status = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Cloud\WorkloadManager\V1\ResourceStatus|null + */ + public function getResourceStatus() + { + return $this->resource_status; + } + + public function hasResourceStatus() + { + return isset($this->resource_status); + } + + public function clearResourceStatus() + { + unset($this->resource_status); + } + + /** + * Output only. [Output only] The current lifecycle state of the evaluation + * resource. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.ResourceStatus resource_status = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Cloud\WorkloadManager\V1\ResourceStatus $var + * @return $this + */ + public function setResourceStatus($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\WorkloadManager\V1\ResourceStatus::class); + $this->resource_status = $var; + + return $this; + } + + /** + * Output only. [Output only] Create time stamp. + * + * Generated from protobuf field .google.protobuf.Timestamp create_time = 7 [(.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 = 7 [(.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 = 8 [(.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 = 8 [(.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; + } + + /** + * Labels as key value pairs. + * + * Generated from protobuf field map labels = 9; + * @return \Google\Protobuf\Internal\MapField + */ + public function getLabels() + { + return $this->labels; + } + + /** + * Labels as key value pairs. + * + * 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; + } + + /** + * Crontab format schedule for scheduled evaluation, currently only supports + * the following fixed schedules: + * * `0 {@*}1 * * *` # Hourly + * * `0 {@*}6 * * *` # Every 6 hours + * * `0 {@*}12 * * *` # Every 12 hours + * * `0 0 {@*}1 * *` # Daily + * * `0 0 {@*}7 * *` # Weekly + * * `0 0 {@*}14 * *` # Every 14 days + * * `0 0 1 {@*}1 *` # Monthly + * + * Generated from protobuf field optional string schedule = 10; + * @return string + */ + public function getSchedule() + { + return isset($this->schedule) ? $this->schedule : ''; + } + + public function hasSchedule() + { + return isset($this->schedule); + } + + public function clearSchedule() + { + unset($this->schedule); + } + + /** + * Crontab format schedule for scheduled evaluation, currently only supports + * the following fixed schedules: + * * `0 {@*}1 * * *` # Hourly + * * `0 {@*}6 * * *` # Every 6 hours + * * `0 {@*}12 * * *` # Every 12 hours + * * `0 0 {@*}1 * *` # Daily + * * `0 0 {@*}7 * *` # Weekly + * * `0 0 {@*}14 * *` # Every 14 days + * * `0 0 1 {@*}1 *` # Monthly + * + * Generated from protobuf field optional string schedule = 10; + * @param string $var + * @return $this + */ + public function setSchedule($var) + { + GPBUtil::checkString($var, True); + $this->schedule = $var; + + return $this; + } + + /** + * The Cloud Storage bucket name for custom rules. + * + * Generated from protobuf field string custom_rules_bucket = 11; + * @return string + */ + public function getCustomRulesBucket() + { + return $this->custom_rules_bucket; + } + + /** + * The Cloud Storage bucket name for custom rules. + * + * Generated from protobuf field string custom_rules_bucket = 11; + * @param string $var + * @return $this + */ + public function setCustomRulesBucket($var) + { + GPBUtil::checkString($var, True); + $this->custom_rules_bucket = $var; + + return $this; + } + + /** + * Evaluation type. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.Evaluation.EvaluationType evaluation_type = 12; + * @return int + */ + public function getEvaluationType() + { + return $this->evaluation_type; + } + + /** + * Evaluation type. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.Evaluation.EvaluationType evaluation_type = 12; + * @param int $var + * @return $this + */ + public function setEvaluationType($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\WorkloadManager\V1\Evaluation\EvaluationType::class); + $this->evaluation_type = $var; + + return $this; + } + + /** + * Optional. The BigQuery destination for detailed evaluation results. + * If this field is specified, the results of each evaluation execution are + * exported to BigQuery. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.BigQueryDestination big_query_destination = 13 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Cloud\WorkloadManager\V1\BigQueryDestination|null + */ + public function getBigQueryDestination() + { + return $this->big_query_destination; + } + + public function hasBigQueryDestination() + { + return isset($this->big_query_destination); + } + + public function clearBigQueryDestination() + { + unset($this->big_query_destination); + } + + /** + * Optional. The BigQuery destination for detailed evaluation results. + * If this field is specified, the results of each evaluation execution are + * exported to BigQuery. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.BigQueryDestination big_query_destination = 13 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\WorkloadManager\V1\BigQueryDestination $var + * @return $this + */ + public function setBigQueryDestination($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\WorkloadManager\V1\BigQueryDestination::class); + $this->big_query_destination = $var; + + return $this; + } + + /** + * Optional. Immutable. Customer-managed encryption key name, in the format + * projects/{@*}locations/{@*}keyRings/{@*}cryptoKeys/*. + * The key will be used for CMEK encryption of the evaluation resource. + * + * Generated from protobuf field string kms_key = 15 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { + * @return string + */ + public function getKmsKey() + { + return $this->kms_key; + } + + /** + * Optional. Immutable. Customer-managed encryption key name, in the format + * projects/{@*}locations/{@*}keyRings/{@*}cryptoKeys/*. + * The key will be used for CMEK encryption of the evaluation resource. + * + * Generated from protobuf field string kms_key = 15 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setKmsKey($var) + { + GPBUtil::checkString($var, True); + $this->kms_key = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Evaluation/EvaluationType.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Evaluation/EvaluationType.php new file mode 100644 index 000000000000..ca76914d92d8 --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Evaluation/EvaluationType.php @@ -0,0 +1,68 @@ +google.cloud.workloadmanager.v1.Evaluation.EvaluationType + */ +class EvaluationType +{ + /** + * Not specified. + * + * Generated from protobuf enum EVALUATION_TYPE_UNSPECIFIED = 0; + */ + const EVALUATION_TYPE_UNSPECIFIED = 0; + /** + * SAP best practices. + * + * Generated from protobuf enum SAP = 1; + */ + const SAP = 1; + /** + * SQL best practices. + * + * Generated from protobuf enum SQL_SERVER = 2; + */ + const SQL_SERVER = 2; + /** + * Customized best practices. + * + * Generated from protobuf enum OTHER = 3; + */ + const OTHER = 3; + + private static $valueToName = [ + self::EVALUATION_TYPE_UNSPECIFIED => 'EVALUATION_TYPE_UNSPECIFIED', + self::SAP => 'SAP', + self::SQL_SERVER => 'SQL_SERVER', + self::OTHER => 'OTHER', + ]; + + 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/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution.php new file mode 100644 index 000000000000..c2467cee43d2 --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution.php @@ -0,0 +1,523 @@ +google.cloud.workloadmanager.v1.Execution + */ +class Execution extends \Google\Protobuf\Internal\Message +{ + /** + * The name of execution resource. The format is + * projects/{project}/locations/{location}/evaluations/{evaluation}/executions/{execution}. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * Output only. [Output only] Start time stamp. + * + * Generated from protobuf field .google.protobuf.Timestamp start_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $start_time = null; + /** + * Output only. [Output only] End time stamp. + * + * Generated from protobuf field .google.protobuf.Timestamp end_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $end_time = null; + /** + * Output only. [Output only] Inventory time stamp. + * + * Generated from protobuf field .google.protobuf.Timestamp inventory_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $inventory_time = null; + /** + * Output only. [Output only] State. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.Execution.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $state = 0; + /** + * Output only. [Output only] Evaluation ID. + * + * Generated from protobuf field string evaluation_id = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $evaluation_id = ''; + /** + * Labels as key value pairs. + * + * Generated from protobuf field map labels = 7; + */ + private $labels; + /** + * Type which represents whether the execution executed directly by user or + * scheduled according to the `Evaluation.schedule` field. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.Execution.Type run_type = 8; + */ + protected $run_type = 0; + /** + * Output only. Execution result summary per rule. + * + * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.RuleExecutionResult rule_results = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + private $rule_results; + /** + * Optional. External data sources. + * + * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.Execution.ExternalDataSources external_data_sources = 10 [(.google.api.field_behavior) = OPTIONAL]; + */ + private $external_data_sources; + /** + * Output only. Additional information generated by the execution. + * + * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.Execution.Notice notices = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + private $notices; + /** + * Optional. Engine. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.Execution.Engine engine = 12 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $engine = 0; + /** + * Output only. [Output only] Result summary for the execution. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.Execution.Summary result_summary = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $result_summary = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * The name of execution resource. The format is + * projects/{project}/locations/{location}/evaluations/{evaluation}/executions/{execution}. + * @type \Google\Protobuf\Timestamp $start_time + * Output only. [Output only] Start time stamp. + * @type \Google\Protobuf\Timestamp $end_time + * Output only. [Output only] End time stamp. + * @type \Google\Protobuf\Timestamp $inventory_time + * Output only. [Output only] Inventory time stamp. + * @type int $state + * Output only. [Output only] State. + * @type string $evaluation_id + * Output only. [Output only] Evaluation ID. + * @type array|\Google\Protobuf\Internal\MapField $labels + * Labels as key value pairs. + * @type int $run_type + * Type which represents whether the execution executed directly by user or + * scheduled according to the `Evaluation.schedule` field. + * @type \Google\Cloud\WorkloadManager\V1\RuleExecutionResult[] $rule_results + * Output only. Execution result summary per rule. + * @type \Google\Cloud\WorkloadManager\V1\Execution\ExternalDataSources[] $external_data_sources + * Optional. External data sources. + * @type \Google\Cloud\WorkloadManager\V1\Execution\Notice[] $notices + * Output only. Additional information generated by the execution. + * @type int $engine + * Optional. Engine. + * @type \Google\Cloud\WorkloadManager\V1\Execution\Summary $result_summary + * Output only. [Output only] Result summary for the execution. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * The name of execution resource. The format is + * projects/{project}/locations/{location}/evaluations/{evaluation}/executions/{execution}. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The name of execution resource. The format is + * projects/{project}/locations/{location}/evaluations/{evaluation}/executions/{execution}. + * + * 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. [Output only] Start time stamp. + * + * Generated from protobuf field .google.protobuf.Timestamp start_time = 2 [(.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. [Output only] Start time stamp. + * + * Generated from protobuf field .google.protobuf.Timestamp start_time = 2 [(.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. [Output only] End time stamp. + * + * Generated from protobuf field .google.protobuf.Timestamp end_time = 3 [(.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. [Output only] End time stamp. + * + * Generated from protobuf field .google.protobuf.Timestamp end_time = 3 [(.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. [Output only] Inventory time stamp. + * + * Generated from protobuf field .google.protobuf.Timestamp inventory_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Protobuf\Timestamp|null + */ + public function getInventoryTime() + { + return $this->inventory_time; + } + + public function hasInventoryTime() + { + return isset($this->inventory_time); + } + + public function clearInventoryTime() + { + unset($this->inventory_time); + } + + /** + * Output only. [Output only] Inventory time stamp. + * + * Generated from protobuf field .google.protobuf.Timestamp inventory_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Protobuf\Timestamp $var + * @return $this + */ + public function setInventoryTime($var) + { + GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); + $this->inventory_time = $var; + + return $this; + } + + /** + * Output only. [Output only] State. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.Execution.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getState() + { + return $this->state; + } + + /** + * Output only. [Output only] State. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.Execution.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setState($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\WorkloadManager\V1\Execution\State::class); + $this->state = $var; + + return $this; + } + + /** + * Output only. [Output only] Evaluation ID. + * + * Generated from protobuf field string evaluation_id = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getEvaluationId() + { + return $this->evaluation_id; + } + + /** + * Output only. [Output only] Evaluation ID. + * + * Generated from protobuf field string evaluation_id = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setEvaluationId($var) + { + GPBUtil::checkString($var, True); + $this->evaluation_id = $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; + } + + /** + * Type which represents whether the execution executed directly by user or + * scheduled according to the `Evaluation.schedule` field. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.Execution.Type run_type = 8; + * @return int + */ + public function getRunType() + { + return $this->run_type; + } + + /** + * Type which represents whether the execution executed directly by user or + * scheduled according to the `Evaluation.schedule` field. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.Execution.Type run_type = 8; + * @param int $var + * @return $this + */ + public function setRunType($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\WorkloadManager\V1\Execution\Type::class); + $this->run_type = $var; + + return $this; + } + + /** + * Output only. Execution result summary per rule. + * + * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.RuleExecutionResult rule_results = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return RepeatedField<\Google\Cloud\WorkloadManager\V1\RuleExecutionResult> + */ + public function getRuleResults() + { + return $this->rule_results; + } + + /** + * Output only. Execution result summary per rule. + * + * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.RuleExecutionResult rule_results = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Cloud\WorkloadManager\V1\RuleExecutionResult[] $var + * @return $this + */ + public function setRuleResults($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\WorkloadManager\V1\RuleExecutionResult::class); + $this->rule_results = $arr; + + return $this; + } + + /** + * Optional. External data sources. + * + * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.Execution.ExternalDataSources external_data_sources = 10 [(.google.api.field_behavior) = OPTIONAL]; + * @return RepeatedField<\Google\Cloud\WorkloadManager\V1\Execution\ExternalDataSources> + */ + public function getExternalDataSources() + { + return $this->external_data_sources; + } + + /** + * Optional. External data sources. + * + * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.Execution.ExternalDataSources external_data_sources = 10 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Cloud\WorkloadManager\V1\Execution\ExternalDataSources[] $var + * @return $this + */ + public function setExternalDataSources($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\WorkloadManager\V1\Execution\ExternalDataSources::class); + $this->external_data_sources = $arr; + + return $this; + } + + /** + * Output only. Additional information generated by the execution. + * + * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.Execution.Notice notices = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return RepeatedField<\Google\Cloud\WorkloadManager\V1\Execution\Notice> + */ + public function getNotices() + { + return $this->notices; + } + + /** + * Output only. Additional information generated by the execution. + * + * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.Execution.Notice notices = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Cloud\WorkloadManager\V1\Execution\Notice[] $var + * @return $this + */ + public function setNotices($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\WorkloadManager\V1\Execution\Notice::class); + $this->notices = $arr; + + return $this; + } + + /** + * Optional. Engine. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.Execution.Engine engine = 12 [(.google.api.field_behavior) = OPTIONAL]; + * @return int + */ + public function getEngine() + { + return $this->engine; + } + + /** + * Optional. Engine. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.Execution.Engine engine = 12 [(.google.api.field_behavior) = OPTIONAL]; + * @param int $var + * @return $this + */ + public function setEngine($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\WorkloadManager\V1\Execution\Engine::class); + $this->engine = $var; + + return $this; + } + + /** + * Output only. [Output only] Result summary for the execution. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.Execution.Summary result_summary = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Cloud\WorkloadManager\V1\Execution\Summary|null + */ + public function getResultSummary() + { + return $this->result_summary; + } + + public function hasResultSummary() + { + return isset($this->result_summary); + } + + public function clearResultSummary() + { + unset($this->result_summary); + } + + /** + * Output only. [Output only] Result summary for the execution. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.Execution.Summary result_summary = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Cloud\WorkloadManager\V1\Execution\Summary $var + * @return $this + */ + public function setResultSummary($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\WorkloadManager\V1\Execution\Summary::class); + $this->result_summary = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/Engine.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/Engine.php new file mode 100644 index 000000000000..2eab2de77522 --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/Engine.php @@ -0,0 +1,61 @@ +google.cloud.workloadmanager.v1.Execution.Engine + */ +class Engine +{ + /** + * The original CG. + * + * Generated from protobuf enum ENGINE_UNSPECIFIED = 0; + */ + const ENGINE_UNSPECIFIED = 0; + /** + * SlimCG / Scanner. + * + * Generated from protobuf enum ENGINE_SCANNER = 1; + */ + const ENGINE_SCANNER = 1; + /** + * Evaluation Engine V2. + * + * Generated from protobuf enum V2 = 2; + */ + const V2 = 2; + + private static $valueToName = [ + self::ENGINE_UNSPECIFIED => 'ENGINE_UNSPECIFIED', + self::ENGINE_SCANNER => 'ENGINE_SCANNER', + self::V2 => 'V2', + ]; + + 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/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/ExternalDataSources.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/ExternalDataSources.php new file mode 100644 index 000000000000..2b3a52e447d9 --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/ExternalDataSources.php @@ -0,0 +1,193 @@ +google.cloud.workloadmanager.v1.Execution.ExternalDataSources + */ +class ExternalDataSources extends \Google\Protobuf\Internal\Message +{ + /** + * Optional. Name of external data source. The name will be used inside the + * rego/sql to refer the external data. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $name = ''; + /** + * Required. URI of external data source. example of bq table + * {project_ID}.{dataset_ID}.{table_ID}. + * + * Generated from protobuf field string uri = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $uri = ''; + /** + * Required. Type of external data source. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.Execution.ExternalDataSources.Type type = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $type = 0; + /** + * Required. The asset type of the external data source. + * This can be a supported Cloud Asset Inventory asset type + * (see https://cloud.google.com/asset-inventory/docs/supported-asset-types) + * to override the default asset type, or it can be a custom type defined by + * the user. + * + * Generated from protobuf field string asset_type = 4 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $asset_type = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Optional. Name of external data source. The name will be used inside the + * rego/sql to refer the external data. + * @type string $uri + * Required. URI of external data source. example of bq table + * {project_ID}.{dataset_ID}.{table_ID}. + * @type int $type + * Required. Type of external data source. + * @type string $asset_type + * Required. The asset type of the external data source. + * This can be a supported Cloud Asset Inventory asset type + * (see https://cloud.google.com/asset-inventory/docs/supported-asset-types) + * to override the default asset type, or it can be a custom type defined by + * the user. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Optional. Name of external data source. The name will be used inside the + * rego/sql to refer the external data. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OPTIONAL]; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Optional. Name of external data source. The name will be used inside the + * rego/sql to refer the external data. + * + * 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; + } + + /** + * Required. URI of external data source. example of bq table + * {project_ID}.{dataset_ID}.{table_ID}. + * + * Generated from protobuf field string uri = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getUri() + { + return $this->uri; + } + + /** + * Required. URI of external data source. example of bq table + * {project_ID}.{dataset_ID}.{table_ID}. + * + * Generated from protobuf field string uri = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setUri($var) + { + GPBUtil::checkString($var, True); + $this->uri = $var; + + return $this; + } + + /** + * Required. Type of external data source. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.Execution.ExternalDataSources.Type type = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return int + */ + public function getType() + { + return $this->type; + } + + /** + * Required. Type of external data source. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.Execution.ExternalDataSources.Type type = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param int $var + * @return $this + */ + public function setType($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\WorkloadManager\V1\Execution\ExternalDataSources\Type::class); + $this->type = $var; + + return $this; + } + + /** + * Required. The asset type of the external data source. + * This can be a supported Cloud Asset Inventory asset type + * (see https://cloud.google.com/asset-inventory/docs/supported-asset-types) + * to override the default asset type, or it can be a custom type defined by + * the user. + * + * Generated from protobuf field string asset_type = 4 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getAssetType() + { + return $this->asset_type; + } + + /** + * Required. The asset type of the external data source. + * This can be a supported Cloud Asset Inventory asset type + * (see https://cloud.google.com/asset-inventory/docs/supported-asset-types) + * to override the default asset type, or it can be a custom type defined by + * the user. + * + * Generated from protobuf field string asset_type = 4 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setAssetType($var) + { + GPBUtil::checkString($var, True); + $this->asset_type = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/ExternalDataSources/Type.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/ExternalDataSources/Type.php new file mode 100644 index 000000000000..ace783f4dc23 --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/ExternalDataSources/Type.php @@ -0,0 +1,54 @@ +google.cloud.workloadmanager.v1.Execution.ExternalDataSources.Type + */ +class Type +{ + /** + * Unknown type. + * + * Generated from protobuf enum TYPE_UNSPECIFIED = 0; + */ + const TYPE_UNSPECIFIED = 0; + /** + * BigQuery table. + * + * Generated from protobuf enum BIG_QUERY_TABLE = 1; + */ + const BIG_QUERY_TABLE = 1; + + private static $valueToName = [ + self::TYPE_UNSPECIFIED => 'TYPE_UNSPECIFIED', + self::BIG_QUERY_TABLE => 'BIG_QUERY_TABLE', + ]; + + 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/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/Notice.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/Notice.php new file mode 100644 index 000000000000..5714c4d9904d --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/Notice.php @@ -0,0 +1,67 @@ +google.cloud.workloadmanager.v1.Execution.Notice + */ +class Notice extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. Message of the notice. + * + * Generated from protobuf field string message = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $message = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $message + * Output only. Message of the notice. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Output only. Message of the notice. + * + * Generated from protobuf field string message = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getMessage() + { + return $this->message; + } + + /** + * Output only. Message of the notice. + * + * Generated from protobuf field string message = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param string $var + * @return $this + */ + public function setMessage($var) + { + GPBUtil::checkString($var, True); + $this->message = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/State.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/State.php new file mode 100644 index 000000000000..dee6c46c0034 --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/State.php @@ -0,0 +1,68 @@ +google.cloud.workloadmanager.v1.Execution.State + */ +class State +{ + /** + * State of execution is unspecified. + * + * Generated from protobuf enum STATE_UNSPECIFIED = 0; + */ + const STATE_UNSPECIFIED = 0; + /** + * The execution is running in backend service. + * + * Generated from protobuf enum RUNNING = 1; + */ + const RUNNING = 1; + /** + * The execution run succeeded. + * + * Generated from protobuf enum SUCCEEDED = 2; + */ + const SUCCEEDED = 2; + /** + * The execution run failed. + * + * Generated from protobuf enum FAILED = 3; + */ + const FAILED = 3; + + private static $valueToName = [ + self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', + 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); + } +} + diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/Summary.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/Summary.php new file mode 100644 index 000000000000..213268e904d6 --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/Summary.php @@ -0,0 +1,135 @@ +google.cloud.workloadmanager.v1.Execution.Summary + */ +class Summary extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. Number of failures. + * + * Generated from protobuf field int64 failures = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $failures = 0; + /** + * Output only. Number of new failures compared to the previous execution. + * + * Generated from protobuf field int64 new_failures = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $new_failures = 0; + /** + * Output only. Number of new fixes compared to the previous execution. + * + * Generated from protobuf field int64 new_fixes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $new_fixes = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int|string $failures + * Output only. Number of failures. + * @type int|string $new_failures + * Output only. Number of new failures compared to the previous execution. + * @type int|string $new_fixes + * Output only. Number of new fixes compared to the previous execution. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Output only. Number of failures. + * + * Generated from protobuf field int64 failures = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int|string + */ + public function getFailures() + { + return $this->failures; + } + + /** + * Output only. Number of failures. + * + * Generated from protobuf field int64 failures = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int|string $var + * @return $this + */ + public function setFailures($var) + { + GPBUtil::checkInt64($var); + $this->failures = $var; + + return $this; + } + + /** + * Output only. Number of new failures compared to the previous execution. + * + * Generated from protobuf field int64 new_failures = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int|string + */ + public function getNewFailures() + { + return $this->new_failures; + } + + /** + * Output only. Number of new failures compared to the previous execution. + * + * Generated from protobuf field int64 new_failures = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int|string $var + * @return $this + */ + public function setNewFailures($var) + { + GPBUtil::checkInt64($var); + $this->new_failures = $var; + + return $this; + } + + /** + * Output only. Number of new fixes compared to the previous execution. + * + * Generated from protobuf field int64 new_fixes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int|string + */ + public function getNewFixes() + { + return $this->new_fixes; + } + + /** + * Output only. Number of new fixes compared to the previous execution. + * + * Generated from protobuf field int64 new_fixes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int|string $var + * @return $this + */ + public function setNewFixes($var) + { + GPBUtil::checkInt64($var); + $this->new_fixes = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/Type.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/Type.php new file mode 100644 index 000000000000..441034593b4a --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/Type.php @@ -0,0 +1,61 @@ +google.cloud.workloadmanager.v1.Execution.Type + */ +class Type +{ + /** + * Type of execution is unspecified. + * + * Generated from protobuf enum TYPE_UNSPECIFIED = 0; + */ + const TYPE_UNSPECIFIED = 0; + /** + * Type of execution is one time. + * + * Generated from protobuf enum ONE_TIME = 1; + */ + const ONE_TIME = 1; + /** + * Type of execution is scheduled. + * + * Generated from protobuf enum SCHEDULED = 2; + */ + const SCHEDULED = 2; + + private static $valueToName = [ + self::TYPE_UNSPECIFIED => 'TYPE_UNSPECIFIED', + self::ONE_TIME => 'ONE_TIME', + self::SCHEDULED => 'SCHEDULED', + ]; + + 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/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ExecutionResult.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ExecutionResult.php new file mode 100644 index 000000000000..324b3ebd2a4f --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ExecutionResult.php @@ -0,0 +1,325 @@ +google.cloud.workloadmanager.v1.ExecutionResult + */ +class ExecutionResult extends \Google\Protobuf\Internal\Message +{ + /** + * The violation message of an execution. + * + * Generated from protobuf field string violation_message = 1; + */ + protected $violation_message = ''; + /** + * The severity of violation. + * + * Generated from protobuf field string severity = 2; + */ + protected $severity = ''; + /** + * The rule that is violated in an evaluation. + * + * Generated from protobuf field string rule = 3 [(.google.api.resource_reference) = { + */ + protected $rule = ''; + /** + * The URL for the documentation of the rule. + * + * Generated from protobuf field string documentation_url = 4; + */ + protected $documentation_url = ''; + /** + * The resource that violates the rule. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.Resource resource = 5; + */ + protected $resource = null; + /** + * The details of violation in an evaluation result. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.ViolationDetails violation_details = 6; + */ + protected $violation_details = null; + /** + * The commands to remediate the violation. + * + * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.Command commands = 7; + */ + private $commands; + /** + * Execution result type of the scanned resource. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.ExecutionResult.Type type = 8; + */ + protected $type = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $violation_message + * The violation message of an execution. + * @type string $severity + * The severity of violation. + * @type string $rule + * The rule that is violated in an evaluation. + * @type string $documentation_url + * The URL for the documentation of the rule. + * @type \Google\Cloud\WorkloadManager\V1\Resource $resource + * The resource that violates the rule. + * @type \Google\Cloud\WorkloadManager\V1\ViolationDetails $violation_details + * The details of violation in an evaluation result. + * @type \Google\Cloud\WorkloadManager\V1\Command[] $commands + * The commands to remediate the violation. + * @type int $type + * Execution result type of the scanned resource. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * The violation message of an execution. + * + * Generated from protobuf field string violation_message = 1; + * @return string + */ + public function getViolationMessage() + { + return $this->violation_message; + } + + /** + * The violation message of an execution. + * + * Generated from protobuf field string violation_message = 1; + * @param string $var + * @return $this + */ + public function setViolationMessage($var) + { + GPBUtil::checkString($var, True); + $this->violation_message = $var; + + return $this; + } + + /** + * The severity of violation. + * + * Generated from protobuf field string severity = 2; + * @return string + */ + public function getSeverity() + { + return $this->severity; + } + + /** + * The severity of violation. + * + * Generated from protobuf field string severity = 2; + * @param string $var + * @return $this + */ + public function setSeverity($var) + { + GPBUtil::checkString($var, True); + $this->severity = $var; + + return $this; + } + + /** + * The rule that is violated in an evaluation. + * + * Generated from protobuf field string rule = 3 [(.google.api.resource_reference) = { + * @return string + */ + public function getRule() + { + return $this->rule; + } + + /** + * The rule that is violated in an evaluation. + * + * Generated from protobuf field string rule = 3 [(.google.api.resource_reference) = { + * @param string $var + * @return $this + */ + public function setRule($var) + { + GPBUtil::checkString($var, True); + $this->rule = $var; + + return $this; + } + + /** + * The URL for the documentation of the rule. + * + * Generated from protobuf field string documentation_url = 4; + * @return string + */ + public function getDocumentationUrl() + { + return $this->documentation_url; + } + + /** + * The URL for the documentation of the rule. + * + * Generated from protobuf field string documentation_url = 4; + * @param string $var + * @return $this + */ + public function setDocumentationUrl($var) + { + GPBUtil::checkString($var, True); + $this->documentation_url = $var; + + return $this; + } + + /** + * The resource that violates the rule. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.Resource resource = 5; + * @return \Google\Cloud\WorkloadManager\V1\Resource|null + */ + public function getResource() + { + return $this->resource; + } + + public function hasResource() + { + return isset($this->resource); + } + + public function clearResource() + { + unset($this->resource); + } + + /** + * The resource that violates the rule. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.Resource resource = 5; + * @param \Google\Cloud\WorkloadManager\V1\Resource $var + * @return $this + */ + public function setResource($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\WorkloadManager\V1\Resource::class); + $this->resource = $var; + + return $this; + } + + /** + * The details of violation in an evaluation result. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.ViolationDetails violation_details = 6; + * @return \Google\Cloud\WorkloadManager\V1\ViolationDetails|null + */ + public function getViolationDetails() + { + return $this->violation_details; + } + + public function hasViolationDetails() + { + return isset($this->violation_details); + } + + public function clearViolationDetails() + { + unset($this->violation_details); + } + + /** + * The details of violation in an evaluation result. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.ViolationDetails violation_details = 6; + * @param \Google\Cloud\WorkloadManager\V1\ViolationDetails $var + * @return $this + */ + public function setViolationDetails($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\WorkloadManager\V1\ViolationDetails::class); + $this->violation_details = $var; + + return $this; + } + + /** + * The commands to remediate the violation. + * + * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.Command commands = 7; + * @return RepeatedField<\Google\Cloud\WorkloadManager\V1\Command> + */ + public function getCommands() + { + return $this->commands; + } + + /** + * The commands to remediate the violation. + * + * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.Command commands = 7; + * @param \Google\Cloud\WorkloadManager\V1\Command[] $var + * @return $this + */ + public function setCommands($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\WorkloadManager\V1\Command::class); + $this->commands = $arr; + + return $this; + } + + /** + * Execution result type of the scanned resource. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.ExecutionResult.Type type = 8; + * @return int + */ + public function getType() + { + return $this->type; + } + + /** + * Execution result type of the scanned resource. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.ExecutionResult.Type type = 8; + * @param int $var + * @return $this + */ + public function setType($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\WorkloadManager\V1\ExecutionResult\Type::class); + $this->type = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ExecutionResult/Type.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ExecutionResult/Type.php new file mode 100644 index 000000000000..4b283dbbaa32 --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ExecutionResult/Type.php @@ -0,0 +1,61 @@ +google.cloud.workloadmanager.v1.ExecutionResult.Type + */ +class Type +{ + /** + * Unknown state. + * + * Generated from protobuf enum TYPE_UNSPECIFIED = 0; + */ + const TYPE_UNSPECIFIED = 0; + /** + * Resource successfully passed the rule. + * + * Generated from protobuf enum TYPE_PASSED = 1; + */ + const TYPE_PASSED = 1; + /** + * Resource violated the rule. + * + * Generated from protobuf enum TYPE_VIOLATED = 2; + */ + const TYPE_VIOLATED = 2; + + private static $valueToName = [ + self::TYPE_UNSPECIFIED => 'TYPE_UNSPECIFIED', + self::TYPE_PASSED => 'TYPE_PASSED', + self::TYPE_VIOLATED => 'TYPE_VIOLATED', + ]; + + 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/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/GceInstanceFilter.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/GceInstanceFilter.php new file mode 100644 index 000000000000..9b64151a16a0 --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/GceInstanceFilter.php @@ -0,0 +1,71 @@ +google.cloud.workloadmanager.v1.GceInstanceFilter + */ +class GceInstanceFilter extends \Google\Protobuf\Internal\Message +{ + /** + * If non-empty, only Compute Engine instances associated with at least one of + * the provided service accounts will be included in the evaluation. + * + * Generated from protobuf field repeated string service_accounts = 4; + */ + private $service_accounts; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string[] $service_accounts + * If non-empty, only Compute Engine instances associated with at least one of + * the provided service accounts will be included in the evaluation. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * If non-empty, only Compute Engine instances associated with at least one of + * the provided service accounts will be included in the evaluation. + * + * Generated from protobuf field repeated string service_accounts = 4; + * @return RepeatedField + */ + public function getServiceAccounts() + { + return $this->service_accounts; + } + + /** + * If non-empty, only Compute Engine instances associated with at least one of + * the provided service accounts will be included in the evaluation. + * + * Generated from protobuf field repeated string service_accounts = 4; + * @param string[] $var + * @return $this + */ + public function setServiceAccounts($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->service_accounts = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/GetEvaluationRequest.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/GetEvaluationRequest.php new file mode 100644 index 000000000000..b75aba40adb4 --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/GetEvaluationRequest.php @@ -0,0 +1,81 @@ +google.cloud.workloadmanager.v1.GetEvaluationRequest + */ +class GetEvaluationRequest 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 WorkloadManagerClient::evaluationName()} for help formatting this field. + * + * @return \Google\Cloud\WorkloadManager\V1\GetEvaluationRequest + * + * @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\Workloadmanager\V1\Service::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/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/GetExecutionRequest.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/GetExecutionRequest.php new file mode 100644 index 000000000000..6226a78e28bd --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/GetExecutionRequest.php @@ -0,0 +1,81 @@ +google.cloud.workloadmanager.v1.GetExecutionRequest + */ +class GetExecutionRequest 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 WorkloadManagerClient::executionName()} for help formatting this field. + * + * @return \Google\Cloud\WorkloadManager\V1\GetExecutionRequest + * + * @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\Workloadmanager\V1\Service::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/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListEvaluationsRequest.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListEvaluationsRequest.php new file mode 100644 index 000000000000..6c84965635f1 --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListEvaluationsRequest.php @@ -0,0 +1,221 @@ +google.cloud.workloadmanager.v1.ListEvaluationsRequest + */ +class ListEvaluationsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Parent value for ListEvaluationsRequest. + * + * 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, 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 the server should return. + * + * Generated from protobuf field string page_token = 3; + */ + protected $page_token = ''; + /** + * Filter to be applied when listing the evaluation results. + * + * Generated from protobuf field string filter = 4; + */ + protected $filter = ''; + /** + * Hint for how to order the results. + * + * Generated from protobuf field string order_by = 5; + */ + protected $order_by = ''; + + /** + * @param string $parent Required. Parent value for ListEvaluationsRequest. Please see + * {@see WorkloadManagerClient::locationName()} for help formatting this field. + * + * @return \Google\Cloud\WorkloadManager\V1\ListEvaluationsRequest + * + * @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 ListEvaluationsRequest. + * @type int $page_size + * Requested page size. Server may return fewer items than requested. + * If unspecified, server will pick an appropriate default. + * @type string $page_token + * A token identifying a page of results the server should return. + * @type string $filter + * Filter to be applied when listing the evaluation results. + * @type string $order_by + * Hint for how to order the results. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Required. Parent value for ListEvaluationsRequest. + * + * 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 ListEvaluationsRequest. + * + * 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, 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, 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 the server should return. + * + * Generated from protobuf field string page_token = 3; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * A token identifying a page of results the server should return. + * + * 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 to be applied when listing the evaluation results. + * + * Generated from protobuf field string filter = 4; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * Filter to be applied when listing the evaluation results. + * + * 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; + } + + /** + * Hint for how to order the results. + * + * Generated from protobuf field string order_by = 5; + * @return string + */ + public function getOrderBy() + { + return $this->order_by; + } + + /** + * Hint for how to order the results. + * + * 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/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListEvaluationsResponse.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListEvaluationsResponse.php new file mode 100644 index 000000000000..9c6d566611ec --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListEvaluationsResponse.php @@ -0,0 +1,135 @@ +google.cloud.workloadmanager.v1.ListEvaluationsResponse + */ +class ListEvaluationsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * The list of evaluations. + * + * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.Evaluation evaluations = 1; + */ + private $evaluations; + /** + * 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 \Google\Cloud\WorkloadManager\V1\Evaluation[] $evaluations + * The list of evaluations. + * @type string $next_page_token + * A token identifying a page of results the server should return. + * @type string[] $unreachable + * Locations that could not be reached. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * The list of evaluations. + * + * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.Evaluation evaluations = 1; + * @return RepeatedField<\Google\Cloud\WorkloadManager\V1\Evaluation> + */ + public function getEvaluations() + { + return $this->evaluations; + } + + /** + * The list of evaluations. + * + * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.Evaluation evaluations = 1; + * @param \Google\Cloud\WorkloadManager\V1\Evaluation[] $var + * @return $this + */ + public function setEvaluations($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\WorkloadManager\V1\Evaluation::class); + $this->evaluations = $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 RepeatedField + */ + public function getUnreachable() + { + return $this->unreachable; + } + + /** + * Locations that could not be reached. + * + * Generated from protobuf field repeated string unreachable = 3; + * @param string[] $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/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListExecutionResultsRequest.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListExecutionResultsRequest.php new file mode 100644 index 000000000000..79ae90c7eea2 --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListExecutionResultsRequest.php @@ -0,0 +1,191 @@ +google.cloud.workloadmanager.v1.ListExecutionResultsRequest + */ +class ListExecutionResultsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The execution results. + * Format: {parent}/evaluations/{@*}executions/{@*}results. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $parent = ''; + /** + * 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; + */ + protected $page_size = 0; + /** + * A token identifying a page of results the server should return. + * + * Generated from protobuf field string page_token = 3; + */ + protected $page_token = ''; + /** + * Filtering results. + * + * Generated from protobuf field string filter = 4; + */ + protected $filter = ''; + + /** + * @param string $parent Required. The execution results. + * Format: {parent}/evaluations/*/executions/*/results. + * + * @return \Google\Cloud\WorkloadManager\V1\ListExecutionResultsRequest + * + * @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 execution results. + * Format: {parent}/evaluations/{@*}executions/{@*}results. + * @type int $page_size + * Requested page size. Server may return fewer items than requested. + * If unspecified, server will pick an appropriate default. + * @type string $page_token + * A token identifying a page of results the server should return. + * @type string $filter + * Filtering results. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Required. The execution results. + * Format: {parent}/evaluations/{@*}executions/{@*}results. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. The execution results. + * Format: {parent}/evaluations/{@*}executions/{@*}results. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED]; + * @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, 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, 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 the server should return. + * + * Generated from protobuf field string page_token = 3; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * A token identifying a page of results the server should return. + * + * 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; + } + + /** + * Filtering results. + * + * Generated from protobuf field string filter = 4; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * Filtering results. + * + * 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/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListExecutionResultsResponse.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListExecutionResultsResponse.php new file mode 100644 index 000000000000..6b22e73de5f7 --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListExecutionResultsResponse.php @@ -0,0 +1,105 @@ +google.cloud.workloadmanager.v1.ListExecutionResultsResponse + */ +class ListExecutionResultsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * The versions from the specified publisher. + * + * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.ExecutionResult execution_results = 1; + */ + private $execution_results; + /** + * 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 \Google\Cloud\WorkloadManager\V1\ExecutionResult[] $execution_results + * 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\Workloadmanager\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * The versions from the specified publisher. + * + * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.ExecutionResult execution_results = 1; + * @return RepeatedField<\Google\Cloud\WorkloadManager\V1\ExecutionResult> + */ + public function getExecutionResults() + { + return $this->execution_results; + } + + /** + * The versions from the specified publisher. + * + * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.ExecutionResult execution_results = 1; + * @param \Google\Cloud\WorkloadManager\V1\ExecutionResult[] $var + * @return $this + */ + public function setExecutionResults($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\WorkloadManager\V1\ExecutionResult::class); + $this->execution_results = $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/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListExecutionsRequest.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListExecutionsRequest.php new file mode 100644 index 000000000000..d23e4813582c --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListExecutionsRequest.php @@ -0,0 +1,226 @@ +google.cloud.workloadmanager.v1.ListExecutionsRequest + */ +class ListExecutionsRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource prefix of the Execution using the form: + * `projects/{project}/locations/{location}/evaluations/{evaluation}`. + * + * 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, 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 the server should return. + * + * Generated from protobuf field string page_token = 3; + */ + protected $page_token = ''; + /** + * Filtering results. + * + * Generated from protobuf field string filter = 4; + */ + protected $filter = ''; + /** + * Field to sort by. See https://google.aip.dev/132#ordering for more details. + * + * Generated from protobuf field string order_by = 5; + */ + protected $order_by = ''; + + /** + * @param string $parent Required. The resource prefix of the Execution using the form: + * `projects/{project}/locations/{location}/evaluations/{evaluation}`. Please see + * {@see WorkloadManagerClient::evaluationName()} for help formatting this field. + * + * @return \Google\Cloud\WorkloadManager\V1\ListExecutionsRequest + * + * @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 prefix of the Execution using the form: + * `projects/{project}/locations/{location}/evaluations/{evaluation}`. + * @type int $page_size + * Requested page size. Server may return fewer items than requested. + * If unspecified, server will pick an appropriate default. + * @type string $page_token + * A token identifying a page of results the server should return. + * @type string $filter + * Filtering results. + * @type string $order_by + * Field to sort by. See https://google.aip.dev/132#ordering for more details. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource prefix of the Execution using the form: + * `projects/{project}/locations/{location}/evaluations/{evaluation}`. + * + * 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 prefix of the Execution using the form: + * `projects/{project}/locations/{location}/evaluations/{evaluation}`. + * + * 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, 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, 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 the server should return. + * + * Generated from protobuf field string page_token = 3; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * A token identifying a page of results the server should return. + * + * 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; + } + + /** + * Filtering results. + * + * Generated from protobuf field string filter = 4; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * Filtering results. + * + * 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; + } + + /** + * Field to sort by. See https://google.aip.dev/132#ordering for more details. + * + * Generated from protobuf field string order_by = 5; + * @return string + */ + public function getOrderBy() + { + return $this->order_by; + } + + /** + * Field to sort by. See https://google.aip.dev/132#ordering for more details. + * + * 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/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListExecutionsResponse.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListExecutionsResponse.php new file mode 100644 index 000000000000..6d130e8d3886 --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListExecutionsResponse.php @@ -0,0 +1,135 @@ +google.cloud.workloadmanager.v1.ListExecutionsResponse + */ +class ListExecutionsResponse extends \Google\Protobuf\Internal\Message +{ + /** + * The list of Execution. + * + * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.Execution executions = 1; + */ + private $executions; + /** + * 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 \Google\Cloud\WorkloadManager\V1\Execution[] $executions + * The list of Execution. + * @type string $next_page_token + * A token identifying a page of results the server should return. + * @type string[] $unreachable + * Locations that could not be reached. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * The list of Execution. + * + * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.Execution executions = 1; + * @return RepeatedField<\Google\Cloud\WorkloadManager\V1\Execution> + */ + public function getExecutions() + { + return $this->executions; + } + + /** + * The list of Execution. + * + * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.Execution executions = 1; + * @param \Google\Cloud\WorkloadManager\V1\Execution[] $var + * @return $this + */ + public function setExecutions($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\WorkloadManager\V1\Execution::class); + $this->executions = $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 RepeatedField + */ + public function getUnreachable() + { + return $this->unreachable; + } + + /** + * Locations that could not be reached. + * + * Generated from protobuf field repeated string unreachable = 3; + * @param string[] $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/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListRulesRequest.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListRulesRequest.php new file mode 100644 index 000000000000..eec3d72aa14b --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListRulesRequest.php @@ -0,0 +1,274 @@ +google.cloud.workloadmanager.v1.ListRulesRequest + */ +class ListRulesRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The [project] on which to execute the request. The format is: + * projects/{project_id}/locations/{location} + * Currently, the pre-defined rules are global available to all projects and + * all regions. + * + * 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, 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 the server should return. + * + * Generated from protobuf field string page_token = 3; + */ + protected $page_token = ''; + /** + * Filter based on primary_category, secondary_category. + * + * Generated from protobuf field string filter = 4; + */ + protected $filter = ''; + /** + * The Cloud Storage bucket name for custom rules. + * + * Generated from protobuf field string custom_rules_bucket = 5; + */ + protected $custom_rules_bucket = ''; + /** + * Optional. The evaluation type of the rules will be applied to. + * The Cloud Storage bucket name for custom rules. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.Evaluation.EvaluationType evaluation_type = 6 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $evaluation_type = 0; + + /** + * @param string $parent Required. The [project] on which to execute the request. The format is: + * projects/{project_id}/locations/{location} + * Currently, the pre-defined rules are global available to all projects and + * all regions. Please see + * {@see WorkloadManagerClient::locationName()} for help formatting this field. + * + * @return \Google\Cloud\WorkloadManager\V1\ListRulesRequest + * + * @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] on which to execute the request. The format is: + * projects/{project_id}/locations/{location} + * Currently, the pre-defined rules are global available to all projects and + * all regions. + * @type int $page_size + * Requested page size. Server may return fewer items than requested. + * If unspecified, server will pick an appropriate default. + * @type string $page_token + * A token identifying a page of results the server should return. + * @type string $filter + * Filter based on primary_category, secondary_category. + * @type string $custom_rules_bucket + * The Cloud Storage bucket name for custom rules. + * @type int $evaluation_type + * Optional. The evaluation type of the rules will be applied to. + * The Cloud Storage bucket name for custom rules. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Required. The [project] on which to execute the request. The format is: + * projects/{project_id}/locations/{location} + * Currently, the pre-defined rules are global available to all projects and + * all regions. + * + * 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] on which to execute the request. The format is: + * projects/{project_id}/locations/{location} + * Currently, the pre-defined rules are global available to all projects and + * all regions. + * + * 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, 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, 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 the server should return. + * + * Generated from protobuf field string page_token = 3; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * A token identifying a page of results the server should return. + * + * 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 based on primary_category, secondary_category. + * + * Generated from protobuf field string filter = 4; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * Filter based on primary_category, secondary_category. + * + * 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; + } + + /** + * The Cloud Storage bucket name for custom rules. + * + * Generated from protobuf field string custom_rules_bucket = 5; + * @return string + */ + public function getCustomRulesBucket() + { + return $this->custom_rules_bucket; + } + + /** + * The Cloud Storage bucket name for custom rules. + * + * Generated from protobuf field string custom_rules_bucket = 5; + * @param string $var + * @return $this + */ + public function setCustomRulesBucket($var) + { + GPBUtil::checkString($var, True); + $this->custom_rules_bucket = $var; + + return $this; + } + + /** + * Optional. The evaluation type of the rules will be applied to. + * The Cloud Storage bucket name for custom rules. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.Evaluation.EvaluationType evaluation_type = 6 [(.google.api.field_behavior) = OPTIONAL]; + * @return int + */ + public function getEvaluationType() + { + return $this->evaluation_type; + } + + /** + * Optional. The evaluation type of the rules will be applied to. + * The Cloud Storage bucket name for custom rules. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.Evaluation.EvaluationType evaluation_type = 6 [(.google.api.field_behavior) = OPTIONAL]; + * @param int $var + * @return $this + */ + public function setEvaluationType($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\WorkloadManager\V1\Evaluation\EvaluationType::class); + $this->evaluation_type = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListRulesResponse.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListRulesResponse.php new file mode 100644 index 000000000000..02e22504f3d4 --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListRulesResponse.php @@ -0,0 +1,67 @@ +google.cloud.workloadmanager.v1.ListRulesResponse + */ +class ListRulesResponse extends \Google\Protobuf\Internal\Message +{ + /** + * All rules in response. + * + * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.Rule rules = 1; + */ + private $rules; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type \Google\Cloud\WorkloadManager\V1\Rule[] $rules + * All rules in response. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * All rules in response. + * + * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.Rule rules = 1; + * @return RepeatedField<\Google\Cloud\WorkloadManager\V1\Rule> + */ + public function getRules() + { + return $this->rules; + } + + /** + * All rules in response. + * + * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.Rule rules = 1; + * @param \Google\Cloud\WorkloadManager\V1\Rule[] $var + * @return $this + */ + public function setRules($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\WorkloadManager\V1\Rule::class); + $this->rules = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListScannedResourcesRequest.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListScannedResourcesRequest.php new file mode 100644 index 000000000000..411c1cb6923a --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListScannedResourcesRequest.php @@ -0,0 +1,254 @@ +google.cloud.workloadmanager.v1.ListScannedResourcesRequest + */ +class ListScannedResourcesRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Parent for ListScannedResourcesRequest. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $parent = ''; + /** + * Rule name. + * + * Generated from protobuf field string rule = 2; + */ + protected $rule = ''; + /** + * 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 = 3; + */ + protected $page_size = 0; + /** + * A token identifying a page of results the server should return. + * + * Generated from protobuf field string page_token = 4; + */ + protected $page_token = ''; + /** + * Filtering results. + * + * Generated from protobuf field string filter = 5; + */ + protected $filter = ''; + /** + * Field to sort by. See https://google.aip.dev/132#ordering for more details. + * + * Generated from protobuf field string order_by = 6; + */ + protected $order_by = ''; + + /** + * @param string $parent Required. Parent for ListScannedResourcesRequest. + * + * @return \Google\Cloud\WorkloadManager\V1\ListScannedResourcesRequest + * + * @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 for ListScannedResourcesRequest. + * @type string $rule + * Rule name. + * @type int $page_size + * Requested page size. Server may return fewer items than requested. + * If unspecified, server will pick an appropriate default. + * @type string $page_token + * A token identifying a page of results the server should return. + * @type string $filter + * Filtering results. + * @type string $order_by + * Field to sort by. See https://google.aip.dev/132#ordering for more details. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Required. Parent for ListScannedResourcesRequest. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getParent() + { + return $this->parent; + } + + /** + * Required. Parent for ListScannedResourcesRequest. + * + * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setParent($var) + { + GPBUtil::checkString($var, True); + $this->parent = $var; + + return $this; + } + + /** + * Rule name. + * + * Generated from protobuf field string rule = 2; + * @return string + */ + public function getRule() + { + return $this->rule; + } + + /** + * Rule name. + * + * Generated from protobuf field string rule = 2; + * @param string $var + * @return $this + */ + public function setRule($var) + { + GPBUtil::checkString($var, True); + $this->rule = $var; + + return $this; + } + + /** + * 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 = 3; + * @return int + */ + public function getPageSize() + { + return $this->page_size; + } + + /** + * 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 = 3; + * @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 the server should return. + * + * Generated from protobuf field string page_token = 4; + * @return string + */ + public function getPageToken() + { + return $this->page_token; + } + + /** + * A token identifying a page of results the server should return. + * + * 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; + } + + /** + * Filtering results. + * + * Generated from protobuf field string filter = 5; + * @return string + */ + public function getFilter() + { + return $this->filter; + } + + /** + * Filtering results. + * + * Generated from protobuf field string filter = 5; + * @param string $var + * @return $this + */ + public function setFilter($var) + { + GPBUtil::checkString($var, True); + $this->filter = $var; + + return $this; + } + + /** + * Field to sort by. See https://google.aip.dev/132#ordering for more details. + * + * Generated from protobuf field string order_by = 6; + * @return string + */ + public function getOrderBy() + { + return $this->order_by; + } + + /** + * Field to sort by. See https://google.aip.dev/132#ordering for more details. + * + * Generated from protobuf field string order_by = 6; + * @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/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListScannedResourcesResponse.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListScannedResourcesResponse.php new file mode 100644 index 000000000000..5af4157fe8bd --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListScannedResourcesResponse.php @@ -0,0 +1,105 @@ +google.cloud.workloadmanager.v1.ListScannedResourcesResponse + */ +class ListScannedResourcesResponse extends \Google\Protobuf\Internal\Message +{ + /** + * All scanned resources in response. + * + * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.ScannedResource scanned_resources = 1; + */ + private $scanned_resources; + /** + * 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 \Google\Cloud\WorkloadManager\V1\ScannedResource[] $scanned_resources + * All scanned resources in response. + * @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\Workloadmanager\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * All scanned resources in response. + * + * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.ScannedResource scanned_resources = 1; + * @return RepeatedField<\Google\Cloud\WorkloadManager\V1\ScannedResource> + */ + public function getScannedResources() + { + return $this->scanned_resources; + } + + /** + * All scanned resources in response. + * + * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.ScannedResource scanned_resources = 1; + * @param \Google\Cloud\WorkloadManager\V1\ScannedResource[] $var + * @return $this + */ + public function setScannedResources($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\WorkloadManager\V1\ScannedResource::class); + $this->scanned_resources = $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/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/OperationMetadata.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/OperationMetadata.php new file mode 100644 index 000000000000..67adbada707b --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/OperationMetadata.php @@ -0,0 +1,307 @@ +google.cloud.workloadmanager.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 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\Workloadmanager\V1\Service::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/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Resource.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Resource.php new file mode 100644 index 000000000000..76f883092db6 --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Resource.php @@ -0,0 +1,135 @@ +google.cloud.workloadmanager.v1.Resource + */ +class Resource extends \Google\Protobuf\Internal\Message +{ + /** + * The type of resource. + * + * Generated from protobuf field string type = 1; + */ + protected $type = ''; + /** + * The name of the resource. + * + * Generated from protobuf field string name = 2; + */ + protected $name = ''; + /** + * The service account associated with the resource. + * + * Generated from protobuf field string service_account = 3; + */ + protected $service_account = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $type + * The type of resource. + * @type string $name + * The name of the resource. + * @type string $service_account + * The service account associated with the resource. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * The type of resource. + * + * Generated from protobuf field string type = 1; + * @return string + */ + public function getType() + { + return $this->type; + } + + /** + * The type of resource. + * + * 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 name of the resource. + * + * Generated from protobuf field string name = 2; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * The name of the resource. + * + * 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 service account associated with the resource. + * + * Generated from protobuf field string service_account = 3; + * @return string + */ + public function getServiceAccount() + { + return $this->service_account; + } + + /** + * The service account associated with the resource. + * + * Generated from protobuf field string service_account = 3; + * @param string $var + * @return $this + */ + public function setServiceAccount($var) + { + GPBUtil::checkString($var, True); + $this->service_account = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ResourceFilter.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ResourceFilter.php new file mode 100644 index 000000000000..da38a03e068e --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ResourceFilter.php @@ -0,0 +1,216 @@ +google.cloud.workloadmanager.v1.ResourceFilter + */ +class ResourceFilter extends \Google\Protobuf\Internal\Message +{ + /** + * The scopes of evaluation resource. + * Format: + * * `projects/{project_id}` + * * `folders/{folder_id}` + * * `organizations/{organization_id}` + * + * Generated from protobuf field repeated string scopes = 1; + */ + private $scopes; + /** + * The pattern to filter resources by their id + * For example, a pattern of ".*prod-cluster.*" will match all resources that + * contain "prod-cluster" in their ID. + * + * Generated from protobuf field repeated string resource_id_patterns = 2; + */ + private $resource_id_patterns; + /** + * Labels to filter resources by. Each key-value pair in the map must exist + * on the resource for it to be included (e.g. VM instance labels). + * For example, specifying `{ "env": "prod", "database": "nosql" }` will only + * include resources that have labels `env=prod` and `database=nosql`. + * + * Generated from protobuf field map inclusion_labels = 3; + */ + private $inclusion_labels; + /** + * Filter compute engine resources. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.GceInstanceFilter gce_instance_filter = 4; + */ + protected $gce_instance_filter = null; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string[] $scopes + * The scopes of evaluation resource. + * Format: + * * `projects/{project_id}` + * * `folders/{folder_id}` + * * `organizations/{organization_id}` + * @type string[] $resource_id_patterns + * The pattern to filter resources by their id + * For example, a pattern of ".*prod-cluster.*" will match all resources that + * contain "prod-cluster" in their ID. + * @type array|\Google\Protobuf\Internal\MapField $inclusion_labels + * Labels to filter resources by. Each key-value pair in the map must exist + * on the resource for it to be included (e.g. VM instance labels). + * For example, specifying `{ "env": "prod", "database": "nosql" }` will only + * include resources that have labels `env=prod` and `database=nosql`. + * @type \Google\Cloud\WorkloadManager\V1\GceInstanceFilter $gce_instance_filter + * Filter compute engine resources. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * The scopes of evaluation resource. + * Format: + * * `projects/{project_id}` + * * `folders/{folder_id}` + * * `organizations/{organization_id}` + * + * Generated from protobuf field repeated string scopes = 1; + * @return RepeatedField + */ + public function getScopes() + { + return $this->scopes; + } + + /** + * The scopes of evaluation resource. + * Format: + * * `projects/{project_id}` + * * `folders/{folder_id}` + * * `organizations/{organization_id}` + * + * Generated from protobuf field repeated string scopes = 1; + * @param string[] $var + * @return $this + */ + public function setScopes($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->scopes = $arr; + + return $this; + } + + /** + * The pattern to filter resources by their id + * For example, a pattern of ".*prod-cluster.*" will match all resources that + * contain "prod-cluster" in their ID. + * + * Generated from protobuf field repeated string resource_id_patterns = 2; + * @return RepeatedField + */ + public function getResourceIdPatterns() + { + return $this->resource_id_patterns; + } + + /** + * The pattern to filter resources by their id + * For example, a pattern of ".*prod-cluster.*" will match all resources that + * contain "prod-cluster" in their ID. + * + * Generated from protobuf field repeated string resource_id_patterns = 2; + * @param string[] $var + * @return $this + */ + public function setResourceIdPatterns($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->resource_id_patterns = $arr; + + return $this; + } + + /** + * Labels to filter resources by. Each key-value pair in the map must exist + * on the resource for it to be included (e.g. VM instance labels). + * For example, specifying `{ "env": "prod", "database": "nosql" }` will only + * include resources that have labels `env=prod` and `database=nosql`. + * + * Generated from protobuf field map inclusion_labels = 3; + * @return \Google\Protobuf\Internal\MapField + */ + public function getInclusionLabels() + { + return $this->inclusion_labels; + } + + /** + * Labels to filter resources by. Each key-value pair in the map must exist + * on the resource for it to be included (e.g. VM instance labels). + * For example, specifying `{ "env": "prod", "database": "nosql" }` will only + * include resources that have labels `env=prod` and `database=nosql`. + * + * Generated from protobuf field map inclusion_labels = 3; + * @param array|\Google\Protobuf\Internal\MapField $var + * @return $this + */ + public function setInclusionLabels($var) + { + $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); + $this->inclusion_labels = $arr; + + return $this; + } + + /** + * Filter compute engine resources. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.GceInstanceFilter gce_instance_filter = 4; + * @return \Google\Cloud\WorkloadManager\V1\GceInstanceFilter|null + */ + public function getGceInstanceFilter() + { + return $this->gce_instance_filter; + } + + public function hasGceInstanceFilter() + { + return isset($this->gce_instance_filter); + } + + public function clearGceInstanceFilter() + { + unset($this->gce_instance_filter); + } + + /** + * Filter compute engine resources. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.GceInstanceFilter gce_instance_filter = 4; + * @param \Google\Cloud\WorkloadManager\V1\GceInstanceFilter $var + * @return $this + */ + public function setGceInstanceFilter($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\WorkloadManager\V1\GceInstanceFilter::class); + $this->gce_instance_filter = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ResourceStatus.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ResourceStatus.php new file mode 100644 index 000000000000..a0129371e9c3 --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ResourceStatus.php @@ -0,0 +1,67 @@ +google.cloud.workloadmanager.v1.ResourceStatus + */ +class ResourceStatus extends \Google\Protobuf\Internal\Message +{ + /** + * State of the Evaluation resource. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.ResourceStatus.State state = 2; + */ + protected $state = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $state + * State of the Evaluation resource. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * State of the Evaluation resource. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.ResourceStatus.State state = 2; + * @return int + */ + public function getState() + { + return $this->state; + } + + /** + * State of the Evaluation resource. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.ResourceStatus.State state = 2; + * @param int $var + * @return $this + */ + public function setState($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\WorkloadManager\V1\ResourceStatus\State::class); + $this->state = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ResourceStatus/State.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ResourceStatus/State.php new file mode 100644 index 000000000000..2eb24634e00e --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ResourceStatus/State.php @@ -0,0 +1,69 @@ +google.cloud.workloadmanager.v1.ResourceStatus.State + */ +class State +{ + /** + * The state has not been populated in this message. + * + * Generated from protobuf enum STATE_UNSPECIFIED = 0; + */ + const STATE_UNSPECIFIED = 0; + /** + * Resource has an active Create operation. + * + * Generated from protobuf enum CREATING = 1; + */ + const CREATING = 1; + /** + * Resource has no outstanding operations on it or has active Update + * operations. + * + * Generated from protobuf enum ACTIVE = 2; + */ + const ACTIVE = 2; + /** + * Resource has an active Delete operation. + * + * Generated from protobuf enum DELETING = 3; + */ + const DELETING = 3; + + private static $valueToName = [ + self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', + self::CREATING => 'CREATING', + self::ACTIVE => 'ACTIVE', + 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); + } +} + diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Rule.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Rule.php new file mode 100644 index 000000000000..103e66e66cb1 --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Rule.php @@ -0,0 +1,479 @@ +google.cloud.workloadmanager.v1.Rule + */ +class Rule extends \Google\Protobuf\Internal\Message +{ + /** + * Rule name. + * + * Generated from protobuf field string name = 1; + */ + protected $name = ''; + /** + * Output only. The version of the rule. + * + * Generated from protobuf field string revision_id = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $revision_id = ''; + /** + * The name display in UI. + * + * Generated from protobuf field string display_name = 3; + */ + protected $display_name = ''; + /** + * Describe rule in plain language. + * + * Generated from protobuf field string description = 4; + */ + protected $description = ''; + /** + * The severity of the rule. + * + * Generated from protobuf field string severity = 5; + */ + protected $severity = ''; + /** + * The primary category. + * + * Generated from protobuf field string primary_category = 6; + */ + protected $primary_category = ''; + /** + * The secondary category. + * + * Generated from protobuf field string secondary_category = 7; + */ + protected $secondary_category = ''; + /** + * The message template for rule. + * + * Generated from protobuf field string error_message = 8; + */ + protected $error_message = ''; + /** + * The document url for the rule. + * + * Generated from protobuf field string uri = 9; + */ + protected $uri = ''; + /** + * The remediation for the rule. + * + * Generated from protobuf field string remediation = 10; + */ + protected $remediation = ''; + /** + * List of user-defined tags. + * + * Generated from protobuf field repeated string tags = 11; + */ + private $tags; + /** + * The type of the rule. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.Rule.RuleType rule_type = 12; + */ + protected $rule_type = 0; + /** + * The CAI asset type of the rule is evaluating, for joined asset types, it + * will be the corresponding primary asset types. + * + * Generated from protobuf field string asset_type = 13; + */ + protected $asset_type = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Rule name. + * @type string $revision_id + * Output only. The version of the rule. + * @type string $display_name + * The name display in UI. + * @type string $description + * Describe rule in plain language. + * @type string $severity + * The severity of the rule. + * @type string $primary_category + * The primary category. + * @type string $secondary_category + * The secondary category. + * @type string $error_message + * The message template for rule. + * @type string $uri + * The document url for the rule. + * @type string $remediation + * The remediation for the rule. + * @type string[] $tags + * List of user-defined tags. + * @type int $rule_type + * The type of the rule. + * @type string $asset_type + * The CAI asset type of the rule is evaluating, for joined asset types, it + * will be the corresponding primary asset types. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Rule name. + * + * Generated from protobuf field string name = 1; + * @return string + */ + public function getName() + { + return $this->name; + } + + /** + * Rule 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. The version of the rule. + * + * Generated from protobuf field string revision_id = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getRevisionId() + { + return $this->revision_id; + } + + /** + * Output only. The version of the rule. + * + * Generated from protobuf field string revision_id = 2 [(.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; + } + + /** + * The name display in UI. + * + * Generated from protobuf field string display_name = 3; + * @return string + */ + public function getDisplayName() + { + return $this->display_name; + } + + /** + * The name display in UI. + * + * Generated from protobuf field string display_name = 3; + * @param string $var + * @return $this + */ + public function setDisplayName($var) + { + GPBUtil::checkString($var, True); + $this->display_name = $var; + + return $this; + } + + /** + * Describe rule in plain language. + * + * Generated from protobuf field string description = 4; + * @return string + */ + public function getDescription() + { + return $this->description; + } + + /** + * Describe rule in plain language. + * + * Generated from protobuf field string description = 4; + * @param string $var + * @return $this + */ + public function setDescription($var) + { + GPBUtil::checkString($var, True); + $this->description = $var; + + return $this; + } + + /** + * The severity of the rule. + * + * Generated from protobuf field string severity = 5; + * @return string + */ + public function getSeverity() + { + return $this->severity; + } + + /** + * The severity of the rule. + * + * Generated from protobuf field string severity = 5; + * @param string $var + * @return $this + */ + public function setSeverity($var) + { + GPBUtil::checkString($var, True); + $this->severity = $var; + + return $this; + } + + /** + * The primary category. + * + * Generated from protobuf field string primary_category = 6; + * @return string + */ + public function getPrimaryCategory() + { + return $this->primary_category; + } + + /** + * The primary category. + * + * Generated from protobuf field string primary_category = 6; + * @param string $var + * @return $this + */ + public function setPrimaryCategory($var) + { + GPBUtil::checkString($var, True); + $this->primary_category = $var; + + return $this; + } + + /** + * The secondary category. + * + * Generated from protobuf field string secondary_category = 7; + * @return string + */ + public function getSecondaryCategory() + { + return $this->secondary_category; + } + + /** + * The secondary category. + * + * Generated from protobuf field string secondary_category = 7; + * @param string $var + * @return $this + */ + public function setSecondaryCategory($var) + { + GPBUtil::checkString($var, True); + $this->secondary_category = $var; + + return $this; + } + + /** + * The message template for rule. + * + * Generated from protobuf field string error_message = 8; + * @return string + */ + public function getErrorMessage() + { + return $this->error_message; + } + + /** + * The message template for rule. + * + * Generated from protobuf field string error_message = 8; + * @param string $var + * @return $this + */ + public function setErrorMessage($var) + { + GPBUtil::checkString($var, True); + $this->error_message = $var; + + return $this; + } + + /** + * The document url for the rule. + * + * Generated from protobuf field string uri = 9; + * @return string + */ + public function getUri() + { + return $this->uri; + } + + /** + * The document url for the rule. + * + * Generated from protobuf field string uri = 9; + * @param string $var + * @return $this + */ + public function setUri($var) + { + GPBUtil::checkString($var, True); + $this->uri = $var; + + return $this; + } + + /** + * The remediation for the rule. + * + * Generated from protobuf field string remediation = 10; + * @return string + */ + public function getRemediation() + { + return $this->remediation; + } + + /** + * The remediation for the rule. + * + * Generated from protobuf field string remediation = 10; + * @param string $var + * @return $this + */ + public function setRemediation($var) + { + GPBUtil::checkString($var, True); + $this->remediation = $var; + + return $this; + } + + /** + * List of user-defined tags. + * + * Generated from protobuf field repeated string tags = 11; + * @return RepeatedField + */ + public function getTags() + { + return $this->tags; + } + + /** + * List of user-defined tags. + * + * Generated from protobuf field repeated string tags = 11; + * @param string[] $var + * @return $this + */ + public function setTags($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); + $this->tags = $arr; + + return $this; + } + + /** + * The type of the rule. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.Rule.RuleType rule_type = 12; + * @return int + */ + public function getRuleType() + { + return $this->rule_type; + } + + /** + * The type of the rule. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.Rule.RuleType rule_type = 12; + * @param int $var + * @return $this + */ + public function setRuleType($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\WorkloadManager\V1\Rule\RuleType::class); + $this->rule_type = $var; + + return $this; + } + + /** + * The CAI asset type of the rule is evaluating, for joined asset types, it + * will be the corresponding primary asset types. + * + * Generated from protobuf field string asset_type = 13; + * @return string + */ + public function getAssetType() + { + return $this->asset_type; + } + + /** + * The CAI asset type of the rule is evaluating, for joined asset types, it + * will be the corresponding primary asset types. + * + * Generated from protobuf field string asset_type = 13; + * @param string $var + * @return $this + */ + public function setAssetType($var) + { + GPBUtil::checkString($var, True); + $this->asset_type = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Rule/RuleType.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Rule/RuleType.php new file mode 100644 index 000000000000..41da1acddf5c --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Rule/RuleType.php @@ -0,0 +1,61 @@ +google.cloud.workloadmanager.v1.Rule.RuleType + */ +class RuleType +{ + /** + * Not specified. + * + * Generated from protobuf enum RULE_TYPE_UNSPECIFIED = 0; + */ + const RULE_TYPE_UNSPECIFIED = 0; + /** + * Baseline rules. + * + * Generated from protobuf enum BASELINE = 1; + */ + const BASELINE = 1; + /** + * Custom rules. + * + * Generated from protobuf enum CUSTOM = 2; + */ + const CUSTOM = 2; + + private static $valueToName = [ + self::RULE_TYPE_UNSPECIFIED => 'RULE_TYPE_UNSPECIFIED', + self::BASELINE => 'BASELINE', + self::CUSTOM => 'CUSTOM', + ]; + + 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/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/RuleExecutionResult.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/RuleExecutionResult.php new file mode 100644 index 000000000000..92f0d8f39dc8 --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/RuleExecutionResult.php @@ -0,0 +1,203 @@ +google.cloud.workloadmanager.v1.RuleExecutionResult + */ +class RuleExecutionResult extends \Google\Protobuf\Internal\Message +{ + /** + * Rule name as plain text like `sap-hana-configured`. + * + * Generated from protobuf field string rule = 1; + */ + protected $rule = ''; + /** + * Output only. The execution status. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.RuleExecutionResult.State state = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $state = 0; + /** + * Execution message, if any. + * + * Generated from protobuf field string message = 3; + */ + protected $message = ''; + /** + * Number of violations. + * + * Generated from protobuf field int64 result_count = 4; + */ + protected $result_count = 0; + /** + * Number of total scanned resources. + * + * Generated from protobuf field int64 scanned_resource_count = 5; + */ + protected $scanned_resource_count = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $rule + * Rule name as plain text like `sap-hana-configured`. + * @type int $state + * Output only. The execution status. + * @type string $message + * Execution message, if any. + * @type int|string $result_count + * Number of violations. + * @type int|string $scanned_resource_count + * Number of total scanned resources. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Rule name as plain text like `sap-hana-configured`. + * + * Generated from protobuf field string rule = 1; + * @return string + */ + public function getRule() + { + return $this->rule; + } + + /** + * Rule name as plain text like `sap-hana-configured`. + * + * Generated from protobuf field string rule = 1; + * @param string $var + * @return $this + */ + public function setRule($var) + { + GPBUtil::checkString($var, True); + $this->rule = $var; + + return $this; + } + + /** + * Output only. The execution status. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.RuleExecutionResult.State state = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return int + */ + public function getState() + { + return $this->state; + } + + /** + * Output only. The execution status. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.RuleExecutionResult.State state = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param int $var + * @return $this + */ + public function setState($var) + { + GPBUtil::checkEnum($var, \Google\Cloud\WorkloadManager\V1\RuleExecutionResult\State::class); + $this->state = $var; + + return $this; + } + + /** + * Execution message, if any. + * + * Generated from protobuf field string message = 3; + * @return string + */ + public function getMessage() + { + return $this->message; + } + + /** + * Execution message, if any. + * + * Generated from protobuf field string message = 3; + * @param string $var + * @return $this + */ + public function setMessage($var) + { + GPBUtil::checkString($var, True); + $this->message = $var; + + return $this; + } + + /** + * Number of violations. + * + * Generated from protobuf field int64 result_count = 4; + * @return int|string + */ + public function getResultCount() + { + return $this->result_count; + } + + /** + * Number of violations. + * + * Generated from protobuf field int64 result_count = 4; + * @param int|string $var + * @return $this + */ + public function setResultCount($var) + { + GPBUtil::checkInt64($var); + $this->result_count = $var; + + return $this; + } + + /** + * Number of total scanned resources. + * + * Generated from protobuf field int64 scanned_resource_count = 5; + * @return int|string + */ + public function getScannedResourceCount() + { + return $this->scanned_resource_count; + } + + /** + * Number of total scanned resources. + * + * Generated from protobuf field int64 scanned_resource_count = 5; + * @param int|string $var + * @return $this + */ + public function setScannedResourceCount($var) + { + GPBUtil::checkInt64($var); + $this->scanned_resource_count = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/RuleExecutionResult/State.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/RuleExecutionResult/State.php new file mode 100644 index 000000000000..1adc3db3ba48 --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/RuleExecutionResult/State.php @@ -0,0 +1,68 @@ +google.cloud.workloadmanager.v1.RuleExecutionResult.State + */ +class State +{ + /** + * Unknown state + * + * Generated from protobuf enum STATE_UNSPECIFIED = 0; + */ + const STATE_UNSPECIFIED = 0; + /** + * Execution completed successfully + * + * Generated from protobuf enum STATE_SUCCESS = 1; + */ + const STATE_SUCCESS = 1; + /** + * Execution completed with failures + * + * Generated from protobuf enum STATE_FAILURE = 2; + */ + const STATE_FAILURE = 2; + /** + * Execution was not executed + * + * Generated from protobuf enum STATE_SKIPPED = 3; + */ + const STATE_SKIPPED = 3; + + private static $valueToName = [ + self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', + self::STATE_SUCCESS => 'STATE_SUCCESS', + self::STATE_FAILURE => 'STATE_FAILURE', + self::STATE_SKIPPED => 'STATE_SKIPPED', + ]; + + 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/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/RuleOutput.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/RuleOutput.php new file mode 100644 index 000000000000..28f1ea969edf --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/RuleOutput.php @@ -0,0 +1,101 @@ +google.cloud.workloadmanager.v1.RuleOutput + */ +class RuleOutput extends \Google\Protobuf\Internal\Message +{ + /** + * Output only. Violation details generated by rule. + * + * Generated from protobuf field map details = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + private $details; + /** + * Output only. The message generated by rule. + * + * Generated from protobuf field string message = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $message = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type array|\Google\Protobuf\Internal\MapField $details + * Output only. Violation details generated by rule. + * @type string $message + * Output only. The message generated by rule. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Output only. Violation details generated by rule. + * + * Generated from protobuf field map details = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return \Google\Protobuf\Internal\MapField + */ + public function getDetails() + { + return $this->details; + } + + /** + * Output only. Violation details generated by rule. + * + * Generated from protobuf field map details = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param array|\Google\Protobuf\Internal\MapField $var + * @return $this + */ + public function setDetails($var) + { + $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); + $this->details = $arr; + + return $this; + } + + /** + * Output only. The message generated by rule. + * + * Generated from protobuf field string message = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return string + */ + public function getMessage() + { + return $this->message; + } + + /** + * Output only. The message generated by rule. + * + * 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; + } + +} + diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/RunEvaluationRequest.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/RunEvaluationRequest.php new file mode 100644 index 000000000000..e5ba45787979 --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/RunEvaluationRequest.php @@ -0,0 +1,242 @@ +google.cloud.workloadmanager.v1.RunEvaluationRequest + */ +class RunEvaluationRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. The resource name of the Evaluation using the form: + * `projects/{project}/locations/{location}/evaluations/{evaluation}`. + * + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { + */ + protected $name = ''; + /** + * Required. ID of the execution which will be created. + * + * Generated from protobuf field string execution_id = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $execution_id = ''; + /** + * Required. The resource being created. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.Execution execution = 3 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $execution = 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 $name Required. The resource name of the Evaluation using the form: + * `projects/{project}/locations/{location}/evaluations/{evaluation}`. Please see + * {@see WorkloadManagerClient::evaluationName()} for help formatting this field. + * @param \Google\Cloud\WorkloadManager\V1\Execution $execution Required. The resource being created. + * @param string $executionId Required. ID of the execution which will be created. + * + * @return \Google\Cloud\WorkloadManager\V1\RunEvaluationRequest + * + * @experimental + */ + public static function build(string $name, \Google\Cloud\WorkloadManager\V1\Execution $execution, string $executionId): self + { + return (new self()) + ->setName($name) + ->setExecution($execution) + ->setExecutionId($executionId); + } + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $name + * Required. The resource name of the Evaluation using the form: + * `projects/{project}/locations/{location}/evaluations/{evaluation}`. + * @type string $execution_id + * Required. ID of the execution which will be created. + * @type \Google\Cloud\WorkloadManager\V1\Execution $execution + * 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 + * 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\Workloadmanager\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Required. The resource name of the Evaluation using the form: + * `projects/{project}/locations/{location}/evaluations/{evaluation}`. + * + * 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 Evaluation using the form: + * `projects/{project}/locations/{location}/evaluations/{evaluation}`. + * + * 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. ID of the execution which will be created. + * + * Generated from protobuf field string execution_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return string + */ + public function getExecutionId() + { + return $this->execution_id; + } + + /** + * Required. ID of the execution which will be created. + * + * Generated from protobuf field string execution_id = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param string $var + * @return $this + */ + public function setExecutionId($var) + { + GPBUtil::checkString($var, True); + $this->execution_id = $var; + + return $this; + } + + /** + * Required. The resource being created. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.Execution execution = 3 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\WorkloadManager\V1\Execution|null + */ + public function getExecution() + { + return $this->execution; + } + + public function hasExecution() + { + return isset($this->execution); + } + + public function clearExecution() + { + unset($this->execution); + } + + /** + * Required. The resource being created. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.Execution execution = 3 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\WorkloadManager\V1\Execution $var + * @return $this + */ + public function setExecution($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\WorkloadManager\V1\Execution::class); + $this->execution = $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/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ScannedResource.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ScannedResource.php new file mode 100644 index 000000000000..3d841554e1ac --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ScannedResource.php @@ -0,0 +1,101 @@ +google.cloud.workloadmanager.v1.ScannedResource + */ +class ScannedResource extends \Google\Protobuf\Internal\Message +{ + /** + * Resource name. + * + * Generated from protobuf field string resource = 1; + */ + protected $resource = ''; + /** + * Resource type. + * + * Generated from protobuf field string type = 2; + */ + protected $type = ''; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $resource + * Resource name. + * @type string $type + * Resource type. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Resource name. + * + * Generated from protobuf field string resource = 1; + * @return string + */ + public function getResource() + { + return $this->resource; + } + + /** + * Resource name. + * + * Generated from protobuf field string resource = 1; + * @param string $var + * @return $this + */ + public function setResource($var) + { + GPBUtil::checkString($var, True); + $this->resource = $var; + + return $this; + } + + /** + * Resource type. + * + * Generated from protobuf field string type = 2; + * @return string + */ + public function getType() + { + return $this->type; + } + + /** + * Resource type. + * + * 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; + } + +} + diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ShellCommand.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ShellCommand.php new file mode 100644 index 000000000000..d862e692f53a --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ShellCommand.php @@ -0,0 +1,135 @@ +google.cloud.workloadmanager.v1.ShellCommand + */ +class ShellCommand extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the command to be executed. + * + * Generated from protobuf field string command = 1; + */ + protected $command = ''; + /** + * Arguments to be passed to the command. + * + * Generated from protobuf field string args = 2; + */ + protected $args = ''; + /** + * Optional. If not specified, the default timeout is 60 seconds. + * + * Generated from protobuf field int32 timeout_seconds = 3; + */ + protected $timeout_seconds = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $command + * The name of the command to be executed. + * @type string $args + * Arguments to be passed to the command. + * @type int $timeout_seconds + * Optional. If not specified, the default timeout is 60 seconds. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * The name of the command to be executed. + * + * Generated from protobuf field string command = 1; + * @return string + */ + public function getCommand() + { + return $this->command; + } + + /** + * The name of the command to be executed. + * + * Generated from protobuf field string command = 1; + * @param string $var + * @return $this + */ + public function setCommand($var) + { + GPBUtil::checkString($var, True); + $this->command = $var; + + return $this; + } + + /** + * Arguments to be passed to the command. + * + * Generated from protobuf field string args = 2; + * @return string + */ + public function getArgs() + { + return $this->args; + } + + /** + * Arguments to be passed to the command. + * + * Generated from protobuf field string args = 2; + * @param string $var + * @return $this + */ + public function setArgs($var) + { + GPBUtil::checkString($var, True); + $this->args = $var; + + return $this; + } + + /** + * Optional. If not specified, the default timeout is 60 seconds. + * + * Generated from protobuf field int32 timeout_seconds = 3; + * @return int + */ + public function getTimeoutSeconds() + { + return $this->timeout_seconds; + } + + /** + * Optional. If not specified, the default timeout is 60 seconds. + * + * Generated from protobuf field int32 timeout_seconds = 3; + * @param int $var + * @return $this + */ + public function setTimeoutSeconds($var) + { + GPBUtil::checkInt32($var); + $this->timeout_seconds = $var; + + return $this; + } + +} + diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/UpdateEvaluationRequest.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/UpdateEvaluationRequest.php new file mode 100644 index 000000000000..39206bd970f6 --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/UpdateEvaluationRequest.php @@ -0,0 +1,225 @@ +google.cloud.workloadmanager.v1.UpdateEvaluationRequest + */ +class UpdateEvaluationRequest extends \Google\Protobuf\Internal\Message +{ + /** + * Required. Field mask is used to specify the fields to be overwritten in the + * Evaluation 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. + * + * 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.workloadmanager.v1.Evaluation evaluation = 2 [(.google.api.field_behavior) = REQUIRED]; + */ + protected $evaluation = 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $request_id = ''; + + /** + * @param \Google\Cloud\WorkloadManager\V1\Evaluation $evaluation Required. The resource being updated. + * @param \Google\Protobuf\FieldMask $updateMask Required. Field mask is used to specify the fields to be overwritten in the + * Evaluation 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. + * + * @return \Google\Cloud\WorkloadManager\V1\UpdateEvaluationRequest + * + * @experimental + */ + public static function build(\Google\Cloud\WorkloadManager\V1\Evaluation $evaluation, \Google\Protobuf\FieldMask $updateMask): self + { + return (new self()) + ->setEvaluation($evaluation) + ->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 + * Evaluation 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. + * @type \Google\Cloud\WorkloadManager\V1\Evaluation $evaluation + * 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 + * 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\Workloadmanager\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * Required. Field mask is used to specify the fields to be overwritten in the + * Evaluation 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. + * + * 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 + * Evaluation 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. + * + * 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.workloadmanager.v1.Evaluation evaluation = 2 [(.google.api.field_behavior) = REQUIRED]; + * @return \Google\Cloud\WorkloadManager\V1\Evaluation|null + */ + public function getEvaluation() + { + return $this->evaluation; + } + + public function hasEvaluation() + { + return isset($this->evaluation); + } + + public function clearEvaluation() + { + unset($this->evaluation); + } + + /** + * Required. The resource being updated. + * + * Generated from protobuf field .google.cloud.workloadmanager.v1.Evaluation evaluation = 2 [(.google.api.field_behavior) = REQUIRED]; + * @param \Google\Cloud\WorkloadManager\V1\Evaluation $var + * @return $this + */ + public function setEvaluation($var) + { + GPBUtil::checkMessage($var, \Google\Cloud\WorkloadManager\V1\Evaluation::class); + $this->evaluation = $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 = 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 + * 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 = 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; + } + +} + diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ViolationDetails.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ViolationDetails.php new file mode 100644 index 000000000000..fd2bd3f72e67 --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ViolationDetails.php @@ -0,0 +1,169 @@ +google.cloud.workloadmanager.v1.ViolationDetails + */ +class ViolationDetails extends \Google\Protobuf\Internal\Message +{ + /** + * The name of the asset. + * + * Generated from protobuf field string asset = 1; + */ + protected $asset = ''; + /** + * The service account associated with the resource. + * + * Generated from protobuf field string service_account = 2; + */ + protected $service_account = ''; + /** + * Details of the violation. + * + * Generated from protobuf field map observed = 3; + */ + private $observed; + /** + * Output only. The rule output of the violation. + * + * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.RuleOutput rule_output = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + private $rule_output; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type string $asset + * The name of the asset. + * @type string $service_account + * The service account associated with the resource. + * @type array|\Google\Protobuf\Internal\MapField $observed + * Details of the violation. + * @type \Google\Cloud\WorkloadManager\V1\RuleOutput[] $rule_output + * Output only. The rule output of the violation. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); + parent::__construct($data); + } + + /** + * The name of the asset. + * + * Generated from protobuf field string asset = 1; + * @return string + */ + public function getAsset() + { + return $this->asset; + } + + /** + * The name of the asset. + * + * Generated from protobuf field string asset = 1; + * @param string $var + * @return $this + */ + public function setAsset($var) + { + GPBUtil::checkString($var, True); + $this->asset = $var; + + return $this; + } + + /** + * The service account associated with the resource. + * + * Generated from protobuf field string service_account = 2; + * @return string + */ + public function getServiceAccount() + { + return $this->service_account; + } + + /** + * The service account associated with the resource. + * + * Generated from protobuf field string service_account = 2; + * @param string $var + * @return $this + */ + public function setServiceAccount($var) + { + GPBUtil::checkString($var, True); + $this->service_account = $var; + + return $this; + } + + /** + * Details of the violation. + * + * Generated from protobuf field map observed = 3; + * @return \Google\Protobuf\Internal\MapField + */ + public function getObserved() + { + return $this->observed; + } + + /** + * Details of the violation. + * + * Generated from protobuf field map observed = 3; + * @param array|\Google\Protobuf\Internal\MapField $var + * @return $this + */ + public function setObserved($var) + { + $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); + $this->observed = $arr; + + return $this; + } + + /** + * Output only. The rule output of the violation. + * + * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.RuleOutput rule_output = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return RepeatedField<\Google\Cloud\WorkloadManager\V1\RuleOutput> + */ + public function getRuleOutput() + { + return $this->rule_output; + } + + /** + * Output only. The rule output of the violation. + * + * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.RuleOutput rule_output = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param \Google\Cloud\WorkloadManager\V1\RuleOutput[] $var + * @return $this + */ + public function setRuleOutput($var) + { + $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\WorkloadManager\V1\RuleOutput::class); + $this->rule_output = $arr; + + return $this; + } + +} + diff --git a/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/create_evaluation.php b/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/create_evaluation.php new file mode 100644 index 000000000000..946ff96e3de8 --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/create_evaluation.php @@ -0,0 +1,89 @@ +setParent($formattedParent) + ->setEvaluationId($evaluationId) + ->setEvaluation($evaluation); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $workloadManagerClient->createEvaluation($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var Evaluation $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 = WorkloadManagerClient::locationName('[PROJECT]', '[LOCATION]'); + $evaluationId = '[EVALUATION_ID]'; + + create_evaluation_sample($formattedParent, $evaluationId); +} +// [END workloadmanager_v1_generated_WorkloadManager_CreateEvaluation_sync] diff --git a/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/delete_evaluation.php b/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/delete_evaluation.php new file mode 100644 index 000000000000..cf7e883c5513 --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/delete_evaluation.php @@ -0,0 +1,80 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $workloadManagerClient->deleteEvaluation($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 = WorkloadManagerClient::evaluationName('[PROJECT]', '[LOCATION]', '[EVALUATION]'); + + delete_evaluation_sample($formattedName); +} +// [END workloadmanager_v1_generated_WorkloadManager_DeleteEvaluation_sync] diff --git a/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/delete_execution.php b/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/delete_execution.php new file mode 100644 index 000000000000..1b42923f0bc6 --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/delete_execution.php @@ -0,0 +1,85 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $workloadManagerClient->deleteExecution($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 = WorkloadManagerClient::executionName( + '[PROJECT]', + '[LOCATION]', + '[EVALUATION]', + '[EXECUTION]' + ); + + delete_execution_sample($formattedName); +} +// [END workloadmanager_v1_generated_WorkloadManager_DeleteExecution_sync] diff --git a/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/get_evaluation.php b/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/get_evaluation.php new file mode 100644 index 000000000000..928dcd7349ce --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/get_evaluation.php @@ -0,0 +1,71 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var Evaluation $response */ + $response = $workloadManagerClient->getEvaluation($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 = WorkloadManagerClient::evaluationName('[PROJECT]', '[LOCATION]', '[EVALUATION]'); + + get_evaluation_sample($formattedName); +} +// [END workloadmanager_v1_generated_WorkloadManager_GetEvaluation_sync] diff --git a/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/get_execution.php b/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/get_execution.php new file mode 100644 index 000000000000..e6490eed3403 --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/get_execution.php @@ -0,0 +1,76 @@ +setName($formattedName); + + // Call the API and handle any network failures. + try { + /** @var Execution $response */ + $response = $workloadManagerClient->getExecution($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 = WorkloadManagerClient::executionName( + '[PROJECT]', + '[LOCATION]', + '[EVALUATION]', + '[EXECUTION]' + ); + + get_execution_sample($formattedName); +} +// [END workloadmanager_v1_generated_WorkloadManager_GetExecution_sync] diff --git a/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/get_location.php b/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/get_location.php new file mode 100644 index 000000000000..4dd8e78e641d --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/get_location.php @@ -0,0 +1,57 @@ +getLocation($request); + printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} +// [END workloadmanager_v1_generated_WorkloadManager_GetLocation_sync] diff --git a/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_evaluations.php b/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_evaluations.php new file mode 100644 index 000000000000..1edf71c9733b --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_evaluations.php @@ -0,0 +1,76 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $workloadManagerClient->listEvaluations($request); + + /** @var Evaluation $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 = WorkloadManagerClient::locationName('[PROJECT]', '[LOCATION]'); + + list_evaluations_sample($formattedParent); +} +// [END workloadmanager_v1_generated_WorkloadManager_ListEvaluations_sync] diff --git a/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_execution_results.php b/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_execution_results.php new file mode 100644 index 000000000000..10119be227df --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_execution_results.php @@ -0,0 +1,76 @@ +setParent($parent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $workloadManagerClient->listExecutionResults($request); + + /** @var ExecutionResult $element */ + foreach ($response as $element) { + printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); + } + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $parent = '[PARENT]'; + + list_execution_results_sample($parent); +} +// [END workloadmanager_v1_generated_WorkloadManager_ListExecutionResults_sync] diff --git a/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_executions.php b/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_executions.php new file mode 100644 index 000000000000..77c8445d1031 --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_executions.php @@ -0,0 +1,77 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $workloadManagerClient->listExecutions($request); + + /** @var Execution $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 = WorkloadManagerClient::evaluationName('[PROJECT]', '[LOCATION]', '[EVALUATION]'); + + list_executions_sample($formattedParent); +} +// [END workloadmanager_v1_generated_WorkloadManager_ListExecutions_sync] diff --git a/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_locations.php b/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_locations.php new file mode 100644 index 000000000000..f8541e067d2d --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_locations.php @@ -0,0 +1,69 @@ +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 workloadmanager_v1_generated_WorkloadManager_ListLocations_sync] diff --git a/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_rules.php b/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_rules.php new file mode 100644 index 000000000000..6f635458dbaf --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_rules.php @@ -0,0 +1,74 @@ +setParent($formattedParent); + + // Call the API and handle any network failures. + try { + /** @var ListRulesResponse $response */ + $response = $workloadManagerClient->listRules($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 = WorkloadManagerClient::locationName('[PROJECT]', '[LOCATION]'); + + list_rules_sample($formattedParent); +} +// [END workloadmanager_v1_generated_WorkloadManager_ListRules_sync] diff --git a/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_scanned_resources.php b/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_scanned_resources.php new file mode 100644 index 000000000000..c130916085f8 --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_scanned_resources.php @@ -0,0 +1,75 @@ +setParent($parent); + + // Call the API and handle any network failures. + try { + /** @var PagedListResponse $response */ + $response = $workloadManagerClient->listScannedResources($request); + + /** @var ScannedResource $element */ + foreach ($response as $element) { + printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); + } + } catch (ApiException $ex) { + printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); + } +} + +/** + * Helper to execute the sample. + * + * This sample has been automatically generated and should be regarded as a code + * template only. It will require modifications to work: + * - It may require correct/in-range values for request initialization. + * - It may require specifying regional endpoints when creating the service client, + * please see the apiEndpoint client configuration option for more details. + */ +function callSample(): void +{ + $parent = '[PARENT]'; + + list_scanned_resources_sample($parent); +} +// [END workloadmanager_v1_generated_WorkloadManager_ListScannedResources_sync] diff --git a/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/run_evaluation.php b/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/run_evaluation.php new file mode 100644 index 000000000000..321c5b2c2235 --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/run_evaluation.php @@ -0,0 +1,89 @@ +setName($formattedName) + ->setExecutionId($executionId) + ->setExecution($execution); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $workloadManagerClient->runEvaluation($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var Execution $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 = WorkloadManagerClient::evaluationName('[PROJECT]', '[LOCATION]', '[EVALUATION]'); + $executionId = '[EXECUTION_ID]'; + + run_evaluation_sample($formattedName, $executionId); +} +// [END workloadmanager_v1_generated_WorkloadManager_RunEvaluation_sync] diff --git a/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/update_evaluation.php b/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/update_evaluation.php new file mode 100644 index 000000000000..7621109e30c8 --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/update_evaluation.php @@ -0,0 +1,74 @@ +setUpdateMask($updateMask) + ->setEvaluation($evaluation); + + // Call the API and handle any network failures. + try { + /** @var OperationResponse $response */ + $response = $workloadManagerClient->updateEvaluation($request); + $response->pollUntilComplete(); + + if ($response->operationSucceeded()) { + /** @var Evaluation $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 workloadmanager_v1_generated_WorkloadManager_UpdateEvaluation_sync] diff --git a/owl-bot-staging/WorkloadManager/v1/src/V1/Client/WorkloadManagerClient.php b/owl-bot-staging/WorkloadManager/v1/src/V1/Client/WorkloadManagerClient.php new file mode 100644 index 000000000000..41c8cf3466c8 --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/src/V1/Client/WorkloadManagerClient.php @@ -0,0 +1,747 @@ + createEvaluationAsync(CreateEvaluationRequest $request, array $optionalArgs = []) + * @method PromiseInterface deleteEvaluationAsync(DeleteEvaluationRequest $request, array $optionalArgs = []) + * @method PromiseInterface deleteExecutionAsync(DeleteExecutionRequest $request, array $optionalArgs = []) + * @method PromiseInterface getEvaluationAsync(GetEvaluationRequest $request, array $optionalArgs = []) + * @method PromiseInterface getExecutionAsync(GetExecutionRequest $request, array $optionalArgs = []) + * @method PromiseInterface listEvaluationsAsync(ListEvaluationsRequest $request, array $optionalArgs = []) + * @method PromiseInterface listExecutionResultsAsync(ListExecutionResultsRequest $request, array $optionalArgs = []) + * @method PromiseInterface listExecutionsAsync(ListExecutionsRequest $request, array $optionalArgs = []) + * @method PromiseInterface listRulesAsync(ListRulesRequest $request, array $optionalArgs = []) + * @method PromiseInterface listScannedResourcesAsync(ListScannedResourcesRequest $request, array $optionalArgs = []) + * @method PromiseInterface runEvaluationAsync(RunEvaluationRequest $request, array $optionalArgs = []) + * @method PromiseInterface updateEvaluationAsync(UpdateEvaluationRequest $request, array $optionalArgs = []) + * @method PromiseInterface getLocationAsync(GetLocationRequest $request, array $optionalArgs = []) + * @method PromiseInterface listLocationsAsync(ListLocationsRequest $request, array $optionalArgs = []) + */ +final class WorkloadManagerClient +{ + use GapicClientTrait; + use ResourceHelperTrait; + + /** The name of the service. */ + private const SERVICE_NAME = 'google.cloud.workloadmanager.v1.WorkloadManager'; + + /** + * The default address of the service. + * + * @deprecated SERVICE_ADDRESS_TEMPLATE should be used instead. + */ + private const SERVICE_ADDRESS = 'workloadmanager.googleapis.com'; + + /** The address template of the service. */ + private const SERVICE_ADDRESS_TEMPLATE = 'workloadmanager.UNIVERSE_DOMAIN'; + + /** The default port of the service. */ + private const DEFAULT_SERVICE_PORT = 443; + + /** The name of the code generator, to be included in the agent header. */ + private const CODEGEN_NAME = 'gapic'; + + /** The default scopes required by the service. */ + public static $serviceScopes = [ + 'https://www.googleapis.com/auth/cloud-platform', + ]; + + private $operationsClient; + + private static function getClientDefaults() + { + return [ + 'serviceName' => self::SERVICE_NAME, + 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, + 'clientConfig' => __DIR__ . '/../resources/workload_manager_client_config.json', + 'descriptorsConfigPath' => __DIR__ . '/../resources/workload_manager_descriptor_config.php', + 'gcpApiConfigPath' => __DIR__ . '/../resources/workload_manager_grpc_config.json', + 'credentialsConfig' => [ + 'defaultScopes' => self::$serviceScopes, + ], + 'transportConfig' => [ + 'rest' => [ + 'restClientConfigPath' => __DIR__ . '/../resources/workload_manager_rest_client_config.php', + ], + ], + ]; + } + + /** + * 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 = $this->descriptors[$methodName]['longRunning'] ?? []; + $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); + $operation->reload(); + return $operation; + } + + /** + * Create the default operation client for the service. + * + * @param array $options ClientOptions for the client. + * + * @return OperationsClient + */ + private function createOperationsClient(array $options) + { + // Unset client-specific configuration options + unset($options['serviceName'], $options['clientConfig'], $options['descriptorsConfigPath']); + + if (isset($options['operationsClient'])) { + return $options['operationsClient']; + } + + return new OperationsClient($options); + } + + /** + * 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(string $project, string $location, string $keyRing, string $cryptoKey): string + { + return self::getPathTemplate('cryptoKey')->render([ + 'project' => $project, + 'location' => $location, + 'key_ring' => $keyRing, + 'crypto_key' => $cryptoKey, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a evaluation + * resource. + * + * @param string $project + * @param string $location + * @param string $evaluation + * + * @return string The formatted evaluation resource. + */ + public static function evaluationName(string $project, string $location, string $evaluation): string + { + return self::getPathTemplate('evaluation')->render([ + 'project' => $project, + 'location' => $location, + 'evaluation' => $evaluation, + ]); + } + + /** + * Formats a string containing the fully-qualified path to represent a execution + * resource. + * + * @param string $project + * @param string $location + * @param string $evaluation + * @param string $execution + * + * @return string The formatted execution resource. + */ + public static function executionName(string $project, string $location, string $evaluation, string $execution): string + { + return self::getPathTemplate('execution')->render([ + 'project' => $project, + 'location' => $location, + 'evaluation' => $evaluation, + 'execution' => $execution, + ]); + } + + /** + * 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(string $project, string $location): string + { + return self::getPathTemplate('location')->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} + * - evaluation: projects/{project}/locations/{location}/evaluations/{evaluation} + * - execution: projects/{project}/locations/{location}/evaluations/{evaluation}/executions/{execution} + * - 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(string $formattedName, ?string $template = null): array + { + return self::parseFormattedName($formattedName, $template); + } + + /** + * Constructor. + * + * @param array|ClientOptions $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 'workloadmanager.googleapis.com:443'. + * @type FetchAuthTokenInterface|CredentialsWrapper $credentials + * This option should only be used with a pre-constructed + * {@see FetchAuthTokenInterface} or {@see CredentialsWrapper} object. Note that + * when one of these objects are provided, any settings in $credentialsConfig will + * be ignored. + * **Important**: If you are providing a path to a credentials file, or a decoded + * credentials file as a PHP array, this usage is now DEPRECATED. Providing an + * unvalidated credential configuration to Google APIs can compromise the security + * of your systems and data. It is recommended to create the credentials explicitly + * ``` + * use Google\Auth\Credentials\ServiceAccountCredentials; + * use Google\Cloud\WorkloadManager\V1\WorkloadManagerClient; + * $creds = new ServiceAccountCredentials($scopes, $json); + * $options = new WorkloadManagerClient(['credentials' => $creds]); + * ``` + * {@see + * https://cloud.google.com/docs/authentication/external/externally-sourced-credentials} + * @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. + * @type false|LoggerInterface $logger + * A PSR-3 compliant logger. If set to false, logging is disabled, ignoring the + * 'GOOGLE_SDK_PHP_LOGGING' environment flag + * @type string $universeDomain + * The service domain for the client. Defaults to 'googleapis.com'. + * } + * + * @throws ValidationException + */ + public function __construct(array|ClientOptions $options = []) + { + $clientOptions = $this->buildClientOptions($options); + $this->setClientOptions($clientOptions); + $this->operationsClient = $this->createOperationsClient($clientOptions); + } + + /** Handles execution of the async variants for each documented method. */ + public function __call($method, $args) + { + if (substr($method, -5) !== 'Async') { + trigger_error('Call to undefined method ' . __CLASS__ . "::$method()", E_USER_ERROR); + } + + array_unshift($args, substr($method, 0, -5)); + return call_user_func_array([$this, 'startAsyncCall'], $args); + } + + /** + * Creates a new Evaluation in a given project and location. + * + * The async variant is {@see WorkloadManagerClient::createEvaluationAsync()} . + * + * @example samples/V1/WorkloadManagerClient/create_evaluation.php + * + * @param CreateEvaluationRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function createEvaluation(CreateEvaluationRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('CreateEvaluation', $request, $callOptions)->wait(); + } + + /** + * Deletes a single Evaluation. + * + * The async variant is {@see WorkloadManagerClient::deleteEvaluationAsync()} . + * + * @example samples/V1/WorkloadManagerClient/delete_evaluation.php + * + * @param DeleteEvaluationRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function deleteEvaluation(DeleteEvaluationRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('DeleteEvaluation', $request, $callOptions)->wait(); + } + + /** + * Deletes a single Execution. + * + * The async variant is {@see WorkloadManagerClient::deleteExecutionAsync()} . + * + * @example samples/V1/WorkloadManagerClient/delete_execution.php + * + * @param DeleteExecutionRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function deleteExecution(DeleteExecutionRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('DeleteExecution', $request, $callOptions)->wait(); + } + + /** + * Gets details of a single Evaluation. + * + * The async variant is {@see WorkloadManagerClient::getEvaluationAsync()} . + * + * @example samples/V1/WorkloadManagerClient/get_evaluation.php + * + * @param GetEvaluationRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Evaluation + * + * @throws ApiException Thrown if the API call fails. + */ + public function getEvaluation(GetEvaluationRequest $request, array $callOptions = []): Evaluation + { + return $this->startApiCall('GetEvaluation', $request, $callOptions)->wait(); + } + + /** + * Gets details of a single Execution. + * + * The async variant is {@see WorkloadManagerClient::getExecutionAsync()} . + * + * @example samples/V1/WorkloadManagerClient/get_execution.php + * + * @param GetExecutionRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Execution + * + * @throws ApiException Thrown if the API call fails. + */ + public function getExecution(GetExecutionRequest $request, array $callOptions = []): Execution + { + return $this->startApiCall('GetExecution', $request, $callOptions)->wait(); + } + + /** + * Lists Evaluations in a given project and location. + * + * The async variant is {@see WorkloadManagerClient::listEvaluationsAsync()} . + * + * @example samples/V1/WorkloadManagerClient/list_evaluations.php + * + * @param ListEvaluationsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listEvaluations(ListEvaluationsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListEvaluations', $request, $callOptions); + } + + /** + * Lists the result of a single evaluation. + * + * The async variant is {@see WorkloadManagerClient::listExecutionResultsAsync()} . + * + * @example samples/V1/WorkloadManagerClient/list_execution_results.php + * + * @param ListExecutionResultsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listExecutionResults(ListExecutionResultsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListExecutionResults', $request, $callOptions); + } + + /** + * Lists Executions in a given project and location. + * + * The async variant is {@see WorkloadManagerClient::listExecutionsAsync()} . + * + * @example samples/V1/WorkloadManagerClient/list_executions.php + * + * @param ListExecutionsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listExecutions(ListExecutionsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListExecutions', $request, $callOptions); + } + + /** + * Lists rules in a given project. + * + * The async variant is {@see WorkloadManagerClient::listRulesAsync()} . + * + * @example samples/V1/WorkloadManagerClient/list_rules.php + * + * @param ListRulesRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 ListRulesResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listRules(ListRulesRequest $request, array $callOptions = []): ListRulesResponse + { + return $this->startApiCall('ListRules', $request, $callOptions)->wait(); + } + + /** + * List all scanned resources for a single Execution. + * + * The async variant is {@see WorkloadManagerClient::listScannedResourcesAsync()} . + * + * @example samples/V1/WorkloadManagerClient/list_scanned_resources.php + * + * @param ListScannedResourcesRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listScannedResources(ListScannedResourcesRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListScannedResources', $request, $callOptions); + } + + /** + * Creates a new Execution in a given project and location. + * + * The async variant is {@see WorkloadManagerClient::runEvaluationAsync()} . + * + * @example samples/V1/WorkloadManagerClient/run_evaluation.php + * + * @param RunEvaluationRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function runEvaluation(RunEvaluationRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('RunEvaluation', $request, $callOptions)->wait(); + } + + /** + * Updates the parameters of a single Evaluation. + * + * The async variant is {@see WorkloadManagerClient::updateEvaluationAsync()} . + * + * @example samples/V1/WorkloadManagerClient/update_evaluation.php + * + * @param UpdateEvaluationRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 OperationResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function updateEvaluation(UpdateEvaluationRequest $request, array $callOptions = []): OperationResponse + { + return $this->startApiCall('UpdateEvaluation', $request, $callOptions)->wait(); + } + + /** + * Gets information about a location. + * + * The async variant is {@see WorkloadManagerClient::getLocationAsync()} . + * + * @example samples/V1/WorkloadManagerClient/get_location.php + * + * @param GetLocationRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 Location + * + * @throws ApiException Thrown if the API call fails. + */ + public function getLocation(GetLocationRequest $request, array $callOptions = []): Location + { + return $this->startApiCall('GetLocation', $request, $callOptions)->wait(); + } + + /** + * Lists information about the supported locations for this service. + * This method can be called in two ways: + * + * * **List all public locations:** Use the path `GET /v1/locations`. + * * **List project-visible locations:** Use the path + * `GET /v1/projects/{project_id}/locations`. This may include public + * locations as well as private or other locations specifically visible + * to the project. + * + * The async variant is {@see WorkloadManagerClient::listLocationsAsync()} . + * + * @example samples/V1/WorkloadManagerClient/list_locations.php + * + * @param ListLocationsRequest $request A request to house fields associated with the call. + * @param array $callOptions { + * 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 PagedListResponse + * + * @throws ApiException Thrown if the API call fails. + */ + public function listLocations(ListLocationsRequest $request, array $callOptions = []): PagedListResponse + { + return $this->startApiCall('ListLocations', $request, $callOptions); + } +} diff --git a/owl-bot-staging/WorkloadManager/v1/src/V1/gapic_metadata.json b/owl-bot-staging/WorkloadManager/v1/src/V1/gapic_metadata.json new file mode 100644 index 000000000000..528f5cd3ba5c --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/src/V1/gapic_metadata.json @@ -0,0 +1,88 @@ +{ + "schema": "1.0", + "comment": "This file maps proto services\/RPCs to the corresponding library clients\/methods", + "language": "php", + "protoPackage": "google.cloud.workloadmanager.v1", + "libraryPackage": "Google\\Cloud\\WorkloadManager\\V1", + "services": { + "WorkloadManager": { + "clients": { + "grpc": { + "libraryClient": "WorkloadManagerGapicClient", + "rpcs": { + "CreateEvaluation": { + "methods": [ + "createEvaluation" + ] + }, + "DeleteEvaluation": { + "methods": [ + "deleteEvaluation" + ] + }, + "DeleteExecution": { + "methods": [ + "deleteExecution" + ] + }, + "GetEvaluation": { + "methods": [ + "getEvaluation" + ] + }, + "GetExecution": { + "methods": [ + "getExecution" + ] + }, + "ListEvaluations": { + "methods": [ + "listEvaluations" + ] + }, + "ListExecutionResults": { + "methods": [ + "listExecutionResults" + ] + }, + "ListExecutions": { + "methods": [ + "listExecutions" + ] + }, + "ListRules": { + "methods": [ + "listRules" + ] + }, + "ListScannedResources": { + "methods": [ + "listScannedResources" + ] + }, + "RunEvaluation": { + "methods": [ + "runEvaluation" + ] + }, + "UpdateEvaluation": { + "methods": [ + "updateEvaluation" + ] + }, + "GetLocation": { + "methods": [ + "getLocation" + ] + }, + "ListLocations": { + "methods": [ + "listLocations" + ] + } + } + } + } + } + } +} \ No newline at end of file diff --git a/owl-bot-staging/WorkloadManager/v1/src/V1/resources/workload_manager_client_config.json b/owl-bot-staging/WorkloadManager/v1/src/V1/resources/workload_manager_client_config.json new file mode 100644 index 000000000000..dd44e952f80f --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/src/V1/resources/workload_manager_client_config.json @@ -0,0 +1,114 @@ +{ + "interfaces": { + "google.cloud.workloadmanager.v1.WorkloadManager": { + "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": { + "CreateEvaluation": { + "timeout_millis": 60000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + }, + "DeleteEvaluation": { + "timeout_millis": 60000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + }, + "DeleteExecution": { + "timeout_millis": 60000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + }, + "GetEvaluation": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "GetExecution": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ListEvaluations": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ListExecutionResults": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ListExecutions": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ListRules": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "ListScannedResources": { + "timeout_millis": 60000, + "retry_codes_name": "retry_policy_1_codes", + "retry_params_name": "retry_policy_1_params" + }, + "RunEvaluation": { + "timeout_millis": 60000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_1_params" + }, + "UpdateEvaluation": { + "timeout_millis": 60000, + "retry_codes_name": "no_retry_1_codes", + "retry_params_name": "no_retry_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/WorkloadManager/v1/src/V1/resources/workload_manager_descriptor_config.php b/owl-bot-staging/WorkloadManager/v1/src/V1/resources/workload_manager_descriptor_config.php new file mode 100644 index 000000000000..e7df68739353 --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/src/V1/resources/workload_manager_descriptor_config.php @@ -0,0 +1,280 @@ + [ + 'google.cloud.workloadmanager.v1.WorkloadManager' => [ + 'CreateEvaluation' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\WorkloadManager\V1\Evaluation', + 'metadataReturnType' => '\Google\Cloud\WorkloadManager\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'DeleteEvaluation' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Protobuf\GPBEmpty', + 'metadataReturnType' => '\Google\Cloud\WorkloadManager\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'DeleteExecution' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Protobuf\GPBEmpty', + 'metadataReturnType' => '\Google\Cloud\WorkloadManager\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'RunEvaluation' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\WorkloadManager\V1\Execution', + 'metadataReturnType' => '\Google\Cloud\WorkloadManager\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'UpdateEvaluation' => [ + 'longRunning' => [ + 'operationReturnType' => '\Google\Cloud\WorkloadManager\V1\Evaluation', + 'metadataReturnType' => '\Google\Cloud\WorkloadManager\V1\OperationMetadata', + 'initialPollDelayMillis' => '500', + 'pollDelayMultiplier' => '1.5', + 'maxPollDelayMillis' => '5000', + 'totalPollTimeoutMillis' => '300000', + ], + 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, + 'headerParams' => [ + [ + 'keyName' => 'evaluation.name', + 'fieldAccessors' => [ + 'getEvaluation', + 'getName', + ], + ], + ], + ], + 'GetEvaluation' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\WorkloadManager\V1\Evaluation', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'GetExecution' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\WorkloadManager\V1\Execution', + 'headerParams' => [ + [ + 'keyName' => 'name', + 'fieldAccessors' => [ + 'getName', + ], + ], + ], + ], + 'ListEvaluations' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getEvaluations', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\WorkloadManager\V1\ListEvaluationsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListExecutionResults' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getExecutionResults', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\WorkloadManager\V1\ListExecutionResultsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListExecutions' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getExecutions', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\WorkloadManager\V1\ListExecutionsResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListRules' => [ + 'callType' => \Google\ApiCore\Call::UNARY_CALL, + 'responseType' => 'Google\Cloud\WorkloadManager\V1\ListRulesResponse', + 'headerParams' => [ + [ + 'keyName' => 'parent', + 'fieldAccessors' => [ + 'getParent', + ], + ], + ], + ], + 'ListScannedResources' => [ + 'pageStreaming' => [ + 'requestPageTokenGetMethod' => 'getPageToken', + 'requestPageTokenSetMethod' => 'setPageToken', + 'requestPageSizeGetMethod' => 'getPageSize', + 'requestPageSizeSetMethod' => 'setPageSize', + 'responsePageTokenGetMethod' => 'getNextPageToken', + 'resourcesGetMethod' => 'getScannedResources', + ], + 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, + 'responseType' => 'Google\Cloud\WorkloadManager\V1\ListScannedResourcesResponse', + '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' => [ + 'cryptoKey' => 'projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}', + 'evaluation' => 'projects/{project}/locations/{location}/evaluations/{evaluation}', + 'execution' => 'projects/{project}/locations/{location}/evaluations/{evaluation}/executions/{execution}', + 'location' => 'projects/{project}/locations/{location}', + ], + ], + ], +]; diff --git a/owl-bot-staging/WorkloadManager/v1/src/V1/resources/workload_manager_rest_client_config.php b/owl-bot-staging/WorkloadManager/v1/src/V1/resources/workload_manager_rest_client_config.php new file mode 100644 index 000000000000..5977c87e8787 --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/src/V1/resources/workload_manager_rest_client_config.php @@ -0,0 +1,242 @@ + [ + '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.cloud.workloadmanager.v1.WorkloadManager' => [ + 'CreateEvaluation' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/evaluations', + 'body' => 'evaluation', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + 'queryParams' => [ + 'evaluation_id', + ], + ], + 'DeleteEvaluation' => [ + 'method' => 'delete', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/evaluations/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'DeleteExecution' => [ + 'method' => 'delete', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/evaluations/*/executions/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetEvaluation' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/evaluations/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'GetExecution' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/evaluations/*/executions/*}', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'ListEvaluations' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/evaluations', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListExecutionResults' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*/evaluations/*/executions/*}/results', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListExecutions' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*/evaluations/*}/executions', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListRules' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/rules', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'ListScannedResources' => [ + 'method' => 'get', + 'uriTemplate' => '/v1/{parent=projects/*/locations/*/evaluations/*/executions/*}/scannedResources', + 'placeholders' => [ + 'parent' => [ + 'getters' => [ + 'getParent', + ], + ], + ], + ], + 'RunEvaluation' => [ + 'method' => 'post', + 'uriTemplate' => '/v1/{name=projects/*/locations/*/evaluations/*}/executions:run', + 'body' => '*', + 'placeholders' => [ + 'name' => [ + 'getters' => [ + 'getName', + ], + ], + ], + ], + 'UpdateEvaluation' => [ + 'method' => 'patch', + 'uriTemplate' => '/v1/{evaluation.name=projects/*/locations/*/evaluations/*}', + 'body' => 'evaluation', + 'placeholders' => [ + 'evaluation.name' => [ + 'getters' => [ + 'getEvaluation', + 'getName', + ], + ], + ], + 'queryParams' => [ + 'update_mask', + ], + ], + ], + '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/WorkloadManager/v1/tests/Unit/V1/Client/WorkloadManagerClientTest.php b/owl-bot-staging/WorkloadManager/v1/tests/Unit/V1/Client/WorkloadManagerClientTest.php new file mode 100644 index 000000000000..6c81198d74ae --- /dev/null +++ b/owl-bot-staging/WorkloadManager/v1/tests/Unit/V1/Client/WorkloadManagerClientTest.php @@ -0,0 +1,1444 @@ +getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); + } + + /** @return WorkloadManagerClient */ + private function createClient(array $options = []) + { + $options += [ + 'credentials' => $this->createCredentials(), + ]; + return new WorkloadManagerClient($options); + } + + /** @test */ + public function createEvaluationTest() + { + $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/createEvaluationTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $description = 'description-1724546052'; + $schedule = 'schedule-697920873'; + $customRulesBucket = 'customRulesBucket2000095296'; + $kmsKey = 'kmsKey-591635343'; + $expectedResponse = new Evaluation(); + $expectedResponse->setName($name); + $expectedResponse->setDescription($description); + $expectedResponse->setSchedule($schedule); + $expectedResponse->setCustomRulesBucket($customRulesBucket); + $expectedResponse->setKmsKey($kmsKey); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/createEvaluationTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); + $evaluationId = 'evaluationId-257994498'; + $evaluation = new Evaluation(); + $request = (new CreateEvaluationRequest()) + ->setParent($formattedParent) + ->setEvaluationId($evaluationId) + ->setEvaluation($evaluation); + $response = $gapicClient->createEvaluation($request); + $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.workloadmanager.v1.WorkloadManager/CreateEvaluation', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualApiRequestObject->getEvaluationId(); + $this->assertProtobufEquals($evaluationId, $actualValue); + $actualValue = $actualApiRequestObject->getEvaluation(); + $this->assertProtobufEquals($evaluation, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createEvaluationTest'); + $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 createEvaluationExceptionTest() + { + $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/createEvaluationTest'); + $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]'); + $evaluationId = 'evaluationId-257994498'; + $evaluation = new Evaluation(); + $request = (new CreateEvaluationRequest()) + ->setParent($formattedParent) + ->setEvaluationId($evaluationId) + ->setEvaluation($evaluation); + $response = $gapicClient->createEvaluation($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createEvaluationTest'); + 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 deleteEvaluationTest() + { + $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/deleteEvaluationTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $expectedResponse = new GPBEmpty(); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/deleteEvaluationTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedName = $gapicClient->evaluationName('[PROJECT]', '[LOCATION]', '[EVALUATION]'); + $request = (new DeleteEvaluationRequest()) + ->setName($formattedName); + $response = $gapicClient->deleteEvaluation($request); + $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.workloadmanager.v1.WorkloadManager/DeleteEvaluation', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/deleteEvaluationTest'); + $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 deleteEvaluationExceptionTest() + { + $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/deleteEvaluationTest'); + $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->evaluationName('[PROJECT]', '[LOCATION]', '[EVALUATION]'); + $request = (new DeleteEvaluationRequest()) + ->setName($formattedName); + $response = $gapicClient->deleteEvaluation($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/deleteEvaluationTest'); + 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 deleteExecutionTest() + { + $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/deleteExecutionTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $expectedResponse = new GPBEmpty(); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/deleteExecutionTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedName = $gapicClient->executionName('[PROJECT]', '[LOCATION]', '[EVALUATION]', '[EXECUTION]'); + $request = (new DeleteExecutionRequest()) + ->setName($formattedName); + $response = $gapicClient->deleteExecution($request); + $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.workloadmanager.v1.WorkloadManager/DeleteExecution', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/deleteExecutionTest'); + $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 deleteExecutionExceptionTest() + { + $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/deleteExecutionTest'); + $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->executionName('[PROJECT]', '[LOCATION]', '[EVALUATION]', '[EXECUTION]'); + $request = (new DeleteExecutionRequest()) + ->setName($formattedName); + $response = $gapicClient->deleteExecution($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/deleteExecutionTest'); + 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 getEvaluationTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $description = 'description-1724546052'; + $schedule = 'schedule-697920873'; + $customRulesBucket = 'customRulesBucket2000095296'; + $kmsKey = 'kmsKey-591635343'; + $expectedResponse = new Evaluation(); + $expectedResponse->setName($name2); + $expectedResponse->setDescription($description); + $expectedResponse->setSchedule($schedule); + $expectedResponse->setCustomRulesBucket($customRulesBucket); + $expectedResponse->setKmsKey($kmsKey); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->evaluationName('[PROJECT]', '[LOCATION]', '[EVALUATION]'); + $request = (new GetEvaluationRequest()) + ->setName($formattedName); + $response = $gapicClient->getEvaluation($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.workloadmanager.v1.WorkloadManager/GetEvaluation', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getEvaluationExceptionTest() + { + $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->evaluationName('[PROJECT]', '[LOCATION]', '[EVALUATION]'); + $request = (new GetEvaluationRequest()) + ->setName($formattedName); + try { + $gapicClient->getEvaluation($request); + // 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 getExecutionTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $name2 = 'name2-1052831874'; + $evaluationId = 'evaluationId-257994498'; + $expectedResponse = new Execution(); + $expectedResponse->setName($name2); + $expectedResponse->setEvaluationId($evaluationId); + $transport->addResponse($expectedResponse); + // Mock request + $formattedName = $gapicClient->executionName('[PROJECT]', '[LOCATION]', '[EVALUATION]', '[EXECUTION]'); + $request = (new GetExecutionRequest()) + ->setName($formattedName); + $response = $gapicClient->getExecution($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.workloadmanager.v1.WorkloadManager/GetExecution', $actualFuncCall); + $actualValue = $actualRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function getExecutionExceptionTest() + { + $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->executionName('[PROJECT]', '[LOCATION]', '[EVALUATION]', '[EXECUTION]'); + $request = (new GetExecutionRequest()) + ->setName($formattedName); + try { + $gapicClient->getExecution($request); + // 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 listEvaluationsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $evaluationsElement = new Evaluation(); + $evaluations = [ + $evaluationsElement, + ]; + $expectedResponse = new ListEvaluationsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setEvaluations($evaluations); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); + $request = (new ListEvaluationsRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listEvaluations($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getEvaluations()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.workloadmanager.v1.WorkloadManager/ListEvaluations', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listEvaluationsExceptionTest() + { + $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]'); + $request = (new ListEvaluationsRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listEvaluations($request); + // 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 listExecutionResultsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $executionResultsElement = new ExecutionResult(); + $executionResults = [ + $executionResultsElement, + ]; + $expectedResponse = new ListExecutionResultsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setExecutionResults($executionResults); + $transport->addResponse($expectedResponse); + // Mock request + $parent = 'parent-995424086'; + $request = (new ListExecutionResultsRequest()) + ->setParent($parent); + $response = $gapicClient->listExecutionResults($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getExecutionResults()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.workloadmanager.v1.WorkloadManager/ListExecutionResults', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($parent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listExecutionResultsExceptionTest() + { + $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 + $parent = 'parent-995424086'; + $request = (new ListExecutionResultsRequest()) + ->setParent($parent); + try { + $gapicClient->listExecutionResults($request); + // 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 listExecutionsTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $executionsElement = new Execution(); + $executions = [ + $executionsElement, + ]; + $expectedResponse = new ListExecutionsResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setExecutions($executions); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->evaluationName('[PROJECT]', '[LOCATION]', '[EVALUATION]'); + $request = (new ListExecutionsRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listExecutions($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getExecutions()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.workloadmanager.v1.WorkloadManager/ListExecutions', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listExecutionsExceptionTest() + { + $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->evaluationName('[PROJECT]', '[LOCATION]', '[EVALUATION]'); + $request = (new ListExecutionsRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listExecutions($request); + // 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 listRulesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $expectedResponse = new ListRulesResponse(); + $transport->addResponse($expectedResponse); + // Mock request + $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); + $request = (new ListRulesRequest()) + ->setParent($formattedParent); + $response = $gapicClient->listRules($request); + $this->assertEquals($expectedResponse, $response); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.workloadmanager.v1.WorkloadManager/ListRules', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listRulesExceptionTest() + { + $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]'); + $request = (new ListRulesRequest()) + ->setParent($formattedParent); + try { + $gapicClient->listRules($request); + // 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 listScannedResourcesTest() + { + $transport = $this->createTransport(); + $gapicClient = $this->createClient([ + 'transport' => $transport, + ]); + $this->assertTrue($transport->isExhausted()); + // Mock response + $nextPageToken = ''; + $scannedResourcesElement = new ScannedResource(); + $scannedResources = [ + $scannedResourcesElement, + ]; + $expectedResponse = new ListScannedResourcesResponse(); + $expectedResponse->setNextPageToken($nextPageToken); + $expectedResponse->setScannedResources($scannedResources); + $transport->addResponse($expectedResponse); + // Mock request + $parent = 'parent-995424086'; + $request = (new ListScannedResourcesRequest()) + ->setParent($parent); + $response = $gapicClient->listScannedResources($request); + $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); + $resources = iterator_to_array($response->iterateAllElements()); + $this->assertSame(1, count($resources)); + $this->assertEquals($expectedResponse->getScannedResources()[0], $resources[0]); + $actualRequests = $transport->popReceivedCalls(); + $this->assertSame(1, count($actualRequests)); + $actualFuncCall = $actualRequests[0]->getFuncCall(); + $actualRequestObject = $actualRequests[0]->getRequestObject(); + $this->assertSame('/google.cloud.workloadmanager.v1.WorkloadManager/ListScannedResources', $actualFuncCall); + $actualValue = $actualRequestObject->getParent(); + $this->assertProtobufEquals($parent, $actualValue); + $this->assertTrue($transport->isExhausted()); + } + + /** @test */ + public function listScannedResourcesExceptionTest() + { + $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 + $parent = 'parent-995424086'; + $request = (new ListScannedResourcesRequest()) + ->setParent($parent); + try { + $gapicClient->listScannedResources($request); + // 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 runEvaluationTest() + { + $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/runEvaluationTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name2 = 'name2-1052831874'; + $evaluationId = 'evaluationId-257994498'; + $expectedResponse = new Execution(); + $expectedResponse->setName($name2); + $expectedResponse->setEvaluationId($evaluationId); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/runEvaluationTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedName = $gapicClient->evaluationName('[PROJECT]', '[LOCATION]', '[EVALUATION]'); + $executionId = 'executionId-1217171550'; + $execution = new Execution(); + $request = (new RunEvaluationRequest()) + ->setName($formattedName) + ->setExecutionId($executionId) + ->setExecution($execution); + $response = $gapicClient->runEvaluation($request); + $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.workloadmanager.v1.WorkloadManager/RunEvaluation', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getName(); + $this->assertProtobufEquals($formattedName, $actualValue); + $actualValue = $actualApiRequestObject->getExecutionId(); + $this->assertProtobufEquals($executionId, $actualValue); + $actualValue = $actualApiRequestObject->getExecution(); + $this->assertProtobufEquals($execution, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/runEvaluationTest'); + $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 runEvaluationExceptionTest() + { + $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/runEvaluationTest'); + $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->evaluationName('[PROJECT]', '[LOCATION]', '[EVALUATION]'); + $executionId = 'executionId-1217171550'; + $execution = new Execution(); + $request = (new RunEvaluationRequest()) + ->setName($formattedName) + ->setExecutionId($executionId) + ->setExecution($execution); + $response = $gapicClient->runEvaluation($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/runEvaluationTest'); + 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 updateEvaluationTest() + { + $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/updateEvaluationTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $description = 'description-1724546052'; + $schedule = 'schedule-697920873'; + $customRulesBucket = 'customRulesBucket2000095296'; + $kmsKey = 'kmsKey-591635343'; + $expectedResponse = new Evaluation(); + $expectedResponse->setName($name); + $expectedResponse->setDescription($description); + $expectedResponse->setSchedule($schedule); + $expectedResponse->setCustomRulesBucket($customRulesBucket); + $expectedResponse->setKmsKey($kmsKey); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/updateEvaluationTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $updateMask = new FieldMask(); + $evaluation = new Evaluation(); + $request = (new UpdateEvaluationRequest()) + ->setUpdateMask($updateMask) + ->setEvaluation($evaluation); + $response = $gapicClient->updateEvaluation($request); + $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.workloadmanager.v1.WorkloadManager/UpdateEvaluation', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getUpdateMask(); + $this->assertProtobufEquals($updateMask, $actualValue); + $actualValue = $actualApiRequestObject->getEvaluation(); + $this->assertProtobufEquals($evaluation, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updateEvaluationTest'); + $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 updateEvaluationExceptionTest() + { + $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/updateEvaluationTest'); + $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(); + $evaluation = new Evaluation(); + $request = (new UpdateEvaluationRequest()) + ->setUpdateMask($updateMask) + ->setEvaluation($evaluation); + $response = $gapicClient->updateEvaluation($request); + $this->assertFalse($response->isDone()); + $this->assertNull($response->getResult()); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/updateEvaluationTest'); + 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); + $request = new GetLocationRequest(); + $response = $gapicClient->getLocation($request); + $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); + $request = new GetLocationRequest(); + try { + $gapicClient->getLocation($request); + // 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); + $request = new ListLocationsRequest(); + $response = $gapicClient->listLocations($request); + $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); + $request = new ListLocationsRequest(); + try { + $gapicClient->listLocations($request); + // 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 createEvaluationAsyncTest() + { + $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/createEvaluationTest'); + $incompleteOperation->setDone(false); + $transport->addResponse($incompleteOperation); + $name = 'name3373707'; + $description = 'description-1724546052'; + $schedule = 'schedule-697920873'; + $customRulesBucket = 'customRulesBucket2000095296'; + $kmsKey = 'kmsKey-591635343'; + $expectedResponse = new Evaluation(); + $expectedResponse->setName($name); + $expectedResponse->setDescription($description); + $expectedResponse->setSchedule($schedule); + $expectedResponse->setCustomRulesBucket($customRulesBucket); + $expectedResponse->setKmsKey($kmsKey); + $anyResponse = new Any(); + $anyResponse->setValue($expectedResponse->serializeToString()); + $completeOperation = new Operation(); + $completeOperation->setName('operations/createEvaluationTest'); + $completeOperation->setDone(true); + $completeOperation->setResponse($anyResponse); + $operationsTransport->addResponse($completeOperation); + // Mock request + $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); + $evaluationId = 'evaluationId-257994498'; + $evaluation = new Evaluation(); + $request = (new CreateEvaluationRequest()) + ->setParent($formattedParent) + ->setEvaluationId($evaluationId) + ->setEvaluation($evaluation); + $response = $gapicClient->createEvaluationAsync($request)->wait(); + $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.workloadmanager.v1.WorkloadManager/CreateEvaluation', $actualApiFuncCall); + $actualValue = $actualApiRequestObject->getParent(); + $this->assertProtobufEquals($formattedParent, $actualValue); + $actualValue = $actualApiRequestObject->getEvaluationId(); + $this->assertProtobufEquals($evaluationId, $actualValue); + $actualValue = $actualApiRequestObject->getEvaluation(); + $this->assertProtobufEquals($evaluation, $actualValue); + $expectedOperationsRequestObject = new GetOperationRequest(); + $expectedOperationsRequestObject->setName('operations/createEvaluationTest'); + $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()); + } +} From da1a9d01b1653559bc4a285e13fad97f5d90597c Mon Sep 17 00:00:00 2001 From: Owl Bot Date: Tue, 9 Jun 2026 10:06:48 +0000 Subject: [PATCH 2/2] =?UTF-8?q?=F0=9F=A6=89=20Updates=20from=20OwlBot=20po?= =?UTF-8?q?st-processor?= 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 --- .../get_iam_policy.php | 2 +- .../list_locations.php | 30 +- .../set_iam_policy.php | 8 +- .../test_iam_permissions.php | 12 +- .../CertificateAuthorityServiceClient.php | 52 +- .../ServiceManagerClient/get_iam_policy.php | 2 +- .../ServiceManagerClient/set_iam_policy.php | 8 +- .../test_iam_permissions.php | 12 +- .../src/V1/Client/ServiceManagerClient.php | 22 +- .../V2/SpeechClient/list_locations.php | 14 +- Speech/src/V2/Client/SpeechClient.php | 14 +- .../list_locations.php | 32 +- .../list_locations.php | 32 +- .../list_locations.php | 32 +- .../Client/DataObjectSearchServiceClient.php | 32 +- .../src/V1/Client/DataObjectServiceClient.php | 32 +- .../V1/Client/VectorSearchServiceClient.php | 32 +- .../V1/VmwareEngineClient/get_iam_policy.php | 2 +- .../V1/VmwareEngineClient/set_iam_policy.php | 8 +- .../test_iam_permissions.php | 12 +- .../src/V1/Client/VmwareEngineClient.php | 22 +- .../WorkloadManagerClient/list_locations.php | 14 +- .../src/V1/Client/WorkloadManagerClient.php | 14 +- .../Cloud/Security/Privateca/V1/Resources.php | 29 - .../Cloud/Security/Privateca/V1/Service.php | 34 - .../ActivateCertificateAuthorityRequest.php | 252 - .../Security/PrivateCA/V1/AttributeType.php | 104 - .../PrivateCA/V1/AttributeTypeAndValue.php | 144 - .../Cloud/Security/PrivateCA/V1/CaPool.php | 341 - .../PrivateCA/V1/CaPool/IssuancePolicy.php | 602 -- .../CaPool/IssuancePolicy/AllowedKeyType.php | 113 - .../AllowedKeyType/EcKeyType.php | 73 - .../EcKeyType/EcSignatureAlgorithm.php | 74 - .../AllowedKeyType/RsaKeyType.php | 119 - .../CaPool/IssuancePolicy/IssuanceModes.php | 124 - .../PrivateCA/V1/CaPool/PublishingOptions.php | 209 - .../PublishingOptions/EncodingFormat.php | 65 - .../Security/PrivateCA/V1/CaPool/Tier.php | 62 - .../Security/PrivateCA/V1/Certificate.php | 755 -- .../V1/Certificate/RevocationDetails.php | 128 - .../PrivateCA/V1/CertificateAuthority.php | 1038 -- .../V1/CertificateAuthority/AccessUrls.php | 127 - .../CertificateAuthority/KeyVersionSpec.php | 128 - .../SignHashAlgorithm.php | 111 - .../V1/CertificateAuthority/State.php | 108 - .../V1/CertificateAuthority/Type.php | 65 - .../UserDefinedAccessUrls.php | 142 - .../PrivateCA/V1/CertificateConfig.php | 259 - .../PrivateCA/V1/CertificateConfig/KeyId.php | 72 - .../V1/CertificateConfig/SubjectConfig.php | 126 - .../PrivateCA/V1/CertificateDescription.php | 438 - .../CertificateFingerprint.php | 67 - .../V1/CertificateDescription/KeyId.php | 72 - .../SubjectDescription.php | 304 - .../V1/CertificateExtensionConstraints.php | 122 - .../KnownCertificateExtension.php | 120 - .../V1/CertificateIdentityConstraints.php | 216 - .../V1/CertificateRevocationList.php | 448 - .../RevokedCertificate.php | 156 - .../V1/CertificateRevocationList/State.php | 67 - .../PrivateCA/V1/CertificateTemplate.php | 593 -- .../PrivateCA/V1/CreateCaPoolRequest.php | 258 - .../V1/CreateCertificateAuthorityRequest.php | 268 - .../PrivateCA/V1/CreateCertificateRequest.php | 451 - .../V1/CreateCertificateTemplateRequest.php | 263 - .../PrivateCA/V1/DeleteCaPoolRequest.php | 212 - .../V1/DeleteCertificateAuthorityRequest.php | 292 - .../V1/DeleteCertificateTemplateRequest.php | 166 - .../V1/DisableCertificateAuthorityRequest.php | 212 - .../V1/EnableCertificateAuthorityRequest.php | 166 - .../Security/PrivateCA/V1/EncryptionSpec.php | 71 - .../PrivateCA/V1/FetchCaCertsRequest.php | 166 - .../PrivateCA/V1/FetchCaCertsResponse.php | 76 - .../V1/FetchCaCertsResponse/CertChain.php | 65 - .../FetchCertificateAuthorityCsrRequest.php | 92 - .../FetchCertificateAuthorityCsrResponse.php | 68 - .../PrivateCA/V1/GetCaPoolRequest.php | 87 - .../V1/GetCertificateAuthorityRequest.php | 97 - .../PrivateCA/V1/GetCertificateRequest.php | 92 - .../GetCertificateRevocationListRequest.php | 102 - .../V1/GetCertificateTemplateRequest.php | 97 - .../Cloud/Security/PrivateCA/V1/KeyUsage.php | 164 - .../V1/KeyUsage/ExtendedKeyUsageOptions.php | 263 - .../PrivateCA/V1/KeyUsage/KeyUsageOptions.php | 345 - .../PrivateCA/V1/ListCaPoolsRequest.php | 256 - .../PrivateCA/V1/ListCaPoolsResponse.php | 144 - .../V1/ListCertificateAuthoritiesRequest.php | 265 - .../V1/ListCertificateAuthoritiesResponse.php | 148 - .../ListCertificateRevocationListsRequest.php | 260 - ...ListCertificateRevocationListsResponse.php | 148 - .../V1/ListCertificateTemplatesRequest.php | 260 - .../V1/ListCertificateTemplatesResponse.php | 148 - .../PrivateCA/V1/ListCertificatesRequest.php | 313 - .../PrivateCA/V1/ListCertificatesResponse.php | 144 - .../Cloud/Security/PrivateCA/V1/ObjectId.php | 73 - .../PrivateCA/V1/OperationMetadata.php | 311 - .../Cloud/Security/PrivateCA/V1/PublicKey.php | 106 - .../PrivateCA/V1/PublicKey/KeyFormat.php | 67 - .../V1/RelativeDistinguishedName.php | 69 - .../PrivateCA/V1/RevocationReason.php | 122 - .../PrivateCA/V1/RevokeCertificateRequest.php | 208 - .../Cloud/Security/PrivateCA/V1/Subject.php | 340 - .../Security/PrivateCA/V1/SubjectAltNames.php | 214 - .../PrivateCA/V1/SubjectRequestMode.php | 96 - .../PrivateCA/V1/SubordinateConfig.php | 135 - .../SubordinateConfigChain.php | 68 - .../UndeleteCertificateAuthorityRequest.php | 166 - .../PrivateCA/V1/UpdateCaPoolRequest.php | 216 - .../V1/UpdateCertificateAuthorityRequest.php | 221 - .../PrivateCA/V1/UpdateCertificateRequest.php | 216 - ...UpdateCertificateRevocationListRequest.php | 221 - .../V1/UpdateCertificateTemplateRequest.php | 221 - .../Security/PrivateCA/V1/X509Extension.php | 155 - .../Security/PrivateCA/V1/X509Parameters.php | 302 - .../PrivateCA/V1/X509Parameters/CaOptions.php | 146 - .../V1/X509Parameters/NameConstraints.php | 436 - .../activate_certificate_authority.php | 128 - .../create_ca_pool.php | 97 - .../create_certificate.php | 85 - .../create_certificate_authority.php | 127 - .../create_certificate_template.php | 95 - .../delete_ca_pool.php | 86 - .../delete_certificate_authority.php | 91 - .../delete_certificate_template.php | 87 - .../disable_certificate_authority.php | 91 - .../enable_certificate_authority.php | 91 - .../fetch_ca_certs.php | 80 - .../fetch_certificate_authority_csr.php | 88 - .../get_ca_pool.php | 76 - .../get_certificate.php | 78 - .../get_certificate_authority.php | 80 - .../get_certificate_revocation_list.php | 82 - .../get_certificate_template.php | 79 - .../get_iam_policy.php | 72 - .../get_location.php | 57 - .../list_ca_pools.php | 78 - .../list_certificate_authorities.php | 84 - .../list_certificate_revocation_lists.php | 84 - .../list_certificate_templates.php | 79 - .../list_certificates.php | 91 - .../list_locations.php | 77 - .../revoke_certificate.php | 84 - .../set_iam_policy.php | 77 - .../test_iam_permissions.php | 84 - .../undelete_certificate_authority.php | 92 - .../update_ca_pool.php | 90 - .../update_certificate.php | 67 - .../update_certificate_authority.php | 107 - .../update_certificate_revocation_list.php | 75 - .../update_certificate_template.php | 75 - .../CertificateAuthorityServiceClient.php | 1458 --- .../v1/src/V1/gapic_metadata.json | 188 - ...icate_authority_service_client_config.json | 206 - ...te_authority_service_descriptor_config.php | 600 -- ...e_authority_service_rest_client_config.php | 534 -- .../CertificateAuthorityServiceClientTest.php | 3513 ------- .../Api/Servicemanagement/V1/Resources.php | 27 - .../Servicemanagement/V1/Servicemanager.php | 32 - .../ServiceManagement/V1/ChangeReport.php | 85 - .../Cloud/ServiceManagement/V1/ConfigFile.php | 135 - .../V1/ConfigFile/FileType.php | 88 - .../Cloud/ServiceManagement/V1/ConfigRef.php | 71 - .../ServiceManagement/V1/ConfigSource.php | 114 - .../V1/CreateServiceConfigRequest.php | 136 - .../V1/CreateServiceRequest.php | 90 - .../V1/CreateServiceRolloutRequest.php | 136 - .../V1/DeleteServiceRequest.php | 90 - .../Cloud/ServiceManagement/V1/Diagnostic.php | 135 - .../ServiceManagement/V1/Diagnostic/Kind.php | 54 - .../V1/EnableServiceResponse.php | 33 - .../V1/GenerateConfigReportRequest.php | 176 - .../V1/GenerateConfigReportResponse.php | 181 - .../V1/GetServiceConfigRequest.php | 179 - .../V1/GetServiceConfigRequest/ConfigView.php | 55 - .../V1/GetServiceRequest.php | 85 - .../V1/GetServiceRolloutRequest.php | 126 - .../V1/ListServiceConfigsRequest.php | 162 - .../V1/ListServiceConfigsResponse.php | 101 - .../V1/ListServiceRolloutsRequest.php | 235 - .../V1/ListServiceRolloutsResponse.php | 101 - .../V1/ListServicesRequest.php | 215 - .../V1/ListServicesResponse.php | 101 - .../ServiceManagement/V1/ManagedService.php | 110 - .../V1/OperationMetadata.php | 183 - .../V1/OperationMetadata/Status.php | 83 - .../V1/OperationMetadata/Step.php | 101 - .../Cloud/ServiceManagement/V1/Rollout.php | 332 - .../V1/Rollout/DeleteServiceStrategy.php | 34 - .../V1/Rollout/RolloutStatus.php | 91 - .../V1/Rollout/TrafficPercentStrategy.php | 100 - .../V1/SubmitConfigSourceRequest.php | 182 - .../V1/SubmitConfigSourceResponse.php | 77 - .../V1/UndeleteServiceRequest.php | 90 - .../V1/UndeleteServiceResponse.php | 77 - .../ServiceManagerClient/create_service.php | 81 - .../create_service_config.php | 81 - .../create_service_rollout.php | 99 - .../ServiceManagerClient/delete_service.php | 88 - .../generate_config_report.php | 70 - .../ServiceManagerClient/get_iam_policy.php | 72 - .../V1/ServiceManagerClient/get_service.php | 72 - .../get_service_config.php | 78 - .../get_service_rollout.php | 76 - .../list_service_configs.php | 78 - .../list_service_rollouts.php | 90 - .../V1/ServiceManagerClient/list_services.php | 66 - .../ServiceManagerClient/set_iam_policy.php | 77 - .../submit_config_source.php | 100 - .../test_iam_permissions.php | 84 - .../ServiceManagerClient/undelete_service.php | 89 - .../v1/src/V1/Client/ServiceManagerClient.php | 775 -- .../v1/src/V1/gapic_metadata.json | 98 - .../service_manager_client_config.json | 112 - .../service_manager_descriptor_config.php | 270 - .../service_manager_rest_client_config.php | 240 - .../V1/Client/ServiceManagerClientTest.php | 1566 --- .../Google/Cloud/Speech/V2/CloudSpeech.php | 34 - .../Cloud/Speech/V2/LocationsMetadata.php | 24 - .../Google/Cloud/Speech/V2/AccessMetadata.php | 68 - .../V2/AccessMetadata/ConstraintType.php | 55 - .../Speech/V2/AutoDetectDecodingConfig.php | 46 - .../Speech/V2/BatchRecognizeFileMetadata.php | 239 - .../Speech/V2/BatchRecognizeFileResult.php | 306 - .../Speech/V2/BatchRecognizeMetadata.php | 68 - .../Cloud/Speech/V2/BatchRecognizeRequest.php | 394 - .../ProcessingStrategy.php | 56 - .../Speech/V2/BatchRecognizeResponse.php | 113 - .../Cloud/Speech/V2/BatchRecognizeResults.php | 117 - .../BatchRecognizeTranscriptionMetadata.php | 146 - .../Cloud/Speech/V2/CloudStorageResult.php | 143 - .../src/Google/Cloud/Speech/V2/Config.php | 175 - .../Speech/V2/CreateCustomClassRequest.php | 223 - .../Speech/V2/CreatePhraseSetRequest.php | 223 - .../Speech/V2/CreateRecognizerRequest.php | 223 - .../Google/Cloud/Speech/V2/CustomClass.php | 607 -- .../Cloud/Speech/V2/CustomClass/ClassItem.php | 67 - .../Cloud/Speech/V2/CustomClass/State.php | 62 - .../Cloud/Speech/V2/CustomPromptConfig.php | 71 - .../Speech/V2/DeleteCustomClassRequest.php | 210 - .../Speech/V2/DeletePhraseSetRequest.php | 205 - .../Speech/V2/DeleteRecognizerRequest.php | 205 - .../Google/Cloud/Speech/V2/DenoiserConfig.php | 118 - .../Speech/V2/ExplicitDecodingConfig.php | 167 - .../ExplicitDecodingConfig/AudioEncoding.php | 131 - .../Cloud/Speech/V2/GcsOutputConfig.php | 71 - .../Cloud/Speech/V2/GetConfigRequest.php | 92 - .../Cloud/Speech/V2/GetCustomClassRequest.php | 87 - .../Cloud/Speech/V2/GetPhraseSetRequest.php | 87 - .../Cloud/Speech/V2/GetRecognizerRequest.php | 87 - .../Cloud/Speech/V2/InlineOutputConfig.php | 33 - .../Google/Cloud/Speech/V2/InlineResult.php | 153 - .../Cloud/Speech/V2/LanguageMetadata.php | 68 - .../Speech/V2/ListCustomClassesRequest.php | 221 - .../Speech/V2/ListCustomClassesResponse.php | 114 - .../Cloud/Speech/V2/ListPhraseSetsRequest.php | 217 - .../Speech/V2/ListPhraseSetsResponse.php | 114 - .../Speech/V2/ListRecognizersRequest.php | 217 - .../Speech/V2/ListRecognizersResponse.php | 114 - .../Cloud/Speech/V2/LocationsMetadata.php | 126 - .../Google/Cloud/Speech/V2/ModelFeature.php | 102 - .../Google/Cloud/Speech/V2/ModelFeatures.php | 67 - .../Google/Cloud/Speech/V2/ModelMetadata.php | 68 - .../V2/NativeOutputFileFormatConfig.php | 33 - .../Cloud/Speech/V2/OperationMetadata.php | 841 -- .../Cloud/Speech/V2/OutputFormatConfig.php | 181 - .../src/Google/Cloud/Speech/V2/PhraseSet.php | 657 -- .../Cloud/Speech/V2/PhraseSet/Phrase.php | 143 - .../Cloud/Speech/V2/PhraseSet/State.php | 62 - .../Cloud/Speech/V2/RecognitionConfig.php | 487 - .../Cloud/Speech/V2/RecognitionFeatures.php | 473 - .../RecognitionFeatures/MultiChannelMode.php | 58 - .../Speech/V2/RecognitionOutputConfig.php | 171 - .../Speech/V2/RecognitionResponseMetadata.php | 159 - .../Cloud/Speech/V2/RecognizeRequest.php | 434 - .../Cloud/Speech/V2/RecognizeResponse.php | 116 - .../src/Google/Cloud/Speech/V2/Recognizer.php | 799 -- .../Cloud/Speech/V2/Recognizer/State.php | 61 - .../Speech/V2/SpeakerDiarizationConfig.php | 109 - .../Cloud/Speech/V2/SpeechAdaptation.php | 107 - .../SpeechAdaptation/AdaptationPhraseSet.php | 112 - .../V2/SpeechRecognitionAlternative.php | 175 - .../Speech/V2/SpeechRecognitionResult.php | 211 - .../Speech/V2/SrtOutputFileFormatConfig.php | 35 - .../Speech/V2/StreamingRecognitionConfig.php | 237 - .../V2/StreamingRecognitionFeatures.php | 199 - .../EndpointingSensitivity.php | 75 - .../VoiceActivityTimeout.php | 137 - .../Speech/V2/StreamingRecognitionResult.php | 320 - .../Speech/V2/StreamingRecognizeRequest.php | 180 - .../Speech/V2/StreamingRecognizeResponse.php | 247 - .../SpeechEventType.php | 79 - .../Speech/V2/TranscriptNormalization.php | 82 - .../V2/TranscriptNormalization/Entry.php | 135 - .../Cloud/Speech/V2/TranslationConfig.php | 68 - .../Speech/V2/UndeleteCustomClassRequest.php | 173 - .../Speech/V2/UndeletePhraseSetRequest.php | 168 - .../Speech/V2/UndeleteRecognizerRequest.php | 168 - .../Cloud/Speech/V2/UpdateConfigRequest.php | 148 - .../Speech/V2/UpdateCustomClassRequest.php | 196 - .../Speech/V2/UpdatePhraseSetRequest.php | 191 - .../Speech/V2/UpdateRecognizerRequest.php | 191 - .../Speech/V2/VttOutputFileFormatConfig.php | 34 - .../src/Google/Cloud/Speech/V2/WordInfo.php | 307 - .../V2/SpeechClient/batch_recognize.php | 88 - .../V2/SpeechClient/create_custom_class.php | 86 - .../V2/SpeechClient/create_phrase_set.php | 86 - .../V2/SpeechClient/create_recognizer.php | 86 - .../V2/SpeechClient/delete_custom_class.php | 85 - .../V2/SpeechClient/delete_phrase_set.php | 84 - .../V2/SpeechClient/delete_recognizer.php | 84 - .../v2/samples/V2/SpeechClient/get_config.php | 73 - .../V2/SpeechClient/get_custom_class.php | 73 - .../samples/V2/SpeechClient/get_location.php | 57 - .../V2/SpeechClient/get_phrase_set.php | 73 - .../V2/SpeechClient/get_recognizer.php | 75 - .../V2/SpeechClient/list_custom_classes.php | 77 - .../V2/SpeechClient/list_locations.php | 69 - .../V2/SpeechClient/list_phrase_sets.php | 77 - .../V2/SpeechClient/list_recognizers.php | 77 - .../v2/samples/V2/SpeechClient/recognize.php | 75 - .../V2/SpeechClient/streaming_recognize.php | 81 - .../V2/SpeechClient/undelete_custom_class.php | 85 - .../V2/SpeechClient/undelete_phrase_set.php | 84 - .../V2/SpeechClient/undelete_recognizer.php | 84 - .../samples/V2/SpeechClient/update_config.php | 59 - .../V2/SpeechClient/update_custom_class.php | 71 - .../V2/SpeechClient/update_phrase_set.php | 71 - .../V2/SpeechClient/update_recognizer.php | 71 - .../Speech/v2/src/V2/Client/SpeechClient.php | 1120 --- .../Speech/v2/src/V2/gapic_metadata.json | 143 - .../V2/resources/speech_client_config.json | 158 - .../V2/resources/speech_descriptor_config.php | 461 - .../resources/speech_rest_client_config.php | 358 - .../tests/Unit/V2/Client/SpeechClientTest.php | 2801 ------ .../Google/Cloud/Vectorsearch/V1/Common.php | 24 - .../Cloud/Vectorsearch/V1/DataObject.php | 28 - .../V1/DataObjectSearchService.php | 32 - .../Vectorsearch/V1/DataObjectService.php | 31 - .../Cloud/Vectorsearch/V1/EmbeddingConfig.php | 25 - .../Cloud/Vectorsearch/V1/EncryptionSpec.php | 26 - .../Vectorsearch/V1/VectorsearchService.php | 38 - .../V1/AggregateDataObjectsRequest.php | 154 - .../V1/AggregateDataObjectsResponse.php | 68 - .../VectorSearch/V1/AggregationMethod.php | 54 - .../V1/BatchCreateDataObjectsRequest.php | 118 - .../V1/BatchCreateDataObjectsResponse.php | 68 - .../V1/BatchDeleteDataObjectsRequest.php | 128 - .../V1/BatchSearchDataObjectsRequest.php | 149 - .../CombineResultsOptions.php | 159 - .../V1/BatchSearchDataObjectsResponse.php | 71 - .../V1/BatchUpdateDataObjectsRequest.php | 138 - .../V1/BatchUpdateDataObjectsResponse.php | 34 - .../Cloud/VectorSearch/V1/Collection.php | 411 - .../V1/CreateCollectionRequest.php | 257 - .../V1/CreateDataObjectRequest.php | 189 - .../VectorSearch/V1/CreateIndexRequest.php | 267 - .../Cloud/VectorSearch/V1/DataObject.php | 317 - .../V1/DedicatedInfrastructure.php | 121 - .../AutoscalingSpec.php | 125 - .../V1/DedicatedInfrastructure/Mode.php | 61 - .../V1/DeleteCollectionRequest.php | 155 - .../V1/DeleteDataObjectRequest.php | 134 - .../VectorSearch/V1/DeleteIndexRequest.php | 165 - .../Cloud/VectorSearch/V1/DenseScannIndex.php | 67 - .../V1/DenseScannIndex/FeatureNormType.php | 61 - .../Cloud/VectorSearch/V1/DenseVector.php | 67 - .../VectorSearch/V1/DenseVectorField.php | 115 - .../Cloud/VectorSearch/V1/DistanceMetric.php | 61 - .../VectorSearch/V1/EmbeddingTaskType.php | 103 - .../Cloud/VectorSearch/V1/EncryptionSpec.php | 80 - .../V1/ExportDataObjectsMetadata.php | 121 - .../V1/ExportDataObjectsRequest.php | 118 - .../GcsExportDestination.php | 105 - .../GcsExportDestination/Format.php | 54 - .../V1/ExportDataObjectsResponse.php | 33 - .../VectorSearch/V1/GetCollectionRequest.php | 81 - .../VectorSearch/V1/GetDataObjectRequest.php | 92 - .../Cloud/VectorSearch/V1/GetIndexRequest.php | 81 - .../V1/ImportDataObjectsMetadata.php | 190 - .../V1/ImportDataObjectsRequest.php | 114 - .../GcsImportConfig.php | 151 - .../V1/ImportDataObjectsResponse.php | 78 - .../Google/Cloud/VectorSearch/V1/Index.php | 489 - .../V1/ListCollectionsRequest.php | 221 - .../V1/ListCollectionsResponse.php | 135 - .../VectorSearch/V1/ListIndexesRequest.php | 221 - .../VectorSearch/V1/ListIndexesResponse.php | 101 - .../VectorSearch/V1/OperationMetadata.php | 311 - .../Cloud/VectorSearch/V1/OutputFields.php | 135 - .../V1/QueryDataObjectsRequest.php | 256 - .../V1/QueryDataObjectsResponse.php | 110 - .../Google/Cloud/VectorSearch/V1/Ranker.php | 75 - .../VectorSearch/V1/ReciprocalRankFusion.php | 67 - .../Google/Cloud/VectorSearch/V1/Search.php | 141 - .../V1/SearchDataObjectsRequest.php | 275 - .../V1/SearchDataObjectsResponse.php | 109 - .../Cloud/VectorSearch/V1/SearchHint.php | 111 - .../VectorSearch/V1/SearchHint/IndexHint.php | 79 - .../VectorSearch/V1/SearchHint/KnnHint.php | 34 - .../Cloud/VectorSearch/V1/SearchResult.php | 125 - .../Cloud/VectorSearch/V1/SemanticSearch.php | 327 - .../Cloud/VectorSearch/V1/SparseVector.php | 101 - .../VectorSearch/V1/SparseVectorField.php | 33 - .../Cloud/VectorSearch/V1/TextSearch.php | 237 - .../V1/UpdateCollectionRequest.php | 282 - .../V1/UpdateDataObjectRequest.php | 142 - .../VectorSearch/V1/UpdateIndexRequest.php | 272 - .../Google/Cloud/VectorSearch/V1/Vector.php | 108 - .../Cloud/VectorSearch/V1/VectorField.php | 108 - .../Cloud/VectorSearch/V1/VectorSearch.php | 368 - .../VectorSearch/V1/VertexEmbeddingConfig.php | 152 - .../aggregate_data_objects.php | 80 - .../batch_search_data_objects.php | 79 - .../get_location.php | 57 - .../list_locations.php | 78 - .../query_data_objects.php | 81 - .../search_data_objects.php | 81 - .../batch_create_data_objects.php | 104 - .../batch_delete_data_objects.php | 91 - .../batch_update_data_objects.php | 85 - .../create_data_object.php | 85 - .../delete_data_object.php | 76 - .../get_data_object.php | 78 - .../DataObjectServiceClient/get_location.php | 57 - .../list_locations.php | 78 - .../update_data_object.php | 59 - .../create_collection.php | 92 - .../create_index.php | 104 - .../delete_collection.php | 84 - .../delete_index.php | 87 - .../export_data_objects.php | 89 - .../get_collection.php | 75 - .../VectorSearchServiceClient/get_index.php | 76 - .../get_location.php | 57 - .../import_data_objects.php | 88 - .../list_collections.php | 76 - .../list_indexes.php | 80 - .../list_locations.php | 78 - .../update_collection.php | 71 - .../update_index.php | 84 - .../Client/DataObjectSearchServiceClient.php | 441 - .../src/V1/Client/DataObjectServiceClient.php | 520 - .../V1/Client/VectorSearchServiceClient.php | 762 -- .../v1/src/V1/gapic_metadata.json | 181 - ...a_object_search_service_client_config.json | 64 - ...bject_search_service_descriptor_config.php | 130 - ...ject_search_service_rest_client_config.php | 148 - .../data_object_service_client_config.json | 103 - .../data_object_service_descriptor_config.php | 151 - ...data_object_service_rest_client_config.php | 186 - .../vector_search_service_client_config.json | 116 - ...ector_search_service_descriptor_config.php | 286 - ...ctor_search_service_rest_client_config.php | 246 - .../DataObjectSearchServiceClientTest.php | 510 - .../V1/Client/DataObjectServiceClientTest.php | 710 -- .../Client/VectorSearchServiceClientTest.php | 1599 ---- .../Cloud/Vmwareengine/V1/Vmwareengine.php | 34 - .../Vmwareengine/V1/VmwareengineResources.php | 29 - .../VmwareEngine/V1/AutoscalingSettings.php | 240 - .../AutoscalingSettings/AutoscalingPolicy.php | 302 - .../V1/AutoscalingSettings/Thresholds.php | 102 - .../Google/Cloud/VmwareEngine/V1/Cluster.php | 411 - .../Cloud/VmwareEngine/V1/Cluster/State.php | 84 - .../VmwareEngine/V1/CreateClusterRequest.php | 306 - .../V1/CreateExternalAccessRuleRequest.php | 313 - .../V1/CreateExternalAddressRequest.php | 313 - .../V1/CreateHcxActivationKeyRequest.php | 313 - .../V1/CreateLoggingServerRequest.php | 313 - .../CreateManagementDnsZoneBindingRequest.php | 317 - .../V1/CreateNetworkPeeringRequest.php | 308 - .../V1/CreateNetworkPolicyRequest.php | 318 - .../V1/CreatePrivateCloudRequest.php | 306 - .../V1/CreatePrivateConnectionRequest.php | 308 - .../V1/CreateVmwareEngineNetworkRequest.php | 333 - .../Cloud/VmwareEngine/V1/Credentials.php | 101 - .../VmwareEngine/V1/DeleteClusterRequest.php | 140 - .../V1/DeleteExternalAccessRuleRequest.php | 180 - .../V1/DeleteExternalAddressRequest.php | 180 - .../V1/DeleteLoggingServerRequest.php | 180 - .../DeleteManagementDnsZoneBindingRequest.php | 180 - .../V1/DeleteNetworkPeeringRequest.php | 180 - .../V1/DeleteNetworkPolicyRequest.php | 180 - .../V1/DeletePrivateCloudRequest.php | 262 - .../V1/DeletePrivateConnectionRequest.php | 180 - .../V1/DeleteVmwareEngineNetworkRequest.php | 226 - .../VmwareEngine/V1/DnsBindPermission.php | 130 - .../Cloud/VmwareEngine/V1/DnsForwarding.php | 207 - .../V1/DnsForwarding/ForwardingRule.php | 104 - .../VmwareEngine/V1/ExternalAccessRule.php | 620 -- .../V1/ExternalAccessRule/Action.php | 62 - .../V1/ExternalAccessRule/IpRange.php | 156 - .../V1/ExternalAccessRule/State.php | 75 - .../Cloud/VmwareEngine/V1/ExternalAddress.php | 342 - .../VmwareEngine/V1/ExternalAddress/State.php | 75 - ...hNetworkPolicyExternalAddressesRequest.php | 202 - ...NetworkPolicyExternalAddressesResponse.php | 110 - .../VmwareEngine/V1/GetClusterRequest.php | 102 - .../V1/GetDnsBindPermissionRequest.php | 107 - .../V1/GetDnsForwardingRequest.php | 102 - .../V1/GetExternalAccessRuleRequest.php | 102 - .../V1/GetExternalAddressRequest.php | 102 - .../V1/GetHcxActivationKeyRequest.php | 101 - .../V1/GetLoggingServerRequest.php | 102 - .../V1/GetManagementDnsZoneBindingRequest.php | 102 - .../V1/GetNetworkPeeringRequest.php | 102 - .../V1/GetNetworkPolicyRequest.php | 102 - .../Cloud/VmwareEngine/V1/GetNodeRequest.php | 92 - .../VmwareEngine/V1/GetNodeTypeRequest.php | 102 - .../V1/GetPrivateCloudRequest.php | 102 - .../V1/GetPrivateConnectionRequest.php | 102 - .../VmwareEngine/V1/GetSubnetRequest.php | 102 - .../V1/GetVmwareEngineNetworkRequest.php | 102 - .../V1/GrantDnsBindPermissionRequest.php | 241 - .../src/Google/Cloud/VmwareEngine/V1/Hcx.php | 169 - .../Cloud/VmwareEngine/V1/Hcx/State.php | 68 - .../VmwareEngine/V1/HcxActivationKey.php | 236 - .../V1/HcxActivationKey/State.php | 68 - .../VmwareEngine/V1/ListClustersRequest.php | 322 - .../VmwareEngine/V1/ListClustersResponse.php | 144 - .../V1/ListExternalAccessRulesRequest.php | 366 - .../V1/ListExternalAccessRulesResponse.php | 144 - .../V1/ListExternalAddressesRequest.php | 367 - .../V1/ListExternalAddressesResponse.php | 144 - .../V1/ListHcxActivationKeysRequest.php | 203 - .../V1/ListHcxActivationKeysResponse.php | 144 - .../V1/ListLoggingServersRequest.php | 371 - .../V1/ListLoggingServersResponse.php | 144 - .../ListManagementDnsZoneBindingsRequest.php | 371 - .../ListManagementDnsZoneBindingsResponse.php | 144 - .../V1/ListNetworkPeeringsRequest.php | 357 - .../V1/ListNetworkPeeringsResponse.php | 140 - .../V1/ListNetworkPoliciesRequest.php | 361 - .../V1/ListNetworkPoliciesResponse.php | 144 - .../VmwareEngine/V1/ListNodeTypesRequest.php | 312 - .../VmwareEngine/V1/ListNodeTypesResponse.php | 144 - .../VmwareEngine/V1/ListNodesRequest.php | 198 - .../VmwareEngine/V1/ListNodesResponse.php | 106 - .../V1/ListPeeringRoutesRequest.php | 239 - .../V1/ListPeeringRoutesResponse.php | 106 - .../V1/ListPrivateCloudsRequest.php | 362 - .../V1/ListPrivateCloudsResponse.php | 144 - ...tPrivateConnectionPeeringRoutesRequest.php | 189 - ...PrivateConnectionPeeringRoutesResponse.php | 106 - .../V1/ListPrivateConnectionsRequest.php | 357 - .../V1/ListPrivateConnectionsResponse.php | 140 - .../VmwareEngine/V1/ListSubnetsRequest.php | 199 - .../VmwareEngine/V1/ListSubnetsResponse.php | 144 - .../V1/ListVmwareEngineNetworksRequest.php | 357 - .../V1/ListVmwareEngineNetworksResponse.php | 140 - .../VmwareEngine/V1/LocationMetadata.php | 69 - .../V1/LocationMetadata/Capability.php | 55 - .../Cloud/VmwareEngine/V1/LoggingServer.php | 349 - .../V1/LoggingServer/Protocol.php | 83 - .../V1/LoggingServer/SourceType.php | 61 - .../V1/ManagementDnsZoneBinding.php | 370 - .../V1/ManagementDnsZoneBinding/State.php | 83 - .../Cloud/VmwareEngine/V1/NetworkConfig.php | 260 - .../Cloud/VmwareEngine/V1/NetworkPeering.php | 775 -- .../V1/NetworkPeering/PeerNetworkType.php | 101 - .../VmwareEngine/V1/NetworkPeering/State.php | 75 - .../Cloud/VmwareEngine/V1/NetworkPolicy.php | 470 - .../V1/NetworkPolicy/NetworkService.php | 109 - .../V1/NetworkPolicy/NetworkService/State.php | 69 - .../src/Google/Cloud/VmwareEngine/V1/Node.php | 299 - .../Cloud/VmwareEngine/V1/Node/State.php | 75 - .../Google/Cloud/VmwareEngine/V1/NodeType.php | 439 - .../VmwareEngine/V1/NodeType/Capability.php | 55 - .../Cloud/VmwareEngine/V1/NodeType/Kind.php | 61 - .../Cloud/VmwareEngine/V1/NodeTypeConfig.php | 113 - .../src/Google/Cloud/VmwareEngine/V1/Nsx.php | 169 - .../Cloud/VmwareEngine/V1/Nsx/State.php | 61 - .../VmwareEngine/V1/OperationMetadata.php | 311 - .../Cloud/VmwareEngine/V1/PeeringRoute.php | 273 - .../V1/PeeringRoute/Direction.php | 61 - .../VmwareEngine/V1/PeeringRoute/Type.php | 69 - .../Cloud/VmwareEngine/V1/Principal.php | 109 - .../Cloud/VmwareEngine/V1/PrivateCloud.php | 637 -- .../V1/PrivateCloud/ManagementCluster.php | 181 - .../VmwareEngine/V1/PrivateCloud/State.php | 91 - .../VmwareEngine/V1/PrivateCloud/Type.php | 65 - .../VmwareEngine/V1/PrivateConnection.php | 604 -- .../V1/PrivateConnection/PeeringState.php | 63 - .../V1/PrivateConnection/RoutingMode.php | 65 - .../V1/PrivateConnection/State.php | 90 - .../V1/PrivateConnection/Type.php | 76 - .../RepairManagementDnsZoneBindingRequest.php | 179 - .../V1/ResetNsxCredentialsRequest.php | 185 - .../V1/ResetVcenterCredentialsRequest.php | 251 - .../V1/RevokeDnsBindPermissionRequest.php | 241 - .../V1/ShowNsxCredentialsRequest.php | 107 - .../V1/ShowVcenterCredentialsRequest.php | 177 - .../V1/StretchedClusterConfig.php | 133 - .../Google/Cloud/VmwareEngine/V1/Subnet.php | 262 - .../Cloud/VmwareEngine/V1/Subnet/State.php | 90 - .../V1/UndeletePrivateCloudRequest.php | 140 - .../VmwareEngine/V1/UpdateClusterRequest.php | 233 - .../V1/UpdateDnsForwardingRequest.php | 235 - .../V1/UpdateExternalAccessRuleRequest.php | 235 - .../V1/UpdateExternalAddressRequest.php | 235 - .../V1/UpdateLoggingServerRequest.php | 235 - .../UpdateManagementDnsZoneBindingRequest.php | 235 - .../V1/UpdateNetworkPeeringRequest.php | 235 - .../V1/UpdateNetworkPolicyRequest.php | 235 - .../V1/UpdatePrivateCloudRequest.php | 195 - .../V1/UpdatePrivateConnectionRequest.php | 235 - .../VmwareEngine/V1/UpdateSubnetRequest.php | 157 - .../V1/UpdateVmwareEngineNetworkRequest.php | 240 - .../Google/Cloud/VmwareEngine/V1/Vcenter.php | 169 - .../Cloud/VmwareEngine/V1/Vcenter/State.php | 61 - .../VmwareEngine/V1/VmwareEngineNetwork.php | 396 - .../V1/VmwareEngineNetwork/State.php | 75 - .../V1/VmwareEngineNetwork/Type.php | 63 - .../V1/VmwareEngineNetwork/VpcNetwork.php | 114 - .../VmwareEngineNetwork/VpcNetwork/Type.php | 73 - .../V1/VmwareEngineClient/create_cluster.php | 111 - .../create_external_access_rule.php | 109 - .../create_external_address.php | 109 - .../create_hcx_activation_key.php | 108 - .../create_logging_server.php | 136 - .../create_management_dns_zone_binding.php | 116 - .../create_network_peering.php | 140 - .../create_network_policy.php | 115 - .../create_private_cloud.php | 139 - .../create_private_connection.php | 150 - .../create_vmware_engine_network.php | 118 - .../V1/VmwareEngineClient/delete_cluster.php | 92 - .../delete_external_access_rule.php | 89 - .../delete_external_address.php | 91 - .../delete_logging_server.php | 89 - .../delete_management_dns_zone_binding.php | 91 - .../delete_network_peering.php | 91 - .../delete_network_policy.php | 90 - .../delete_private_cloud.php | 101 - .../delete_private_connection.php | 90 - .../delete_vmware_engine_network.php | 91 - ...etch_network_policy_external_addresses.php | 85 - .../V1/VmwareEngineClient/get_cluster.php | 80 - .../get_dns_bind_permission.php | 78 - .../VmwareEngineClient/get_dns_forwarding.php | 79 - .../get_external_access_rule.php | 80 - .../get_external_address.php | 80 - .../get_hcx_activation_key.php | 80 - .../V1/VmwareEngineClient/get_iam_policy.php | 72 - .../V1/VmwareEngineClient/get_location.php | 57 - .../VmwareEngineClient/get_logging_server.php | 80 - .../get_management_dns_zone_binding.php | 80 - .../get_network_peering.php | 82 - .../VmwareEngineClient/get_network_policy.php | 79 - .../V1/VmwareEngineClient/get_node.php | 79 - .../V1/VmwareEngineClient/get_node_type.php | 75 - .../VmwareEngineClient/get_private_cloud.php | 75 - .../get_private_connection.php | 81 - .../V1/VmwareEngineClient/get_subnet.php | 80 - .../get_vmware_engine_network.php | 82 - .../grant_dns_bind_permission.php | 94 - .../V1/VmwareEngineClient/list_clusters.php | 84 - .../list_external_access_rules.php | 84 - .../list_external_addresses.php | 86 - .../list_hcx_activation_keys.php | 85 - .../V1/VmwareEngineClient/list_locations.php | 62 - .../list_logging_servers.php | 86 - .../list_management_dns_zone_bindings.php | 85 - .../list_network_peerings.php | 80 - .../list_network_policies.php | 79 - .../V1/VmwareEngineClient/list_node_types.php | 80 - .../V1/VmwareEngineClient/list_nodes.php | 85 - .../list_peering_routes.php | 84 - .../list_private_clouds.php | 80 - ...list_private_connection_peering_routes.php | 83 - .../list_private_connections.php | 79 - .../V1/VmwareEngineClient/list_subnets.php | 85 - .../list_vmware_engine_networks.php | 79 - .../repair_management_dns_zone_binding.php | 93 - .../reset_nsx_credentials.php | 92 - .../reset_vcenter_credentials.php | 92 - .../revoke_dns_bind_permission.php | 93 - .../V1/VmwareEngineClient/set_iam_policy.php | 77 - .../show_nsx_credentials.php | 80 - .../show_vcenter_credentials.php | 80 - .../test_iam_permissions.php | 84 - .../undelete_private_cloud.php | 90 - .../V1/VmwareEngineClient/update_cluster.php | 82 - .../update_dns_forwarding.php | 101 - .../update_external_access_rule.php | 75 - .../update_external_address.php | 80 - .../update_logging_server.php | 110 - .../update_management_dns_zone_binding.php | 75 - .../update_network_peering.php | 118 - .../update_network_policy.php | 101 - .../update_private_cloud.php | 118 - .../update_private_connection.php | 129 - .../V1/VmwareEngineClient/update_subnet.php | 79 - .../update_vmware_engine_network.php | 90 - .../v1/src/V1/Client/VmwareEngineClient.php | 3013 ------ .../v1/src/V1/gapic_metadata.json | 413 - .../vmware_engine_client_config.json | 449 - .../vmware_engine_descriptor_config.php | 1430 --- .../vmware_engine_rest_client_config.php | 1083 --- .../Unit/V1/Client/VmwareEngineClientTest.php | 8496 ----------------- .../Cloud/Workloadmanager/V1/Service.php | 32 - .../Cloud/WorkloadManager/V1/AgentCommand.php | 105 - .../V1/BigQueryDestination.php | 105 - .../Cloud/WorkloadManager/V1/Command.php | 111 - .../V1/CreateEvaluationRequest.php | 242 - .../V1/DeleteEvaluationRequest.php | 193 - .../V1/DeleteExecutionRequest.php | 155 - .../Cloud/WorkloadManager/V1/Evaluation.php | 597 -- .../V1/Evaluation/EvaluationType.php | 68 - .../Cloud/WorkloadManager/V1/Execution.php | 523 - .../WorkloadManager/V1/Execution/Engine.php | 61 - .../V1/Execution/ExternalDataSources.php | 193 - .../V1/Execution/ExternalDataSources/Type.php | 54 - .../WorkloadManager/V1/Execution/Notice.php | 67 - .../WorkloadManager/V1/Execution/State.php | 68 - .../WorkloadManager/V1/Execution/Summary.php | 135 - .../WorkloadManager/V1/Execution/Type.php | 61 - .../WorkloadManager/V1/ExecutionResult.php | 325 - .../V1/ExecutionResult/Type.php | 61 - .../WorkloadManager/V1/GceInstanceFilter.php | 71 - .../V1/GetEvaluationRequest.php | 81 - .../V1/GetExecutionRequest.php | 81 - .../V1/ListEvaluationsRequest.php | 221 - .../V1/ListEvaluationsResponse.php | 135 - .../V1/ListExecutionResultsRequest.php | 191 - .../V1/ListExecutionResultsResponse.php | 105 - .../V1/ListExecutionsRequest.php | 226 - .../V1/ListExecutionsResponse.php | 135 - .../WorkloadManager/V1/ListRulesRequest.php | 274 - .../WorkloadManager/V1/ListRulesResponse.php | 67 - .../V1/ListScannedResourcesRequest.php | 254 - .../V1/ListScannedResourcesResponse.php | 105 - .../WorkloadManager/V1/OperationMetadata.php | 307 - .../Cloud/WorkloadManager/V1/Resource.php | 135 - .../WorkloadManager/V1/ResourceFilter.php | 216 - .../WorkloadManager/V1/ResourceStatus.php | 67 - .../V1/ResourceStatus/State.php | 69 - .../Google/Cloud/WorkloadManager/V1/Rule.php | 479 - .../WorkloadManager/V1/Rule/RuleType.php | 61 - .../V1/RuleExecutionResult.php | 203 - .../V1/RuleExecutionResult/State.php | 68 - .../Cloud/WorkloadManager/V1/RuleOutput.php | 101 - .../V1/RunEvaluationRequest.php | 242 - .../WorkloadManager/V1/ScannedResource.php | 101 - .../Cloud/WorkloadManager/V1/ShellCommand.php | 135 - .../V1/UpdateEvaluationRequest.php | 225 - .../WorkloadManager/V1/ViolationDetails.php | 169 - .../create_evaluation.php | 89 - .../delete_evaluation.php | 80 - .../delete_execution.php | 85 - .../WorkloadManagerClient/get_evaluation.php | 71 - .../WorkloadManagerClient/get_execution.php | 76 - .../V1/WorkloadManagerClient/get_location.php | 57 - .../list_evaluations.php | 76 - .../list_execution_results.php | 76 - .../WorkloadManagerClient/list_executions.php | 77 - .../WorkloadManagerClient/list_locations.php | 69 - .../V1/WorkloadManagerClient/list_rules.php | 74 - .../list_scanned_resources.php | 75 - .../WorkloadManagerClient/run_evaluation.php | 89 - .../update_evaluation.php | 74 - .../src/V1/Client/WorkloadManagerClient.php | 747 -- .../v1/src/V1/gapic_metadata.json | 88 - .../workload_manager_client_config.json | 114 - .../workload_manager_descriptor_config.php | 280 - .../workload_manager_rest_client_config.php | 242 - .../V1/Client/WorkloadManagerClientTest.php | 1444 --- 766 files changed, 220 insertions(+), 142117 deletions(-) delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/GPBMetadata/Google/Cloud/Security/Privateca/V1/Resources.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/GPBMetadata/Google/Cloud/Security/Privateca/V1/Service.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ActivateCertificateAuthorityRequest.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/AttributeType.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/AttributeTypeAndValue.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy/AllowedKeyType.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy/AllowedKeyType/EcKeyType.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy/AllowedKeyType/EcKeyType/EcSignatureAlgorithm.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy/AllowedKeyType/RsaKeyType.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy/IssuanceModes.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/PublishingOptions.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/PublishingOptions/EncodingFormat.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/Tier.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/Certificate.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/Certificate/RevocationDetails.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/AccessUrls.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/KeyVersionSpec.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/SignHashAlgorithm.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/State.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/Type.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/UserDefinedAccessUrls.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateConfig.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateConfig/KeyId.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateConfig/SubjectConfig.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateDescription.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateDescription/CertificateFingerprint.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateDescription/KeyId.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateDescription/SubjectDescription.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateExtensionConstraints.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateExtensionConstraints/KnownCertificateExtension.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateIdentityConstraints.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateRevocationList.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateRevocationList/RevokedCertificate.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateRevocationList/State.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateTemplate.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CreateCaPoolRequest.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CreateCertificateAuthorityRequest.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CreateCertificateRequest.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CreateCertificateTemplateRequest.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/DeleteCaPoolRequest.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/DeleteCertificateAuthorityRequest.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/DeleteCertificateTemplateRequest.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/DisableCertificateAuthorityRequest.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/EnableCertificateAuthorityRequest.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/EncryptionSpec.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/FetchCaCertsRequest.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/FetchCaCertsResponse.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/FetchCaCertsResponse/CertChain.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/FetchCertificateAuthorityCsrRequest.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/FetchCertificateAuthorityCsrResponse.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/GetCaPoolRequest.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/GetCertificateAuthorityRequest.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/GetCertificateRequest.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/GetCertificateRevocationListRequest.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/GetCertificateTemplateRequest.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/KeyUsage.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/KeyUsage/ExtendedKeyUsageOptions.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/KeyUsage/KeyUsageOptions.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCaPoolsRequest.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCaPoolsResponse.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateAuthoritiesRequest.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateAuthoritiesResponse.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateRevocationListsRequest.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateRevocationListsResponse.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateTemplatesRequest.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateTemplatesResponse.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificatesRequest.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificatesResponse.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ObjectId.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/OperationMetadata.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/PublicKey.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/PublicKey/KeyFormat.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/RelativeDistinguishedName.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/RevocationReason.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/RevokeCertificateRequest.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/Subject.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/SubjectAltNames.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/SubjectRequestMode.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/SubordinateConfig.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/SubordinateConfig/SubordinateConfigChain.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UndeleteCertificateAuthorityRequest.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UpdateCaPoolRequest.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UpdateCertificateAuthorityRequest.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UpdateCertificateRequest.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UpdateCertificateRevocationListRequest.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UpdateCertificateTemplateRequest.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/X509Extension.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/X509Parameters.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/X509Parameters/CaOptions.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/X509Parameters/NameConstraints.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/activate_certificate_authority.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/create_ca_pool.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/create_certificate.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/create_certificate_authority.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/create_certificate_template.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/delete_ca_pool.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/delete_certificate_authority.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/delete_certificate_template.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/disable_certificate_authority.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/enable_certificate_authority.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/fetch_ca_certs.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/fetch_certificate_authority_csr.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_ca_pool.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_certificate.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_certificate_authority.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_certificate_revocation_list.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_certificate_template.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_iam_policy.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_location.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_ca_pools.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_certificate_authorities.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_certificate_revocation_lists.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_certificate_templates.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_certificates.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_locations.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/revoke_certificate.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/set_iam_policy.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/test_iam_permissions.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/undelete_certificate_authority.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/update_ca_pool.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/update_certificate.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/update_certificate_authority.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/update_certificate_revocation_list.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/update_certificate_template.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/src/V1/Client/CertificateAuthorityServiceClient.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/src/V1/gapic_metadata.json delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/src/V1/resources/certificate_authority_service_client_config.json delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/src/V1/resources/certificate_authority_service_descriptor_config.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/src/V1/resources/certificate_authority_service_rest_client_config.php delete mode 100644 owl-bot-staging/SecurityPrivateCa/v1/tests/Unit/V1/Client/CertificateAuthorityServiceClientTest.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/GPBMetadata/Google/Api/Servicemanagement/V1/Resources.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/GPBMetadata/Google/Api/Servicemanagement/V1/Servicemanager.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ChangeReport.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ConfigFile.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ConfigFile/FileType.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ConfigRef.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ConfigSource.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/CreateServiceConfigRequest.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/CreateServiceRequest.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/CreateServiceRolloutRequest.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/DeleteServiceRequest.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Diagnostic.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Diagnostic/Kind.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/EnableServiceResponse.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GenerateConfigReportRequest.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GenerateConfigReportResponse.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GetServiceConfigRequest.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GetServiceConfigRequest/ConfigView.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GetServiceRequest.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GetServiceRolloutRequest.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServiceConfigsRequest.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServiceConfigsResponse.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServiceRolloutsRequest.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServiceRolloutsResponse.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServicesRequest.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServicesResponse.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ManagedService.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/OperationMetadata.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/OperationMetadata/Status.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/OperationMetadata/Step.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Rollout.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Rollout/DeleteServiceStrategy.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Rollout/RolloutStatus.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Rollout/TrafficPercentStrategy.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/SubmitConfigSourceRequest.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/SubmitConfigSourceResponse.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/UndeleteServiceRequest.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/UndeleteServiceResponse.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/create_service.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/create_service_config.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/create_service_rollout.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/delete_service.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/generate_config_report.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/get_iam_policy.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/get_service.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/get_service_config.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/get_service_rollout.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/list_service_configs.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/list_service_rollouts.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/list_services.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/set_iam_policy.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/submit_config_source.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/test_iam_permissions.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/undelete_service.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/src/V1/Client/ServiceManagerClient.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/src/V1/gapic_metadata.json delete mode 100644 owl-bot-staging/ServiceManagement/v1/src/V1/resources/service_manager_client_config.json delete mode 100644 owl-bot-staging/ServiceManagement/v1/src/V1/resources/service_manager_descriptor_config.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/src/V1/resources/service_manager_rest_client_config.php delete mode 100644 owl-bot-staging/ServiceManagement/v1/tests/Unit/V1/Client/ServiceManagerClientTest.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/GPBMetadata/Google/Cloud/Speech/V2/CloudSpeech.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/GPBMetadata/Google/Cloud/Speech/V2/LocationsMetadata.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/AccessMetadata.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/AccessMetadata/ConstraintType.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/AutoDetectDecodingConfig.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeFileMetadata.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeFileResult.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeMetadata.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeRequest.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeRequest/ProcessingStrategy.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeResponse.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeResults.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeTranscriptionMetadata.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CloudStorageResult.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/Config.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CreateCustomClassRequest.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CreatePhraseSetRequest.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CreateRecognizerRequest.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CustomClass.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CustomClass/ClassItem.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CustomClass/State.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CustomPromptConfig.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/DeleteCustomClassRequest.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/DeletePhraseSetRequest.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/DeleteRecognizerRequest.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/DenoiserConfig.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ExplicitDecodingConfig.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ExplicitDecodingConfig/AudioEncoding.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/GcsOutputConfig.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/GetConfigRequest.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/GetCustomClassRequest.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/GetPhraseSetRequest.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/GetRecognizerRequest.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/InlineOutputConfig.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/InlineResult.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/LanguageMetadata.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListCustomClassesRequest.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListCustomClassesResponse.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListPhraseSetsRequest.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListPhraseSetsResponse.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListRecognizersRequest.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListRecognizersResponse.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/LocationsMetadata.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ModelFeature.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ModelFeatures.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ModelMetadata.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/NativeOutputFileFormatConfig.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/OperationMetadata.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/OutputFormatConfig.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/PhraseSet.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/PhraseSet/Phrase.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/PhraseSet/State.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognitionConfig.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognitionFeatures.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognitionFeatures/MultiChannelMode.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognitionOutputConfig.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognitionResponseMetadata.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognizeRequest.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognizeResponse.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/Recognizer.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/Recognizer/State.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SpeakerDiarizationConfig.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SpeechAdaptation.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SpeechAdaptation/AdaptationPhraseSet.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SpeechRecognitionAlternative.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SpeechRecognitionResult.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SrtOutputFileFormatConfig.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognitionConfig.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognitionFeatures.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognitionFeatures/EndpointingSensitivity.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognitionFeatures/VoiceActivityTimeout.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognitionResult.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognizeRequest.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognizeResponse.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognizeResponse/SpeechEventType.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/TranscriptNormalization.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/TranscriptNormalization/Entry.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/TranslationConfig.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UndeleteCustomClassRequest.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UndeletePhraseSetRequest.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UndeleteRecognizerRequest.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UpdateConfigRequest.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UpdateCustomClassRequest.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UpdatePhraseSetRequest.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UpdateRecognizerRequest.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/VttOutputFileFormatConfig.php delete mode 100644 owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/WordInfo.php delete mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/batch_recognize.php delete mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/create_custom_class.php delete mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/create_phrase_set.php delete mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/create_recognizer.php delete mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/delete_custom_class.php delete mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/delete_phrase_set.php delete mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/delete_recognizer.php delete mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/get_config.php delete mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/get_custom_class.php delete mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/get_location.php delete mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/get_phrase_set.php delete mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/get_recognizer.php delete mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/list_custom_classes.php delete mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/list_locations.php delete mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/list_phrase_sets.php delete mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/list_recognizers.php delete mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/recognize.php delete mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/streaming_recognize.php delete mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/undelete_custom_class.php delete mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/undelete_phrase_set.php delete mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/undelete_recognizer.php delete mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/update_config.php delete mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/update_custom_class.php delete mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/update_phrase_set.php delete mode 100644 owl-bot-staging/Speech/v2/samples/V2/SpeechClient/update_recognizer.php delete mode 100644 owl-bot-staging/Speech/v2/src/V2/Client/SpeechClient.php delete mode 100644 owl-bot-staging/Speech/v2/src/V2/gapic_metadata.json delete mode 100644 owl-bot-staging/Speech/v2/src/V2/resources/speech_client_config.json delete mode 100644 owl-bot-staging/Speech/v2/src/V2/resources/speech_descriptor_config.php delete mode 100644 owl-bot-staging/Speech/v2/src/V2/resources/speech_rest_client_config.php delete mode 100644 owl-bot-staging/Speech/v2/tests/Unit/V2/Client/SpeechClientTest.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/Common.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/DataObject.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/DataObjectSearchService.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/DataObjectService.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/EmbeddingConfig.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/EncryptionSpec.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/VectorsearchService.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/AggregateDataObjectsRequest.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/AggregateDataObjectsResponse.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/AggregationMethod.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchCreateDataObjectsRequest.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchCreateDataObjectsResponse.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchDeleteDataObjectsRequest.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchSearchDataObjectsRequest.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchSearchDataObjectsRequest/CombineResultsOptions.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchSearchDataObjectsResponse.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchUpdateDataObjectsRequest.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchUpdateDataObjectsResponse.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/Collection.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/CreateCollectionRequest.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/CreateDataObjectRequest.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/CreateIndexRequest.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DataObject.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DedicatedInfrastructure.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DedicatedInfrastructure/AutoscalingSpec.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DedicatedInfrastructure/Mode.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DeleteCollectionRequest.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DeleteDataObjectRequest.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DeleteIndexRequest.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DenseScannIndex.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DenseScannIndex/FeatureNormType.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DenseVector.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DenseVectorField.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DistanceMetric.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/EmbeddingTaskType.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/EncryptionSpec.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ExportDataObjectsMetadata.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ExportDataObjectsRequest.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ExportDataObjectsRequest/GcsExportDestination.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ExportDataObjectsRequest/GcsExportDestination/Format.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ExportDataObjectsResponse.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/GetCollectionRequest.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/GetDataObjectRequest.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/GetIndexRequest.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ImportDataObjectsMetadata.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ImportDataObjectsRequest.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ImportDataObjectsRequest/GcsImportConfig.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ImportDataObjectsResponse.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/Index.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ListCollectionsRequest.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ListCollectionsResponse.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ListIndexesRequest.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ListIndexesResponse.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/OperationMetadata.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/OutputFields.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/QueryDataObjectsRequest.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/QueryDataObjectsResponse.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/Ranker.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ReciprocalRankFusion.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/Search.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchDataObjectsRequest.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchDataObjectsResponse.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchHint.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchHint/IndexHint.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchHint/KnnHint.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchResult.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SemanticSearch.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SparseVector.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SparseVectorField.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/TextSearch.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/UpdateCollectionRequest.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/UpdateDataObjectRequest.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/UpdateIndexRequest.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/Vector.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/VectorField.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/VectorSearch.php delete mode 100644 owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/VertexEmbeddingConfig.php delete mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/aggregate_data_objects.php delete mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/batch_search_data_objects.php delete mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/get_location.php delete mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/list_locations.php delete mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/query_data_objects.php delete mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/search_data_objects.php delete mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/batch_create_data_objects.php delete mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/batch_delete_data_objects.php delete mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/batch_update_data_objects.php delete mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/create_data_object.php delete mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/delete_data_object.php delete mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/get_data_object.php delete mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/get_location.php delete mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/list_locations.php delete mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/update_data_object.php delete mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/create_collection.php delete mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/create_index.php delete mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/delete_collection.php delete mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/delete_index.php delete mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/export_data_objects.php delete mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/get_collection.php delete mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/get_index.php delete mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/get_location.php delete mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/import_data_objects.php delete mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/list_collections.php delete mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/list_indexes.php delete mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/list_locations.php delete mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/update_collection.php delete mode 100644 owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/update_index.php delete mode 100644 owl-bot-staging/VectorSearch/v1/src/V1/Client/DataObjectSearchServiceClient.php delete mode 100644 owl-bot-staging/VectorSearch/v1/src/V1/Client/DataObjectServiceClient.php delete mode 100644 owl-bot-staging/VectorSearch/v1/src/V1/Client/VectorSearchServiceClient.php delete mode 100644 owl-bot-staging/VectorSearch/v1/src/V1/gapic_metadata.json delete mode 100644 owl-bot-staging/VectorSearch/v1/src/V1/resources/data_object_search_service_client_config.json delete mode 100644 owl-bot-staging/VectorSearch/v1/src/V1/resources/data_object_search_service_descriptor_config.php delete mode 100644 owl-bot-staging/VectorSearch/v1/src/V1/resources/data_object_search_service_rest_client_config.php delete mode 100644 owl-bot-staging/VectorSearch/v1/src/V1/resources/data_object_service_client_config.json delete mode 100644 owl-bot-staging/VectorSearch/v1/src/V1/resources/data_object_service_descriptor_config.php delete mode 100644 owl-bot-staging/VectorSearch/v1/src/V1/resources/data_object_service_rest_client_config.php delete mode 100644 owl-bot-staging/VectorSearch/v1/src/V1/resources/vector_search_service_client_config.json delete mode 100644 owl-bot-staging/VectorSearch/v1/src/V1/resources/vector_search_service_descriptor_config.php delete mode 100644 owl-bot-staging/VectorSearch/v1/src/V1/resources/vector_search_service_rest_client_config.php delete mode 100644 owl-bot-staging/VectorSearch/v1/tests/Unit/V1/Client/DataObjectSearchServiceClientTest.php delete mode 100644 owl-bot-staging/VectorSearch/v1/tests/Unit/V1/Client/DataObjectServiceClientTest.php delete mode 100644 owl-bot-staging/VectorSearch/v1/tests/Unit/V1/Client/VectorSearchServiceClientTest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/GPBMetadata/Google/Cloud/Vmwareengine/V1/Vmwareengine.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/GPBMetadata/Google/Cloud/Vmwareengine/V1/VmwareengineResources.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/AutoscalingSettings.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/AutoscalingSettings/AutoscalingPolicy.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/AutoscalingSettings/Thresholds.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Cluster.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Cluster/State.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateClusterRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateExternalAccessRuleRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateExternalAddressRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateHcxActivationKeyRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateLoggingServerRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateManagementDnsZoneBindingRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateNetworkPeeringRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateNetworkPolicyRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreatePrivateCloudRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreatePrivateConnectionRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateVmwareEngineNetworkRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Credentials.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteClusterRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteExternalAccessRuleRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteExternalAddressRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteLoggingServerRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteManagementDnsZoneBindingRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteNetworkPeeringRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteNetworkPolicyRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeletePrivateCloudRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeletePrivateConnectionRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteVmwareEngineNetworkRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DnsBindPermission.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DnsForwarding.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DnsForwarding/ForwardingRule.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAccessRule.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAccessRule/Action.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAccessRule/IpRange.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAccessRule/State.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAddress.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAddress/State.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/FetchNetworkPolicyExternalAddressesRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/FetchNetworkPolicyExternalAddressesResponse.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetClusterRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetDnsBindPermissionRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetDnsForwardingRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetExternalAccessRuleRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetExternalAddressRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetHcxActivationKeyRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetLoggingServerRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetManagementDnsZoneBindingRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetNetworkPeeringRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetNetworkPolicyRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetNodeRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetNodeTypeRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetPrivateCloudRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetPrivateConnectionRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetSubnetRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetVmwareEngineNetworkRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GrantDnsBindPermissionRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Hcx.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Hcx/State.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/HcxActivationKey.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/HcxActivationKey/State.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListClustersRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListClustersResponse.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListExternalAccessRulesRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListExternalAccessRulesResponse.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListExternalAddressesRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListExternalAddressesResponse.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListHcxActivationKeysRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListHcxActivationKeysResponse.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListLoggingServersRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListLoggingServersResponse.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListManagementDnsZoneBindingsRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListManagementDnsZoneBindingsResponse.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNetworkPeeringsRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNetworkPeeringsResponse.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNetworkPoliciesRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNetworkPoliciesResponse.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNodeTypesRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNodeTypesResponse.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNodesRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNodesResponse.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPeeringRoutesRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPeeringRoutesResponse.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateCloudsRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateCloudsResponse.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateConnectionPeeringRoutesRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateConnectionPeeringRoutesResponse.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateConnectionsRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateConnectionsResponse.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListSubnetsRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListSubnetsResponse.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListVmwareEngineNetworksRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListVmwareEngineNetworksResponse.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/LocationMetadata.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/LocationMetadata/Capability.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/LoggingServer.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/LoggingServer/Protocol.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/LoggingServer/SourceType.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ManagementDnsZoneBinding.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ManagementDnsZoneBinding/State.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkConfig.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPeering.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPeering/PeerNetworkType.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPeering/State.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPolicy.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPolicy/NetworkService.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPolicy/NetworkService/State.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Node.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Node/State.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NodeType.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NodeType/Capability.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NodeType/Kind.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NodeTypeConfig.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Nsx.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Nsx/State.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/OperationMetadata.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PeeringRoute.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PeeringRoute/Direction.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PeeringRoute/Type.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Principal.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateCloud.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateCloud/ManagementCluster.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateCloud/State.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateCloud/Type.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateConnection.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateConnection/PeeringState.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateConnection/RoutingMode.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateConnection/State.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateConnection/Type.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/RepairManagementDnsZoneBindingRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ResetNsxCredentialsRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ResetVcenterCredentialsRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/RevokeDnsBindPermissionRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ShowNsxCredentialsRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ShowVcenterCredentialsRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/StretchedClusterConfig.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Subnet.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Subnet/State.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UndeletePrivateCloudRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateClusterRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateDnsForwardingRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateExternalAccessRuleRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateExternalAddressRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateLoggingServerRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateManagementDnsZoneBindingRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateNetworkPeeringRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateNetworkPolicyRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdatePrivateCloudRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdatePrivateConnectionRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateSubnetRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateVmwareEngineNetworkRequest.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Vcenter.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Vcenter/State.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/VmwareEngineNetwork.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/VmwareEngineNetwork/State.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/VmwareEngineNetwork/Type.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/VmwareEngineNetwork/VpcNetwork.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/VmwareEngineNetwork/VpcNetwork/Type.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_cluster.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_external_access_rule.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_external_address.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_hcx_activation_key.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_logging_server.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_management_dns_zone_binding.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_network_peering.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_network_policy.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_private_cloud.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_private_connection.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_vmware_engine_network.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_cluster.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_external_access_rule.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_external_address.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_logging_server.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_management_dns_zone_binding.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_network_peering.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_network_policy.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_private_cloud.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_private_connection.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_vmware_engine_network.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/fetch_network_policy_external_addresses.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_cluster.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_dns_bind_permission.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_dns_forwarding.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_external_access_rule.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_external_address.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_hcx_activation_key.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_iam_policy.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_location.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_logging_server.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_management_dns_zone_binding.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_network_peering.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_network_policy.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_node.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_node_type.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_private_cloud.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_private_connection.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_subnet.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_vmware_engine_network.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/grant_dns_bind_permission.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_clusters.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_external_access_rules.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_external_addresses.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_hcx_activation_keys.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_locations.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_logging_servers.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_management_dns_zone_bindings.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_network_peerings.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_network_policies.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_node_types.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_nodes.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_peering_routes.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_private_clouds.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_private_connection_peering_routes.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_private_connections.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_subnets.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_vmware_engine_networks.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/repair_management_dns_zone_binding.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/reset_nsx_credentials.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/reset_vcenter_credentials.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/revoke_dns_bind_permission.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/set_iam_policy.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/show_nsx_credentials.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/show_vcenter_credentials.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/test_iam_permissions.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/undelete_private_cloud.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_cluster.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_dns_forwarding.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_external_access_rule.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_external_address.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_logging_server.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_management_dns_zone_binding.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_network_peering.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_network_policy.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_private_cloud.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_private_connection.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_subnet.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_vmware_engine_network.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/src/V1/Client/VmwareEngineClient.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/src/V1/gapic_metadata.json delete mode 100644 owl-bot-staging/VmwareEngine/v1/src/V1/resources/vmware_engine_client_config.json delete mode 100644 owl-bot-staging/VmwareEngine/v1/src/V1/resources/vmware_engine_descriptor_config.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/src/V1/resources/vmware_engine_rest_client_config.php delete mode 100644 owl-bot-staging/VmwareEngine/v1/tests/Unit/V1/Client/VmwareEngineClientTest.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/GPBMetadata/Google/Cloud/Workloadmanager/V1/Service.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/AgentCommand.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/BigQueryDestination.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Command.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/CreateEvaluationRequest.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/DeleteEvaluationRequest.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/DeleteExecutionRequest.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Evaluation.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Evaluation/EvaluationType.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/Engine.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/ExternalDataSources.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/ExternalDataSources/Type.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/Notice.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/State.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/Summary.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/Type.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ExecutionResult.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ExecutionResult/Type.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/GceInstanceFilter.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/GetEvaluationRequest.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/GetExecutionRequest.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListEvaluationsRequest.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListEvaluationsResponse.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListExecutionResultsRequest.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListExecutionResultsResponse.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListExecutionsRequest.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListExecutionsResponse.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListRulesRequest.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListRulesResponse.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListScannedResourcesRequest.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListScannedResourcesResponse.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/OperationMetadata.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Resource.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ResourceFilter.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ResourceStatus.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ResourceStatus/State.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Rule.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Rule/RuleType.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/RuleExecutionResult.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/RuleExecutionResult/State.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/RuleOutput.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/RunEvaluationRequest.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ScannedResource.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ShellCommand.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/UpdateEvaluationRequest.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ViolationDetails.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/create_evaluation.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/delete_evaluation.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/delete_execution.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/get_evaluation.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/get_execution.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/get_location.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_evaluations.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_execution_results.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_executions.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_locations.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_rules.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_scanned_resources.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/run_evaluation.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/update_evaluation.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/src/V1/Client/WorkloadManagerClient.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/src/V1/gapic_metadata.json delete mode 100644 owl-bot-staging/WorkloadManager/v1/src/V1/resources/workload_manager_client_config.json delete mode 100644 owl-bot-staging/WorkloadManager/v1/src/V1/resources/workload_manager_descriptor_config.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/src/V1/resources/workload_manager_rest_client_config.php delete mode 100644 owl-bot-staging/WorkloadManager/v1/tests/Unit/V1/Client/WorkloadManagerClientTest.php diff --git a/SecurityPrivateCa/samples/V1/CertificateAuthorityServiceClient/get_iam_policy.php b/SecurityPrivateCa/samples/V1/CertificateAuthorityServiceClient/get_iam_policy.php index 6a2662762175..8a5dfd28f679 100644 --- a/SecurityPrivateCa/samples/V1/CertificateAuthorityServiceClient/get_iam_policy.php +++ b/SecurityPrivateCa/samples/V1/CertificateAuthorityServiceClient/get_iam_policy.php @@ -30,7 +30,7 @@ /** * Gets the access control policy for a resource. Returns an empty policy -if the resource exists and does not have a policy set. + * if the resource exists and does not have a policy set. * * @param string $resource REQUIRED: The resource for which the policy is being requested. * See the operation documentation for the appropriate value for this field. diff --git a/SecurityPrivateCa/samples/V1/CertificateAuthorityServiceClient/list_locations.php b/SecurityPrivateCa/samples/V1/CertificateAuthorityServiceClient/list_locations.php index 2935ae88781d..78730c821433 100644 --- a/SecurityPrivateCa/samples/V1/CertificateAuthorityServiceClient/list_locations.php +++ b/SecurityPrivateCa/samples/V1/CertificateAuthorityServiceClient/list_locations.php @@ -31,21 +31,21 @@ /** * Lists information about the supported locations for this service. - -This method lists locations based on the resource scope provided in -the [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: * -**Global locations**: If `name` is empty, the method lists the -public locations available to all projects. * **Project-specific -locations**: If `name` follows the format -`projects/{project}`, the method lists locations visible to that -specific project. This includes public, private, or other -project-specific locations enabled for the project. - -For gRPC and client library implementations, the resource name is -passed as the `name` field. For direct service calls, the resource -name is -incorporated into the request path based on the specific service -implementation and version. + * + * This method lists locations based on the resource scope provided in + * the [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: * + * **Global locations**: If `name` is empty, the method lists the + * public locations available to all projects. * **Project-specific + * locations**: If `name` follows the format + * `projects/{project}`, the method lists locations visible to that + * specific project. This includes public, private, or other + * project-specific locations enabled for the project. + * + * For gRPC and client library implementations, the resource name is + * passed as the `name` field. For direct service calls, the resource + * name is + * incorporated into the request path based on the specific service + * implementation and version. * * This sample has been automatically generated and should be regarded as a code * template only. It will require modifications to work: diff --git a/SecurityPrivateCa/samples/V1/CertificateAuthorityServiceClient/set_iam_policy.php b/SecurityPrivateCa/samples/V1/CertificateAuthorityServiceClient/set_iam_policy.php index 108cb8513a83..ec3234cc287a 100644 --- a/SecurityPrivateCa/samples/V1/CertificateAuthorityServiceClient/set_iam_policy.php +++ b/SecurityPrivateCa/samples/V1/CertificateAuthorityServiceClient/set_iam_policy.php @@ -30,10 +30,10 @@ /** * Sets the access control policy on the specified resource. Replaces -any existing policy. - -Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` -errors. + * any existing policy. + * + * Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` + * errors. * * @param string $resource REQUIRED: The resource for which the policy is being specified. * See the operation documentation for the appropriate value for this field. diff --git a/SecurityPrivateCa/samples/V1/CertificateAuthorityServiceClient/test_iam_permissions.php b/SecurityPrivateCa/samples/V1/CertificateAuthorityServiceClient/test_iam_permissions.php index b213cc176906..2951c3c90e45 100644 --- a/SecurityPrivateCa/samples/V1/CertificateAuthorityServiceClient/test_iam_permissions.php +++ b/SecurityPrivateCa/samples/V1/CertificateAuthorityServiceClient/test_iam_permissions.php @@ -30,12 +30,12 @@ /** * 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. + * 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. * * @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. diff --git a/SecurityPrivateCa/src/V1/Client/CertificateAuthorityServiceClient.php b/SecurityPrivateCa/src/V1/Client/CertificateAuthorityServiceClient.php index 922eddae8f6e..766bb632f80d 100644 --- a/SecurityPrivateCa/src/V1/Client/CertificateAuthorityServiceClient.php +++ b/SecurityPrivateCa/src/V1/Client/CertificateAuthorityServiceClient.php @@ -1375,21 +1375,21 @@ public function getLocation(GetLocationRequest $request, array $callOptions = [] /** * Lists information about the supported locations for this service. - - This method lists locations based on the resource scope provided in - the [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: * - **Global locations**: If `name` is empty, the method lists the - public locations available to all projects. * **Project-specific - locations**: If `name` follows the format - `projects/{project}`, the method lists locations visible to that - specific project. This includes public, private, or other - project-specific locations enabled for the project. - - For gRPC and client library implementations, the resource name is - passed as the `name` field. For direct service calls, the resource - name is - incorporated into the request path based on the specific service - implementation and version. + * + * This method lists locations based on the resource scope provided in + * the [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: * + * **Global locations**: If `name` is empty, the method lists the + * public locations available to all projects. * **Project-specific + * locations**: If `name` follows the format + * `projects/{project}`, the method lists locations visible to that + * specific project. This includes public, private, or other + * project-specific locations enabled for the project. + * + * For gRPC and client library implementations, the resource name is + * passed as the `name` field. For direct service calls, the resource + * name is + * incorporated into the request path based on the specific service + * implementation and version. * * The async variant is * {@see CertificateAuthorityServiceClient::listLocationsAsync()} . @@ -1417,7 +1417,7 @@ public function listLocations(ListLocationsRequest $request, array $callOptions /** * Gets the access control policy for a resource. Returns an empty policy - if the resource exists and does not have a policy set. + * if the resource exists and does not have a policy set. * * The async variant is * {@see CertificateAuthorityServiceClient::getIamPolicyAsync()} . @@ -1445,10 +1445,10 @@ public function getIamPolicy(GetIamPolicyRequest $request, array $callOptions = /** * Sets the access control policy on the specified resource. Replaces - any existing policy. - - Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` - errors. + * any existing policy. + * + * Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` + * errors. * * The async variant is * {@see CertificateAuthorityServiceClient::setIamPolicyAsync()} . @@ -1476,12 +1476,12 @@ public function setIamPolicy(SetIamPolicyRequest $request, array $callOptions = /** * 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. + * resource does not exist, this will return an empty set of + * permissions, not a `NOT_FOUND` error. + * + * Note: This operation is designed to be used for building + * permission-aware UIs and command-line tools, not for authorization + * checking. This operation may "fail open" without warning. * * The async variant is * {@see CertificateAuthorityServiceClient::testIamPermissionsAsync()} . diff --git a/ServiceManagement/samples/V1/ServiceManagerClient/get_iam_policy.php b/ServiceManagement/samples/V1/ServiceManagerClient/get_iam_policy.php index cae6963865ad..3ba8b5555edd 100644 --- a/ServiceManagement/samples/V1/ServiceManagerClient/get_iam_policy.php +++ b/ServiceManagement/samples/V1/ServiceManagerClient/get_iam_policy.php @@ -30,7 +30,7 @@ /** * Gets the access control policy for a resource. Returns an empty policy -if the resource exists and does not have a policy set. + * if the resource exists and does not have a policy set. * * @param string $resource REQUIRED: The resource for which the policy is being requested. * See the operation documentation for the appropriate value for this field. diff --git a/ServiceManagement/samples/V1/ServiceManagerClient/set_iam_policy.php b/ServiceManagement/samples/V1/ServiceManagerClient/set_iam_policy.php index 5bf62dcf4110..be6901b97efd 100644 --- a/ServiceManagement/samples/V1/ServiceManagerClient/set_iam_policy.php +++ b/ServiceManagement/samples/V1/ServiceManagerClient/set_iam_policy.php @@ -30,10 +30,10 @@ /** * Sets the access control policy on the specified resource. Replaces -any existing policy. - -Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` -errors. + * any existing policy. + * + * Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` + * errors. * * @param string $resource REQUIRED: The resource for which the policy is being specified. * See the operation documentation for the appropriate value for this field. diff --git a/ServiceManagement/samples/V1/ServiceManagerClient/test_iam_permissions.php b/ServiceManagement/samples/V1/ServiceManagerClient/test_iam_permissions.php index 50cf54e00bde..94f2d72c737b 100644 --- a/ServiceManagement/samples/V1/ServiceManagerClient/test_iam_permissions.php +++ b/ServiceManagement/samples/V1/ServiceManagerClient/test_iam_permissions.php @@ -30,12 +30,12 @@ /** * 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. + * 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. * * @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. diff --git a/ServiceManagement/src/V1/Client/ServiceManagerClient.php b/ServiceManagement/src/V1/Client/ServiceManagerClient.php index ff81cc0df9ba..e06b6052514f 100644 --- a/ServiceManagement/src/V1/Client/ServiceManagerClient.php +++ b/ServiceManagement/src/V1/Client/ServiceManagerClient.php @@ -690,7 +690,7 @@ public function undeleteService(UndeleteServiceRequest $request, array $callOpti /** * Gets the access control policy for a resource. Returns an empty policy - if the resource exists and does not have a policy set. + * if the resource exists and does not have a policy set. * * The async variant is {@see ServiceManagerClient::getIamPolicyAsync()} . * @@ -717,10 +717,10 @@ public function getIamPolicy(GetIamPolicyRequest $request, array $callOptions = /** * Sets the access control policy on the specified resource. Replaces - any existing policy. - - Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` - errors. + * any existing policy. + * + * Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` + * errors. * * The async variant is {@see ServiceManagerClient::setIamPolicyAsync()} . * @@ -747,12 +747,12 @@ public function setIamPolicy(SetIamPolicyRequest $request, array $callOptions = /** * 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. + * resource does not exist, this will return an empty set of + * permissions, not a `NOT_FOUND` error. + * + * Note: This operation is designed to be used for building + * permission-aware UIs and command-line tools, not for authorization + * checking. This operation may "fail open" without warning. * * The async variant is {@see ServiceManagerClient::testIamPermissionsAsync()} . * diff --git a/Speech/samples/V2/SpeechClient/list_locations.php b/Speech/samples/V2/SpeechClient/list_locations.php index 4e41716a1eba..a31ac4b207ca 100644 --- a/Speech/samples/V2/SpeechClient/list_locations.php +++ b/Speech/samples/V2/SpeechClient/list_locations.php @@ -31,13 +31,13 @@ /** * Lists information about the supported locations for this service. -This method can be called in two ways: - -* **List all public locations:** Use the path `GET /v1/locations`. -* **List project-visible locations:** Use the path -`GET /v1/projects/{project_id}/locations`. This may include public -locations as well as private or other locations specifically visible -to the project. + * This method can be called in two ways: + * + * * **List all public locations:** Use the path `GET /v1/locations`. + * * **List project-visible locations:** Use the path + * `GET /v1/projects/{project_id}/locations`. This may include public + * locations as well as private or other locations specifically visible + * to the project. * * This sample has been automatically generated and should be regarded as a code * template only. It will require modifications to work: diff --git a/Speech/src/V2/Client/SpeechClient.php b/Speech/src/V2/Client/SpeechClient.php index 1979b539a7f0..f7ea21548fa9 100644 --- a/Speech/src/V2/Client/SpeechClient.php +++ b/Speech/src/V2/Client/SpeechClient.php @@ -1090,13 +1090,13 @@ public function getLocation(GetLocationRequest $request, array $callOptions = [] /** * Lists information about the supported locations for this service. - This method can be called in two ways: - - * **List all public locations:** Use the path `GET /v1/locations`. - * **List project-visible locations:** Use the path - `GET /v1/projects/{project_id}/locations`. This may include public - locations as well as private or other locations specifically visible - to the project. + * This method can be called in two ways: + * + * * **List all public locations:** Use the path `GET /v1/locations`. + * * **List project-visible locations:** Use the path + * `GET /v1/projects/{project_id}/locations`. This may include public + * locations as well as private or other locations specifically visible + * to the project. * * The async variant is {@see SpeechClient::listLocationsAsync()} . * diff --git a/VectorSearch/samples/V1/DataObjectSearchServiceClient/list_locations.php b/VectorSearch/samples/V1/DataObjectSearchServiceClient/list_locations.php index 37706aa0e667..65a26d857a7f 100644 --- a/VectorSearch/samples/V1/DataObjectSearchServiceClient/list_locations.php +++ b/VectorSearch/samples/V1/DataObjectSearchServiceClient/list_locations.php @@ -31,22 +31,22 @@ /** * Lists information about the supported locations for this service. - -This method lists locations based on the resource scope provided in -the [ListLocationsRequest.name] field: - -* **Global locations**: If `name` is empty, the method lists the -public locations available to all projects. * **Project-specific -locations**: If `name` follows the format -`projects/{project}`, the method lists locations visible to that -specific project. This includes public, private, or other -project-specific locations enabled for the project. - -For gRPC and client library implementations, the resource name is -passed as the `name` field. For direct service calls, the resource -name is -incorporated into the request path based on the specific service -implementation and version. + * + * This method lists locations based on the resource scope provided in + * the [ListLocationsRequest.name] field: + * + * * **Global locations**: If `name` is empty, the method lists the + * public locations available to all projects. * **Project-specific + * locations**: If `name` follows the format + * `projects/{project}`, the method lists locations visible to that + * specific project. This includes public, private, or other + * project-specific locations enabled for the project. + * + * For gRPC and client library implementations, the resource name is + * passed as the `name` field. For direct service calls, the resource + * name is + * incorporated into the request path based on the specific service + * implementation and version. * * This sample has been automatically generated and should be regarded as a code * template only. It will require modifications to work: diff --git a/VectorSearch/samples/V1/DataObjectServiceClient/list_locations.php b/VectorSearch/samples/V1/DataObjectServiceClient/list_locations.php index 9af82c4d0882..0a4730deaa8c 100644 --- a/VectorSearch/samples/V1/DataObjectServiceClient/list_locations.php +++ b/VectorSearch/samples/V1/DataObjectServiceClient/list_locations.php @@ -31,22 +31,22 @@ /** * Lists information about the supported locations for this service. - -This method lists locations based on the resource scope provided in -the [ListLocationsRequest.name] field: - -* **Global locations**: If `name` is empty, the method lists the -public locations available to all projects. * **Project-specific -locations**: If `name` follows the format -`projects/{project}`, the method lists locations visible to that -specific project. This includes public, private, or other -project-specific locations enabled for the project. - -For gRPC and client library implementations, the resource name is -passed as the `name` field. For direct service calls, the resource -name is -incorporated into the request path based on the specific service -implementation and version. + * + * This method lists locations based on the resource scope provided in + * the [ListLocationsRequest.name] field: + * + * * **Global locations**: If `name` is empty, the method lists the + * public locations available to all projects. * **Project-specific + * locations**: If `name` follows the format + * `projects/{project}`, the method lists locations visible to that + * specific project. This includes public, private, or other + * project-specific locations enabled for the project. + * + * For gRPC and client library implementations, the resource name is + * passed as the `name` field. For direct service calls, the resource + * name is + * incorporated into the request path based on the specific service + * implementation and version. * * This sample has been automatically generated and should be regarded as a code * template only. It will require modifications to work: diff --git a/VectorSearch/samples/V1/VectorSearchServiceClient/list_locations.php b/VectorSearch/samples/V1/VectorSearchServiceClient/list_locations.php index 6a4b493270e4..212feaf99516 100644 --- a/VectorSearch/samples/V1/VectorSearchServiceClient/list_locations.php +++ b/VectorSearch/samples/V1/VectorSearchServiceClient/list_locations.php @@ -31,22 +31,22 @@ /** * Lists information about the supported locations for this service. - -This method lists locations based on the resource scope provided in -the [ListLocationsRequest.name] field: - -* **Global locations**: If `name` is empty, the method lists the -public locations available to all projects. * **Project-specific -locations**: If `name` follows the format -`projects/{project}`, the method lists locations visible to that -specific project. This includes public, private, or other -project-specific locations enabled for the project. - -For gRPC and client library implementations, the resource name is -passed as the `name` field. For direct service calls, the resource -name is -incorporated into the request path based on the specific service -implementation and version. + * + * This method lists locations based on the resource scope provided in + * the [ListLocationsRequest.name] field: + * + * * **Global locations**: If `name` is empty, the method lists the + * public locations available to all projects. * **Project-specific + * locations**: If `name` follows the format + * `projects/{project}`, the method lists locations visible to that + * specific project. This includes public, private, or other + * project-specific locations enabled for the project. + * + * For gRPC and client library implementations, the resource name is + * passed as the `name` field. For direct service calls, the resource + * name is + * incorporated into the request path based on the specific service + * implementation and version. * * This sample has been automatically generated and should be regarded as a code * template only. It will require modifications to work: diff --git a/VectorSearch/src/V1/Client/DataObjectSearchServiceClient.php b/VectorSearch/src/V1/Client/DataObjectSearchServiceClient.php index 9bfe20796f91..0459e3a28625 100644 --- a/VectorSearch/src/V1/Client/DataObjectSearchServiceClient.php +++ b/VectorSearch/src/V1/Client/DataObjectSearchServiceClient.php @@ -401,22 +401,22 @@ public function getLocation(GetLocationRequest $request, array $callOptions = [] /** * Lists information about the supported locations for this service. - - This method lists locations based on the resource scope provided in - the [ListLocationsRequest.name] field: - - * **Global locations**: If `name` is empty, the method lists the - public locations available to all projects. * **Project-specific - locations**: If `name` follows the format - `projects/{project}`, the method lists locations visible to that - specific project. This includes public, private, or other - project-specific locations enabled for the project. - - For gRPC and client library implementations, the resource name is - passed as the `name` field. For direct service calls, the resource - name is - incorporated into the request path based on the specific service - implementation and version. + * + * This method lists locations based on the resource scope provided in + * the [ListLocationsRequest.name] field: + * + * * **Global locations**: If `name` is empty, the method lists the + * public locations available to all projects. * **Project-specific + * locations**: If `name` follows the format + * `projects/{project}`, the method lists locations visible to that + * specific project. This includes public, private, or other + * project-specific locations enabled for the project. + * + * For gRPC and client library implementations, the resource name is + * passed as the `name` field. For direct service calls, the resource + * name is + * incorporated into the request path based on the specific service + * implementation and version. * * The async variant is {@see DataObjectSearchServiceClient::listLocationsAsync()} * . diff --git a/VectorSearch/src/V1/Client/DataObjectServiceClient.php b/VectorSearch/src/V1/Client/DataObjectServiceClient.php index c7c7b92003b3..a590f471ede8 100644 --- a/VectorSearch/src/V1/Client/DataObjectServiceClient.php +++ b/VectorSearch/src/V1/Client/DataObjectServiceClient.php @@ -484,22 +484,22 @@ public function getLocation(GetLocationRequest $request, array $callOptions = [] /** * Lists information about the supported locations for this service. - - This method lists locations based on the resource scope provided in - the [ListLocationsRequest.name] field: - - * **Global locations**: If `name` is empty, the method lists the - public locations available to all projects. * **Project-specific - locations**: If `name` follows the format - `projects/{project}`, the method lists locations visible to that - specific project. This includes public, private, or other - project-specific locations enabled for the project. - - For gRPC and client library implementations, the resource name is - passed as the `name` field. For direct service calls, the resource - name is - incorporated into the request path based on the specific service - implementation and version. + * + * This method lists locations based on the resource scope provided in + * the [ListLocationsRequest.name] field: + * + * * **Global locations**: If `name` is empty, the method lists the + * public locations available to all projects. * **Project-specific + * locations**: If `name` follows the format + * `projects/{project}`, the method lists locations visible to that + * specific project. This includes public, private, or other + * project-specific locations enabled for the project. + * + * For gRPC and client library implementations, the resource name is + * passed as the `name` field. For direct service calls, the resource + * name is + * incorporated into the request path based on the specific service + * implementation and version. * * The async variant is {@see DataObjectServiceClient::listLocationsAsync()} . * diff --git a/VectorSearch/src/V1/Client/VectorSearchServiceClient.php b/VectorSearch/src/V1/Client/VectorSearchServiceClient.php index 56b7b5cdf47a..04b146b496da 100644 --- a/VectorSearch/src/V1/Client/VectorSearchServiceClient.php +++ b/VectorSearch/src/V1/Client/VectorSearchServiceClient.php @@ -718,22 +718,22 @@ public function getLocation(GetLocationRequest $request, array $callOptions = [] /** * Lists information about the supported locations for this service. - - This method lists locations based on the resource scope provided in - the [ListLocationsRequest.name] field: - - * **Global locations**: If `name` is empty, the method lists the - public locations available to all projects. * **Project-specific - locations**: If `name` follows the format - `projects/{project}`, the method lists locations visible to that - specific project. This includes public, private, or other - project-specific locations enabled for the project. - - For gRPC and client library implementations, the resource name is - passed as the `name` field. For direct service calls, the resource - name is - incorporated into the request path based on the specific service - implementation and version. + * + * This method lists locations based on the resource scope provided in + * the [ListLocationsRequest.name] field: + * + * * **Global locations**: If `name` is empty, the method lists the + * public locations available to all projects. * **Project-specific + * locations**: If `name` follows the format + * `projects/{project}`, the method lists locations visible to that + * specific project. This includes public, private, or other + * project-specific locations enabled for the project. + * + * For gRPC and client library implementations, the resource name is + * passed as the `name` field. For direct service calls, the resource + * name is + * incorporated into the request path based on the specific service + * implementation and version. * * The async variant is {@see VectorSearchServiceClient::listLocationsAsync()} . * diff --git a/VmwareEngine/samples/V1/VmwareEngineClient/get_iam_policy.php b/VmwareEngine/samples/V1/VmwareEngineClient/get_iam_policy.php index e41c3bc434d7..cfe3ea75a739 100644 --- a/VmwareEngine/samples/V1/VmwareEngineClient/get_iam_policy.php +++ b/VmwareEngine/samples/V1/VmwareEngineClient/get_iam_policy.php @@ -30,7 +30,7 @@ /** * Gets the access control policy for a resource. Returns an empty policy -if the resource exists and does not have a policy set. + * if the resource exists and does not have a policy set. * * @param string $resource REQUIRED: The resource for which the policy is being requested. * See the operation documentation for the appropriate value for this field. diff --git a/VmwareEngine/samples/V1/VmwareEngineClient/set_iam_policy.php b/VmwareEngine/samples/V1/VmwareEngineClient/set_iam_policy.php index f5c2b3f2a65b..0e308fc9c23e 100644 --- a/VmwareEngine/samples/V1/VmwareEngineClient/set_iam_policy.php +++ b/VmwareEngine/samples/V1/VmwareEngineClient/set_iam_policy.php @@ -30,10 +30,10 @@ /** * Sets the access control policy on the specified resource. Replaces -any existing policy. - -Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` -errors. + * any existing policy. + * + * Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` + * errors. * * @param string $resource REQUIRED: The resource for which the policy is being specified. * See the operation documentation for the appropriate value for this field. diff --git a/VmwareEngine/samples/V1/VmwareEngineClient/test_iam_permissions.php b/VmwareEngine/samples/V1/VmwareEngineClient/test_iam_permissions.php index 8c9e382bdb77..9f023150568f 100644 --- a/VmwareEngine/samples/V1/VmwareEngineClient/test_iam_permissions.php +++ b/VmwareEngine/samples/V1/VmwareEngineClient/test_iam_permissions.php @@ -30,12 +30,12 @@ /** * 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. + * 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. * * @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. diff --git a/VmwareEngine/src/V1/Client/VmwareEngineClient.php b/VmwareEngine/src/V1/Client/VmwareEngineClient.php index b878e24f38c7..c19af8401244 100644 --- a/VmwareEngine/src/V1/Client/VmwareEngineClient.php +++ b/VmwareEngine/src/V1/Client/VmwareEngineClient.php @@ -3024,7 +3024,7 @@ public function listLocations(ListLocationsRequest $request, array $callOptions /** * Gets the access control policy for a resource. Returns an empty policy - if the resource exists and does not have a policy set. + * if the resource exists and does not have a policy set. * * The async variant is {@see VmwareEngineClient::getIamPolicyAsync()} . * @@ -3051,10 +3051,10 @@ public function getIamPolicy(GetIamPolicyRequest $request, array $callOptions = /** * Sets the access control policy on the specified resource. Replaces - any existing policy. - - Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` - errors. + * any existing policy. + * + * Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` + * errors. * * The async variant is {@see VmwareEngineClient::setIamPolicyAsync()} . * @@ -3081,12 +3081,12 @@ public function setIamPolicy(SetIamPolicyRequest $request, array $callOptions = /** * 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. + * resource does not exist, this will return an empty set of + * permissions, not a `NOT_FOUND` error. + * + * Note: This operation is designed to be used for building + * permission-aware UIs and command-line tools, not for authorization + * checking. This operation may "fail open" without warning. * * The async variant is {@see VmwareEngineClient::testIamPermissionsAsync()} . * diff --git a/WorkloadManager/samples/V1/WorkloadManagerClient/list_locations.php b/WorkloadManager/samples/V1/WorkloadManagerClient/list_locations.php index 1e592e3655cd..f8541e067d2d 100644 --- a/WorkloadManager/samples/V1/WorkloadManagerClient/list_locations.php +++ b/WorkloadManager/samples/V1/WorkloadManagerClient/list_locations.php @@ -31,13 +31,13 @@ /** * Lists information about the supported locations for this service. -This method can be called in two ways: - -* **List all public locations:** Use the path `GET /v1/locations`. -* **List project-visible locations:** Use the path -`GET /v1/projects/{project_id}/locations`. This may include public -locations as well as private or other locations specifically visible -to the project. + * This method can be called in two ways: + * + * * **List all public locations:** Use the path `GET /v1/locations`. + * * **List project-visible locations:** Use the path + * `GET /v1/projects/{project_id}/locations`. This may include public + * locations as well as private or other locations specifically visible + * to the project. * * This sample has been automatically generated and should be regarded as a code * template only. It will require modifications to work: diff --git a/WorkloadManager/src/V1/Client/WorkloadManagerClient.php b/WorkloadManager/src/V1/Client/WorkloadManagerClient.php index 165069a46c28..53107a97bed6 100644 --- a/WorkloadManager/src/V1/Client/WorkloadManagerClient.php +++ b/WorkloadManager/src/V1/Client/WorkloadManagerClient.php @@ -720,13 +720,13 @@ public function getLocation(GetLocationRequest $request, array $callOptions = [] /** * Lists information about the supported locations for this service. - This method can be called in two ways: - - * **List all public locations:** Use the path `GET /v1/locations`. - * **List project-visible locations:** Use the path - `GET /v1/projects/{project_id}/locations`. This may include public - locations as well as private or other locations specifically visible - to the project. + * This method can be called in two ways: + * + * * **List all public locations:** Use the path `GET /v1/locations`. + * * **List project-visible locations:** Use the path + * `GET /v1/projects/{project_id}/locations`. This may include public + * locations as well as private or other locations specifically visible + * to the project. * * The async variant is {@see WorkloadManagerClient::listLocationsAsync()} . * diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/GPBMetadata/Google/Cloud/Security/Privateca/V1/Resources.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/GPBMetadata/Google/Cloud/Security/Privateca/V1/Resources.php deleted file mode 100644 index 35d57a49c7fe..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/GPBMetadata/Google/Cloud/Security/Privateca/V1/Resources.php +++ /dev/null @@ -1,29 +0,0 @@ -internalAddGeneratedFile( - "\x0A\xB7n\x0A2google/cloud/security/privateca/v1/resources.proto\x12\"google.cloud.security.privateca.v1\x1A\x19google/api/resource.proto\x1A\x1Egoogle/protobuf/duration.proto\x1A\x1Fgoogle/protobuf/timestamp.proto\x1A\x16google/type/expr.proto\"\x86\x12\x0A\x14CertificateAuthority\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x08\x12S\x0A\x04type\x18\x02 \x01(\x0E2=.google.cloud.security.privateca.v1.CertificateAuthority.TypeB\x06\xE0A\x02\xE0A\x05\x12M\x0A\x06config\x18\x03 \x01(\x0B25.google.cloud.security.privateca.v1.CertificateConfigB\x06\xE0A\x02\xE0A\x05\x123\x0A\x08lifetime\x18\x04 \x01(\x0B2\x19.google.protobuf.DurationB\x06\xE0A\x02\xE0A\x05\x12a\x0A\x08key_spec\x18\x05 \x01(\x0B2G.google.cloud.security.privateca.v1.CertificateAuthority.KeyVersionSpecB\x06\xE0A\x02\xE0A\x05\x12V\x0A\x12subordinate_config\x18\x06 \x01(\x0B25.google.cloud.security.privateca.v1.SubordinateConfigB\x03\xE0A\x01\x12B\x0A\x04tier\x18\x07 \x01(\x0E2/.google.cloud.security.privateca.v1.CaPool.TierB\x03\xE0A\x03\x12R\x0A\x05state\x18\x08 \x01(\x0E2>.google.cloud.security.privateca.v1.CertificateAuthority.StateB\x03\xE0A\x03\x12 \x0A\x13pem_ca_certificates\x18\x09 \x03(\x09B\x03\xE0A\x03\x12d\x0A\x1Bca_certificate_descriptions\x18\x0A \x03(\x0B2:.google.cloud.security.privateca.v1.CertificateDescriptionB\x03\xE0A\x03\x12\x17\x0A\x0Agcs_bucket\x18\x0B \x01(\x09B\x03\xE0A\x05\x12]\x0A\x0Baccess_urls\x18\x0C \x01(\x0B2C.google.cloud.security.privateca.v1.CertificateAuthority.AccessUrlsB\x03\xE0A\x03\x124\x0A\x0Bcreate_time\x18\x0D \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x0E \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bdelete_time\x18\x0F \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bexpire_time\x18\x10 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12Y\x0A\x06labels\x18\x11 \x03(\x0B2D.google.cloud.security.privateca.v1.CertificateAuthority.LabelsEntryB\x03\xE0A\x01\x12u\x0A\x18user_defined_access_urls\x18\x12 \x01(\x0B2N.google.cloud.security.privateca.v1.CertificateAuthority.UserDefinedAccessUrlsB\x03\xE0A\x01\x12\x1A\x0A\x0Dsatisfies_pzs\x18\x13 \x01(\x08B\x03\xE0A\x03\x12\x1A\x0A\x0Dsatisfies_pzi\x18\x14 \x01(\x08B\x03\xE0A\x03\x1AH\x0A\x0AAccessUrls\x12!\x0A\x19ca_certificate_access_url\x18\x01 \x01(\x09\x12\x17\x0A\x0Fcrl_access_urls\x18\x02 \x03(\x09\x1A\xA0\x01\x0A\x0EKeyVersionSpec\x12\x1F\x0A\x15cloud_kms_key_version\x18\x01 \x01(\x09H\x00\x12_\x0A\x09algorithm\x18\x02 \x01(\x0E2J.google.cloud.security.privateca.v1.CertificateAuthority.SignHashAlgorithmH\x00B\x0C\x0A\x0AKeyVersion\x1A`\x0A\x15UserDefinedAccessUrls\x12)\x0A\x1Caia_issuing_certificate_urls\x18\x01 \x03(\x09B\x03\xE0A\x01\x12\x1C\x0A\x0Fcrl_access_urls\x18\x02 \x03(\x09B\x03\xE0A\x01\x1A-\x0A\x0BLabelsEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12\x0D\x0A\x05value\x18\x02 \x01(\x09:\x028\x01\">\x0A\x04Type\x12\x14\x0A\x10TYPE_UNSPECIFIED\x10\x00\x12\x0F\x0A\x0BSELF_SIGNED\x10\x01\x12\x0F\x0A\x0BSUBORDINATE\x10\x02\"p\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x0B\x0A\x07ENABLED\x10\x01\x12\x0C\x0A\x08DISABLED\x10\x02\x12\x0A\x0A\x06STAGED\x10\x03\x12\x1C\x0A\x18AWAITING_USER_ACTIVATION\x10\x04\x12\x0B\x0A\x07DELETED\x10\x05\"\xFC\x01\x0A\x11SignHashAlgorithm\x12#\x0A\x1FSIGN_HASH_ALGORITHM_UNSPECIFIED\x10\x00\x12\x17\x0A\x13RSA_PSS_2048_SHA256\x10\x01\x12\x17\x0A\x13RSA_PSS_3072_SHA256\x10\x02\x12\x17\x0A\x13RSA_PSS_4096_SHA256\x10\x03\x12\x19\x0A\x15RSA_PKCS1_2048_SHA256\x10\x06\x12\x19\x0A\x15RSA_PKCS1_3072_SHA256\x10\x07\x12\x19\x0A\x15RSA_PKCS1_4096_SHA256\x10\x08\x12\x12\x0A\x0EEC_P256_SHA256\x10\x04\x12\x12\x0A\x0EEC_P384_SHA384\x10\x05:\x9D\x01\xEAA\x99\x01\x0A-privateca.googleapis.com/CertificateAuthority\x12hprojects/{project}/locations/{location}/caPools/{ca_pool}/certificateAuthorities/{certificate_authority}\"\xE6\x11\x0A\x06CaPool\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x08\x12E\x0A\x04tier\x18\x02 \x01(\x0E2/.google.cloud.security.privateca.v1.CaPool.TierB\x06\xE0A\x02\xE0A\x05\x12W\x0A\x0Fissuance_policy\x18\x03 \x01(\x0B29.google.cloud.security.privateca.v1.CaPool.IssuancePolicyB\x03\xE0A\x01\x12]\x0A\x12publishing_options\x18\x04 \x01(\x0B2<.google.cloud.security.privateca.v1.CaPool.PublishingOptionsB\x03\xE0A\x01\x12P\x0A\x0Fencryption_spec\x18\x08 \x01(\x0B22.google.cloud.security.privateca.v1.EncryptionSpecB\x03\xE0A\x01\x12K\x0A\x06labels\x18\x05 \x03(\x0B26.google.cloud.security.privateca.v1.CaPool.LabelsEntryB\x03\xE0A\x01\x1A\xFB\x01\x0A\x11PublishingOptions\x12\x1C\x0A\x0Fpublish_ca_cert\x18\x01 \x01(\x08B\x03\xE0A\x01\x12\x18\x0A\x0Bpublish_crl\x18\x02 \x01(\x08B\x03\xE0A\x01\x12i\x0A\x0Fencoding_format\x18\x03 \x01(\x0E2K.google.cloud.security.privateca.v1.CaPool.PublishingOptions.EncodingFormatB\x03\xE0A\x01\"C\x0A\x0EEncodingFormat\x12\x1F\x0A\x1BENCODING_FORMAT_UNSPECIFIED\x10\x00\x12\x07\x0A\x03PEM\x10\x01\x12\x07\x0A\x03DER\x10\x02\x1A\xE2\x0A\x0A\x0EIssuancePolicy\x12h\x0A\x11allowed_key_types\x18\x01 \x03(\x0B2H.google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyTypeB\x03\xE0A\x01\x129\x0A\x11backdate_duration\x18\x07 \x01(\x0B2\x19.google.protobuf.DurationB\x03\xE0A\x01\x126\x0A)allow_requester_specified_not_before_time\x18\x08 \x01(\x08B\x03\xE0A\x01\x128\x0A\x10maximum_lifetime\x18\x02 \x01(\x0B2\x19.google.protobuf.DurationB\x03\xE0A\x01\x12l\x0A\x16allowed_issuance_modes\x18\x03 \x01(\x0B2G.google.cloud.security.privateca.v1.CaPool.IssuancePolicy.IssuanceModesB\x03\xE0A\x01\x12P\x0A\x0Fbaseline_values\x18\x04 \x01(\x0B22.google.cloud.security.privateca.v1.X509ParametersB\x03\xE0A\x01\x12e\x0A\x14identity_constraints\x18\x05 \x01(\x0B2B.google.cloud.security.privateca.v1.CertificateIdentityConstraintsB\x03\xE0A\x01\x12h\x0A\x16passthrough_extensions\x18\x06 \x01(\x0B2C.google.cloud.security.privateca.v1.CertificateExtensionConstraintsB\x03\xE0A\x01\x1A\xC5\x04\x0A\x0EAllowedKeyType\x12b\x0A\x03rsa\x18\x01 \x01(\x0B2S.google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyType.RsaKeyTypeH\x00\x12l\x0A\x0Eelliptic_curve\x18\x02 \x01(\x0B2R.google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyType.EcKeyTypeH\x00\x1AJ\x0A\x0ARsaKeyType\x12\x1D\x0A\x10min_modulus_size\x18\x01 \x01(\x03B\x03\xE0A\x01\x12\x1D\x0A\x10max_modulus_size\x18\x02 \x01(\x03B\x03\xE0A\x01\x1A\x88\x02\x0A\x09EcKeyType\x12\x89\x01\x0A\x13signature_algorithm\x18\x01 \x01(\x0E2g.google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyType.EcKeyType.EcSignatureAlgorithmB\x03\xE0A\x01\"o\x0A\x14EcSignatureAlgorithm\x12&\x0A\"EC_SIGNATURE_ALGORITHM_UNSPECIFIED\x10\x00\x12\x0E\x0A\x0AECDSA_P256\x10\x01\x12\x0E\x0A\x0AECDSA_P384\x10\x02\x12\x0F\x0A\x0BEDDSA_25519\x10\x03B\x0A\x0A\x08key_type\x1A`\x0A\x0DIssuanceModes\x12%\x0A\x18allow_csr_based_issuance\x18\x01 \x01(\x08B\x03\xE0A\x01\x12(\x0A\x1Ballow_config_based_issuance\x18\x02 \x01(\x08B\x03\xE0A\x01\x1A-\x0A\x0BLabelsEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12\x0D\x0A\x05value\x18\x02 \x01(\x09:\x028\x01\"8\x0A\x04Tier\x12\x14\x0A\x10TIER_UNSPECIFIED\x10\x00\x12\x0E\x0A\x0AENTERPRISE\x10\x01\x12\x0A\x0A\x06DEVOPS\x10\x02:_\xEAA\\\x0A\x1Fprivateca.googleapis.com/CaPool\x129projects/{project}/locations/{location}/caPools/{ca_pool}\"'\x0A\x0EEncryptionSpec\x12\x15\x0A\x0Dcloud_kms_key\x18\x01 \x01(\x09\"\xBC\x08\x0A\x19CertificateRevocationList\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x08\x12\x1C\x0A\x0Fsequence_number\x18\x02 \x01(\x03B\x03\xE0A\x03\x12s\x0A\x14revoked_certificates\x18\x03 \x03(\x0B2P.google.cloud.security.privateca.v1.CertificateRevocationList.RevokedCertificateB\x03\xE0A\x03\x12\x14\x0A\x07pem_crl\x18\x04 \x01(\x09B\x03\xE0A\x03\x12\x17\x0A\x0Aaccess_url\x18\x05 \x01(\x09B\x03\xE0A\x03\x12W\x0A\x05state\x18\x06 \x01(\x0E2C.google.cloud.security.privateca.v1.CertificateRevocationList.StateB\x03\xE0A\x03\x124\x0A\x0Bcreate_time\x18\x07 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x08 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12\x18\x0A\x0Brevision_id\x18\x09 \x01(\x09B\x03\xE0A\x03\x12^\x0A\x06labels\x18\x0A \x03(\x0B2I.google.cloud.security.privateca.v1.CertificateRevocationList.LabelsEntryB\x03\xE0A\x01\x1A\xC0\x01\x0A\x12RevokedCertificate\x12>\x0A\x0Bcertificate\x18\x01 \x01(\x09B)\xFAA&\x0A\$privateca.googleapis.com/Certificate\x12\x19\x0A\x11hex_serial_number\x18\x02 \x01(\x09\x12O\x0A\x11revocation_reason\x18\x03 \x01(\x0E24.google.cloud.security.privateca.v1.RevocationReason\x1A-\x0A\x0BLabelsEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12\x0D\x0A\x05value\x18\x02 \x01(\x09:\x028\x01\":\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x0A\x0A\x06ACTIVE\x10\x01\x12\x0E\x0A\x0ASUPERSEDED\x10\x02:\xDC\x01\xEAA\xD8\x01\x0A2privateca.googleapis.com/CertificateRevocationList\x12\xA1\x01projects/{project}/locations/{location}/caPools/{ca_pool}/certificateAuthorities/{certificate_authority}/certificateRevocationLists/{certificate_revocation_list}\"\xAA\x0A\x0A\x0BCertificate\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x08\x12\x16\x0A\x07pem_csr\x18\x02 \x01(\x09B\x03\xE0A\x05H\x00\x12L\x0A\x06config\x18\x03 \x01(\x0B25.google.cloud.security.privateca.v1.CertificateConfigB\x03\xE0A\x05H\x00\x12[\x0A\x1Cissuer_certificate_authority\x18\x04 \x01(\x09B5\xE0A\x03\xFAA/\x0A-privateca.googleapis.com/CertificateAuthority\x123\x0A\x08lifetime\x18\x05 \x01(\x0B2\x19.google.protobuf.DurationB\x06\xE0A\x02\xE0A\x05\x12R\x0A\x14certificate_template\x18\x06 \x01(\x09B4\xE0A\x05\xFAA.\x0A,privateca.googleapis.com/CertificateTemplate\x12Q\x0A\x0Csubject_mode\x18\x07 \x01(\x0E26.google.cloud.security.privateca.v1.SubjectRequestModeB\x03\xE0A\x05\x12b\x0A\x12revocation_details\x18\x08 \x01(\x0B2A.google.cloud.security.privateca.v1.Certificate.RevocationDetailsB\x03\xE0A\x03\x12\x1C\x0A\x0Fpem_certificate\x18\x09 \x01(\x09B\x03\xE0A\x03\x12`\x0A\x17certificate_description\x18\x0A \x01(\x0B2:.google.cloud.security.privateca.v1.CertificateDescriptionB\x03\xE0A\x03\x12\"\x0A\x15pem_certificate_chain\x18\x0B \x03(\x09B\x03\xE0A\x03\x124\x0A\x0Bcreate_time\x18\x0C \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x0D \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12P\x0A\x06labels\x18\x0E \x03(\x0B2;.google.cloud.security.privateca.v1.Certificate.LabelsEntryB\x03\xE0A\x01\x12B\x0A\x19requested_not_before_time\x18\x0F \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x01\x1A\x98\x01\x0A\x11RevocationDetails\x12N\x0A\x10revocation_state\x18\x01 \x01(\x0E24.google.cloud.security.privateca.v1.RevocationReason\x123\x0A\x0Frevocation_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.Timestamp\x1A-\x0A\x0BLabelsEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12\x0D\x0A\x05value\x18\x02 \x01(\x09:\x028\x01:\x7F\xEAA|\x0A\$privateca.googleapis.com/Certificate\x12Tprojects/{project}/locations/{location}/caPools/{ca_pool}/certificates/{certificate}B\x14\x0A\x12certificate_config\"\xA0\x06\x0A\x13CertificateTemplate\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x08\x128\x0A\x10maximum_lifetime\x18\x09 \x01(\x0B2\x19.google.protobuf.DurationB\x03\xE0A\x01\x12R\x0A\x11predefined_values\x18\x02 \x01(\x0B22.google.cloud.security.privateca.v1.X509ParametersB\x03\xE0A\x01\x12e\x0A\x14identity_constraints\x18\x03 \x01(\x0B2B.google.cloud.security.privateca.v1.CertificateIdentityConstraintsB\x03\xE0A\x01\x12h\x0A\x16passthrough_extensions\x18\x04 \x01(\x0B2C.google.cloud.security.privateca.v1.CertificateExtensionConstraintsB\x03\xE0A\x01\x12\x18\x0A\x0Bdescription\x18\x05 \x01(\x09B\x03\xE0A\x01\x124\x0A\x0Bcreate_time\x18\x06 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x07 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12X\x0A\x06labels\x18\x08 \x03(\x0B2C.google.cloud.security.privateca.v1.CertificateTemplate.LabelsEntryB\x03\xE0A\x01\x1A-\x0A\x0BLabelsEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12\x0D\x0A\x05value\x18\x02 \x01(\x09:\x028\x01:\x87\x01\xEAA\x83\x01\x0A,privateca.googleapis.com/CertificateTemplate\x12Sprojects/{project}/locations/{location}/certificateTemplates/{certificate_template}\"\xCE\x06\x0A\x0EX509Parameters\x12D\x0A\x09key_usage\x18\x01 \x01(\x0B2,.google.cloud.security.privateca.v1.KeyUsageB\x03\xE0A\x01\x12U\x0A\x0Aca_options\x18\x02 \x01(\x0B2<.google.cloud.security.privateca.v1.X509Parameters.CaOptionsB\x03\xE0A\x01\x12E\x0A\x0Apolicy_ids\x18\x03 \x03(\x0B2,.google.cloud.security.privateca.v1.ObjectIdB\x03\xE0A\x01\x12\x1D\x0A\x10aia_ocsp_servers\x18\x04 \x03(\x09B\x03\xE0A\x01\x12a\x0A\x10name_constraints\x18\x06 \x01(\x0B2B.google.cloud.security.privateca.v1.X509Parameters.NameConstraintsB\x03\xE0A\x01\x12U\x0A\x15additional_extensions\x18\x05 \x03(\x0B21.google.cloud.security.privateca.v1.X509ExtensionB\x03\xE0A\x01\x1As\x0A\x09CaOptions\x12\x17\x0A\x05is_ca\x18\x01 \x01(\x08B\x03\xE0A\x01H\x00\x88\x01\x01\x12(\x0A\x16max_issuer_path_length\x18\x02 \x01(\x05B\x03\xE0A\x01H\x01\x88\x01\x01B\x08\x0A\x06_is_caB\x19\x0A\x17_max_issuer_path_length\x1A\x89\x02\x0A\x0FNameConstraints\x12\x10\x0A\x08critical\x18\x01 \x01(\x08\x12\x1B\x0A\x13permitted_dns_names\x18\x02 \x03(\x09\x12\x1A\x0A\x12excluded_dns_names\x18\x03 \x03(\x09\x12\x1B\x0A\x13permitted_ip_ranges\x18\x04 \x03(\x09\x12\x1A\x0A\x12excluded_ip_ranges\x18\x05 \x03(\x09\x12!\x0A\x19permitted_email_addresses\x18\x06 \x03(\x09\x12 \x0A\x18excluded_email_addresses\x18\x07 \x03(\x09\x12\x16\x0A\x0Epermitted_uris\x18\x08 \x03(\x09\x12\x15\x0A\x0Dexcluded_uris\x18\x09 \x03(\x09\"\xA9\x02\x0A\x11SubordinateConfig\x12V\x0A\x15certificate_authority\x18\x01 \x01(\x09B5\xE0A\x02\xFAA/\x0A-privateca.googleapis.com/CertificateAuthorityH\x00\x12m\x0A\x10pem_issuer_chain\x18\x02 \x01(\x0B2L.google.cloud.security.privateca.v1.SubordinateConfig.SubordinateConfigChainB\x03\xE0A\x02H\x00\x1A7\x0A\x16SubordinateConfigChain\x12\x1D\x0A\x10pem_certificates\x18\x01 \x03(\x09B\x03\xE0A\x02B\x14\x0A\x12subordinate_config\"\x9D\x01\x0A\x09PublicKey\x12\x10\x0A\x03key\x18\x01 \x01(\x0CB\x03\xE0A\x02\x12L\x0A\x06format\x18\x02 \x01(\x0E27.google.cloud.security.privateca.v1.PublicKey.KeyFormatB\x03\xE0A\x02\"0\x0A\x09KeyFormat\x12\x1A\x0A\x16KEY_FORMAT_UNSPECIFIED\x10\x00\x12\x07\x0A\x03PEM\x10\x01\"\xAC\x04\x0A\x11CertificateConfig\x12`\x0A\x0Esubject_config\x18\x01 \x01(\x0B2C.google.cloud.security.privateca.v1.CertificateConfig.SubjectConfigB\x03\xE0A\x02\x12L\x0A\x0Bx509_config\x18\x02 \x01(\x0B22.google.cloud.security.privateca.v1.X509ParametersB\x03\xE0A\x02\x12F\x0A\x0Apublic_key\x18\x03 \x01(\x0B2-.google.cloud.security.privateca.v1.PublicKeyB\x03\xE0A\x01\x12X\x0A\x0Esubject_key_id\x18\x04 \x01(\x0B2;.google.cloud.security.privateca.v1.CertificateConfig.KeyIdB\x03\xE0A\x01\x1A\xA6\x01\x0A\x0DSubjectConfig\x12A\x0A\x07subject\x18\x01 \x01(\x0B2+.google.cloud.security.privateca.v1.SubjectB\x03\xE0A\x01\x12R\x0A\x10subject_alt_name\x18\x02 \x01(\x0B23.google.cloud.security.privateca.v1.SubjectAltNamesB\x03\xE0A\x01\x1A\x1C\x0A\x05KeyId\x12\x13\x0A\x06key_id\x18\x01 \x01(\x09B\x03\xE0A\x02\"\xC1\x08\x0A\x16CertificateDescription\x12j\x0A\x13subject_description\x18\x01 \x01(\x0B2M.google.cloud.security.privateca.v1.CertificateDescription.SubjectDescription\x12L\x0A\x10x509_description\x18\x02 \x01(\x0B22.google.cloud.security.privateca.v1.X509Parameters\x12A\x0A\x0Apublic_key\x18\x03 \x01(\x0B2-.google.cloud.security.privateca.v1.PublicKey\x12X\x0A\x0Esubject_key_id\x18\x04 \x01(\x0B2@.google.cloud.security.privateca.v1.CertificateDescription.KeyId\x12Z\x0A\x10authority_key_id\x18\x05 \x01(\x0B2@.google.cloud.security.privateca.v1.CertificateDescription.KeyId\x12\x1F\x0A\x17crl_distribution_points\x18\x06 \x03(\x09\x12\$\x0A\x1Caia_issuing_certificate_urls\x18\x07 \x03(\x09\x12k\x0A\x10cert_fingerprint\x18\x08 \x01(\x0B2Q.google.cloud.security.privateca.v1.CertificateDescription.CertificateFingerprint\x12\x1E\x0A\x16tbs_certificate_digest\x18\x09 \x01(\x09\x1A\xD2\x02\x0A\x12SubjectDescription\x12<\x0A\x07subject\x18\x01 \x01(\x0B2+.google.cloud.security.privateca.v1.Subject\x12M\x0A\x10subject_alt_name\x18\x02 \x01(\x0B23.google.cloud.security.privateca.v1.SubjectAltNames\x12\x19\x0A\x11hex_serial_number\x18\x03 \x01(\x09\x12+\x0A\x08lifetime\x18\x04 \x01(\x0B2\x19.google.protobuf.Duration\x123\x0A\x0Fnot_before_time\x18\x05 \x01(\x0B2\x1A.google.protobuf.Timestamp\x122\x0A\x0Enot_after_time\x18\x06 \x01(\x0B2\x1A.google.protobuf.Timestamp\x1A\x1C\x0A\x05KeyId\x12\x13\x0A\x06key_id\x18\x01 \x01(\x09B\x03\xE0A\x01\x1A-\x0A\x16CertificateFingerprint\x12\x13\x0A\x0Bsha256_hash\x18\x01 \x01(\x09\"'\x0A\x08ObjectId\x12\x1B\x0A\x0Eobject_id_path\x18\x01 \x03(\x05B\x03\xE0A\x02\"\x80\x01\x0A\x0DX509Extension\x12D\x0A\x09object_id\x18\x01 \x01(\x0B2,.google.cloud.security.privateca.v1.ObjectIdB\x03\xE0A\x02\x12\x15\x0A\x08critical\x18\x02 \x01(\x08B\x03\xE0A\x01\x12\x12\x0A\x05value\x18\x03 \x01(\x0CB\x03\xE0A\x02\"\xA2\x05\x0A\x08KeyUsage\x12T\x0A\x0Ebase_key_usage\x18\x01 \x01(\x0B2<.google.cloud.security.privateca.v1.KeyUsage.KeyUsageOptions\x12`\x0A\x12extended_key_usage\x18\x02 \x01(\x0B2D.google.cloud.security.privateca.v1.KeyUsage.ExtendedKeyUsageOptions\x12Q\x0A\x1Bunknown_extended_key_usages\x18\x03 \x03(\x0B2,.google.cloud.security.privateca.v1.ObjectId\x1A\xE7\x01\x0A\x0FKeyUsageOptions\x12\x19\x0A\x11digital_signature\x18\x01 \x01(\x08\x12\x1A\x0A\x12content_commitment\x18\x02 \x01(\x08\x12\x18\x0A\x10key_encipherment\x18\x03 \x01(\x08\x12\x19\x0A\x11data_encipherment\x18\x04 \x01(\x08\x12\x15\x0A\x0Dkey_agreement\x18\x05 \x01(\x08\x12\x11\x0A\x09cert_sign\x18\x06 \x01(\x08\x12\x10\x0A\x08crl_sign\x18\x07 \x01(\x08\x12\x15\x0A\x0Dencipher_only\x18\x08 \x01(\x08\x12\x15\x0A\x0Ddecipher_only\x18\x09 \x01(\x08\x1A\xA0\x01\x0A\x17ExtendedKeyUsageOptions\x12\x13\x0A\x0Bserver_auth\x18\x01 \x01(\x08\x12\x13\x0A\x0Bclient_auth\x18\x02 \x01(\x08\x12\x14\x0A\x0Ccode_signing\x18\x03 \x01(\x08\x12\x18\x0A\x10email_protection\x18\x04 \x01(\x08\x12\x15\x0A\x0Dtime_stamping\x18\x05 \x01(\x08\x12\x14\x0A\x0Cocsp_signing\x18\x06 \x01(\x08\"\xBE\x01\x0A\x15AttributeTypeAndValue\x12A\x0A\x04type\x18\x01 \x01(\x0E21.google.cloud.security.privateca.v1.AttributeTypeH\x00\x12A\x0A\x09object_id\x18\x02 \x01(\x0B2,.google.cloud.security.privateca.v1.ObjectIdH\x00\x12\x0D\x0A\x05value\x18\x03 \x01(\x09B\x10\x0A\x0Eattribute_type\"j\x0A\x19RelativeDistinguishedName\x12M\x0A\x0Aattributes\x18\x01 \x03(\x0B29.google.cloud.security.privateca.v1.AttributeTypeAndValue\"\x8D\x02\x0A\x07Subject\x12\x13\x0A\x0Bcommon_name\x18\x01 \x01(\x09\x12\x14\x0A\x0Ccountry_code\x18\x02 \x01(\x09\x12\x14\x0A\x0Corganization\x18\x03 \x01(\x09\x12\x1B\x0A\x13organizational_unit\x18\x04 \x01(\x09\x12\x10\x0A\x08locality\x18\x05 \x01(\x09\x12\x10\x0A\x08province\x18\x06 \x01(\x09\x12\x16\x0A\x0Estreet_address\x18\x07 \x01(\x09\x12\x13\x0A\x0Bpostal_code\x18\x08 \x01(\x09\x12S\x0A\x0Crdn_sequence\x18\x09 \x03(\x0B2=.google.cloud.security.privateca.v1.RelativeDistinguishedName\"\xA9\x01\x0A\x0FSubjectAltNames\x12\x11\x0A\x09dns_names\x18\x01 \x03(\x09\x12\x0C\x0A\x04uris\x18\x02 \x03(\x09\x12\x17\x0A\x0Femail_addresses\x18\x03 \x03(\x09\x12\x14\x0A\x0Cip_addresses\x18\x04 \x03(\x09\x12F\x0A\x0Bcustom_sans\x18\x05 \x03(\x0B21.google.cloud.security.privateca.v1.X509Extension\"\xFA\x01\x0A\x1ECertificateIdentityConstraints\x12.\x0A\x0Ecel_expression\x18\x01 \x01(\x0B2\x11.google.type.ExprB\x03\xE0A\x01\x12+\x0A\x19allow_subject_passthrough\x18\x02 \x01(\x08B\x03\xE0A\x02H\x00\x88\x01\x01\x125\x0A#allow_subject_alt_names_passthrough\x18\x03 \x01(\x08B\x03\xE0A\x02H\x01\x88\x01\x01B\x1C\x0A\x1A_allow_subject_passthroughB&\x0A\$_allow_subject_alt_names_passthrough\"\xB4\x03\x0A\x1FCertificateExtensionConstraints\x12|\x0A\x10known_extensions\x18\x01 \x03(\x0E2].google.cloud.security.privateca.v1.CertificateExtensionConstraints.KnownCertificateExtensionB\x03\xE0A\x01\x12P\x0A\x15additional_extensions\x18\x02 \x03(\x0B2,.google.cloud.security.privateca.v1.ObjectIdB\x03\xE0A\x01\"\xC0\x01\x0A\x19KnownCertificateExtension\x12+\x0A'KNOWN_CERTIFICATE_EXTENSION_UNSPECIFIED\x10\x00\x12\x12\x0A\x0EBASE_KEY_USAGE\x10\x01\x12\x16\x0A\x12EXTENDED_KEY_USAGE\x10\x02\x12\x0E\x0A\x0ACA_OPTIONS\x10\x03\x12\x0E\x0A\x0APOLICY_IDS\x10\x04\x12\x14\x0A\x10AIA_OCSP_SERVERS\x10\x05\x12\x14\x0A\x10NAME_CONSTRAINTS\x10\x06*\xBE\x01\x0A\x0DAttributeType\x12\x1E\x0A\x1AATTRIBUTE_TYPE_UNSPECIFIED\x10\x00\x12\x0F\x0A\x0BCOMMON_NAME\x10\x01\x12\x10\x0A\x0CCOUNTRY_CODE\x10\x02\x12\x10\x0A\x0CORGANIZATION\x10\x03\x12\x17\x0A\x13ORGANIZATIONAL_UNIT\x10\x04\x12\x0C\x0A\x08LOCALITY\x10\x05\x12\x0C\x0A\x08PROVINCE\x10\x06\x12\x12\x0A\x0ESTREET_ADDRESS\x10\x07\x12\x0F\x0A\x0BPOSTAL_CODE\x10\x08*\x87\x02\x0A\x10RevocationReason\x12!\x0A\x1DREVOCATION_REASON_UNSPECIFIED\x10\x00\x12\x12\x0A\x0EKEY_COMPROMISE\x10\x01\x12\$\x0A CERTIFICATE_AUTHORITY_COMPROMISE\x10\x02\x12\x17\x0A\x13AFFILIATION_CHANGED\x10\x03\x12\x0E\x0A\x0ASUPERSEDED\x10\x04\x12\x1A\x0A\x16CESSATION_OF_OPERATION\x10\x05\x12\x14\x0A\x10CERTIFICATE_HOLD\x10\x06\x12\x17\x0A\x13PRIVILEGE_WITHDRAWN\x10\x07\x12\"\x0A\x1EATTRIBUTE_AUTHORITY_COMPROMISE\x10\x08*o\x0A\x12SubjectRequestMode\x12\$\x0A SUBJECT_REQUEST_MODE_UNSPECIFIED\x10\x00\x12\x0B\x0A\x07DEFAULT\x10\x01\x12\x10\x0A\x0CRDN_SEQUENCE\x10\x03\x12\x14\x0A\x10REFLECTED_SPIFFE\x10\x02B\xFC\x01\x0A&com.google.cloud.security.privateca.v1B\x17PrivateCaResourcesProtoP\x01ZDcloud.google.com/go/security/privateca/apiv1/privatecapb;privatecapb\xAA\x02\"Google.Cloud.Security.PrivateCA.V1\xCA\x02\"Google\\Cloud\\Security\\PrivateCA\\V1\xEA\x02&Google::Cloud::Security::PrivateCA::V1b\x06proto3" - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/GPBMetadata/Google/Cloud/Security/Privateca/V1/Service.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/GPBMetadata/Google/Cloud/Security/Privateca/V1/Service.php deleted file mode 100644 index 9ef4ade00b13..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/GPBMetadata/Google/Cloud/Security/Privateca/V1/Service.php +++ /dev/null @@ -1,34 +0,0 @@ -internalAddGeneratedFile( - "\x0A\xFCr\x0A0google/cloud/security/privateca/v1/service.proto\x12\"google.cloud.security.privateca.v1\x1A\x17google/api/client.proto\x1A\x1Fgoogle/api/field_behavior.proto\x1A\x1Bgoogle/api/field_info.proto\x1A\x19google/api/resource.proto\x1A2google/cloud/security/privateca/v1/resources.proto\x1A#google/longrunning/operations.proto\x1A\x1Bgoogle/protobuf/empty.proto\x1A google/protobuf/field_mask.proto\x1A\x1Fgoogle/protobuf/timestamp.proto\"\x9F\x02\x0A\x18CreateCertificateRequest\x127\x0A\x06parent\x18\x01 \x01(\x09B'\xE0A\x02\xFAA!\x0A\x1Fprivateca.googleapis.com/CaPool\x12\x1B\x0A\x0Ecertificate_id\x18\x02 \x01(\x09B\x03\xE0A\x01\x12I\x0A\x0Bcertificate\x18\x03 \x01(\x0B2/.google.cloud.security.privateca.v1.CertificateB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x04 \x01(\x09B\x03\xE0A\x01\x12\x1A\x0A\x0Dvalidate_only\x18\x05 \x01(\x08B\x03\xE0A\x01\x12-\x0A issuing_certificate_authority_id\x18\x06 \x01(\x09B\x03\xE0A\x01\"S\x0A\x15GetCertificateRequest\x12:\x0A\x04name\x18\x01 \x01(\x09B,\xE0A\x02\xFAA&\x0A\$privateca.googleapis.com/Certificate\"\xAF\x01\x0A\x17ListCertificatesRequest\x127\x0A\x06parent\x18\x01 \x01(\x09B'\xE0A\x02\xFAA!\x0A\x1Fprivateca.googleapis.com/CaPool\x12\x16\x0A\x09page_size\x18\x02 \x01(\x05B\x03\xE0A\x01\x12\x17\x0A\x0Apage_token\x18\x03 \x01(\x09B\x03\xE0A\x01\x12\x13\x0A\x06filter\x18\x04 \x01(\x09B\x03\xE0A\x01\x12\x15\x0A\x08order_by\x18\x05 \x01(\x09B\x03\xE0A\x01\"\x8F\x01\x0A\x18ListCertificatesResponse\x12E\x0A\x0Ccertificates\x18\x01 \x03(\x0B2/.google.cloud.security.privateca.v1.Certificate\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\x12\x13\x0A\x0Bunreachable\x18\x03 \x03(\x09\"\xBA\x01\x0A\x18RevokeCertificateRequest\x12:\x0A\x04name\x18\x01 \x01(\x09B,\xE0A\x02\xFAA&\x0A\$privateca.googleapis.com/Certificate\x12I\x0A\x06reason\x18\x02 \x01(\x0E24.google.cloud.security.privateca.v1.RevocationReasonB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x03\xE0A\x01\"\xB4\x01\x0A\x18UpdateCertificateRequest\x12I\x0A\x0Bcertificate\x18\x01 \x01(\x0B2/.google.cloud.security.privateca.v1.CertificateB\x03\xE0A\x02\x124\x0A\x0Bupdate_mask\x18\x02 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x03\xE0A\x01\"\x84\x02\x0A#ActivateCertificateAuthorityRequest\x12C\x0A\x04name\x18\x01 \x01(\x09B5\xE0A\x02\xFAA/\x0A-privateca.googleapis.com/CertificateAuthority\x12\x1F\x0A\x12pem_ca_certificate\x18\x02 \x01(\x09B\x03\xE0A\x02\x12V\x0A\x12subordinate_config\x18\x03 \x01(\x0B25.google.cloud.security.privateca.v1.SubordinateConfigB\x03\xE0A\x02\x12\x1F\x0A\x0Arequest_id\x18\x04 \x01(\x09B\x0B\xE0A\x01\xE2\x8C\xCF\xD7\x08\x02\x08\x01\"\xFA\x01\x0A!CreateCertificateAuthorityRequest\x127\x0A\x06parent\x18\x01 \x01(\x09B'\xE0A\x02\xFAA!\x0A\x1Fprivateca.googleapis.com/CaPool\x12%\x0A\x18certificate_authority_id\x18\x02 \x01(\x09B\x03\xE0A\x02\x12\\\x0A\x15certificate_authority\x18\x03 \x01(\x0B28.google.cloud.security.privateca.v1.CertificateAuthorityB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x04 \x01(\x09B\x03\xE0A\x01\"\xB3\x01\x0A\"DisableCertificateAuthorityRequest\x12C\x0A\x04name\x18\x01 \x01(\x09B5\xE0A\x02\xFAA/\x0A-privateca.googleapis.com/CertificateAuthority\x12\x1F\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x0B\xE0A\x01\xE2\x8C\xCF\xD7\x08\x02\x08\x01\x12'\x0A\x1Aignore_dependent_resources\x18\x03 \x01(\x08B\x03\xE0A\x01\"\x89\x01\x0A!EnableCertificateAuthorityRequest\x12C\x0A\x04name\x18\x01 \x01(\x09B5\xE0A\x02\xFAA/\x0A-privateca.googleapis.com/CertificateAuthority\x12\x1F\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x0B\xE0A\x01\xE2\x8C\xCF\xD7\x08\x02\x08\x01\"j\x0A#FetchCertificateAuthorityCsrRequest\x12C\x0A\x04name\x18\x01 \x01(\x09B5\xE0A\x02\xFAA/\x0A-privateca.googleapis.com/CertificateAuthority\"<\x0A\$FetchCertificateAuthorityCsrResponse\x12\x14\x0A\x07pem_csr\x18\x01 \x01(\x09B\x03\xE0A\x03\"e\x0A\x1EGetCertificateAuthorityRequest\x12C\x0A\x04name\x18\x01 \x01(\x09B5\xE0A\x02\xFAA/\x0A-privateca.googleapis.com/CertificateAuthority\"\xB9\x01\x0A!ListCertificateAuthoritiesRequest\x127\x0A\x06parent\x18\x01 \x01(\x09B'\xE0A\x02\xFAA!\x0A\x1Fprivateca.googleapis.com/CaPool\x12\x16\x0A\x09page_size\x18\x02 \x01(\x05B\x03\xE0A\x01\x12\x17\x0A\x0Apage_token\x18\x03 \x01(\x09B\x03\xE0A\x01\x12\x13\x0A\x06filter\x18\x04 \x01(\x09B\x03\xE0A\x01\x12\x15\x0A\x08order_by\x18\x05 \x01(\x09B\x03\xE0A\x01\"\xAD\x01\x0A\"ListCertificateAuthoritiesResponse\x12Y\x0A\x17certificate_authorities\x18\x01 \x03(\x0B28.google.cloud.security.privateca.v1.CertificateAuthority\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\x12\x13\x0A\x0Bunreachable\x18\x03 \x03(\x09\"\x8B\x01\x0A#UndeleteCertificateAuthorityRequest\x12C\x0A\x04name\x18\x01 \x01(\x09B5\xE0A\x02\xFAA/\x0A-privateca.googleapis.com/CertificateAuthority\x12\x1F\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x0B\xE0A\x01\xE2\x8C\xCF\xD7\x08\x02\x08\x01\"\xFB\x01\x0A!DeleteCertificateAuthorityRequest\x12C\x0A\x04name\x18\x01 \x01(\x09B5\xE0A\x02\xFAA/\x0A-privateca.googleapis.com/CertificateAuthority\x12\x1F\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x0B\xE0A\x01\xE2\x8C\xCF\xD7\x08\x02\x08\x01\x12'\x0A\x1Aignore_active_certificates\x18\x04 \x01(\x08B\x03\xE0A\x01\x12\x1E\x0A\x11skip_grace_period\x18\x05 \x01(\x08B\x03\xE0A\x01\x12'\x0A\x1Aignore_dependent_resources\x18\x06 \x01(\x08B\x03\xE0A\x01\"\xD8\x01\x0A!UpdateCertificateAuthorityRequest\x12\\\x0A\x15certificate_authority\x18\x01 \x01(\x0B28.google.cloud.security.privateca.v1.CertificateAuthorityB\x03\xE0A\x02\x124\x0A\x0Bupdate_mask\x18\x02 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x02\x12\x1F\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x0B\xE0A\x01\xE2\x8C\xCF\xD7\x08\x02\x08\x01\"\xCC\x01\x0A\x13CreateCaPoolRequest\x129\x0A\x06parent\x18\x01 \x01(\x09B)\xE0A\x02\xFAA#\x0A!locations.googleapis.com/Location\x12\x17\x0A\x0Aca_pool_id\x18\x02 \x01(\x09B\x03\xE0A\x02\x12@\x0A\x07ca_pool\x18\x03 \x01(\x0B2*.google.cloud.security.privateca.v1.CaPoolB\x03\xE0A\x02\x12\x1F\x0A\x0Arequest_id\x18\x04 \x01(\x09B\x0B\xE0A\x01\xE2\x8C\xCF\xD7\x08\x02\x08\x01\"\xAE\x01\x0A\x13UpdateCaPoolRequest\x12@\x0A\x07ca_pool\x18\x01 \x01(\x0B2*.google.cloud.security.privateca.v1.CaPoolB\x03\xE0A\x02\x124\x0A\x0Bupdate_mask\x18\x02 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x02\x12\x1F\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x0B\xE0A\x01\xE2\x8C\xCF\xD7\x08\x02\x08\x01\"\x96\x01\x0A\x13DeleteCaPoolRequest\x125\x0A\x04name\x18\x01 \x01(\x09B'\xE0A\x02\xFAA!\x0A\x1Fprivateca.googleapis.com/CaPool\x12\x1F\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x0B\xE0A\x01\xE2\x8C\xCF\xD7\x08\x02\x08\x01\x12'\x0A\x1Aignore_dependent_resources\x18\x04 \x01(\x08B\x03\xE0A\x01\"h\x0A\x13FetchCaCertsRequest\x128\x0A\x07ca_pool\x18\x01 \x01(\x09B'\xE0A\x02\xFAA!\x0A\x1Fprivateca.googleapis.com/CaPool\x12\x17\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x03\xE0A\x01\"\x8F\x01\x0A\x14FetchCaCertsResponse\x12T\x0A\x08ca_certs\x18\x01 \x03(\x0B2B.google.cloud.security.privateca.v1.FetchCaCertsResponse.CertChain\x1A!\x0A\x09CertChain\x12\x14\x0A\x0Ccertificates\x18\x01 \x03(\x09\"I\x0A\x10GetCaPoolRequest\x125\x0A\x04name\x18\x01 \x01(\x09B'\xE0A\x02\xFAA!\x0A\x1Fprivateca.googleapis.com/CaPool\"\xAC\x01\x0A\x12ListCaPoolsRequest\x129\x0A\x06parent\x18\x01 \x01(\x09B)\xE0A\x02\xFAA#\x0A!locations.googleapis.com/Location\x12\x16\x0A\x09page_size\x18\x02 \x01(\x05B\x03\xE0A\x01\x12\x17\x0A\x0Apage_token\x18\x03 \x01(\x09B\x03\xE0A\x01\x12\x13\x0A\x06filter\x18\x04 \x01(\x09B\x03\xE0A\x01\x12\x15\x0A\x08order_by\x18\x05 \x01(\x09B\x03\xE0A\x01\"\x81\x01\x0A\x13ListCaPoolsResponse\x12<\x0A\x08ca_pools\x18\x01 \x03(\x0B2*.google.cloud.security.privateca.v1.CaPool\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\x12\x13\x0A\x0Bunreachable\x18\x03 \x03(\x09\"o\x0A#GetCertificateRevocationListRequest\x12H\x0A\x04name\x18\x01 \x01(\x09B:\xE0A\x02\xFAA4\x0A2privateca.googleapis.com/CertificateRevocationList\"\xCB\x01\x0A%ListCertificateRevocationListsRequest\x12E\x0A\x06parent\x18\x01 \x01(\x09B5\xE0A\x02\xFAA/\x0A-privateca.googleapis.com/CertificateAuthority\x12\x16\x0A\x09page_size\x18\x02 \x01(\x05B\x03\xE0A\x01\x12\x17\x0A\x0Apage_token\x18\x03 \x01(\x09B\x03\xE0A\x01\x12\x13\x0A\x06filter\x18\x04 \x01(\x09B\x03\xE0A\x01\x12\x15\x0A\x08order_by\x18\x05 \x01(\x09B\x03\xE0A\x01\"\xBB\x01\x0A&ListCertificateRevocationListsResponse\x12c\x0A\x1Ccertificate_revocation_lists\x18\x01 \x03(\x0B2=.google.cloud.security.privateca.v1.CertificateRevocationList\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\x12\x13\x0A\x0Bunreachable\x18\x03 \x03(\x09\"\xE0\x01\x0A&UpdateCertificateRevocationListRequest\x12g\x0A\x1Bcertificate_revocation_list\x18\x01 \x01(\x0B2=.google.cloud.security.privateca.v1.CertificateRevocationListB\x03\xE0A\x02\x124\x0A\x0Bupdate_mask\x18\x02 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x03\xE0A\x01\"\x80\x02\x0A CreateCertificateTemplateRequest\x129\x0A\x06parent\x18\x01 \x01(\x09B)\xE0A\x02\xFAA#\x0A!locations.googleapis.com/Location\x12\$\x0A\x17certificate_template_id\x18\x02 \x01(\x09B\x03\xE0A\x02\x12Z\x0A\x14certificate_template\x18\x03 \x01(\x0B27.google.cloud.security.privateca.v1.CertificateTemplateB\x03\xE0A\x02\x12\x1F\x0A\x0Arequest_id\x18\x04 \x01(\x09B\x0B\xE0A\x01\xE2\x8C\xCF\xD7\x08\x02\x08\x01\"\x87\x01\x0A DeleteCertificateTemplateRequest\x12B\x0A\x04name\x18\x01 \x01(\x09B4\xE0A\x02\xFAA.\x0A,privateca.googleapis.com/CertificateTemplate\x12\x1F\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x0B\xE0A\x01\xE2\x8C\xCF\xD7\x08\x02\x08\x01\"c\x0A\x1DGetCertificateTemplateRequest\x12B\x0A\x04name\x18\x01 \x01(\x09B4\xE0A\x02\xFAA.\x0A,privateca.googleapis.com/CertificateTemplate\"\xB9\x01\x0A\x1FListCertificateTemplatesRequest\x129\x0A\x06parent\x18\x01 \x01(\x09B)\xE0A\x02\xFAA#\x0A!locations.googleapis.com/Location\x12\x16\x0A\x09page_size\x18\x02 \x01(\x05B\x03\xE0A\x01\x12\x17\x0A\x0Apage_token\x18\x03 \x01(\x09B\x03\xE0A\x01\x12\x13\x0A\x06filter\x18\x04 \x01(\x09B\x03\xE0A\x01\x12\x15\x0A\x08order_by\x18\x05 \x01(\x09B\x03\xE0A\x01\"\xA8\x01\x0A ListCertificateTemplatesResponse\x12V\x0A\x15certificate_templates\x18\x01 \x03(\x0B27.google.cloud.security.privateca.v1.CertificateTemplate\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\x12\x13\x0A\x0Bunreachable\x18\x03 \x03(\x09\"\xD5\x01\x0A UpdateCertificateTemplateRequest\x12Z\x0A\x14certificate_template\x18\x01 \x01(\x0B27.google.cloud.security.privateca.v1.CertificateTemplateB\x03\xE0A\x02\x124\x0A\x0Bupdate_mask\x18\x02 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x02\x12\x1F\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x0B\xE0A\x01\xE2\x8C\xCF\xD7\x08\x02\x08\x01\"\x80\x02\x0A\x11OperationMetadata\x124\x0A\x0Bcreate_time\x18\x01 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x121\x0A\x08end_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12\x13\x0A\x06target\x18\x03 \x01(\x09B\x03\xE0A\x03\x12\x11\x0A\x04verb\x18\x04 \x01(\x09B\x03\xE0A\x03\x12\x1B\x0A\x0Estatus_message\x18\x05 \x01(\x09B\x03\xE0A\x03\x12#\x0A\x16requested_cancellation\x18\x06 \x01(\x08B\x03\xE0A\x03\x12\x18\x0A\x0Bapi_version\x18\x07 \x01(\x09B\x03\xE0A\x032\xFA;\x0A\x1BCertificateAuthorityService\x12\xF7\x01\x0A\x11CreateCertificate\x12<.google.cloud.security.privateca.v1.CreateCertificateRequest\x1A/.google.cloud.security.privateca.v1.Certificate\"s\xDAA!parent,certificate,certificate_id\x82\xD3\xE4\x93\x02I\":/v1/{parent=projects/*/locations/*/caPools/*}/certificates:\x0Bcertificate\x12\xC7\x01\x0A\x0EGetCertificate\x129.google.cloud.security.privateca.v1.GetCertificateRequest\x1A/.google.cloud.security.privateca.v1.Certificate\"I\xDAA\x04name\x82\xD3\xE4\x93\x02<\x12:/v1/{name=projects/*/locations/*/caPools/*/certificates/*}\x12\xDA\x01\x0A\x10ListCertificates\x12;.google.cloud.security.privateca.v1.ListCertificatesRequest\x1A<.google.cloud.security.privateca.v1.ListCertificatesResponse\"K\xDAA\x06parent\x82\xD3\xE4\x93\x02<\x12:/v1/{parent=projects/*/locations/*/caPools/*}/certificates\x12\xD7\x01\x0A\x11RevokeCertificate\x12<.google.cloud.security.privateca.v1.RevokeCertificateRequest\x1A/.google.cloud.security.privateca.v1.Certificate\"S\xDAA\x04name\x82\xD3\xE4\x93\x02F\"A/v1/{name=projects/*/locations/*/caPools/*/certificates/*}:revoke:\x01*\x12\xF9\x01\x0A\x11UpdateCertificate\x12<.google.cloud.security.privateca.v1.UpdateCertificateRequest\x1A/.google.cloud.security.privateca.v1.Certificate\"u\xDAA\x17certificate,update_mask\x82\xD3\xE4\x93\x02U2F/v1/{certificate.name=projects/*/locations/*/caPools/*/certificates/*}:\x0Bcertificate\x12\x94\x02\x0A\x1CActivateCertificateAuthority\x12G.google.cloud.security.privateca.v1.ActivateCertificateAuthorityRequest\x1A\x1D.google.longrunning.Operation\"\x8B\x01\xCAA)\x0A\x14CertificateAuthority\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x02R\"M/v1/{name=projects/*/locations/*/caPools/*/certificateAuthorities/*}:activate:\x01*\x12\xCC\x02\x0A\x1ACreateCertificateAuthority\x12E.google.cloud.security.privateca.v1.CreateCertificateAuthorityRequest\x1A\x1D.google.longrunning.Operation\"\xC7\x01\xCAA)\x0A\x14CertificateAuthority\x12\x11OperationMetadata\xDAA5parent,certificate_authority,certificate_authority_id\x82\xD3\xE4\x93\x02]\"D/v1/{parent=projects/*/locations/*/caPools/*}/certificateAuthorities:\x15certificate_authority\x12\x91\x02\x0A\x1BDisableCertificateAuthority\x12F.google.cloud.security.privateca.v1.DisableCertificateAuthorityRequest\x1A\x1D.google.longrunning.Operation\"\x8A\x01\xCAA)\x0A\x14CertificateAuthority\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x02Q\"L/v1/{name=projects/*/locations/*/caPools/*/certificateAuthorities/*}:disable:\x01*\x12\x8E\x02\x0A\x1AEnableCertificateAuthority\x12E.google.cloud.security.privateca.v1.EnableCertificateAuthorityRequest\x1A\x1D.google.longrunning.Operation\"\x89\x01\xCAA)\x0A\x14CertificateAuthority\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x02P\"K/v1/{name=projects/*/locations/*/caPools/*/certificateAuthorities/*}:enable:\x01*\x12\x8C\x02\x0A\x1CFetchCertificateAuthorityCsr\x12G.google.cloud.security.privateca.v1.FetchCertificateAuthorityCsrRequest\x1AH.google.cloud.security.privateca.v1.FetchCertificateAuthorityCsrResponse\"Y\xDAA\x04name\x82\xD3\xE4\x93\x02L\x12J/v1/{name=projects/*/locations/*/caPools/*/certificateAuthorities/*}:fetch\x12\xEC\x01\x0A\x17GetCertificateAuthority\x12B.google.cloud.security.privateca.v1.GetCertificateAuthorityRequest\x1A8.google.cloud.security.privateca.v1.CertificateAuthority\"S\xDAA\x04name\x82\xD3\xE4\x93\x02F\x12D/v1/{name=projects/*/locations/*/caPools/*/certificateAuthorities/*}\x12\x82\x02\x0A\x1AListCertificateAuthorities\x12E.google.cloud.security.privateca.v1.ListCertificateAuthoritiesRequest\x1AF.google.cloud.security.privateca.v1.ListCertificateAuthoritiesResponse\"U\xDAA\x06parent\x82\xD3\xE4\x93\x02F\x12D/v1/{parent=projects/*/locations/*/caPools/*}/certificateAuthorities\x12\x94\x02\x0A\x1CUndeleteCertificateAuthority\x12G.google.cloud.security.privateca.v1.UndeleteCertificateAuthorityRequest\x1A\x1D.google.longrunning.Operation\"\x8B\x01\xCAA)\x0A\x14CertificateAuthority\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x02R\"M/v1/{name=projects/*/locations/*/caPools/*/certificateAuthorities/*}:undelete:\x01*\x12\x83\x02\x0A\x1ADeleteCertificateAuthority\x12E.google.cloud.security.privateca.v1.DeleteCertificateAuthorityRequest\x1A\x1D.google.longrunning.Operation\"\x7F\xCAA)\x0A\x14CertificateAuthority\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x02F*D/v1/{name=projects/*/locations/*/caPools/*/certificateAuthorities/*}\x12\xCE\x02\x0A\x1AUpdateCertificateAuthority\x12E.google.cloud.security.privateca.v1.UpdateCertificateAuthorityRequest\x1A\x1D.google.longrunning.Operation\"\xC9\x01\xCAA)\x0A\x14CertificateAuthority\x12\x11OperationMetadata\xDAA!certificate_authority,update_mask\x82\xD3\xE4\x93\x02s2Z/v1/{certificate_authority.name=projects/*/locations/*/caPools/*/certificateAuthorities/*}:\x15certificate_authority\x12\xDE\x01\x0A\x0CCreateCaPool\x127.google.cloud.security.privateca.v1.CreateCaPoolRequest\x1A\x1D.google.longrunning.Operation\"v\xCAA\x1B\x0A\x06CaPool\x12\x11OperationMetadata\xDAA\x19parent,ca_pool,ca_pool_id\x82\xD3\xE4\x93\x026\"+/v1/{parent=projects/*/locations/*}/caPools:\x07ca_pool\x12\xE0\x01\x0A\x0CUpdateCaPool\x127.google.cloud.security.privateca.v1.UpdateCaPoolRequest\x1A\x1D.google.longrunning.Operation\"x\xCAA\x1B\x0A\x06CaPool\x12\x11OperationMetadata\xDAA\x13ca_pool,update_mask\x82\xD3\xE4\x93\x02>23/v1/{ca_pool.name=projects/*/locations/*/caPools/*}:\x07ca_pool\x12\xA9\x01\x0A\x09GetCaPool\x124.google.cloud.security.privateca.v1.GetCaPoolRequest\x1A*.google.cloud.security.privateca.v1.CaPool\":\xDAA\x04name\x82\xD3\xE4\x93\x02-\x12+/v1/{name=projects/*/locations/*/caPools/*}\x12\xBC\x01\x0A\x0BListCaPools\x126.google.cloud.security.privateca.v1.ListCaPoolsRequest\x1A7.google.cloud.security.privateca.v1.ListCaPoolsResponse\"<\xDAA\x06parent\x82\xD3\xE4\x93\x02-\x12+/v1/{parent=projects/*/locations/*}/caPools\x12\xCF\x01\x0A\x0CDeleteCaPool\x127.google.cloud.security.privateca.v1.DeleteCaPoolRequest\x1A\x1D.google.longrunning.Operation\"g\xCAA*\x0A\x15google.protobuf.Empty\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x02-*+/v1/{name=projects/*/locations/*/caPools/*}\x12\xD3\x01\x0A\x0CFetchCaCerts\x127.google.cloud.security.privateca.v1.FetchCaCertsRequest\x1A8.google.cloud.security.privateca.v1.FetchCaCertsResponse\"P\xDAA\x07ca_pool\x82\xD3\xE4\x93\x02@\";/v1/{ca_pool=projects/*/locations/*/caPools/*}:fetchCaCerts:\x01*\x12\x98\x02\x0A\x1CGetCertificateRevocationList\x12G.google.cloud.security.privateca.v1.GetCertificateRevocationListRequest\x1A=.google.cloud.security.privateca.v1.CertificateRevocationList\"p\xDAA\x04name\x82\xD3\xE4\x93\x02c\x12a/v1/{name=projects/*/locations/*/caPools/*/certificateAuthorities/*/certificateRevocationLists/*}\x12\xAB\x02\x0A\x1EListCertificateRevocationLists\x12I.google.cloud.security.privateca.v1.ListCertificateRevocationListsRequest\x1AJ.google.cloud.security.privateca.v1.ListCertificateRevocationListsResponse\"r\xDAA\x06parent\x82\xD3\xE4\x93\x02c\x12a/v1/{parent=projects/*/locations/*/caPools/*/certificateAuthorities/*}/certificateRevocationLists\x12\x8D\x03\x0A\x1FUpdateCertificateRevocationList\x12J.google.cloud.security.privateca.v1.UpdateCertificateRevocationListRequest\x1A\x1D.google.longrunning.Operation\"\xFE\x01\xCAA.\x0A\x19CertificateRevocationList\x12\x11OperationMetadata\xDAA'certificate_revocation_list,update_mask\x82\xD3\xE4\x93\x02\x9C\x012}/v1/{certificate_revocation_list.name=projects/*/locations/*/caPools/*/certificateAuthorities/*/certificateRevocationLists/*}:\x1Bcertificate_revocation_list\x12\xBA\x02\x0A\x19CreateCertificateTemplate\x12D.google.cloud.security.privateca.v1.CreateCertificateTemplateRequest\x1A\x1D.google.longrunning.Operation\"\xB7\x01\xCAA(\x0A\x13CertificateTemplate\x12\x11OperationMetadata\xDAA3parent,certificate_template,certificate_template_id\x82\xD3\xE4\x93\x02P\"8/v1/{parent=projects/*/locations/*}/certificateTemplates:\x14certificate_template\x12\x9A\x02\x0A\x19DeleteCertificateTemplate\x12D.google.cloud.security.privateca.v1.DeleteCertificateTemplateRequest\x1A\x1D.google.longrunning.Operation\"\x97\x01\xCAAM\x0A\x15google.protobuf.Empty\x124google.cloud.security.privateca.v1.OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x02:*8/v1/{name=projects/*/locations/*/certificateTemplates/*}\x12\xDD\x01\x0A\x16GetCertificateTemplate\x12A.google.cloud.security.privateca.v1.GetCertificateTemplateRequest\x1A7.google.cloud.security.privateca.v1.CertificateTemplate\"G\xDAA\x04name\x82\xD3\xE4\x93\x02:\x128/v1/{name=projects/*/locations/*/certificateTemplates/*}\x12\xF0\x01\x0A\x18ListCertificateTemplates\x12C.google.cloud.security.privateca.v1.ListCertificateTemplatesRequest\x1AD.google.cloud.security.privateca.v1.ListCertificateTemplatesResponse\"I\xDAA\x06parent\x82\xD3\xE4\x93\x02:\x128/v1/{parent=projects/*/locations/*}/certificateTemplates\x12\xBC\x02\x0A\x19UpdateCertificateTemplate\x12D.google.cloud.security.privateca.v1.UpdateCertificateTemplateRequest\x1A\x1D.google.longrunning.Operation\"\xB9\x01\xCAA(\x0A\x13CertificateTemplate\x12\x11OperationMetadata\xDAA certificate_template,update_mask\x82\xD3\xE4\x93\x02e2M/v1/{certificate_template.name=projects/*/locations/*/certificateTemplates/*}:\x14certificate_template\x1AL\xCAA\x18privateca.googleapis.com\xD2A.https://www.googleapis.com/auth/cloud-platformB\xF3\x01\x0A&com.google.cloud.security.privateca.v1B\x0EPrivateCaProtoP\x01ZDcloud.google.com/go/security/privateca/apiv1/privatecapb;privatecapb\xAA\x02\"Google.Cloud.Security.PrivateCA.V1\xCA\x02\"Google\\Cloud\\Security\\PrivateCA\\V1\xEA\x02&Google::Cloud::Security::PrivateCA::V1b\x06proto3" - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ActivateCertificateAuthorityRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ActivateCertificateAuthorityRequest.php deleted file mode 100644 index 8e1b5c725c04..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ActivateCertificateAuthorityRequest.php +++ /dev/null @@ -1,252 +0,0 @@ -google.cloud.security.privateca.v1.ActivateCertificateAuthorityRequest - */ -class ActivateCertificateAuthorityRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name for this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Required. The signed CA certificate issued from - * [FetchCertificateAuthorityCsrResponse.pem_csr][google.cloud.security.privateca.v1.FetchCertificateAuthorityCsrResponse.pem_csr]. - * - * Generated from protobuf field string pem_ca_certificate = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $pem_ca_certificate = ''; - /** - * Required. Must include information about the issuer of - * 'pem_ca_certificate', and any further issuers until the self-signed CA. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.SubordinateConfig subordinate_config = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $subordinate_config = null; - /** - * Optional. An 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, (.google.api.field_info) = { - */ - protected $request_id = ''; - - /** - * @param string $name Required. The resource name for this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the format `projects/*/locations/*/caPools/*/certificateAuthorities/*`. Please see - * {@see CertificateAuthorityServiceClient::certificateAuthorityName()} for help formatting this field. - * - * @return \Google\Cloud\Security\PrivateCA\V1\ActivateCertificateAuthorityRequest - * - * @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 for this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. - * @type string $pem_ca_certificate - * Required. The signed CA certificate issued from - * [FetchCertificateAuthorityCsrResponse.pem_csr][google.cloud.security.privateca.v1.FetchCertificateAuthorityCsrResponse.pem_csr]. - * @type \Google\Cloud\Security\PrivateCA\V1\SubordinateConfig $subordinate_config - * Required. Must include information about the issuer of - * 'pem_ca_certificate', and any further issuers until the self-signed CA. - * @type string $request_id - * Optional. An 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\Security\Privateca\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name for this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. - * - * 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 for this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. - * - * 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 signed CA certificate issued from - * [FetchCertificateAuthorityCsrResponse.pem_csr][google.cloud.security.privateca.v1.FetchCertificateAuthorityCsrResponse.pem_csr]. - * - * Generated from protobuf field string pem_ca_certificate = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getPemCaCertificate() - { - return $this->pem_ca_certificate; - } - - /** - * Required. The signed CA certificate issued from - * [FetchCertificateAuthorityCsrResponse.pem_csr][google.cloud.security.privateca.v1.FetchCertificateAuthorityCsrResponse.pem_csr]. - * - * Generated from protobuf field string pem_ca_certificate = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setPemCaCertificate($var) - { - GPBUtil::checkString($var, True); - $this->pem_ca_certificate = $var; - - return $this; - } - - /** - * Required. Must include information about the issuer of - * 'pem_ca_certificate', and any further issuers until the self-signed CA. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.SubordinateConfig subordinate_config = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Security\PrivateCA\V1\SubordinateConfig|null - */ - public function getSubordinateConfig() - { - return $this->subordinate_config; - } - - public function hasSubordinateConfig() - { - return isset($this->subordinate_config); - } - - public function clearSubordinateConfig() - { - unset($this->subordinate_config); - } - - /** - * Required. Must include information about the issuer of - * 'pem_ca_certificate', and any further issuers until the self-signed CA. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.SubordinateConfig subordinate_config = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Security\PrivateCA\V1\SubordinateConfig $var - * @return $this - */ - public function setSubordinateConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\SubordinateConfig::class); - $this->subordinate_config = $var; - - return $this; - } - - /** - * Optional. An 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, (.google.api.field_info) = { - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. An 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, (.google.api.field_info) = { - * @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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/AttributeType.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/AttributeType.php deleted file mode 100644 index d96495de8a1e..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/AttributeType.php +++ /dev/null @@ -1,104 +0,0 @@ -google.cloud.security.privateca.v1.AttributeType - */ -class AttributeType -{ - /** - * Attribute type is unspecified. - * - * Generated from protobuf enum ATTRIBUTE_TYPE_UNSPECIFIED = 0; - */ - const ATTRIBUTE_TYPE_UNSPECIFIED = 0; - /** - * The "common name" of the subject. - * - * Generated from protobuf enum COMMON_NAME = 1; - */ - const COMMON_NAME = 1; - /** - * The country code of the subject. - * - * Generated from protobuf enum COUNTRY_CODE = 2; - */ - const COUNTRY_CODE = 2; - /** - * The organization of the subject. - * - * Generated from protobuf enum ORGANIZATION = 3; - */ - const ORGANIZATION = 3; - /** - * The organizational unit of the subject. - * - * Generated from protobuf enum ORGANIZATIONAL_UNIT = 4; - */ - const ORGANIZATIONAL_UNIT = 4; - /** - * The locality or city of the subject. - * - * Generated from protobuf enum LOCALITY = 5; - */ - const LOCALITY = 5; - /** - * The province, territory, or regional state of the subject. - * - * Generated from protobuf enum PROVINCE = 6; - */ - const PROVINCE = 6; - /** - * The street address of the subject. - * - * Generated from protobuf enum STREET_ADDRESS = 7; - */ - const STREET_ADDRESS = 7; - /** - * The postal code of the subject. - * - * Generated from protobuf enum POSTAL_CODE = 8; - */ - const POSTAL_CODE = 8; - - private static $valueToName = [ - self::ATTRIBUTE_TYPE_UNSPECIFIED => 'ATTRIBUTE_TYPE_UNSPECIFIED', - self::COMMON_NAME => 'COMMON_NAME', - self::COUNTRY_CODE => 'COUNTRY_CODE', - self::ORGANIZATION => 'ORGANIZATION', - self::ORGANIZATIONAL_UNIT => 'ORGANIZATIONAL_UNIT', - self::LOCALITY => 'LOCALITY', - self::PROVINCE => 'PROVINCE', - self::STREET_ADDRESS => 'STREET_ADDRESS', - self::POSTAL_CODE => 'POSTAL_CODE', - ]; - - 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/AttributeTypeAndValue.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/AttributeTypeAndValue.php deleted file mode 100644 index 532af418ab7f..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/AttributeTypeAndValue.php +++ /dev/null @@ -1,144 +0,0 @@ -google.cloud.security.privateca.v1.AttributeTypeAndValue - */ -class AttributeTypeAndValue extends \Google\Protobuf\Internal\Message -{ - /** - * The value for the attribute type. - * - * Generated from protobuf field string value = 3; - */ - protected $value = ''; - protected $attribute_type; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $type - * The attribute type of the attribute and value pair. - * @type \Google\Cloud\Security\PrivateCA\V1\ObjectId $object_id - * Object ID for an attribute type of an attribute and value pair. - * @type string $value - * The value for the attribute type. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * The attribute type of the attribute and value pair. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.AttributeType type = 1; - * @return int - */ - public function getType() - { - return $this->readOneof(1); - } - - public function hasType() - { - return $this->hasOneof(1); - } - - /** - * The attribute type of the attribute and value pair. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.AttributeType type = 1; - * @param int $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Security\PrivateCA\V1\AttributeType::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * Object ID for an attribute type of an attribute and value pair. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.ObjectId object_id = 2; - * @return \Google\Cloud\Security\PrivateCA\V1\ObjectId|null - */ - public function getObjectId() - { - return $this->readOneof(2); - } - - public function hasObjectId() - { - return $this->hasOneof(2); - } - - /** - * Object ID for an attribute type of an attribute and value pair. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.ObjectId object_id = 2; - * @param \Google\Cloud\Security\PrivateCA\V1\ObjectId $var - * @return $this - */ - public function setObjectId($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\ObjectId::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * The value for the attribute type. - * - * Generated from protobuf field string value = 3; - * @return string - */ - public function getValue() - { - return $this->value; - } - - /** - * The value for the attribute type. - * - * Generated from protobuf field string value = 3; - * @param string $var - * @return $this - */ - public function setValue($var) - { - GPBUtil::checkString($var, True); - $this->value = $var; - - return $this; - } - - /** - * @return string - */ - public function getAttributeType() - { - return $this->whichOneof("attribute_type"); - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool.php deleted file mode 100644 index 73c9ce2d9be6..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool.php +++ /dev/null @@ -1,341 +0,0 @@ -google.cloud.security.privateca.v1.CaPool - */ -class CaPool extends \Google\Protobuf\Internal\Message -{ - /** - * Identifier. The resource name for this - * [CaPool][google.cloud.security.privateca.v1.CaPool] in the format - * `projects/{@*}locations/{@*}caPools/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; - */ - protected $name = ''; - /** - * Required. Immutable. The - * [Tier][google.cloud.security.privateca.v1.CaPool.Tier] of this - * [CaPool][google.cloud.security.privateca.v1.CaPool]. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.Tier tier = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; - */ - protected $tier = 0; - /** - * Optional. The - * [IssuancePolicy][google.cloud.security.privateca.v1.CaPool.IssuancePolicy] - * to control how - * [Certificates][google.cloud.security.privateca.v1.Certificate] will be - * issued from this [CaPool][google.cloud.security.privateca.v1.CaPool]. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.IssuancePolicy issuance_policy = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $issuance_policy = null; - /** - * Optional. The - * [PublishingOptions][google.cloud.security.privateca.v1.CaPool.PublishingOptions] - * to follow when issuing - * [Certificates][google.cloud.security.privateca.v1.Certificate] from any - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in this [CaPool][google.cloud.security.privateca.v1.CaPool]. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.PublishingOptions publishing_options = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $publishing_options = null; - /** - * Optional. When - * [EncryptionSpec][google.cloud.security.privateca.v1.EncryptionSpec] is - * provided, the [Subject][google.cloud.security.privateca.v1.Subject], - * [SubjectAltNames][google.cloud.security.privateca.v1.SubjectAltNames], and - * the PEM-encoded certificate fields will be encrypted at rest. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.EncryptionSpec encryption_spec = 8 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $encryption_spec = null; - /** - * Optional. Labels with user-defined metadata. - * - * Generated from protobuf field map labels = 5 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $labels; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Identifier. The resource name for this - * [CaPool][google.cloud.security.privateca.v1.CaPool] in the format - * `projects/{@*}locations/{@*}caPools/*`. - * @type int $tier - * Required. Immutable. The - * [Tier][google.cloud.security.privateca.v1.CaPool.Tier] of this - * [CaPool][google.cloud.security.privateca.v1.CaPool]. - * @type \Google\Cloud\Security\PrivateCA\V1\CaPool\IssuancePolicy $issuance_policy - * Optional. The - * [IssuancePolicy][google.cloud.security.privateca.v1.CaPool.IssuancePolicy] - * to control how - * [Certificates][google.cloud.security.privateca.v1.Certificate] will be - * issued from this [CaPool][google.cloud.security.privateca.v1.CaPool]. - * @type \Google\Cloud\Security\PrivateCA\V1\CaPool\PublishingOptions $publishing_options - * Optional. The - * [PublishingOptions][google.cloud.security.privateca.v1.CaPool.PublishingOptions] - * to follow when issuing - * [Certificates][google.cloud.security.privateca.v1.Certificate] from any - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in this [CaPool][google.cloud.security.privateca.v1.CaPool]. - * @type \Google\Cloud\Security\PrivateCA\V1\EncryptionSpec $encryption_spec - * Optional. When - * [EncryptionSpec][google.cloud.security.privateca.v1.EncryptionSpec] is - * provided, the [Subject][google.cloud.security.privateca.v1.Subject], - * [SubjectAltNames][google.cloud.security.privateca.v1.SubjectAltNames], and - * the PEM-encoded certificate fields will be encrypted at rest. - * @type array|\Google\Protobuf\Internal\MapField $labels - * Optional. Labels with user-defined metadata. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * Identifier. The resource name for this - * [CaPool][google.cloud.security.privateca.v1.CaPool] in the format - * `projects/{@*}locations/{@*}caPools/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Identifier. The resource name for this - * [CaPool][google.cloud.security.privateca.v1.CaPool] in the format - * `projects/{@*}locations/{@*}caPools/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Required. Immutable. The - * [Tier][google.cloud.security.privateca.v1.CaPool.Tier] of this - * [CaPool][google.cloud.security.privateca.v1.CaPool]. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.Tier tier = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; - * @return int - */ - public function getTier() - { - return $this->tier; - } - - /** - * Required. Immutable. The - * [Tier][google.cloud.security.privateca.v1.CaPool.Tier] of this - * [CaPool][google.cloud.security.privateca.v1.CaPool]. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.Tier tier = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; - * @param int $var - * @return $this - */ - public function setTier($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Security\PrivateCA\V1\CaPool\Tier::class); - $this->tier = $var; - - return $this; - } - - /** - * Optional. The - * [IssuancePolicy][google.cloud.security.privateca.v1.CaPool.IssuancePolicy] - * to control how - * [Certificates][google.cloud.security.privateca.v1.Certificate] will be - * issued from this [CaPool][google.cloud.security.privateca.v1.CaPool]. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.IssuancePolicy issuance_policy = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\Security\PrivateCA\V1\CaPool\IssuancePolicy|null - */ - public function getIssuancePolicy() - { - return $this->issuance_policy; - } - - public function hasIssuancePolicy() - { - return isset($this->issuance_policy); - } - - public function clearIssuancePolicy() - { - unset($this->issuance_policy); - } - - /** - * Optional. The - * [IssuancePolicy][google.cloud.security.privateca.v1.CaPool.IssuancePolicy] - * to control how - * [Certificates][google.cloud.security.privateca.v1.Certificate] will be - * issued from this [CaPool][google.cloud.security.privateca.v1.CaPool]. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.IssuancePolicy issuance_policy = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\Security\PrivateCA\V1\CaPool\IssuancePolicy $var - * @return $this - */ - public function setIssuancePolicy($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CaPool\IssuancePolicy::class); - $this->issuance_policy = $var; - - return $this; - } - - /** - * Optional. The - * [PublishingOptions][google.cloud.security.privateca.v1.CaPool.PublishingOptions] - * to follow when issuing - * [Certificates][google.cloud.security.privateca.v1.Certificate] from any - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in this [CaPool][google.cloud.security.privateca.v1.CaPool]. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.PublishingOptions publishing_options = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\Security\PrivateCA\V1\CaPool\PublishingOptions|null - */ - public function getPublishingOptions() - { - return $this->publishing_options; - } - - public function hasPublishingOptions() - { - return isset($this->publishing_options); - } - - public function clearPublishingOptions() - { - unset($this->publishing_options); - } - - /** - * Optional. The - * [PublishingOptions][google.cloud.security.privateca.v1.CaPool.PublishingOptions] - * to follow when issuing - * [Certificates][google.cloud.security.privateca.v1.Certificate] from any - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in this [CaPool][google.cloud.security.privateca.v1.CaPool]. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.PublishingOptions publishing_options = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\Security\PrivateCA\V1\CaPool\PublishingOptions $var - * @return $this - */ - public function setPublishingOptions($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CaPool\PublishingOptions::class); - $this->publishing_options = $var; - - return $this; - } - - /** - * Optional. When - * [EncryptionSpec][google.cloud.security.privateca.v1.EncryptionSpec] is - * provided, the [Subject][google.cloud.security.privateca.v1.Subject], - * [SubjectAltNames][google.cloud.security.privateca.v1.SubjectAltNames], and - * the PEM-encoded certificate fields will be encrypted at rest. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.EncryptionSpec encryption_spec = 8 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\Security\PrivateCA\V1\EncryptionSpec|null - */ - public function getEncryptionSpec() - { - return $this->encryption_spec; - } - - public function hasEncryptionSpec() - { - return isset($this->encryption_spec); - } - - public function clearEncryptionSpec() - { - unset($this->encryption_spec); - } - - /** - * Optional. When - * [EncryptionSpec][google.cloud.security.privateca.v1.EncryptionSpec] is - * provided, the [Subject][google.cloud.security.privateca.v1.Subject], - * [SubjectAltNames][google.cloud.security.privateca.v1.SubjectAltNames], and - * the PEM-encoded certificate fields will be encrypted at rest. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.EncryptionSpec encryption_spec = 8 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\Security\PrivateCA\V1\EncryptionSpec $var - * @return $this - */ - public function setEncryptionSpec($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\EncryptionSpec::class); - $this->encryption_spec = $var; - - return $this; - } - - /** - * Optional. Labels with user-defined metadata. - * - * Generated from protobuf field map labels = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Optional. Labels with user-defined metadata. - * - * Generated from protobuf field map labels = 5 [(.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; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy.php deleted file mode 100644 index 30739bffd916..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy.php +++ /dev/null @@ -1,602 +0,0 @@ -google.cloud.security.privateca.v1.CaPool.IssuancePolicy - */ -class IssuancePolicy extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. If any - * [AllowedKeyType][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyType] - * is specified, then the certificate request's public key must match one of - * the key types listed here. Otherwise, any key may be used. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyType allowed_key_types = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $allowed_key_types; - /** - * Optional. If set, all certificates issued from this - * [CaPool][google.cloud.security.privateca.v1.CaPool] will be backdated by - * this duration. The 'not_before_time' will be the issuance time minus this - * [backdate_duration][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.backdate_duration], - * and the 'not_after_time' will be adjusted to preserve the requested - * lifetime. The maximum duration that a certificate can be backdated with - * these options is 48 hours in the past. - * This option cannot be set if - * [allow_requester_specified_not_before_time][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.allow_requester_specified_not_before_time] - * is set. - * - * Generated from protobuf field .google.protobuf.Duration backdate_duration = 7 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $backdate_duration = null; - /** - * Optional. If set to true, allows requesters to specify the - * [requested_not_before_time][google.cloud.security.privateca.v1.Certificate.requested_not_before_time] - * field when creating a - * [Certificate][google.cloud.security.privateca.v1.Certificate]. - * Certificates requested with this option enabled will have a - * 'not_before_time' equal to the value specified in the request. The - * 'not_after_time' will be adjusted to preserve the requested lifetime. The - * maximum time that a certificate can be backdated with these options is 48 - * hours in the past. This option cannot be set if - * [backdate_duration][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.backdate_duration] - * is set. - * - * Generated from protobuf field bool allow_requester_specified_not_before_time = 8 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $allow_requester_specified_not_before_time = false; - /** - * Optional. The maximum lifetime allowed for issued - * [Certificates][google.cloud.security.privateca.v1.Certificate]. Note that - * if the issuing - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * expires before a - * [Certificate][google.cloud.security.privateca.v1.Certificate] resource's - * requested maximum_lifetime, the effective lifetime will be explicitly - * truncated to match it. - * - * Generated from protobuf field .google.protobuf.Duration maximum_lifetime = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $maximum_lifetime = null; - /** - * Optional. If specified, then only methods allowed in the - * [IssuanceModes][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.IssuanceModes] - * may be used to issue - * [Certificates][google.cloud.security.privateca.v1.Certificate]. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.IssuancePolicy.IssuanceModes allowed_issuance_modes = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $allowed_issuance_modes = null; - /** - * Optional. A set of X.509 values that will be applied to all certificates - * issued through this [CaPool][google.cloud.security.privateca.v1.CaPool]. - * If a certificate request includes conflicting values for the same - * properties, they will be overwritten by the values defined here. If a - * certificate request uses a - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * that defines conflicting - * [predefined_values][google.cloud.security.privateca.v1.CertificateTemplate.predefined_values] - * for the same properties, the certificate issuance request will fail. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.X509Parameters baseline_values = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $baseline_values = null; - /** - * Optional. Describes constraints on identities that may appear in - * [Certificates][google.cloud.security.privateca.v1.Certificate] issued - * through this [CaPool][google.cloud.security.privateca.v1.CaPool]. If this - * is omitted, then this [CaPool][google.cloud.security.privateca.v1.CaPool] - * will not add restrictions on a certificate's identity. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateIdentityConstraints identity_constraints = 5 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $identity_constraints = null; - /** - * Optional. Describes the set of X.509 extensions that may appear in a - * [Certificate][google.cloud.security.privateca.v1.Certificate] issued - * through this [CaPool][google.cloud.security.privateca.v1.CaPool]. If a - * certificate request sets extensions that don't appear in the - * [passthrough_extensions][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.passthrough_extensions], - * those extensions will be dropped. If a certificate request uses a - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * with - * [predefined_values][google.cloud.security.privateca.v1.CertificateTemplate.predefined_values] - * that don't appear here, the certificate issuance request will fail. If - * this is omitted, then this - * [CaPool][google.cloud.security.privateca.v1.CaPool] will not add - * restrictions on a certificate's X.509 extensions. These constraints do - * not apply to X.509 extensions set in this - * [CaPool][google.cloud.security.privateca.v1.CaPool]'s - * [baseline_values][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.baseline_values]. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateExtensionConstraints passthrough_extensions = 6 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $passthrough_extensions = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Security\PrivateCA\V1\CaPool\IssuancePolicy\AllowedKeyType[] $allowed_key_types - * Optional. If any - * [AllowedKeyType][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyType] - * is specified, then the certificate request's public key must match one of - * the key types listed here. Otherwise, any key may be used. - * @type \Google\Protobuf\Duration $backdate_duration - * Optional. If set, all certificates issued from this - * [CaPool][google.cloud.security.privateca.v1.CaPool] will be backdated by - * this duration. The 'not_before_time' will be the issuance time minus this - * [backdate_duration][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.backdate_duration], - * and the 'not_after_time' will be adjusted to preserve the requested - * lifetime. The maximum duration that a certificate can be backdated with - * these options is 48 hours in the past. - * This option cannot be set if - * [allow_requester_specified_not_before_time][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.allow_requester_specified_not_before_time] - * is set. - * @type bool $allow_requester_specified_not_before_time - * Optional. If set to true, allows requesters to specify the - * [requested_not_before_time][google.cloud.security.privateca.v1.Certificate.requested_not_before_time] - * field when creating a - * [Certificate][google.cloud.security.privateca.v1.Certificate]. - * Certificates requested with this option enabled will have a - * 'not_before_time' equal to the value specified in the request. The - * 'not_after_time' will be adjusted to preserve the requested lifetime. The - * maximum time that a certificate can be backdated with these options is 48 - * hours in the past. This option cannot be set if - * [backdate_duration][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.backdate_duration] - * is set. - * @type \Google\Protobuf\Duration $maximum_lifetime - * Optional. The maximum lifetime allowed for issued - * [Certificates][google.cloud.security.privateca.v1.Certificate]. Note that - * if the issuing - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * expires before a - * [Certificate][google.cloud.security.privateca.v1.Certificate] resource's - * requested maximum_lifetime, the effective lifetime will be explicitly - * truncated to match it. - * @type \Google\Cloud\Security\PrivateCA\V1\CaPool\IssuancePolicy\IssuanceModes $allowed_issuance_modes - * Optional. If specified, then only methods allowed in the - * [IssuanceModes][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.IssuanceModes] - * may be used to issue - * [Certificates][google.cloud.security.privateca.v1.Certificate]. - * @type \Google\Cloud\Security\PrivateCA\V1\X509Parameters $baseline_values - * Optional. A set of X.509 values that will be applied to all certificates - * issued through this [CaPool][google.cloud.security.privateca.v1.CaPool]. - * If a certificate request includes conflicting values for the same - * properties, they will be overwritten by the values defined here. If a - * certificate request uses a - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * that defines conflicting - * [predefined_values][google.cloud.security.privateca.v1.CertificateTemplate.predefined_values] - * for the same properties, the certificate issuance request will fail. - * @type \Google\Cloud\Security\PrivateCA\V1\CertificateIdentityConstraints $identity_constraints - * Optional. Describes constraints on identities that may appear in - * [Certificates][google.cloud.security.privateca.v1.Certificate] issued - * through this [CaPool][google.cloud.security.privateca.v1.CaPool]. If this - * is omitted, then this [CaPool][google.cloud.security.privateca.v1.CaPool] - * will not add restrictions on a certificate's identity. - * @type \Google\Cloud\Security\PrivateCA\V1\CertificateExtensionConstraints $passthrough_extensions - * Optional. Describes the set of X.509 extensions that may appear in a - * [Certificate][google.cloud.security.privateca.v1.Certificate] issued - * through this [CaPool][google.cloud.security.privateca.v1.CaPool]. If a - * certificate request sets extensions that don't appear in the - * [passthrough_extensions][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.passthrough_extensions], - * those extensions will be dropped. If a certificate request uses a - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * with - * [predefined_values][google.cloud.security.privateca.v1.CertificateTemplate.predefined_values] - * that don't appear here, the certificate issuance request will fail. If - * this is omitted, then this - * [CaPool][google.cloud.security.privateca.v1.CaPool] will not add - * restrictions on a certificate's X.509 extensions. These constraints do - * not apply to X.509 extensions set in this - * [CaPool][google.cloud.security.privateca.v1.CaPool]'s - * [baseline_values][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.baseline_values]. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * Optional. If any - * [AllowedKeyType][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyType] - * is specified, then the certificate request's public key must match one of - * the key types listed here. Otherwise, any key may be used. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyType allowed_key_types = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @return RepeatedField<\Google\Cloud\Security\PrivateCA\V1\CaPool\IssuancePolicy\AllowedKeyType> - */ - public function getAllowedKeyTypes() - { - return $this->allowed_key_types; - } - - /** - * Optional. If any - * [AllowedKeyType][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyType] - * is specified, then the certificate request's public key must match one of - * the key types listed here. Otherwise, any key may be used. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyType allowed_key_types = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\Security\PrivateCA\V1\CaPool\IssuancePolicy\AllowedKeyType[] $var - * @return $this - */ - public function setAllowedKeyTypes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Security\PrivateCA\V1\CaPool\IssuancePolicy\AllowedKeyType::class); - $this->allowed_key_types = $arr; - - return $this; - } - - /** - * Optional. If set, all certificates issued from this - * [CaPool][google.cloud.security.privateca.v1.CaPool] will be backdated by - * this duration. The 'not_before_time' will be the issuance time minus this - * [backdate_duration][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.backdate_duration], - * and the 'not_after_time' will be adjusted to preserve the requested - * lifetime. The maximum duration that a certificate can be backdated with - * these options is 48 hours in the past. - * This option cannot be set if - * [allow_requester_specified_not_before_time][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.allow_requester_specified_not_before_time] - * is set. - * - * Generated from protobuf field .google.protobuf.Duration backdate_duration = 7 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Duration|null - */ - public function getBackdateDuration() - { - return $this->backdate_duration; - } - - public function hasBackdateDuration() - { - return isset($this->backdate_duration); - } - - public function clearBackdateDuration() - { - unset($this->backdate_duration); - } - - /** - * Optional. If set, all certificates issued from this - * [CaPool][google.cloud.security.privateca.v1.CaPool] will be backdated by - * this duration. The 'not_before_time' will be the issuance time minus this - * [backdate_duration][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.backdate_duration], - * and the 'not_after_time' will be adjusted to preserve the requested - * lifetime. The maximum duration that a certificate can be backdated with - * these options is 48 hours in the past. - * This option cannot be set if - * [allow_requester_specified_not_before_time][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.allow_requester_specified_not_before_time] - * is set. - * - * Generated from protobuf field .google.protobuf.Duration backdate_duration = 7 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setBackdateDuration($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->backdate_duration = $var; - - return $this; - } - - /** - * Optional. If set to true, allows requesters to specify the - * [requested_not_before_time][google.cloud.security.privateca.v1.Certificate.requested_not_before_time] - * field when creating a - * [Certificate][google.cloud.security.privateca.v1.Certificate]. - * Certificates requested with this option enabled will have a - * 'not_before_time' equal to the value specified in the request. The - * 'not_after_time' will be adjusted to preserve the requested lifetime. The - * maximum time that a certificate can be backdated with these options is 48 - * hours in the past. This option cannot be set if - * [backdate_duration][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.backdate_duration] - * is set. - * - * Generated from protobuf field bool allow_requester_specified_not_before_time = 8 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getAllowRequesterSpecifiedNotBeforeTime() - { - return $this->allow_requester_specified_not_before_time; - } - - /** - * Optional. If set to true, allows requesters to specify the - * [requested_not_before_time][google.cloud.security.privateca.v1.Certificate.requested_not_before_time] - * field when creating a - * [Certificate][google.cloud.security.privateca.v1.Certificate]. - * Certificates requested with this option enabled will have a - * 'not_before_time' equal to the value specified in the request. The - * 'not_after_time' will be adjusted to preserve the requested lifetime. The - * maximum time that a certificate can be backdated with these options is 48 - * hours in the past. This option cannot be set if - * [backdate_duration][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.backdate_duration] - * is set. - * - * Generated from protobuf field bool allow_requester_specified_not_before_time = 8 [(.google.api.field_behavior) = OPTIONAL]; - * @param bool $var - * @return $this - */ - public function setAllowRequesterSpecifiedNotBeforeTime($var) - { - GPBUtil::checkBool($var); - $this->allow_requester_specified_not_before_time = $var; - - return $this; - } - - /** - * Optional. The maximum lifetime allowed for issued - * [Certificates][google.cloud.security.privateca.v1.Certificate]. Note that - * if the issuing - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * expires before a - * [Certificate][google.cloud.security.privateca.v1.Certificate] resource's - * requested maximum_lifetime, the effective lifetime will be explicitly - * truncated to match it. - * - * Generated from protobuf field .google.protobuf.Duration maximum_lifetime = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Duration|null - */ - public function getMaximumLifetime() - { - return $this->maximum_lifetime; - } - - public function hasMaximumLifetime() - { - return isset($this->maximum_lifetime); - } - - public function clearMaximumLifetime() - { - unset($this->maximum_lifetime); - } - - /** - * Optional. The maximum lifetime allowed for issued - * [Certificates][google.cloud.security.privateca.v1.Certificate]. Note that - * if the issuing - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * expires before a - * [Certificate][google.cloud.security.privateca.v1.Certificate] resource's - * requested maximum_lifetime, the effective lifetime will be explicitly - * truncated to match it. - * - * Generated from protobuf field .google.protobuf.Duration maximum_lifetime = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setMaximumLifetime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->maximum_lifetime = $var; - - return $this; - } - - /** - * Optional. If specified, then only methods allowed in the - * [IssuanceModes][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.IssuanceModes] - * may be used to issue - * [Certificates][google.cloud.security.privateca.v1.Certificate]. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.IssuancePolicy.IssuanceModes allowed_issuance_modes = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\Security\PrivateCA\V1\CaPool\IssuancePolicy\IssuanceModes|null - */ - public function getAllowedIssuanceModes() - { - return $this->allowed_issuance_modes; - } - - public function hasAllowedIssuanceModes() - { - return isset($this->allowed_issuance_modes); - } - - public function clearAllowedIssuanceModes() - { - unset($this->allowed_issuance_modes); - } - - /** - * Optional. If specified, then only methods allowed in the - * [IssuanceModes][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.IssuanceModes] - * may be used to issue - * [Certificates][google.cloud.security.privateca.v1.Certificate]. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.IssuancePolicy.IssuanceModes allowed_issuance_modes = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\Security\PrivateCA\V1\CaPool\IssuancePolicy\IssuanceModes $var - * @return $this - */ - public function setAllowedIssuanceModes($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CaPool\IssuancePolicy\IssuanceModes::class); - $this->allowed_issuance_modes = $var; - - return $this; - } - - /** - * Optional. A set of X.509 values that will be applied to all certificates - * issued through this [CaPool][google.cloud.security.privateca.v1.CaPool]. - * If a certificate request includes conflicting values for the same - * properties, they will be overwritten by the values defined here. If a - * certificate request uses a - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * that defines conflicting - * [predefined_values][google.cloud.security.privateca.v1.CertificateTemplate.predefined_values] - * for the same properties, the certificate issuance request will fail. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.X509Parameters baseline_values = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\Security\PrivateCA\V1\X509Parameters|null - */ - public function getBaselineValues() - { - return $this->baseline_values; - } - - public function hasBaselineValues() - { - return isset($this->baseline_values); - } - - public function clearBaselineValues() - { - unset($this->baseline_values); - } - - /** - * Optional. A set of X.509 values that will be applied to all certificates - * issued through this [CaPool][google.cloud.security.privateca.v1.CaPool]. - * If a certificate request includes conflicting values for the same - * properties, they will be overwritten by the values defined here. If a - * certificate request uses a - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * that defines conflicting - * [predefined_values][google.cloud.security.privateca.v1.CertificateTemplate.predefined_values] - * for the same properties, the certificate issuance request will fail. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.X509Parameters baseline_values = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\Security\PrivateCA\V1\X509Parameters $var - * @return $this - */ - public function setBaselineValues($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\X509Parameters::class); - $this->baseline_values = $var; - - return $this; - } - - /** - * Optional. Describes constraints on identities that may appear in - * [Certificates][google.cloud.security.privateca.v1.Certificate] issued - * through this [CaPool][google.cloud.security.privateca.v1.CaPool]. If this - * is omitted, then this [CaPool][google.cloud.security.privateca.v1.CaPool] - * will not add restrictions on a certificate's identity. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateIdentityConstraints identity_constraints = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\Security\PrivateCA\V1\CertificateIdentityConstraints|null - */ - public function getIdentityConstraints() - { - return $this->identity_constraints; - } - - public function hasIdentityConstraints() - { - return isset($this->identity_constraints); - } - - public function clearIdentityConstraints() - { - unset($this->identity_constraints); - } - - /** - * Optional. Describes constraints on identities that may appear in - * [Certificates][google.cloud.security.privateca.v1.Certificate] issued - * through this [CaPool][google.cloud.security.privateca.v1.CaPool]. If this - * is omitted, then this [CaPool][google.cloud.security.privateca.v1.CaPool] - * will not add restrictions on a certificate's identity. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateIdentityConstraints identity_constraints = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\Security\PrivateCA\V1\CertificateIdentityConstraints $var - * @return $this - */ - public function setIdentityConstraints($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CertificateIdentityConstraints::class); - $this->identity_constraints = $var; - - return $this; - } - - /** - * Optional. Describes the set of X.509 extensions that may appear in a - * [Certificate][google.cloud.security.privateca.v1.Certificate] issued - * through this [CaPool][google.cloud.security.privateca.v1.CaPool]. If a - * certificate request sets extensions that don't appear in the - * [passthrough_extensions][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.passthrough_extensions], - * those extensions will be dropped. If a certificate request uses a - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * with - * [predefined_values][google.cloud.security.privateca.v1.CertificateTemplate.predefined_values] - * that don't appear here, the certificate issuance request will fail. If - * this is omitted, then this - * [CaPool][google.cloud.security.privateca.v1.CaPool] will not add - * restrictions on a certificate's X.509 extensions. These constraints do - * not apply to X.509 extensions set in this - * [CaPool][google.cloud.security.privateca.v1.CaPool]'s - * [baseline_values][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.baseline_values]. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateExtensionConstraints passthrough_extensions = 6 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\Security\PrivateCA\V1\CertificateExtensionConstraints|null - */ - public function getPassthroughExtensions() - { - return $this->passthrough_extensions; - } - - public function hasPassthroughExtensions() - { - return isset($this->passthrough_extensions); - } - - public function clearPassthroughExtensions() - { - unset($this->passthrough_extensions); - } - - /** - * Optional. Describes the set of X.509 extensions that may appear in a - * [Certificate][google.cloud.security.privateca.v1.Certificate] issued - * through this [CaPool][google.cloud.security.privateca.v1.CaPool]. If a - * certificate request sets extensions that don't appear in the - * [passthrough_extensions][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.passthrough_extensions], - * those extensions will be dropped. If a certificate request uses a - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * with - * [predefined_values][google.cloud.security.privateca.v1.CertificateTemplate.predefined_values] - * that don't appear here, the certificate issuance request will fail. If - * this is omitted, then this - * [CaPool][google.cloud.security.privateca.v1.CaPool] will not add - * restrictions on a certificate's X.509 extensions. These constraints do - * not apply to X.509 extensions set in this - * [CaPool][google.cloud.security.privateca.v1.CaPool]'s - * [baseline_values][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.baseline_values]. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateExtensionConstraints passthrough_extensions = 6 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\Security\PrivateCA\V1\CertificateExtensionConstraints $var - * @return $this - */ - public function setPassthroughExtensions($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CertificateExtensionConstraints::class); - $this->passthrough_extensions = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy/AllowedKeyType.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy/AllowedKeyType.php deleted file mode 100644 index a39c3a457850..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy/AllowedKeyType.php +++ /dev/null @@ -1,113 +0,0 @@ -google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyType - */ -class AllowedKeyType extends \Google\Protobuf\Internal\Message -{ - protected $key_type; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Security\PrivateCA\V1\CaPool\IssuancePolicy\AllowedKeyType\RsaKeyType $rsa - * Represents an allowed RSA key type. - * @type \Google\Cloud\Security\PrivateCA\V1\CaPool\IssuancePolicy\AllowedKeyType\EcKeyType $elliptic_curve - * Represents an allowed Elliptic Curve key type. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * Represents an allowed RSA key type. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyType.RsaKeyType rsa = 1; - * @return \Google\Cloud\Security\PrivateCA\V1\CaPool\IssuancePolicy\AllowedKeyType\RsaKeyType|null - */ - public function getRsa() - { - return $this->readOneof(1); - } - - public function hasRsa() - { - return $this->hasOneof(1); - } - - /** - * Represents an allowed RSA key type. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyType.RsaKeyType rsa = 1; - * @param \Google\Cloud\Security\PrivateCA\V1\CaPool\IssuancePolicy\AllowedKeyType\RsaKeyType $var - * @return $this - */ - public function setRsa($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CaPool\IssuancePolicy\AllowedKeyType\RsaKeyType::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * Represents an allowed Elliptic Curve key type. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyType.EcKeyType elliptic_curve = 2; - * @return \Google\Cloud\Security\PrivateCA\V1\CaPool\IssuancePolicy\AllowedKeyType\EcKeyType|null - */ - public function getEllipticCurve() - { - return $this->readOneof(2); - } - - public function hasEllipticCurve() - { - return $this->hasOneof(2); - } - - /** - * Represents an allowed Elliptic Curve key type. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyType.EcKeyType elliptic_curve = 2; - * @param \Google\Cloud\Security\PrivateCA\V1\CaPool\IssuancePolicy\AllowedKeyType\EcKeyType $var - * @return $this - */ - public function setEllipticCurve($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CaPool\IssuancePolicy\AllowedKeyType\EcKeyType::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * @return string - */ - public function getKeyType() - { - return $this->whichOneof("key_type"); - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy/AllowedKeyType/EcKeyType.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy/AllowedKeyType/EcKeyType.php deleted file mode 100644 index 388f76485b17..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy/AllowedKeyType/EcKeyType.php +++ /dev/null @@ -1,73 +0,0 @@ -google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyType.EcKeyType - */ -class EcKeyType extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. A signature algorithm that must be used. If this is - * omitted, any EC-based signature algorithm will be allowed. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyType.EcKeyType.EcSignatureAlgorithm signature_algorithm = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $signature_algorithm = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $signature_algorithm - * Optional. A signature algorithm that must be used. If this is - * omitted, any EC-based signature algorithm will be allowed. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * Optional. A signature algorithm that must be used. If this is - * omitted, any EC-based signature algorithm will be allowed. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyType.EcKeyType.EcSignatureAlgorithm signature_algorithm = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getSignatureAlgorithm() - { - return $this->signature_algorithm; - } - - /** - * Optional. A signature algorithm that must be used. If this is - * omitted, any EC-based signature algorithm will be allowed. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyType.EcKeyType.EcSignatureAlgorithm signature_algorithm = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setSignatureAlgorithm($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Security\PrivateCA\V1\CaPool\IssuancePolicy\AllowedKeyType\EcKeyType\EcSignatureAlgorithm::class); - $this->signature_algorithm = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy/AllowedKeyType/EcKeyType/EcSignatureAlgorithm.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy/AllowedKeyType/EcKeyType/EcSignatureAlgorithm.php deleted file mode 100644 index 756710e45ed2..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy/AllowedKeyType/EcKeyType/EcSignatureAlgorithm.php +++ /dev/null @@ -1,74 +0,0 @@ -google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyType.EcKeyType.EcSignatureAlgorithm - */ -class EcSignatureAlgorithm -{ - /** - * Not specified. Signifies that any signature algorithm may be used. - * - * Generated from protobuf enum EC_SIGNATURE_ALGORITHM_UNSPECIFIED = 0; - */ - const EC_SIGNATURE_ALGORITHM_UNSPECIFIED = 0; - /** - * Refers to the Elliptic Curve Digital Signature Algorithm over the - * NIST P-256 curve. - * - * Generated from protobuf enum ECDSA_P256 = 1; - */ - const ECDSA_P256 = 1; - /** - * Refers to the Elliptic Curve Digital Signature Algorithm over the - * NIST P-384 curve. - * - * Generated from protobuf enum ECDSA_P384 = 2; - */ - const ECDSA_P384 = 2; - /** - * Refers to the Edwards-curve Digital Signature Algorithm over curve - * 25519, as described in RFC 8410. - * - * Generated from protobuf enum EDDSA_25519 = 3; - */ - const EDDSA_25519 = 3; - - private static $valueToName = [ - self::EC_SIGNATURE_ALGORITHM_UNSPECIFIED => 'EC_SIGNATURE_ALGORITHM_UNSPECIFIED', - self::ECDSA_P256 => 'ECDSA_P256', - self::ECDSA_P384 => 'ECDSA_P384', - self::EDDSA_25519 => 'EDDSA_25519', - ]; - - 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy/AllowedKeyType/RsaKeyType.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy/AllowedKeyType/RsaKeyType.php deleted file mode 100644 index ac049c8f0efb..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy/AllowedKeyType/RsaKeyType.php +++ /dev/null @@ -1,119 +0,0 @@ -google.cloud.security.privateca.v1.CaPool.IssuancePolicy.AllowedKeyType.RsaKeyType - */ -class RsaKeyType extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. The minimum allowed RSA modulus size (inclusive), in bits. - * If this is not set, or if set to zero, the service-level min RSA - * modulus size will continue to apply. - * - * Generated from protobuf field int64 min_modulus_size = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $min_modulus_size = 0; - /** - * Optional. The maximum allowed RSA modulus size (inclusive), in bits. - * If this is not set, or if set to zero, the service will not enforce - * an explicit upper bound on RSA modulus sizes. - * - * Generated from protobuf field int64 max_modulus_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $max_modulus_size = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int|string $min_modulus_size - * Optional. The minimum allowed RSA modulus size (inclusive), in bits. - * If this is not set, or if set to zero, the service-level min RSA - * modulus size will continue to apply. - * @type int|string $max_modulus_size - * Optional. The maximum allowed RSA modulus size (inclusive), in bits. - * If this is not set, or if set to zero, the service will not enforce - * an explicit upper bound on RSA modulus sizes. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * Optional. The minimum allowed RSA modulus size (inclusive), in bits. - * If this is not set, or if set to zero, the service-level min RSA - * modulus size will continue to apply. - * - * Generated from protobuf field int64 min_modulus_size = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @return int|string - */ - public function getMinModulusSize() - { - return $this->min_modulus_size; - } - - /** - * Optional. The minimum allowed RSA modulus size (inclusive), in bits. - * If this is not set, or if set to zero, the service-level min RSA - * modulus size will continue to apply. - * - * Generated from protobuf field int64 min_modulus_size = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @param int|string $var - * @return $this - */ - public function setMinModulusSize($var) - { - GPBUtil::checkInt64($var); - $this->min_modulus_size = $var; - - return $this; - } - - /** - * Optional. The maximum allowed RSA modulus size (inclusive), in bits. - * If this is not set, or if set to zero, the service will not enforce - * an explicit upper bound on RSA modulus sizes. - * - * Generated from protobuf field int64 max_modulus_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return int|string - */ - public function getMaxModulusSize() - { - return $this->max_modulus_size; - } - - /** - * Optional. The maximum allowed RSA modulus size (inclusive), in bits. - * If this is not set, or if set to zero, the service will not enforce - * an explicit upper bound on RSA modulus sizes. - * - * Generated from protobuf field int64 max_modulus_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param int|string $var - * @return $this - */ - public function setMaxModulusSize($var) - { - GPBUtil::checkInt64($var); - $this->max_modulus_size = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy/IssuanceModes.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy/IssuanceModes.php deleted file mode 100644 index 31f5b86475c2..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/IssuancePolicy/IssuanceModes.php +++ /dev/null @@ -1,124 +0,0 @@ -google.cloud.security.privateca.v1.CaPool.IssuancePolicy.IssuanceModes - */ -class IssuanceModes extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. When true, allows callers to create - * [Certificates][google.cloud.security.privateca.v1.Certificate] by - * specifying a CSR. - * - * Generated from protobuf field bool allow_csr_based_issuance = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $allow_csr_based_issuance = false; - /** - * Optional. When true, allows callers to create - * [Certificates][google.cloud.security.privateca.v1.Certificate] by - * specifying a - * [CertificateConfig][google.cloud.security.privateca.v1.CertificateConfig]. - * - * Generated from protobuf field bool allow_config_based_issuance = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $allow_config_based_issuance = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type bool $allow_csr_based_issuance - * Optional. When true, allows callers to create - * [Certificates][google.cloud.security.privateca.v1.Certificate] by - * specifying a CSR. - * @type bool $allow_config_based_issuance - * Optional. When true, allows callers to create - * [Certificates][google.cloud.security.privateca.v1.Certificate] by - * specifying a - * [CertificateConfig][google.cloud.security.privateca.v1.CertificateConfig]. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * Optional. When true, allows callers to create - * [Certificates][google.cloud.security.privateca.v1.Certificate] by - * specifying a CSR. - * - * Generated from protobuf field bool allow_csr_based_issuance = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getAllowCsrBasedIssuance() - { - return $this->allow_csr_based_issuance; - } - - /** - * Optional. When true, allows callers to create - * [Certificates][google.cloud.security.privateca.v1.Certificate] by - * specifying a CSR. - * - * Generated from protobuf field bool allow_csr_based_issuance = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @param bool $var - * @return $this - */ - public function setAllowCsrBasedIssuance($var) - { - GPBUtil::checkBool($var); - $this->allow_csr_based_issuance = $var; - - return $this; - } - - /** - * Optional. When true, allows callers to create - * [Certificates][google.cloud.security.privateca.v1.Certificate] by - * specifying a - * [CertificateConfig][google.cloud.security.privateca.v1.CertificateConfig]. - * - * Generated from protobuf field bool allow_config_based_issuance = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getAllowConfigBasedIssuance() - { - return $this->allow_config_based_issuance; - } - - /** - * Optional. When true, allows callers to create - * [Certificates][google.cloud.security.privateca.v1.Certificate] by - * specifying a - * [CertificateConfig][google.cloud.security.privateca.v1.CertificateConfig]. - * - * Generated from protobuf field bool allow_config_based_issuance = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param bool $var - * @return $this - */ - public function setAllowConfigBasedIssuance($var) - { - GPBUtil::checkBool($var); - $this->allow_config_based_issuance = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/PublishingOptions.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/PublishingOptions.php deleted file mode 100644 index 07ad3f819067..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/PublishingOptions.php +++ /dev/null @@ -1,209 +0,0 @@ -google.cloud.security.privateca.v1.CaPool.PublishingOptions - */ -class PublishingOptions extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. When true, publishes each - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s - * CA certificate and includes its URL in the "Authority Information Access" - * X.509 extension in all issued - * [Certificates][google.cloud.security.privateca.v1.Certificate]. If this - * is false, the CA certificate will not be published and the corresponding - * X.509 extension will not be written in issued certificates. - * - * Generated from protobuf field bool publish_ca_cert = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $publish_ca_cert = false; - /** - * Optional. When true, publishes each - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s - * CRL and includes its URL in the "CRL Distribution Points" X.509 extension - * in all issued - * [Certificates][google.cloud.security.privateca.v1.Certificate]. If this - * is false, CRLs will not be published and the corresponding X.509 - * extension will not be written in issued certificates. CRLs will expire 7 - * days from their creation. However, we will rebuild daily. CRLs are also - * rebuilt shortly after a certificate is revoked. - * - * Generated from protobuf field bool publish_crl = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $publish_crl = false; - /** - * Optional. Specifies the encoding format of each - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * resource's CA certificate and CRLs. If this is omitted, CA certificates - * and CRLs will be published in PEM. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.PublishingOptions.EncodingFormat encoding_format = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $encoding_format = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type bool $publish_ca_cert - * Optional. When true, publishes each - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s - * CA certificate and includes its URL in the "Authority Information Access" - * X.509 extension in all issued - * [Certificates][google.cloud.security.privateca.v1.Certificate]. If this - * is false, the CA certificate will not be published and the corresponding - * X.509 extension will not be written in issued certificates. - * @type bool $publish_crl - * Optional. When true, publishes each - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s - * CRL and includes its URL in the "CRL Distribution Points" X.509 extension - * in all issued - * [Certificates][google.cloud.security.privateca.v1.Certificate]. If this - * is false, CRLs will not be published and the corresponding X.509 - * extension will not be written in issued certificates. CRLs will expire 7 - * days from their creation. However, we will rebuild daily. CRLs are also - * rebuilt shortly after a certificate is revoked. - * @type int $encoding_format - * Optional. Specifies the encoding format of each - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * resource's CA certificate and CRLs. If this is omitted, CA certificates - * and CRLs will be published in PEM. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * Optional. When true, publishes each - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s - * CA certificate and includes its URL in the "Authority Information Access" - * X.509 extension in all issued - * [Certificates][google.cloud.security.privateca.v1.Certificate]. If this - * is false, the CA certificate will not be published and the corresponding - * X.509 extension will not be written in issued certificates. - * - * Generated from protobuf field bool publish_ca_cert = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getPublishCaCert() - { - return $this->publish_ca_cert; - } - - /** - * Optional. When true, publishes each - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s - * CA certificate and includes its URL in the "Authority Information Access" - * X.509 extension in all issued - * [Certificates][google.cloud.security.privateca.v1.Certificate]. If this - * is false, the CA certificate will not be published and the corresponding - * X.509 extension will not be written in issued certificates. - * - * Generated from protobuf field bool publish_ca_cert = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @param bool $var - * @return $this - */ - public function setPublishCaCert($var) - { - GPBUtil::checkBool($var); - $this->publish_ca_cert = $var; - - return $this; - } - - /** - * Optional. When true, publishes each - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s - * CRL and includes its URL in the "CRL Distribution Points" X.509 extension - * in all issued - * [Certificates][google.cloud.security.privateca.v1.Certificate]. If this - * is false, CRLs will not be published and the corresponding X.509 - * extension will not be written in issued certificates. CRLs will expire 7 - * days from their creation. However, we will rebuild daily. CRLs are also - * rebuilt shortly after a certificate is revoked. - * - * Generated from protobuf field bool publish_crl = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getPublishCrl() - { - return $this->publish_crl; - } - - /** - * Optional. When true, publishes each - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s - * CRL and includes its URL in the "CRL Distribution Points" X.509 extension - * in all issued - * [Certificates][google.cloud.security.privateca.v1.Certificate]. If this - * is false, CRLs will not be published and the corresponding X.509 - * extension will not be written in issued certificates. CRLs will expire 7 - * days from their creation. However, we will rebuild daily. CRLs are also - * rebuilt shortly after a certificate is revoked. - * - * Generated from protobuf field bool publish_crl = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param bool $var - * @return $this - */ - public function setPublishCrl($var) - { - GPBUtil::checkBool($var); - $this->publish_crl = $var; - - return $this; - } - - /** - * Optional. Specifies the encoding format of each - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * resource's CA certificate and CRLs. If this is omitted, CA certificates - * and CRLs will be published in PEM. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.PublishingOptions.EncodingFormat encoding_format = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getEncodingFormat() - { - return $this->encoding_format; - } - - /** - * Optional. Specifies the encoding format of each - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * resource's CA certificate and CRLs. If this is omitted, CA certificates - * and CRLs will be published in PEM. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.PublishingOptions.EncodingFormat encoding_format = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setEncodingFormat($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Security\PrivateCA\V1\CaPool\PublishingOptions\EncodingFormat::class); - $this->encoding_format = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/PublishingOptions/EncodingFormat.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/PublishingOptions/EncodingFormat.php deleted file mode 100644 index b5057cbcaed6..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/PublishingOptions/EncodingFormat.php +++ /dev/null @@ -1,65 +0,0 @@ -google.cloud.security.privateca.v1.CaPool.PublishingOptions.EncodingFormat - */ -class EncodingFormat -{ - /** - * Not specified. By default, PEM format will be used. - * - * Generated from protobuf enum ENCODING_FORMAT_UNSPECIFIED = 0; - */ - const ENCODING_FORMAT_UNSPECIFIED = 0; - /** - * The - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s - * CA certificate and CRLs will be published in PEM format. - * - * Generated from protobuf enum PEM = 1; - */ - const PEM = 1; - /** - * The - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s - * CA certificate and CRLs will be published in DER format. - * - * Generated from protobuf enum DER = 2; - */ - const DER = 2; - - private static $valueToName = [ - self::ENCODING_FORMAT_UNSPECIFIED => 'ENCODING_FORMAT_UNSPECIFIED', - self::PEM => 'PEM', - self::DER => 'DER', - ]; - - 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/Tier.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/Tier.php deleted file mode 100644 index 8f09b78fdacc..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CaPool/Tier.php +++ /dev/null @@ -1,62 +0,0 @@ -google.cloud.security.privateca.v1.CaPool.Tier - */ -class Tier -{ - /** - * Not specified. - * - * Generated from protobuf enum TIER_UNSPECIFIED = 0; - */ - const TIER_UNSPECIFIED = 0; - /** - * Enterprise tier. - * - * Generated from protobuf enum ENTERPRISE = 1; - */ - const ENTERPRISE = 1; - /** - * DevOps tier. - * - * Generated from protobuf enum DEVOPS = 2; - */ - const DEVOPS = 2; - - private static $valueToName = [ - self::TIER_UNSPECIFIED => 'TIER_UNSPECIFIED', - self::ENTERPRISE => 'ENTERPRISE', - self::DEVOPS => 'DEVOPS', - ]; - - 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/Certificate.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/Certificate.php deleted file mode 100644 index 5ae97a2348a6..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/Certificate.php +++ /dev/null @@ -1,755 +0,0 @@ -google.cloud.security.privateca.v1.Certificate - */ -class Certificate extends \Google\Protobuf\Internal\Message -{ - /** - * Identifier. The resource name for this - * [Certificate][google.cloud.security.privateca.v1.Certificate] in the format - * `projects/{@*}locations/{@*}caPools/{@*}certificates/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; - */ - protected $name = ''; - /** - * Output only. The resource name of the issuing - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. - * - * Generated from protobuf field string issuer_certificate_authority = 4 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { - */ - protected $issuer_certificate_authority = ''; - /** - * Required. Immutable. The desired lifetime of a certificate. Used to create - * the "not_before_time" and "not_after_time" fields inside an X.509 - * certificate. Note that the lifetime may be truncated if it would extend - * past the life of any certificate authority in the issuing chain. - * - * Generated from protobuf field .google.protobuf.Duration lifetime = 5 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; - */ - protected $lifetime = null; - /** - * Immutable. The resource name for a - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * used to issue this certificate, in the format - * `projects/{@*}locations/{@*}certificateTemplates/*`. - * If this is specified, the caller must have the necessary permission to - * use this template. If this is omitted, no template will be used. - * This template must be in the same location as the - * [Certificate][google.cloud.security.privateca.v1.Certificate]. - * - * Generated from protobuf field string certificate_template = 6 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { - */ - protected $certificate_template = ''; - /** - * Immutable. Specifies how the - * [Certificate][google.cloud.security.privateca.v1.Certificate]'s identity - * fields are to be decided. If this is omitted, the `DEFAULT` subject mode - * will be used. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.SubjectRequestMode subject_mode = 7 [(.google.api.field_behavior) = IMMUTABLE]; - */ - protected $subject_mode = 0; - /** - * Output only. Details regarding the revocation of this - * [Certificate][google.cloud.security.privateca.v1.Certificate]. This - * [Certificate][google.cloud.security.privateca.v1.Certificate] is considered - * revoked if and only if this field is present. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.Certificate.RevocationDetails revocation_details = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $revocation_details = null; - /** - * Output only. The pem-encoded, signed X.509 certificate. - * - * Generated from protobuf field string pem_certificate = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $pem_certificate = ''; - /** - * Output only. A structured description of the issued X.509 certificate. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateDescription certificate_description = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $certificate_description = null; - /** - * Output only. The chain that may be used to verify the X.509 certificate. - * Expected to be in issuer-to-root order according to RFC 5246. - * - * Generated from protobuf field repeated string pem_certificate_chain = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - private $pem_certificate_chain; - /** - * Output only. The time at which this - * [Certificate][google.cloud.security.privateca.v1.Certificate] was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The time at which this - * [Certificate][google.cloud.security.privateca.v1.Certificate] was updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Optional. Labels with user-defined metadata. - * - * Generated from protobuf field map labels = 14 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $labels; - /** - * Optional. The requested - * [not_before_time][google.cloud.security.privateca.v1.CertificateDescription.SubjectDescription.not_before_time] - * of this [Certificate][google.cloud.security.privateca.v1.Certificate]. This - * field may only be set if the - * [CaPool.IssuancePolicy.allow_requester_specified_not_before_time][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.allow_requester_specified_not_before_time] - * field is set to true for the issuing - * [CaPool][google.cloud.security.privateca.v1.CaPool]. - * If this field is specified, the certificate will be issued with this - * 'not_before_time'. If this is not specified, the 'not_before_time' will be - * set to the issuance time or issuance time minus - * [backdate_duration][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.backdate_duration] - * depending on the [CaPool][google.cloud.security.privateca.v1.CaPool] - * configuration. - * - * Generated from protobuf field .google.protobuf.Timestamp requested_not_before_time = 15 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $requested_not_before_time = null; - protected $certificate_config; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Identifier. The resource name for this - * [Certificate][google.cloud.security.privateca.v1.Certificate] in the format - * `projects/{@*}locations/{@*}caPools/{@*}certificates/*`. - * @type string $pem_csr - * Immutable. A pem-encoded X.509 certificate signing request (CSR). - * @type \Google\Cloud\Security\PrivateCA\V1\CertificateConfig $config - * Immutable. A description of the certificate and key that does not require - * X.509 or ASN.1. - * @type string $issuer_certificate_authority - * Output only. The resource name of the issuing - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. - * @type \Google\Protobuf\Duration $lifetime - * Required. Immutable. The desired lifetime of a certificate. Used to create - * the "not_before_time" and "not_after_time" fields inside an X.509 - * certificate. Note that the lifetime may be truncated if it would extend - * past the life of any certificate authority in the issuing chain. - * @type string $certificate_template - * Immutable. The resource name for a - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * used to issue this certificate, in the format - * `projects/{@*}locations/{@*}certificateTemplates/*`. - * If this is specified, the caller must have the necessary permission to - * use this template. If this is omitted, no template will be used. - * This template must be in the same location as the - * [Certificate][google.cloud.security.privateca.v1.Certificate]. - * @type int $subject_mode - * Immutable. Specifies how the - * [Certificate][google.cloud.security.privateca.v1.Certificate]'s identity - * fields are to be decided. If this is omitted, the `DEFAULT` subject mode - * will be used. - * @type \Google\Cloud\Security\PrivateCA\V1\Certificate\RevocationDetails $revocation_details - * Output only. Details regarding the revocation of this - * [Certificate][google.cloud.security.privateca.v1.Certificate]. This - * [Certificate][google.cloud.security.privateca.v1.Certificate] is considered - * revoked if and only if this field is present. - * @type string $pem_certificate - * Output only. The pem-encoded, signed X.509 certificate. - * @type \Google\Cloud\Security\PrivateCA\V1\CertificateDescription $certificate_description - * Output only. A structured description of the issued X.509 certificate. - * @type string[] $pem_certificate_chain - * Output only. The chain that may be used to verify the X.509 certificate. - * Expected to be in issuer-to-root order according to RFC 5246. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. The time at which this - * [Certificate][google.cloud.security.privateca.v1.Certificate] was created. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. The time at which this - * [Certificate][google.cloud.security.privateca.v1.Certificate] was updated. - * @type array|\Google\Protobuf\Internal\MapField $labels - * Optional. Labels with user-defined metadata. - * @type \Google\Protobuf\Timestamp $requested_not_before_time - * Optional. The requested - * [not_before_time][google.cloud.security.privateca.v1.CertificateDescription.SubjectDescription.not_before_time] - * of this [Certificate][google.cloud.security.privateca.v1.Certificate]. This - * field may only be set if the - * [CaPool.IssuancePolicy.allow_requester_specified_not_before_time][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.allow_requester_specified_not_before_time] - * field is set to true for the issuing - * [CaPool][google.cloud.security.privateca.v1.CaPool]. - * If this field is specified, the certificate will be issued with this - * 'not_before_time'. If this is not specified, the 'not_before_time' will be - * set to the issuance time or issuance time minus - * [backdate_duration][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.backdate_duration] - * depending on the [CaPool][google.cloud.security.privateca.v1.CaPool] - * configuration. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * Identifier. The resource name for this - * [Certificate][google.cloud.security.privateca.v1.Certificate] in the format - * `projects/{@*}locations/{@*}caPools/{@*}certificates/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Identifier. The resource name for this - * [Certificate][google.cloud.security.privateca.v1.Certificate] in the format - * `projects/{@*}locations/{@*}caPools/{@*}certificates/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Immutable. A pem-encoded X.509 certificate signing request (CSR). - * - * Generated from protobuf field string pem_csr = 2 [(.google.api.field_behavior) = IMMUTABLE]; - * @return string - */ - public function getPemCsr() - { - return $this->readOneof(2); - } - - public function hasPemCsr() - { - return $this->hasOneof(2); - } - - /** - * Immutable. A pem-encoded X.509 certificate signing request (CSR). - * - * Generated from protobuf field string pem_csr = 2 [(.google.api.field_behavior) = IMMUTABLE]; - * @param string $var - * @return $this - */ - public function setPemCsr($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * Immutable. A description of the certificate and key that does not require - * X.509 or ASN.1. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateConfig config = 3 [(.google.api.field_behavior) = IMMUTABLE]; - * @return \Google\Cloud\Security\PrivateCA\V1\CertificateConfig|null - */ - public function getConfig() - { - return $this->readOneof(3); - } - - public function hasConfig() - { - return $this->hasOneof(3); - } - - /** - * Immutable. A description of the certificate and key that does not require - * X.509 or ASN.1. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateConfig config = 3 [(.google.api.field_behavior) = IMMUTABLE]; - * @param \Google\Cloud\Security\PrivateCA\V1\CertificateConfig $var - * @return $this - */ - public function setConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CertificateConfig::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * Output only. The resource name of the issuing - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. - * - * Generated from protobuf field string issuer_certificate_authority = 4 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { - * @return string - */ - public function getIssuerCertificateAuthority() - { - return $this->issuer_certificate_authority; - } - - /** - * Output only. The resource name of the issuing - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. - * - * Generated from protobuf field string issuer_certificate_authority = 4 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setIssuerCertificateAuthority($var) - { - GPBUtil::checkString($var, True); - $this->issuer_certificate_authority = $var; - - return $this; - } - - /** - * Required. Immutable. The desired lifetime of a certificate. Used to create - * the "not_before_time" and "not_after_time" fields inside an X.509 - * certificate. Note that the lifetime may be truncated if it would extend - * past the life of any certificate authority in the issuing chain. - * - * Generated from protobuf field .google.protobuf.Duration lifetime = 5 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; - * @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. Immutable. The desired lifetime of a certificate. Used to create - * the "not_before_time" and "not_after_time" fields inside an X.509 - * certificate. Note that the lifetime may be truncated if it would extend - * past the life of any certificate authority in the issuing chain. - * - * Generated from protobuf field .google.protobuf.Duration lifetime = 5 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setLifetime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->lifetime = $var; - - return $this; - } - - /** - * Immutable. The resource name for a - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * used to issue this certificate, in the format - * `projects/{@*}locations/{@*}certificateTemplates/*`. - * If this is specified, the caller must have the necessary permission to - * use this template. If this is omitted, no template will be used. - * This template must be in the same location as the - * [Certificate][google.cloud.security.privateca.v1.Certificate]. - * - * Generated from protobuf field string certificate_template = 6 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { - * @return string - */ - public function getCertificateTemplate() - { - return $this->certificate_template; - } - - /** - * Immutable. The resource name for a - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * used to issue this certificate, in the format - * `projects/{@*}locations/{@*}certificateTemplates/*`. - * If this is specified, the caller must have the necessary permission to - * use this template. If this is omitted, no template will be used. - * This template must be in the same location as the - * [Certificate][google.cloud.security.privateca.v1.Certificate]. - * - * Generated from protobuf field string certificate_template = 6 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setCertificateTemplate($var) - { - GPBUtil::checkString($var, True); - $this->certificate_template = $var; - - return $this; - } - - /** - * Immutable. Specifies how the - * [Certificate][google.cloud.security.privateca.v1.Certificate]'s identity - * fields are to be decided. If this is omitted, the `DEFAULT` subject mode - * will be used. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.SubjectRequestMode subject_mode = 7 [(.google.api.field_behavior) = IMMUTABLE]; - * @return int - */ - public function getSubjectMode() - { - return $this->subject_mode; - } - - /** - * Immutable. Specifies how the - * [Certificate][google.cloud.security.privateca.v1.Certificate]'s identity - * fields are to be decided. If this is omitted, the `DEFAULT` subject mode - * will be used. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.SubjectRequestMode subject_mode = 7 [(.google.api.field_behavior) = IMMUTABLE]; - * @param int $var - * @return $this - */ - public function setSubjectMode($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Security\PrivateCA\V1\SubjectRequestMode::class); - $this->subject_mode = $var; - - return $this; - } - - /** - * Output only. Details regarding the revocation of this - * [Certificate][google.cloud.security.privateca.v1.Certificate]. This - * [Certificate][google.cloud.security.privateca.v1.Certificate] is considered - * revoked if and only if this field is present. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.Certificate.RevocationDetails revocation_details = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Cloud\Security\PrivateCA\V1\Certificate\RevocationDetails|null - */ - public function getRevocationDetails() - { - return $this->revocation_details; - } - - public function hasRevocationDetails() - { - return isset($this->revocation_details); - } - - public function clearRevocationDetails() - { - unset($this->revocation_details); - } - - /** - * Output only. Details regarding the revocation of this - * [Certificate][google.cloud.security.privateca.v1.Certificate]. This - * [Certificate][google.cloud.security.privateca.v1.Certificate] is considered - * revoked if and only if this field is present. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.Certificate.RevocationDetails revocation_details = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\Security\PrivateCA\V1\Certificate\RevocationDetails $var - * @return $this - */ - public function setRevocationDetails($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\Certificate\RevocationDetails::class); - $this->revocation_details = $var; - - return $this; - } - - /** - * Output only. The pem-encoded, signed X.509 certificate. - * - * 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, signed X.509 certificate. - * - * 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. A structured description of the issued X.509 certificate. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateDescription certificate_description = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Cloud\Security\PrivateCA\V1\CertificateDescription|null - */ - public function getCertificateDescription() - { - return $this->certificate_description; - } - - public function hasCertificateDescription() - { - return isset($this->certificate_description); - } - - public function clearCertificateDescription() - { - unset($this->certificate_description); - } - - /** - * Output only. A structured description of the issued X.509 certificate. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateDescription certificate_description = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\Security\PrivateCA\V1\CertificateDescription $var - * @return $this - */ - public function setCertificateDescription($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CertificateDescription::class); - $this->certificate_description = $var; - - return $this; - } - - /** - * Output only. The chain that may be used to verify the X.509 certificate. - * Expected to be in issuer-to-root order according to RFC 5246. - * - * Generated from protobuf field repeated string pem_certificate_chain = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return RepeatedField - */ - public function getPemCertificateChain() - { - return $this->pem_certificate_chain; - } - - /** - * Output only. The chain that may be used to verify the X.509 certificate. - * Expected to be in issuer-to-root order according to RFC 5246. - * - * Generated from protobuf field repeated string pem_certificate_chain = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string[] $var - * @return $this - */ - public function setPemCertificateChain($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->pem_certificate_chain = $arr; - - return $this; - } - - /** - * Output only. The time at which this - * [Certificate][google.cloud.security.privateca.v1.Certificate] was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 12 [(.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 - * [Certificate][google.cloud.security.privateca.v1.Certificate] was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 12 [(.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 - * [Certificate][google.cloud.security.privateca.v1.Certificate] was updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 13 [(.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 at which this - * [Certificate][google.cloud.security.privateca.v1.Certificate] was updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 13 [(.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. Labels with user-defined metadata. - * - * Generated from protobuf field map labels = 14 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Optional. Labels with user-defined metadata. - * - * Generated from protobuf field map labels = 14 [(.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. The requested - * [not_before_time][google.cloud.security.privateca.v1.CertificateDescription.SubjectDescription.not_before_time] - * of this [Certificate][google.cloud.security.privateca.v1.Certificate]. This - * field may only be set if the - * [CaPool.IssuancePolicy.allow_requester_specified_not_before_time][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.allow_requester_specified_not_before_time] - * field is set to true for the issuing - * [CaPool][google.cloud.security.privateca.v1.CaPool]. - * If this field is specified, the certificate will be issued with this - * 'not_before_time'. If this is not specified, the 'not_before_time' will be - * set to the issuance time or issuance time minus - * [backdate_duration][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.backdate_duration] - * depending on the [CaPool][google.cloud.security.privateca.v1.CaPool] - * configuration. - * - * Generated from protobuf field .google.protobuf.Timestamp requested_not_before_time = 15 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getRequestedNotBeforeTime() - { - return $this->requested_not_before_time; - } - - public function hasRequestedNotBeforeTime() - { - return isset($this->requested_not_before_time); - } - - public function clearRequestedNotBeforeTime() - { - unset($this->requested_not_before_time); - } - - /** - * Optional. The requested - * [not_before_time][google.cloud.security.privateca.v1.CertificateDescription.SubjectDescription.not_before_time] - * of this [Certificate][google.cloud.security.privateca.v1.Certificate]. This - * field may only be set if the - * [CaPool.IssuancePolicy.allow_requester_specified_not_before_time][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.allow_requester_specified_not_before_time] - * field is set to true for the issuing - * [CaPool][google.cloud.security.privateca.v1.CaPool]. - * If this field is specified, the certificate will be issued with this - * 'not_before_time'. If this is not specified, the 'not_before_time' will be - * set to the issuance time or issuance time minus - * [backdate_duration][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.backdate_duration] - * depending on the [CaPool][google.cloud.security.privateca.v1.CaPool] - * configuration. - * - * Generated from protobuf field .google.protobuf.Timestamp requested_not_before_time = 15 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setRequestedNotBeforeTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->requested_not_before_time = $var; - - return $this; - } - - /** - * @return string - */ - public function getCertificateConfig() - { - return $this->whichOneof("certificate_config"); - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/Certificate/RevocationDetails.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/Certificate/RevocationDetails.php deleted file mode 100644 index fe4597b96211..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/Certificate/RevocationDetails.php +++ /dev/null @@ -1,128 +0,0 @@ -google.cloud.security.privateca.v1.Certificate.RevocationDetails - */ -class RevocationDetails extends \Google\Protobuf\Internal\Message -{ - /** - * Indicates why a - * [Certificate][google.cloud.security.privateca.v1.Certificate] was - * revoked. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.RevocationReason revocation_state = 1; - */ - protected $revocation_state = 0; - /** - * The time at which this - * [Certificate][google.cloud.security.privateca.v1.Certificate] was - * revoked. - * - * Generated from protobuf field .google.protobuf.Timestamp revocation_time = 2; - */ - protected $revocation_time = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $revocation_state - * Indicates why a - * [Certificate][google.cloud.security.privateca.v1.Certificate] was - * revoked. - * @type \Google\Protobuf\Timestamp $revocation_time - * The time at which this - * [Certificate][google.cloud.security.privateca.v1.Certificate] was - * revoked. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * Indicates why a - * [Certificate][google.cloud.security.privateca.v1.Certificate] was - * revoked. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.RevocationReason revocation_state = 1; - * @return int - */ - public function getRevocationState() - { - return $this->revocation_state; - } - - /** - * Indicates why a - * [Certificate][google.cloud.security.privateca.v1.Certificate] was - * revoked. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.RevocationReason revocation_state = 1; - * @param int $var - * @return $this - */ - public function setRevocationState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Security\PrivateCA\V1\RevocationReason::class); - $this->revocation_state = $var; - - return $this; - } - - /** - * The time at which this - * [Certificate][google.cloud.security.privateca.v1.Certificate] was - * revoked. - * - * Generated from protobuf field .google.protobuf.Timestamp revocation_time = 2; - * @return \Google\Protobuf\Timestamp|null - */ - public function getRevocationTime() - { - return $this->revocation_time; - } - - public function hasRevocationTime() - { - return isset($this->revocation_time); - } - - public function clearRevocationTime() - { - unset($this->revocation_time); - } - - /** - * The time at which this - * [Certificate][google.cloud.security.privateca.v1.Certificate] was - * revoked. - * - * Generated from protobuf field .google.protobuf.Timestamp revocation_time = 2; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setRevocationTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->revocation_time = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority.php deleted file mode 100644 index 1316e0d1ec5d..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority.php +++ /dev/null @@ -1,1038 +0,0 @@ -google.cloud.security.privateca.v1.CertificateAuthority - */ -class CertificateAuthority extends \Google\Protobuf\Internal\Message -{ - /** - * Identifier. The resource name for this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; - */ - protected $name = ''; - /** - * Required. Immutable. The - * [Type][google.cloud.security.privateca.v1.CertificateAuthority.Type] of - * this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority.Type type = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; - */ - protected $type = 0; - /** - * Required. Immutable. The config used to create a self-signed X.509 - * certificate or CSR. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateConfig config = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; - */ - protected $config = null; - /** - * Required. Immutable. The desired lifetime of the CA certificate. Used to - * create the "not_before_time" and "not_after_time" fields inside an X.509 - * certificate. - * - * Generated from protobuf field .google.protobuf.Duration lifetime = 4 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; - */ - protected $lifetime = null; - /** - * Required. Immutable. Used when issuing certificates for this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. - * If this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * is a self-signed CertificateAuthority, this key is also used to sign the - * self-signed CA certificate. Otherwise, it is used to sign a CSR. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority.KeyVersionSpec key_spec = 5 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; - */ - protected $key_spec = null; - /** - * Optional. If this is a subordinate - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority], - * this field will be set with the subordinate configuration, which describes - * its issuers. This may be updated, but this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * must continue to validate. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.SubordinateConfig subordinate_config = 6 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $subordinate_config = null; - /** - * Output only. The - * [CaPool.Tier][google.cloud.security.privateca.v1.CaPool.Tier] of the - * [CaPool][google.cloud.security.privateca.v1.CaPool] that includes this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.Tier tier = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $tier = 0; - /** - * Output only. The - * [State][google.cloud.security.privateca.v1.CertificateAuthority.State] for - * this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = 0; - /** - * Output only. This - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s - * certificate chain, including the current - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s - * certificate. Ordered such that the root issuer is the final element - * (consistent with RFC 5246). For a self-signed CA, this will only list the - * current - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s - * certificate. - * - * Generated from protobuf field repeated string pem_ca_certificates = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - private $pem_ca_certificates; - /** - * Output only. A structured description of this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s - * CA certificate and its issuers. Ordered as self-to-root. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CertificateDescription ca_certificate_descriptions = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - private $ca_certificate_descriptions; - /** - * Immutable. The name of a Cloud Storage bucket where this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * will publish content, such as the CA certificate and CRLs. This must be a - * bucket name, without any prefixes (such as `gs://`) or suffixes (such as - * `.googleapis.com`). For example, to use a bucket named `my-bucket`, you - * would simply specify `my-bucket`. If not specified, a managed bucket will - * be created. - * - * Generated from protobuf field string gcs_bucket = 11 [(.google.api.field_behavior) = IMMUTABLE]; - */ - protected $gcs_bucket = ''; - /** - * Output only. URLs for accessing content published by this CA, such as the - * CA certificate and CRLs. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority.AccessUrls access_urls = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $access_urls = null; - /** - * Output only. The time at which this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The time at which this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * was last updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Output only. The time at which this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * was soft deleted, if it is in the - * [DELETED][google.cloud.security.privateca.v1.CertificateAuthority.State.DELETED] - * state. - * - * Generated from protobuf field .google.protobuf.Timestamp delete_time = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $delete_time = null; - /** - * Output only. The time at which this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * will be permanently purged, if it is in the - * [DELETED][google.cloud.security.privateca.v1.CertificateAuthority.State.DELETED] - * state. - * - * Generated from protobuf field .google.protobuf.Timestamp expire_time = 16 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $expire_time = null; - /** - * Optional. Labels with user-defined metadata. - * - * Generated from protobuf field map labels = 17 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $labels; - /** - * Optional. User-defined URLs for CA certificate and CRLs. The service does - * not publish content to these URLs. It is up to the user to mirror content - * to these URLs. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority.UserDefinedAccessUrls user_defined_access_urls = 18 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $user_defined_access_urls = null; - /** - * Output only. Reserved for future use. - * - * Generated from protobuf field bool satisfies_pzs = 19 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $satisfies_pzs = false; - /** - * Output only. Reserved for future use. - * - * Generated from protobuf field bool satisfies_pzi = 20 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $satisfies_pzi = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Identifier. The resource name for this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. - * @type int $type - * Required. Immutable. The - * [Type][google.cloud.security.privateca.v1.CertificateAuthority.Type] of - * this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. - * @type \Google\Cloud\Security\PrivateCA\V1\CertificateConfig $config - * Required. Immutable. The config used to create a self-signed X.509 - * certificate or CSR. - * @type \Google\Protobuf\Duration $lifetime - * Required. Immutable. The desired lifetime of the CA certificate. Used to - * create the "not_before_time" and "not_after_time" fields inside an X.509 - * certificate. - * @type \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority\KeyVersionSpec $key_spec - * Required. Immutable. Used when issuing certificates for this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. - * If this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * is a self-signed CertificateAuthority, this key is also used to sign the - * self-signed CA certificate. Otherwise, it is used to sign a CSR. - * @type \Google\Cloud\Security\PrivateCA\V1\SubordinateConfig $subordinate_config - * Optional. If this is a subordinate - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority], - * this field will be set with the subordinate configuration, which describes - * its issuers. This may be updated, but this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * must continue to validate. - * @type int $tier - * Output only. The - * [CaPool.Tier][google.cloud.security.privateca.v1.CaPool.Tier] of the - * [CaPool][google.cloud.security.privateca.v1.CaPool] that includes this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. - * @type int $state - * Output only. The - * [State][google.cloud.security.privateca.v1.CertificateAuthority.State] for - * this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. - * @type string[] $pem_ca_certificates - * Output only. This - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s - * certificate chain, including the current - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s - * certificate. Ordered such that the root issuer is the final element - * (consistent with RFC 5246). For a self-signed CA, this will only list the - * current - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s - * certificate. - * @type \Google\Cloud\Security\PrivateCA\V1\CertificateDescription[] $ca_certificate_descriptions - * Output only. A structured description of this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s - * CA certificate and its issuers. Ordered as self-to-root. - * @type string $gcs_bucket - * Immutable. The name of a Cloud Storage bucket where this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * will publish content, such as the CA certificate and CRLs. This must be a - * bucket name, without any prefixes (such as `gs://`) or suffixes (such as - * `.googleapis.com`). For example, to use a bucket named `my-bucket`, you - * would simply specify `my-bucket`. If not specified, a managed bucket will - * be created. - * @type \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority\AccessUrls $access_urls - * Output only. URLs for accessing content published by this CA, such as the - * CA certificate and CRLs. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. The time at which this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * was created. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. The time at which this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * was last updated. - * @type \Google\Protobuf\Timestamp $delete_time - * Output only. The time at which this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * was soft deleted, if it is in the - * [DELETED][google.cloud.security.privateca.v1.CertificateAuthority.State.DELETED] - * state. - * @type \Google\Protobuf\Timestamp $expire_time - * Output only. The time at which this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * will be permanently purged, if it is in the - * [DELETED][google.cloud.security.privateca.v1.CertificateAuthority.State.DELETED] - * state. - * @type array|\Google\Protobuf\Internal\MapField $labels - * Optional. Labels with user-defined metadata. - * @type \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority\UserDefinedAccessUrls $user_defined_access_urls - * Optional. User-defined URLs for CA certificate and CRLs. The service does - * not publish content to these URLs. It is up to the user to mirror content - * to these URLs. - * @type bool $satisfies_pzs - * Output only. Reserved for future use. - * @type bool $satisfies_pzi - * Output only. Reserved for future use. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * Identifier. The resource name for this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Identifier. The resource name for this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Required. Immutable. The - * [Type][google.cloud.security.privateca.v1.CertificateAuthority.Type] of - * this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority.Type type = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; - * @return int - */ - public function getType() - { - return $this->type; - } - - /** - * Required. Immutable. The - * [Type][google.cloud.security.privateca.v1.CertificateAuthority.Type] of - * this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority.Type type = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; - * @param int $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority\Type::class); - $this->type = $var; - - return $this; - } - - /** - * Required. Immutable. The config used to create a self-signed X.509 - * certificate or CSR. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateConfig config = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; - * @return \Google\Cloud\Security\PrivateCA\V1\CertificateConfig|null - */ - public function getConfig() - { - return $this->config; - } - - public function hasConfig() - { - return isset($this->config); - } - - public function clearConfig() - { - unset($this->config); - } - - /** - * Required. Immutable. The config used to create a self-signed X.509 - * certificate or CSR. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateConfig config = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; - * @param \Google\Cloud\Security\PrivateCA\V1\CertificateConfig $var - * @return $this - */ - public function setConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CertificateConfig::class); - $this->config = $var; - - return $this; - } - - /** - * Required. Immutable. The desired lifetime of the CA certificate. Used to - * create the "not_before_time" and "not_after_time" fields inside an X.509 - * certificate. - * - * Generated from protobuf field .google.protobuf.Duration lifetime = 4 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; - * @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. Immutable. The desired lifetime of the CA certificate. Used to - * create the "not_before_time" and "not_after_time" fields inside an X.509 - * certificate. - * - * Generated from protobuf field .google.protobuf.Duration lifetime = 4 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setLifetime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->lifetime = $var; - - return $this; - } - - /** - * Required. Immutable. Used when issuing certificates for this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. - * If this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * is a self-signed CertificateAuthority, this key is also used to sign the - * self-signed CA certificate. Otherwise, it is used to sign a CSR. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority.KeyVersionSpec key_spec = 5 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; - * @return \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority\KeyVersionSpec|null - */ - public function getKeySpec() - { - return $this->key_spec; - } - - public function hasKeySpec() - { - return isset($this->key_spec); - } - - public function clearKeySpec() - { - unset($this->key_spec); - } - - /** - * Required. Immutable. Used when issuing certificates for this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. - * If this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * is a self-signed CertificateAuthority, this key is also used to sign the - * self-signed CA certificate. Otherwise, it is used to sign a CSR. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority.KeyVersionSpec key_spec = 5 [(.google.api.field_behavior) = REQUIRED, (.google.api.field_behavior) = IMMUTABLE]; - * @param \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority\KeyVersionSpec $var - * @return $this - */ - public function setKeySpec($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority\KeyVersionSpec::class); - $this->key_spec = $var; - - return $this; - } - - /** - * Optional. If this is a subordinate - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority], - * this field will be set with the subordinate configuration, which describes - * its issuers. This may be updated, but this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * must continue to validate. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.SubordinateConfig subordinate_config = 6 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\Security\PrivateCA\V1\SubordinateConfig|null - */ - public function getSubordinateConfig() - { - return $this->subordinate_config; - } - - public function hasSubordinateConfig() - { - return isset($this->subordinate_config); - } - - public function clearSubordinateConfig() - { - unset($this->subordinate_config); - } - - /** - * Optional. If this is a subordinate - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority], - * this field will be set with the subordinate configuration, which describes - * its issuers. This may be updated, but this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * must continue to validate. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.SubordinateConfig subordinate_config = 6 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\Security\PrivateCA\V1\SubordinateConfig $var - * @return $this - */ - public function setSubordinateConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\SubordinateConfig::class); - $this->subordinate_config = $var; - - return $this; - } - - /** - * Output only. The - * [CaPool.Tier][google.cloud.security.privateca.v1.CaPool.Tier] of the - * [CaPool][google.cloud.security.privateca.v1.CaPool] that includes this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.Tier tier = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getTier() - { - return $this->tier; - } - - /** - * Output only. The - * [CaPool.Tier][google.cloud.security.privateca.v1.CaPool.Tier] of the - * [CaPool][google.cloud.security.privateca.v1.CaPool] that includes this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool.Tier tier = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setTier($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Security\PrivateCA\V1\CaPool\Tier::class); - $this->tier = $var; - - return $this; - } - - /** - * Output only. The - * [State][google.cloud.security.privateca.v1.CertificateAuthority.State] for - * this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Output only. The - * [State][google.cloud.security.privateca.v1.CertificateAuthority.State] for - * this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority\State::class); - $this->state = $var; - - return $this; - } - - /** - * Output only. This - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s - * certificate chain, including the current - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s - * certificate. Ordered such that the root issuer is the final element - * (consistent with RFC 5246). For a self-signed CA, this will only list the - * current - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s - * certificate. - * - * Generated from protobuf field repeated string pem_ca_certificates = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return RepeatedField - */ - public function getPemCaCertificates() - { - return $this->pem_ca_certificates; - } - - /** - * Output only. This - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s - * certificate chain, including the current - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s - * certificate. Ordered such that the root issuer is the final element - * (consistent with RFC 5246). For a self-signed CA, this will only list the - * current - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s - * certificate. - * - * Generated from protobuf field repeated string pem_ca_certificates = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string[] $var - * @return $this - */ - public function setPemCaCertificates($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->pem_ca_certificates = $arr; - - return $this; - } - - /** - * Output only. A structured description of this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s - * CA certificate and its issuers. Ordered as self-to-root. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CertificateDescription ca_certificate_descriptions = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return RepeatedField<\Google\Cloud\Security\PrivateCA\V1\CertificateDescription> - */ - public function getCaCertificateDescriptions() - { - return $this->ca_certificate_descriptions; - } - - /** - * Output only. A structured description of this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s - * CA certificate and its issuers. Ordered as self-to-root. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CertificateDescription ca_certificate_descriptions = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\Security\PrivateCA\V1\CertificateDescription[] $var - * @return $this - */ - public function setCaCertificateDescriptions($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Security\PrivateCA\V1\CertificateDescription::class); - $this->ca_certificate_descriptions = $arr; - - return $this; - } - - /** - * Immutable. The name of a Cloud Storage bucket where this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * will publish content, such as the CA certificate and CRLs. This must be a - * bucket name, without any prefixes (such as `gs://`) or suffixes (such as - * `.googleapis.com`). For example, to use a bucket named `my-bucket`, you - * would simply specify `my-bucket`. If not specified, a managed bucket will - * be created. - * - * Generated from protobuf field string gcs_bucket = 11 [(.google.api.field_behavior) = IMMUTABLE]; - * @return string - */ - public function getGcsBucket() - { - return $this->gcs_bucket; - } - - /** - * Immutable. The name of a Cloud Storage bucket where this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * will publish content, such as the CA certificate and CRLs. This must be a - * bucket name, without any prefixes (such as `gs://`) or suffixes (such as - * `.googleapis.com`). For example, to use a bucket named `my-bucket`, you - * would simply specify `my-bucket`. If not specified, a managed bucket will - * be created. - * - * Generated from protobuf field string gcs_bucket = 11 [(.google.api.field_behavior) = IMMUTABLE]; - * @param string $var - * @return $this - */ - public function setGcsBucket($var) - { - GPBUtil::checkString($var, True); - $this->gcs_bucket = $var; - - return $this; - } - - /** - * Output only. URLs for accessing content published by this CA, such as the - * CA certificate and CRLs. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority.AccessUrls access_urls = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority\AccessUrls|null - */ - public function getAccessUrls() - { - return $this->access_urls; - } - - public function hasAccessUrls() - { - return isset($this->access_urls); - } - - public function clearAccessUrls() - { - unset($this->access_urls); - } - - /** - * Output only. URLs for accessing content published by this CA, such as the - * CA certificate and CRLs. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority.AccessUrls access_urls = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority\AccessUrls $var - * @return $this - */ - public function setAccessUrls($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority\AccessUrls::class); - $this->access_urls = $var; - - return $this; - } - - /** - * Output only. The time at which this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 13 [(.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 - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 13 [(.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 - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * was last updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 14 [(.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 at which this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * was last updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 14 [(.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 time at which this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * was soft deleted, if it is in the - * [DELETED][google.cloud.security.privateca.v1.CertificateAuthority.State.DELETED] - * state. - * - * Generated from protobuf field .google.protobuf.Timestamp delete_time = 15 [(.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. The time at which this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * was soft deleted, if it is in the - * [DELETED][google.cloud.security.privateca.v1.CertificateAuthority.State.DELETED] - * state. - * - * Generated from protobuf field .google.protobuf.Timestamp delete_time = 15 [(.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. The time at which this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * will be permanently purged, if it is in the - * [DELETED][google.cloud.security.privateca.v1.CertificateAuthority.State.DELETED] - * state. - * - * Generated from protobuf field .google.protobuf.Timestamp expire_time = 16 [(.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 - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * will be permanently purged, if it is in the - * [DELETED][google.cloud.security.privateca.v1.CertificateAuthority.State.DELETED] - * state. - * - * Generated from protobuf field .google.protobuf.Timestamp expire_time = 16 [(.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; - } - - /** - * Optional. Labels with user-defined metadata. - * - * Generated from protobuf field map labels = 17 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Optional. Labels with user-defined metadata. - * - * Generated from protobuf field map labels = 17 [(.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. User-defined URLs for CA certificate and CRLs. The service does - * not publish content to these URLs. It is up to the user to mirror content - * to these URLs. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority.UserDefinedAccessUrls user_defined_access_urls = 18 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority\UserDefinedAccessUrls|null - */ - public function getUserDefinedAccessUrls() - { - return $this->user_defined_access_urls; - } - - public function hasUserDefinedAccessUrls() - { - return isset($this->user_defined_access_urls); - } - - public function clearUserDefinedAccessUrls() - { - unset($this->user_defined_access_urls); - } - - /** - * Optional. User-defined URLs for CA certificate and CRLs. The service does - * not publish content to these URLs. It is up to the user to mirror content - * to these URLs. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority.UserDefinedAccessUrls user_defined_access_urls = 18 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority\UserDefinedAccessUrls $var - * @return $this - */ - public function setUserDefinedAccessUrls($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority\UserDefinedAccessUrls::class); - $this->user_defined_access_urls = $var; - - return $this; - } - - /** - * Output only. Reserved for future use. - * - * Generated from protobuf field bool satisfies_pzs = 19 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return bool - */ - public function getSatisfiesPzs() - { - return $this->satisfies_pzs; - } - - /** - * Output only. Reserved for future use. - * - * Generated from protobuf field bool satisfies_pzs = 19 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param bool $var - * @return $this - */ - public function setSatisfiesPzs($var) - { - GPBUtil::checkBool($var); - $this->satisfies_pzs = $var; - - return $this; - } - - /** - * Output only. Reserved for future use. - * - * Generated from protobuf field bool satisfies_pzi = 20 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return bool - */ - public function getSatisfiesPzi() - { - return $this->satisfies_pzi; - } - - /** - * Output only. Reserved for future use. - * - * Generated from protobuf field bool satisfies_pzi = 20 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param bool $var - * @return $this - */ - public function setSatisfiesPzi($var) - { - GPBUtil::checkBool($var); - $this->satisfies_pzi = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/AccessUrls.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/AccessUrls.php deleted file mode 100644 index 7b1f79c445b1..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/AccessUrls.php +++ /dev/null @@ -1,127 +0,0 @@ -google.cloud.security.privateca.v1.CertificateAuthority.AccessUrls - */ -class AccessUrls extends \Google\Protobuf\Internal\Message -{ - /** - * The URL where this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s - * CA certificate is published. This will only be set for CAs that have been - * activated. - * - * Generated from protobuf field string ca_certificate_access_url = 1; - */ - protected $ca_certificate_access_url = ''; - /** - * The URLs where this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s - * CRLs are published. This will only be set for CAs that have been - * activated. - * - * Generated from protobuf field repeated string crl_access_urls = 2; - */ - private $crl_access_urls; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $ca_certificate_access_url - * The URL where this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s - * CA certificate is published. This will only be set for CAs that have been - * activated. - * @type string[] $crl_access_urls - * The URLs where this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s - * CRLs are published. This will only be set for CAs that have been - * activated. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * The URL where this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s - * CA certificate is published. This will only be set for CAs that have been - * activated. - * - * Generated from protobuf field string ca_certificate_access_url = 1; - * @return string - */ - public function getCaCertificateAccessUrl() - { - return $this->ca_certificate_access_url; - } - - /** - * The URL where this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s - * CA certificate is published. This will only be set for CAs that have been - * activated. - * - * Generated from protobuf field string ca_certificate_access_url = 1; - * @param string $var - * @return $this - */ - public function setCaCertificateAccessUrl($var) - { - GPBUtil::checkString($var, True); - $this->ca_certificate_access_url = $var; - - return $this; - } - - /** - * The URLs where this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s - * CRLs are published. This will only be set for CAs that have been - * activated. - * - * Generated from protobuf field repeated string crl_access_urls = 2; - * @return RepeatedField - */ - public function getCrlAccessUrls() - { - return $this->crl_access_urls; - } - - /** - * The URLs where this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]'s - * CRLs are published. This will only be set for CAs that have been - * activated. - * - * Generated from protobuf field repeated string crl_access_urls = 2; - * @param string[] $var - * @return $this - */ - public function setCrlAccessUrls($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->crl_access_urls = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/KeyVersionSpec.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/KeyVersionSpec.php deleted file mode 100644 index 02829272751d..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/KeyVersionSpec.php +++ /dev/null @@ -1,128 +0,0 @@ -google.cloud.security.privateca.v1.CertificateAuthority.KeyVersionSpec - */ -class KeyVersionSpec extends \Google\Protobuf\Internal\Message -{ - protected $KeyVersion; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $cloud_kms_key_version - * The resource name for an existing Cloud KMS CryptoKeyVersion in the - * format - * `projects/{@*}locations/{@*}keyRings/{@*}cryptoKeys/{@*}cryptoKeyVersions/*`. - * This option enables full flexibility in the key's capabilities and - * properties. - * @type int $algorithm - * The algorithm to use for creating a managed Cloud KMS key for a for a - * simplified experience. All managed keys will be have their - * [ProtectionLevel][google.cloud.kms.v1.ProtectionLevel] as `HSM`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * The resource name for an existing Cloud KMS CryptoKeyVersion in the - * format - * `projects/{@*}locations/{@*}keyRings/{@*}cryptoKeys/{@*}cryptoKeyVersions/*`. - * This option enables full flexibility in the key's capabilities and - * properties. - * - * Generated from protobuf field string cloud_kms_key_version = 1; - * @return string - */ - public function getCloudKmsKeyVersion() - { - return $this->readOneof(1); - } - - public function hasCloudKmsKeyVersion() - { - return $this->hasOneof(1); - } - - /** - * The resource name for an existing Cloud KMS CryptoKeyVersion in the - * format - * `projects/{@*}locations/{@*}keyRings/{@*}cryptoKeys/{@*}cryptoKeyVersions/*`. - * This option enables full flexibility in the key's capabilities and - * properties. - * - * Generated from protobuf field string cloud_kms_key_version = 1; - * @param string $var - * @return $this - */ - public function setCloudKmsKeyVersion($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * The algorithm to use for creating a managed Cloud KMS key for a for a - * simplified experience. All managed keys will be have their - * [ProtectionLevel][google.cloud.kms.v1.ProtectionLevel] as `HSM`. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority.SignHashAlgorithm algorithm = 2; - * @return int - */ - public function getAlgorithm() - { - return $this->readOneof(2); - } - - public function hasAlgorithm() - { - return $this->hasOneof(2); - } - - /** - * The algorithm to use for creating a managed Cloud KMS key for a for a - * simplified experience. All managed keys will be have their - * [ProtectionLevel][google.cloud.kms.v1.ProtectionLevel] as `HSM`. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority.SignHashAlgorithm algorithm = 2; - * @param int $var - * @return $this - */ - public function setAlgorithm($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority\SignHashAlgorithm::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * @return string - */ - public function getKeyVersion() - { - return $this->whichOneof("KeyVersion"); - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/SignHashAlgorithm.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/SignHashAlgorithm.php deleted file mode 100644 index 1572ffc1a3d1..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/SignHashAlgorithm.php +++ /dev/null @@ -1,111 +0,0 @@ -google.cloud.security.privateca.v1.CertificateAuthority.SignHashAlgorithm - */ -class SignHashAlgorithm -{ - /** - * Not specified. - * - * Generated from protobuf enum SIGN_HASH_ALGORITHM_UNSPECIFIED = 0; - */ - const SIGN_HASH_ALGORITHM_UNSPECIFIED = 0; - /** - * maps to CryptoKeyVersionAlgorithm.RSA_SIGN_PSS_2048_SHA256 - * - * Generated from protobuf enum RSA_PSS_2048_SHA256 = 1; - */ - const RSA_PSS_2048_SHA256 = 1; - /** - * maps to CryptoKeyVersionAlgorithm. RSA_SIGN_PSS_3072_SHA256 - * - * Generated from protobuf enum RSA_PSS_3072_SHA256 = 2; - */ - const RSA_PSS_3072_SHA256 = 2; - /** - * maps to CryptoKeyVersionAlgorithm.RSA_SIGN_PSS_4096_SHA256 - * - * Generated from protobuf enum RSA_PSS_4096_SHA256 = 3; - */ - const RSA_PSS_4096_SHA256 = 3; - /** - * maps to CryptoKeyVersionAlgorithm.RSA_SIGN_PKCS1_2048_SHA256 - * - * Generated from protobuf enum RSA_PKCS1_2048_SHA256 = 6; - */ - const RSA_PKCS1_2048_SHA256 = 6; - /** - * maps to CryptoKeyVersionAlgorithm.RSA_SIGN_PKCS1_3072_SHA256 - * - * Generated from protobuf enum RSA_PKCS1_3072_SHA256 = 7; - */ - const RSA_PKCS1_3072_SHA256 = 7; - /** - * maps to CryptoKeyVersionAlgorithm.RSA_SIGN_PKCS1_4096_SHA256 - * - * Generated from protobuf enum RSA_PKCS1_4096_SHA256 = 8; - */ - const RSA_PKCS1_4096_SHA256 = 8; - /** - * maps to CryptoKeyVersionAlgorithm.EC_SIGN_P256_SHA256 - * - * Generated from protobuf enum EC_P256_SHA256 = 4; - */ - const EC_P256_SHA256 = 4; - /** - * maps to CryptoKeyVersionAlgorithm.EC_SIGN_P384_SHA384 - * - * Generated from protobuf enum EC_P384_SHA384 = 5; - */ - const EC_P384_SHA384 = 5; - - private static $valueToName = [ - self::SIGN_HASH_ALGORITHM_UNSPECIFIED => 'SIGN_HASH_ALGORITHM_UNSPECIFIED', - self::RSA_PSS_2048_SHA256 => 'RSA_PSS_2048_SHA256', - self::RSA_PSS_3072_SHA256 => 'RSA_PSS_3072_SHA256', - self::RSA_PSS_4096_SHA256 => 'RSA_PSS_4096_SHA256', - self::RSA_PKCS1_2048_SHA256 => 'RSA_PKCS1_2048_SHA256', - self::RSA_PKCS1_3072_SHA256 => 'RSA_PKCS1_3072_SHA256', - self::RSA_PKCS1_4096_SHA256 => 'RSA_PKCS1_4096_SHA256', - self::EC_P256_SHA256 => 'EC_P256_SHA256', - self::EC_P384_SHA384 => 'EC_P384_SHA384', - ]; - - 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/State.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/State.php deleted file mode 100644 index e3741fdbc95f..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/State.php +++ /dev/null @@ -1,108 +0,0 @@ -google.cloud.security.privateca.v1.CertificateAuthority.State - */ -class State -{ - /** - * Not specified. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * Certificates can be issued from this CA. CRLs will be generated for this - * CA. The CA will be part of the - * [CaPool][google.cloud.security.privateca.v1.CaPool]'s trust anchor, and - * will be used to issue certificates from the - * [CaPool][google.cloud.security.privateca.v1.CaPool]. - * - * Generated from protobuf enum ENABLED = 1; - */ - const ENABLED = 1; - /** - * Certificates cannot be issued from this CA. CRLs will still be generated. - * The CA will be part of the - * [CaPool][google.cloud.security.privateca.v1.CaPool]'s trust anchor, but - * will not be used to issue certificates from the - * [CaPool][google.cloud.security.privateca.v1.CaPool]. - * - * Generated from protobuf enum DISABLED = 2; - */ - const DISABLED = 2; - /** - * Certificates can be issued from this CA. CRLs will be generated for this - * CA. The CA will be part of the - * [CaPool][google.cloud.security.privateca.v1.CaPool]'s trust anchor, but - * will not be used to issue certificates from the - * [CaPool][google.cloud.security.privateca.v1.CaPool]. - * - * Generated from protobuf enum STAGED = 3; - */ - const STAGED = 3; - /** - * Certificates cannot be issued from this CA. CRLs will not be generated. - * The CA will not be part of the - * [CaPool][google.cloud.security.privateca.v1.CaPool]'s trust anchor, and - * will not be used to issue certificates from the - * [CaPool][google.cloud.security.privateca.v1.CaPool]. - * - * Generated from protobuf enum AWAITING_USER_ACTIVATION = 4; - */ - const AWAITING_USER_ACTIVATION = 4; - /** - * Certificates cannot be issued from this CA. CRLs will not be generated. - * The CA may still be recovered by calling - * [CertificateAuthorityService.UndeleteCertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthorityService.UndeleteCertificateAuthority] - * before - * [expire_time][google.cloud.security.privateca.v1.CertificateAuthority.expire_time]. - * The CA will not be part of the - * [CaPool][google.cloud.security.privateca.v1.CaPool]'s trust anchor, and - * will not be used to issue certificates from the - * [CaPool][google.cloud.security.privateca.v1.CaPool]. - * - * Generated from protobuf enum DELETED = 5; - */ - const DELETED = 5; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::ENABLED => 'ENABLED', - self::DISABLED => 'DISABLED', - self::STAGED => 'STAGED', - self::AWAITING_USER_ACTIVATION => 'AWAITING_USER_ACTIVATION', - 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); - } -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/Type.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/Type.php deleted file mode 100644 index d9559ba8a1a7..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/Type.php +++ /dev/null @@ -1,65 +0,0 @@ -google.cloud.security.privateca.v1.CertificateAuthority.Type - */ -class Type -{ - /** - * Not specified. - * - * Generated from protobuf enum TYPE_UNSPECIFIED = 0; - */ - const TYPE_UNSPECIFIED = 0; - /** - * Self-signed CA. - * - * Generated from protobuf enum SELF_SIGNED = 1; - */ - const SELF_SIGNED = 1; - /** - * Subordinate CA. Could be issued by a Private CA - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * or an unmanaged CA. - * - * Generated from protobuf enum SUBORDINATE = 2; - */ - const SUBORDINATE = 2; - - private static $valueToName = [ - self::TYPE_UNSPECIFIED => 'TYPE_UNSPECIFIED', - self::SELF_SIGNED => 'SELF_SIGNED', - self::SUBORDINATE => 'SUBORDINATE', - ]; - - 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/UserDefinedAccessUrls.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/UserDefinedAccessUrls.php deleted file mode 100644 index 5e5927f1b981..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateAuthority/UserDefinedAccessUrls.php +++ /dev/null @@ -1,142 +0,0 @@ -google.cloud.security.privateca.v1.CertificateAuthority.UserDefinedAccessUrls - */ -class UserDefinedAccessUrls extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. A list of URLs where the issuer CA certificate may be - * downloaded, which appears in the "Authority Information Access" extension - * in the certificate. If specified, the default [Cloud Storage - * URLs][google.cloud.security.privateca.v1.CertificateAuthority.AccessUrls.ca_certificate_access_url] - * will be omitted. - * - * Generated from protobuf field repeated string aia_issuing_certificate_urls = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $aia_issuing_certificate_urls; - /** - * Optional. A list of URLs where to obtain CRL information, i.e. - * the DistributionPoint.fullName described by - * https://tools.ietf.org/html/rfc5280#section-4.2.1.13. - * If specified, the default - * [Cloud Storage - * URLs][google.cloud.security.privateca.v1.CertificateAuthority.AccessUrls.crl_access_urls] - * will be omitted. - * - * Generated from protobuf field repeated string crl_access_urls = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $crl_access_urls; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string[] $aia_issuing_certificate_urls - * Optional. A list of URLs where the issuer CA certificate may be - * downloaded, which appears in the "Authority Information Access" extension - * in the certificate. If specified, the default [Cloud Storage - * URLs][google.cloud.security.privateca.v1.CertificateAuthority.AccessUrls.ca_certificate_access_url] - * will be omitted. - * @type string[] $crl_access_urls - * Optional. A list of URLs where to obtain CRL information, i.e. - * the DistributionPoint.fullName described by - * https://tools.ietf.org/html/rfc5280#section-4.2.1.13. - * If specified, the default - * [Cloud Storage - * URLs][google.cloud.security.privateca.v1.CertificateAuthority.AccessUrls.crl_access_urls] - * will be omitted. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * Optional. A list of URLs where the issuer CA certificate may be - * downloaded, which appears in the "Authority Information Access" extension - * in the certificate. If specified, the default [Cloud Storage - * URLs][google.cloud.security.privateca.v1.CertificateAuthority.AccessUrls.ca_certificate_access_url] - * will be omitted. - * - * Generated from protobuf field repeated string aia_issuing_certificate_urls = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @return RepeatedField - */ - public function getAiaIssuingCertificateUrls() - { - return $this->aia_issuing_certificate_urls; - } - - /** - * Optional. A list of URLs where the issuer CA certificate may be - * downloaded, which appears in the "Authority Information Access" extension - * in the certificate. If specified, the default [Cloud Storage - * URLs][google.cloud.security.privateca.v1.CertificateAuthority.AccessUrls.ca_certificate_access_url] - * will be omitted. - * - * Generated from protobuf field repeated string aia_issuing_certificate_urls = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @param string[] $var - * @return $this - */ - public function setAiaIssuingCertificateUrls($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->aia_issuing_certificate_urls = $arr; - - return $this; - } - - /** - * Optional. A list of URLs where to obtain CRL information, i.e. - * the DistributionPoint.fullName described by - * https://tools.ietf.org/html/rfc5280#section-4.2.1.13. - * If specified, the default - * [Cloud Storage - * URLs][google.cloud.security.privateca.v1.CertificateAuthority.AccessUrls.crl_access_urls] - * will be omitted. - * - * Generated from protobuf field repeated string crl_access_urls = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return RepeatedField - */ - public function getCrlAccessUrls() - { - return $this->crl_access_urls; - } - - /** - * Optional. A list of URLs where to obtain CRL information, i.e. - * the DistributionPoint.fullName described by - * https://tools.ietf.org/html/rfc5280#section-4.2.1.13. - * If specified, the default - * [Cloud Storage - * URLs][google.cloud.security.privateca.v1.CertificateAuthority.AccessUrls.crl_access_urls] - * will be omitted. - * - * Generated from protobuf field repeated string crl_access_urls = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param string[] $var - * @return $this - */ - public function setCrlAccessUrls($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->crl_access_urls = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateConfig.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateConfig.php deleted file mode 100644 index 2504069cb736..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateConfig.php +++ /dev/null @@ -1,259 +0,0 @@ -google.cloud.security.privateca.v1.CertificateConfig - */ -class CertificateConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Specifies some of the values in a certificate that are related to - * the subject. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateConfig.SubjectConfig subject_config = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $subject_config = null; - /** - * Required. Describes how some of the technical X.509 fields in a certificate - * should be populated. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.X509Parameters x509_config = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $x509_config = null; - /** - * Optional. The public key that corresponds to this config. This is, for - * example, used when issuing - * [Certificates][google.cloud.security.privateca.v1.Certificate], but not - * when creating a self-signed - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * or - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * CSR. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.PublicKey public_key = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $public_key = null; - /** - * Optional. When specified this provides a custom SKI to be used in the - * certificate. This should only be used to maintain a SKI of an existing CA - * originally created outside CA service, which was not generated using method - * (1) described in RFC 5280 section 4.2.1.2. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateConfig.KeyId subject_key_id = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $subject_key_id = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Security\PrivateCA\V1\CertificateConfig\SubjectConfig $subject_config - * Required. Specifies some of the values in a certificate that are related to - * the subject. - * @type \Google\Cloud\Security\PrivateCA\V1\X509Parameters $x509_config - * Required. Describes how some of the technical X.509 fields in a certificate - * should be populated. - * @type \Google\Cloud\Security\PrivateCA\V1\PublicKey $public_key - * Optional. The public key that corresponds to this config. This is, for - * example, used when issuing - * [Certificates][google.cloud.security.privateca.v1.Certificate], but not - * when creating a self-signed - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * or - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * CSR. - * @type \Google\Cloud\Security\PrivateCA\V1\CertificateConfig\KeyId $subject_key_id - * Optional. When specified this provides a custom SKI to be used in the - * certificate. This should only be used to maintain a SKI of an existing CA - * originally created outside CA service, which was not generated using method - * (1) described in RFC 5280 section 4.2.1.2. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * Required. Specifies some of the values in a certificate that are related to - * the subject. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateConfig.SubjectConfig subject_config = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Security\PrivateCA\V1\CertificateConfig\SubjectConfig|null - */ - public function getSubjectConfig() - { - return $this->subject_config; - } - - public function hasSubjectConfig() - { - return isset($this->subject_config); - } - - public function clearSubjectConfig() - { - unset($this->subject_config); - } - - /** - * Required. Specifies some of the values in a certificate that are related to - * the subject. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateConfig.SubjectConfig subject_config = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Security\PrivateCA\V1\CertificateConfig\SubjectConfig $var - * @return $this - */ - public function setSubjectConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CertificateConfig\SubjectConfig::class); - $this->subject_config = $var; - - return $this; - } - - /** - * Required. Describes how some of the technical X.509 fields in a certificate - * should be populated. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.X509Parameters x509_config = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Security\PrivateCA\V1\X509Parameters|null - */ - public function getX509Config() - { - return $this->x509_config; - } - - public function hasX509Config() - { - return isset($this->x509_config); - } - - public function clearX509Config() - { - unset($this->x509_config); - } - - /** - * Required. Describes how some of the technical X.509 fields in a certificate - * should be populated. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.X509Parameters x509_config = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Security\PrivateCA\V1\X509Parameters $var - * @return $this - */ - public function setX509Config($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\X509Parameters::class); - $this->x509_config = $var; - - return $this; - } - - /** - * Optional. The public key that corresponds to this config. This is, for - * example, used when issuing - * [Certificates][google.cloud.security.privateca.v1.Certificate], but not - * when creating a self-signed - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * or - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * CSR. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.PublicKey public_key = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\Security\PrivateCA\V1\PublicKey|null - */ - public function getPublicKey() - { - return $this->public_key; - } - - public function hasPublicKey() - { - return isset($this->public_key); - } - - public function clearPublicKey() - { - unset($this->public_key); - } - - /** - * Optional. The public key that corresponds to this config. This is, for - * example, used when issuing - * [Certificates][google.cloud.security.privateca.v1.Certificate], but not - * when creating a self-signed - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * or - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * CSR. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.PublicKey public_key = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\Security\PrivateCA\V1\PublicKey $var - * @return $this - */ - public function setPublicKey($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\PublicKey::class); - $this->public_key = $var; - - return $this; - } - - /** - * Optional. When specified this provides a custom SKI to be used in the - * certificate. This should only be used to maintain a SKI of an existing CA - * originally created outside CA service, which was not generated using method - * (1) described in RFC 5280 section 4.2.1.2. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateConfig.KeyId subject_key_id = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\Security\PrivateCA\V1\CertificateConfig\KeyId|null - */ - public function getSubjectKeyId() - { - return $this->subject_key_id; - } - - public function hasSubjectKeyId() - { - return isset($this->subject_key_id); - } - - public function clearSubjectKeyId() - { - unset($this->subject_key_id); - } - - /** - * Optional. When specified this provides a custom SKI to be used in the - * certificate. This should only be used to maintain a SKI of an existing CA - * originally created outside CA service, which was not generated using method - * (1) described in RFC 5280 section 4.2.1.2. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateConfig.KeyId subject_key_id = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\Security\PrivateCA\V1\CertificateConfig\KeyId $var - * @return $this - */ - public function setSubjectKeyId($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CertificateConfig\KeyId::class); - $this->subject_key_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateConfig/KeyId.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateConfig/KeyId.php deleted file mode 100644 index c8873de11789..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateConfig/KeyId.php +++ /dev/null @@ -1,72 +0,0 @@ -google.cloud.security.privateca.v1.CertificateConfig.KeyId - */ -class KeyId extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The value of this KeyId encoded in lowercase hexadecimal. This - * is most likely the 160 bit SHA-1 hash of the public key. - * - * Generated from protobuf field string key_id = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $key_id = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $key_id - * Required. The value of this KeyId encoded in lowercase hexadecimal. This - * is most likely the 160 bit SHA-1 hash of the public key. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * Required. The value of this KeyId encoded in lowercase hexadecimal. This - * is most likely the 160 bit SHA-1 hash of the public key. - * - * Generated from protobuf field string key_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getKeyId() - { - return $this->key_id; - } - - /** - * Required. The value of this KeyId encoded in lowercase hexadecimal. This - * is most likely the 160 bit SHA-1 hash of the public key. - * - * Generated from protobuf field string key_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * @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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateConfig/SubjectConfig.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateConfig/SubjectConfig.php deleted file mode 100644 index 30bba29d3256..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateConfig/SubjectConfig.php +++ /dev/null @@ -1,126 +0,0 @@ -google.cloud.security.privateca.v1.CertificateConfig.SubjectConfig - */ -class SubjectConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. Contains distinguished name fields such as the common name, - * location and organization. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.Subject subject = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $subject = null; - /** - * Optional. The subject alternative name fields. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.SubjectAltNames subject_alt_name = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $subject_alt_name = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Security\PrivateCA\V1\Subject $subject - * Optional. Contains distinguished name fields such as the common name, - * location and organization. - * @type \Google\Cloud\Security\PrivateCA\V1\SubjectAltNames $subject_alt_name - * Optional. The subject alternative name fields. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * Optional. Contains distinguished name fields such as the common name, - * location and organization. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.Subject subject = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\Security\PrivateCA\V1\Subject|null - */ - public function getSubject() - { - return $this->subject; - } - - public function hasSubject() - { - return isset($this->subject); - } - - public function clearSubject() - { - unset($this->subject); - } - - /** - * Optional. Contains distinguished name fields such as the common name, - * location and organization. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.Subject subject = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\Security\PrivateCA\V1\Subject $var - * @return $this - */ - public function setSubject($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\Subject::class); - $this->subject = $var; - - return $this; - } - - /** - * Optional. The subject alternative name fields. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.SubjectAltNames subject_alt_name = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\Security\PrivateCA\V1\SubjectAltNames|null - */ - public function getSubjectAltName() - { - return $this->subject_alt_name; - } - - public function hasSubjectAltName() - { - return isset($this->subject_alt_name); - } - - public function clearSubjectAltName() - { - unset($this->subject_alt_name); - } - - /** - * Optional. The subject alternative name fields. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.SubjectAltNames subject_alt_name = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\Security\PrivateCA\V1\SubjectAltNames $var - * @return $this - */ - public function setSubjectAltName($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\SubjectAltNames::class); - $this->subject_alt_name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateDescription.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateDescription.php deleted file mode 100644 index 569224be347b..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateDescription.php +++ /dev/null @@ -1,438 +0,0 @@ -google.cloud.security.privateca.v1.CertificateDescription - */ -class CertificateDescription extends \Google\Protobuf\Internal\Message -{ - /** - * Describes some of the values in a certificate that are related to the - * subject and lifetime. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateDescription.SubjectDescription subject_description = 1; - */ - protected $subject_description = null; - /** - * Describes some of the technical X.509 fields in a certificate. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.X509Parameters x509_description = 2; - */ - protected $x509_description = null; - /** - * The public key that corresponds to an issued certificate. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.PublicKey public_key = 3; - */ - protected $public_key = null; - /** - * Provides a means of identifiying certificates that contain a particular - * public key, per https://tools.ietf.org/html/rfc5280#section-4.2.1.2. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateDescription.KeyId subject_key_id = 4; - */ - protected $subject_key_id = null; - /** - * Identifies the subject_key_id of the parent certificate, per - * https://tools.ietf.org/html/rfc5280#section-4.2.1.1 - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateDescription.KeyId authority_key_id = 5; - */ - protected $authority_key_id = null; - /** - * Describes a list of locations to obtain CRL information, i.e. - * the DistributionPoint.fullName described by - * https://tools.ietf.org/html/rfc5280#section-4.2.1.13 - * - * Generated from protobuf field repeated string crl_distribution_points = 6; - */ - private $crl_distribution_points; - /** - * Describes lists of issuer CA certificate URLs that appear in the - * "Authority Information Access" extension in the certificate. - * - * Generated from protobuf field repeated string aia_issuing_certificate_urls = 7; - */ - private $aia_issuing_certificate_urls; - /** - * The hash of the x.509 certificate. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateDescription.CertificateFingerprint cert_fingerprint = 8; - */ - protected $cert_fingerprint = null; - /** - * The hash of the pre-signed certificate, which will be signed by the CA. - * Corresponds to the TBS Certificate in - * https://tools.ietf.org/html/rfc5280#section-4.1.2. The field will always be - * populated. - * - * Generated from protobuf field string tbs_certificate_digest = 9; - */ - protected $tbs_certificate_digest = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Security\PrivateCA\V1\CertificateDescription\SubjectDescription $subject_description - * Describes some of the values in a certificate that are related to the - * subject and lifetime. - * @type \Google\Cloud\Security\PrivateCA\V1\X509Parameters $x509_description - * Describes some of the technical X.509 fields in a certificate. - * @type \Google\Cloud\Security\PrivateCA\V1\PublicKey $public_key - * The public key that corresponds to an issued certificate. - * @type \Google\Cloud\Security\PrivateCA\V1\CertificateDescription\KeyId $subject_key_id - * Provides a means of identifiying certificates that contain a particular - * public key, per https://tools.ietf.org/html/rfc5280#section-4.2.1.2. - * @type \Google\Cloud\Security\PrivateCA\V1\CertificateDescription\KeyId $authority_key_id - * Identifies the subject_key_id of the parent certificate, per - * https://tools.ietf.org/html/rfc5280#section-4.2.1.1 - * @type string[] $crl_distribution_points - * Describes a list of locations to obtain CRL information, i.e. - * the DistributionPoint.fullName described by - * https://tools.ietf.org/html/rfc5280#section-4.2.1.13 - * @type string[] $aia_issuing_certificate_urls - * Describes lists of issuer CA certificate URLs that appear in the - * "Authority Information Access" extension in the certificate. - * @type \Google\Cloud\Security\PrivateCA\V1\CertificateDescription\CertificateFingerprint $cert_fingerprint - * The hash of the x.509 certificate. - * @type string $tbs_certificate_digest - * The hash of the pre-signed certificate, which will be signed by the CA. - * Corresponds to the TBS Certificate in - * https://tools.ietf.org/html/rfc5280#section-4.1.2. The field will always be - * populated. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * Describes some of the values in a certificate that are related to the - * subject and lifetime. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateDescription.SubjectDescription subject_description = 1; - * @return \Google\Cloud\Security\PrivateCA\V1\CertificateDescription\SubjectDescription|null - */ - public function getSubjectDescription() - { - return $this->subject_description; - } - - public function hasSubjectDescription() - { - return isset($this->subject_description); - } - - public function clearSubjectDescription() - { - unset($this->subject_description); - } - - /** - * Describes some of the values in a certificate that are related to the - * subject and lifetime. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateDescription.SubjectDescription subject_description = 1; - * @param \Google\Cloud\Security\PrivateCA\V1\CertificateDescription\SubjectDescription $var - * @return $this - */ - public function setSubjectDescription($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CertificateDescription\SubjectDescription::class); - $this->subject_description = $var; - - return $this; - } - - /** - * Describes some of the technical X.509 fields in a certificate. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.X509Parameters x509_description = 2; - * @return \Google\Cloud\Security\PrivateCA\V1\X509Parameters|null - */ - public function getX509Description() - { - return $this->x509_description; - } - - public function hasX509Description() - { - return isset($this->x509_description); - } - - public function clearX509Description() - { - unset($this->x509_description); - } - - /** - * Describes some of the technical X.509 fields in a certificate. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.X509Parameters x509_description = 2; - * @param \Google\Cloud\Security\PrivateCA\V1\X509Parameters $var - * @return $this - */ - public function setX509Description($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\X509Parameters::class); - $this->x509_description = $var; - - return $this; - } - - /** - * The public key that corresponds to an issued certificate. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.PublicKey public_key = 3; - * @return \Google\Cloud\Security\PrivateCA\V1\PublicKey|null - */ - public function getPublicKey() - { - return $this->public_key; - } - - public function hasPublicKey() - { - return isset($this->public_key); - } - - public function clearPublicKey() - { - unset($this->public_key); - } - - /** - * The public key that corresponds to an issued certificate. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.PublicKey public_key = 3; - * @param \Google\Cloud\Security\PrivateCA\V1\PublicKey $var - * @return $this - */ - public function setPublicKey($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\PublicKey::class); - $this->public_key = $var; - - return $this; - } - - /** - * Provides a means of identifiying certificates that contain a particular - * public key, per https://tools.ietf.org/html/rfc5280#section-4.2.1.2. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateDescription.KeyId subject_key_id = 4; - * @return \Google\Cloud\Security\PrivateCA\V1\CertificateDescription\KeyId|null - */ - public function getSubjectKeyId() - { - return $this->subject_key_id; - } - - public function hasSubjectKeyId() - { - return isset($this->subject_key_id); - } - - public function clearSubjectKeyId() - { - unset($this->subject_key_id); - } - - /** - * Provides a means of identifiying certificates that contain a particular - * public key, per https://tools.ietf.org/html/rfc5280#section-4.2.1.2. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateDescription.KeyId subject_key_id = 4; - * @param \Google\Cloud\Security\PrivateCA\V1\CertificateDescription\KeyId $var - * @return $this - */ - public function setSubjectKeyId($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CertificateDescription\KeyId::class); - $this->subject_key_id = $var; - - return $this; - } - - /** - * Identifies the subject_key_id of the parent certificate, per - * https://tools.ietf.org/html/rfc5280#section-4.2.1.1 - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateDescription.KeyId authority_key_id = 5; - * @return \Google\Cloud\Security\PrivateCA\V1\CertificateDescription\KeyId|null - */ - public function getAuthorityKeyId() - { - return $this->authority_key_id; - } - - public function hasAuthorityKeyId() - { - return isset($this->authority_key_id); - } - - public function clearAuthorityKeyId() - { - unset($this->authority_key_id); - } - - /** - * Identifies the subject_key_id of the parent certificate, per - * https://tools.ietf.org/html/rfc5280#section-4.2.1.1 - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateDescription.KeyId authority_key_id = 5; - * @param \Google\Cloud\Security\PrivateCA\V1\CertificateDescription\KeyId $var - * @return $this - */ - public function setAuthorityKeyId($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CertificateDescription\KeyId::class); - $this->authority_key_id = $var; - - return $this; - } - - /** - * Describes a list of locations to obtain CRL information, i.e. - * the DistributionPoint.fullName described by - * https://tools.ietf.org/html/rfc5280#section-4.2.1.13 - * - * Generated from protobuf field repeated string crl_distribution_points = 6; - * @return RepeatedField - */ - public function getCrlDistributionPoints() - { - return $this->crl_distribution_points; - } - - /** - * Describes a list of locations to obtain CRL information, i.e. - * the DistributionPoint.fullName described by - * https://tools.ietf.org/html/rfc5280#section-4.2.1.13 - * - * Generated from protobuf field repeated string crl_distribution_points = 6; - * @param string[] $var - * @return $this - */ - public function setCrlDistributionPoints($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->crl_distribution_points = $arr; - - return $this; - } - - /** - * Describes lists of issuer CA certificate URLs that appear in the - * "Authority Information Access" extension in the certificate. - * - * Generated from protobuf field repeated string aia_issuing_certificate_urls = 7; - * @return RepeatedField - */ - public function getAiaIssuingCertificateUrls() - { - return $this->aia_issuing_certificate_urls; - } - - /** - * Describes lists of issuer CA certificate URLs that appear in the - * "Authority Information Access" extension in the certificate. - * - * Generated from protobuf field repeated string aia_issuing_certificate_urls = 7; - * @param string[] $var - * @return $this - */ - public function setAiaIssuingCertificateUrls($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->aia_issuing_certificate_urls = $arr; - - return $this; - } - - /** - * The hash of the x.509 certificate. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateDescription.CertificateFingerprint cert_fingerprint = 8; - * @return \Google\Cloud\Security\PrivateCA\V1\CertificateDescription\CertificateFingerprint|null - */ - public function getCertFingerprint() - { - return $this->cert_fingerprint; - } - - public function hasCertFingerprint() - { - return isset($this->cert_fingerprint); - } - - public function clearCertFingerprint() - { - unset($this->cert_fingerprint); - } - - /** - * The hash of the x.509 certificate. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateDescription.CertificateFingerprint cert_fingerprint = 8; - * @param \Google\Cloud\Security\PrivateCA\V1\CertificateDescription\CertificateFingerprint $var - * @return $this - */ - public function setCertFingerprint($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CertificateDescription\CertificateFingerprint::class); - $this->cert_fingerprint = $var; - - return $this; - } - - /** - * The hash of the pre-signed certificate, which will be signed by the CA. - * Corresponds to the TBS Certificate in - * https://tools.ietf.org/html/rfc5280#section-4.1.2. The field will always be - * populated. - * - * Generated from protobuf field string tbs_certificate_digest = 9; - * @return string - */ - public function getTbsCertificateDigest() - { - return $this->tbs_certificate_digest; - } - - /** - * The hash of the pre-signed certificate, which will be signed by the CA. - * Corresponds to the TBS Certificate in - * https://tools.ietf.org/html/rfc5280#section-4.1.2. The field will always be - * populated. - * - * Generated from protobuf field string tbs_certificate_digest = 9; - * @param string $var - * @return $this - */ - public function setTbsCertificateDigest($var) - { - GPBUtil::checkString($var, True); - $this->tbs_certificate_digest = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateDescription/CertificateFingerprint.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateDescription/CertificateFingerprint.php deleted file mode 100644 index 0917921343d8..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateDescription/CertificateFingerprint.php +++ /dev/null @@ -1,67 +0,0 @@ -google.cloud.security.privateca.v1.CertificateDescription.CertificateFingerprint - */ -class CertificateFingerprint extends \Google\Protobuf\Internal\Message -{ - /** - * The SHA 256 hash, encoded in hexadecimal, of the DER x509 certificate. - * - * Generated from protobuf field string sha256_hash = 1; - */ - protected $sha256_hash = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $sha256_hash - * The SHA 256 hash, encoded in hexadecimal, of the DER x509 certificate. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * The SHA 256 hash, encoded in hexadecimal, of the DER x509 certificate. - * - * Generated from protobuf field string sha256_hash = 1; - * @return string - */ - public function getSha256Hash() - { - return $this->sha256_hash; - } - - /** - * The SHA 256 hash, encoded in hexadecimal, of the DER x509 certificate. - * - * Generated from protobuf field string sha256_hash = 1; - * @param string $var - * @return $this - */ - public function setSha256Hash($var) - { - GPBUtil::checkString($var, True); - $this->sha256_hash = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateDescription/KeyId.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateDescription/KeyId.php deleted file mode 100644 index 6d1dce5a6e80..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateDescription/KeyId.php +++ /dev/null @@ -1,72 +0,0 @@ -google.cloud.security.privateca.v1.CertificateDescription.KeyId - */ -class KeyId extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. The value of this KeyId encoded in lowercase hexadecimal. This - * is most likely the 160 bit SHA-1 hash of the public key. - * - * Generated from protobuf field string key_id = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $key_id = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $key_id - * Optional. The value of this KeyId encoded in lowercase hexadecimal. This - * is most likely the 160 bit SHA-1 hash of the public key. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * Optional. The value of this KeyId encoded in lowercase hexadecimal. This - * is most likely the 160 bit SHA-1 hash of the public key. - * - * Generated from protobuf field string key_id = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getKeyId() - { - return $this->key_id; - } - - /** - * Optional. The value of this KeyId encoded in lowercase hexadecimal. This - * is most likely the 160 bit SHA-1 hash of the public key. - * - * Generated from protobuf field string key_id = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateDescription/SubjectDescription.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateDescription/SubjectDescription.php deleted file mode 100644 index 1dad6e22127c..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateDescription/SubjectDescription.php +++ /dev/null @@ -1,304 +0,0 @@ -google.cloud.security.privateca.v1.CertificateDescription.SubjectDescription - */ -class SubjectDescription extends \Google\Protobuf\Internal\Message -{ - /** - * Contains distinguished name fields such as the common name, location and - * / organization. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.Subject subject = 1; - */ - protected $subject = null; - /** - * The subject alternative name fields. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.SubjectAltNames subject_alt_name = 2; - */ - protected $subject_alt_name = null; - /** - * The serial number encoded in lowercase hexadecimal. - * - * Generated from protobuf field string hex_serial_number = 3; - */ - protected $hex_serial_number = ''; - /** - * For convenience, the actual lifetime of an issued certificate. - * - * Generated from protobuf field .google.protobuf.Duration lifetime = 4; - */ - protected $lifetime = null; - /** - * The time at which the certificate becomes valid. - * - * Generated from protobuf field .google.protobuf.Timestamp not_before_time = 5; - */ - protected $not_before_time = null; - /** - * The time after which the certificate is expired. - * Per RFC 5280, the validity period for a certificate is the period of time - * from not_before_time through not_after_time, inclusive. - * Corresponds to 'not_before_time' + 'lifetime' - 1 second. - * - * Generated from protobuf field .google.protobuf.Timestamp not_after_time = 6; - */ - protected $not_after_time = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Security\PrivateCA\V1\Subject $subject - * Contains distinguished name fields such as the common name, location and - * / organization. - * @type \Google\Cloud\Security\PrivateCA\V1\SubjectAltNames $subject_alt_name - * The subject alternative name fields. - * @type string $hex_serial_number - * The serial number encoded in lowercase hexadecimal. - * @type \Google\Protobuf\Duration $lifetime - * For convenience, the actual lifetime of an issued certificate. - * @type \Google\Protobuf\Timestamp $not_before_time - * The time at which the certificate becomes valid. - * @type \Google\Protobuf\Timestamp $not_after_time - * The time after which the certificate is expired. - * Per RFC 5280, the validity period for a certificate is the period of time - * from not_before_time through not_after_time, inclusive. - * Corresponds to 'not_before_time' + 'lifetime' - 1 second. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * Contains distinguished name fields such as the common name, location and - * / organization. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.Subject subject = 1; - * @return \Google\Cloud\Security\PrivateCA\V1\Subject|null - */ - public function getSubject() - { - return $this->subject; - } - - public function hasSubject() - { - return isset($this->subject); - } - - public function clearSubject() - { - unset($this->subject); - } - - /** - * Contains distinguished name fields such as the common name, location and - * / organization. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.Subject subject = 1; - * @param \Google\Cloud\Security\PrivateCA\V1\Subject $var - * @return $this - */ - public function setSubject($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\Subject::class); - $this->subject = $var; - - return $this; - } - - /** - * The subject alternative name fields. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.SubjectAltNames subject_alt_name = 2; - * @return \Google\Cloud\Security\PrivateCA\V1\SubjectAltNames|null - */ - public function getSubjectAltName() - { - return $this->subject_alt_name; - } - - public function hasSubjectAltName() - { - return isset($this->subject_alt_name); - } - - public function clearSubjectAltName() - { - unset($this->subject_alt_name); - } - - /** - * The subject alternative name fields. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.SubjectAltNames subject_alt_name = 2; - * @param \Google\Cloud\Security\PrivateCA\V1\SubjectAltNames $var - * @return $this - */ - public function setSubjectAltName($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\SubjectAltNames::class); - $this->subject_alt_name = $var; - - return $this; - } - - /** - * The serial number encoded in lowercase hexadecimal. - * - * Generated from protobuf field string hex_serial_number = 3; - * @return string - */ - public function getHexSerialNumber() - { - return $this->hex_serial_number; - } - - /** - * The serial number encoded in lowercase hexadecimal. - * - * Generated from protobuf field string hex_serial_number = 3; - * @param string $var - * @return $this - */ - public function setHexSerialNumber($var) - { - GPBUtil::checkString($var, True); - $this->hex_serial_number = $var; - - return $this; - } - - /** - * For convenience, the actual lifetime of an issued certificate. - * - * Generated from protobuf field .google.protobuf.Duration lifetime = 4; - * @return \Google\Protobuf\Duration|null - */ - public function getLifetime() - { - return $this->lifetime; - } - - public function hasLifetime() - { - return isset($this->lifetime); - } - - public function clearLifetime() - { - unset($this->lifetime); - } - - /** - * For convenience, the actual lifetime of an issued certificate. - * - * Generated from protobuf field .google.protobuf.Duration lifetime = 4; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setLifetime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->lifetime = $var; - - return $this; - } - - /** - * The time at which the certificate becomes valid. - * - * Generated from protobuf field .google.protobuf.Timestamp not_before_time = 5; - * @return \Google\Protobuf\Timestamp|null - */ - public function getNotBeforeTime() - { - return $this->not_before_time; - } - - public function hasNotBeforeTime() - { - return isset($this->not_before_time); - } - - public function clearNotBeforeTime() - { - unset($this->not_before_time); - } - - /** - * The time at which the certificate becomes valid. - * - * Generated from protobuf field .google.protobuf.Timestamp not_before_time = 5; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setNotBeforeTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->not_before_time = $var; - - return $this; - } - - /** - * The time after which the certificate is expired. - * Per RFC 5280, the validity period for a certificate is the period of time - * from not_before_time through not_after_time, inclusive. - * Corresponds to 'not_before_time' + 'lifetime' - 1 second. - * - * Generated from protobuf field .google.protobuf.Timestamp not_after_time = 6; - * @return \Google\Protobuf\Timestamp|null - */ - public function getNotAfterTime() - { - return $this->not_after_time; - } - - public function hasNotAfterTime() - { - return isset($this->not_after_time); - } - - public function clearNotAfterTime() - { - unset($this->not_after_time); - } - - /** - * The time after which the certificate is expired. - * Per RFC 5280, the validity period for a certificate is the period of time - * from not_before_time through not_after_time, inclusive. - * Corresponds to 'not_before_time' + 'lifetime' - 1 second. - * - * Generated from protobuf field .google.protobuf.Timestamp not_after_time = 6; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setNotAfterTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->not_after_time = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateExtensionConstraints.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateExtensionConstraints.php deleted file mode 100644 index 27c29d4fa4ae..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateExtensionConstraints.php +++ /dev/null @@ -1,122 +0,0 @@ -google.cloud.security.privateca.v1.CertificateExtensionConstraints - */ -class CertificateExtensionConstraints extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. A set of named X.509 extensions. Will be combined with - * [additional_extensions][google.cloud.security.privateca.v1.CertificateExtensionConstraints.additional_extensions] - * to determine the full set of X.509 extensions. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CertificateExtensionConstraints.KnownCertificateExtension known_extensions = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $known_extensions; - /** - * Optional. A set of [ObjectIds][google.cloud.security.privateca.v1.ObjectId] - * identifying custom X.509 extensions. Will be combined with - * [known_extensions][google.cloud.security.privateca.v1.CertificateExtensionConstraints.known_extensions] - * to determine the full set of X.509 extensions. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.ObjectId additional_extensions = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $additional_extensions; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int[] $known_extensions - * Optional. A set of named X.509 extensions. Will be combined with - * [additional_extensions][google.cloud.security.privateca.v1.CertificateExtensionConstraints.additional_extensions] - * to determine the full set of X.509 extensions. - * @type \Google\Cloud\Security\PrivateCA\V1\ObjectId[] $additional_extensions - * Optional. A set of [ObjectIds][google.cloud.security.privateca.v1.ObjectId] - * identifying custom X.509 extensions. Will be combined with - * [known_extensions][google.cloud.security.privateca.v1.CertificateExtensionConstraints.known_extensions] - * to determine the full set of X.509 extensions. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * Optional. A set of named X.509 extensions. Will be combined with - * [additional_extensions][google.cloud.security.privateca.v1.CertificateExtensionConstraints.additional_extensions] - * to determine the full set of X.509 extensions. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CertificateExtensionConstraints.KnownCertificateExtension known_extensions = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @return RepeatedField - */ - public function getKnownExtensions() - { - return $this->known_extensions; - } - - /** - * Optional. A set of named X.509 extensions. Will be combined with - * [additional_extensions][google.cloud.security.privateca.v1.CertificateExtensionConstraints.additional_extensions] - * to determine the full set of X.509 extensions. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CertificateExtensionConstraints.KnownCertificateExtension known_extensions = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @param int[] $var - * @return $this - */ - public function setKnownExtensions($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\Security\PrivateCA\V1\CertificateExtensionConstraints\KnownCertificateExtension::class); - $this->known_extensions = $arr; - - return $this; - } - - /** - * Optional. A set of [ObjectIds][google.cloud.security.privateca.v1.ObjectId] - * identifying custom X.509 extensions. Will be combined with - * [known_extensions][google.cloud.security.privateca.v1.CertificateExtensionConstraints.known_extensions] - * to determine the full set of X.509 extensions. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.ObjectId additional_extensions = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return RepeatedField<\Google\Cloud\Security\PrivateCA\V1\ObjectId> - */ - public function getAdditionalExtensions() - { - return $this->additional_extensions; - } - - /** - * Optional. A set of [ObjectIds][google.cloud.security.privateca.v1.ObjectId] - * identifying custom X.509 extensions. Will be combined with - * [known_extensions][google.cloud.security.privateca.v1.CertificateExtensionConstraints.known_extensions] - * to determine the full set of X.509 extensions. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.ObjectId additional_extensions = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\Security\PrivateCA\V1\ObjectId[] $var - * @return $this - */ - public function setAdditionalExtensions($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Security\PrivateCA\V1\ObjectId::class); - $this->additional_extensions = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateExtensionConstraints/KnownCertificateExtension.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateExtensionConstraints/KnownCertificateExtension.php deleted file mode 100644 index acd4be6ab29d..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateExtensionConstraints/KnownCertificateExtension.php +++ /dev/null @@ -1,120 +0,0 @@ -google.cloud.security.privateca.v1.CertificateExtensionConstraints.KnownCertificateExtension - */ -class KnownCertificateExtension -{ - /** - * Not specified. - * - * Generated from protobuf enum KNOWN_CERTIFICATE_EXTENSION_UNSPECIFIED = 0; - */ - const KNOWN_CERTIFICATE_EXTENSION_UNSPECIFIED = 0; - /** - * Refers to a certificate's Key Usage extension, as described in [RFC 5280 - * section 4.2.1.3](https://tools.ietf.org/html/rfc5280#section-4.2.1.3). - * This corresponds to the - * [KeyUsage.base_key_usage][google.cloud.security.privateca.v1.KeyUsage.base_key_usage] - * field. - * - * Generated from protobuf enum BASE_KEY_USAGE = 1; - */ - const BASE_KEY_USAGE = 1; - /** - * Refers to a certificate's Extended Key Usage extension, as described in - * [RFC 5280 - * section 4.2.1.12](https://tools.ietf.org/html/rfc5280#section-4.2.1.12). - * This corresponds to the - * [KeyUsage.extended_key_usage][google.cloud.security.privateca.v1.KeyUsage.extended_key_usage] - * message. - * - * Generated from protobuf enum EXTENDED_KEY_USAGE = 2; - */ - const EXTENDED_KEY_USAGE = 2; - /** - * Refers to a certificate's Basic Constraints extension, as described in - * [RFC 5280 - * section 4.2.1.9](https://tools.ietf.org/html/rfc5280#section-4.2.1.9). - * This corresponds to the - * [X509Parameters.ca_options][google.cloud.security.privateca.v1.X509Parameters.ca_options] - * field. - * - * Generated from protobuf enum CA_OPTIONS = 3; - */ - const CA_OPTIONS = 3; - /** - * Refers to a certificate's Policy object identifiers, as described in - * [RFC 5280 - * section 4.2.1.4](https://tools.ietf.org/html/rfc5280#section-4.2.1.4). - * This corresponds to the - * [X509Parameters.policy_ids][google.cloud.security.privateca.v1.X509Parameters.policy_ids] - * field. - * - * Generated from protobuf enum POLICY_IDS = 4; - */ - const POLICY_IDS = 4; - /** - * Refers to OCSP servers in a certificate's Authority Information Access - * extension, as described in - * [RFC 5280 - * section 4.2.2.1](https://tools.ietf.org/html/rfc5280#section-4.2.2.1), - * This corresponds to the - * [X509Parameters.aia_ocsp_servers][google.cloud.security.privateca.v1.X509Parameters.aia_ocsp_servers] - * field. - * - * Generated from protobuf enum AIA_OCSP_SERVERS = 5; - */ - const AIA_OCSP_SERVERS = 5; - /** - * Refers to Name Constraints extension as described in - * [RFC 5280 - * section 4.2.1.10](https://tools.ietf.org/html/rfc5280#section-4.2.1.10) - * - * Generated from protobuf enum NAME_CONSTRAINTS = 6; - */ - const NAME_CONSTRAINTS = 6; - - private static $valueToName = [ - self::KNOWN_CERTIFICATE_EXTENSION_UNSPECIFIED => 'KNOWN_CERTIFICATE_EXTENSION_UNSPECIFIED', - self::BASE_KEY_USAGE => 'BASE_KEY_USAGE', - self::EXTENDED_KEY_USAGE => 'EXTENDED_KEY_USAGE', - self::CA_OPTIONS => 'CA_OPTIONS', - self::POLICY_IDS => 'POLICY_IDS', - self::AIA_OCSP_SERVERS => 'AIA_OCSP_SERVERS', - self::NAME_CONSTRAINTS => 'NAME_CONSTRAINTS', - ]; - - 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateIdentityConstraints.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateIdentityConstraints.php deleted file mode 100644 index eef3861b4394..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateIdentityConstraints.php +++ /dev/null @@ -1,216 +0,0 @@ -google.cloud.security.privateca.v1.CertificateIdentityConstraints - */ -class CertificateIdentityConstraints extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. A CEL expression that may be used to validate the resolved X.509 - * Subject and/or Subject Alternative Name before a certificate is signed. To - * see the full allowed syntax and some examples, see - * https://cloud.google.com/certificate-authority-service/docs/using-cel - * - * Generated from protobuf field .google.type.Expr cel_expression = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $cel_expression = null; - /** - * Required. If this is true, the - * [Subject][google.cloud.security.privateca.v1.Subject] field may be copied - * from a certificate request into the signed certificate. Otherwise, the - * requested [Subject][google.cloud.security.privateca.v1.Subject] will be - * discarded. - * - * Generated from protobuf field optional bool allow_subject_passthrough = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $allow_subject_passthrough = null; - /** - * Required. If this is true, the - * [SubjectAltNames][google.cloud.security.privateca.v1.SubjectAltNames] - * extension may be copied from a certificate request into the signed - * certificate. Otherwise, the requested - * [SubjectAltNames][google.cloud.security.privateca.v1.SubjectAltNames] will - * be discarded. - * - * Generated from protobuf field optional bool allow_subject_alt_names_passthrough = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $allow_subject_alt_names_passthrough = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Type\Expr $cel_expression - * Optional. A CEL expression that may be used to validate the resolved X.509 - * Subject and/or Subject Alternative Name before a certificate is signed. To - * see the full allowed syntax and some examples, see - * https://cloud.google.com/certificate-authority-service/docs/using-cel - * @type bool $allow_subject_passthrough - * Required. If this is true, the - * [Subject][google.cloud.security.privateca.v1.Subject] field may be copied - * from a certificate request into the signed certificate. Otherwise, the - * requested [Subject][google.cloud.security.privateca.v1.Subject] will be - * discarded. - * @type bool $allow_subject_alt_names_passthrough - * Required. If this is true, the - * [SubjectAltNames][google.cloud.security.privateca.v1.SubjectAltNames] - * extension may be copied from a certificate request into the signed - * certificate. Otherwise, the requested - * [SubjectAltNames][google.cloud.security.privateca.v1.SubjectAltNames] will - * be discarded. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * Optional. A CEL expression that may be used to validate the resolved X.509 - * Subject and/or Subject Alternative Name before a certificate is signed. To - * see the full allowed syntax and some examples, see - * https://cloud.google.com/certificate-authority-service/docs/using-cel - * - * Generated from protobuf field .google.type.Expr cel_expression = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Type\Expr|null - */ - public function getCelExpression() - { - return $this->cel_expression; - } - - public function hasCelExpression() - { - return isset($this->cel_expression); - } - - public function clearCelExpression() - { - unset($this->cel_expression); - } - - /** - * Optional. A CEL expression that may be used to validate the resolved X.509 - * Subject and/or Subject Alternative Name before a certificate is signed. To - * see the full allowed syntax and some examples, see - * https://cloud.google.com/certificate-authority-service/docs/using-cel - * - * Generated from protobuf field .google.type.Expr cel_expression = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Type\Expr $var - * @return $this - */ - public function setCelExpression($var) - { - GPBUtil::checkMessage($var, \Google\Type\Expr::class); - $this->cel_expression = $var; - - return $this; - } - - /** - * Required. If this is true, the - * [Subject][google.cloud.security.privateca.v1.Subject] field may be copied - * from a certificate request into the signed certificate. Otherwise, the - * requested [Subject][google.cloud.security.privateca.v1.Subject] will be - * discarded. - * - * Generated from protobuf field optional bool allow_subject_passthrough = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return bool - */ - public function getAllowSubjectPassthrough() - { - return isset($this->allow_subject_passthrough) ? $this->allow_subject_passthrough : false; - } - - public function hasAllowSubjectPassthrough() - { - return isset($this->allow_subject_passthrough); - } - - public function clearAllowSubjectPassthrough() - { - unset($this->allow_subject_passthrough); - } - - /** - * Required. If this is true, the - * [Subject][google.cloud.security.privateca.v1.Subject] field may be copied - * from a certificate request into the signed certificate. Otherwise, the - * requested [Subject][google.cloud.security.privateca.v1.Subject] will be - * discarded. - * - * Generated from protobuf field optional bool allow_subject_passthrough = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param bool $var - * @return $this - */ - public function setAllowSubjectPassthrough($var) - { - GPBUtil::checkBool($var); - $this->allow_subject_passthrough = $var; - - return $this; - } - - /** - * Required. If this is true, the - * [SubjectAltNames][google.cloud.security.privateca.v1.SubjectAltNames] - * extension may be copied from a certificate request into the signed - * certificate. Otherwise, the requested - * [SubjectAltNames][google.cloud.security.privateca.v1.SubjectAltNames] will - * be discarded. - * - * Generated from protobuf field optional bool allow_subject_alt_names_passthrough = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return bool - */ - public function getAllowSubjectAltNamesPassthrough() - { - return isset($this->allow_subject_alt_names_passthrough) ? $this->allow_subject_alt_names_passthrough : false; - } - - public function hasAllowSubjectAltNamesPassthrough() - { - return isset($this->allow_subject_alt_names_passthrough); - } - - public function clearAllowSubjectAltNamesPassthrough() - { - unset($this->allow_subject_alt_names_passthrough); - } - - /** - * Required. If this is true, the - * [SubjectAltNames][google.cloud.security.privateca.v1.SubjectAltNames] - * extension may be copied from a certificate request into the signed - * certificate. Otherwise, the requested - * [SubjectAltNames][google.cloud.security.privateca.v1.SubjectAltNames] will - * be discarded. - * - * Generated from protobuf field optional bool allow_subject_alt_names_passthrough = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param bool $var - * @return $this - */ - public function setAllowSubjectAltNamesPassthrough($var) - { - GPBUtil::checkBool($var); - $this->allow_subject_alt_names_passthrough = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateRevocationList.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateRevocationList.php deleted file mode 100644 index 586fb81d765c..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateRevocationList.php +++ /dev/null @@ -1,448 +0,0 @@ -google.cloud.security.privateca.v1.CertificateRevocationList - */ -class CertificateRevocationList extends \Google\Protobuf\Internal\Message -{ - /** - * Identifier. The resource name for this - * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] - * in the format `projects/{@*}locations/{@*}caPools/*certificateAuthorities/{@*} - * certificateRevocationLists/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; - */ - protected $name = ''; - /** - * Output only. The CRL sequence number that appears in pem_crl. - * - * Generated from protobuf field int64 sequence_number = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $sequence_number = 0; - /** - * Output only. The revoked serial numbers that appear in pem_crl. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CertificateRevocationList.RevokedCertificate revoked_certificates = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - private $revoked_certificates; - /** - * Output only. The PEM-encoded X.509 CRL. - * - * Generated from protobuf field string pem_crl = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $pem_crl = ''; - /** - * Output only. The location where 'pem_crl' can be accessed. - * - * Generated from protobuf field string access_url = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $access_url = ''; - /** - * Output only. The - * [State][google.cloud.security.privateca.v1.CertificateRevocationList.State] - * for this - * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList]. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateRevocationList.State state = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = 0; - /** - * Output only. The time at which this - * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] - * was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The time at which this - * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] - * was updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Output only. The revision ID of this - * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList]. - * A new revision is committed whenever a new CRL is published. The format is - * an 8-character hexadecimal string. - * - * Generated from protobuf field string revision_id = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $revision_id = ''; - /** - * Optional. Labels with user-defined metadata. - * - * Generated from protobuf field map labels = 10 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $labels; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Identifier. The resource name for this - * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] - * in the format `projects/{@*}locations/{@*}caPools/*certificateAuthorities/{@*} - * certificateRevocationLists/*`. - * @type int|string $sequence_number - * Output only. The CRL sequence number that appears in pem_crl. - * @type \Google\Cloud\Security\PrivateCA\V1\CertificateRevocationList\RevokedCertificate[] $revoked_certificates - * Output only. The revoked serial numbers that appear in pem_crl. - * @type string $pem_crl - * Output only. The PEM-encoded X.509 CRL. - * @type string $access_url - * Output only. The location where 'pem_crl' can be accessed. - * @type int $state - * Output only. The - * [State][google.cloud.security.privateca.v1.CertificateRevocationList.State] - * for this - * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList]. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. The time at which this - * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] - * was created. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. The time at which this - * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] - * was updated. - * @type string $revision_id - * Output only. The revision ID of this - * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList]. - * A new revision is committed whenever a new CRL is published. The format is - * an 8-character hexadecimal string. - * @type array|\Google\Protobuf\Internal\MapField $labels - * Optional. Labels with user-defined metadata. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * Identifier. The resource name for this - * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] - * in the format `projects/{@*}locations/{@*}caPools/*certificateAuthorities/{@*} - * certificateRevocationLists/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Identifier. The resource name for this - * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] - * in the format `projects/{@*}locations/{@*}caPools/*certificateAuthorities/{@*} - * certificateRevocationLists/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Output only. The CRL sequence number that appears in pem_crl. - * - * Generated from protobuf field int64 sequence_number = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int|string - */ - public function getSequenceNumber() - { - return $this->sequence_number; - } - - /** - * Output only. The CRL sequence number that appears in pem_crl. - * - * Generated from protobuf field int64 sequence_number = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int|string $var - * @return $this - */ - public function setSequenceNumber($var) - { - GPBUtil::checkInt64($var); - $this->sequence_number = $var; - - return $this; - } - - /** - * Output only. The revoked serial numbers that appear in pem_crl. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CertificateRevocationList.RevokedCertificate revoked_certificates = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return RepeatedField<\Google\Cloud\Security\PrivateCA\V1\CertificateRevocationList\RevokedCertificate> - */ - public function getRevokedCertificates() - { - return $this->revoked_certificates; - } - - /** - * Output only. The revoked serial numbers that appear in pem_crl. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CertificateRevocationList.RevokedCertificate revoked_certificates = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\Security\PrivateCA\V1\CertificateRevocationList\RevokedCertificate[] $var - * @return $this - */ - public function setRevokedCertificates($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Security\PrivateCA\V1\CertificateRevocationList\RevokedCertificate::class); - $this->revoked_certificates = $arr; - - return $this; - } - - /** - * Output only. The PEM-encoded X.509 CRL. - * - * Generated from protobuf field string pem_crl = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getPemCrl() - { - return $this->pem_crl; - } - - /** - * Output only. The PEM-encoded X.509 CRL. - * - * Generated from protobuf field string pem_crl = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setPemCrl($var) - { - GPBUtil::checkString($var, True); - $this->pem_crl = $var; - - return $this; - } - - /** - * Output only. The location where 'pem_crl' can be accessed. - * - * Generated from protobuf field string access_url = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getAccessUrl() - { - return $this->access_url; - } - - /** - * Output only. The location where 'pem_crl' can be accessed. - * - * Generated from protobuf field string access_url = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setAccessUrl($var) - { - GPBUtil::checkString($var, True); - $this->access_url = $var; - - return $this; - } - - /** - * Output only. The - * [State][google.cloud.security.privateca.v1.CertificateRevocationList.State] - * for this - * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList]. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateRevocationList.State state = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Output only. The - * [State][google.cloud.security.privateca.v1.CertificateRevocationList.State] - * for this - * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList]. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateRevocationList.State state = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Security\PrivateCA\V1\CertificateRevocationList\State::class); - $this->state = $var; - - return $this; - } - - /** - * Output only. The time at which this - * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] - * was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 7 [(.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 - * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] - * was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 7 [(.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 - * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] - * was updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 8 [(.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 at which this - * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] - * was updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 8 [(.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 revision ID of this - * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList]. - * A new revision is committed whenever a new CRL is published. The format is - * an 8-character hexadecimal string. - * - * Generated from protobuf field string revision_id = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getRevisionId() - { - return $this->revision_id; - } - - /** - * Output only. The revision ID of this - * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList]. - * A new revision is committed whenever a new CRL is published. The format is - * an 8-character hexadecimal string. - * - * Generated from protobuf field string revision_id = 9 [(.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; - } - - /** - * Optional. Labels with user-defined metadata. - * - * Generated from protobuf field map labels = 10 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Optional. Labels with user-defined metadata. - * - * Generated from protobuf field map labels = 10 [(.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; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateRevocationList/RevokedCertificate.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateRevocationList/RevokedCertificate.php deleted file mode 100644 index 4a20ce5962e2..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateRevocationList/RevokedCertificate.php +++ /dev/null @@ -1,156 +0,0 @@ -google.cloud.security.privateca.v1.CertificateRevocationList.RevokedCertificate - */ -class RevokedCertificate extends \Google\Protobuf\Internal\Message -{ - /** - * The resource name for the - * [Certificate][google.cloud.security.privateca.v1.Certificate] in the - * format `projects/{@*}locations/{@*}caPools/{@*}certificates/*`. - * - * Generated from protobuf field string certificate = 1 [(.google.api.resource_reference) = { - */ - protected $certificate = ''; - /** - * The serial number of the - * [Certificate][google.cloud.security.privateca.v1.Certificate]. - * - * Generated from protobuf field string hex_serial_number = 2; - */ - protected $hex_serial_number = ''; - /** - * The reason the - * [Certificate][google.cloud.security.privateca.v1.Certificate] was - * revoked. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.RevocationReason revocation_reason = 3; - */ - protected $revocation_reason = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $certificate - * The resource name for the - * [Certificate][google.cloud.security.privateca.v1.Certificate] in the - * format `projects/{@*}locations/{@*}caPools/{@*}certificates/*`. - * @type string $hex_serial_number - * The serial number of the - * [Certificate][google.cloud.security.privateca.v1.Certificate]. - * @type int $revocation_reason - * The reason the - * [Certificate][google.cloud.security.privateca.v1.Certificate] was - * revoked. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * The resource name for the - * [Certificate][google.cloud.security.privateca.v1.Certificate] in the - * format `projects/{@*}locations/{@*}caPools/{@*}certificates/*`. - * - * Generated from protobuf field string certificate = 1 [(.google.api.resource_reference) = { - * @return string - */ - public function getCertificate() - { - return $this->certificate; - } - - /** - * The resource name for the - * [Certificate][google.cloud.security.privateca.v1.Certificate] in the - * format `projects/{@*}locations/{@*}caPools/{@*}certificates/*`. - * - * Generated from protobuf field string certificate = 1 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setCertificate($var) - { - GPBUtil::checkString($var, True); - $this->certificate = $var; - - return $this; - } - - /** - * The serial number of the - * [Certificate][google.cloud.security.privateca.v1.Certificate]. - * - * Generated from protobuf field string hex_serial_number = 2; - * @return string - */ - public function getHexSerialNumber() - { - return $this->hex_serial_number; - } - - /** - * The serial number of the - * [Certificate][google.cloud.security.privateca.v1.Certificate]. - * - * Generated from protobuf field string hex_serial_number = 2; - * @param string $var - * @return $this - */ - public function setHexSerialNumber($var) - { - GPBUtil::checkString($var, True); - $this->hex_serial_number = $var; - - return $this; - } - - /** - * The reason the - * [Certificate][google.cloud.security.privateca.v1.Certificate] was - * revoked. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.RevocationReason revocation_reason = 3; - * @return int - */ - public function getRevocationReason() - { - return $this->revocation_reason; - } - - /** - * The reason the - * [Certificate][google.cloud.security.privateca.v1.Certificate] was - * revoked. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.RevocationReason revocation_reason = 3; - * @param int $var - * @return $this - */ - public function setRevocationReason($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Security\PrivateCA\V1\RevocationReason::class); - $this->revocation_reason = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateRevocationList/State.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateRevocationList/State.php deleted file mode 100644 index f2b08643e5bf..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateRevocationList/State.php +++ /dev/null @@ -1,67 +0,0 @@ -google.cloud.security.privateca.v1.CertificateRevocationList.State - */ -class State -{ - /** - * Not specified. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * The - * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] - * is up to date. - * - * Generated from protobuf enum ACTIVE = 1; - */ - const ACTIVE = 1; - /** - * The - * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] - * is no longer current. - * - * Generated from protobuf enum SUPERSEDED = 2; - */ - const SUPERSEDED = 2; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::ACTIVE => 'ACTIVE', - self::SUPERSEDED => 'SUPERSEDED', - ]; - - 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateTemplate.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateTemplate.php deleted file mode 100644 index 168c0bcad1ef..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CertificateTemplate.php +++ /dev/null @@ -1,593 +0,0 @@ -google.cloud.security.privateca.v1.CertificateTemplate - */ -class CertificateTemplate extends \Google\Protobuf\Internal\Message -{ - /** - * Identifier. The resource name for this - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * in the format `projects/{@*}locations/{@*}certificateTemplates/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; - */ - protected $name = ''; - /** - * Optional. The maximum lifetime allowed for issued - * [Certificates][google.cloud.security.privateca.v1.Certificate] that use - * this template. If the issuing - * [CaPool][google.cloud.security.privateca.v1.CaPool] resource's - * [IssuancePolicy][google.cloud.security.privateca.v1.CaPool.IssuancePolicy] - * specifies a - * [maximum_lifetime][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.maximum_lifetime] - * the minimum of the two durations will be the maximum lifetime for issued - * [Certificates][google.cloud.security.privateca.v1.Certificate]. Note that - * if the issuing - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * expires before a - * [Certificate][google.cloud.security.privateca.v1.Certificate]'s requested - * maximum_lifetime, the effective lifetime will be explicitly truncated - * to match it. - * - * Generated from protobuf field .google.protobuf.Duration maximum_lifetime = 9 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $maximum_lifetime = null; - /** - * Optional. A set of X.509 values that will be applied to all issued - * certificates that use this template. If the certificate request includes - * conflicting values for the same properties, they will be overwritten by the - * values defined here. If the issuing - * [CaPool][google.cloud.security.privateca.v1.CaPool]'s - * [IssuancePolicy][google.cloud.security.privateca.v1.CaPool.IssuancePolicy] - * defines conflicting - * [baseline_values][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.baseline_values] - * for the same properties, the certificate issuance request will fail. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.X509Parameters predefined_values = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $predefined_values = null; - /** - * Optional. Describes constraints on identities that may be appear in - * [Certificates][google.cloud.security.privateca.v1.Certificate] issued using - * this template. If this is omitted, then this template will not add - * restrictions on a certificate's identity. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateIdentityConstraints identity_constraints = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $identity_constraints = null; - /** - * Optional. Describes the set of X.509 extensions that may appear in a - * [Certificate][google.cloud.security.privateca.v1.Certificate] issued using - * this - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate]. - * If a certificate request sets extensions that don't appear in the - * [passthrough_extensions][google.cloud.security.privateca.v1.CertificateTemplate.passthrough_extensions], - * those extensions will be dropped. If the issuing - * [CaPool][google.cloud.security.privateca.v1.CaPool]'s - * [IssuancePolicy][google.cloud.security.privateca.v1.CaPool.IssuancePolicy] - * defines - * [baseline_values][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.baseline_values] - * that don't appear here, the certificate issuance request will fail. If this - * is omitted, then this template will not add restrictions on a certificate's - * X.509 extensions. These constraints do not apply to X.509 extensions set in - * this - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate]'s - * [predefined_values][google.cloud.security.privateca.v1.CertificateTemplate.predefined_values]. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateExtensionConstraints passthrough_extensions = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $passthrough_extensions = null; - /** - * Optional. A human-readable description of scenarios this template is - * intended for. - * - * Generated from protobuf field string description = 5 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $description = ''; - /** - * Output only. The time at which this - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * was created. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The time at which this - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * was updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Optional. Labels with user-defined metadata. - * - * Generated from protobuf field map labels = 8 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $labels; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Identifier. The resource name for this - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * in the format `projects/{@*}locations/{@*}certificateTemplates/*`. - * @type \Google\Protobuf\Duration $maximum_lifetime - * Optional. The maximum lifetime allowed for issued - * [Certificates][google.cloud.security.privateca.v1.Certificate] that use - * this template. If the issuing - * [CaPool][google.cloud.security.privateca.v1.CaPool] resource's - * [IssuancePolicy][google.cloud.security.privateca.v1.CaPool.IssuancePolicy] - * specifies a - * [maximum_lifetime][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.maximum_lifetime] - * the minimum of the two durations will be the maximum lifetime for issued - * [Certificates][google.cloud.security.privateca.v1.Certificate]. Note that - * if the issuing - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * expires before a - * [Certificate][google.cloud.security.privateca.v1.Certificate]'s requested - * maximum_lifetime, the effective lifetime will be explicitly truncated - * to match it. - * @type \Google\Cloud\Security\PrivateCA\V1\X509Parameters $predefined_values - * Optional. A set of X.509 values that will be applied to all issued - * certificates that use this template. If the certificate request includes - * conflicting values for the same properties, they will be overwritten by the - * values defined here. If the issuing - * [CaPool][google.cloud.security.privateca.v1.CaPool]'s - * [IssuancePolicy][google.cloud.security.privateca.v1.CaPool.IssuancePolicy] - * defines conflicting - * [baseline_values][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.baseline_values] - * for the same properties, the certificate issuance request will fail. - * @type \Google\Cloud\Security\PrivateCA\V1\CertificateIdentityConstraints $identity_constraints - * Optional. Describes constraints on identities that may be appear in - * [Certificates][google.cloud.security.privateca.v1.Certificate] issued using - * this template. If this is omitted, then this template will not add - * restrictions on a certificate's identity. - * @type \Google\Cloud\Security\PrivateCA\V1\CertificateExtensionConstraints $passthrough_extensions - * Optional. Describes the set of X.509 extensions that may appear in a - * [Certificate][google.cloud.security.privateca.v1.Certificate] issued using - * this - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate]. - * If a certificate request sets extensions that don't appear in the - * [passthrough_extensions][google.cloud.security.privateca.v1.CertificateTemplate.passthrough_extensions], - * those extensions will be dropped. If the issuing - * [CaPool][google.cloud.security.privateca.v1.CaPool]'s - * [IssuancePolicy][google.cloud.security.privateca.v1.CaPool.IssuancePolicy] - * defines - * [baseline_values][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.baseline_values] - * that don't appear here, the certificate issuance request will fail. If this - * is omitted, then this template will not add restrictions on a certificate's - * X.509 extensions. These constraints do not apply to X.509 extensions set in - * this - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate]'s - * [predefined_values][google.cloud.security.privateca.v1.CertificateTemplate.predefined_values]. - * @type string $description - * Optional. A human-readable description of scenarios this template is - * intended for. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. The time at which this - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * was created. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. The time at which this - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * was updated. - * @type array|\Google\Protobuf\Internal\MapField $labels - * Optional. Labels with user-defined metadata. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * Identifier. The resource name for this - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * in the format `projects/{@*}locations/{@*}certificateTemplates/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Identifier. The resource name for this - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * in the format `projects/{@*}locations/{@*}certificateTemplates/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Optional. The maximum lifetime allowed for issued - * [Certificates][google.cloud.security.privateca.v1.Certificate] that use - * this template. If the issuing - * [CaPool][google.cloud.security.privateca.v1.CaPool] resource's - * [IssuancePolicy][google.cloud.security.privateca.v1.CaPool.IssuancePolicy] - * specifies a - * [maximum_lifetime][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.maximum_lifetime] - * the minimum of the two durations will be the maximum lifetime for issued - * [Certificates][google.cloud.security.privateca.v1.Certificate]. Note that - * if the issuing - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * expires before a - * [Certificate][google.cloud.security.privateca.v1.Certificate]'s requested - * maximum_lifetime, the effective lifetime will be explicitly truncated - * to match it. - * - * Generated from protobuf field .google.protobuf.Duration maximum_lifetime = 9 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Duration|null - */ - public function getMaximumLifetime() - { - return $this->maximum_lifetime; - } - - public function hasMaximumLifetime() - { - return isset($this->maximum_lifetime); - } - - public function clearMaximumLifetime() - { - unset($this->maximum_lifetime); - } - - /** - * Optional. The maximum lifetime allowed for issued - * [Certificates][google.cloud.security.privateca.v1.Certificate] that use - * this template. If the issuing - * [CaPool][google.cloud.security.privateca.v1.CaPool] resource's - * [IssuancePolicy][google.cloud.security.privateca.v1.CaPool.IssuancePolicy] - * specifies a - * [maximum_lifetime][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.maximum_lifetime] - * the minimum of the two durations will be the maximum lifetime for issued - * [Certificates][google.cloud.security.privateca.v1.Certificate]. Note that - * if the issuing - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * expires before a - * [Certificate][google.cloud.security.privateca.v1.Certificate]'s requested - * maximum_lifetime, the effective lifetime will be explicitly truncated - * to match it. - * - * Generated from protobuf field .google.protobuf.Duration maximum_lifetime = 9 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setMaximumLifetime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->maximum_lifetime = $var; - - return $this; - } - - /** - * Optional. A set of X.509 values that will be applied to all issued - * certificates that use this template. If the certificate request includes - * conflicting values for the same properties, they will be overwritten by the - * values defined here. If the issuing - * [CaPool][google.cloud.security.privateca.v1.CaPool]'s - * [IssuancePolicy][google.cloud.security.privateca.v1.CaPool.IssuancePolicy] - * defines conflicting - * [baseline_values][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.baseline_values] - * for the same properties, the certificate issuance request will fail. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.X509Parameters predefined_values = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\Security\PrivateCA\V1\X509Parameters|null - */ - public function getPredefinedValues() - { - return $this->predefined_values; - } - - public function hasPredefinedValues() - { - return isset($this->predefined_values); - } - - public function clearPredefinedValues() - { - unset($this->predefined_values); - } - - /** - * Optional. A set of X.509 values that will be applied to all issued - * certificates that use this template. If the certificate request includes - * conflicting values for the same properties, they will be overwritten by the - * values defined here. If the issuing - * [CaPool][google.cloud.security.privateca.v1.CaPool]'s - * [IssuancePolicy][google.cloud.security.privateca.v1.CaPool.IssuancePolicy] - * defines conflicting - * [baseline_values][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.baseline_values] - * for the same properties, the certificate issuance request will fail. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.X509Parameters predefined_values = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\Security\PrivateCA\V1\X509Parameters $var - * @return $this - */ - public function setPredefinedValues($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\X509Parameters::class); - $this->predefined_values = $var; - - return $this; - } - - /** - * Optional. Describes constraints on identities that may be appear in - * [Certificates][google.cloud.security.privateca.v1.Certificate] issued using - * this template. If this is omitted, then this template will not add - * restrictions on a certificate's identity. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateIdentityConstraints identity_constraints = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\Security\PrivateCA\V1\CertificateIdentityConstraints|null - */ - public function getIdentityConstraints() - { - return $this->identity_constraints; - } - - public function hasIdentityConstraints() - { - return isset($this->identity_constraints); - } - - public function clearIdentityConstraints() - { - unset($this->identity_constraints); - } - - /** - * Optional. Describes constraints on identities that may be appear in - * [Certificates][google.cloud.security.privateca.v1.Certificate] issued using - * this template. If this is omitted, then this template will not add - * restrictions on a certificate's identity. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateIdentityConstraints identity_constraints = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\Security\PrivateCA\V1\CertificateIdentityConstraints $var - * @return $this - */ - public function setIdentityConstraints($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CertificateIdentityConstraints::class); - $this->identity_constraints = $var; - - return $this; - } - - /** - * Optional. Describes the set of X.509 extensions that may appear in a - * [Certificate][google.cloud.security.privateca.v1.Certificate] issued using - * this - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate]. - * If a certificate request sets extensions that don't appear in the - * [passthrough_extensions][google.cloud.security.privateca.v1.CertificateTemplate.passthrough_extensions], - * those extensions will be dropped. If the issuing - * [CaPool][google.cloud.security.privateca.v1.CaPool]'s - * [IssuancePolicy][google.cloud.security.privateca.v1.CaPool.IssuancePolicy] - * defines - * [baseline_values][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.baseline_values] - * that don't appear here, the certificate issuance request will fail. If this - * is omitted, then this template will not add restrictions on a certificate's - * X.509 extensions. These constraints do not apply to X.509 extensions set in - * this - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate]'s - * [predefined_values][google.cloud.security.privateca.v1.CertificateTemplate.predefined_values]. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateExtensionConstraints passthrough_extensions = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\Security\PrivateCA\V1\CertificateExtensionConstraints|null - */ - public function getPassthroughExtensions() - { - return $this->passthrough_extensions; - } - - public function hasPassthroughExtensions() - { - return isset($this->passthrough_extensions); - } - - public function clearPassthroughExtensions() - { - unset($this->passthrough_extensions); - } - - /** - * Optional. Describes the set of X.509 extensions that may appear in a - * [Certificate][google.cloud.security.privateca.v1.Certificate] issued using - * this - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate]. - * If a certificate request sets extensions that don't appear in the - * [passthrough_extensions][google.cloud.security.privateca.v1.CertificateTemplate.passthrough_extensions], - * those extensions will be dropped. If the issuing - * [CaPool][google.cloud.security.privateca.v1.CaPool]'s - * [IssuancePolicy][google.cloud.security.privateca.v1.CaPool.IssuancePolicy] - * defines - * [baseline_values][google.cloud.security.privateca.v1.CaPool.IssuancePolicy.baseline_values] - * that don't appear here, the certificate issuance request will fail. If this - * is omitted, then this template will not add restrictions on a certificate's - * X.509 extensions. These constraints do not apply to X.509 extensions set in - * this - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate]'s - * [predefined_values][google.cloud.security.privateca.v1.CertificateTemplate.predefined_values]. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateExtensionConstraints passthrough_extensions = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\Security\PrivateCA\V1\CertificateExtensionConstraints $var - * @return $this - */ - public function setPassthroughExtensions($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CertificateExtensionConstraints::class); - $this->passthrough_extensions = $var; - - return $this; - } - - /** - * Optional. A human-readable description of scenarios this template is - * intended for. - * - * Generated from protobuf field string description = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * Optional. A human-readable description of scenarios this template is - * intended for. - * - * Generated from protobuf field string description = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * Output only. The time at which this - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * was created. - * - * 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. The time at which this - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * was created. - * - * 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. The time at which this - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * was updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 7 [(.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 at which this - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * was updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 7 [(.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. Labels with user-defined metadata. - * - * Generated from protobuf field map labels = 8 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Optional. Labels with user-defined metadata. - * - * Generated from protobuf field map labels = 8 [(.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; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CreateCaPoolRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CreateCaPoolRequest.php deleted file mode 100644 index 977761d36040..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CreateCaPoolRequest.php +++ /dev/null @@ -1,258 +0,0 @@ -google.cloud.security.privateca.v1.CreateCaPoolRequest - */ -class CreateCaPoolRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the location associated with the - * [CaPool][google.cloud.security.privateca.v1.CaPool], in the format - * `projects/{@*}locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. It must be unique within a location and match the regular - * expression `[a-zA-Z0-9_-]{1,63}` - * - * Generated from protobuf field string ca_pool_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $ca_pool_id = ''; - /** - * Required. A [CaPool][google.cloud.security.privateca.v1.CaPool] with - * initial field values. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool ca_pool = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $ca_pool = null; - /** - * Optional. An 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, (.google.api.field_info) = { - */ - protected $request_id = ''; - - /** - * @param string $parent Required. The resource name of the location associated with the - * [CaPool][google.cloud.security.privateca.v1.CaPool], in the format - * `projects/*/locations/*`. Please see - * {@see CertificateAuthorityServiceClient::locationName()} for help formatting this field. - * @param \Google\Cloud\Security\PrivateCA\V1\CaPool $caPool Required. A [CaPool][google.cloud.security.privateca.v1.CaPool] with - * initial field values. - * @param string $caPoolId Required. It must be unique within a location and match the regular - * expression `[a-zA-Z0-9_-]{1,63}` - * - * @return \Google\Cloud\Security\PrivateCA\V1\CreateCaPoolRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\Security\PrivateCA\V1\CaPool $caPool, string $caPoolId): self - { - return (new self()) - ->setParent($parent) - ->setCaPool($caPool) - ->setCaPoolId($caPoolId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The resource name of the location associated with the - * [CaPool][google.cloud.security.privateca.v1.CaPool], in the format - * `projects/{@*}locations/*`. - * @type string $ca_pool_id - * Required. It must be unique within a location and match the regular - * expression `[a-zA-Z0-9_-]{1,63}` - * @type \Google\Cloud\Security\PrivateCA\V1\CaPool $ca_pool - * Required. A [CaPool][google.cloud.security.privateca.v1.CaPool] with - * initial field values. - * @type string $request_id - * Optional. An 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\Security\Privateca\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the location associated with the - * [CaPool][google.cloud.security.privateca.v1.CaPool], 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 associated with the - * [CaPool][google.cloud.security.privateca.v1.CaPool], 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. It must be unique within a location and match the regular - * expression `[a-zA-Z0-9_-]{1,63}` - * - * Generated from protobuf field string ca_pool_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getCaPoolId() - { - return $this->ca_pool_id; - } - - /** - * Required. It must be unique within a location and match the regular - * expression `[a-zA-Z0-9_-]{1,63}` - * - * Generated from protobuf field string ca_pool_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setCaPoolId($var) - { - GPBUtil::checkString($var, True); - $this->ca_pool_id = $var; - - return $this; - } - - /** - * Required. A [CaPool][google.cloud.security.privateca.v1.CaPool] with - * initial field values. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool ca_pool = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Security\PrivateCA\V1\CaPool|null - */ - public function getCaPool() - { - return $this->ca_pool; - } - - public function hasCaPool() - { - return isset($this->ca_pool); - } - - public function clearCaPool() - { - unset($this->ca_pool); - } - - /** - * Required. A [CaPool][google.cloud.security.privateca.v1.CaPool] with - * initial field values. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool ca_pool = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Security\PrivateCA\V1\CaPool $var - * @return $this - */ - public function setCaPool($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CaPool::class); - $this->ca_pool = $var; - - return $this; - } - - /** - * Optional. An 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, (.google.api.field_info) = { - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. An 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, (.google.api.field_info) = { - * @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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CreateCertificateAuthorityRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CreateCertificateAuthorityRequest.php deleted file mode 100644 index d8a521c6e17b..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CreateCertificateAuthorityRequest.php +++ /dev/null @@ -1,268 +0,0 @@ -google.cloud.security.privateca.v1.CreateCertificateAuthorityRequest - */ -class CreateCertificateAuthorityRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the - * [CaPool][google.cloud.security.privateca.v1.CaPool] associated with the - * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority], - * in the format `projects/{@*}locations/{@*}caPools/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. It must be unique within a location and match the regular - * expression `[a-zA-Z0-9_-]{1,63}` - * - * Generated from protobuf field string certificate_authority_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $certificate_authority_id = ''; - /** - * Required. A - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * with initial field values. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority certificate_authority = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $certificate_authority = null; - /** - * Optional. An 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 resource name of the - * [CaPool][google.cloud.security.privateca.v1.CaPool] associated with the - * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority], - * in the format `projects/*/locations/*/caPools/*`. Please see - * {@see CertificateAuthorityServiceClient::caPoolName()} for help formatting this field. - * @param \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority $certificateAuthority Required. A - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * with initial field values. - * @param string $certificateAuthorityId Required. It must be unique within a location and match the regular - * expression `[a-zA-Z0-9_-]{1,63}` - * - * @return \Google\Cloud\Security\PrivateCA\V1\CreateCertificateAuthorityRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority $certificateAuthority, string $certificateAuthorityId): self - { - return (new self()) - ->setParent($parent) - ->setCertificateAuthority($certificateAuthority) - ->setCertificateAuthorityId($certificateAuthorityId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The resource name of the - * [CaPool][google.cloud.security.privateca.v1.CaPool] associated with the - * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority], - * in the format `projects/{@*}locations/{@*}caPools/*`. - * @type string $certificate_authority_id - * Required. It must be unique within a location and match the regular - * expression `[a-zA-Z0-9_-]{1,63}` - * @type \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority $certificate_authority - * Required. A - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * with initial field values. - * @type string $request_id - * Optional. An 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\Security\Privateca\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the - * [CaPool][google.cloud.security.privateca.v1.CaPool] associated with the - * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority], - * in the format `projects/{@*}locations/{@*}caPools/*`. - * - * 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 - * [CaPool][google.cloud.security.privateca.v1.CaPool] associated with the - * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority], - * in the format `projects/{@*}locations/{@*}caPools/*`. - * - * 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. It must be unique within a location and match the regular - * expression `[a-zA-Z0-9_-]{1,63}` - * - * Generated from protobuf field string certificate_authority_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getCertificateAuthorityId() - { - return $this->certificate_authority_id; - } - - /** - * Required. It must be unique within a location and match the regular - * expression `[a-zA-Z0-9_-]{1,63}` - * - * Generated from protobuf field string certificate_authority_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setCertificateAuthorityId($var) - { - GPBUtil::checkString($var, True); - $this->certificate_authority_id = $var; - - return $this; - } - - /** - * Required. A - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * with initial field values. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority certificate_authority = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority|null - */ - public function getCertificateAuthority() - { - return $this->certificate_authority; - } - - public function hasCertificateAuthority() - { - return isset($this->certificate_authority); - } - - public function clearCertificateAuthority() - { - unset($this->certificate_authority); - } - - /** - * Required. A - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * with initial field values. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority certificate_authority = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority $var - * @return $this - */ - public function setCertificateAuthority($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority::class); - $this->certificate_authority = $var; - - return $this; - } - - /** - * Optional. An 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 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CreateCertificateRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CreateCertificateRequest.php deleted file mode 100644 index 52cedd280c8a..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CreateCertificateRequest.php +++ /dev/null @@ -1,451 +0,0 @@ -google.cloud.security.privateca.v1.CreateCertificateRequest - */ -class CreateCertificateRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the - * [CaPool][google.cloud.security.privateca.v1.CaPool] associated with the - * [Certificate][google.cloud.security.privateca.v1.Certificate], in the - * format `projects/{@*}locations/{@*}caPools/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Optional. It must be unique within a location and match the regular - * expression `[a-zA-Z0-9_-]{1,63}`. This field is required when using a - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the Enterprise - * [CertificateAuthority.tier][google.cloud.security.privateca.v1.CertificateAuthority.tier], - * but is optional and its value is ignored otherwise. - * - * Generated from protobuf field string certificate_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $certificate_id = ''; - /** - * Required. A [Certificate][google.cloud.security.privateca.v1.Certificate] - * with initial field values. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.Certificate certificate = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $certificate = null; - /** - * Optional. An 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 = ''; - /** - * Optional. If this is true, no - * [Certificate][google.cloud.security.privateca.v1.Certificate] resource will - * be persisted regardless of the - * [CaPool][google.cloud.security.privateca.v1.CaPool]'s - * [tier][google.cloud.security.privateca.v1.CaPool.tier], and the returned - * [Certificate][google.cloud.security.privateca.v1.Certificate] will not - * contain the - * [pem_certificate][google.cloud.security.privateca.v1.Certificate.pem_certificate] - * field. - * - * Generated from protobuf field bool validate_only = 5 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $validate_only = false; - /** - * Optional. The resource ID of the - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * that should issue the certificate. This optional field will ignore the - * load-balancing scheme of the Pool and directly issue the certificate from - * the CA with the specified ID, contained in the same - * [CaPool][google.cloud.security.privateca.v1.CaPool] referenced by `parent`. - * Per-CA quota rules apply. If left empty, a - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * will be chosen from the [CaPool][google.cloud.security.privateca.v1.CaPool] - * by the service. For example, to issue a - * [Certificate][google.cloud.security.privateca.v1.Certificate] from a - * Certificate Authority with resource name - * "projects/my-project/locations/us-central1/caPools/my-pool/certificateAuthorities/my-ca", - * you can set the - * [parent][google.cloud.security.privateca.v1.CreateCertificateRequest.parent] - * to "projects/my-project/locations/us-central1/caPools/my-pool" and the - * [issuing_certificate_authority_id][google.cloud.security.privateca.v1.CreateCertificateRequest.issuing_certificate_authority_id] - * to "my-ca". - * - * Generated from protobuf field string issuing_certificate_authority_id = 6 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $issuing_certificate_authority_id = ''; - - /** - * @param string $parent Required. The resource name of the - * [CaPool][google.cloud.security.privateca.v1.CaPool] associated with the - * [Certificate][google.cloud.security.privateca.v1.Certificate], in the - * format `projects/*/locations/*/caPools/*`. Please see - * {@see CertificateAuthorityServiceClient::caPoolName()} for help formatting this field. - * @param \Google\Cloud\Security\PrivateCA\V1\Certificate $certificate Required. A [Certificate][google.cloud.security.privateca.v1.Certificate] - * with initial field values. - * @param string $certificateId Optional. It must be unique within a location and match the regular - * expression `[a-zA-Z0-9_-]{1,63}`. This field is required when using a - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the Enterprise - * [CertificateAuthority.tier][google.cloud.security.privateca.v1.CertificateAuthority.tier], - * but is optional and its value is ignored otherwise. - * - * @return \Google\Cloud\Security\PrivateCA\V1\CreateCertificateRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\Security\PrivateCA\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 resource name of the - * [CaPool][google.cloud.security.privateca.v1.CaPool] associated with the - * [Certificate][google.cloud.security.privateca.v1.Certificate], in the - * format `projects/{@*}locations/{@*}caPools/*`. - * @type string $certificate_id - * Optional. It must be unique within a location and match the regular - * expression `[a-zA-Z0-9_-]{1,63}`. This field is required when using a - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the Enterprise - * [CertificateAuthority.tier][google.cloud.security.privateca.v1.CertificateAuthority.tier], - * but is optional and its value is ignored otherwise. - * @type \Google\Cloud\Security\PrivateCA\V1\Certificate $certificate - * Required. A [Certificate][google.cloud.security.privateca.v1.Certificate] - * with initial field values. - * @type string $request_id - * Optional. An 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 bool $validate_only - * Optional. If this is true, no - * [Certificate][google.cloud.security.privateca.v1.Certificate] resource will - * be persisted regardless of the - * [CaPool][google.cloud.security.privateca.v1.CaPool]'s - * [tier][google.cloud.security.privateca.v1.CaPool.tier], and the returned - * [Certificate][google.cloud.security.privateca.v1.Certificate] will not - * contain the - * [pem_certificate][google.cloud.security.privateca.v1.Certificate.pem_certificate] - * field. - * @type string $issuing_certificate_authority_id - * Optional. The resource ID of the - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * that should issue the certificate. This optional field will ignore the - * load-balancing scheme of the Pool and directly issue the certificate from - * the CA with the specified ID, contained in the same - * [CaPool][google.cloud.security.privateca.v1.CaPool] referenced by `parent`. - * Per-CA quota rules apply. If left empty, a - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * will be chosen from the [CaPool][google.cloud.security.privateca.v1.CaPool] - * by the service. For example, to issue a - * [Certificate][google.cloud.security.privateca.v1.Certificate] from a - * Certificate Authority with resource name - * "projects/my-project/locations/us-central1/caPools/my-pool/certificateAuthorities/my-ca", - * you can set the - * [parent][google.cloud.security.privateca.v1.CreateCertificateRequest.parent] - * to "projects/my-project/locations/us-central1/caPools/my-pool" and the - * [issuing_certificate_authority_id][google.cloud.security.privateca.v1.CreateCertificateRequest.issuing_certificate_authority_id] - * to "my-ca". - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the - * [CaPool][google.cloud.security.privateca.v1.CaPool] associated with the - * [Certificate][google.cloud.security.privateca.v1.Certificate], in the - * format `projects/{@*}locations/{@*}caPools/*`. - * - * 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 - * [CaPool][google.cloud.security.privateca.v1.CaPool] associated with the - * [Certificate][google.cloud.security.privateca.v1.Certificate], in the - * format `projects/{@*}locations/{@*}caPools/*`. - * - * 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. It must be unique within a location and match the regular - * expression `[a-zA-Z0-9_-]{1,63}`. This field is required when using a - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the Enterprise - * [CertificateAuthority.tier][google.cloud.security.privateca.v1.CertificateAuthority.tier], - * but is optional and its value is ignored otherwise. - * - * Generated from protobuf field string certificate_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getCertificateId() - { - return $this->certificate_id; - } - - /** - * Optional. It must be unique within a location and match the regular - * expression `[a-zA-Z0-9_-]{1,63}`. This field is required when using a - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the Enterprise - * [CertificateAuthority.tier][google.cloud.security.privateca.v1.CertificateAuthority.tier], - * but is optional and its value is ignored otherwise. - * - * Generated from protobuf field string certificate_id = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setCertificateId($var) - { - GPBUtil::checkString($var, True); - $this->certificate_id = $var; - - return $this; - } - - /** - * Required. A [Certificate][google.cloud.security.privateca.v1.Certificate] - * with initial field values. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.Certificate certificate = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Security\PrivateCA\V1\Certificate|null - */ - public function getCertificate() - { - return $this->certificate; - } - - public function hasCertificate() - { - return isset($this->certificate); - } - - public function clearCertificate() - { - unset($this->certificate); - } - - /** - * Required. A [Certificate][google.cloud.security.privateca.v1.Certificate] - * with initial field values. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.Certificate certificate = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Security\PrivateCA\V1\Certificate $var - * @return $this - */ - public function setCertificate($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\Certificate::class); - $this->certificate = $var; - - return $this; - } - - /** - * Optional. An 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 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; - } - - /** - * Optional. If this is true, no - * [Certificate][google.cloud.security.privateca.v1.Certificate] resource will - * be persisted regardless of the - * [CaPool][google.cloud.security.privateca.v1.CaPool]'s - * [tier][google.cloud.security.privateca.v1.CaPool.tier], and the returned - * [Certificate][google.cloud.security.privateca.v1.Certificate] will not - * contain the - * [pem_certificate][google.cloud.security.privateca.v1.Certificate.pem_certificate] - * field. - * - * Generated from protobuf field bool validate_only = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getValidateOnly() - { - return $this->validate_only; - } - - /** - * Optional. If this is true, no - * [Certificate][google.cloud.security.privateca.v1.Certificate] resource will - * be persisted regardless of the - * [CaPool][google.cloud.security.privateca.v1.CaPool]'s - * [tier][google.cloud.security.privateca.v1.CaPool.tier], and the returned - * [Certificate][google.cloud.security.privateca.v1.Certificate] will not - * contain the - * [pem_certificate][google.cloud.security.privateca.v1.Certificate.pem_certificate] - * field. - * - * 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; - } - - /** - * Optional. The resource ID of the - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * that should issue the certificate. This optional field will ignore the - * load-balancing scheme of the Pool and directly issue the certificate from - * the CA with the specified ID, contained in the same - * [CaPool][google.cloud.security.privateca.v1.CaPool] referenced by `parent`. - * Per-CA quota rules apply. If left empty, a - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * will be chosen from the [CaPool][google.cloud.security.privateca.v1.CaPool] - * by the service. For example, to issue a - * [Certificate][google.cloud.security.privateca.v1.Certificate] from a - * Certificate Authority with resource name - * "projects/my-project/locations/us-central1/caPools/my-pool/certificateAuthorities/my-ca", - * you can set the - * [parent][google.cloud.security.privateca.v1.CreateCertificateRequest.parent] - * to "projects/my-project/locations/us-central1/caPools/my-pool" and the - * [issuing_certificate_authority_id][google.cloud.security.privateca.v1.CreateCertificateRequest.issuing_certificate_authority_id] - * to "my-ca". - * - * Generated from protobuf field string issuing_certificate_authority_id = 6 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getIssuingCertificateAuthorityId() - { - return $this->issuing_certificate_authority_id; - } - - /** - * Optional. The resource ID of the - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * that should issue the certificate. This optional field will ignore the - * load-balancing scheme of the Pool and directly issue the certificate from - * the CA with the specified ID, contained in the same - * [CaPool][google.cloud.security.privateca.v1.CaPool] referenced by `parent`. - * Per-CA quota rules apply. If left empty, a - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * will be chosen from the [CaPool][google.cloud.security.privateca.v1.CaPool] - * by the service. For example, to issue a - * [Certificate][google.cloud.security.privateca.v1.Certificate] from a - * Certificate Authority with resource name - * "projects/my-project/locations/us-central1/caPools/my-pool/certificateAuthorities/my-ca", - * you can set the - * [parent][google.cloud.security.privateca.v1.CreateCertificateRequest.parent] - * to "projects/my-project/locations/us-central1/caPools/my-pool" and the - * [issuing_certificate_authority_id][google.cloud.security.privateca.v1.CreateCertificateRequest.issuing_certificate_authority_id] - * to "my-ca". - * - * Generated from protobuf field string issuing_certificate_authority_id = 6 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setIssuingCertificateAuthorityId($var) - { - GPBUtil::checkString($var, True); - $this->issuing_certificate_authority_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CreateCertificateTemplateRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CreateCertificateTemplateRequest.php deleted file mode 100644 index dec2eba9c145..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/CreateCertificateTemplateRequest.php +++ /dev/null @@ -1,263 +0,0 @@ -google.cloud.security.privateca.v1.CreateCertificateTemplateRequest - */ -class CreateCertificateTemplateRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the location associated with the - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate], - * in the format `projects/{@*}locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. It must be unique within a location and match the regular - * expression `[a-zA-Z0-9_-]{1,63}` - * - * Generated from protobuf field string certificate_template_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $certificate_template_id = ''; - /** - * Required. A - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * with initial field values. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateTemplate certificate_template = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $certificate_template = null; - /** - * Optional. An 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, (.google.api.field_info) = { - */ - protected $request_id = ''; - - /** - * @param string $parent Required. The resource name of the location associated with the - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate], - * in the format `projects/*/locations/*`. Please see - * {@see CertificateAuthorityServiceClient::locationName()} for help formatting this field. - * @param \Google\Cloud\Security\PrivateCA\V1\CertificateTemplate $certificateTemplate Required. A - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * with initial field values. - * @param string $certificateTemplateId Required. It must be unique within a location and match the regular - * expression `[a-zA-Z0-9_-]{1,63}` - * - * @return \Google\Cloud\Security\PrivateCA\V1\CreateCertificateTemplateRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\Security\PrivateCA\V1\CertificateTemplate $certificateTemplate, string $certificateTemplateId): self - { - return (new self()) - ->setParent($parent) - ->setCertificateTemplate($certificateTemplate) - ->setCertificateTemplateId($certificateTemplateId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The resource name of the location associated with the - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate], - * in the format `projects/{@*}locations/*`. - * @type string $certificate_template_id - * Required. It must be unique within a location and match the regular - * expression `[a-zA-Z0-9_-]{1,63}` - * @type \Google\Cloud\Security\PrivateCA\V1\CertificateTemplate $certificate_template - * Required. A - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * with initial field values. - * @type string $request_id - * Optional. An 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\Security\Privateca\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the location associated with the - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate], - * 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 associated with the - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate], - * 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. It must be unique within a location and match the regular - * expression `[a-zA-Z0-9_-]{1,63}` - * - * Generated from protobuf field string certificate_template_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getCertificateTemplateId() - { - return $this->certificate_template_id; - } - - /** - * Required. It must be unique within a location and match the regular - * expression `[a-zA-Z0-9_-]{1,63}` - * - * Generated from protobuf field string certificate_template_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setCertificateTemplateId($var) - { - GPBUtil::checkString($var, True); - $this->certificate_template_id = $var; - - return $this; - } - - /** - * Required. A - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * with initial field values. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateTemplate certificate_template = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Security\PrivateCA\V1\CertificateTemplate|null - */ - public function getCertificateTemplate() - { - return $this->certificate_template; - } - - public function hasCertificateTemplate() - { - return isset($this->certificate_template); - } - - public function clearCertificateTemplate() - { - unset($this->certificate_template); - } - - /** - * Required. A - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * with initial field values. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateTemplate certificate_template = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Security\PrivateCA\V1\CertificateTemplate $var - * @return $this - */ - public function setCertificateTemplate($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CertificateTemplate::class); - $this->certificate_template = $var; - - return $this; - } - - /** - * Optional. An 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, (.google.api.field_info) = { - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. An 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, (.google.api.field_info) = { - * @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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/DeleteCaPoolRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/DeleteCaPoolRequest.php deleted file mode 100644 index d8c6a5c64212..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/DeleteCaPoolRequest.php +++ /dev/null @@ -1,212 +0,0 @@ -google.cloud.security.privateca.v1.DeleteCaPoolRequest - */ -class DeleteCaPoolRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name for this - * [CaPool][google.cloud.security.privateca.v1.CaPool] in the format - * `projects/{@*}locations/{@*}caPools/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Optional. An 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { - */ - protected $request_id = ''; - /** - * Optional. This field allows this pool to be deleted even if it's being - * depended on by another resource. However, doing so may result in unintended - * and unrecoverable effects on any dependent resources since the pool will - * no longer be able to issue certificates. - * - * Generated from protobuf field bool ignore_dependent_resources = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $ignore_dependent_resources = false; - - /** - * @param string $name Required. The resource name for this - * [CaPool][google.cloud.security.privateca.v1.CaPool] in the format - * `projects/*/locations/*/caPools/*`. Please see - * {@see CertificateAuthorityServiceClient::caPoolName()} for help formatting this field. - * - * @return \Google\Cloud\Security\PrivateCA\V1\DeleteCaPoolRequest - * - * @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 for this - * [CaPool][google.cloud.security.privateca.v1.CaPool] in the format - * `projects/{@*}locations/{@*}caPools/*`. - * @type string $request_id - * Optional. An 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 bool $ignore_dependent_resources - * Optional. This field allows this pool to be deleted even if it's being - * depended on by another resource. However, doing so may result in unintended - * and unrecoverable effects on any dependent resources since the pool will - * no longer be able to issue certificates. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name for this - * [CaPool][google.cloud.security.privateca.v1.CaPool] in the format - * `projects/{@*}locations/{@*}caPools/*`. - * - * 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 for this - * [CaPool][google.cloud.security.privateca.v1.CaPool] in the format - * `projects/{@*}locations/{@*}caPools/*`. - * - * 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 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. An 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { - * @param string $var - * @return $this - */ - public function setRequestId($var) - { - GPBUtil::checkString($var, True); - $this->request_id = $var; - - return $this; - } - - /** - * Optional. This field allows this pool to be deleted even if it's being - * depended on by another resource. However, doing so may result in unintended - * and unrecoverable effects on any dependent resources since the pool will - * no longer be able to issue certificates. - * - * Generated from protobuf field bool ignore_dependent_resources = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getIgnoreDependentResources() - { - return $this->ignore_dependent_resources; - } - - /** - * Optional. This field allows this pool to be deleted even if it's being - * depended on by another resource. However, doing so may result in unintended - * and unrecoverable effects on any dependent resources since the pool will - * no longer be able to issue certificates. - * - * Generated from protobuf field bool ignore_dependent_resources = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param bool $var - * @return $this - */ - public function setIgnoreDependentResources($var) - { - GPBUtil::checkBool($var); - $this->ignore_dependent_resources = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/DeleteCertificateAuthorityRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/DeleteCertificateAuthorityRequest.php deleted file mode 100644 index 70b330903526..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/DeleteCertificateAuthorityRequest.php +++ /dev/null @@ -1,292 +0,0 @@ -google.cloud.security.privateca.v1.DeleteCertificateAuthorityRequest - */ -class DeleteCertificateAuthorityRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name for this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Optional. An 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { - */ - protected $request_id = ''; - /** - * Optional. This field allows the CA to be deleted even if the CA has - * active certs. Active certs include both unrevoked and unexpired certs. - * - * Generated from protobuf field bool ignore_active_certificates = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $ignore_active_certificates = false; - /** - * Optional. If this flag is set, the Certificate Authority will be deleted as - * soon as possible without a 30-day grace period where undeletion would have - * been allowed. If you proceed, there will be no way to recover this CA. - * - * Generated from protobuf field bool skip_grace_period = 5 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $skip_grace_period = false; - /** - * Optional. This field allows this CA to be deleted even if it's being - * depended on by another resource. However, doing so may result in unintended - * and unrecoverable effects on any dependent resources since the CA will - * no longer be able to issue certificates. - * - * Generated from protobuf field bool ignore_dependent_resources = 6 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $ignore_dependent_resources = false; - - /** - * @param string $name Required. The resource name for this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the format `projects/*/locations/*/caPools/*/certificateAuthorities/*`. Please see - * {@see CertificateAuthorityServiceClient::certificateAuthorityName()} for help formatting this field. - * - * @return \Google\Cloud\Security\PrivateCA\V1\DeleteCertificateAuthorityRequest - * - * @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 for this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. - * @type string $request_id - * Optional. An 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 bool $ignore_active_certificates - * Optional. This field allows the CA to be deleted even if the CA has - * active certs. Active certs include both unrevoked and unexpired certs. - * @type bool $skip_grace_period - * Optional. If this flag is set, the Certificate Authority will be deleted as - * soon as possible without a 30-day grace period where undeletion would have - * been allowed. If you proceed, there will be no way to recover this CA. - * @type bool $ignore_dependent_resources - * Optional. This field allows this CA to be deleted even if it's being - * depended on by another resource. However, doing so may result in unintended - * and unrecoverable effects on any dependent resources since the CA will - * no longer be able to issue certificates. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name for this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. - * - * 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 for this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. - * - * 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 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. An 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { - * @param string $var - * @return $this - */ - public function setRequestId($var) - { - GPBUtil::checkString($var, True); - $this->request_id = $var; - - return $this; - } - - /** - * Optional. This field allows the CA to be deleted even if the CA has - * active certs. Active certs include both unrevoked and unexpired certs. - * - * Generated from protobuf field bool ignore_active_certificates = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getIgnoreActiveCertificates() - { - return $this->ignore_active_certificates; - } - - /** - * Optional. This field allows the CA to be deleted even if the CA has - * active certs. Active certs include both unrevoked and unexpired certs. - * - * Generated from protobuf field bool ignore_active_certificates = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param bool $var - * @return $this - */ - public function setIgnoreActiveCertificates($var) - { - GPBUtil::checkBool($var); - $this->ignore_active_certificates = $var; - - return $this; - } - - /** - * Optional. If this flag is set, the Certificate Authority will be deleted as - * soon as possible without a 30-day grace period where undeletion would have - * been allowed. If you proceed, there will be no way to recover this CA. - * - * Generated from protobuf field bool skip_grace_period = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getSkipGracePeriod() - { - return $this->skip_grace_period; - } - - /** - * Optional. If this flag is set, the Certificate Authority will be deleted as - * soon as possible without a 30-day grace period where undeletion would have - * been allowed. If you proceed, there will be no way to recover this CA. - * - * Generated from protobuf field bool skip_grace_period = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @param bool $var - * @return $this - */ - public function setSkipGracePeriod($var) - { - GPBUtil::checkBool($var); - $this->skip_grace_period = $var; - - return $this; - } - - /** - * Optional. This field allows this CA to be deleted even if it's being - * depended on by another resource. However, doing so may result in unintended - * and unrecoverable effects on any dependent resources since the CA will - * no longer be able to issue certificates. - * - * Generated from protobuf field bool ignore_dependent_resources = 6 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getIgnoreDependentResources() - { - return $this->ignore_dependent_resources; - } - - /** - * Optional. This field allows this CA to be deleted even if it's being - * depended on by another resource. However, doing so may result in unintended - * and unrecoverable effects on any dependent resources since the CA will - * no longer be able to issue certificates. - * - * Generated from protobuf field bool ignore_dependent_resources = 6 [(.google.api.field_behavior) = OPTIONAL]; - * @param bool $var - * @return $this - */ - public function setIgnoreDependentResources($var) - { - GPBUtil::checkBool($var); - $this->ignore_dependent_resources = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/DeleteCertificateTemplateRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/DeleteCertificateTemplateRequest.php deleted file mode 100644 index a4a8c12ce4fe..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/DeleteCertificateTemplateRequest.php +++ /dev/null @@ -1,166 +0,0 @@ -google.cloud.security.privateca.v1.DeleteCertificateTemplateRequest - */ -class DeleteCertificateTemplateRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name for this - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * in the format `projects/{@*}locations/{@*}certificateTemplates/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Optional. An 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { - */ - protected $request_id = ''; - - /** - * @param string $name Required. The resource name for this - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * in the format `projects/*/locations/*/certificateTemplates/*`. Please see - * {@see CertificateAuthorityServiceClient::certificateTemplateName()} for help formatting this field. - * - * @return \Google\Cloud\Security\PrivateCA\V1\DeleteCertificateTemplateRequest - * - * @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 for this - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * in the format `projects/{@*}locations/{@*}certificateTemplates/*`. - * @type string $request_id - * Optional. An 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\Security\Privateca\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name for this - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * in the format `projects/{@*}locations/{@*}certificateTemplates/*`. - * - * 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 for this - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * in the format `projects/{@*}locations/{@*}certificateTemplates/*`. - * - * 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 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. An 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { - * @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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/DisableCertificateAuthorityRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/DisableCertificateAuthorityRequest.php deleted file mode 100644 index 68b4546f5bf0..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/DisableCertificateAuthorityRequest.php +++ /dev/null @@ -1,212 +0,0 @@ -google.cloud.security.privateca.v1.DisableCertificateAuthorityRequest - */ -class DisableCertificateAuthorityRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name for this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Optional. An 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { - */ - protected $request_id = ''; - /** - * Optional. This field allows this CA to be disabled even if it's being - * depended on by another resource. However, doing so may result in unintended - * and unrecoverable effects on any dependent resources since the CA will - * no longer be able to issue certificates. - * - * Generated from protobuf field bool ignore_dependent_resources = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $ignore_dependent_resources = false; - - /** - * @param string $name Required. The resource name for this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the format `projects/*/locations/*/caPools/*/certificateAuthorities/*`. Please see - * {@see CertificateAuthorityServiceClient::certificateAuthorityName()} for help formatting this field. - * - * @return \Google\Cloud\Security\PrivateCA\V1\DisableCertificateAuthorityRequest - * - * @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 for this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. - * @type string $request_id - * Optional. An 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 bool $ignore_dependent_resources - * Optional. This field allows this CA to be disabled even if it's being - * depended on by another resource. However, doing so may result in unintended - * and unrecoverable effects on any dependent resources since the CA will - * no longer be able to issue certificates. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name for this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. - * - * 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 for this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. - * - * 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 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. An 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { - * @param string $var - * @return $this - */ - public function setRequestId($var) - { - GPBUtil::checkString($var, True); - $this->request_id = $var; - - return $this; - } - - /** - * Optional. This field allows this CA to be disabled even if it's being - * depended on by another resource. However, doing so may result in unintended - * and unrecoverable effects on any dependent resources since the CA will - * no longer be able to issue certificates. - * - * Generated from protobuf field bool ignore_dependent_resources = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getIgnoreDependentResources() - { - return $this->ignore_dependent_resources; - } - - /** - * Optional. This field allows this CA to be disabled even if it's being - * depended on by another resource. However, doing so may result in unintended - * and unrecoverable effects on any dependent resources since the CA will - * no longer be able to issue certificates. - * - * Generated from protobuf field bool ignore_dependent_resources = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param bool $var - * @return $this - */ - public function setIgnoreDependentResources($var) - { - GPBUtil::checkBool($var); - $this->ignore_dependent_resources = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/EnableCertificateAuthorityRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/EnableCertificateAuthorityRequest.php deleted file mode 100644 index 6483e3e49371..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/EnableCertificateAuthorityRequest.php +++ /dev/null @@ -1,166 +0,0 @@ -google.cloud.security.privateca.v1.EnableCertificateAuthorityRequest - */ -class EnableCertificateAuthorityRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name for this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Optional. An 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { - */ - protected $request_id = ''; - - /** - * @param string $name Required. The resource name for this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the format `projects/*/locations/*/caPools/*/certificateAuthorities/*`. Please see - * {@see CertificateAuthorityServiceClient::certificateAuthorityName()} for help formatting this field. - * - * @return \Google\Cloud\Security\PrivateCA\V1\EnableCertificateAuthorityRequest - * - * @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 for this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. - * @type string $request_id - * Optional. An 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\Security\Privateca\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name for this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. - * - * 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 for this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. - * - * 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 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. An 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { - * @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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/EncryptionSpec.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/EncryptionSpec.php deleted file mode 100644 index 329f51897689..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/EncryptionSpec.php +++ /dev/null @@ -1,71 +0,0 @@ -google.cloud.security.privateca.v1.EncryptionSpec - */ -class EncryptionSpec extends \Google\Protobuf\Internal\Message -{ - /** - * The resource name for a Cloud KMS key in the format - * `projects/{@*}locations/{@*}keyRings/{@*}cryptoKeys/*`. - * - * Generated from protobuf field string cloud_kms_key = 1; - */ - protected $cloud_kms_key = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $cloud_kms_key - * The resource name for a Cloud KMS key in the format - * `projects/{@*}locations/{@*}keyRings/{@*}cryptoKeys/*`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * The resource name for a Cloud KMS key in the format - * `projects/{@*}locations/{@*}keyRings/{@*}cryptoKeys/*`. - * - * Generated from protobuf field string cloud_kms_key = 1; - * @return string - */ - public function getCloudKmsKey() - { - return $this->cloud_kms_key; - } - - /** - * The resource name for a Cloud KMS key in the format - * `projects/{@*}locations/{@*}keyRings/{@*}cryptoKeys/*`. - * - * Generated from protobuf field string cloud_kms_key = 1; - * @param string $var - * @return $this - */ - public function setCloudKmsKey($var) - { - GPBUtil::checkString($var, True); - $this->cloud_kms_key = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/FetchCaCertsRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/FetchCaCertsRequest.php deleted file mode 100644 index 73a59a0ec28e..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/FetchCaCertsRequest.php +++ /dev/null @@ -1,166 +0,0 @@ -google.cloud.security.privateca.v1.FetchCaCertsRequest - */ -class FetchCaCertsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name for the - * [CaPool][google.cloud.security.privateca.v1.CaPool] in the format - * `projects/{@*}locations/{@*}caPools/*`. - * - * Generated from protobuf field string ca_pool = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $ca_pool = ''; - /** - * Optional. An 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 = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $request_id = ''; - - /** - * @param string $caPool Required. The resource name for the - * [CaPool][google.cloud.security.privateca.v1.CaPool] in the format - * `projects/*/locations/*/caPools/*`. Please see - * {@see CertificateAuthorityServiceClient::caPoolName()} for help formatting this field. - * - * @return \Google\Cloud\Security\PrivateCA\V1\FetchCaCertsRequest - * - * @experimental - */ - public static function build(string $caPool): self - { - return (new self()) - ->setCaPool($caPool); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $ca_pool - * Required. The resource name for the - * [CaPool][google.cloud.security.privateca.v1.CaPool] in the format - * `projects/{@*}locations/{@*}caPools/*`. - * @type string $request_id - * Optional. An 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\Security\Privateca\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name for the - * [CaPool][google.cloud.security.privateca.v1.CaPool] in the format - * `projects/{@*}locations/{@*}caPools/*`. - * - * 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. The resource name for the - * [CaPool][google.cloud.security.privateca.v1.CaPool] in the format - * `projects/{@*}locations/{@*}caPools/*`. - * - * 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; - } - - /** - * Optional. An 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 = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. An 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 = 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; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/FetchCaCertsResponse.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/FetchCaCertsResponse.php deleted file mode 100644 index 58e56752f6d8..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/FetchCaCertsResponse.php +++ /dev/null @@ -1,76 +0,0 @@ -google.cloud.security.privateca.v1.FetchCaCertsResponse - */ -class FetchCaCertsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The PEM encoded CA certificate chains of all certificate authorities in - * this [CaPool][google.cloud.security.privateca.v1.CaPool] in the ENABLED, - * DISABLED, or STAGED states. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.FetchCaCertsResponse.CertChain ca_certs = 1; - */ - private $ca_certs; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Security\PrivateCA\V1\FetchCaCertsResponse\CertChain[] $ca_certs - * The PEM encoded CA certificate chains of all certificate authorities in - * this [CaPool][google.cloud.security.privateca.v1.CaPool] in the ENABLED, - * DISABLED, or STAGED states. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * The PEM encoded CA certificate chains of all certificate authorities in - * this [CaPool][google.cloud.security.privateca.v1.CaPool] in the ENABLED, - * DISABLED, or STAGED states. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.FetchCaCertsResponse.CertChain ca_certs = 1; - * @return RepeatedField<\Google\Cloud\Security\PrivateCA\V1\FetchCaCertsResponse\CertChain> - */ - public function getCaCerts() - { - return $this->ca_certs; - } - - /** - * The PEM encoded CA certificate chains of all certificate authorities in - * this [CaPool][google.cloud.security.privateca.v1.CaPool] in the ENABLED, - * DISABLED, or STAGED states. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.FetchCaCertsResponse.CertChain ca_certs = 1; - * @param \Google\Cloud\Security\PrivateCA\V1\FetchCaCertsResponse\CertChain[] $var - * @return $this - */ - public function setCaCerts($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Security\PrivateCA\V1\FetchCaCertsResponse\CertChain::class); - $this->ca_certs = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/FetchCaCertsResponse/CertChain.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/FetchCaCertsResponse/CertChain.php deleted file mode 100644 index 7575387f2789..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/FetchCaCertsResponse/CertChain.php +++ /dev/null @@ -1,65 +0,0 @@ -google.cloud.security.privateca.v1.FetchCaCertsResponse.CertChain - */ -class CertChain extends \Google\Protobuf\Internal\Message -{ - /** - * The certificates that form the CA chain, from leaf to root order. - * - * Generated from protobuf field repeated string certificates = 1; - */ - private $certificates; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string[] $certificates - * The certificates that form the CA chain, from leaf to root order. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * The certificates that form the CA chain, from leaf to root order. - * - * Generated from protobuf field repeated string certificates = 1; - * @return RepeatedField - */ - public function getCertificates() - { - return $this->certificates; - } - - /** - * The certificates that form the CA chain, from leaf to root order. - * - * Generated from protobuf field repeated string certificates = 1; - * @param string[] $var - * @return $this - */ - public function setCertificates($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->certificates = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/FetchCertificateAuthorityCsrRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/FetchCertificateAuthorityCsrRequest.php deleted file mode 100644 index c682733e7e1a..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/FetchCertificateAuthorityCsrRequest.php +++ /dev/null @@ -1,92 +0,0 @@ -google.cloud.security.privateca.v1.FetchCertificateAuthorityCsrRequest - */ -class FetchCertificateAuthorityCsrRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name for this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. - * - * 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 for this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the format `projects/*/locations/*/caPools/*/certificateAuthorities/*`. Please see - * {@see CertificateAuthorityServiceClient::certificateAuthorityName()} for help formatting this field. - * - * @return \Google\Cloud\Security\PrivateCA\V1\FetchCertificateAuthorityCsrRequest - * - * @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 for this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name for this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. - * - * 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 for this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. - * - * 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/FetchCertificateAuthorityCsrResponse.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/FetchCertificateAuthorityCsrResponse.php deleted file mode 100644 index cb7266b7a61e..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/FetchCertificateAuthorityCsrResponse.php +++ /dev/null @@ -1,68 +0,0 @@ -google.cloud.security.privateca.v1.FetchCertificateAuthorityCsrResponse - */ -class FetchCertificateAuthorityCsrResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The PEM-encoded signed certificate signing request (CSR). - * - * Generated from protobuf field string pem_csr = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $pem_csr = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $pem_csr - * Output only. The PEM-encoded signed certificate signing request (CSR). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The PEM-encoded signed certificate signing request (CSR). - * - * Generated from protobuf field string pem_csr = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getPemCsr() - { - return $this->pem_csr; - } - - /** - * Output only. The PEM-encoded signed certificate signing request (CSR). - * - * Generated from protobuf field string pem_csr = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setPemCsr($var) - { - GPBUtil::checkString($var, True); - $this->pem_csr = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/GetCaPoolRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/GetCaPoolRequest.php deleted file mode 100644 index 97ee1d29b11b..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/GetCaPoolRequest.php +++ /dev/null @@ -1,87 +0,0 @@ -google.cloud.security.privateca.v1.GetCaPoolRequest - */ -class GetCaPoolRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The [name][google.cloud.security.privateca.v1.CaPool.name] of the - * [CaPool][google.cloud.security.privateca.v1.CaPool] 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][google.cloud.security.privateca.v1.CaPool.name] of the - * [CaPool][google.cloud.security.privateca.v1.CaPool] to get. Please see - * {@see CertificateAuthorityServiceClient::caPoolName()} for help formatting this field. - * - * @return \Google\Cloud\Security\PrivateCA\V1\GetCaPoolRequest - * - * @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][google.cloud.security.privateca.v1.CaPool.name] of the - * [CaPool][google.cloud.security.privateca.v1.CaPool] to get. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Required. The [name][google.cloud.security.privateca.v1.CaPool.name] of the - * [CaPool][google.cloud.security.privateca.v1.CaPool] 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][google.cloud.security.privateca.v1.CaPool.name] of the - * [CaPool][google.cloud.security.privateca.v1.CaPool] 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/GetCertificateAuthorityRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/GetCertificateAuthorityRequest.php deleted file mode 100644 index 29ab94d196c6..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/GetCertificateAuthorityRequest.php +++ /dev/null @@ -1,97 +0,0 @@ -google.cloud.security.privateca.v1.GetCertificateAuthorityRequest - */ -class GetCertificateAuthorityRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The - * [name][google.cloud.security.privateca.v1.CertificateAuthority.name] of the - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * 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][google.cloud.security.privateca.v1.CertificateAuthority.name] of the - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * to get. Please see - * {@see CertificateAuthorityServiceClient::certificateAuthorityName()} for help formatting this field. - * - * @return \Google\Cloud\Security\PrivateCA\V1\GetCertificateAuthorityRequest - * - * @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][google.cloud.security.privateca.v1.CertificateAuthority.name] of the - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * to get. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Required. The - * [name][google.cloud.security.privateca.v1.CertificateAuthority.name] of the - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * 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][google.cloud.security.privateca.v1.CertificateAuthority.name] of the - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/GetCertificateRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/GetCertificateRequest.php deleted file mode 100644 index bd0b841c530c..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/GetCertificateRequest.php +++ /dev/null @@ -1,92 +0,0 @@ -google.cloud.security.privateca.v1.GetCertificateRequest - */ -class GetCertificateRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The [name][google.cloud.security.privateca.v1.Certificate.name] - * of the [Certificate][google.cloud.security.privateca.v1.Certificate] 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][google.cloud.security.privateca.v1.Certificate.name] - * of the [Certificate][google.cloud.security.privateca.v1.Certificate] to - * get. Please see - * {@see CertificateAuthorityServiceClient::certificateName()} for help formatting this field. - * - * @return \Google\Cloud\Security\PrivateCA\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. The [name][google.cloud.security.privateca.v1.Certificate.name] - * of the [Certificate][google.cloud.security.privateca.v1.Certificate] to - * get. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Required. The [name][google.cloud.security.privateca.v1.Certificate.name] - * of the [Certificate][google.cloud.security.privateca.v1.Certificate] 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][google.cloud.security.privateca.v1.Certificate.name] - * of the [Certificate][google.cloud.security.privateca.v1.Certificate] 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/GetCertificateRevocationListRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/GetCertificateRevocationListRequest.php deleted file mode 100644 index 2d6bcc851616..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/GetCertificateRevocationListRequest.php +++ /dev/null @@ -1,102 +0,0 @@ -google.cloud.security.privateca.v1.GetCertificateRevocationListRequest - */ -class GetCertificateRevocationListRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The - * [name][google.cloud.security.privateca.v1.CertificateRevocationList.name] - * of the - * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] - * 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][google.cloud.security.privateca.v1.CertificateRevocationList.name] - * of the - * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] - * to get. Please see - * {@see CertificateAuthorityServiceClient::certificateRevocationListName()} for help formatting this field. - * - * @return \Google\Cloud\Security\PrivateCA\V1\GetCertificateRevocationListRequest - * - * @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][google.cloud.security.privateca.v1.CertificateRevocationList.name] - * of the - * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] - * to get. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Required. The - * [name][google.cloud.security.privateca.v1.CertificateRevocationList.name] - * of the - * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] - * 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][google.cloud.security.privateca.v1.CertificateRevocationList.name] - * of the - * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] - * 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/GetCertificateTemplateRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/GetCertificateTemplateRequest.php deleted file mode 100644 index b4214aa905a4..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/GetCertificateTemplateRequest.php +++ /dev/null @@ -1,97 +0,0 @@ -google.cloud.security.privateca.v1.GetCertificateTemplateRequest - */ -class GetCertificateTemplateRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The - * [name][google.cloud.security.privateca.v1.CertificateTemplate.name] of the - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * 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][google.cloud.security.privateca.v1.CertificateTemplate.name] of the - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * to get. Please see - * {@see CertificateAuthorityServiceClient::certificateTemplateName()} for help formatting this field. - * - * @return \Google\Cloud\Security\PrivateCA\V1\GetCertificateTemplateRequest - * - * @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][google.cloud.security.privateca.v1.CertificateTemplate.name] of the - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * to get. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Required. The - * [name][google.cloud.security.privateca.v1.CertificateTemplate.name] of the - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * 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][google.cloud.security.privateca.v1.CertificateTemplate.name] of the - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/KeyUsage.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/KeyUsage.php deleted file mode 100644 index 7f432229f3cc..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/KeyUsage.php +++ /dev/null @@ -1,164 +0,0 @@ -google.cloud.security.privateca.v1.KeyUsage - */ -class KeyUsage extends \Google\Protobuf\Internal\Message -{ - /** - * Describes high-level ways in which a key may be used. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.KeyUsage.KeyUsageOptions base_key_usage = 1; - */ - protected $base_key_usage = null; - /** - * Detailed scenarios in which a key may be used. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.KeyUsage.ExtendedKeyUsageOptions extended_key_usage = 2; - */ - protected $extended_key_usage = null; - /** - * Used to describe extended key usages that are not listed in the - * [KeyUsage.ExtendedKeyUsageOptions][google.cloud.security.privateca.v1.KeyUsage.ExtendedKeyUsageOptions] - * message. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.ObjectId unknown_extended_key_usages = 3; - */ - private $unknown_extended_key_usages; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Security\PrivateCA\V1\KeyUsage\KeyUsageOptions $base_key_usage - * Describes high-level ways in which a key may be used. - * @type \Google\Cloud\Security\PrivateCA\V1\KeyUsage\ExtendedKeyUsageOptions $extended_key_usage - * Detailed scenarios in which a key may be used. - * @type \Google\Cloud\Security\PrivateCA\V1\ObjectId[] $unknown_extended_key_usages - * Used to describe extended key usages that are not listed in the - * [KeyUsage.ExtendedKeyUsageOptions][google.cloud.security.privateca.v1.KeyUsage.ExtendedKeyUsageOptions] - * message. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * Describes high-level ways in which a key may be used. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.KeyUsage.KeyUsageOptions base_key_usage = 1; - * @return \Google\Cloud\Security\PrivateCA\V1\KeyUsage\KeyUsageOptions|null - */ - public function getBaseKeyUsage() - { - return $this->base_key_usage; - } - - public function hasBaseKeyUsage() - { - return isset($this->base_key_usage); - } - - public function clearBaseKeyUsage() - { - unset($this->base_key_usage); - } - - /** - * Describes high-level ways in which a key may be used. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.KeyUsage.KeyUsageOptions base_key_usage = 1; - * @param \Google\Cloud\Security\PrivateCA\V1\KeyUsage\KeyUsageOptions $var - * @return $this - */ - public function setBaseKeyUsage($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\KeyUsage\KeyUsageOptions::class); - $this->base_key_usage = $var; - - return $this; - } - - /** - * Detailed scenarios in which a key may be used. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.KeyUsage.ExtendedKeyUsageOptions extended_key_usage = 2; - * @return \Google\Cloud\Security\PrivateCA\V1\KeyUsage\ExtendedKeyUsageOptions|null - */ - public function getExtendedKeyUsage() - { - return $this->extended_key_usage; - } - - public function hasExtendedKeyUsage() - { - return isset($this->extended_key_usage); - } - - public function clearExtendedKeyUsage() - { - unset($this->extended_key_usage); - } - - /** - * Detailed scenarios in which a key may be used. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.KeyUsage.ExtendedKeyUsageOptions extended_key_usage = 2; - * @param \Google\Cloud\Security\PrivateCA\V1\KeyUsage\ExtendedKeyUsageOptions $var - * @return $this - */ - public function setExtendedKeyUsage($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\KeyUsage\ExtendedKeyUsageOptions::class); - $this->extended_key_usage = $var; - - return $this; - } - - /** - * Used to describe extended key usages that are not listed in the - * [KeyUsage.ExtendedKeyUsageOptions][google.cloud.security.privateca.v1.KeyUsage.ExtendedKeyUsageOptions] - * message. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.ObjectId unknown_extended_key_usages = 3; - * @return RepeatedField<\Google\Cloud\Security\PrivateCA\V1\ObjectId> - */ - public function getUnknownExtendedKeyUsages() - { - return $this->unknown_extended_key_usages; - } - - /** - * Used to describe extended key usages that are not listed in the - * [KeyUsage.ExtendedKeyUsageOptions][google.cloud.security.privateca.v1.KeyUsage.ExtendedKeyUsageOptions] - * message. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.ObjectId unknown_extended_key_usages = 3; - * @param \Google\Cloud\Security\PrivateCA\V1\ObjectId[] $var - * @return $this - */ - public function setUnknownExtendedKeyUsages($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Security\PrivateCA\V1\ObjectId::class); - $this->unknown_extended_key_usages = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/KeyUsage/ExtendedKeyUsageOptions.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/KeyUsage/ExtendedKeyUsageOptions.php deleted file mode 100644 index 112b38358bac..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/KeyUsage/ExtendedKeyUsageOptions.php +++ /dev/null @@ -1,263 +0,0 @@ -google.cloud.security.privateca.v1.KeyUsage.ExtendedKeyUsageOptions - */ -class ExtendedKeyUsageOptions extends \Google\Protobuf\Internal\Message -{ - /** - * Corresponds to OID 1.3.6.1.5.5.7.3.1. Officially described as "TLS WWW - * server authentication", though regularly used for non-WWW TLS. - * - * Generated from protobuf field bool server_auth = 1; - */ - protected $server_auth = false; - /** - * Corresponds to OID 1.3.6.1.5.5.7.3.2. Officially described as "TLS WWW - * client authentication", though regularly used for non-WWW TLS. - * - * Generated from protobuf field bool client_auth = 2; - */ - protected $client_auth = false; - /** - * Corresponds to OID 1.3.6.1.5.5.7.3.3. Officially described as "Signing of - * downloadable executable code client authentication". - * - * Generated from protobuf field bool code_signing = 3; - */ - protected $code_signing = false; - /** - * Corresponds to OID 1.3.6.1.5.5.7.3.4. Officially described as "Email - * protection". - * - * Generated from protobuf field bool email_protection = 4; - */ - protected $email_protection = false; - /** - * Corresponds to OID 1.3.6.1.5.5.7.3.8. Officially described as "Binding - * the hash of an object to a time". - * - * Generated from protobuf field bool time_stamping = 5; - */ - protected $time_stamping = false; - /** - * Corresponds to OID 1.3.6.1.5.5.7.3.9. Officially described as "Signing - * OCSP responses". - * - * Generated from protobuf field bool ocsp_signing = 6; - */ - protected $ocsp_signing = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type bool $server_auth - * Corresponds to OID 1.3.6.1.5.5.7.3.1. Officially described as "TLS WWW - * server authentication", though regularly used for non-WWW TLS. - * @type bool $client_auth - * Corresponds to OID 1.3.6.1.5.5.7.3.2. Officially described as "TLS WWW - * client authentication", though regularly used for non-WWW TLS. - * @type bool $code_signing - * Corresponds to OID 1.3.6.1.5.5.7.3.3. Officially described as "Signing of - * downloadable executable code client authentication". - * @type bool $email_protection - * Corresponds to OID 1.3.6.1.5.5.7.3.4. Officially described as "Email - * protection". - * @type bool $time_stamping - * Corresponds to OID 1.3.6.1.5.5.7.3.8. Officially described as "Binding - * the hash of an object to a time". - * @type bool $ocsp_signing - * Corresponds to OID 1.3.6.1.5.5.7.3.9. Officially described as "Signing - * OCSP responses". - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * Corresponds to OID 1.3.6.1.5.5.7.3.1. Officially described as "TLS WWW - * server authentication", though regularly used for non-WWW TLS. - * - * Generated from protobuf field bool server_auth = 1; - * @return bool - */ - public function getServerAuth() - { - return $this->server_auth; - } - - /** - * Corresponds to OID 1.3.6.1.5.5.7.3.1. Officially described as "TLS WWW - * server authentication", though regularly used for non-WWW TLS. - * - * Generated from protobuf field bool server_auth = 1; - * @param bool $var - * @return $this - */ - public function setServerAuth($var) - { - GPBUtil::checkBool($var); - $this->server_auth = $var; - - return $this; - } - - /** - * Corresponds to OID 1.3.6.1.5.5.7.3.2. Officially described as "TLS WWW - * client authentication", though regularly used for non-WWW TLS. - * - * Generated from protobuf field bool client_auth = 2; - * @return bool - */ - public function getClientAuth() - { - return $this->client_auth; - } - - /** - * Corresponds to OID 1.3.6.1.5.5.7.3.2. Officially described as "TLS WWW - * client authentication", though regularly used for non-WWW TLS. - * - * Generated from protobuf field bool client_auth = 2; - * @param bool $var - * @return $this - */ - public function setClientAuth($var) - { - GPBUtil::checkBool($var); - $this->client_auth = $var; - - return $this; - } - - /** - * Corresponds to OID 1.3.6.1.5.5.7.3.3. Officially described as "Signing of - * downloadable executable code client authentication". - * - * Generated from protobuf field bool code_signing = 3; - * @return bool - */ - public function getCodeSigning() - { - return $this->code_signing; - } - - /** - * Corresponds to OID 1.3.6.1.5.5.7.3.3. Officially described as "Signing of - * downloadable executable code client authentication". - * - * Generated from protobuf field bool code_signing = 3; - * @param bool $var - * @return $this - */ - public function setCodeSigning($var) - { - GPBUtil::checkBool($var); - $this->code_signing = $var; - - return $this; - } - - /** - * Corresponds to OID 1.3.6.1.5.5.7.3.4. Officially described as "Email - * protection". - * - * Generated from protobuf field bool email_protection = 4; - * @return bool - */ - public function getEmailProtection() - { - return $this->email_protection; - } - - /** - * Corresponds to OID 1.3.6.1.5.5.7.3.4. Officially described as "Email - * protection". - * - * Generated from protobuf field bool email_protection = 4; - * @param bool $var - * @return $this - */ - public function setEmailProtection($var) - { - GPBUtil::checkBool($var); - $this->email_protection = $var; - - return $this; - } - - /** - * Corresponds to OID 1.3.6.1.5.5.7.3.8. Officially described as "Binding - * the hash of an object to a time". - * - * Generated from protobuf field bool time_stamping = 5; - * @return bool - */ - public function getTimeStamping() - { - return $this->time_stamping; - } - - /** - * Corresponds to OID 1.3.6.1.5.5.7.3.8. Officially described as "Binding - * the hash of an object to a time". - * - * Generated from protobuf field bool time_stamping = 5; - * @param bool $var - * @return $this - */ - public function setTimeStamping($var) - { - GPBUtil::checkBool($var); - $this->time_stamping = $var; - - return $this; - } - - /** - * Corresponds to OID 1.3.6.1.5.5.7.3.9. Officially described as "Signing - * OCSP responses". - * - * Generated from protobuf field bool ocsp_signing = 6; - * @return bool - */ - public function getOcspSigning() - { - return $this->ocsp_signing; - } - - /** - * Corresponds to OID 1.3.6.1.5.5.7.3.9. Officially described as "Signing - * OCSP responses". - * - * Generated from protobuf field bool ocsp_signing = 6; - * @param bool $var - * @return $this - */ - public function setOcspSigning($var) - { - GPBUtil::checkBool($var); - $this->ocsp_signing = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/KeyUsage/KeyUsageOptions.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/KeyUsage/KeyUsageOptions.php deleted file mode 100644 index 200c9acf6ba0..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/KeyUsage/KeyUsageOptions.php +++ /dev/null @@ -1,345 +0,0 @@ -google.cloud.security.privateca.v1.KeyUsage.KeyUsageOptions - */ -class KeyUsageOptions extends \Google\Protobuf\Internal\Message -{ - /** - * The key may be used for digital signatures. - * - * Generated from protobuf field bool digital_signature = 1; - */ - protected $digital_signature = false; - /** - * The key may be used for cryptographic commitments. Note that this may - * also be referred to as "non-repudiation". - * - * Generated from protobuf field bool content_commitment = 2; - */ - protected $content_commitment = false; - /** - * The key may be used to encipher other keys. - * - * Generated from protobuf field bool key_encipherment = 3; - */ - protected $key_encipherment = false; - /** - * The key may be used to encipher data. - * - * Generated from protobuf field bool data_encipherment = 4; - */ - protected $data_encipherment = false; - /** - * The key may be used in a key agreement protocol. - * - * Generated from protobuf field bool key_agreement = 5; - */ - protected $key_agreement = false; - /** - * The key may be used to sign certificates. - * - * Generated from protobuf field bool cert_sign = 6; - */ - protected $cert_sign = false; - /** - * The key may be used sign certificate revocation lists. - * - * Generated from protobuf field bool crl_sign = 7; - */ - protected $crl_sign = false; - /** - * The key may be used to encipher only. - * - * Generated from protobuf field bool encipher_only = 8; - */ - protected $encipher_only = false; - /** - * The key may be used to decipher only. - * - * Generated from protobuf field bool decipher_only = 9; - */ - protected $decipher_only = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type bool $digital_signature - * The key may be used for digital signatures. - * @type bool $content_commitment - * The key may be used for cryptographic commitments. Note that this may - * also be referred to as "non-repudiation". - * @type bool $key_encipherment - * The key may be used to encipher other keys. - * @type bool $data_encipherment - * The key may be used to encipher data. - * @type bool $key_agreement - * The key may be used in a key agreement protocol. - * @type bool $cert_sign - * The key may be used to sign certificates. - * @type bool $crl_sign - * The key may be used sign certificate revocation lists. - * @type bool $encipher_only - * The key may be used to encipher only. - * @type bool $decipher_only - * The key may be used to decipher only. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * The key may be used for digital signatures. - * - * Generated from protobuf field bool digital_signature = 1; - * @return bool - */ - public function getDigitalSignature() - { - return $this->digital_signature; - } - - /** - * The key may be used for digital signatures. - * - * Generated from protobuf field bool digital_signature = 1; - * @param bool $var - * @return $this - */ - public function setDigitalSignature($var) - { - GPBUtil::checkBool($var); - $this->digital_signature = $var; - - return $this; - } - - /** - * The key may be used for cryptographic commitments. Note that this may - * also be referred to as "non-repudiation". - * - * Generated from protobuf field bool content_commitment = 2; - * @return bool - */ - public function getContentCommitment() - { - return $this->content_commitment; - } - - /** - * The key may be used for cryptographic commitments. Note that this may - * also be referred to as "non-repudiation". - * - * Generated from protobuf field bool content_commitment = 2; - * @param bool $var - * @return $this - */ - public function setContentCommitment($var) - { - GPBUtil::checkBool($var); - $this->content_commitment = $var; - - return $this; - } - - /** - * The key may be used to encipher other keys. - * - * Generated from protobuf field bool key_encipherment = 3; - * @return bool - */ - public function getKeyEncipherment() - { - return $this->key_encipherment; - } - - /** - * The key may be used to encipher other keys. - * - * Generated from protobuf field bool key_encipherment = 3; - * @param bool $var - * @return $this - */ - public function setKeyEncipherment($var) - { - GPBUtil::checkBool($var); - $this->key_encipherment = $var; - - return $this; - } - - /** - * The key may be used to encipher data. - * - * Generated from protobuf field bool data_encipherment = 4; - * @return bool - */ - public function getDataEncipherment() - { - return $this->data_encipherment; - } - - /** - * The key may be used to encipher data. - * - * Generated from protobuf field bool data_encipherment = 4; - * @param bool $var - * @return $this - */ - public function setDataEncipherment($var) - { - GPBUtil::checkBool($var); - $this->data_encipherment = $var; - - return $this; - } - - /** - * The key may be used in a key agreement protocol. - * - * Generated from protobuf field bool key_agreement = 5; - * @return bool - */ - public function getKeyAgreement() - { - return $this->key_agreement; - } - - /** - * The key may be used in a key agreement protocol. - * - * Generated from protobuf field bool key_agreement = 5; - * @param bool $var - * @return $this - */ - public function setKeyAgreement($var) - { - GPBUtil::checkBool($var); - $this->key_agreement = $var; - - return $this; - } - - /** - * The key may be used to sign certificates. - * - * Generated from protobuf field bool cert_sign = 6; - * @return bool - */ - public function getCertSign() - { - return $this->cert_sign; - } - - /** - * The key may be used to sign certificates. - * - * Generated from protobuf field bool cert_sign = 6; - * @param bool $var - * @return $this - */ - public function setCertSign($var) - { - GPBUtil::checkBool($var); - $this->cert_sign = $var; - - return $this; - } - - /** - * The key may be used sign certificate revocation lists. - * - * Generated from protobuf field bool crl_sign = 7; - * @return bool - */ - public function getCrlSign() - { - return $this->crl_sign; - } - - /** - * The key may be used sign certificate revocation lists. - * - * Generated from protobuf field bool crl_sign = 7; - * @param bool $var - * @return $this - */ - public function setCrlSign($var) - { - GPBUtil::checkBool($var); - $this->crl_sign = $var; - - return $this; - } - - /** - * The key may be used to encipher only. - * - * Generated from protobuf field bool encipher_only = 8; - * @return bool - */ - public function getEncipherOnly() - { - return $this->encipher_only; - } - - /** - * The key may be used to encipher only. - * - * Generated from protobuf field bool encipher_only = 8; - * @param bool $var - * @return $this - */ - public function setEncipherOnly($var) - { - GPBUtil::checkBool($var); - $this->encipher_only = $var; - - return $this; - } - - /** - * The key may be used to decipher only. - * - * Generated from protobuf field bool decipher_only = 9; - * @return bool - */ - public function getDecipherOnly() - { - return $this->decipher_only; - } - - /** - * The key may be used to decipher only. - * - * Generated from protobuf field bool decipher_only = 9; - * @param bool $var - * @return $this - */ - public function setDecipherOnly($var) - { - GPBUtil::checkBool($var); - $this->decipher_only = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCaPoolsRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCaPoolsRequest.php deleted file mode 100644 index 78a8d0f71091..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCaPoolsRequest.php +++ /dev/null @@ -1,256 +0,0 @@ -google.cloud.security.privateca.v1.ListCaPoolsRequest - */ -class ListCaPoolsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the location associated with the - * [CaPools][google.cloud.security.privateca.v1.CaPool], in the format - * `projects/{@*}locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Optional. Limit on the number of - * [CaPools][google.cloud.security.privateca.v1.CaPool] to include in the - * response. Further [CaPools][google.cloud.security.privateca.v1.CaPool] can - * subsequently be obtained by including the - * [ListCaPoolsResponse.next_page_token][google.cloud.security.privateca.v1.ListCaPoolsResponse.next_page_token] - * in a subsequent request. If unspecified, the server will pick an - * appropriate default. - * - * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $page_size = 0; - /** - * Optional. Pagination token, returned earlier via - * [ListCaPoolsResponse.next_page_token][google.cloud.security.privateca.v1.ListCaPoolsResponse.next_page_token]. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $page_token = ''; - /** - * Optional. Only include resources that match the filter in the response. - * - * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $filter = ''; - /** - * Optional. Specify how the results should be sorted. - * - * 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 location associated with the - * [CaPools][google.cloud.security.privateca.v1.CaPool], in the format - * `projects/*/locations/*`. Please see - * {@see CertificateAuthorityServiceClient::locationName()} for help formatting this field. - * - * @return \Google\Cloud\Security\PrivateCA\V1\ListCaPoolsRequest - * - * @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 location associated with the - * [CaPools][google.cloud.security.privateca.v1.CaPool], in the format - * `projects/{@*}locations/*`. - * @type int $page_size - * Optional. Limit on the number of - * [CaPools][google.cloud.security.privateca.v1.CaPool] to include in the - * response. Further [CaPools][google.cloud.security.privateca.v1.CaPool] can - * subsequently be obtained by including the - * [ListCaPoolsResponse.next_page_token][google.cloud.security.privateca.v1.ListCaPoolsResponse.next_page_token] - * in a subsequent request. If unspecified, the server will pick an - * appropriate default. - * @type string $page_token - * Optional. Pagination token, returned earlier via - * [ListCaPoolsResponse.next_page_token][google.cloud.security.privateca.v1.ListCaPoolsResponse.next_page_token]. - * @type string $filter - * Optional. Only include resources that match the filter in the response. - * @type string $order_by - * Optional. Specify how the results should be sorted. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the location associated with the - * [CaPools][google.cloud.security.privateca.v1.CaPool], 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 associated with the - * [CaPools][google.cloud.security.privateca.v1.CaPool], 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. Limit on the number of - * [CaPools][google.cloud.security.privateca.v1.CaPool] to include in the - * response. Further [CaPools][google.cloud.security.privateca.v1.CaPool] can - * subsequently be obtained by including the - * [ListCaPoolsResponse.next_page_token][google.cloud.security.privateca.v1.ListCaPoolsResponse.next_page_token] - * in a subsequent request. If unspecified, the 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. Limit on the number of - * [CaPools][google.cloud.security.privateca.v1.CaPool] to include in the - * response. Further [CaPools][google.cloud.security.privateca.v1.CaPool] can - * subsequently be obtained by including the - * [ListCaPoolsResponse.next_page_token][google.cloud.security.privateca.v1.ListCaPoolsResponse.next_page_token] - * in a subsequent request. If unspecified, the 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. Pagination token, returned earlier via - * [ListCaPoolsResponse.next_page_token][google.cloud.security.privateca.v1.ListCaPoolsResponse.next_page_token]. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Optional. Pagination token, returned earlier via - * [ListCaPoolsResponse.next_page_token][google.cloud.security.privateca.v1.ListCaPoolsResponse.next_page_token]. - * - * 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. Only include resources that match the filter in the response. - * - * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Optional. Only include resources that match the filter in the response. - * - * 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. Specify how the results should be sorted. - * - * Generated from protobuf field string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * Optional. Specify how the results should be sorted. - * - * 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCaPoolsResponse.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCaPoolsResponse.php deleted file mode 100644 index 1c7373498b77..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCaPoolsResponse.php +++ /dev/null @@ -1,144 +0,0 @@ -google.cloud.security.privateca.v1.ListCaPoolsResponse - */ -class ListCaPoolsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The list of [CaPools][google.cloud.security.privateca.v1.CaPool]. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CaPool ca_pools = 1; - */ - private $ca_pools; - /** - * A token to retrieve next page of results. Pass this value in - * [ListCertificateAuthoritiesRequest.page_token][google.cloud.security.privateca.v1.ListCertificateAuthoritiesRequest.page_token] - * to retrieve the next page of results. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - /** - * A list of locations (e.g. "us-west1") 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 \Google\Cloud\Security\PrivateCA\V1\CaPool[] $ca_pools - * The list of [CaPools][google.cloud.security.privateca.v1.CaPool]. - * @type string $next_page_token - * A token to retrieve next page of results. Pass this value in - * [ListCertificateAuthoritiesRequest.page_token][google.cloud.security.privateca.v1.ListCertificateAuthoritiesRequest.page_token] - * to retrieve the next page of results. - * @type string[] $unreachable - * A list of locations (e.g. "us-west1") that could not be reached. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * The list of [CaPools][google.cloud.security.privateca.v1.CaPool]. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CaPool ca_pools = 1; - * @return RepeatedField<\Google\Cloud\Security\PrivateCA\V1\CaPool> - */ - public function getCaPools() - { - return $this->ca_pools; - } - - /** - * The list of [CaPools][google.cloud.security.privateca.v1.CaPool]. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CaPool ca_pools = 1; - * @param \Google\Cloud\Security\PrivateCA\V1\CaPool[] $var - * @return $this - */ - public function setCaPools($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Security\PrivateCA\V1\CaPool::class); - $this->ca_pools = $arr; - - return $this; - } - - /** - * A token to retrieve next page of results. Pass this value in - * [ListCertificateAuthoritiesRequest.page_token][google.cloud.security.privateca.v1.ListCertificateAuthoritiesRequest.page_token] - * to retrieve 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 retrieve next page of results. Pass this value in - * [ListCertificateAuthoritiesRequest.page_token][google.cloud.security.privateca.v1.ListCertificateAuthoritiesRequest.page_token] - * to retrieve 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; - } - - /** - * A list of locations (e.g. "us-west1") that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @return RepeatedField - */ - public function getUnreachable() - { - return $this->unreachable; - } - - /** - * A list of locations (e.g. "us-west1") that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @param string[] $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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateAuthoritiesRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateAuthoritiesRequest.php deleted file mode 100644 index 24fab0d845a8..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateAuthoritiesRequest.php +++ /dev/null @@ -1,265 +0,0 @@ -google.cloud.security.privateca.v1.ListCertificateAuthoritiesRequest - */ -class ListCertificateAuthoritiesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the - * [CaPool][google.cloud.security.privateca.v1.CaPool] associated with the - * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority], - * in the format `projects/{@*}locations/{@*}caPools/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Optional. Limit on the number of - * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority] - * to include in the response. Further - * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority] - * can subsequently be obtained by including the - * [ListCertificateAuthoritiesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateAuthoritiesResponse.next_page_token] - * in a subsequent request. If unspecified, the server will pick an - * appropriate default. - * - * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $page_size = 0; - /** - * Optional. Pagination token, returned earlier via - * [ListCertificateAuthoritiesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateAuthoritiesResponse.next_page_token]. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $page_token = ''; - /** - * Optional. Only include resources that match the filter in the response. - * - * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $filter = ''; - /** - * Optional. Specify how the results should be sorted. - * - * 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 - * [CaPool][google.cloud.security.privateca.v1.CaPool] associated with the - * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority], - * in the format `projects/*/locations/*/caPools/*`. Please see - * {@see CertificateAuthorityServiceClient::caPoolName()} for help formatting this field. - * - * @return \Google\Cloud\Security\PrivateCA\V1\ListCertificateAuthoritiesRequest - * - * @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 - * [CaPool][google.cloud.security.privateca.v1.CaPool] associated with the - * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority], - * in the format `projects/{@*}locations/{@*}caPools/*`. - * @type int $page_size - * Optional. Limit on the number of - * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority] - * to include in the response. Further - * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority] - * can subsequently be obtained by including the - * [ListCertificateAuthoritiesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateAuthoritiesResponse.next_page_token] - * in a subsequent request. If unspecified, the server will pick an - * appropriate default. - * @type string $page_token - * Optional. Pagination token, returned earlier via - * [ListCertificateAuthoritiesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateAuthoritiesResponse.next_page_token]. - * @type string $filter - * Optional. Only include resources that match the filter in the response. - * @type string $order_by - * Optional. Specify how the results should be sorted. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the - * [CaPool][google.cloud.security.privateca.v1.CaPool] associated with the - * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority], - * in the format `projects/{@*}locations/{@*}caPools/*`. - * - * 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 - * [CaPool][google.cloud.security.privateca.v1.CaPool] associated with the - * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority], - * in the format `projects/{@*}locations/{@*}caPools/*`. - * - * 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. Limit on the number of - * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority] - * to include in the response. Further - * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority] - * can subsequently be obtained by including the - * [ListCertificateAuthoritiesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateAuthoritiesResponse.next_page_token] - * in a subsequent request. If unspecified, the 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. Limit on the number of - * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority] - * to include in the response. Further - * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority] - * can subsequently be obtained by including the - * [ListCertificateAuthoritiesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateAuthoritiesResponse.next_page_token] - * in a subsequent request. If unspecified, the 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. Pagination token, returned earlier via - * [ListCertificateAuthoritiesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateAuthoritiesResponse.next_page_token]. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Optional. Pagination token, returned earlier via - * [ListCertificateAuthoritiesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateAuthoritiesResponse.next_page_token]. - * - * 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. Only include resources that match the filter in the response. - * - * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Optional. Only include resources that match the filter in the response. - * - * 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. Specify how the results should be sorted. - * - * Generated from protobuf field string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * Optional. Specify how the results should be sorted. - * - * 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateAuthoritiesResponse.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateAuthoritiesResponse.php deleted file mode 100644 index 36887d5ea9a3..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateAuthoritiesResponse.php +++ /dev/null @@ -1,148 +0,0 @@ -google.cloud.security.privateca.v1.ListCertificateAuthoritiesResponse - */ -class ListCertificateAuthoritiesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The list of - * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority]. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CertificateAuthority certificate_authorities = 1; - */ - private $certificate_authorities; - /** - * A token to retrieve next page of results. Pass this value in - * [ListCertificateAuthoritiesRequest.page_token][google.cloud.security.privateca.v1.ListCertificateAuthoritiesRequest.page_token] - * to retrieve the next page of results. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - /** - * A list of locations (e.g. "us-west1") 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 \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority[] $certificate_authorities - * The list of - * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority]. - * @type string $next_page_token - * A token to retrieve next page of results. Pass this value in - * [ListCertificateAuthoritiesRequest.page_token][google.cloud.security.privateca.v1.ListCertificateAuthoritiesRequest.page_token] - * to retrieve the next page of results. - * @type string[] $unreachable - * A list of locations (e.g. "us-west1") that could not be reached. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * The list of - * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority]. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CertificateAuthority certificate_authorities = 1; - * @return RepeatedField<\Google\Cloud\Security\PrivateCA\V1\CertificateAuthority> - */ - public function getCertificateAuthorities() - { - return $this->certificate_authorities; - } - - /** - * The list of - * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority]. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CertificateAuthority certificate_authorities = 1; - * @param \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority[] $var - * @return $this - */ - public function setCertificateAuthorities($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority::class); - $this->certificate_authorities = $arr; - - return $this; - } - - /** - * A token to retrieve next page of results. Pass this value in - * [ListCertificateAuthoritiesRequest.page_token][google.cloud.security.privateca.v1.ListCertificateAuthoritiesRequest.page_token] - * to retrieve 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 retrieve next page of results. Pass this value in - * [ListCertificateAuthoritiesRequest.page_token][google.cloud.security.privateca.v1.ListCertificateAuthoritiesRequest.page_token] - * to retrieve 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; - } - - /** - * A list of locations (e.g. "us-west1") that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @return RepeatedField - */ - public function getUnreachable() - { - return $this->unreachable; - } - - /** - * A list of locations (e.g. "us-west1") that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @param string[] $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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateRevocationListsRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateRevocationListsRequest.php deleted file mode 100644 index bb02c0cf5ce4..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateRevocationListsRequest.php +++ /dev/null @@ -1,260 +0,0 @@ -google.cloud.security.privateca.v1.ListCertificateRevocationListsRequest - */ -class ListCertificateRevocationListsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the location associated with the - * [CertificateRevocationLists][google.cloud.security.privateca.v1.CertificateRevocationList], - * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Optional. Limit on the number of - * [CertificateRevocationLists][google.cloud.security.privateca.v1.CertificateRevocationList] - * to include in the response. Further - * [CertificateRevocationLists][google.cloud.security.privateca.v1.CertificateRevocationList] - * can subsequently be obtained by including the - * [ListCertificateRevocationListsResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateRevocationListsResponse.next_page_token] - * in a subsequent request. If unspecified, the server will pick an - * appropriate default. - * - * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $page_size = 0; - /** - * Optional. Pagination token, returned earlier via - * [ListCertificateRevocationListsResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateRevocationListsResponse.next_page_token]. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $page_token = ''; - /** - * Optional. Only include resources that match the filter in the response. - * - * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $filter = ''; - /** - * Optional. Specify how the results should be sorted. - * - * 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 location associated with the - * [CertificateRevocationLists][google.cloud.security.privateca.v1.CertificateRevocationList], - * in the format `projects/*/locations/*/caPools/*/certificateAuthorities/*`. Please see - * {@see CertificateAuthorityServiceClient::certificateAuthorityName()} for help formatting this field. - * - * @return \Google\Cloud\Security\PrivateCA\V1\ListCertificateRevocationListsRequest - * - * @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 location associated with the - * [CertificateRevocationLists][google.cloud.security.privateca.v1.CertificateRevocationList], - * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. - * @type int $page_size - * Optional. Limit on the number of - * [CertificateRevocationLists][google.cloud.security.privateca.v1.CertificateRevocationList] - * to include in the response. Further - * [CertificateRevocationLists][google.cloud.security.privateca.v1.CertificateRevocationList] - * can subsequently be obtained by including the - * [ListCertificateRevocationListsResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateRevocationListsResponse.next_page_token] - * in a subsequent request. If unspecified, the server will pick an - * appropriate default. - * @type string $page_token - * Optional. Pagination token, returned earlier via - * [ListCertificateRevocationListsResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateRevocationListsResponse.next_page_token]. - * @type string $filter - * Optional. Only include resources that match the filter in the response. - * @type string $order_by - * Optional. Specify how the results should be sorted. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the location associated with the - * [CertificateRevocationLists][google.cloud.security.privateca.v1.CertificateRevocationList], - * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. - * - * 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 associated with the - * [CertificateRevocationLists][google.cloud.security.privateca.v1.CertificateRevocationList], - * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. - * - * 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. Limit on the number of - * [CertificateRevocationLists][google.cloud.security.privateca.v1.CertificateRevocationList] - * to include in the response. Further - * [CertificateRevocationLists][google.cloud.security.privateca.v1.CertificateRevocationList] - * can subsequently be obtained by including the - * [ListCertificateRevocationListsResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateRevocationListsResponse.next_page_token] - * in a subsequent request. If unspecified, the 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. Limit on the number of - * [CertificateRevocationLists][google.cloud.security.privateca.v1.CertificateRevocationList] - * to include in the response. Further - * [CertificateRevocationLists][google.cloud.security.privateca.v1.CertificateRevocationList] - * can subsequently be obtained by including the - * [ListCertificateRevocationListsResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateRevocationListsResponse.next_page_token] - * in a subsequent request. If unspecified, the 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. Pagination token, returned earlier via - * [ListCertificateRevocationListsResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateRevocationListsResponse.next_page_token]. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Optional. Pagination token, returned earlier via - * [ListCertificateRevocationListsResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateRevocationListsResponse.next_page_token]. - * - * 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. Only include resources that match the filter in the response. - * - * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Optional. Only include resources that match the filter in the response. - * - * 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. Specify how the results should be sorted. - * - * Generated from protobuf field string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * Optional. Specify how the results should be sorted. - * - * 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateRevocationListsResponse.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateRevocationListsResponse.php deleted file mode 100644 index 392efa937fe7..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateRevocationListsResponse.php +++ /dev/null @@ -1,148 +0,0 @@ -google.cloud.security.privateca.v1.ListCertificateRevocationListsResponse - */ -class ListCertificateRevocationListsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The list of - * [CertificateRevocationLists][google.cloud.security.privateca.v1.CertificateRevocationList]. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CertificateRevocationList certificate_revocation_lists = 1; - */ - private $certificate_revocation_lists; - /** - * A token to retrieve next page of results. Pass this value in - * [ListCertificateRevocationListsRequest.page_token][google.cloud.security.privateca.v1.ListCertificateRevocationListsRequest.page_token] - * to retrieve the next page of results. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - /** - * A list of locations (e.g. "us-west1") 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 \Google\Cloud\Security\PrivateCA\V1\CertificateRevocationList[] $certificate_revocation_lists - * The list of - * [CertificateRevocationLists][google.cloud.security.privateca.v1.CertificateRevocationList]. - * @type string $next_page_token - * A token to retrieve next page of results. Pass this value in - * [ListCertificateRevocationListsRequest.page_token][google.cloud.security.privateca.v1.ListCertificateRevocationListsRequest.page_token] - * to retrieve the next page of results. - * @type string[] $unreachable - * A list of locations (e.g. "us-west1") that could not be reached. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * The list of - * [CertificateRevocationLists][google.cloud.security.privateca.v1.CertificateRevocationList]. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CertificateRevocationList certificate_revocation_lists = 1; - * @return RepeatedField<\Google\Cloud\Security\PrivateCA\V1\CertificateRevocationList> - */ - public function getCertificateRevocationLists() - { - return $this->certificate_revocation_lists; - } - - /** - * The list of - * [CertificateRevocationLists][google.cloud.security.privateca.v1.CertificateRevocationList]. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CertificateRevocationList certificate_revocation_lists = 1; - * @param \Google\Cloud\Security\PrivateCA\V1\CertificateRevocationList[] $var - * @return $this - */ - public function setCertificateRevocationLists($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Security\PrivateCA\V1\CertificateRevocationList::class); - $this->certificate_revocation_lists = $arr; - - return $this; - } - - /** - * A token to retrieve next page of results. Pass this value in - * [ListCertificateRevocationListsRequest.page_token][google.cloud.security.privateca.v1.ListCertificateRevocationListsRequest.page_token] - * to retrieve 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 retrieve next page of results. Pass this value in - * [ListCertificateRevocationListsRequest.page_token][google.cloud.security.privateca.v1.ListCertificateRevocationListsRequest.page_token] - * to retrieve 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; - } - - /** - * A list of locations (e.g. "us-west1") that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @return RepeatedField - */ - public function getUnreachable() - { - return $this->unreachable; - } - - /** - * A list of locations (e.g. "us-west1") that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @param string[] $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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateTemplatesRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateTemplatesRequest.php deleted file mode 100644 index cf391fa7dee6..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateTemplatesRequest.php +++ /dev/null @@ -1,260 +0,0 @@ -google.cloud.security.privateca.v1.ListCertificateTemplatesRequest - */ -class ListCertificateTemplatesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the location associated with the - * [CertificateTemplates][google.cloud.security.privateca.v1.CertificateTemplate], - * in the format `projects/{@*}locations/*`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Optional. Limit on the number of - * [CertificateTemplates][google.cloud.security.privateca.v1.CertificateTemplate] - * to include in the response. Further - * [CertificateTemplates][google.cloud.security.privateca.v1.CertificateTemplate] - * can subsequently be obtained by including the - * [ListCertificateTemplatesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateTemplatesResponse.next_page_token] - * in a subsequent request. If unspecified, the server will pick an - * appropriate default. - * - * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $page_size = 0; - /** - * Optional. Pagination token, returned earlier via - * [ListCertificateTemplatesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateTemplatesResponse.next_page_token]. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $page_token = ''; - /** - * Optional. Only include resources that match the filter in the response. - * - * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $filter = ''; - /** - * Optional. Specify how the results should be sorted. - * - * 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 location associated with the - * [CertificateTemplates][google.cloud.security.privateca.v1.CertificateTemplate], - * in the format `projects/*/locations/*`. Please see - * {@see CertificateAuthorityServiceClient::locationName()} for help formatting this field. - * - * @return \Google\Cloud\Security\PrivateCA\V1\ListCertificateTemplatesRequest - * - * @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 location associated with the - * [CertificateTemplates][google.cloud.security.privateca.v1.CertificateTemplate], - * in the format `projects/{@*}locations/*`. - * @type int $page_size - * Optional. Limit on the number of - * [CertificateTemplates][google.cloud.security.privateca.v1.CertificateTemplate] - * to include in the response. Further - * [CertificateTemplates][google.cloud.security.privateca.v1.CertificateTemplate] - * can subsequently be obtained by including the - * [ListCertificateTemplatesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateTemplatesResponse.next_page_token] - * in a subsequent request. If unspecified, the server will pick an - * appropriate default. - * @type string $page_token - * Optional. Pagination token, returned earlier via - * [ListCertificateTemplatesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateTemplatesResponse.next_page_token]. - * @type string $filter - * Optional. Only include resources that match the filter in the response. - * @type string $order_by - * Optional. Specify how the results should be sorted. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the location associated with the - * [CertificateTemplates][google.cloud.security.privateca.v1.CertificateTemplate], - * 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 associated with the - * [CertificateTemplates][google.cloud.security.privateca.v1.CertificateTemplate], - * 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. Limit on the number of - * [CertificateTemplates][google.cloud.security.privateca.v1.CertificateTemplate] - * to include in the response. Further - * [CertificateTemplates][google.cloud.security.privateca.v1.CertificateTemplate] - * can subsequently be obtained by including the - * [ListCertificateTemplatesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateTemplatesResponse.next_page_token] - * in a subsequent request. If unspecified, the 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. Limit on the number of - * [CertificateTemplates][google.cloud.security.privateca.v1.CertificateTemplate] - * to include in the response. Further - * [CertificateTemplates][google.cloud.security.privateca.v1.CertificateTemplate] - * can subsequently be obtained by including the - * [ListCertificateTemplatesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateTemplatesResponse.next_page_token] - * in a subsequent request. If unspecified, the 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. Pagination token, returned earlier via - * [ListCertificateTemplatesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateTemplatesResponse.next_page_token]. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Optional. Pagination token, returned earlier via - * [ListCertificateTemplatesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificateTemplatesResponse.next_page_token]. - * - * 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. Only include resources that match the filter in the response. - * - * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Optional. Only include resources that match the filter in the response. - * - * 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. Specify how the results should be sorted. - * - * Generated from protobuf field string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * Optional. Specify how the results should be sorted. - * - * 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateTemplatesResponse.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateTemplatesResponse.php deleted file mode 100644 index e3be4d853b47..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificateTemplatesResponse.php +++ /dev/null @@ -1,148 +0,0 @@ -google.cloud.security.privateca.v1.ListCertificateTemplatesResponse - */ -class ListCertificateTemplatesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The list of - * [CertificateTemplates][google.cloud.security.privateca.v1.CertificateTemplate]. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CertificateTemplate certificate_templates = 1; - */ - private $certificate_templates; - /** - * A token to retrieve next page of results. Pass this value in - * [ListCertificateTemplatesRequest.page_token][google.cloud.security.privateca.v1.ListCertificateTemplatesRequest.page_token] - * to retrieve the next page of results. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - /** - * A list of locations (e.g. "us-west1") 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 \Google\Cloud\Security\PrivateCA\V1\CertificateTemplate[] $certificate_templates - * The list of - * [CertificateTemplates][google.cloud.security.privateca.v1.CertificateTemplate]. - * @type string $next_page_token - * A token to retrieve next page of results. Pass this value in - * [ListCertificateTemplatesRequest.page_token][google.cloud.security.privateca.v1.ListCertificateTemplatesRequest.page_token] - * to retrieve the next page of results. - * @type string[] $unreachable - * A list of locations (e.g. "us-west1") that could not be reached. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * The list of - * [CertificateTemplates][google.cloud.security.privateca.v1.CertificateTemplate]. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CertificateTemplate certificate_templates = 1; - * @return RepeatedField<\Google\Cloud\Security\PrivateCA\V1\CertificateTemplate> - */ - public function getCertificateTemplates() - { - return $this->certificate_templates; - } - - /** - * The list of - * [CertificateTemplates][google.cloud.security.privateca.v1.CertificateTemplate]. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.CertificateTemplate certificate_templates = 1; - * @param \Google\Cloud\Security\PrivateCA\V1\CertificateTemplate[] $var - * @return $this - */ - public function setCertificateTemplates($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Security\PrivateCA\V1\CertificateTemplate::class); - $this->certificate_templates = $arr; - - return $this; - } - - /** - * A token to retrieve next page of results. Pass this value in - * [ListCertificateTemplatesRequest.page_token][google.cloud.security.privateca.v1.ListCertificateTemplatesRequest.page_token] - * to retrieve 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 retrieve next page of results. Pass this value in - * [ListCertificateTemplatesRequest.page_token][google.cloud.security.privateca.v1.ListCertificateTemplatesRequest.page_token] - * to retrieve 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; - } - - /** - * A list of locations (e.g. "us-west1") that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @return RepeatedField - */ - public function getUnreachable() - { - return $this->unreachable; - } - - /** - * A list of locations (e.g. "us-west1") that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @param string[] $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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificatesRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificatesRequest.php deleted file mode 100644 index 9313f4111e6e..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificatesRequest.php +++ /dev/null @@ -1,313 +0,0 @@ -google.cloud.security.privateca.v1.ListCertificatesRequest - */ -class ListCertificatesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the parent associated with the - * [Certificates][google.cloud.security.privateca.v1.Certificate], in the - * format `projects/{@*}locations/{@*}caPools/*`. The parent resource name can be - * in one of two forms: - * 1. **Specific CA Pool:** To list certificates within a single CA Pool: - * `projects/{@*}locations/{@*}caPools/*` - * 2. **All CA Pools in a Location:** To list certificates across *all* CA - * Pools in a given project and location, use the wildcard character (`-`) - * in place of the CA Pool ID. - * Example: `projects/{@*}locations/{@*}caPools/-` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Optional. Limit on the number of - * [Certificates][google.cloud.security.privateca.v1.Certificate] to include - * in the response. Further - * [Certificates][google.cloud.security.privateca.v1.Certificate] can - * subsequently be obtained by including the - * [ListCertificatesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificatesResponse.next_page_token] - * in a subsequent request. If unspecified, the server will pick an - * appropriate default. - * - * Generated from protobuf field int32 page_size = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $page_size = 0; - /** - * Optional. Pagination token, returned earlier via - * [ListCertificatesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificatesResponse.next_page_token]. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $page_token = ''; - /** - * Optional. Only include resources that match the filter in the response. For - * details on supported filters and syntax, see [Certificates Filtering - * documentation](https://cloud.google.com/certificate-authority-service/docs/sorting-filtering-certificates#filtering_support). - * - * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $filter = ''; - /** - * Optional. Specify how the results should be sorted. For details on - * supported fields and syntax, see [Certificates Sorting - * documentation](https://cloud.google.com/certificate-authority-service/docs/sorting-filtering-certificates#sorting_support). - * - * 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 parent associated with the - * [Certificates][google.cloud.security.privateca.v1.Certificate], in the - * format `projects/*/locations/*/caPools/*`. The parent resource name can be - * in one of two forms: - * - * 1. **Specific CA Pool:** To list certificates within a single CA Pool: - * `projects/*/locations/*/caPools/*` - * - * 2. **All CA Pools in a Location:** To list certificates across *all* CA - * Pools in a given project and location, use the wildcard character (`-`) - * in place of the CA Pool ID. - * Example: `projects/*/locations/*/caPools/-` - * Please see {@see CertificateAuthorityServiceClient::caPoolName()} for help formatting this field. - * - * @return \Google\Cloud\Security\PrivateCA\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 resource name of the parent associated with the - * [Certificates][google.cloud.security.privateca.v1.Certificate], in the - * format `projects/{@*}locations/{@*}caPools/*`. The parent resource name can be - * in one of two forms: - * 1. **Specific CA Pool:** To list certificates within a single CA Pool: - * `projects/{@*}locations/{@*}caPools/*` - * 2. **All CA Pools in a Location:** To list certificates across *all* CA - * Pools in a given project and location, use the wildcard character (`-`) - * in place of the CA Pool ID. - * Example: `projects/{@*}locations/{@*}caPools/-` - * @type int $page_size - * Optional. Limit on the number of - * [Certificates][google.cloud.security.privateca.v1.Certificate] to include - * in the response. Further - * [Certificates][google.cloud.security.privateca.v1.Certificate] can - * subsequently be obtained by including the - * [ListCertificatesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificatesResponse.next_page_token] - * in a subsequent request. If unspecified, the server will pick an - * appropriate default. - * @type string $page_token - * Optional. Pagination token, returned earlier via - * [ListCertificatesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificatesResponse.next_page_token]. - * @type string $filter - * Optional. Only include resources that match the filter in the response. For - * details on supported filters and syntax, see [Certificates Filtering - * documentation](https://cloud.google.com/certificate-authority-service/docs/sorting-filtering-certificates#filtering_support). - * @type string $order_by - * Optional. Specify how the results should be sorted. For details on - * supported fields and syntax, see [Certificates Sorting - * documentation](https://cloud.google.com/certificate-authority-service/docs/sorting-filtering-certificates#sorting_support). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the parent associated with the - * [Certificates][google.cloud.security.privateca.v1.Certificate], in the - * format `projects/{@*}locations/{@*}caPools/*`. The parent resource name can be - * in one of two forms: - * 1. **Specific CA Pool:** To list certificates within a single CA Pool: - * `projects/{@*}locations/{@*}caPools/*` - * 2. **All CA Pools in a Location:** To list certificates across *all* CA - * Pools in a given project and location, use the wildcard character (`-`) - * in place of the CA Pool ID. - * Example: `projects/{@*}locations/{@*}caPools/-` - * - * 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 parent associated with the - * [Certificates][google.cloud.security.privateca.v1.Certificate], in the - * format `projects/{@*}locations/{@*}caPools/*`. The parent resource name can be - * in one of two forms: - * 1. **Specific CA Pool:** To list certificates within a single CA Pool: - * `projects/{@*}locations/{@*}caPools/*` - * 2. **All CA Pools in a Location:** To list certificates across *all* CA - * Pools in a given project and location, use the wildcard character (`-`) - * in place of the CA Pool ID. - * Example: `projects/{@*}locations/{@*}caPools/-` - * - * 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. Limit on the number of - * [Certificates][google.cloud.security.privateca.v1.Certificate] to include - * in the response. Further - * [Certificates][google.cloud.security.privateca.v1.Certificate] can - * subsequently be obtained by including the - * [ListCertificatesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificatesResponse.next_page_token] - * in a subsequent request. If unspecified, the 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. Limit on the number of - * [Certificates][google.cloud.security.privateca.v1.Certificate] to include - * in the response. Further - * [Certificates][google.cloud.security.privateca.v1.Certificate] can - * subsequently be obtained by including the - * [ListCertificatesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificatesResponse.next_page_token] - * in a subsequent request. If unspecified, the 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. Pagination token, returned earlier via - * [ListCertificatesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificatesResponse.next_page_token]. - * - * Generated from protobuf field string page_token = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Optional. Pagination token, returned earlier via - * [ListCertificatesResponse.next_page_token][google.cloud.security.privateca.v1.ListCertificatesResponse.next_page_token]. - * - * 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. Only include resources that match the filter in the response. For - * details on supported filters and syntax, see [Certificates Filtering - * documentation](https://cloud.google.com/certificate-authority-service/docs/sorting-filtering-certificates#filtering_support). - * - * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Optional. Only include resources that match the filter in the response. For - * details on supported filters and syntax, see [Certificates Filtering - * documentation](https://cloud.google.com/certificate-authority-service/docs/sorting-filtering-certificates#filtering_support). - * - * 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. Specify how the results should be sorted. For details on - * supported fields and syntax, see [Certificates Sorting - * documentation](https://cloud.google.com/certificate-authority-service/docs/sorting-filtering-certificates#sorting_support). - * - * Generated from protobuf field string order_by = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * Optional. Specify how the results should be sorted. For details on - * supported fields and syntax, see [Certificates Sorting - * documentation](https://cloud.google.com/certificate-authority-service/docs/sorting-filtering-certificates#sorting_support). - * - * 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificatesResponse.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificatesResponse.php deleted file mode 100644 index 4a640eb686d5..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ListCertificatesResponse.php +++ /dev/null @@ -1,144 +0,0 @@ -google.cloud.security.privateca.v1.ListCertificatesResponse - */ -class ListCertificatesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The list of [Certificates][google.cloud.security.privateca.v1.Certificate]. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.Certificate certificates = 1; - */ - private $certificates; - /** - * A token to retrieve next page of results. Pass this value in - * [ListCertificatesRequest.page_token][google.cloud.security.privateca.v1.ListCertificatesRequest.page_token] - * to retrieve the next page of results. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - /** - * A list of locations (e.g. "us-west1") 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 \Google\Cloud\Security\PrivateCA\V1\Certificate[] $certificates - * The list of [Certificates][google.cloud.security.privateca.v1.Certificate]. - * @type string $next_page_token - * A token to retrieve next page of results. Pass this value in - * [ListCertificatesRequest.page_token][google.cloud.security.privateca.v1.ListCertificatesRequest.page_token] - * to retrieve the next page of results. - * @type string[] $unreachable - * A list of locations (e.g. "us-west1") that could not be reached. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * The list of [Certificates][google.cloud.security.privateca.v1.Certificate]. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.Certificate certificates = 1; - * @return RepeatedField<\Google\Cloud\Security\PrivateCA\V1\Certificate> - */ - public function getCertificates() - { - return $this->certificates; - } - - /** - * The list of [Certificates][google.cloud.security.privateca.v1.Certificate]. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.Certificate certificates = 1; - * @param \Google\Cloud\Security\PrivateCA\V1\Certificate[] $var - * @return $this - */ - public function setCertificates($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Security\PrivateCA\V1\Certificate::class); - $this->certificates = $arr; - - return $this; - } - - /** - * A token to retrieve next page of results. Pass this value in - * [ListCertificatesRequest.page_token][google.cloud.security.privateca.v1.ListCertificatesRequest.page_token] - * to retrieve 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 retrieve next page of results. Pass this value in - * [ListCertificatesRequest.page_token][google.cloud.security.privateca.v1.ListCertificatesRequest.page_token] - * to retrieve 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; - } - - /** - * A list of locations (e.g. "us-west1") that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @return RepeatedField - */ - public function getUnreachable() - { - return $this->unreachable; - } - - /** - * A list of locations (e.g. "us-west1") that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @param string[] $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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ObjectId.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ObjectId.php deleted file mode 100644 index ae046007323f..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/ObjectId.php +++ /dev/null @@ -1,73 +0,0 @@ -google.cloud.security.privateca.v1.ObjectId - */ -class ObjectId extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The parts of an OID path. The most significant parts of the path - * come first. - * - * Generated from protobuf field repeated int32 object_id_path = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - private $object_id_path; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int[] $object_id_path - * Required. The parts of an OID path. The most significant parts of the path - * come first. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * Required. The parts of an OID path. The most significant parts of the path - * come first. - * - * Generated from protobuf field repeated int32 object_id_path = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return RepeatedField - */ - public function getObjectIdPath() - { - return $this->object_id_path; - } - - /** - * Required. The parts of an OID path. The most significant parts of the path - * come first. - * - * Generated from protobuf field repeated int32 object_id_path = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param int[] $var - * @return $this - */ - public function setObjectIdPath($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::INT32); - $this->object_id_path = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/OperationMetadata.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/OperationMetadata.php deleted file mode 100644 index 32771fd1adb3..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/OperationMetadata.php +++ /dev/null @@ -1,311 +0,0 @@ -google.cloud.security.privateca.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 - * [google.longrunning.Operation.error][google.longrunning.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 - * [google.longrunning.Operation.error][google.longrunning.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\Security\Privateca\V1\Service::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 - * [google.longrunning.Operation.error][google.longrunning.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 - * [google.longrunning.Operation.error][google.longrunning.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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/PublicKey.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/PublicKey.php deleted file mode 100644 index 09b2adaed9a0..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/PublicKey.php +++ /dev/null @@ -1,106 +0,0 @@ -google.cloud.security.privateca.v1.PublicKey - */ -class PublicKey extends \Google\Protobuf\Internal\Message -{ - /** - * Required. A public key. The padding and encoding - * must match with the `KeyFormat` value specified for the `format` field. - * - * Generated from protobuf field bytes key = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $key = ''; - /** - * Required. The format of the public key. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.PublicKey.KeyFormat format = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $format = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $key - * Required. A public key. The padding and encoding - * must match with the `KeyFormat` value specified for the `format` field. - * @type int $format - * Required. The format of the public key. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * Required. A public key. The padding and encoding - * must match with the `KeyFormat` value specified for the `format` field. - * - * Generated from protobuf field bytes key = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getKey() - { - return $this->key; - } - - /** - * Required. A public key. The padding and encoding - * must match with the `KeyFormat` value specified for the `format` field. - * - * Generated from protobuf field bytes key = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setKey($var) - { - GPBUtil::checkString($var, False); - $this->key = $var; - - return $this; - } - - /** - * Required. The format of the public key. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.PublicKey.KeyFormat format = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getFormat() - { - return $this->format; - } - - /** - * Required. The format of the public key. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.PublicKey.KeyFormat format = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setFormat($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Security\PrivateCA\V1\PublicKey\KeyFormat::class); - $this->format = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/PublicKey/KeyFormat.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/PublicKey/KeyFormat.php deleted file mode 100644 index 5057742c7900..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/PublicKey/KeyFormat.php +++ /dev/null @@ -1,67 +0,0 @@ -google.cloud.security.privateca.v1.PublicKey.KeyFormat - */ -class KeyFormat -{ - /** - * Default unspecified value. - * - * Generated from protobuf enum KEY_FORMAT_UNSPECIFIED = 0; - */ - const KEY_FORMAT_UNSPECIFIED = 0; - /** - * The key is PEM-encoded as defined in [RFC - * 7468](https://tools.ietf.org/html/rfc7468). It can be any of the - * following: a PEM-encoded PKCS#1/RFC 3447 RSAPublicKey - * structure, an RFC 5280 - * [SubjectPublicKeyInfo](https://tools.ietf.org/html/rfc5280#section-4.1) - * or a PEM-encoded X.509 certificate signing request (CSR). If a - * [SubjectPublicKeyInfo](https://tools.ietf.org/html/rfc5280#section-4.1) - * is specified, it can contain a A PEM-encoded PKCS#1/RFC 3447 RSAPublicKey - * or a NIST P-256/secp256r1/prime256v1 or P-384 key. If a CSR is specified, - * it will used solely for the purpose of extracting the public key. When - * generated by the service, it will always be an RFC 5280 - * [SubjectPublicKeyInfo](https://tools.ietf.org/html/rfc5280#section-4.1) - * structure containing an algorithm identifier and a key. - * - * Generated from protobuf enum PEM = 1; - */ - const PEM = 1; - - private static $valueToName = [ - self::KEY_FORMAT_UNSPECIFIED => 'KEY_FORMAT_UNSPECIFIED', - self::PEM => 'PEM', - ]; - - 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/RelativeDistinguishedName.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/RelativeDistinguishedName.php deleted file mode 100644 index 737538b2d983..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/RelativeDistinguishedName.php +++ /dev/null @@ -1,69 +0,0 @@ -google.cloud.security.privateca.v1.RelativeDistinguishedName - */ -class RelativeDistinguishedName extends \Google\Protobuf\Internal\Message -{ - /** - * Attributes describes the attribute value assertions in the RDN. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.AttributeTypeAndValue attributes = 1; - */ - private $attributes; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Security\PrivateCA\V1\AttributeTypeAndValue[] $attributes - * Attributes describes the attribute value assertions in the RDN. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * Attributes describes the attribute value assertions in the RDN. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.AttributeTypeAndValue attributes = 1; - * @return RepeatedField<\Google\Cloud\Security\PrivateCA\V1\AttributeTypeAndValue> - */ - public function getAttributes() - { - return $this->attributes; - } - - /** - * Attributes describes the attribute value assertions in the RDN. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.AttributeTypeAndValue attributes = 1; - * @param \Google\Cloud\Security\PrivateCA\V1\AttributeTypeAndValue[] $var - * @return $this - */ - public function setAttributes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Security\PrivateCA\V1\AttributeTypeAndValue::class); - $this->attributes = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/RevocationReason.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/RevocationReason.php deleted file mode 100644 index 919eb2cb9c31..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/RevocationReason.php +++ /dev/null @@ -1,122 +0,0 @@ -google.cloud.security.privateca.v1.RevocationReason - */ -class RevocationReason -{ - /** - * Default unspecified value. This value does indicate that a - * [Certificate][google.cloud.security.privateca.v1.Certificate] has been - * revoked, but that a reason has not been recorded. - * - * Generated from protobuf enum REVOCATION_REASON_UNSPECIFIED = 0; - */ - const REVOCATION_REASON_UNSPECIFIED = 0; - /** - * Key material for this - * [Certificate][google.cloud.security.privateca.v1.Certificate] may have - * leaked. - * - * Generated from protobuf enum KEY_COMPROMISE = 1; - */ - const KEY_COMPROMISE = 1; - /** - * The key material for a certificate authority in the issuing path may have - * leaked. - * - * Generated from protobuf enum CERTIFICATE_AUTHORITY_COMPROMISE = 2; - */ - const CERTIFICATE_AUTHORITY_COMPROMISE = 2; - /** - * The subject or other attributes in this - * [Certificate][google.cloud.security.privateca.v1.Certificate] have changed. - * - * Generated from protobuf enum AFFILIATION_CHANGED = 3; - */ - const AFFILIATION_CHANGED = 3; - /** - * This [Certificate][google.cloud.security.privateca.v1.Certificate] has been - * superseded. - * - * Generated from protobuf enum SUPERSEDED = 4; - */ - const SUPERSEDED = 4; - /** - * This [Certificate][google.cloud.security.privateca.v1.Certificate] or - * entities in the issuing path have ceased to operate. - * - * Generated from protobuf enum CESSATION_OF_OPERATION = 5; - */ - const CESSATION_OF_OPERATION = 5; - /** - * This [Certificate][google.cloud.security.privateca.v1.Certificate] should - * not be considered valid, it is expected that it may become valid in the - * future. - * - * Generated from protobuf enum CERTIFICATE_HOLD = 6; - */ - const CERTIFICATE_HOLD = 6; - /** - * This [Certificate][google.cloud.security.privateca.v1.Certificate] no - * longer has permission to assert the listed attributes. - * - * Generated from protobuf enum PRIVILEGE_WITHDRAWN = 7; - */ - const PRIVILEGE_WITHDRAWN = 7; - /** - * The authority which determines appropriate attributes for a - * [Certificate][google.cloud.security.privateca.v1.Certificate] may have been - * compromised. - * - * Generated from protobuf enum ATTRIBUTE_AUTHORITY_COMPROMISE = 8; - */ - const ATTRIBUTE_AUTHORITY_COMPROMISE = 8; - - private static $valueToName = [ - self::REVOCATION_REASON_UNSPECIFIED => 'REVOCATION_REASON_UNSPECIFIED', - self::KEY_COMPROMISE => 'KEY_COMPROMISE', - self::CERTIFICATE_AUTHORITY_COMPROMISE => 'CERTIFICATE_AUTHORITY_COMPROMISE', - self::AFFILIATION_CHANGED => 'AFFILIATION_CHANGED', - self::SUPERSEDED => 'SUPERSEDED', - self::CESSATION_OF_OPERATION => 'CESSATION_OF_OPERATION', - self::CERTIFICATE_HOLD => 'CERTIFICATE_HOLD', - self::PRIVILEGE_WITHDRAWN => 'PRIVILEGE_WITHDRAWN', - self::ATTRIBUTE_AUTHORITY_COMPROMISE => 'ATTRIBUTE_AUTHORITY_COMPROMISE', - ]; - - 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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/RevokeCertificateRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/RevokeCertificateRequest.php deleted file mode 100644 index a1c5dcb28f5e..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/RevokeCertificateRequest.php +++ /dev/null @@ -1,208 +0,0 @@ -google.cloud.security.privateca.v1.RevokeCertificateRequest - */ -class RevokeCertificateRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name for this - * [Certificate][google.cloud.security.privateca.v1.Certificate] in the format - * `projects/{@*}locations/{@*}caPools/{@*}certificates/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Required. The - * [RevocationReason][google.cloud.security.privateca.v1.RevocationReason] for - * revoking this certificate. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.RevocationReason reason = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $reason = 0; - /** - * Optional. An 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $request_id = ''; - - /** - * @param string $name Required. The resource name for this - * [Certificate][google.cloud.security.privateca.v1.Certificate] in the format - * `projects/*/locations/*/caPools/*/certificates/*`. Please see - * {@see CertificateAuthorityServiceClient::certificateName()} for help formatting this field. - * - * @return \Google\Cloud\Security\PrivateCA\V1\RevokeCertificateRequest - * - * @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 for this - * [Certificate][google.cloud.security.privateca.v1.Certificate] in the format - * `projects/{@*}locations/{@*}caPools/{@*}certificates/*`. - * @type int $reason - * Required. The - * [RevocationReason][google.cloud.security.privateca.v1.RevocationReason] for - * revoking this certificate. - * @type string $request_id - * Optional. An 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\Security\Privateca\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name for this - * [Certificate][google.cloud.security.privateca.v1.Certificate] in the format - * `projects/{@*}locations/{@*}caPools/{@*}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. The resource name for this - * [Certificate][google.cloud.security.privateca.v1.Certificate] in the format - * `projects/{@*}locations/{@*}caPools/{@*}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; - } - - /** - * Required. The - * [RevocationReason][google.cloud.security.privateca.v1.RevocationReason] for - * revoking this certificate. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.RevocationReason reason = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getReason() - { - return $this->reason; - } - - /** - * Required. The - * [RevocationReason][google.cloud.security.privateca.v1.RevocationReason] for - * revoking this certificate. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.RevocationReason reason = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setReason($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Security\PrivateCA\V1\RevocationReason::class); - $this->reason = $var; - - return $this; - } - - /** - * Optional. An 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. An 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 = 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; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/Subject.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/Subject.php deleted file mode 100644 index abe915895acf..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/Subject.php +++ /dev/null @@ -1,340 +0,0 @@ -google.cloud.security.privateca.v1.Subject - */ -class Subject extends \Google\Protobuf\Internal\Message -{ - /** - * The "common name" of the subject. - * - * Generated from protobuf field string common_name = 1; - */ - protected $common_name = ''; - /** - * The country code of the subject. - * - * Generated from protobuf field string country_code = 2; - */ - protected $country_code = ''; - /** - * The organization of the subject. - * - * Generated from protobuf field string organization = 3; - */ - protected $organization = ''; - /** - * The organizational_unit of the subject. - * - * Generated from protobuf field string organizational_unit = 4; - */ - protected $organizational_unit = ''; - /** - * The locality or city of the subject. - * - * Generated from protobuf field string locality = 5; - */ - protected $locality = ''; - /** - * The province, territory, or regional state of the subject. - * - * Generated from protobuf field string province = 6; - */ - protected $province = ''; - /** - * The street address of the subject. - * - * Generated from protobuf field string street_address = 7; - */ - protected $street_address = ''; - /** - * The postal code of the subject. - * - * Generated from protobuf field string postal_code = 8; - */ - protected $postal_code = ''; - /** - * This field can be used in place of the named subject fields. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.RelativeDistinguishedName rdn_sequence = 9; - */ - private $rdn_sequence; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $common_name - * The "common name" of the subject. - * @type string $country_code - * The country code of the subject. - * @type string $organization - * The organization of the subject. - * @type string $organizational_unit - * The organizational_unit of the subject. - * @type string $locality - * The locality or city of the subject. - * @type string $province - * The province, territory, or regional state of the subject. - * @type string $street_address - * The street address of the subject. - * @type string $postal_code - * The postal code of the subject. - * @type \Google\Cloud\Security\PrivateCA\V1\RelativeDistinguishedName[] $rdn_sequence - * This field can be used in place of the named subject fields. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * The "common name" of the subject. - * - * Generated from protobuf field string common_name = 1; - * @return string - */ - public function getCommonName() - { - return $this->common_name; - } - - /** - * The "common name" of the subject. - * - * Generated from protobuf field string common_name = 1; - * @param string $var - * @return $this - */ - public function setCommonName($var) - { - GPBUtil::checkString($var, True); - $this->common_name = $var; - - return $this; - } - - /** - * The country code of the subject. - * - * Generated from protobuf field string country_code = 2; - * @return string - */ - public function getCountryCode() - { - return $this->country_code; - } - - /** - * The country code of the subject. - * - * Generated from protobuf field string country_code = 2; - * @param string $var - * @return $this - */ - public function setCountryCode($var) - { - GPBUtil::checkString($var, True); - $this->country_code = $var; - - return $this; - } - - /** - * The organization of the subject. - * - * Generated from protobuf field string organization = 3; - * @return string - */ - public function getOrganization() - { - return $this->organization; - } - - /** - * The organization of the subject. - * - * Generated from protobuf field string organization = 3; - * @param string $var - * @return $this - */ - public function setOrganization($var) - { - GPBUtil::checkString($var, True); - $this->organization = $var; - - return $this; - } - - /** - * The organizational_unit of the subject. - * - * Generated from protobuf field string organizational_unit = 4; - * @return string - */ - public function getOrganizationalUnit() - { - return $this->organizational_unit; - } - - /** - * The organizational_unit of the subject. - * - * Generated from protobuf field string organizational_unit = 4; - * @param string $var - * @return $this - */ - public function setOrganizationalUnit($var) - { - GPBUtil::checkString($var, True); - $this->organizational_unit = $var; - - return $this; - } - - /** - * The locality or city of the subject. - * - * Generated from protobuf field string locality = 5; - * @return string - */ - public function getLocality() - { - return $this->locality; - } - - /** - * The locality or city of the subject. - * - * Generated from protobuf field string locality = 5; - * @param string $var - * @return $this - */ - public function setLocality($var) - { - GPBUtil::checkString($var, True); - $this->locality = $var; - - return $this; - } - - /** - * The province, territory, or regional state of the subject. - * - * Generated from protobuf field string province = 6; - * @return string - */ - public function getProvince() - { - return $this->province; - } - - /** - * The province, territory, or regional state of the subject. - * - * Generated from protobuf field string province = 6; - * @param string $var - * @return $this - */ - public function setProvince($var) - { - GPBUtil::checkString($var, True); - $this->province = $var; - - return $this; - } - - /** - * The street address of the subject. - * - * Generated from protobuf field string street_address = 7; - * @return string - */ - public function getStreetAddress() - { - return $this->street_address; - } - - /** - * The street address of the subject. - * - * Generated from protobuf field string street_address = 7; - * @param string $var - * @return $this - */ - public function setStreetAddress($var) - { - GPBUtil::checkString($var, True); - $this->street_address = $var; - - return $this; - } - - /** - * The postal code of the subject. - * - * Generated from protobuf field string postal_code = 8; - * @return string - */ - public function getPostalCode() - { - return $this->postal_code; - } - - /** - * The postal code of the subject. - * - * Generated from protobuf field string postal_code = 8; - * @param string $var - * @return $this - */ - public function setPostalCode($var) - { - GPBUtil::checkString($var, True); - $this->postal_code = $var; - - return $this; - } - - /** - * This field can be used in place of the named subject fields. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.RelativeDistinguishedName rdn_sequence = 9; - * @return RepeatedField<\Google\Cloud\Security\PrivateCA\V1\RelativeDistinguishedName> - */ - public function getRdnSequence() - { - return $this->rdn_sequence; - } - - /** - * This field can be used in place of the named subject fields. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.RelativeDistinguishedName rdn_sequence = 9; - * @param \Google\Cloud\Security\PrivateCA\V1\RelativeDistinguishedName[] $var - * @return $this - */ - public function setRdnSequence($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Security\PrivateCA\V1\RelativeDistinguishedName::class); - $this->rdn_sequence = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/SubjectAltNames.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/SubjectAltNames.php deleted file mode 100644 index 97042ad72bad..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/SubjectAltNames.php +++ /dev/null @@ -1,214 +0,0 @@ -google.cloud.security.privateca.v1.SubjectAltNames - */ -class SubjectAltNames extends \Google\Protobuf\Internal\Message -{ - /** - * Contains only valid, fully-qualified host names. - * - * Generated from protobuf field repeated string dns_names = 1; - */ - private $dns_names; - /** - * Contains only valid RFC 3986 URIs. - * - * Generated from protobuf field repeated string uris = 2; - */ - private $uris; - /** - * Contains only valid RFC 2822 E-mail addresses. - * - * Generated from protobuf field repeated string email_addresses = 3; - */ - private $email_addresses; - /** - * Contains only valid 32-bit IPv4 addresses or RFC 4291 IPv6 addresses. - * - * Generated from protobuf field repeated string ip_addresses = 4; - */ - private $ip_addresses; - /** - * Contains additional subject alternative name values. - * For each custom_san, the `value` field must contain an ASN.1 encoded - * UTF8String. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.X509Extension custom_sans = 5; - */ - private $custom_sans; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string[] $dns_names - * Contains only valid, fully-qualified host names. - * @type string[] $uris - * Contains only valid RFC 3986 URIs. - * @type string[] $email_addresses - * Contains only valid RFC 2822 E-mail addresses. - * @type string[] $ip_addresses - * Contains only valid 32-bit IPv4 addresses or RFC 4291 IPv6 addresses. - * @type \Google\Cloud\Security\PrivateCA\V1\X509Extension[] $custom_sans - * Contains additional subject alternative name values. - * For each custom_san, the `value` field must contain an ASN.1 encoded - * UTF8String. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * Contains only valid, fully-qualified host names. - * - * Generated from protobuf field repeated string dns_names = 1; - * @return RepeatedField - */ - public function getDnsNames() - { - return $this->dns_names; - } - - /** - * Contains only valid, fully-qualified host names. - * - * Generated from protobuf field repeated string dns_names = 1; - * @param string[] $var - * @return $this - */ - public function setDnsNames($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->dns_names = $arr; - - return $this; - } - - /** - * Contains only valid RFC 3986 URIs. - * - * Generated from protobuf field repeated string uris = 2; - * @return RepeatedField - */ - public function getUris() - { - return $this->uris; - } - - /** - * Contains only valid RFC 3986 URIs. - * - * Generated from protobuf field repeated string uris = 2; - * @param string[] $var - * @return $this - */ - public function setUris($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->uris = $arr; - - return $this; - } - - /** - * Contains only valid RFC 2822 E-mail addresses. - * - * Generated from protobuf field repeated string email_addresses = 3; - * @return RepeatedField - */ - public function getEmailAddresses() - { - return $this->email_addresses; - } - - /** - * Contains only valid RFC 2822 E-mail addresses. - * - * Generated from protobuf field repeated string email_addresses = 3; - * @param string[] $var - * @return $this - */ - public function setEmailAddresses($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->email_addresses = $arr; - - return $this; - } - - /** - * Contains only valid 32-bit IPv4 addresses or RFC 4291 IPv6 addresses. - * - * Generated from protobuf field repeated string ip_addresses = 4; - * @return RepeatedField - */ - public function getIpAddresses() - { - return $this->ip_addresses; - } - - /** - * Contains only valid 32-bit IPv4 addresses or RFC 4291 IPv6 addresses. - * - * Generated from protobuf field repeated string ip_addresses = 4; - * @param string[] $var - * @return $this - */ - public function setIpAddresses($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->ip_addresses = $arr; - - return $this; - } - - /** - * Contains additional subject alternative name values. - * For each custom_san, the `value` field must contain an ASN.1 encoded - * UTF8String. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.X509Extension custom_sans = 5; - * @return RepeatedField<\Google\Cloud\Security\PrivateCA\V1\X509Extension> - */ - public function getCustomSans() - { - return $this->custom_sans; - } - - /** - * Contains additional subject alternative name values. - * For each custom_san, the `value` field must contain an ASN.1 encoded - * UTF8String. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.X509Extension custom_sans = 5; - * @param \Google\Cloud\Security\PrivateCA\V1\X509Extension[] $var - * @return $this - */ - public function setCustomSans($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Security\PrivateCA\V1\X509Extension::class); - $this->custom_sans = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/SubjectRequestMode.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/SubjectRequestMode.php deleted file mode 100644 index 5932c585535f..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/SubjectRequestMode.php +++ /dev/null @@ -1,96 +0,0 @@ -google.cloud.security.privateca.v1.SubjectRequestMode - */ -class SubjectRequestMode -{ - /** - * Not specified. - * - * Generated from protobuf enum SUBJECT_REQUEST_MODE_UNSPECIFIED = 0; - */ - const SUBJECT_REQUEST_MODE_UNSPECIFIED = 0; - /** - * The default mode used in most cases. Indicates that the certificate's - * [Subject][google.cloud.security.privateca.v1.Subject] and/or - * [SubjectAltNames][google.cloud.security.privateca.v1.SubjectAltNames] are - * specified in the certificate request. This mode requires the caller to have - * the `privateca.certificates.create` permission. - * - * Generated from protobuf enum DEFAULT = 1; - */ - const PBDEFAULT = 1; - /** - * A mode used to get an accurate representation of the Subject - * field's distinguished name. Indicates that the certificate's - * [Subject][google.cloud.security.privateca.v1.Subject] and/or - * [SubjectAltNames][google.cloud.security.privateca.v1.SubjectAltNames] are - * specified in the certificate request. When parsing a PEM CSR this mode will - * maintain the sequence of RDNs found in the CSR's subject field in the - * issued [Certificate][google.cloud.security.privateca.v1.Certificate]. This - * mode requires the caller to have the `privateca.certificates.create` - * permission. - * - * Generated from protobuf enum RDN_SEQUENCE = 3; - */ - const RDN_SEQUENCE = 3; - /** - * A mode reserved for special cases. Indicates that the certificate should - * have one SPIFFE - * [SubjectAltNames][google.cloud.security.privateca.v1.SubjectAltNames] set - * by the service based on the caller's identity. This mode will ignore any - * explicitly specified [Subject][google.cloud.security.privateca.v1.Subject] - * and/or - * [SubjectAltNames][google.cloud.security.privateca.v1.SubjectAltNames] in - * the certificate request. This mode requires the caller to have the - * `privateca.certificates.createForSelf` permission. - * - * Generated from protobuf enum REFLECTED_SPIFFE = 2; - */ - const REFLECTED_SPIFFE = 2; - - private static $valueToName = [ - self::SUBJECT_REQUEST_MODE_UNSPECIFIED => 'SUBJECT_REQUEST_MODE_UNSPECIFIED', - self::PBDEFAULT => 'DEFAULT', - self::RDN_SEQUENCE => 'RDN_SEQUENCE', - self::REFLECTED_SPIFFE => 'REFLECTED_SPIFFE', - ]; - - 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); - } -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/SubordinateConfig.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/SubordinateConfig.php deleted file mode 100644 index 364e925c0b05..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/SubordinateConfig.php +++ /dev/null @@ -1,135 +0,0 @@ -google.cloud.security.privateca.v1.SubordinateConfig - */ -class SubordinateConfig extends \Google\Protobuf\Internal\Message -{ - protected $subordinate_config; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $certificate_authority - * Required. This can refer to a - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * that was used to create a subordinate - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. - * This field is used for information and usability purposes only. The - * resource name is in the format - * `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. - * @type \Google\Cloud\Security\PrivateCA\V1\SubordinateConfig\SubordinateConfigChain $pem_issuer_chain - * Required. Contains the PEM certificate chain for the issuers of this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority], - * but not pem certificate for this CA itself. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * Required. This can refer to a - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * that was used to create a subordinate - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. - * This field is used for information and usability purposes only. The - * resource name is in the format - * `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. - * - * Generated from protobuf field string certificate_authority = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getCertificateAuthority() - { - return $this->readOneof(1); - } - - public function hasCertificateAuthority() - { - return $this->hasOneof(1); - } - - /** - * Required. This can refer to a - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * that was used to create a subordinate - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. - * This field is used for information and usability purposes only. The - * resource name is in the format - * `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. - * - * Generated from protobuf field string certificate_authority = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setCertificateAuthority($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * Required. Contains the PEM certificate chain for the issuers of this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority], - * but not pem certificate for this CA itself. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.SubordinateConfig.SubordinateConfigChain pem_issuer_chain = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Security\PrivateCA\V1\SubordinateConfig\SubordinateConfigChain|null - */ - public function getPemIssuerChain() - { - return $this->readOneof(2); - } - - public function hasPemIssuerChain() - { - return $this->hasOneof(2); - } - - /** - * Required. Contains the PEM certificate chain for the issuers of this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority], - * but not pem certificate for this CA itself. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.SubordinateConfig.SubordinateConfigChain pem_issuer_chain = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Security\PrivateCA\V1\SubordinateConfig\SubordinateConfigChain $var - * @return $this - */ - public function setPemIssuerChain($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\SubordinateConfig\SubordinateConfigChain::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * @return string - */ - public function getSubordinateConfig() - { - return $this->whichOneof("subordinate_config"); - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/SubordinateConfig/SubordinateConfigChain.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/SubordinateConfig/SubordinateConfigChain.php deleted file mode 100644 index 107fc5682746..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/SubordinateConfig/SubordinateConfigChain.php +++ /dev/null @@ -1,68 +0,0 @@ -google.cloud.security.privateca.v1.SubordinateConfig.SubordinateConfigChain - */ -class SubordinateConfigChain extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Expected to be in leaf-to-root order according to RFC 5246. - * - * Generated from protobuf field repeated string pem_certificates = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - private $pem_certificates; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string[] $pem_certificates - * Required. Expected to be in leaf-to-root order according to RFC 5246. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * Required. Expected to be in leaf-to-root order according to RFC 5246. - * - * Generated from protobuf field repeated string pem_certificates = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return RepeatedField - */ - public function getPemCertificates() - { - return $this->pem_certificates; - } - - /** - * Required. Expected to be in leaf-to-root order according to RFC 5246. - * - * Generated from protobuf field repeated string pem_certificates = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string[] $var - * @return $this - */ - public function setPemCertificates($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->pem_certificates = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UndeleteCertificateAuthorityRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UndeleteCertificateAuthorityRequest.php deleted file mode 100644 index d168251dde62..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UndeleteCertificateAuthorityRequest.php +++ /dev/null @@ -1,166 +0,0 @@ -google.cloud.security.privateca.v1.UndeleteCertificateAuthorityRequest - */ -class UndeleteCertificateAuthorityRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name for this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Optional. An 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { - */ - protected $request_id = ''; - - /** - * @param string $name Required. The resource name for this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the format `projects/*/locations/*/caPools/*/certificateAuthorities/*`. Please see - * {@see CertificateAuthorityServiceClient::certificateAuthorityName()} for help formatting this field. - * - * @return \Google\Cloud\Security\PrivateCA\V1\UndeleteCertificateAuthorityRequest - * - * @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 for this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. - * @type string $request_id - * Optional. An 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\Security\Privateca\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name for this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. - * - * 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 for this - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in the format `projects/{@*}locations/{@*}caPools/{@*}certificateAuthorities/*`. - * - * 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 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. An 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { - * @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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UpdateCaPoolRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UpdateCaPoolRequest.php deleted file mode 100644 index 0114b1f48dff..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UpdateCaPoolRequest.php +++ /dev/null @@ -1,216 +0,0 @@ -google.cloud.security.privateca.v1.UpdateCaPoolRequest - */ -class UpdateCaPoolRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. [CaPool][google.cloud.security.privateca.v1.CaPool] with updated - * values. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool ca_pool = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $ca_pool = null; - /** - * Required. A list of fields to be updated in this request. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $update_mask = null; - /** - * Optional. An 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 = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { - */ - protected $request_id = ''; - - /** - * @param \Google\Cloud\Security\PrivateCA\V1\CaPool $caPool Required. [CaPool][google.cloud.security.privateca.v1.CaPool] with updated - * values. - * @param \Google\Protobuf\FieldMask $updateMask Required. A list of fields to be updated in this request. - * - * @return \Google\Cloud\Security\PrivateCA\V1\UpdateCaPoolRequest - * - * @experimental - */ - public static function build(\Google\Cloud\Security\PrivateCA\V1\CaPool $caPool, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setCaPool($caPool) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Security\PrivateCA\V1\CaPool $ca_pool - * Required. [CaPool][google.cloud.security.privateca.v1.CaPool] with updated - * values. - * @type \Google\Protobuf\FieldMask $update_mask - * Required. A list of fields to be updated in this request. - * @type string $request_id - * Optional. An 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\Security\Privateca\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Required. [CaPool][google.cloud.security.privateca.v1.CaPool] with updated - * values. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool ca_pool = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Security\PrivateCA\V1\CaPool|null - */ - public function getCaPool() - { - return $this->ca_pool; - } - - public function hasCaPool() - { - return isset($this->ca_pool); - } - - public function clearCaPool() - { - unset($this->ca_pool); - } - - /** - * Required. [CaPool][google.cloud.security.privateca.v1.CaPool] with updated - * values. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CaPool ca_pool = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Security\PrivateCA\V1\CaPool $var - * @return $this - */ - public function setCaPool($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CaPool::class); - $this->ca_pool = $var; - - return $this; - } - - /** - * Required. A list of fields to be updated in this request. - * - * 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. A list of fields to be updated in this request. - * - * 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; - } - - /** - * Optional. An 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 = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. An 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 = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { - * @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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UpdateCertificateAuthorityRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UpdateCertificateAuthorityRequest.php deleted file mode 100644 index 5af30051cf4d..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UpdateCertificateAuthorityRequest.php +++ /dev/null @@ -1,221 +0,0 @@ -google.cloud.security.privateca.v1.UpdateCertificateAuthorityRequest - */ -class UpdateCertificateAuthorityRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * with updated values. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority certificate_authority = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $certificate_authority = null; - /** - * Required. A list of fields to be updated in this request. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $update_mask = null; - /** - * Optional. An 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 = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { - */ - protected $request_id = ''; - - /** - * @param \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority $certificateAuthority Required. - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * with updated values. - * @param \Google\Protobuf\FieldMask $updateMask Required. A list of fields to be updated in this request. - * - * @return \Google\Cloud\Security\PrivateCA\V1\UpdateCertificateAuthorityRequest - * - * @experimental - */ - public static function build(\Google\Cloud\Security\PrivateCA\V1\CertificateAuthority $certificateAuthority, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setCertificateAuthority($certificateAuthority) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority $certificate_authority - * Required. - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * with updated values. - * @type \Google\Protobuf\FieldMask $update_mask - * Required. A list of fields to be updated in this request. - * @type string $request_id - * Optional. An 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\Security\Privateca\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Required. - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * with updated values. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority certificate_authority = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority|null - */ - public function getCertificateAuthority() - { - return $this->certificate_authority; - } - - public function hasCertificateAuthority() - { - return isset($this->certificate_authority); - } - - public function clearCertificateAuthority() - { - unset($this->certificate_authority); - } - - /** - * Required. - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * with updated values. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateAuthority certificate_authority = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority $var - * @return $this - */ - public function setCertificateAuthority($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CertificateAuthority::class); - $this->certificate_authority = $var; - - return $this; - } - - /** - * Required. A list of fields to be updated in this request. - * - * 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. A list of fields to be updated in this request. - * - * 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; - } - - /** - * Optional. An 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 = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. An 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 = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { - * @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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UpdateCertificateRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UpdateCertificateRequest.php deleted file mode 100644 index 96118eec5794..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UpdateCertificateRequest.php +++ /dev/null @@ -1,216 +0,0 @@ -google.cloud.security.privateca.v1.UpdateCertificateRequest - */ -class UpdateCertificateRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. [Certificate][google.cloud.security.privateca.v1.Certificate] - * with updated values. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.Certificate certificate = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $certificate = null; - /** - * Required. A list of fields to be updated in this request. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $update_mask = null; - /** - * Optional. An 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $request_id = ''; - - /** - * @param \Google\Cloud\Security\PrivateCA\V1\Certificate $certificate Required. [Certificate][google.cloud.security.privateca.v1.Certificate] - * with updated values. - * @param \Google\Protobuf\FieldMask $updateMask Required. A list of fields to be updated in this request. - * - * @return \Google\Cloud\Security\PrivateCA\V1\UpdateCertificateRequest - * - * @experimental - */ - public static function build(\Google\Cloud\Security\PrivateCA\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\Security\PrivateCA\V1\Certificate $certificate - * Required. [Certificate][google.cloud.security.privateca.v1.Certificate] - * with updated values. - * @type \Google\Protobuf\FieldMask $update_mask - * Required. A list of fields to be updated in this request. - * @type string $request_id - * Optional. An 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\Security\Privateca\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Required. [Certificate][google.cloud.security.privateca.v1.Certificate] - * with updated values. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.Certificate certificate = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Security\PrivateCA\V1\Certificate|null - */ - public function getCertificate() - { - return $this->certificate; - } - - public function hasCertificate() - { - return isset($this->certificate); - } - - public function clearCertificate() - { - unset($this->certificate); - } - - /** - * Required. [Certificate][google.cloud.security.privateca.v1.Certificate] - * with updated values. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.Certificate certificate = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Security\PrivateCA\V1\Certificate $var - * @return $this - */ - public function setCertificate($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\Certificate::class); - $this->certificate = $var; - - return $this; - } - - /** - * Required. A list of fields to be updated in this request. - * - * 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. A list of fields to be updated in this request. - * - * 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; - } - - /** - * Optional. An 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. An 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 = 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; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UpdateCertificateRevocationListRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UpdateCertificateRevocationListRequest.php deleted file mode 100644 index efb8dcf26ca0..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UpdateCertificateRevocationListRequest.php +++ /dev/null @@ -1,221 +0,0 @@ -google.cloud.security.privateca.v1.UpdateCertificateRevocationListRequest - */ -class UpdateCertificateRevocationListRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. - * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] - * with updated values. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateRevocationList certificate_revocation_list = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $certificate_revocation_list = null; - /** - * Required. A list of fields to be updated in this request. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $update_mask = null; - /** - * Optional. An 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $request_id = ''; - - /** - * @param \Google\Cloud\Security\PrivateCA\V1\CertificateRevocationList $certificateRevocationList Required. - * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] - * with updated values. - * @param \Google\Protobuf\FieldMask $updateMask Required. A list of fields to be updated in this request. - * - * @return \Google\Cloud\Security\PrivateCA\V1\UpdateCertificateRevocationListRequest - * - * @experimental - */ - public static function build(\Google\Cloud\Security\PrivateCA\V1\CertificateRevocationList $certificateRevocationList, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setCertificateRevocationList($certificateRevocationList) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Security\PrivateCA\V1\CertificateRevocationList $certificate_revocation_list - * Required. - * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] - * with updated values. - * @type \Google\Protobuf\FieldMask $update_mask - * Required. A list of fields to be updated in this request. - * @type string $request_id - * Optional. An 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\Security\Privateca\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Required. - * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] - * with updated values. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateRevocationList certificate_revocation_list = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Security\PrivateCA\V1\CertificateRevocationList|null - */ - public function getCertificateRevocationList() - { - return $this->certificate_revocation_list; - } - - public function hasCertificateRevocationList() - { - return isset($this->certificate_revocation_list); - } - - public function clearCertificateRevocationList() - { - unset($this->certificate_revocation_list); - } - - /** - * Required. - * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList] - * with updated values. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateRevocationList certificate_revocation_list = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Security\PrivateCA\V1\CertificateRevocationList $var - * @return $this - */ - public function setCertificateRevocationList($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CertificateRevocationList::class); - $this->certificate_revocation_list = $var; - - return $this; - } - - /** - * Required. A list of fields to be updated in this request. - * - * 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. A list of fields to be updated in this request. - * - * 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; - } - - /** - * Optional. An 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. An 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 = 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; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UpdateCertificateTemplateRequest.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UpdateCertificateTemplateRequest.php deleted file mode 100644 index ce213554b5c9..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/UpdateCertificateTemplateRequest.php +++ /dev/null @@ -1,221 +0,0 @@ -google.cloud.security.privateca.v1.UpdateCertificateTemplateRequest - */ -class UpdateCertificateTemplateRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * with updated values. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateTemplate certificate_template = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $certificate_template = null; - /** - * Required. A list of fields to be updated in this request. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $update_mask = null; - /** - * Optional. An 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 = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { - */ - protected $request_id = ''; - - /** - * @param \Google\Cloud\Security\PrivateCA\V1\CertificateTemplate $certificateTemplate Required. - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * with updated values. - * @param \Google\Protobuf\FieldMask $updateMask Required. A list of fields to be updated in this request. - * - * @return \Google\Cloud\Security\PrivateCA\V1\UpdateCertificateTemplateRequest - * - * @experimental - */ - public static function build(\Google\Cloud\Security\PrivateCA\V1\CertificateTemplate $certificateTemplate, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setCertificateTemplate($certificateTemplate) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Security\PrivateCA\V1\CertificateTemplate $certificate_template - * Required. - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * with updated values. - * @type \Google\Protobuf\FieldMask $update_mask - * Required. A list of fields to be updated in this request. - * @type string $request_id - * Optional. An 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\Security\Privateca\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Required. - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * with updated values. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateTemplate certificate_template = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Security\PrivateCA\V1\CertificateTemplate|null - */ - public function getCertificateTemplate() - { - return $this->certificate_template; - } - - public function hasCertificateTemplate() - { - return isset($this->certificate_template); - } - - public function clearCertificateTemplate() - { - unset($this->certificate_template); - } - - /** - * Required. - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * with updated values. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.CertificateTemplate certificate_template = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Security\PrivateCA\V1\CertificateTemplate $var - * @return $this - */ - public function setCertificateTemplate($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\CertificateTemplate::class); - $this->certificate_template = $var; - - return $this; - } - - /** - * Required. A list of fields to be updated in this request. - * - * 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. A list of fields to be updated in this request. - * - * 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; - } - - /** - * Optional. An 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 = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. An 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 = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { - * @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/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/X509Extension.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/X509Extension.php deleted file mode 100644 index c98cc052fe79..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/X509Extension.php +++ /dev/null @@ -1,155 +0,0 @@ -google.cloud.security.privateca.v1.X509Extension - */ -class X509Extension extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The OID for this X.509 extension. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.ObjectId object_id = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $object_id = null; - /** - * Optional. Indicates whether or not this extension is critical (i.e., if the - * client does not know how to handle this extension, the client should - * consider this to be an error). - * - * Generated from protobuf field bool critical = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $critical = false; - /** - * Required. The value of this X.509 extension. - * - * Generated from protobuf field bytes value = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $value = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Security\PrivateCA\V1\ObjectId $object_id - * Required. The OID for this X.509 extension. - * @type bool $critical - * Optional. Indicates whether or not this extension is critical (i.e., if the - * client does not know how to handle this extension, the client should - * consider this to be an error). - * @type string $value - * Required. The value of this X.509 extension. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * Required. The OID for this X.509 extension. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.ObjectId object_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Security\PrivateCA\V1\ObjectId|null - */ - public function getObjectId() - { - return $this->object_id; - } - - public function hasObjectId() - { - return isset($this->object_id); - } - - public function clearObjectId() - { - unset($this->object_id); - } - - /** - * Required. The OID for this X.509 extension. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.ObjectId object_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Security\PrivateCA\V1\ObjectId $var - * @return $this - */ - public function setObjectId($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\ObjectId::class); - $this->object_id = $var; - - return $this; - } - - /** - * Optional. Indicates whether or not this extension is critical (i.e., if the - * client does not know how to handle this extension, the client should - * consider this to be an error). - * - * Generated from protobuf field bool critical = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getCritical() - { - return $this->critical; - } - - /** - * Optional. Indicates whether or not this extension is critical (i.e., if the - * client does not know how to handle this extension, the client should - * consider this to be an error). - * - * Generated from protobuf field bool critical = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param bool $var - * @return $this - */ - public function setCritical($var) - { - GPBUtil::checkBool($var); - $this->critical = $var; - - return $this; - } - - /** - * Required. The value of this X.509 extension. - * - * Generated from protobuf field bytes value = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getValue() - { - return $this->value; - } - - /** - * Required. The value of this X.509 extension. - * - * Generated from protobuf field bytes value = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setValue($var) - { - GPBUtil::checkString($var, False); - $this->value = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/X509Parameters.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/X509Parameters.php deleted file mode 100644 index a8abd4b0a953..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/X509Parameters.php +++ /dev/null @@ -1,302 +0,0 @@ -google.cloud.security.privateca.v1.X509Parameters - */ -class X509Parameters extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. Indicates the intended use for keys that correspond to a - * certificate. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.KeyUsage key_usage = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $key_usage = null; - /** - * Optional. Describes options in this - * [X509Parameters][google.cloud.security.privateca.v1.X509Parameters] that - * are relevant in a CA certificate. If not specified, a default basic - * constraints extension with `is_ca=false` will be added for leaf - * certificates. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.X509Parameters.CaOptions ca_options = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $ca_options = null; - /** - * Optional. Describes the X.509 certificate policy object identifiers, per - * https://tools.ietf.org/html/rfc5280#section-4.2.1.4. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.ObjectId policy_ids = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $policy_ids; - /** - * Optional. Describes Online Certificate Status Protocol (OCSP) endpoint - * addresses that appear in the "Authority Information Access" extension in - * the certificate. - * - * Generated from protobuf field repeated string aia_ocsp_servers = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $aia_ocsp_servers; - /** - * Optional. Describes the X.509 name constraints extension. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.X509Parameters.NameConstraints name_constraints = 6 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $name_constraints = null; - /** - * Optional. Describes custom X.509 extensions. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.X509Extension additional_extensions = 5 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $additional_extensions; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Security\PrivateCA\V1\KeyUsage $key_usage - * Optional. Indicates the intended use for keys that correspond to a - * certificate. - * @type \Google\Cloud\Security\PrivateCA\V1\X509Parameters\CaOptions $ca_options - * Optional. Describes options in this - * [X509Parameters][google.cloud.security.privateca.v1.X509Parameters] that - * are relevant in a CA certificate. If not specified, a default basic - * constraints extension with `is_ca=false` will be added for leaf - * certificates. - * @type \Google\Cloud\Security\PrivateCA\V1\ObjectId[] $policy_ids - * Optional. Describes the X.509 certificate policy object identifiers, per - * https://tools.ietf.org/html/rfc5280#section-4.2.1.4. - * @type string[] $aia_ocsp_servers - * Optional. Describes Online Certificate Status Protocol (OCSP) endpoint - * addresses that appear in the "Authority Information Access" extension in - * the certificate. - * @type \Google\Cloud\Security\PrivateCA\V1\X509Parameters\NameConstraints $name_constraints - * Optional. Describes the X.509 name constraints extension. - * @type \Google\Cloud\Security\PrivateCA\V1\X509Extension[] $additional_extensions - * Optional. Describes custom X.509 extensions. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * Optional. Indicates the intended use for keys that correspond to a - * certificate. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.KeyUsage key_usage = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\Security\PrivateCA\V1\KeyUsage|null - */ - public function getKeyUsage() - { - return $this->key_usage; - } - - public function hasKeyUsage() - { - return isset($this->key_usage); - } - - public function clearKeyUsage() - { - unset($this->key_usage); - } - - /** - * Optional. Indicates the intended use for keys that correspond to a - * certificate. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.KeyUsage key_usage = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\Security\PrivateCA\V1\KeyUsage $var - * @return $this - */ - public function setKeyUsage($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\KeyUsage::class); - $this->key_usage = $var; - - return $this; - } - - /** - * Optional. Describes options in this - * [X509Parameters][google.cloud.security.privateca.v1.X509Parameters] that - * are relevant in a CA certificate. If not specified, a default basic - * constraints extension with `is_ca=false` will be added for leaf - * certificates. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.X509Parameters.CaOptions ca_options = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\Security\PrivateCA\V1\X509Parameters\CaOptions|null - */ - public function getCaOptions() - { - return $this->ca_options; - } - - public function hasCaOptions() - { - return isset($this->ca_options); - } - - public function clearCaOptions() - { - unset($this->ca_options); - } - - /** - * Optional. Describes options in this - * [X509Parameters][google.cloud.security.privateca.v1.X509Parameters] that - * are relevant in a CA certificate. If not specified, a default basic - * constraints extension with `is_ca=false` will be added for leaf - * certificates. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.X509Parameters.CaOptions ca_options = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\Security\PrivateCA\V1\X509Parameters\CaOptions $var - * @return $this - */ - public function setCaOptions($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\X509Parameters\CaOptions::class); - $this->ca_options = $var; - - return $this; - } - - /** - * Optional. Describes the X.509 certificate policy object identifiers, per - * https://tools.ietf.org/html/rfc5280#section-4.2.1.4. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.ObjectId policy_ids = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return RepeatedField<\Google\Cloud\Security\PrivateCA\V1\ObjectId> - */ - public function getPolicyIds() - { - return $this->policy_ids; - } - - /** - * Optional. Describes the X.509 certificate policy object identifiers, per - * https://tools.ietf.org/html/rfc5280#section-4.2.1.4. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.ObjectId policy_ids = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\Security\PrivateCA\V1\ObjectId[] $var - * @return $this - */ - public function setPolicyIds($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Security\PrivateCA\V1\ObjectId::class); - $this->policy_ids = $arr; - - return $this; - } - - /** - * Optional. Describes Online Certificate Status Protocol (OCSP) endpoint - * addresses that appear in the "Authority Information Access" extension in - * the certificate. - * - * Generated from protobuf field repeated string aia_ocsp_servers = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return RepeatedField - */ - public function getAiaOcspServers() - { - return $this->aia_ocsp_servers; - } - - /** - * Optional. Describes Online Certificate Status Protocol (OCSP) endpoint - * addresses that appear in the "Authority Information Access" extension in - * the certificate. - * - * Generated from protobuf field repeated string aia_ocsp_servers = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param string[] $var - * @return $this - */ - public function setAiaOcspServers($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->aia_ocsp_servers = $arr; - - return $this; - } - - /** - * Optional. Describes the X.509 name constraints extension. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.X509Parameters.NameConstraints name_constraints = 6 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\Security\PrivateCA\V1\X509Parameters\NameConstraints|null - */ - public function getNameConstraints() - { - return $this->name_constraints; - } - - public function hasNameConstraints() - { - return isset($this->name_constraints); - } - - public function clearNameConstraints() - { - unset($this->name_constraints); - } - - /** - * Optional. Describes the X.509 name constraints extension. - * - * Generated from protobuf field .google.cloud.security.privateca.v1.X509Parameters.NameConstraints name_constraints = 6 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\Security\PrivateCA\V1\X509Parameters\NameConstraints $var - * @return $this - */ - public function setNameConstraints($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Security\PrivateCA\V1\X509Parameters\NameConstraints::class); - $this->name_constraints = $var; - - return $this; - } - - /** - * Optional. Describes custom X.509 extensions. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.X509Extension additional_extensions = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return RepeatedField<\Google\Cloud\Security\PrivateCA\V1\X509Extension> - */ - public function getAdditionalExtensions() - { - return $this->additional_extensions; - } - - /** - * Optional. Describes custom X.509 extensions. - * - * Generated from protobuf field repeated .google.cloud.security.privateca.v1.X509Extension additional_extensions = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\Security\PrivateCA\V1\X509Extension[] $var - * @return $this - */ - public function setAdditionalExtensions($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Security\PrivateCA\V1\X509Extension::class); - $this->additional_extensions = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/X509Parameters/CaOptions.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/X509Parameters/CaOptions.php deleted file mode 100644 index 8fc67a2a4d60..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/X509Parameters/CaOptions.php +++ /dev/null @@ -1,146 +0,0 @@ -google.cloud.security.privateca.v1.X509Parameters.CaOptions - */ -class CaOptions extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. Refers to the "CA" boolean field in the X.509 extension. - * When this value is missing, the basic constraints extension will be - * omitted from the certificate. - * - * Generated from protobuf field optional bool is_ca = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $is_ca = null; - /** - * Optional. Refers to the path length constraint field in the X.509 - * extension. For a CA certificate, this value describes the depth of - * subordinate CA certificates that are allowed. If this value is less than - * 0, the request will fail. If this value is missing, the max path length - * will be omitted from the certificate. - * - * Generated from protobuf field optional int32 max_issuer_path_length = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $max_issuer_path_length = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type bool $is_ca - * Optional. Refers to the "CA" boolean field in the X.509 extension. - * When this value is missing, the basic constraints extension will be - * omitted from the certificate. - * @type int $max_issuer_path_length - * Optional. Refers to the path length constraint field in the X.509 - * extension. For a CA certificate, this value describes the depth of - * subordinate CA certificates that are allowed. If this value is less than - * 0, the request will fail. If this value is missing, the max path length - * will be omitted from the certificate. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * Optional. Refers to the "CA" boolean field in the X.509 extension. - * When this value is missing, the basic constraints extension will be - * omitted from the certificate. - * - * Generated from protobuf field optional bool is_ca = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getIsCa() - { - return isset($this->is_ca) ? $this->is_ca : false; - } - - public function hasIsCa() - { - return isset($this->is_ca); - } - - public function clearIsCa() - { - unset($this->is_ca); - } - - /** - * Optional. Refers to the "CA" boolean field in the X.509 extension. - * When this value is missing, the basic constraints extension will be - * omitted from the certificate. - * - * Generated from protobuf field optional bool is_ca = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @param bool $var - * @return $this - */ - public function setIsCa($var) - { - GPBUtil::checkBool($var); - $this->is_ca = $var; - - return $this; - } - - /** - * Optional. Refers to the path length constraint field in the X.509 - * extension. For a CA certificate, this value describes the depth of - * subordinate CA certificates that are allowed. If this value is less than - * 0, the request will fail. If this value is missing, the max path length - * will be omitted from the certificate. - * - * Generated from protobuf field optional int32 max_issuer_path_length = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getMaxIssuerPathLength() - { - return isset($this->max_issuer_path_length) ? $this->max_issuer_path_length : 0; - } - - public function hasMaxIssuerPathLength() - { - return isset($this->max_issuer_path_length); - } - - public function clearMaxIssuerPathLength() - { - unset($this->max_issuer_path_length); - } - - /** - * Optional. Refers to the path length constraint field in the X.509 - * extension. For a CA certificate, this value describes the depth of - * subordinate CA certificates that are allowed. If this value is less than - * 0, the request will fail. If this value is missing, the max path length - * will be omitted from the certificate. - * - * Generated from protobuf field optional int32 max_issuer_path_length = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setMaxIssuerPathLength($var) - { - GPBUtil::checkInt32($var); - $this->max_issuer_path_length = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/X509Parameters/NameConstraints.php b/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/X509Parameters/NameConstraints.php deleted file mode 100644 index 0c345c079fd1..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/proto/src/Google/Cloud/Security/PrivateCA/V1/X509Parameters/NameConstraints.php +++ /dev/null @@ -1,436 +0,0 @@ -google.cloud.security.privateca.v1.X509Parameters.NameConstraints - */ -class NameConstraints extends \Google\Protobuf\Internal\Message -{ - /** - * Indicates whether or not the name constraints are marked critical. - * - * Generated from protobuf field bool critical = 1; - */ - protected $critical = false; - /** - * Contains permitted DNS names. Any DNS name that can be - * constructed by simply adding zero or more labels to - * the left-hand side of the name satisfies the name constraint. - * For example, `example.com`, `www.example.com`, `www.sub.example.com` - * would satisfy `example.com` while `example1.com` does not. - * - * Generated from protobuf field repeated string permitted_dns_names = 2; - */ - private $permitted_dns_names; - /** - * Contains excluded DNS names. Any DNS name that can be - * constructed by simply adding zero or more labels to - * the left-hand side of the name satisfies the name constraint. - * For example, `example.com`, `www.example.com`, `www.sub.example.com` - * would satisfy `example.com` while `example1.com` does not. - * - * Generated from protobuf field repeated string excluded_dns_names = 3; - */ - private $excluded_dns_names; - /** - * Contains the permitted IP ranges. For IPv4 addresses, the ranges - * are expressed using CIDR notation as specified in RFC 4632. - * For IPv6 addresses, the ranges are expressed in similar encoding as IPv4 - * addresses. - * - * Generated from protobuf field repeated string permitted_ip_ranges = 4; - */ - private $permitted_ip_ranges; - /** - * Contains the excluded IP ranges. For IPv4 addresses, the ranges - * are expressed using CIDR notation as specified in RFC 4632. - * For IPv6 addresses, the ranges are expressed in similar encoding as IPv4 - * addresses. - * - * Generated from protobuf field repeated string excluded_ip_ranges = 5; - */ - private $excluded_ip_ranges; - /** - * Contains the permitted email addresses. The value can be a particular - * email address, a hostname to indicate all email addresses on that host or - * a domain with a leading period (e.g. `.example.com`) to indicate - * all email addresses in that domain. - * - * Generated from protobuf field repeated string permitted_email_addresses = 6; - */ - private $permitted_email_addresses; - /** - * Contains the excluded email addresses. The value can be a particular - * email address, a hostname to indicate all email addresses on that host or - * a domain with a leading period (e.g. `.example.com`) to indicate - * all email addresses in that domain. - * - * Generated from protobuf field repeated string excluded_email_addresses = 7; - */ - private $excluded_email_addresses; - /** - * Contains the permitted URIs that apply to the host part of the name. - * The value can be a hostname or a domain with a - * leading period (like `.example.com`) - * - * Generated from protobuf field repeated string permitted_uris = 8; - */ - private $permitted_uris; - /** - * Contains the excluded URIs that apply to the host part of the name. - * The value can be a hostname or a domain with a - * leading period (like `.example.com`) - * - * Generated from protobuf field repeated string excluded_uris = 9; - */ - private $excluded_uris; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type bool $critical - * Indicates whether or not the name constraints are marked critical. - * @type string[] $permitted_dns_names - * Contains permitted DNS names. Any DNS name that can be - * constructed by simply adding zero or more labels to - * the left-hand side of the name satisfies the name constraint. - * For example, `example.com`, `www.example.com`, `www.sub.example.com` - * would satisfy `example.com` while `example1.com` does not. - * @type string[] $excluded_dns_names - * Contains excluded DNS names. Any DNS name that can be - * constructed by simply adding zero or more labels to - * the left-hand side of the name satisfies the name constraint. - * For example, `example.com`, `www.example.com`, `www.sub.example.com` - * would satisfy `example.com` while `example1.com` does not. - * @type string[] $permitted_ip_ranges - * Contains the permitted IP ranges. For IPv4 addresses, the ranges - * are expressed using CIDR notation as specified in RFC 4632. - * For IPv6 addresses, the ranges are expressed in similar encoding as IPv4 - * addresses. - * @type string[] $excluded_ip_ranges - * Contains the excluded IP ranges. For IPv4 addresses, the ranges - * are expressed using CIDR notation as specified in RFC 4632. - * For IPv6 addresses, the ranges are expressed in similar encoding as IPv4 - * addresses. - * @type string[] $permitted_email_addresses - * Contains the permitted email addresses. The value can be a particular - * email address, a hostname to indicate all email addresses on that host or - * a domain with a leading period (e.g. `.example.com`) to indicate - * all email addresses in that domain. - * @type string[] $excluded_email_addresses - * Contains the excluded email addresses. The value can be a particular - * email address, a hostname to indicate all email addresses on that host or - * a domain with a leading period (e.g. `.example.com`) to indicate - * all email addresses in that domain. - * @type string[] $permitted_uris - * Contains the permitted URIs that apply to the host part of the name. - * The value can be a hostname or a domain with a - * leading period (like `.example.com`) - * @type string[] $excluded_uris - * Contains the excluded URIs that apply to the host part of the name. - * The value can be a hostname or a domain with a - * leading period (like `.example.com`) - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Security\Privateca\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * Indicates whether or not the name constraints are marked critical. - * - * Generated from protobuf field bool critical = 1; - * @return bool - */ - public function getCritical() - { - return $this->critical; - } - - /** - * Indicates whether or not the name constraints are marked critical. - * - * Generated from protobuf field bool critical = 1; - * @param bool $var - * @return $this - */ - public function setCritical($var) - { - GPBUtil::checkBool($var); - $this->critical = $var; - - return $this; - } - - /** - * Contains permitted DNS names. Any DNS name that can be - * constructed by simply adding zero or more labels to - * the left-hand side of the name satisfies the name constraint. - * For example, `example.com`, `www.example.com`, `www.sub.example.com` - * would satisfy `example.com` while `example1.com` does not. - * - * Generated from protobuf field repeated string permitted_dns_names = 2; - * @return RepeatedField - */ - public function getPermittedDnsNames() - { - return $this->permitted_dns_names; - } - - /** - * Contains permitted DNS names. Any DNS name that can be - * constructed by simply adding zero or more labels to - * the left-hand side of the name satisfies the name constraint. - * For example, `example.com`, `www.example.com`, `www.sub.example.com` - * would satisfy `example.com` while `example1.com` does not. - * - * Generated from protobuf field repeated string permitted_dns_names = 2; - * @param string[] $var - * @return $this - */ - public function setPermittedDnsNames($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->permitted_dns_names = $arr; - - return $this; - } - - /** - * Contains excluded DNS names. Any DNS name that can be - * constructed by simply adding zero or more labels to - * the left-hand side of the name satisfies the name constraint. - * For example, `example.com`, `www.example.com`, `www.sub.example.com` - * would satisfy `example.com` while `example1.com` does not. - * - * Generated from protobuf field repeated string excluded_dns_names = 3; - * @return RepeatedField - */ - public function getExcludedDnsNames() - { - return $this->excluded_dns_names; - } - - /** - * Contains excluded DNS names. Any DNS name that can be - * constructed by simply adding zero or more labels to - * the left-hand side of the name satisfies the name constraint. - * For example, `example.com`, `www.example.com`, `www.sub.example.com` - * would satisfy `example.com` while `example1.com` does not. - * - * Generated from protobuf field repeated string excluded_dns_names = 3; - * @param string[] $var - * @return $this - */ - public function setExcludedDnsNames($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->excluded_dns_names = $arr; - - return $this; - } - - /** - * Contains the permitted IP ranges. For IPv4 addresses, the ranges - * are expressed using CIDR notation as specified in RFC 4632. - * For IPv6 addresses, the ranges are expressed in similar encoding as IPv4 - * addresses. - * - * Generated from protobuf field repeated string permitted_ip_ranges = 4; - * @return RepeatedField - */ - public function getPermittedIpRanges() - { - return $this->permitted_ip_ranges; - } - - /** - * Contains the permitted IP ranges. For IPv4 addresses, the ranges - * are expressed using CIDR notation as specified in RFC 4632. - * For IPv6 addresses, the ranges are expressed in similar encoding as IPv4 - * addresses. - * - * Generated from protobuf field repeated string permitted_ip_ranges = 4; - * @param string[] $var - * @return $this - */ - public function setPermittedIpRanges($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->permitted_ip_ranges = $arr; - - return $this; - } - - /** - * Contains the excluded IP ranges. For IPv4 addresses, the ranges - * are expressed using CIDR notation as specified in RFC 4632. - * For IPv6 addresses, the ranges are expressed in similar encoding as IPv4 - * addresses. - * - * Generated from protobuf field repeated string excluded_ip_ranges = 5; - * @return RepeatedField - */ - public function getExcludedIpRanges() - { - return $this->excluded_ip_ranges; - } - - /** - * Contains the excluded IP ranges. For IPv4 addresses, the ranges - * are expressed using CIDR notation as specified in RFC 4632. - * For IPv6 addresses, the ranges are expressed in similar encoding as IPv4 - * addresses. - * - * Generated from protobuf field repeated string excluded_ip_ranges = 5; - * @param string[] $var - * @return $this - */ - public function setExcludedIpRanges($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->excluded_ip_ranges = $arr; - - return $this; - } - - /** - * Contains the permitted email addresses. The value can be a particular - * email address, a hostname to indicate all email addresses on that host or - * a domain with a leading period (e.g. `.example.com`) to indicate - * all email addresses in that domain. - * - * Generated from protobuf field repeated string permitted_email_addresses = 6; - * @return RepeatedField - */ - public function getPermittedEmailAddresses() - { - return $this->permitted_email_addresses; - } - - /** - * Contains the permitted email addresses. The value can be a particular - * email address, a hostname to indicate all email addresses on that host or - * a domain with a leading period (e.g. `.example.com`) to indicate - * all email addresses in that domain. - * - * Generated from protobuf field repeated string permitted_email_addresses = 6; - * @param string[] $var - * @return $this - */ - public function setPermittedEmailAddresses($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->permitted_email_addresses = $arr; - - return $this; - } - - /** - * Contains the excluded email addresses. The value can be a particular - * email address, a hostname to indicate all email addresses on that host or - * a domain with a leading period (e.g. `.example.com`) to indicate - * all email addresses in that domain. - * - * Generated from protobuf field repeated string excluded_email_addresses = 7; - * @return RepeatedField - */ - public function getExcludedEmailAddresses() - { - return $this->excluded_email_addresses; - } - - /** - * Contains the excluded email addresses. The value can be a particular - * email address, a hostname to indicate all email addresses on that host or - * a domain with a leading period (e.g. `.example.com`) to indicate - * all email addresses in that domain. - * - * Generated from protobuf field repeated string excluded_email_addresses = 7; - * @param string[] $var - * @return $this - */ - public function setExcludedEmailAddresses($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->excluded_email_addresses = $arr; - - return $this; - } - - /** - * Contains the permitted URIs that apply to the host part of the name. - * The value can be a hostname or a domain with a - * leading period (like `.example.com`) - * - * Generated from protobuf field repeated string permitted_uris = 8; - * @return RepeatedField - */ - public function getPermittedUris() - { - return $this->permitted_uris; - } - - /** - * Contains the permitted URIs that apply to the host part of the name. - * The value can be a hostname or a domain with a - * leading period (like `.example.com`) - * - * Generated from protobuf field repeated string permitted_uris = 8; - * @param string[] $var - * @return $this - */ - public function setPermittedUris($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->permitted_uris = $arr; - - return $this; - } - - /** - * Contains the excluded URIs that apply to the host part of the name. - * The value can be a hostname or a domain with a - * leading period (like `.example.com`) - * - * Generated from protobuf field repeated string excluded_uris = 9; - * @return RepeatedField - */ - public function getExcludedUris() - { - return $this->excluded_uris; - } - - /** - * Contains the excluded URIs that apply to the host part of the name. - * The value can be a hostname or a domain with a - * leading period (like `.example.com`) - * - * Generated from protobuf field repeated string excluded_uris = 9; - * @param string[] $var - * @return $this - */ - public function setExcludedUris($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->excluded_uris = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/activate_certificate_authority.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/activate_certificate_authority.php deleted file mode 100644 index bbe081a50003..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/activate_certificate_authority.php +++ /dev/null @@ -1,128 +0,0 @@ -setCertificateAuthority($formattedSubordinateConfigCertificateAuthority); - $request = (new ActivateCertificateAuthorityRequest()) - ->setName($formattedName) - ->setPemCaCertificate($pemCaCertificate) - ->setSubordinateConfig($subordinateConfig); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $certificateAuthorityServiceClient->activateCertificateAuthority($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var CertificateAuthority $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 = CertificateAuthorityServiceClient::certificateAuthorityName( - '[PROJECT]', - '[LOCATION]', - '[CA_POOL]', - '[CERTIFICATE_AUTHORITY]' - ); - $pemCaCertificate = '[PEM_CA_CERTIFICATE]'; - $formattedSubordinateConfigCertificateAuthority = CertificateAuthorityServiceClient::certificateAuthorityName( - '[PROJECT]', - '[LOCATION]', - '[CA_POOL]', - '[CERTIFICATE_AUTHORITY]' - ); - - activate_certificate_authority_sample( - $formattedName, - $pemCaCertificate, - $formattedSubordinateConfigCertificateAuthority - ); -} -// [END privateca_v1_generated_CertificateAuthorityService_ActivateCertificateAuthority_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/create_ca_pool.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/create_ca_pool.php deleted file mode 100644 index 4f9f6a31dfa8..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/create_ca_pool.php +++ /dev/null @@ -1,97 +0,0 @@ -setTier($caPoolTier); - $request = (new CreateCaPoolRequest()) - ->setParent($formattedParent) - ->setCaPoolId($caPoolId) - ->setCaPool($caPool); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $certificateAuthorityServiceClient->createCaPool($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var CaPool $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 = CertificateAuthorityServiceClient::locationName('[PROJECT]', '[LOCATION]'); - $caPoolId = '[CA_POOL_ID]'; - $caPoolTier = Tier::TIER_UNSPECIFIED; - - create_ca_pool_sample($formattedParent, $caPoolId, $caPoolTier); -} -// [END privateca_v1_generated_CertificateAuthorityService_CreateCaPool_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/create_certificate.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/create_certificate.php deleted file mode 100644 index 88eebe7166b1..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/create_certificate.php +++ /dev/null @@ -1,85 +0,0 @@ -setLifetime($certificateLifetime); - $request = (new CreateCertificateRequest()) - ->setParent($formattedParent) - ->setCertificate($certificate); - - // Call the API and handle any network failures. - try { - /** @var Certificate $response */ - $response = $certificateAuthorityServiceClient->createCertificate($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 = CertificateAuthorityServiceClient::caPoolName( - '[PROJECT]', - '[LOCATION]', - '[CA_POOL]' - ); - - create_certificate_sample($formattedParent); -} -// [END privateca_v1_generated_CertificateAuthorityService_CreateCertificate_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/create_certificate_authority.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/create_certificate_authority.php deleted file mode 100644 index 22be6b3dbb58..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/create_certificate_authority.php +++ /dev/null @@ -1,127 +0,0 @@ -setSubjectConfig($certificateAuthorityConfigSubjectConfig) - ->setX509Config($certificateAuthorityConfigX509Config); - $certificateAuthorityLifetime = new Duration(); - $certificateAuthorityKeySpec = new KeyVersionSpec(); - $certificateAuthority = (new CertificateAuthority()) - ->setType($certificateAuthorityType) - ->setConfig($certificateAuthorityConfig) - ->setLifetime($certificateAuthorityLifetime) - ->setKeySpec($certificateAuthorityKeySpec); - $request = (new CreateCertificateAuthorityRequest()) - ->setParent($formattedParent) - ->setCertificateAuthorityId($certificateAuthorityId) - ->setCertificateAuthority($certificateAuthority); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $certificateAuthorityServiceClient->createCertificateAuthority($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var CertificateAuthority $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 = CertificateAuthorityServiceClient::caPoolName( - '[PROJECT]', - '[LOCATION]', - '[CA_POOL]' - ); - $certificateAuthorityId = '[CERTIFICATE_AUTHORITY_ID]'; - $certificateAuthorityType = Type::TYPE_UNSPECIFIED; - - create_certificate_authority_sample( - $formattedParent, - $certificateAuthorityId, - $certificateAuthorityType - ); -} -// [END privateca_v1_generated_CertificateAuthorityService_CreateCertificateAuthority_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/create_certificate_template.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/create_certificate_template.php deleted file mode 100644 index a4199c133d95..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/create_certificate_template.php +++ /dev/null @@ -1,95 +0,0 @@ -setParent($formattedParent) - ->setCertificateTemplateId($certificateTemplateId) - ->setCertificateTemplate($certificateTemplate); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $certificateAuthorityServiceClient->createCertificateTemplate($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var CertificateTemplate $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 = CertificateAuthorityServiceClient::locationName('[PROJECT]', '[LOCATION]'); - $certificateTemplateId = '[CERTIFICATE_TEMPLATE_ID]'; - - create_certificate_template_sample($formattedParent, $certificateTemplateId); -} -// [END privateca_v1_generated_CertificateAuthorityService_CreateCertificateTemplate_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/delete_ca_pool.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/delete_ca_pool.php deleted file mode 100644 index 5d64cb64a4a2..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/delete_ca_pool.php +++ /dev/null @@ -1,86 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $certificateAuthorityServiceClient->deleteCaPool($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 = CertificateAuthorityServiceClient::caPoolName( - '[PROJECT]', - '[LOCATION]', - '[CA_POOL]' - ); - - delete_ca_pool_sample($formattedName); -} -// [END privateca_v1_generated_CertificateAuthorityService_DeleteCaPool_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/delete_certificate_authority.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/delete_certificate_authority.php deleted file mode 100644 index c36222e28a75..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/delete_certificate_authority.php +++ /dev/null @@ -1,91 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $certificateAuthorityServiceClient->deleteCertificateAuthority($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var CertificateAuthority $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 = CertificateAuthorityServiceClient::certificateAuthorityName( - '[PROJECT]', - '[LOCATION]', - '[CA_POOL]', - '[CERTIFICATE_AUTHORITY]' - ); - - delete_certificate_authority_sample($formattedName); -} -// [END privateca_v1_generated_CertificateAuthorityService_DeleteCertificateAuthority_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/delete_certificate_template.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/delete_certificate_template.php deleted file mode 100644 index 66874aad02dc..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/delete_certificate_template.php +++ /dev/null @@ -1,87 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $certificateAuthorityServiceClient->deleteCertificateTemplate($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 = CertificateAuthorityServiceClient::certificateTemplateName( - '[PROJECT]', - '[LOCATION]', - '[CERTIFICATE_TEMPLATE]' - ); - - delete_certificate_template_sample($formattedName); -} -// [END privateca_v1_generated_CertificateAuthorityService_DeleteCertificateTemplate_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/disable_certificate_authority.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/disable_certificate_authority.php deleted file mode 100644 index 630c57d7917d..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/disable_certificate_authority.php +++ /dev/null @@ -1,91 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $certificateAuthorityServiceClient->disableCertificateAuthority($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var CertificateAuthority $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 = CertificateAuthorityServiceClient::certificateAuthorityName( - '[PROJECT]', - '[LOCATION]', - '[CA_POOL]', - '[CERTIFICATE_AUTHORITY]' - ); - - disable_certificate_authority_sample($formattedName); -} -// [END privateca_v1_generated_CertificateAuthorityService_DisableCertificateAuthority_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/enable_certificate_authority.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/enable_certificate_authority.php deleted file mode 100644 index 6b04124f2d7d..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/enable_certificate_authority.php +++ /dev/null @@ -1,91 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $certificateAuthorityServiceClient->enableCertificateAuthority($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var CertificateAuthority $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 = CertificateAuthorityServiceClient::certificateAuthorityName( - '[PROJECT]', - '[LOCATION]', - '[CA_POOL]', - '[CERTIFICATE_AUTHORITY]' - ); - - enable_certificate_authority_sample($formattedName); -} -// [END privateca_v1_generated_CertificateAuthorityService_EnableCertificateAuthority_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/fetch_ca_certs.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/fetch_ca_certs.php deleted file mode 100644 index 148de8af991d..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/fetch_ca_certs.php +++ /dev/null @@ -1,80 +0,0 @@ -setCaPool($formattedCaPool); - - // Call the API and handle any network failures. - try { - /** @var FetchCaCertsResponse $response */ - $response = $certificateAuthorityServiceClient->fetchCaCerts($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 -{ - $formattedCaPool = CertificateAuthorityServiceClient::caPoolName( - '[PROJECT]', - '[LOCATION]', - '[CA_POOL]' - ); - - fetch_ca_certs_sample($formattedCaPool); -} -// [END privateca_v1_generated_CertificateAuthorityService_FetchCaCerts_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/fetch_certificate_authority_csr.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/fetch_certificate_authority_csr.php deleted file mode 100644 index c864a03ebab3..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/fetch_certificate_authority_csr.php +++ /dev/null @@ -1,88 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var FetchCertificateAuthorityCsrResponse $response */ - $response = $certificateAuthorityServiceClient->fetchCertificateAuthorityCsr($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 = CertificateAuthorityServiceClient::certificateAuthorityName( - '[PROJECT]', - '[LOCATION]', - '[CA_POOL]', - '[CERTIFICATE_AUTHORITY]' - ); - - fetch_certificate_authority_csr_sample($formattedName); -} -// [END privateca_v1_generated_CertificateAuthorityService_FetchCertificateAuthorityCsr_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_ca_pool.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_ca_pool.php deleted file mode 100644 index d3dfe53a73b8..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_ca_pool.php +++ /dev/null @@ -1,76 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var CaPool $response */ - $response = $certificateAuthorityServiceClient->getCaPool($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 = CertificateAuthorityServiceClient::caPoolName( - '[PROJECT]', - '[LOCATION]', - '[CA_POOL]' - ); - - get_ca_pool_sample($formattedName); -} -// [END privateca_v1_generated_CertificateAuthorityService_GetCaPool_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_certificate.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_certificate.php deleted file mode 100644 index 0065f8f3dbf2..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_certificate.php +++ /dev/null @@ -1,78 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var Certificate $response */ - $response = $certificateAuthorityServiceClient->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 = CertificateAuthorityServiceClient::certificateName( - '[PROJECT]', - '[LOCATION]', - '[CA_POOL]', - '[CERTIFICATE]' - ); - - get_certificate_sample($formattedName); -} -// [END privateca_v1_generated_CertificateAuthorityService_GetCertificate_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_certificate_authority.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_certificate_authority.php deleted file mode 100644 index cadbdad5326d..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_certificate_authority.php +++ /dev/null @@ -1,80 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var CertificateAuthority $response */ - $response = $certificateAuthorityServiceClient->getCertificateAuthority($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 = CertificateAuthorityServiceClient::certificateAuthorityName( - '[PROJECT]', - '[LOCATION]', - '[CA_POOL]', - '[CERTIFICATE_AUTHORITY]' - ); - - get_certificate_authority_sample($formattedName); -} -// [END privateca_v1_generated_CertificateAuthorityService_GetCertificateAuthority_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_certificate_revocation_list.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_certificate_revocation_list.php deleted file mode 100644 index 8594ccb9e376..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_certificate_revocation_list.php +++ /dev/null @@ -1,82 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var CertificateRevocationList $response */ - $response = $certificateAuthorityServiceClient->getCertificateRevocationList($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 = CertificateAuthorityServiceClient::certificateRevocationListName( - '[PROJECT]', - '[LOCATION]', - '[CA_POOL]', - '[CERTIFICATE_AUTHORITY]', - '[CERTIFICATE_REVOCATION_LIST]' - ); - - get_certificate_revocation_list_sample($formattedName); -} -// [END privateca_v1_generated_CertificateAuthorityService_GetCertificateRevocationList_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_certificate_template.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_certificate_template.php deleted file mode 100644 index ca69b6075b2f..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_certificate_template.php +++ /dev/null @@ -1,79 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var CertificateTemplate $response */ - $response = $certificateAuthorityServiceClient->getCertificateTemplate($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 = CertificateAuthorityServiceClient::certificateTemplateName( - '[PROJECT]', - '[LOCATION]', - '[CERTIFICATE_TEMPLATE]' - ); - - get_certificate_template_sample($formattedName); -} -// [END privateca_v1_generated_CertificateAuthorityService_GetCertificateTemplate_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_iam_policy.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_iam_policy.php deleted file mode 100644 index a351034ccfea..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/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 = $certificateAuthorityServiceClient->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 privateca_v1_generated_CertificateAuthorityService_GetIamPolicy_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_location.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/get_location.php deleted file mode 100644 index 859895c3c110..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/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 privateca_v1_generated_CertificateAuthorityService_GetLocation_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_ca_pools.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_ca_pools.php deleted file mode 100644 index f25f9de28afe..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_ca_pools.php +++ /dev/null @@ -1,78 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $certificateAuthorityServiceClient->listCaPools($request); - - /** @var CaPool $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 = CertificateAuthorityServiceClient::locationName('[PROJECT]', '[LOCATION]'); - - list_ca_pools_sample($formattedParent); -} -// [END privateca_v1_generated_CertificateAuthorityService_ListCaPools_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_certificate_authorities.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_certificate_authorities.php deleted file mode 100644 index f65b8809fcb6..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_certificate_authorities.php +++ /dev/null @@ -1,84 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $certificateAuthorityServiceClient->listCertificateAuthorities($request); - - /** @var CertificateAuthority $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 = CertificateAuthorityServiceClient::caPoolName( - '[PROJECT]', - '[LOCATION]', - '[CA_POOL]' - ); - - list_certificate_authorities_sample($formattedParent); -} -// [END privateca_v1_generated_CertificateAuthorityService_ListCertificateAuthorities_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_certificate_revocation_lists.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_certificate_revocation_lists.php deleted file mode 100644 index a827a487d673..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_certificate_revocation_lists.php +++ /dev/null @@ -1,84 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $certificateAuthorityServiceClient->listCertificateRevocationLists($request); - - /** @var CertificateRevocationList $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 = CertificateAuthorityServiceClient::certificateAuthorityName( - '[PROJECT]', - '[LOCATION]', - '[CA_POOL]', - '[CERTIFICATE_AUTHORITY]' - ); - - list_certificate_revocation_lists_sample($formattedParent); -} -// [END privateca_v1_generated_CertificateAuthorityService_ListCertificateRevocationLists_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_certificate_templates.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_certificate_templates.php deleted file mode 100644 index 0a0c98aff194..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_certificate_templates.php +++ /dev/null @@ -1,79 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $certificateAuthorityServiceClient->listCertificateTemplates($request); - - /** @var CertificateTemplate $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 = CertificateAuthorityServiceClient::locationName('[PROJECT]', '[LOCATION]'); - - list_certificate_templates_sample($formattedParent); -} -// [END privateca_v1_generated_CertificateAuthorityService_ListCertificateTemplates_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_certificates.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_certificates.php deleted file mode 100644 index 9b665e39ff7f..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_certificates.php +++ /dev/null @@ -1,91 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $certificateAuthorityServiceClient->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 = CertificateAuthorityServiceClient::caPoolName( - '[PROJECT]', - '[LOCATION]', - '[CA_POOL]' - ); - - list_certificates_sample($formattedParent); -} -// [END privateca_v1_generated_CertificateAuthorityService_ListCertificates_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_locations.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_locations.php deleted file mode 100644 index 1c37b5ee6144..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/list_locations.php +++ /dev/null @@ -1,77 +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 privateca_v1_generated_CertificateAuthorityService_ListLocations_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/revoke_certificate.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/revoke_certificate.php deleted file mode 100644 index ecc9084de793..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/revoke_certificate.php +++ /dev/null @@ -1,84 +0,0 @@ -setName($formattedName) - ->setReason($reason); - - // Call the API and handle any network failures. - try { - /** @var Certificate $response */ - $response = $certificateAuthorityServiceClient->revokeCertificate($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 = CertificateAuthorityServiceClient::certificateName( - '[PROJECT]', - '[LOCATION]', - '[CA_POOL]', - '[CERTIFICATE]' - ); - $reason = RevocationReason::REVOCATION_REASON_UNSPECIFIED; - - revoke_certificate_sample($formattedName, $reason); -} -// [END privateca_v1_generated_CertificateAuthorityService_RevokeCertificate_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/set_iam_policy.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/set_iam_policy.php deleted file mode 100644 index 2146e5d72607..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/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 = $certificateAuthorityServiceClient->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 privateca_v1_generated_CertificateAuthorityService_SetIamPolicy_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/test_iam_permissions.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/test_iam_permissions.php deleted file mode 100644 index 0704d9f1d8f5..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/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 = $certificateAuthorityServiceClient->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 privateca_v1_generated_CertificateAuthorityService_TestIamPermissions_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/undelete_certificate_authority.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/undelete_certificate_authority.php deleted file mode 100644 index 62414a8d9e43..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/undelete_certificate_authority.php +++ /dev/null @@ -1,92 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $certificateAuthorityServiceClient->undeleteCertificateAuthority($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var CertificateAuthority $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 = CertificateAuthorityServiceClient::certificateAuthorityName( - '[PROJECT]', - '[LOCATION]', - '[CA_POOL]', - '[CERTIFICATE_AUTHORITY]' - ); - - undelete_certificate_authority_sample($formattedName); -} -// [END privateca_v1_generated_CertificateAuthorityService_UndeleteCertificateAuthority_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/update_ca_pool.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/update_ca_pool.php deleted file mode 100644 index 79adc4935636..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/update_ca_pool.php +++ /dev/null @@ -1,90 +0,0 @@ -setTier($caPoolTier); - $updateMask = new FieldMask(); - $request = (new UpdateCaPoolRequest()) - ->setCaPool($caPool) - ->setUpdateMask($updateMask); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $certificateAuthorityServiceClient->updateCaPool($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var CaPool $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 -{ - $caPoolTier = Tier::TIER_UNSPECIFIED; - - update_ca_pool_sample($caPoolTier); -} -// [END privateca_v1_generated_CertificateAuthorityService_UpdateCaPool_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/update_certificate.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/update_certificate.php deleted file mode 100644 index f6ca1bdab733..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/update_certificate.php +++ /dev/null @@ -1,67 +0,0 @@ -setLifetime($certificateLifetime); - $updateMask = new FieldMask(); - $request = (new UpdateCertificateRequest()) - ->setCertificate($certificate) - ->setUpdateMask($updateMask); - - // Call the API and handle any network failures. - try { - /** @var Certificate $response */ - $response = $certificateAuthorityServiceClient->updateCertificate($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END privateca_v1_generated_CertificateAuthorityService_UpdateCertificate_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/update_certificate_authority.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/update_certificate_authority.php deleted file mode 100644 index 3a7b6d267304..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/update_certificate_authority.php +++ /dev/null @@ -1,107 +0,0 @@ -setSubjectConfig($certificateAuthorityConfigSubjectConfig) - ->setX509Config($certificateAuthorityConfigX509Config); - $certificateAuthorityLifetime = new Duration(); - $certificateAuthorityKeySpec = new KeyVersionSpec(); - $certificateAuthority = (new CertificateAuthority()) - ->setType($certificateAuthorityType) - ->setConfig($certificateAuthorityConfig) - ->setLifetime($certificateAuthorityLifetime) - ->setKeySpec($certificateAuthorityKeySpec); - $updateMask = new FieldMask(); - $request = (new UpdateCertificateAuthorityRequest()) - ->setCertificateAuthority($certificateAuthority) - ->setUpdateMask($updateMask); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $certificateAuthorityServiceClient->updateCertificateAuthority($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var CertificateAuthority $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 -{ - $certificateAuthorityType = Type::TYPE_UNSPECIFIED; - - update_certificate_authority_sample($certificateAuthorityType); -} -// [END privateca_v1_generated_CertificateAuthorityService_UpdateCertificateAuthority_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/update_certificate_revocation_list.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/update_certificate_revocation_list.php deleted file mode 100644 index a9b831f1acd5..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/update_certificate_revocation_list.php +++ /dev/null @@ -1,75 +0,0 @@ -setCertificateRevocationList($certificateRevocationList) - ->setUpdateMask($updateMask); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $certificateAuthorityServiceClient->updateCertificateRevocationList($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var CertificateRevocationList $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 privateca_v1_generated_CertificateAuthorityService_UpdateCertificateRevocationList_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/update_certificate_template.php b/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/update_certificate_template.php deleted file mode 100644 index 6159afbf8fda..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/samples/V1/CertificateAuthorityServiceClient/update_certificate_template.php +++ /dev/null @@ -1,75 +0,0 @@ -setCertificateTemplate($certificateTemplate) - ->setUpdateMask($updateMask); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $certificateAuthorityServiceClient->updateCertificateTemplate($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var CertificateTemplate $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 privateca_v1_generated_CertificateAuthorityService_UpdateCertificateTemplate_sync] diff --git a/owl-bot-staging/SecurityPrivateCa/v1/src/V1/Client/CertificateAuthorityServiceClient.php b/owl-bot-staging/SecurityPrivateCa/v1/src/V1/Client/CertificateAuthorityServiceClient.php deleted file mode 100644 index ab68b4660fb5..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/src/V1/Client/CertificateAuthorityServiceClient.php +++ /dev/null @@ -1,1458 +0,0 @@ - activateCertificateAuthorityAsync(ActivateCertificateAuthorityRequest $request, array $optionalArgs = []) - * @method PromiseInterface createCaPoolAsync(CreateCaPoolRequest $request, array $optionalArgs = []) - * @method PromiseInterface createCertificateAsync(CreateCertificateRequest $request, array $optionalArgs = []) - * @method PromiseInterface createCertificateAuthorityAsync(CreateCertificateAuthorityRequest $request, array $optionalArgs = []) - * @method PromiseInterface createCertificateTemplateAsync(CreateCertificateTemplateRequest $request, array $optionalArgs = []) - * @method PromiseInterface deleteCaPoolAsync(DeleteCaPoolRequest $request, array $optionalArgs = []) - * @method PromiseInterface deleteCertificateAuthorityAsync(DeleteCertificateAuthorityRequest $request, array $optionalArgs = []) - * @method PromiseInterface deleteCertificateTemplateAsync(DeleteCertificateTemplateRequest $request, array $optionalArgs = []) - * @method PromiseInterface disableCertificateAuthorityAsync(DisableCertificateAuthorityRequest $request, array $optionalArgs = []) - * @method PromiseInterface enableCertificateAuthorityAsync(EnableCertificateAuthorityRequest $request, array $optionalArgs = []) - * @method PromiseInterface fetchCaCertsAsync(FetchCaCertsRequest $request, array $optionalArgs = []) - * @method PromiseInterface fetchCertificateAuthorityCsrAsync(FetchCertificateAuthorityCsrRequest $request, array $optionalArgs = []) - * @method PromiseInterface getCaPoolAsync(GetCaPoolRequest $request, array $optionalArgs = []) - * @method PromiseInterface getCertificateAsync(GetCertificateRequest $request, array $optionalArgs = []) - * @method PromiseInterface getCertificateAuthorityAsync(GetCertificateAuthorityRequest $request, array $optionalArgs = []) - * @method PromiseInterface getCertificateRevocationListAsync(GetCertificateRevocationListRequest $request, array $optionalArgs = []) - * @method PromiseInterface getCertificateTemplateAsync(GetCertificateTemplateRequest $request, array $optionalArgs = []) - * @method PromiseInterface listCaPoolsAsync(ListCaPoolsRequest $request, array $optionalArgs = []) - * @method PromiseInterface listCertificateAuthoritiesAsync(ListCertificateAuthoritiesRequest $request, array $optionalArgs = []) - * @method PromiseInterface listCertificateRevocationListsAsync(ListCertificateRevocationListsRequest $request, array $optionalArgs = []) - * @method PromiseInterface listCertificateTemplatesAsync(ListCertificateTemplatesRequest $request, array $optionalArgs = []) - * @method PromiseInterface listCertificatesAsync(ListCertificatesRequest $request, array $optionalArgs = []) - * @method PromiseInterface revokeCertificateAsync(RevokeCertificateRequest $request, array $optionalArgs = []) - * @method PromiseInterface undeleteCertificateAuthorityAsync(UndeleteCertificateAuthorityRequest $request, array $optionalArgs = []) - * @method PromiseInterface updateCaPoolAsync(UpdateCaPoolRequest $request, array $optionalArgs = []) - * @method PromiseInterface updateCertificateAsync(UpdateCertificateRequest $request, array $optionalArgs = []) - * @method PromiseInterface updateCertificateAuthorityAsync(UpdateCertificateAuthorityRequest $request, array $optionalArgs = []) - * @method PromiseInterface updateCertificateRevocationListAsync(UpdateCertificateRevocationListRequest $request, array $optionalArgs = []) - * @method PromiseInterface updateCertificateTemplateAsync(UpdateCertificateTemplateRequest $request, array $optionalArgs = []) - * @method PromiseInterface getLocationAsync(GetLocationRequest $request, array $optionalArgs = []) - * @method PromiseInterface listLocationsAsync(ListLocationsRequest $request, array $optionalArgs = []) - * @method PromiseInterface getIamPolicyAsync(GetIamPolicyRequest $request, array $optionalArgs = []) - * @method PromiseInterface setIamPolicyAsync(SetIamPolicyRequest $request, array $optionalArgs = []) - * @method PromiseInterface testIamPermissionsAsync(TestIamPermissionsRequest $request, array $optionalArgs = []) - */ -final class CertificateAuthorityServiceClient -{ - use GapicClientTrait; - use ResourceHelperTrait; - - /** The name of the service. */ - private const SERVICE_NAME = 'google.cloud.security.privateca.v1.CertificateAuthorityService'; - - /** - * The default address of the service. - * - * @deprecated SERVICE_ADDRESS_TEMPLATE should be used instead. - */ - private const SERVICE_ADDRESS = 'privateca.googleapis.com'; - - /** The address template of the service. */ - private const SERVICE_ADDRESS_TEMPLATE = 'privateca.UNIVERSE_DOMAIN'; - - /** The default port of the service. */ - private const DEFAULT_SERVICE_PORT = 443; - - /** The name of the code generator, to be included in the agent header. */ - private const CODEGEN_NAME = 'gapic'; - - /** The default scopes required by the service. */ - public static $serviceScopes = [ - 'https://www.googleapis.com/auth/cloud-platform', - ]; - - private $operationsClient; - - private static function getClientDefaults() - { - return [ - 'serviceName' => self::SERVICE_NAME, - 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, - 'clientConfig' => __DIR__ . '/../resources/certificate_authority_service_client_config.json', - 'descriptorsConfigPath' => __DIR__ . '/../resources/certificate_authority_service_descriptor_config.php', - 'gcpApiConfigPath' => __DIR__ . '/../resources/certificate_authority_service_grpc_config.json', - 'credentialsConfig' => [ - 'defaultScopes' => self::$serviceScopes, - ], - 'transportConfig' => [ - 'rest' => [ - 'restClientConfigPath' => __DIR__ . '/../resources/certificate_authority_service_rest_client_config.php', - ], - ], - ]; - } - - /** - * 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 = $this->descriptors[$methodName]['longRunning'] ?? []; - $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); - $operation->reload(); - return $operation; - } - - /** - * Create the default operation client for the service. - * - * @param array $options ClientOptions for the client. - * - * @return OperationsClient - */ - private function createOperationsClient(array $options) - { - // Unset client-specific configuration options - unset($options['serviceName'], $options['clientConfig'], $options['descriptorsConfigPath']); - - if (isset($options['operationsClient'])) { - return $options['operationsClient']; - } - - return new OperationsClient($options); - } - - /** - * 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(string $project, string $location, string $caPool): string - { - return self::getPathTemplate('caPool')->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 $caPool - * @param string $certificate - * - * @return string The formatted certificate resource. - */ - public static function certificateName(string $project, string $location, string $caPool, string $certificate): string - { - return self::getPathTemplate('certificate')->render([ - 'project' => $project, - 'location' => $location, - 'ca_pool' => $caPool, - 'certificate' => $certificate, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * certificate_authority resource. - * - * @param string $project - * @param string $location - * @param string $caPool - * @param string $certificateAuthority - * - * @return string The formatted certificate_authority resource. - */ - public static function certificateAuthorityName(string $project, string $location, string $caPool, string $certificateAuthority): string - { - return self::getPathTemplate('certificateAuthority')->render([ - 'project' => $project, - 'location' => $location, - 'ca_pool' => $caPool, - 'certificate_authority' => $certificateAuthority, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * certificate_revocation_list resource. - * - * @param string $project - * @param string $location - * @param string $caPool - * @param string $certificateAuthority - * @param string $certificateRevocationList - * - * @return string The formatted certificate_revocation_list resource. - */ - public static function certificateRevocationListName(string $project, string $location, string $caPool, string $certificateAuthority, string $certificateRevocationList): string - { - return self::getPathTemplate('certificateRevocationList')->render([ - 'project' => $project, - 'location' => $location, - 'ca_pool' => $caPool, - 'certificate_authority' => $certificateAuthority, - 'certificate_revocation_list' => $certificateRevocationList, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * certificate_template resource. - * - * @param string $project - * @param string $location - * @param string $certificateTemplate - * - * @return string The formatted certificate_template resource. - */ - public static function certificateTemplateName(string $project, string $location, string $certificateTemplate): string - { - return self::getPathTemplate('certificateTemplate')->render([ - 'project' => $project, - 'location' => $location, - 'certificate_template' => $certificateTemplate, - ]); - } - - /** - * 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(string $project, string $location): string - { - return self::getPathTemplate('location')->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}/caPools/{ca_pool}/certificates/{certificate} - * - certificateAuthority: projects/{project}/locations/{location}/caPools/{ca_pool}/certificateAuthorities/{certificate_authority} - * - certificateRevocationList: projects/{project}/locations/{location}/caPools/{ca_pool}/certificateAuthorities/{certificate_authority}/certificateRevocationLists/{certificate_revocation_list} - * - certificateTemplate: projects/{project}/locations/{location}/certificateTemplates/{certificate_template} - * - 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(string $formattedName, ?string $template = null): array - { - return self::parseFormattedName($formattedName, $template); - } - - /** - * Constructor. - * - * @param array|ClientOptions $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 'privateca.googleapis.com:443'. - * @type FetchAuthTokenInterface|CredentialsWrapper $credentials - * This option should only be used with a pre-constructed - * {@see FetchAuthTokenInterface} or {@see CredentialsWrapper} object. Note that - * when one of these objects are provided, any settings in $credentialsConfig will - * be ignored. - * **Important**: If you are providing a path to a credentials file, or a decoded - * credentials file as a PHP array, this usage is now DEPRECATED. Providing an - * unvalidated credential configuration to Google APIs can compromise the security - * of your systems and data. It is recommended to create the credentials explicitly - * ``` - * use Google\Auth\Credentials\ServiceAccountCredentials; - * use Google\Cloud\Security\PrivateCA\V1\CertificateAuthorityServiceClient; - * $creds = new ServiceAccountCredentials($scopes, $json); - * $options = new CertificateAuthorityServiceClient(['credentials' => $creds]); - * ``` - * {@see - * https://cloud.google.com/docs/authentication/external/externally-sourced-credentials} - * @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. - * @type false|LoggerInterface $logger - * A PSR-3 compliant logger. If set to false, logging is disabled, ignoring the - * 'GOOGLE_SDK_PHP_LOGGING' environment flag - * @type string $universeDomain - * The service domain for the client. Defaults to 'googleapis.com'. - * } - * - * @throws ValidationException - */ - public function __construct(array|ClientOptions $options = []) - { - $clientOptions = $this->buildClientOptions($options); - $this->setClientOptions($clientOptions); - $this->operationsClient = $this->createOperationsClient($clientOptions); - } - - /** Handles execution of the async variants for each documented method. */ - public function __call($method, $args) - { - if (substr($method, -5) !== 'Async') { - trigger_error('Call to undefined method ' . __CLASS__ . "::$method()", E_USER_ERROR); - } - - array_unshift($args, substr($method, 0, -5)); - return call_user_func_array([$this, 'startAsyncCall'], $args); - } - - /** - * Activate a - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * that is in state - * [AWAITING_USER_ACTIVATION][google.cloud.security.privateca.v1.CertificateAuthority.State.AWAITING_USER_ACTIVATION] - * and is of type - * [SUBORDINATE][google.cloud.security.privateca.v1.CertificateAuthority.Type.SUBORDINATE]. - * After the parent Certificate Authority signs a certificate signing request - * from - * [FetchCertificateAuthorityCsr][google.cloud.security.privateca.v1.CertificateAuthorityService.FetchCertificateAuthorityCsr], - * this method can complete the activation process. - * - * The async variant is - * {@see CertificateAuthorityServiceClient::activateCertificateAuthorityAsync()} . - * - * @example samples/V1/CertificateAuthorityServiceClient/activate_certificate_authority.php - * - * @param ActivateCertificateAuthorityRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function activateCertificateAuthority(ActivateCertificateAuthorityRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('ActivateCertificateAuthority', $request, $callOptions)->wait(); - } - - /** - * Create a [CaPool][google.cloud.security.privateca.v1.CaPool]. - * - * The async variant is - * {@see CertificateAuthorityServiceClient::createCaPoolAsync()} . - * - * @example samples/V1/CertificateAuthorityServiceClient/create_ca_pool.php - * - * @param CreateCaPoolRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function createCaPool(CreateCaPoolRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('CreateCaPool', $request, $callOptions)->wait(); - } - - /** - * Create a new [Certificate][google.cloud.security.privateca.v1.Certificate] - * in a given Project, Location from a particular - * [CaPool][google.cloud.security.privateca.v1.CaPool]. - * - * The async variant is - * {@see CertificateAuthorityServiceClient::createCertificateAsync()} . - * - * @example samples/V1/CertificateAuthorityServiceClient/create_certificate.php - * - * @param CreateCertificateRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Certificate - * - * @throws ApiException Thrown if the API call fails. - */ - public function createCertificate(CreateCertificateRequest $request, array $callOptions = []): Certificate - { - return $this->startApiCall('CreateCertificate', $request, $callOptions)->wait(); - } - - /** - * Create a new - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * in a given Project and Location. - * - * The async variant is - * {@see CertificateAuthorityServiceClient::createCertificateAuthorityAsync()} . - * - * @example samples/V1/CertificateAuthorityServiceClient/create_certificate_authority.php - * - * @param CreateCertificateAuthorityRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function createCertificateAuthority(CreateCertificateAuthorityRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('CreateCertificateAuthority', $request, $callOptions)->wait(); - } - - /** - * Create a new - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate] - * in a given Project and Location. - * - * The async variant is - * {@see CertificateAuthorityServiceClient::createCertificateTemplateAsync()} . - * - * @example samples/V1/CertificateAuthorityServiceClient/create_certificate_template.php - * - * @param CreateCertificateTemplateRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function createCertificateTemplate(CreateCertificateTemplateRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('CreateCertificateTemplate', $request, $callOptions)->wait(); - } - - /** - * Delete a [CaPool][google.cloud.security.privateca.v1.CaPool]. - * - * The async variant is - * {@see CertificateAuthorityServiceClient::deleteCaPoolAsync()} . - * - * @example samples/V1/CertificateAuthorityServiceClient/delete_ca_pool.php - * - * @param DeleteCaPoolRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function deleteCaPool(DeleteCaPoolRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('DeleteCaPool', $request, $callOptions)->wait(); - } - - /** - * Delete a - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. - * - * The async variant is - * {@see CertificateAuthorityServiceClient::deleteCertificateAuthorityAsync()} . - * - * @example samples/V1/CertificateAuthorityServiceClient/delete_certificate_authority.php - * - * @param DeleteCertificateAuthorityRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function deleteCertificateAuthority(DeleteCertificateAuthorityRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('DeleteCertificateAuthority', $request, $callOptions)->wait(); - } - - /** - * DeleteCertificateTemplate deletes a - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate]. - * - * The async variant is - * {@see CertificateAuthorityServiceClient::deleteCertificateTemplateAsync()} . - * - * @example samples/V1/CertificateAuthorityServiceClient/delete_certificate_template.php - * - * @param DeleteCertificateTemplateRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function deleteCertificateTemplate(DeleteCertificateTemplateRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('DeleteCertificateTemplate', $request, $callOptions)->wait(); - } - - /** - * Disable a - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. - * - * The async variant is - * {@see CertificateAuthorityServiceClient::disableCertificateAuthorityAsync()} . - * - * @example samples/V1/CertificateAuthorityServiceClient/disable_certificate_authority.php - * - * @param DisableCertificateAuthorityRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function disableCertificateAuthority(DisableCertificateAuthorityRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('DisableCertificateAuthority', $request, $callOptions)->wait(); - } - - /** - * Enable a - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. - * - * The async variant is - * {@see CertificateAuthorityServiceClient::enableCertificateAuthorityAsync()} . - * - * @example samples/V1/CertificateAuthorityServiceClient/enable_certificate_authority.php - * - * @param EnableCertificateAuthorityRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function enableCertificateAuthority(EnableCertificateAuthorityRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('EnableCertificateAuthority', $request, $callOptions)->wait(); - } - - /** - * FetchCaCerts returns the current trust anchor for the - * [CaPool][google.cloud.security.privateca.v1.CaPool]. This will include CA - * certificate chains for all certificate authorities in the ENABLED, - * DISABLED, or STAGED states. - * - * The async variant is - * {@see CertificateAuthorityServiceClient::fetchCaCertsAsync()} . - * - * @example samples/V1/CertificateAuthorityServiceClient/fetch_ca_certs.php - * - * @param FetchCaCertsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 FetchCaCertsResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function fetchCaCerts(FetchCaCertsRequest $request, array $callOptions = []): FetchCaCertsResponse - { - return $this->startApiCall('FetchCaCerts', $request, $callOptions)->wait(); - } - - /** - * Fetch a certificate signing request (CSR) from a - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * that is in state - * [AWAITING_USER_ACTIVATION][google.cloud.security.privateca.v1.CertificateAuthority.State.AWAITING_USER_ACTIVATION] - * and is of type - * [SUBORDINATE][google.cloud.security.privateca.v1.CertificateAuthority.Type.SUBORDINATE]. - * The CSR must then be signed by the desired parent Certificate Authority, - * which could be another - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * resource, or could be an on-prem certificate authority. See also - * [ActivateCertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthorityService.ActivateCertificateAuthority]. - * - * The async variant is - * {@see CertificateAuthorityServiceClient::fetchCertificateAuthorityCsrAsync()} . - * - * @example samples/V1/CertificateAuthorityServiceClient/fetch_certificate_authority_csr.php - * - * @param FetchCertificateAuthorityCsrRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 FetchCertificateAuthorityCsrResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function fetchCertificateAuthorityCsr(FetchCertificateAuthorityCsrRequest $request, array $callOptions = []): FetchCertificateAuthorityCsrResponse - { - return $this->startApiCall('FetchCertificateAuthorityCsr', $request, $callOptions)->wait(); - } - - /** - * Returns a [CaPool][google.cloud.security.privateca.v1.CaPool]. - * - * The async variant is {@see CertificateAuthorityServiceClient::getCaPoolAsync()} - * . - * - * @example samples/V1/CertificateAuthorityServiceClient/get_ca_pool.php - * - * @param GetCaPoolRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 CaPool - * - * @throws ApiException Thrown if the API call fails. - */ - public function getCaPool(GetCaPoolRequest $request, array $callOptions = []): CaPool - { - return $this->startApiCall('GetCaPool', $request, $callOptions)->wait(); - } - - /** - * Returns a [Certificate][google.cloud.security.privateca.v1.Certificate]. - * - * The async variant is - * {@see CertificateAuthorityServiceClient::getCertificateAsync()} . - * - * @example samples/V1/CertificateAuthorityServiceClient/get_certificate.php - * - * @param GetCertificateRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Certificate - * - * @throws ApiException Thrown if the API call fails. - */ - public function getCertificate(GetCertificateRequest $request, array $callOptions = []): Certificate - { - return $this->startApiCall('GetCertificate', $request, $callOptions)->wait(); - } - - /** - * Returns a - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. - * - * The async variant is - * {@see CertificateAuthorityServiceClient::getCertificateAuthorityAsync()} . - * - * @example samples/V1/CertificateAuthorityServiceClient/get_certificate_authority.php - * - * @param GetCertificateAuthorityRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 CertificateAuthority - * - * @throws ApiException Thrown if the API call fails. - */ - public function getCertificateAuthority(GetCertificateAuthorityRequest $request, array $callOptions = []): CertificateAuthority - { - return $this->startApiCall('GetCertificateAuthority', $request, $callOptions)->wait(); - } - - /** - * Returns a - * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList]. - * - * The async variant is - * {@see CertificateAuthorityServiceClient::getCertificateRevocationListAsync()} . - * - * @example samples/V1/CertificateAuthorityServiceClient/get_certificate_revocation_list.php - * - * @param GetCertificateRevocationListRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 CertificateRevocationList - * - * @throws ApiException Thrown if the API call fails. - */ - public function getCertificateRevocationList(GetCertificateRevocationListRequest $request, array $callOptions = []): CertificateRevocationList - { - return $this->startApiCall('GetCertificateRevocationList', $request, $callOptions)->wait(); - } - - /** - * Returns a - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate]. - * - * The async variant is - * {@see CertificateAuthorityServiceClient::getCertificateTemplateAsync()} . - * - * @example samples/V1/CertificateAuthorityServiceClient/get_certificate_template.php - * - * @param GetCertificateTemplateRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 CertificateTemplate - * - * @throws ApiException Thrown if the API call fails. - */ - public function getCertificateTemplate(GetCertificateTemplateRequest $request, array $callOptions = []): CertificateTemplate - { - return $this->startApiCall('GetCertificateTemplate', $request, $callOptions)->wait(); - } - - /** - * Lists [CaPools][google.cloud.security.privateca.v1.CaPool]. - * - * The async variant is - * {@see CertificateAuthorityServiceClient::listCaPoolsAsync()} . - * - * @example samples/V1/CertificateAuthorityServiceClient/list_ca_pools.php - * - * @param ListCaPoolsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listCaPools(ListCaPoolsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListCaPools', $request, $callOptions); - } - - /** - * Lists - * [CertificateAuthorities][google.cloud.security.privateca.v1.CertificateAuthority]. - * - * The async variant is - * {@see CertificateAuthorityServiceClient::listCertificateAuthoritiesAsync()} . - * - * @example samples/V1/CertificateAuthorityServiceClient/list_certificate_authorities.php - * - * @param ListCertificateAuthoritiesRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listCertificateAuthorities(ListCertificateAuthoritiesRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListCertificateAuthorities', $request, $callOptions); - } - - /** - * Lists - * [CertificateRevocationLists][google.cloud.security.privateca.v1.CertificateRevocationList]. - * - * The async variant is - * {@see CertificateAuthorityServiceClient::listCertificateRevocationListsAsync()} - * . - * - * @example samples/V1/CertificateAuthorityServiceClient/list_certificate_revocation_lists.php - * - * @param ListCertificateRevocationListsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listCertificateRevocationLists(ListCertificateRevocationListsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListCertificateRevocationLists', $request, $callOptions); - } - - /** - * Lists - * [CertificateTemplates][google.cloud.security.privateca.v1.CertificateTemplate]. - * - * The async variant is - * {@see CertificateAuthorityServiceClient::listCertificateTemplatesAsync()} . - * - * @example samples/V1/CertificateAuthorityServiceClient/list_certificate_templates.php - * - * @param ListCertificateTemplatesRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listCertificateTemplates(ListCertificateTemplatesRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListCertificateTemplates', $request, $callOptions); - } - - /** - * Lists [Certificates][google.cloud.security.privateca.v1.Certificate]. - * - * The async variant is - * {@see CertificateAuthorityServiceClient::listCertificatesAsync()} . - * - * @example samples/V1/CertificateAuthorityServiceClient/list_certificates.php - * - * @param ListCertificatesRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listCertificates(ListCertificatesRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListCertificates', $request, $callOptions); - } - - /** - * Revoke a [Certificate][google.cloud.security.privateca.v1.Certificate]. - * - * The async variant is - * {@see CertificateAuthorityServiceClient::revokeCertificateAsync()} . - * - * @example samples/V1/CertificateAuthorityServiceClient/revoke_certificate.php - * - * @param RevokeCertificateRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Certificate - * - * @throws ApiException Thrown if the API call fails. - */ - public function revokeCertificate(RevokeCertificateRequest $request, array $callOptions = []): Certificate - { - return $this->startApiCall('RevokeCertificate', $request, $callOptions)->wait(); - } - - /** - * Undelete a - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority] - * that has been deleted. - * - * The async variant is - * {@see CertificateAuthorityServiceClient::undeleteCertificateAuthorityAsync()} . - * - * @example samples/V1/CertificateAuthorityServiceClient/undelete_certificate_authority.php - * - * @param UndeleteCertificateAuthorityRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function undeleteCertificateAuthority(UndeleteCertificateAuthorityRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('UndeleteCertificateAuthority', $request, $callOptions)->wait(); - } - - /** - * Update a [CaPool][google.cloud.security.privateca.v1.CaPool]. - * - * The async variant is - * {@see CertificateAuthorityServiceClient::updateCaPoolAsync()} . - * - * @example samples/V1/CertificateAuthorityServiceClient/update_ca_pool.php - * - * @param UpdateCaPoolRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateCaPool(UpdateCaPoolRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('UpdateCaPool', $request, $callOptions)->wait(); - } - - /** - * Update a [Certificate][google.cloud.security.privateca.v1.Certificate]. - * Currently, the only field you can update is the - * [labels][google.cloud.security.privateca.v1.Certificate.labels] field. - * - * The async variant is - * {@see CertificateAuthorityServiceClient::updateCertificateAsync()} . - * - * @example samples/V1/CertificateAuthorityServiceClient/update_certificate.php - * - * @param UpdateCertificateRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Certificate - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateCertificate(UpdateCertificateRequest $request, array $callOptions = []): Certificate - { - return $this->startApiCall('UpdateCertificate', $request, $callOptions)->wait(); - } - - /** - * Update a - * [CertificateAuthority][google.cloud.security.privateca.v1.CertificateAuthority]. - * - * The async variant is - * {@see CertificateAuthorityServiceClient::updateCertificateAuthorityAsync()} . - * - * @example samples/V1/CertificateAuthorityServiceClient/update_certificate_authority.php - * - * @param UpdateCertificateAuthorityRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateCertificateAuthority(UpdateCertificateAuthorityRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('UpdateCertificateAuthority', $request, $callOptions)->wait(); - } - - /** - * Update a - * [CertificateRevocationList][google.cloud.security.privateca.v1.CertificateRevocationList]. - * - * The async variant is - * {@see CertificateAuthorityServiceClient::updateCertificateRevocationListAsync()} - * . - * - * @example samples/V1/CertificateAuthorityServiceClient/update_certificate_revocation_list.php - * - * @param UpdateCertificateRevocationListRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateCertificateRevocationList(UpdateCertificateRevocationListRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('UpdateCertificateRevocationList', $request, $callOptions)->wait(); - } - - /** - * Update a - * [CertificateTemplate][google.cloud.security.privateca.v1.CertificateTemplate]. - * - * The async variant is - * {@see CertificateAuthorityServiceClient::updateCertificateTemplateAsync()} . - * - * @example samples/V1/CertificateAuthorityServiceClient/update_certificate_template.php - * - * @param UpdateCertificateTemplateRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateCertificateTemplate(UpdateCertificateTemplateRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('UpdateCertificateTemplate', $request, $callOptions)->wait(); - } - - /** - * Gets information about a location. - * - * The async variant is - * {@see CertificateAuthorityServiceClient::getLocationAsync()} . - * - * @example samples/V1/CertificateAuthorityServiceClient/get_location.php - * - * @param GetLocationRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Location - * - * @throws ApiException Thrown if the API call fails. - */ - public function getLocation(GetLocationRequest $request, array $callOptions = []): Location - { - return $this->startApiCall('GetLocation', $request, $callOptions)->wait(); - } - - /** - * Lists information about the supported locations for this service. - * - * This method lists locations based on the resource scope provided in - * the [ListLocationsRequest.name][google.cloud.location.ListLocationsRequest.name] field: * - * **Global locations**: If `name` is empty, the method lists the - * public locations available to all projects. * **Project-specific - * locations**: If `name` follows the format - * `projects/{project}`, the method lists locations visible to that - * specific project. This includes public, private, or other - * project-specific locations enabled for the project. - * - * For gRPC and client library implementations, the resource name is - * passed as the `name` field. For direct service calls, the resource - * name is - * incorporated into the request path based on the specific service - * implementation and version. - * - * The async variant is - * {@see CertificateAuthorityServiceClient::listLocationsAsync()} . - * - * @example samples/V1/CertificateAuthorityServiceClient/list_locations.php - * - * @param ListLocationsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listLocations(ListLocationsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListLocations', $request, $callOptions); - } - - /** - * Gets the access control policy for a resource. Returns an empty policy - * if the resource exists and does not have a policy set. - * - * The async variant is - * {@see CertificateAuthorityServiceClient::getIamPolicyAsync()} . - * - * @example samples/V1/CertificateAuthorityServiceClient/get_iam_policy.php - * - * @param GetIamPolicyRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Policy - * - * @throws ApiException Thrown if the API call fails. - */ - public function getIamPolicy(GetIamPolicyRequest $request, array $callOptions = []): Policy - { - return $this->startApiCall('GetIamPolicy', $request, $callOptions)->wait(); - } - - /** - * Sets the access control policy on the specified resource. Replaces - * any existing policy. - * - * Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` - * errors. - * - * The async variant is - * {@see CertificateAuthorityServiceClient::setIamPolicyAsync()} . - * - * @example samples/V1/CertificateAuthorityServiceClient/set_iam_policy.php - * - * @param SetIamPolicyRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Policy - * - * @throws ApiException Thrown if the API call fails. - */ - public function setIamPolicy(SetIamPolicyRequest $request, array $callOptions = []): Policy - { - return $this->startApiCall('SetIamPolicy', $request, $callOptions)->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. - * - * The async variant is - * {@see CertificateAuthorityServiceClient::testIamPermissionsAsync()} . - * - * @example samples/V1/CertificateAuthorityServiceClient/test_iam_permissions.php - * - * @param TestIamPermissionsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 TestIamPermissionsResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function testIamPermissions(TestIamPermissionsRequest $request, array $callOptions = []): TestIamPermissionsResponse - { - return $this->startApiCall('TestIamPermissions', $request, $callOptions)->wait(); - } -} diff --git a/owl-bot-staging/SecurityPrivateCa/v1/src/V1/gapic_metadata.json b/owl-bot-staging/SecurityPrivateCa/v1/src/V1/gapic_metadata.json deleted file mode 100644 index b7ecefd419d9..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/src/V1/gapic_metadata.json +++ /dev/null @@ -1,188 +0,0 @@ -{ - "schema": "1.0", - "comment": "This file maps proto services\/RPCs to the corresponding library clients\/methods", - "language": "php", - "protoPackage": "google.cloud.security.privateca.v1", - "libraryPackage": "Google\\Cloud\\Security\\PrivateCA\\V1", - "services": { - "CertificateAuthorityService": { - "clients": { - "grpc": { - "libraryClient": "CertificateAuthorityServiceGapicClient", - "rpcs": { - "ActivateCertificateAuthority": { - "methods": [ - "activateCertificateAuthority" - ] - }, - "CreateCaPool": { - "methods": [ - "createCaPool" - ] - }, - "CreateCertificate": { - "methods": [ - "createCertificate" - ] - }, - "CreateCertificateAuthority": { - "methods": [ - "createCertificateAuthority" - ] - }, - "CreateCertificateTemplate": { - "methods": [ - "createCertificateTemplate" - ] - }, - "DeleteCaPool": { - "methods": [ - "deleteCaPool" - ] - }, - "DeleteCertificateAuthority": { - "methods": [ - "deleteCertificateAuthority" - ] - }, - "DeleteCertificateTemplate": { - "methods": [ - "deleteCertificateTemplate" - ] - }, - "DisableCertificateAuthority": { - "methods": [ - "disableCertificateAuthority" - ] - }, - "EnableCertificateAuthority": { - "methods": [ - "enableCertificateAuthority" - ] - }, - "FetchCaCerts": { - "methods": [ - "fetchCaCerts" - ] - }, - "FetchCertificateAuthorityCsr": { - "methods": [ - "fetchCertificateAuthorityCsr" - ] - }, - "GetCaPool": { - "methods": [ - "getCaPool" - ] - }, - "GetCertificate": { - "methods": [ - "getCertificate" - ] - }, - "GetCertificateAuthority": { - "methods": [ - "getCertificateAuthority" - ] - }, - "GetCertificateRevocationList": { - "methods": [ - "getCertificateRevocationList" - ] - }, - "GetCertificateTemplate": { - "methods": [ - "getCertificateTemplate" - ] - }, - "ListCaPools": { - "methods": [ - "listCaPools" - ] - }, - "ListCertificateAuthorities": { - "methods": [ - "listCertificateAuthorities" - ] - }, - "ListCertificateRevocationLists": { - "methods": [ - "listCertificateRevocationLists" - ] - }, - "ListCertificateTemplates": { - "methods": [ - "listCertificateTemplates" - ] - }, - "ListCertificates": { - "methods": [ - "listCertificates" - ] - }, - "RevokeCertificate": { - "methods": [ - "revokeCertificate" - ] - }, - "UndeleteCertificateAuthority": { - "methods": [ - "undeleteCertificateAuthority" - ] - }, - "UpdateCaPool": { - "methods": [ - "updateCaPool" - ] - }, - "UpdateCertificate": { - "methods": [ - "updateCertificate" - ] - }, - "UpdateCertificateAuthority": { - "methods": [ - "updateCertificateAuthority" - ] - }, - "UpdateCertificateRevocationList": { - "methods": [ - "updateCertificateRevocationList" - ] - }, - "UpdateCertificateTemplate": { - "methods": [ - "updateCertificateTemplate" - ] - }, - "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/SecurityPrivateCa/v1/src/V1/resources/certificate_authority_service_client_config.json b/owl-bot-staging/SecurityPrivateCa/v1/src/V1/resources/certificate_authority_service_client_config.json deleted file mode 100644 index 7d91cf3d1dba..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/src/V1/resources/certificate_authority_service_client_config.json +++ /dev/null @@ -1,206 +0,0 @@ -{ - "interfaces": { - "google.cloud.security.privateca.v1.CertificateAuthorityService": { - "retry_codes": { - "no_retry_codes": [], - "retry_policy_1_codes": [ - "UNKNOWN", - "UNAVAILABLE", - "DEADLINE_EXCEEDED" - ] - }, - "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": 100, - "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": { - "ActivateCertificateAuthority": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "CreateCaPool": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "CreateCertificate": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "CreateCertificateAuthority": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "CreateCertificateTemplate": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "DeleteCaPool": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "DeleteCertificateAuthority": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "DeleteCertificateTemplate": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "DisableCertificateAuthority": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "EnableCertificateAuthority": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "FetchCaCerts": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "FetchCertificateAuthorityCsr": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetCaPool": { - "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" - }, - "GetCertificateAuthority": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetCertificateRevocationList": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetCertificateTemplate": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListCaPools": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListCertificateAuthorities": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListCertificateRevocationLists": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListCertificateTemplates": { - "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" - }, - "RevokeCertificate": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "UndeleteCertificateAuthority": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "UpdateCaPool": { - "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" - }, - "UpdateCertificateAuthority": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "UpdateCertificateRevocationList": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "UpdateCertificateTemplate": { - "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" - }, - "GetIamPolicy": { - "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" - } - } - } - } -} diff --git a/owl-bot-staging/SecurityPrivateCa/v1/src/V1/resources/certificate_authority_service_descriptor_config.php b/owl-bot-staging/SecurityPrivateCa/v1/src/V1/resources/certificate_authority_service_descriptor_config.php deleted file mode 100644 index 3d8570152f5b..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/src/V1/resources/certificate_authority_service_descriptor_config.php +++ /dev/null @@ -1,600 +0,0 @@ - [ - 'google.cloud.security.privateca.v1.CertificateAuthorityService' => [ - 'ActivateCertificateAuthority' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\Security\PrivateCA\V1\CertificateAuthority', - 'metadataReturnType' => '\Google\Cloud\Security\PrivateCA\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'CreateCaPool' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\Security\PrivateCA\V1\CaPool', - 'metadataReturnType' => '\Google\Cloud\Security\PrivateCA\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateCertificateAuthority' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\Security\PrivateCA\V1\CertificateAuthority', - 'metadataReturnType' => '\Google\Cloud\Security\PrivateCA\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateCertificateTemplate' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\Security\PrivateCA\V1\CertificateTemplate', - 'metadataReturnType' => '\Google\Cloud\Security\PrivateCA\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'DeleteCaPool' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\Security\PrivateCA\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'DeleteCertificateAuthority' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\Security\PrivateCA\V1\CertificateAuthority', - 'metadataReturnType' => '\Google\Cloud\Security\PrivateCA\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'DeleteCertificateTemplate' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\Security\PrivateCA\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'DisableCertificateAuthority' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\Security\PrivateCA\V1\CertificateAuthority', - 'metadataReturnType' => '\Google\Cloud\Security\PrivateCA\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'EnableCertificateAuthority' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\Security\PrivateCA\V1\CertificateAuthority', - 'metadataReturnType' => '\Google\Cloud\Security\PrivateCA\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'UndeleteCertificateAuthority' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\Security\PrivateCA\V1\CertificateAuthority', - 'metadataReturnType' => '\Google\Cloud\Security\PrivateCA\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'UpdateCaPool' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\Security\PrivateCA\V1\CaPool', - 'metadataReturnType' => '\Google\Cloud\Security\PrivateCA\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'ca_pool.name', - 'fieldAccessors' => [ - 'getCaPool', - 'getName', - ], - ], - ], - ], - 'UpdateCertificateAuthority' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\Security\PrivateCA\V1\CertificateAuthority', - 'metadataReturnType' => '\Google\Cloud\Security\PrivateCA\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'certificate_authority.name', - 'fieldAccessors' => [ - 'getCertificateAuthority', - 'getName', - ], - ], - ], - ], - 'UpdateCertificateRevocationList' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\Security\PrivateCA\V1\CertificateRevocationList', - 'metadataReturnType' => '\Google\Cloud\Security\PrivateCA\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'certificate_revocation_list.name', - 'fieldAccessors' => [ - 'getCertificateRevocationList', - 'getName', - ], - ], - ], - ], - 'UpdateCertificateTemplate' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\Security\PrivateCA\V1\CertificateTemplate', - 'metadataReturnType' => '\Google\Cloud\Security\PrivateCA\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'certificate_template.name', - 'fieldAccessors' => [ - 'getCertificateTemplate', - 'getName', - ], - ], - ], - ], - 'CreateCertificate' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Security\PrivateCA\V1\Certificate', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'FetchCaCerts' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Security\PrivateCA\V1\FetchCaCertsResponse', - 'headerParams' => [ - [ - 'keyName' => 'ca_pool', - 'fieldAccessors' => [ - 'getCaPool', - ], - ], - ], - ], - 'FetchCertificateAuthorityCsr' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Security\PrivateCA\V1\FetchCertificateAuthorityCsrResponse', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetCaPool' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Security\PrivateCA\V1\CaPool', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetCertificate' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Security\PrivateCA\V1\Certificate', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetCertificateAuthority' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Security\PrivateCA\V1\CertificateAuthority', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetCertificateRevocationList' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Security\PrivateCA\V1\CertificateRevocationList', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetCertificateTemplate' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Security\PrivateCA\V1\CertificateTemplate', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'ListCaPools' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getCaPools', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\Security\PrivateCA\V1\ListCaPoolsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListCertificateAuthorities' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getCertificateAuthorities', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\Security\PrivateCA\V1\ListCertificateAuthoritiesResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListCertificateRevocationLists' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getCertificateRevocationLists', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\Security\PrivateCA\V1\ListCertificateRevocationListsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListCertificateTemplates' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getCertificateTemplates', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\Security\PrivateCA\V1\ListCertificateTemplatesResponse', - '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\Security\PrivateCA\V1\ListCertificatesResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'RevokeCertificate' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Security\PrivateCA\V1\Certificate', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'UpdateCertificate' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Security\PrivateCA\V1\Certificate', - 'headerParams' => [ - [ - 'keyName' => 'certificate.name', - 'fieldAccessors' => [ - 'getCertificate', - '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' => [ - 'caPool' => 'projects/{project}/locations/{location}/caPools/{ca_pool}', - 'certificate' => 'projects/{project}/locations/{location}/caPools/{ca_pool}/certificates/{certificate}', - 'certificateAuthority' => 'projects/{project}/locations/{location}/caPools/{ca_pool}/certificateAuthorities/{certificate_authority}', - 'certificateRevocationList' => 'projects/{project}/locations/{location}/caPools/{ca_pool}/certificateAuthorities/{certificate_authority}/certificateRevocationLists/{certificate_revocation_list}', - 'certificateTemplate' => 'projects/{project}/locations/{location}/certificateTemplates/{certificate_template}', - 'location' => 'projects/{project}/locations/{location}', - ], - ], - ], -]; diff --git a/owl-bot-staging/SecurityPrivateCa/v1/src/V1/resources/certificate_authority_service_rest_client_config.php b/owl-bot-staging/SecurityPrivateCa/v1/src/V1/resources/certificate_authority_service_rest_client_config.php deleted file mode 100644 index ede260daa50a..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/src/V1/resources/certificate_authority_service_rest_client_config.php +++ /dev/null @@ -1,534 +0,0 @@ - [ - '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.cloud.security.privateca.v1.CertificateAuthorityService' => [ - 'ActivateCertificateAuthority' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/caPools/*/certificateAuthorities/*}:activate', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'CreateCaPool' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/caPools', - 'body' => 'ca_pool', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'ca_pool_id', - ], - ], - 'CreateCertificate' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/caPools/*}/certificates', - 'body' => 'certificate', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'CreateCertificateAuthority' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/caPools/*}/certificateAuthorities', - 'body' => 'certificate_authority', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'certificate_authority_id', - ], - ], - 'CreateCertificateTemplate' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/certificateTemplates', - 'body' => 'certificate_template', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'certificate_template_id', - ], - ], - 'DeleteCaPool' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/caPools/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteCertificateAuthority' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/caPools/*/certificateAuthorities/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteCertificateTemplate' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/certificateTemplates/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DisableCertificateAuthority' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/caPools/*/certificateAuthorities/*}:disable', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'EnableCertificateAuthority' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/caPools/*/certificateAuthorities/*}:enable', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'FetchCaCerts' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{ca_pool=projects/*/locations/*/caPools/*}:fetchCaCerts', - 'body' => '*', - 'placeholders' => [ - 'ca_pool' => [ - 'getters' => [ - 'getCaPool', - ], - ], - ], - ], - 'FetchCertificateAuthorityCsr' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/caPools/*/certificateAuthorities/*}:fetch', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetCaPool' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/caPools/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetCertificate' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/caPools/*/certificates/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetCertificateAuthority' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/caPools/*/certificateAuthorities/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetCertificateRevocationList' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/caPools/*/certificateAuthorities/*/certificateRevocationLists/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetCertificateTemplate' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/certificateTemplates/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListCaPools' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/caPools', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListCertificateAuthorities' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/caPools/*}/certificateAuthorities', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListCertificateRevocationLists' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/caPools/*/certificateAuthorities/*}/certificateRevocationLists', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListCertificateTemplates' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/certificateTemplates', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListCertificates' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/caPools/*}/certificates', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'RevokeCertificate' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/caPools/*/certificates/*}:revoke', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'UndeleteCertificateAuthority' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/caPools/*/certificateAuthorities/*}:undelete', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'UpdateCaPool' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{ca_pool.name=projects/*/locations/*/caPools/*}', - 'body' => 'ca_pool', - 'placeholders' => [ - 'ca_pool.name' => [ - 'getters' => [ - 'getCaPool', - 'getName', - ], - ], - ], - 'queryParams' => [ - 'update_mask', - ], - ], - 'UpdateCertificate' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{certificate.name=projects/*/locations/*/caPools/*/certificates/*}', - 'body' => 'certificate', - 'placeholders' => [ - 'certificate.name' => [ - 'getters' => [ - 'getCertificate', - 'getName', - ], - ], - ], - 'queryParams' => [ - 'update_mask', - ], - ], - 'UpdateCertificateAuthority' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{certificate_authority.name=projects/*/locations/*/caPools/*/certificateAuthorities/*}', - 'body' => 'certificate_authority', - 'placeholders' => [ - 'certificate_authority.name' => [ - 'getters' => [ - 'getCertificateAuthority', - 'getName', - ], - ], - ], - 'queryParams' => [ - 'update_mask', - ], - ], - 'UpdateCertificateRevocationList' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{certificate_revocation_list.name=projects/*/locations/*/caPools/*/certificateAuthorities/*/certificateRevocationLists/*}', - 'body' => 'certificate_revocation_list', - 'placeholders' => [ - 'certificate_revocation_list.name' => [ - 'getters' => [ - 'getCertificateRevocationList', - 'getName', - ], - ], - ], - 'queryParams' => [ - 'update_mask', - ], - ], - 'UpdateCertificateTemplate' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{certificate_template.name=projects/*/locations/*/certificateTemplates/*}', - 'body' => 'certificate_template', - 'placeholders' => [ - 'certificate_template.name' => [ - 'getters' => [ - 'getCertificateTemplate', - 'getName', - ], - ], - ], - 'queryParams' => [ - 'update_mask', - ], - ], - ], - 'google.iam.v1.IAMPolicy' => [ - 'GetIamPolicy' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/caPools/*}:getIamPolicy', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/certificateTemplates/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/caPools/*/certificateAuthorities/*/certificateRevocationLists/*}:getIamPolicy', - ], - ], - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'SetIamPolicy' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/caPools/*}:setIamPolicy', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/certificateTemplates/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/caPools/*/certificateAuthorities/*/certificateRevocationLists/*}:setIamPolicy', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'TestIamPermissions' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/caPools/*}:testIamPermissions', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/certificateTemplates/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/caPools/*/certificateAuthorities/*/certificateRevocationLists/*}: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/SecurityPrivateCa/v1/tests/Unit/V1/Client/CertificateAuthorityServiceClientTest.php b/owl-bot-staging/SecurityPrivateCa/v1/tests/Unit/V1/Client/CertificateAuthorityServiceClientTest.php deleted file mode 100644 index 9f95ea94dbeb..000000000000 --- a/owl-bot-staging/SecurityPrivateCa/v1/tests/Unit/V1/Client/CertificateAuthorityServiceClientTest.php +++ /dev/null @@ -1,3513 +0,0 @@ -getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); - } - - /** @return CertificateAuthorityServiceClient */ - private function createClient(array $options = []) - { - $options += [ - 'credentials' => $this->createCredentials(), - ]; - return new CertificateAuthorityServiceClient($options); - } - - /** @test */ - public function activateCertificateAuthorityTest() - { - $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/activateCertificateAuthorityTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name2 = 'name2-1052831874'; - $gcsBucket = 'gcsBucket-1720393710'; - $satisfiesPzs = false; - $satisfiesPzi = false; - $expectedResponse = new CertificateAuthority(); - $expectedResponse->setName($name2); - $expectedResponse->setGcsBucket($gcsBucket); - $expectedResponse->setSatisfiesPzs($satisfiesPzs); - $expectedResponse->setSatisfiesPzi($satisfiesPzi); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/activateCertificateAuthorityTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->certificateAuthorityName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]'); - $pemCaCertificate = 'pemCaCertificate1041594685'; - $subordinateConfig = new SubordinateConfig(); - $subordinateConfigCertificateAuthority = $gapicClient->certificateAuthorityName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]'); - $subordinateConfig->setCertificateAuthority($subordinateConfigCertificateAuthority); - $request = (new ActivateCertificateAuthorityRequest()) - ->setName($formattedName) - ->setPemCaCertificate($pemCaCertificate) - ->setSubordinateConfig($subordinateConfig); - $response = $gapicClient->activateCertificateAuthority($request); - $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.security.privateca.v1.CertificateAuthorityService/ActivateCertificateAuthority', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $actualValue = $actualApiRequestObject->getPemCaCertificate(); - $this->assertProtobufEquals($pemCaCertificate, $actualValue); - $actualValue = $actualApiRequestObject->getSubordinateConfig(); - $this->assertProtobufEquals($subordinateConfig, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/activateCertificateAuthorityTest'); - $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 activateCertificateAuthorityExceptionTest() - { - $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/activateCertificateAuthorityTest'); - $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->certificateAuthorityName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]'); - $pemCaCertificate = 'pemCaCertificate1041594685'; - $subordinateConfig = new SubordinateConfig(); - $subordinateConfigCertificateAuthority = $gapicClient->certificateAuthorityName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]'); - $subordinateConfig->setCertificateAuthority($subordinateConfigCertificateAuthority); - $request = (new ActivateCertificateAuthorityRequest()) - ->setName($formattedName) - ->setPemCaCertificate($pemCaCertificate) - ->setSubordinateConfig($subordinateConfig); - $response = $gapicClient->activateCertificateAuthority($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/activateCertificateAuthorityTest'); - 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 createCaPoolTest() - { - $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/createCaPoolTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $expectedResponse = new CaPool(); - $expectedResponse->setName($name); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createCaPoolTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $caPoolId = 'caPoolId458688829'; - $caPool = new CaPool(); - $caPoolTier = Tier::TIER_UNSPECIFIED; - $caPool->setTier($caPoolTier); - $request = (new CreateCaPoolRequest()) - ->setParent($formattedParent) - ->setCaPoolId($caPoolId) - ->setCaPool($caPool); - $response = $gapicClient->createCaPool($request); - $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.security.privateca.v1.CertificateAuthorityService/CreateCaPool', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getCaPoolId(); - $this->assertProtobufEquals($caPoolId, $actualValue); - $actualValue = $actualApiRequestObject->getCaPool(); - $this->assertProtobufEquals($caPool, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createCaPoolTest'); - $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 createCaPoolExceptionTest() - { - $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/createCaPoolTest'); - $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]'); - $caPoolId = 'caPoolId458688829'; - $caPool = new CaPool(); - $caPoolTier = Tier::TIER_UNSPECIFIED; - $caPool->setTier($caPoolTier); - $request = (new CreateCaPoolRequest()) - ->setParent($formattedParent) - ->setCaPoolId($caPoolId) - ->setCaPool($caPool); - $response = $gapicClient->createCaPool($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createCaPoolTest'); - 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 createCertificateTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $pemCsr = 'pemCsr-683665829'; - $issuerCertificateAuthority = 'issuerCertificateAuthority-750099051'; - $certificateTemplate = 'certificateTemplate2049676834'; - $pemCertificate = 'pemCertificate1234463984'; - $expectedResponse = new Certificate(); - $expectedResponse->setName($name); - $expectedResponse->setPemCsr($pemCsr); - $expectedResponse->setIssuerCertificateAuthority($issuerCertificateAuthority); - $expectedResponse->setCertificateTemplate($certificateTemplate); - $expectedResponse->setPemCertificate($pemCertificate); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->caPoolName('[PROJECT]', '[LOCATION]', '[CA_POOL]'); - $certificate = new Certificate(); - $certificateLifetime = new Duration(); - $certificate->setLifetime($certificateLifetime); - $request = (new CreateCertificateRequest()) - ->setParent($formattedParent) - ->setCertificate($certificate); - $response = $gapicClient->createCertificate($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.security.privateca.v1.CertificateAuthorityService/CreateCertificate', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getCertificate(); - $this->assertProtobufEquals($certificate, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createCertificateExceptionTest() - { - $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->caPoolName('[PROJECT]', '[LOCATION]', '[CA_POOL]'); - $certificate = new Certificate(); - $certificateLifetime = new Duration(); - $certificate->setLifetime($certificateLifetime); - $request = (new CreateCertificateRequest()) - ->setParent($formattedParent) - ->setCertificate($certificate); - try { - $gapicClient->createCertificate($request); - // 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 createCertificateAuthorityTest() - { - $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/createCertificateAuthorityTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $gcsBucket = 'gcsBucket-1720393710'; - $satisfiesPzs = false; - $satisfiesPzi = false; - $expectedResponse = new CertificateAuthority(); - $expectedResponse->setName($name); - $expectedResponse->setGcsBucket($gcsBucket); - $expectedResponse->setSatisfiesPzs($satisfiesPzs); - $expectedResponse->setSatisfiesPzi($satisfiesPzi); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createCertificateAuthorityTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->caPoolName('[PROJECT]', '[LOCATION]', '[CA_POOL]'); - $certificateAuthorityId = 'certificateAuthorityId561919295'; - $certificateAuthority = new CertificateAuthority(); - $certificateAuthorityType = Type::TYPE_UNSPECIFIED; - $certificateAuthority->setType($certificateAuthorityType); - $certificateAuthorityConfig = new CertificateConfig(); - $configSubjectConfig = new SubjectConfig(); - $certificateAuthorityConfig->setSubjectConfig($configSubjectConfig); - $configX509Config = new X509Parameters(); - $certificateAuthorityConfig->setX509Config($configX509Config); - $certificateAuthority->setConfig($certificateAuthorityConfig); - $certificateAuthorityLifetime = new Duration(); - $certificateAuthority->setLifetime($certificateAuthorityLifetime); - $certificateAuthorityKeySpec = new KeyVersionSpec(); - $certificateAuthority->setKeySpec($certificateAuthorityKeySpec); - $request = (new CreateCertificateAuthorityRequest()) - ->setParent($formattedParent) - ->setCertificateAuthorityId($certificateAuthorityId) - ->setCertificateAuthority($certificateAuthority); - $response = $gapicClient->createCertificateAuthority($request); - $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.security.privateca.v1.CertificateAuthorityService/CreateCertificateAuthority', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getCertificateAuthorityId(); - $this->assertProtobufEquals($certificateAuthorityId, $actualValue); - $actualValue = $actualApiRequestObject->getCertificateAuthority(); - $this->assertProtobufEquals($certificateAuthority, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createCertificateAuthorityTest'); - $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 createCertificateAuthorityExceptionTest() - { - $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/createCertificateAuthorityTest'); - $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->caPoolName('[PROJECT]', '[LOCATION]', '[CA_POOL]'); - $certificateAuthorityId = 'certificateAuthorityId561919295'; - $certificateAuthority = new CertificateAuthority(); - $certificateAuthorityType = Type::TYPE_UNSPECIFIED; - $certificateAuthority->setType($certificateAuthorityType); - $certificateAuthorityConfig = new CertificateConfig(); - $configSubjectConfig = new SubjectConfig(); - $certificateAuthorityConfig->setSubjectConfig($configSubjectConfig); - $configX509Config = new X509Parameters(); - $certificateAuthorityConfig->setX509Config($configX509Config); - $certificateAuthority->setConfig($certificateAuthorityConfig); - $certificateAuthorityLifetime = new Duration(); - $certificateAuthority->setLifetime($certificateAuthorityLifetime); - $certificateAuthorityKeySpec = new KeyVersionSpec(); - $certificateAuthority->setKeySpec($certificateAuthorityKeySpec); - $request = (new CreateCertificateAuthorityRequest()) - ->setParent($formattedParent) - ->setCertificateAuthorityId($certificateAuthorityId) - ->setCertificateAuthority($certificateAuthority); - $response = $gapicClient->createCertificateAuthority($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createCertificateAuthorityTest'); - 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 createCertificateTemplateTest() - { - $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/createCertificateTemplateTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $description = 'description-1724546052'; - $expectedResponse = new CertificateTemplate(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createCertificateTemplateTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $certificateTemplateId = 'certificateTemplateId372609112'; - $certificateTemplate = new CertificateTemplate(); - $request = (new CreateCertificateTemplateRequest()) - ->setParent($formattedParent) - ->setCertificateTemplateId($certificateTemplateId) - ->setCertificateTemplate($certificateTemplate); - $response = $gapicClient->createCertificateTemplate($request); - $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.security.privateca.v1.CertificateAuthorityService/CreateCertificateTemplate', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getCertificateTemplateId(); - $this->assertProtobufEquals($certificateTemplateId, $actualValue); - $actualValue = $actualApiRequestObject->getCertificateTemplate(); - $this->assertProtobufEquals($certificateTemplate, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createCertificateTemplateTest'); - $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 createCertificateTemplateExceptionTest() - { - $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/createCertificateTemplateTest'); - $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]'); - $certificateTemplateId = 'certificateTemplateId372609112'; - $certificateTemplate = new CertificateTemplate(); - $request = (new CreateCertificateTemplateRequest()) - ->setParent($formattedParent) - ->setCertificateTemplateId($certificateTemplateId) - ->setCertificateTemplate($certificateTemplate); - $response = $gapicClient->createCertificateTemplate($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createCertificateTemplateTest'); - 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 deleteCaPoolTest() - { - $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/deleteCaPoolTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteCaPoolTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->caPoolName('[PROJECT]', '[LOCATION]', '[CA_POOL]'); - $request = (new DeleteCaPoolRequest()) - ->setName($formattedName); - $response = $gapicClient->deleteCaPool($request); - $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.security.privateca.v1.CertificateAuthorityService/DeleteCaPool', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteCaPoolTest'); - $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 deleteCaPoolExceptionTest() - { - $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/deleteCaPoolTest'); - $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->caPoolName('[PROJECT]', '[LOCATION]', '[CA_POOL]'); - $request = (new DeleteCaPoolRequest()) - ->setName($formattedName); - $response = $gapicClient->deleteCaPool($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteCaPoolTest'); - 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 deleteCertificateAuthorityTest() - { - $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/deleteCertificateAuthorityTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name2 = 'name2-1052831874'; - $gcsBucket = 'gcsBucket-1720393710'; - $satisfiesPzs = false; - $satisfiesPzi = false; - $expectedResponse = new CertificateAuthority(); - $expectedResponse->setName($name2); - $expectedResponse->setGcsBucket($gcsBucket); - $expectedResponse->setSatisfiesPzs($satisfiesPzs); - $expectedResponse->setSatisfiesPzi($satisfiesPzi); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteCertificateAuthorityTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->certificateAuthorityName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]'); - $request = (new DeleteCertificateAuthorityRequest()) - ->setName($formattedName); - $response = $gapicClient->deleteCertificateAuthority($request); - $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.security.privateca.v1.CertificateAuthorityService/DeleteCertificateAuthority', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteCertificateAuthorityTest'); - $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 deleteCertificateAuthorityExceptionTest() - { - $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/deleteCertificateAuthorityTest'); - $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->certificateAuthorityName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]'); - $request = (new DeleteCertificateAuthorityRequest()) - ->setName($formattedName); - $response = $gapicClient->deleteCertificateAuthority($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteCertificateAuthorityTest'); - 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 deleteCertificateTemplateTest() - { - $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/deleteCertificateTemplateTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteCertificateTemplateTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->certificateTemplateName('[PROJECT]', '[LOCATION]', '[CERTIFICATE_TEMPLATE]'); - $request = (new DeleteCertificateTemplateRequest()) - ->setName($formattedName); - $response = $gapicClient->deleteCertificateTemplate($request); - $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.security.privateca.v1.CertificateAuthorityService/DeleteCertificateTemplate', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteCertificateTemplateTest'); - $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 deleteCertificateTemplateExceptionTest() - { - $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/deleteCertificateTemplateTest'); - $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->certificateTemplateName('[PROJECT]', '[LOCATION]', '[CERTIFICATE_TEMPLATE]'); - $request = (new DeleteCertificateTemplateRequest()) - ->setName($formattedName); - $response = $gapicClient->deleteCertificateTemplate($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteCertificateTemplateTest'); - 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 disableCertificateAuthorityTest() - { - $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/disableCertificateAuthorityTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name2 = 'name2-1052831874'; - $gcsBucket = 'gcsBucket-1720393710'; - $satisfiesPzs = false; - $satisfiesPzi = false; - $expectedResponse = new CertificateAuthority(); - $expectedResponse->setName($name2); - $expectedResponse->setGcsBucket($gcsBucket); - $expectedResponse->setSatisfiesPzs($satisfiesPzs); - $expectedResponse->setSatisfiesPzi($satisfiesPzi); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/disableCertificateAuthorityTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->certificateAuthorityName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]'); - $request = (new DisableCertificateAuthorityRequest()) - ->setName($formattedName); - $response = $gapicClient->disableCertificateAuthority($request); - $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.security.privateca.v1.CertificateAuthorityService/DisableCertificateAuthority', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/disableCertificateAuthorityTest'); - $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 disableCertificateAuthorityExceptionTest() - { - $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/disableCertificateAuthorityTest'); - $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->certificateAuthorityName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]'); - $request = (new DisableCertificateAuthorityRequest()) - ->setName($formattedName); - $response = $gapicClient->disableCertificateAuthority($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/disableCertificateAuthorityTest'); - 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 enableCertificateAuthorityTest() - { - $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/enableCertificateAuthorityTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name2 = 'name2-1052831874'; - $gcsBucket = 'gcsBucket-1720393710'; - $satisfiesPzs = false; - $satisfiesPzi = false; - $expectedResponse = new CertificateAuthority(); - $expectedResponse->setName($name2); - $expectedResponse->setGcsBucket($gcsBucket); - $expectedResponse->setSatisfiesPzs($satisfiesPzs); - $expectedResponse->setSatisfiesPzi($satisfiesPzi); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/enableCertificateAuthorityTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->certificateAuthorityName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]'); - $request = (new EnableCertificateAuthorityRequest()) - ->setName($formattedName); - $response = $gapicClient->enableCertificateAuthority($request); - $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.security.privateca.v1.CertificateAuthorityService/EnableCertificateAuthority', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/enableCertificateAuthorityTest'); - $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 enableCertificateAuthorityExceptionTest() - { - $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/enableCertificateAuthorityTest'); - $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->certificateAuthorityName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]'); - $request = (new EnableCertificateAuthorityRequest()) - ->setName($formattedName); - $response = $gapicClient->enableCertificateAuthority($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/enableCertificateAuthorityTest'); - 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 fetchCaCertsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new FetchCaCertsResponse(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedCaPool = $gapicClient->caPoolName('[PROJECT]', '[LOCATION]', '[CA_POOL]'); - $request = (new FetchCaCertsRequest()) - ->setCaPool($formattedCaPool); - $response = $gapicClient->fetchCaCerts($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.security.privateca.v1.CertificateAuthorityService/FetchCaCerts', $actualFuncCall); - $actualValue = $actualRequestObject->getCaPool(); - $this->assertProtobufEquals($formattedCaPool, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function fetchCaCertsExceptionTest() - { - $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 - $formattedCaPool = $gapicClient->caPoolName('[PROJECT]', '[LOCATION]', '[CA_POOL]'); - $request = (new FetchCaCertsRequest()) - ->setCaPool($formattedCaPool); - try { - $gapicClient->fetchCaCerts($request); - // 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 fetchCertificateAuthorityCsrTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $pemCsr = 'pemCsr-683665829'; - $expectedResponse = new FetchCertificateAuthorityCsrResponse(); - $expectedResponse->setPemCsr($pemCsr); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->certificateAuthorityName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]'); - $request = (new FetchCertificateAuthorityCsrRequest()) - ->setName($formattedName); - $response = $gapicClient->fetchCertificateAuthorityCsr($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.security.privateca.v1.CertificateAuthorityService/FetchCertificateAuthorityCsr', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function fetchCertificateAuthorityCsrExceptionTest() - { - $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->certificateAuthorityName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]'); - $request = (new FetchCertificateAuthorityCsrRequest()) - ->setName($formattedName); - try { - $gapicClient->fetchCertificateAuthorityCsr($request); - // 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 getCaPoolTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $expectedResponse = new CaPool(); - $expectedResponse->setName($name2); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->caPoolName('[PROJECT]', '[LOCATION]', '[CA_POOL]'); - $request = (new GetCaPoolRequest()) - ->setName($formattedName); - $response = $gapicClient->getCaPool($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.security.privateca.v1.CertificateAuthorityService/GetCaPool', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getCaPoolExceptionTest() - { - $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->caPoolName('[PROJECT]', '[LOCATION]', '[CA_POOL]'); - $request = (new GetCaPoolRequest()) - ->setName($formattedName); - try { - $gapicClient->getCaPool($request); - // 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 getCertificateTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $pemCsr = 'pemCsr-683665829'; - $issuerCertificateAuthority = 'issuerCertificateAuthority-750099051'; - $certificateTemplate = 'certificateTemplate2049676834'; - $pemCertificate = 'pemCertificate1234463984'; - $expectedResponse = new Certificate(); - $expectedResponse->setName($name2); - $expectedResponse->setPemCsr($pemCsr); - $expectedResponse->setIssuerCertificateAuthority($issuerCertificateAuthority); - $expectedResponse->setCertificateTemplate($certificateTemplate); - $expectedResponse->setPemCertificate($pemCertificate); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->certificateName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE]'); - $request = (new GetCertificateRequest()) - ->setName($formattedName); - $response = $gapicClient->getCertificate($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.security.privateca.v1.CertificateAuthorityService/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]', '[CA_POOL]', '[CERTIFICATE]'); - $request = (new GetCertificateRequest()) - ->setName($formattedName); - try { - $gapicClient->getCertificate($request); - // 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 getCertificateAuthorityTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $gcsBucket = 'gcsBucket-1720393710'; - $satisfiesPzs = false; - $satisfiesPzi = false; - $expectedResponse = new CertificateAuthority(); - $expectedResponse->setName($name2); - $expectedResponse->setGcsBucket($gcsBucket); - $expectedResponse->setSatisfiesPzs($satisfiesPzs); - $expectedResponse->setSatisfiesPzi($satisfiesPzi); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->certificateAuthorityName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]'); - $request = (new GetCertificateAuthorityRequest()) - ->setName($formattedName); - $response = $gapicClient->getCertificateAuthority($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.security.privateca.v1.CertificateAuthorityService/GetCertificateAuthority', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getCertificateAuthorityExceptionTest() - { - $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->certificateAuthorityName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]'); - $request = (new GetCertificateAuthorityRequest()) - ->setName($formattedName); - try { - $gapicClient->getCertificateAuthority($request); - // 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 getCertificateRevocationListTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $sequenceNumber = 1309190777; - $pemCrl = 'pemCrl-683665866'; - $accessUrl = 'accessUrl-1141680108'; - $revisionId = 'revisionId513861631'; - $expectedResponse = new CertificateRevocationList(); - $expectedResponse->setName($name2); - $expectedResponse->setSequenceNumber($sequenceNumber); - $expectedResponse->setPemCrl($pemCrl); - $expectedResponse->setAccessUrl($accessUrl); - $expectedResponse->setRevisionId($revisionId); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->certificateRevocationListName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]', '[CERTIFICATE_REVOCATION_LIST]'); - $request = (new GetCertificateRevocationListRequest()) - ->setName($formattedName); - $response = $gapicClient->getCertificateRevocationList($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.security.privateca.v1.CertificateAuthorityService/GetCertificateRevocationList', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getCertificateRevocationListExceptionTest() - { - $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->certificateRevocationListName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]', '[CERTIFICATE_REVOCATION_LIST]'); - $request = (new GetCertificateRevocationListRequest()) - ->setName($formattedName); - try { - $gapicClient->getCertificateRevocationList($request); - // 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 getCertificateTemplateTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $description = 'description-1724546052'; - $expectedResponse = new CertificateTemplate(); - $expectedResponse->setName($name2); - $expectedResponse->setDescription($description); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->certificateTemplateName('[PROJECT]', '[LOCATION]', '[CERTIFICATE_TEMPLATE]'); - $request = (new GetCertificateTemplateRequest()) - ->setName($formattedName); - $response = $gapicClient->getCertificateTemplate($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.security.privateca.v1.CertificateAuthorityService/GetCertificateTemplate', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getCertificateTemplateExceptionTest() - { - $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->certificateTemplateName('[PROJECT]', '[LOCATION]', '[CERTIFICATE_TEMPLATE]'); - $request = (new GetCertificateTemplateRequest()) - ->setName($formattedName); - try { - $gapicClient->getCertificateTemplate($request); - // 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 listCaPoolsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $caPoolsElement = new CaPool(); - $caPools = [ - $caPoolsElement, - ]; - $expectedResponse = new ListCaPoolsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setCaPools($caPools); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $request = (new ListCaPoolsRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listCaPools($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getCaPools()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.security.privateca.v1.CertificateAuthorityService/ListCaPools', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listCaPoolsExceptionTest() - { - $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]'); - $request = (new ListCaPoolsRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listCaPools($request); - // 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 listCertificateAuthoritiesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $certificateAuthoritiesElement = new CertificateAuthority(); - $certificateAuthorities = [ - $certificateAuthoritiesElement, - ]; - $expectedResponse = new ListCertificateAuthoritiesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setCertificateAuthorities($certificateAuthorities); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->caPoolName('[PROJECT]', '[LOCATION]', '[CA_POOL]'); - $request = (new ListCertificateAuthoritiesRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listCertificateAuthorities($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getCertificateAuthorities()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.security.privateca.v1.CertificateAuthorityService/ListCertificateAuthorities', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listCertificateAuthoritiesExceptionTest() - { - $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->caPoolName('[PROJECT]', '[LOCATION]', '[CA_POOL]'); - $request = (new ListCertificateAuthoritiesRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listCertificateAuthorities($request); - // 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 listCertificateRevocationListsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $certificateRevocationListsElement = new CertificateRevocationList(); - $certificateRevocationLists = [ - $certificateRevocationListsElement, - ]; - $expectedResponse = new ListCertificateRevocationListsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setCertificateRevocationLists($certificateRevocationLists); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->certificateAuthorityName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]'); - $request = (new ListCertificateRevocationListsRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listCertificateRevocationLists($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getCertificateRevocationLists()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.security.privateca.v1.CertificateAuthorityService/ListCertificateRevocationLists', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listCertificateRevocationListsExceptionTest() - { - $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->certificateAuthorityName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]'); - $request = (new ListCertificateRevocationListsRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listCertificateRevocationLists($request); - // 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 listCertificateTemplatesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $certificateTemplatesElement = new CertificateTemplate(); - $certificateTemplates = [ - $certificateTemplatesElement, - ]; - $expectedResponse = new ListCertificateTemplatesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setCertificateTemplates($certificateTemplates); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $request = (new ListCertificateTemplatesRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listCertificateTemplates($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getCertificateTemplates()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.security.privateca.v1.CertificateAuthorityService/ListCertificateTemplates', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listCertificateTemplatesExceptionTest() - { - $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]'); - $request = (new ListCertificateTemplatesRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listCertificateTemplates($request); - // 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->caPoolName('[PROJECT]', '[LOCATION]', '[CA_POOL]'); - $request = (new ListCertificatesRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listCertificates($request); - $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.security.privateca.v1.CertificateAuthorityService/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->caPoolName('[PROJECT]', '[LOCATION]', '[CA_POOL]'); - $request = (new ListCertificatesRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listCertificates($request); - // 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 revokeCertificateTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $pemCsr = 'pemCsr-683665829'; - $issuerCertificateAuthority = 'issuerCertificateAuthority-750099051'; - $certificateTemplate = 'certificateTemplate2049676834'; - $pemCertificate = 'pemCertificate1234463984'; - $expectedResponse = new Certificate(); - $expectedResponse->setName($name2); - $expectedResponse->setPemCsr($pemCsr); - $expectedResponse->setIssuerCertificateAuthority($issuerCertificateAuthority); - $expectedResponse->setCertificateTemplate($certificateTemplate); - $expectedResponse->setPemCertificate($pemCertificate); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->certificateName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE]'); - $reason = RevocationReason::REVOCATION_REASON_UNSPECIFIED; - $request = (new RevokeCertificateRequest()) - ->setName($formattedName) - ->setReason($reason); - $response = $gapicClient->revokeCertificate($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.security.privateca.v1.CertificateAuthorityService/RevokeCertificate', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $actualValue = $actualRequestObject->getReason(); - $this->assertProtobufEquals($reason, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function revokeCertificateExceptionTest() - { - $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]', '[CA_POOL]', '[CERTIFICATE]'); - $reason = RevocationReason::REVOCATION_REASON_UNSPECIFIED; - $request = (new RevokeCertificateRequest()) - ->setName($formattedName) - ->setReason($reason); - try { - $gapicClient->revokeCertificate($request); - // 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 undeleteCertificateAuthorityTest() - { - $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/undeleteCertificateAuthorityTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name2 = 'name2-1052831874'; - $gcsBucket = 'gcsBucket-1720393710'; - $satisfiesPzs = false; - $satisfiesPzi = false; - $expectedResponse = new CertificateAuthority(); - $expectedResponse->setName($name2); - $expectedResponse->setGcsBucket($gcsBucket); - $expectedResponse->setSatisfiesPzs($satisfiesPzs); - $expectedResponse->setSatisfiesPzi($satisfiesPzi); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/undeleteCertificateAuthorityTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->certificateAuthorityName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]'); - $request = (new UndeleteCertificateAuthorityRequest()) - ->setName($formattedName); - $response = $gapicClient->undeleteCertificateAuthority($request); - $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.security.privateca.v1.CertificateAuthorityService/UndeleteCertificateAuthority', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/undeleteCertificateAuthorityTest'); - $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 undeleteCertificateAuthorityExceptionTest() - { - $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/undeleteCertificateAuthorityTest'); - $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->certificateAuthorityName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]'); - $request = (new UndeleteCertificateAuthorityRequest()) - ->setName($formattedName); - $response = $gapicClient->undeleteCertificateAuthority($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/undeleteCertificateAuthorityTest'); - 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 updateCaPoolTest() - { - $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/updateCaPoolTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $expectedResponse = new CaPool(); - $expectedResponse->setName($name); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateCaPoolTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $caPool = new CaPool(); - $caPoolTier = Tier::TIER_UNSPECIFIED; - $caPool->setTier($caPoolTier); - $updateMask = new FieldMask(); - $request = (new UpdateCaPoolRequest()) - ->setCaPool($caPool) - ->setUpdateMask($updateMask); - $response = $gapicClient->updateCaPool($request); - $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.security.privateca.v1.CertificateAuthorityService/UpdateCaPool', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getCaPool(); - $this->assertProtobufEquals($caPool, $actualValue); - $actualValue = $actualApiRequestObject->getUpdateMask(); - $this->assertProtobufEquals($updateMask, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateCaPoolTest'); - $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 updateCaPoolExceptionTest() - { - $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/updateCaPoolTest'); - $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 - $caPool = new CaPool(); - $caPoolTier = Tier::TIER_UNSPECIFIED; - $caPool->setTier($caPoolTier); - $updateMask = new FieldMask(); - $request = (new UpdateCaPoolRequest()) - ->setCaPool($caPool) - ->setUpdateMask($updateMask); - $response = $gapicClient->updateCaPool($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateCaPoolTest'); - 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 updateCertificateTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $pemCsr = 'pemCsr-683665829'; - $issuerCertificateAuthority = 'issuerCertificateAuthority-750099051'; - $certificateTemplate = 'certificateTemplate2049676834'; - $pemCertificate = 'pemCertificate1234463984'; - $expectedResponse = new Certificate(); - $expectedResponse->setName($name); - $expectedResponse->setPemCsr($pemCsr); - $expectedResponse->setIssuerCertificateAuthority($issuerCertificateAuthority); - $expectedResponse->setCertificateTemplate($certificateTemplate); - $expectedResponse->setPemCertificate($pemCertificate); - $transport->addResponse($expectedResponse); - // Mock request - $certificate = new Certificate(); - $certificateLifetime = new Duration(); - $certificate->setLifetime($certificateLifetime); - $updateMask = new FieldMask(); - $request = (new UpdateCertificateRequest()) - ->setCertificate($certificate) - ->setUpdateMask($updateMask); - $response = $gapicClient->updateCertificate($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.security.privateca.v1.CertificateAuthorityService/UpdateCertificate', $actualFuncCall); - $actualValue = $actualRequestObject->getCertificate(); - $this->assertProtobufEquals($certificate, $actualValue); - $actualValue = $actualRequestObject->getUpdateMask(); - $this->assertProtobufEquals($updateMask, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateCertificateExceptionTest() - { - $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 - $certificate = new Certificate(); - $certificateLifetime = new Duration(); - $certificate->setLifetime($certificateLifetime); - $updateMask = new FieldMask(); - $request = (new UpdateCertificateRequest()) - ->setCertificate($certificate) - ->setUpdateMask($updateMask); - try { - $gapicClient->updateCertificate($request); - // 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 updateCertificateAuthorityTest() - { - $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/updateCertificateAuthorityTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $gcsBucket = 'gcsBucket-1720393710'; - $satisfiesPzs = false; - $satisfiesPzi = false; - $expectedResponse = new CertificateAuthority(); - $expectedResponse->setName($name); - $expectedResponse->setGcsBucket($gcsBucket); - $expectedResponse->setSatisfiesPzs($satisfiesPzs); - $expectedResponse->setSatisfiesPzi($satisfiesPzi); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateCertificateAuthorityTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $certificateAuthority = new CertificateAuthority(); - $certificateAuthorityType = Type::TYPE_UNSPECIFIED; - $certificateAuthority->setType($certificateAuthorityType); - $certificateAuthorityConfig = new CertificateConfig(); - $configSubjectConfig = new SubjectConfig(); - $certificateAuthorityConfig->setSubjectConfig($configSubjectConfig); - $configX509Config = new X509Parameters(); - $certificateAuthorityConfig->setX509Config($configX509Config); - $certificateAuthority->setConfig($certificateAuthorityConfig); - $certificateAuthorityLifetime = new Duration(); - $certificateAuthority->setLifetime($certificateAuthorityLifetime); - $certificateAuthorityKeySpec = new KeyVersionSpec(); - $certificateAuthority->setKeySpec($certificateAuthorityKeySpec); - $updateMask = new FieldMask(); - $request = (new UpdateCertificateAuthorityRequest()) - ->setCertificateAuthority($certificateAuthority) - ->setUpdateMask($updateMask); - $response = $gapicClient->updateCertificateAuthority($request); - $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.security.privateca.v1.CertificateAuthorityService/UpdateCertificateAuthority', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getCertificateAuthority(); - $this->assertProtobufEquals($certificateAuthority, $actualValue); - $actualValue = $actualApiRequestObject->getUpdateMask(); - $this->assertProtobufEquals($updateMask, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateCertificateAuthorityTest'); - $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 updateCertificateAuthorityExceptionTest() - { - $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/updateCertificateAuthorityTest'); - $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 - $certificateAuthority = new CertificateAuthority(); - $certificateAuthorityType = Type::TYPE_UNSPECIFIED; - $certificateAuthority->setType($certificateAuthorityType); - $certificateAuthorityConfig = new CertificateConfig(); - $configSubjectConfig = new SubjectConfig(); - $certificateAuthorityConfig->setSubjectConfig($configSubjectConfig); - $configX509Config = new X509Parameters(); - $certificateAuthorityConfig->setX509Config($configX509Config); - $certificateAuthority->setConfig($certificateAuthorityConfig); - $certificateAuthorityLifetime = new Duration(); - $certificateAuthority->setLifetime($certificateAuthorityLifetime); - $certificateAuthorityKeySpec = new KeyVersionSpec(); - $certificateAuthority->setKeySpec($certificateAuthorityKeySpec); - $updateMask = new FieldMask(); - $request = (new UpdateCertificateAuthorityRequest()) - ->setCertificateAuthority($certificateAuthority) - ->setUpdateMask($updateMask); - $response = $gapicClient->updateCertificateAuthority($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateCertificateAuthorityTest'); - 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 updateCertificateRevocationListTest() - { - $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/updateCertificateRevocationListTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $sequenceNumber = 1309190777; - $pemCrl = 'pemCrl-683665866'; - $accessUrl = 'accessUrl-1141680108'; - $revisionId = 'revisionId513861631'; - $expectedResponse = new CertificateRevocationList(); - $expectedResponse->setName($name); - $expectedResponse->setSequenceNumber($sequenceNumber); - $expectedResponse->setPemCrl($pemCrl); - $expectedResponse->setAccessUrl($accessUrl); - $expectedResponse->setRevisionId($revisionId); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateCertificateRevocationListTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $certificateRevocationList = new CertificateRevocationList(); - $updateMask = new FieldMask(); - $request = (new UpdateCertificateRevocationListRequest()) - ->setCertificateRevocationList($certificateRevocationList) - ->setUpdateMask($updateMask); - $response = $gapicClient->updateCertificateRevocationList($request); - $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.security.privateca.v1.CertificateAuthorityService/UpdateCertificateRevocationList', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getCertificateRevocationList(); - $this->assertProtobufEquals($certificateRevocationList, $actualValue); - $actualValue = $actualApiRequestObject->getUpdateMask(); - $this->assertProtobufEquals($updateMask, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateCertificateRevocationListTest'); - $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 updateCertificateRevocationListExceptionTest() - { - $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/updateCertificateRevocationListTest'); - $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 - $certificateRevocationList = new CertificateRevocationList(); - $updateMask = new FieldMask(); - $request = (new UpdateCertificateRevocationListRequest()) - ->setCertificateRevocationList($certificateRevocationList) - ->setUpdateMask($updateMask); - $response = $gapicClient->updateCertificateRevocationList($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateCertificateRevocationListTest'); - 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 updateCertificateTemplateTest() - { - $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/updateCertificateTemplateTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $description = 'description-1724546052'; - $expectedResponse = new CertificateTemplate(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateCertificateTemplateTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $certificateTemplate = new CertificateTemplate(); - $updateMask = new FieldMask(); - $request = (new UpdateCertificateTemplateRequest()) - ->setCertificateTemplate($certificateTemplate) - ->setUpdateMask($updateMask); - $response = $gapicClient->updateCertificateTemplate($request); - $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.security.privateca.v1.CertificateAuthorityService/UpdateCertificateTemplate', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getCertificateTemplate(); - $this->assertProtobufEquals($certificateTemplate, $actualValue); - $actualValue = $actualApiRequestObject->getUpdateMask(); - $this->assertProtobufEquals($updateMask, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateCertificateTemplateTest'); - $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 updateCertificateTemplateExceptionTest() - { - $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/updateCertificateTemplateTest'); - $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 - $certificateTemplate = new CertificateTemplate(); - $updateMask = new FieldMask(); - $request = (new UpdateCertificateTemplateRequest()) - ->setCertificateTemplate($certificateTemplate) - ->setUpdateMask($updateMask); - $response = $gapicClient->updateCertificateTemplate($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateCertificateTemplateTest'); - 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); - $request = new GetLocationRequest(); - $response = $gapicClient->getLocation($request); - $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); - $request = new GetLocationRequest(); - try { - $gapicClient->getLocation($request); - // 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); - $request = new ListLocationsRequest(); - $response = $gapicClient->listLocations($request); - $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); - $request = new ListLocationsRequest(); - try { - $gapicClient->listLocations($request); - // 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'; - $request = (new GetIamPolicyRequest()) - ->setResource($resource); - $response = $gapicClient->getIamPolicy($request); - $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'; - $request = (new GetIamPolicyRequest()) - ->setResource($resource); - try { - $gapicClient->getIamPolicy($request); - // 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(); - $request = (new SetIamPolicyRequest()) - ->setResource($resource) - ->setPolicy($policy); - $response = $gapicClient->setIamPolicy($request); - $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(); - $request = (new SetIamPolicyRequest()) - ->setResource($resource) - ->setPolicy($policy); - try { - $gapicClient->setIamPolicy($request); - // 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 = []; - $request = (new TestIamPermissionsRequest()) - ->setResource($resource) - ->setPermissions($permissions); - $response = $gapicClient->testIamPermissions($request); - $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 = []; - $request = (new TestIamPermissionsRequest()) - ->setResource($resource) - ->setPermissions($permissions); - try { - $gapicClient->testIamPermissions($request); - // 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 activateCertificateAuthorityAsyncTest() - { - $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/activateCertificateAuthorityTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name2 = 'name2-1052831874'; - $gcsBucket = 'gcsBucket-1720393710'; - $satisfiesPzs = false; - $satisfiesPzi = false; - $expectedResponse = new CertificateAuthority(); - $expectedResponse->setName($name2); - $expectedResponse->setGcsBucket($gcsBucket); - $expectedResponse->setSatisfiesPzs($satisfiesPzs); - $expectedResponse->setSatisfiesPzi($satisfiesPzi); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/activateCertificateAuthorityTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->certificateAuthorityName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]'); - $pemCaCertificate = 'pemCaCertificate1041594685'; - $subordinateConfig = new SubordinateConfig(); - $subordinateConfigCertificateAuthority = $gapicClient->certificateAuthorityName('[PROJECT]', '[LOCATION]', '[CA_POOL]', '[CERTIFICATE_AUTHORITY]'); - $subordinateConfig->setCertificateAuthority($subordinateConfigCertificateAuthority); - $request = (new ActivateCertificateAuthorityRequest()) - ->setName($formattedName) - ->setPemCaCertificate($pemCaCertificate) - ->setSubordinateConfig($subordinateConfig); - $response = $gapicClient->activateCertificateAuthorityAsync($request)->wait(); - $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.security.privateca.v1.CertificateAuthorityService/ActivateCertificateAuthority', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $actualValue = $actualApiRequestObject->getPemCaCertificate(); - $this->assertProtobufEquals($pemCaCertificate, $actualValue); - $actualValue = $actualApiRequestObject->getSubordinateConfig(); - $this->assertProtobufEquals($subordinateConfig, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/activateCertificateAuthorityTest'); - $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()); - } -} diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/GPBMetadata/Google/Api/Servicemanagement/V1/Resources.php b/owl-bot-staging/ServiceManagement/v1/proto/src/GPBMetadata/Google/Api/Servicemanagement/V1/Resources.php deleted file mode 100644 index ed8e9e4a6998..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/proto/src/GPBMetadata/Google/Api/Servicemanagement/V1/Resources.php +++ /dev/null @@ -1,27 +0,0 @@ -internalAddGeneratedFile( - "\x0A\xD5\x11\x0A/google/api/servicemanagement/v1/resources.proto\x12\x1Fgoogle.api.servicemanagement.v1\x1A\x1Fgoogle/api/field_behavior.proto\x1A\x1Fgoogle/protobuf/timestamp.proto\"C\x0A\x0EManagedService\x12\x14\x0A\x0Cservice_name\x18\x02 \x01(\x09\x12\x1B\x0A\x13producer_project_id\x18\x03 \x01(\x09\"\x91\x03\x0A\x11OperationMetadata\x12\x16\x0A\x0Eresource_names\x18\x01 \x03(\x09\x12F\x0A\x05steps\x18\x02 \x03(\x0B27.google.api.servicemanagement.v1.OperationMetadata.Step\x12\x1B\x0A\x13progress_percentage\x18\x03 \x01(\x05\x12.\x0A\x0Astart_time\x18\x04 \x01(\x0B2\x1A.google.protobuf.Timestamp\x1Af\x0A\x04Step\x12\x13\x0A\x0Bdescription\x18\x02 \x01(\x09\x12I\x0A\x06status\x18\x04 \x01(\x0E29.google.api.servicemanagement.v1.OperationMetadata.Status\"g\x0A\x06Status\x12\x16\x0A\x12STATUS_UNSPECIFIED\x10\x00\x12\x08\x0A\x04DONE\x10\x01\x12\x0F\x0A\x0BNOT_STARTED\x10\x02\x12\x0F\x0A\x0BIN_PROGRESS\x10\x03\x12\x0A\x0A\x06FAILED\x10\x04\x12\x0D\x0A\x09CANCELLED\x10\x05\"\x8F\x01\x0A\x0ADiagnostic\x12\x10\x0A\x08location\x18\x01 \x01(\x09\x12>\x0A\x04kind\x18\x02 \x01(\x0E20.google.api.servicemanagement.v1.Diagnostic.Kind\x12\x0F\x0A\x07message\x18\x03 \x01(\x09\"\x1E\x0A\x04Kind\x12\x0B\x0A\x07WARNING\x10\x00\x12\x09\x0A\x05ERROR\x10\x01\"V\x0A\x0CConfigSource\x12\x0A\x0A\x02id\x18\x05 \x01(\x09\x12:\x0A\x05files\x18\x02 \x03(\x0B2+.google.api.servicemanagement.v1.ConfigFile\"\x95\x02\x0A\x0AConfigFile\x12\x11\x0A\x09file_path\x18\x01 \x01(\x09\x12\x15\x0A\x0Dfile_contents\x18\x03 \x01(\x0C\x12G\x0A\x09file_type\x18\x04 \x01(\x0E24.google.api.servicemanagement.v1.ConfigFile.FileType\"\x93\x01\x0A\x08FileType\x12\x19\x0A\x15FILE_TYPE_UNSPECIFIED\x10\x00\x12\x17\x0A\x13SERVICE_CONFIG_YAML\x10\x01\x12\x11\x0A\x0DOPEN_API_JSON\x10\x02\x12\x11\x0A\x0DOPEN_API_YAML\x10\x03\x12\x1D\x0A\x19FILE_DESCRIPTOR_SET_PROTO\x10\x04\x12\x0E\x0A\x0APROTO_FILE\x10\x06\"\x19\x0A\x09ConfigRef\x12\x0C\x0A\x04name\x18\x01 \x01(\x09\"@\x0A\x0CChangeReport\x120\x0A\x0Econfig_changes\x18\x01 \x03(\x0B2\x18.google.api.ConfigChange\"\xF9\x05\x0A\x07Rollout\x12\x17\x0A\x0Arollout_id\x18\x01 \x01(\x09B\x03\xE0A\x01\x12/\x0A\x0Bcreate_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.Timestamp\x12\x12\x0A\x0Acreated_by\x18\x03 \x01(\x09\x12F\x0A\x06status\x18\x04 \x01(\x0E26.google.api.servicemanagement.v1.Rollout.RolloutStatus\x12c\x0A\x18traffic_percent_strategy\x18\x05 \x01(\x0B2?.google.api.servicemanagement.v1.Rollout.TrafficPercentStrategyH\x00\x12b\x0A\x17delete_service_strategy\x18\xC8\x01 \x01(\x0B2>.google.api.servicemanagement.v1.Rollout.DeleteServiceStrategyH\x00\x12\x14\x0A\x0Cservice_name\x18\x08 \x01(\x09\x1A\xB3\x01\x0A\x16TrafficPercentStrategy\x12e\x0A\x0Bpercentages\x18\x01 \x03(\x0B2P.google.api.servicemanagement.v1.Rollout.TrafficPercentStrategy.PercentagesEntry\x1A2\x0A\x10PercentagesEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12\x0D\x0A\x05value\x18\x02 \x01(\x01:\x028\x01\x1A\x17\x0A\x15DeleteServiceStrategy\"\x8D\x01\x0A\x0DRolloutStatus\x12\x1E\x0A\x1AROLLOUT_STATUS_UNSPECIFIED\x10\x00\x12\x0F\x0A\x0BIN_PROGRESS\x10\x01\x12\x0B\x0A\x07SUCCESS\x10\x02\x12\x0D\x0A\x09CANCELLED\x10\x03\x12\x0A\x0A\x06FAILED\x10\x04\x12\x0B\x0A\x07PENDING\x10\x05\x12\x16\x0A\x12FAILED_ROLLED_BACK\x10\x06B\x0A\x0A\x08strategyB\x82\x02\x0A#com.google.api.servicemanagement.v1B\x0EResourcesProtoP\x01ZScloud.google.com/go/servicemanagement/apiv1/servicemanagementpb;servicemanagementpb\xA2\x02\x04GASM\xAA\x02!Google.Cloud.ServiceManagement.V1\xCA\x02!Google\\Cloud\\ServiceManagement\\V1\xEA\x02\$Google::Cloud::ServiceManagement::V1b\x06proto3" - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/GPBMetadata/Google/Api/Servicemanagement/V1/Servicemanager.php b/owl-bot-staging/ServiceManagement/v1/proto/src/GPBMetadata/Google/Api/Servicemanagement/V1/Servicemanager.php deleted file mode 100644 index b20a66c1e099..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/proto/src/GPBMetadata/Google/Api/Servicemanagement/V1/Servicemanager.php +++ /dev/null @@ -1,32 +0,0 @@ -internalAddGeneratedFile( - "\x0A\xC6.\x0A4google/api/servicemanagement/v1/servicemanager.proto\x12\x1Fgoogle.api.servicemanagement.v1\x1A\x17google/api/client.proto\x1A\x1Fgoogle/api/field_behavior.proto\x1A\x18google/api/service.proto\x1A/google/api/servicemanagement/v1/resources.proto\x1A#google/longrunning/operations.proto\x1A\x19google/protobuf/any.proto\x1A\x1Bgoogle/protobuf/empty.proto\"r\x0A\x13ListServicesRequest\x12\x1B\x0A\x13producer_project_id\x18\x01 \x01(\x09\x12\x11\x0A\x09page_size\x18\x05 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x06 \x01(\x09\x12\x17\x0A\x0Bconsumer_id\x18\x07 \x01(\x09B\x02\x18\x01\"r\x0A\x14ListServicesResponse\x12A\x0A\x08services\x18\x01 \x03(\x0B2/.google.api.servicemanagement.v1.ManagedService\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\".\x0A\x11GetServiceRequest\x12\x19\x0A\x0Cservice_name\x18\x01 \x01(\x09B\x03\xE0A\x02\"]\x0A\x14CreateServiceRequest\x12E\x0A\x07service\x18\x01 \x01(\x0B2/.google.api.servicemanagement.v1.ManagedServiceB\x03\xE0A\x02\"1\x0A\x14DeleteServiceRequest\x12\x19\x0A\x0Cservice_name\x18\x01 \x01(\x09B\x03\xE0A\x02\"3\x0A\x16UndeleteServiceRequest\x12\x19\x0A\x0Cservice_name\x18\x01 \x01(\x09B\x03\xE0A\x02\"[\x0A\x17UndeleteServiceResponse\x12@\x0A\x07service\x18\x01 \x01(\x0B2/.google.api.servicemanagement.v1.ManagedService\"\xC2\x01\x0A\x17GetServiceConfigRequest\x12\x19\x0A\x0Cservice_name\x18\x01 \x01(\x09B\x03\xE0A\x02\x12\x16\x0A\x09config_id\x18\x02 \x01(\x09B\x03\xE0A\x02\x12Q\x0A\x04view\x18\x03 \x01(\x0E2C.google.api.servicemanagement.v1.GetServiceConfigRequest.ConfigView\"!\x0A\x0AConfigView\x12\x09\x0A\x05BASIC\x10\x00\x12\x08\x0A\x04FULL\x10\x01\"]\x0A\x19ListServiceConfigsRequest\x12\x19\x0A\x0Cservice_name\x18\x01 \x01(\x09B\x03\xE0A\x02\x12\x12\x0A\x0Apage_token\x18\x02 \x01(\x09\x12\x11\x0A\x09page_size\x18\x03 \x01(\x05\"c\x0A\x1AListServiceConfigsResponse\x12,\x0A\x0Fservice_configs\x18\x01 \x03(\x0B2\x13.google.api.Service\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\"i\x0A\x1ACreateServiceConfigRequest\x12\x19\x0A\x0Cservice_name\x18\x01 \x01(\x09B\x03\xE0A\x02\x120\x0A\x0Eservice_config\x18\x02 \x01(\x0B2\x13.google.api.ServiceB\x03\xE0A\x02\"\x9D\x01\x0A\x19SubmitConfigSourceRequest\x12\x19\x0A\x0Cservice_name\x18\x01 \x01(\x09B\x03\xE0A\x02\x12I\x0A\x0Dconfig_source\x18\x02 \x01(\x0B2-.google.api.servicemanagement.v1.ConfigSourceB\x03\xE0A\x02\x12\x1A\x0A\x0Dvalidate_only\x18\x03 \x01(\x08B\x03\xE0A\x01\"I\x0A\x1ASubmitConfigSourceResponse\x12+\x0A\x0Eservice_config\x18\x01 \x01(\x0B2\x13.google.api.Service\"x\x0A\x1BCreateServiceRolloutRequest\x12\x19\x0A\x0Cservice_name\x18\x01 \x01(\x09B\x03\xE0A\x02\x12>\x0A\x07rollout\x18\x02 \x01(\x0B2(.google.api.servicemanagement.v1.RolloutB\x03\xE0A\x02\"s\x0A\x1AListServiceRolloutsRequest\x12\x19\x0A\x0Cservice_name\x18\x01 \x01(\x09B\x03\xE0A\x02\x12\x12\x0A\x0Apage_token\x18\x02 \x01(\x09\x12\x11\x0A\x09page_size\x18\x03 \x01(\x05\x12\x13\x0A\x06filter\x18\x04 \x01(\x09B\x03\xE0A\x02\"r\x0A\x1BListServiceRolloutsResponse\x12:\x0A\x08rollouts\x18\x01 \x03(\x0B2(.google.api.servicemanagement.v1.Rollout\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\"N\x0A\x18GetServiceRolloutRequest\x12\x19\x0A\x0Cservice_name\x18\x01 \x01(\x09B\x03\xE0A\x02\x12\x17\x0A\x0Arollout_id\x18\x02 \x01(\x09B\x03\xE0A\x02\"\x17\x0A\x15EnableServiceResponse\"{\x0A\x1BGenerateConfigReportRequest\x12-\x0A\x0Anew_config\x18\x01 \x01(\x0B2\x14.google.protobuf.AnyB\x03\xE0A\x02\x12-\x0A\x0Aold_config\x18\x02 \x01(\x0B2\x14.google.protobuf.AnyB\x03\xE0A\x01\"\xC9\x01\x0A\x1CGenerateConfigReportResponse\x12\x14\x0A\x0Cservice_name\x18\x01 \x01(\x09\x12\x0A\x0A\x02id\x18\x02 \x01(\x09\x12E\x0A\x0Echange_reports\x18\x03 \x03(\x0B2-.google.api.servicemanagement.v1.ChangeReport\x12@\x0A\x0Bdiagnostics\x18\x04 \x03(\x0B2+.google.api.servicemanagement.v1.Diagnostic2\xC8\x19\x0A\x0EServiceManager\x12\xB3\x01\x0A\x0CListServices\x124.google.api.servicemanagement.v1.ListServicesRequest\x1A5.google.api.servicemanagement.v1.ListServicesResponse\"6\xDAA\x1Fproducer_project_id,consumer_id\x82\xD3\xE4\x93\x02\x0E\x12\x0C/v1/services\x12\xA5\x01\x0A\x0AGetService\x122.google.api.servicemanagement.v1.GetServiceRequest\x1A/.google.api.servicemanagement.v1.ManagedService\"2\xDAA\x0Cservice_name\x82\xD3\xE4\x93\x02\x1D\x12\x1B/v1/services/{service_name}\x12\xF5\x01\x0A\x0DCreateService\x125.google.api.servicemanagement.v1.CreateServiceRequest\x1A\x1D.google.longrunning.Operation\"\x8D\x01\xCAAc\x0A.google.api.servicemanagement.v1.ManagedService\x121google.api.servicemanagement.v1.OperationMetadata\xDAA\x07service\x82\xD3\xE4\x93\x02\x17\"\x0C/v1/services:\x07service\x12\xE6\x01\x0A\x0DDeleteService\x125.google.api.servicemanagement.v1.DeleteServiceRequest\x1A\x1D.google.longrunning.Operation\"\x7F\xCAAJ\x0A\x15google.protobuf.Empty\x121google.api.servicemanagement.v1.OperationMetadata\xDAA\x0Cservice_name\x82\xD3\xE4\x93\x02\x1D*\x1B/v1/services/{service_name}\x12\x96\x02\x0A\x0FUndeleteService\x127.google.api.servicemanagement.v1.UndeleteServiceRequest\x1A\x1D.google.longrunning.Operation\"\xAA\x01\xCAAl\x0A7google.api.servicemanagement.v1.UndeleteServiceResponse\x121google.api.servicemanagement.v1.OperationMetadata\xDAA\x0Cservice_name\x82\xD3\xE4\x93\x02&\"\$/v1/services/{service_name}:undelete\x12\xC9\x01\x0A\x12ListServiceConfigs\x12:.google.api.servicemanagement.v1.ListServiceConfigsRequest\x1A;.google.api.servicemanagement.v1.ListServiceConfigsResponse\":\xDAA\x0Cservice_name\x82\xD3\xE4\x93\x02%\x12#/v1/services/{service_name}/configs\x12\xDE\x01\x0A\x10GetServiceConfig\x128.google.api.servicemanagement.v1.GetServiceConfigRequest\x1A\x13.google.api.Service\"{\xDAA\x1Bservice_name,config_id,view\x82\xD3\xE4\x93\x02W\x12//v1/services/{service_name}/configs/{config_id}Z\$\x12\"/v1/services/{service_name}/config\x12\xC2\x01\x0A\x13CreateServiceConfig\x12;.google.api.servicemanagement.v1.CreateServiceConfigRequest\x1A\x13.google.api.Service\"Y\xDAA\x1Bservice_name,service_config\x82\xD3\xE4\x93\x025\"#/v1/services/{service_name}/configs:\x0Eservice_config\x12\xC4\x02\x0A\x12SubmitConfigSource\x12:.google.api.servicemanagement.v1.SubmitConfigSourceRequest\x1A\x1D.google.longrunning.Operation\"\xD2\x01\xCAAo\x0A:google.api.servicemanagement.v1.SubmitConfigSourceResponse\x121google.api.servicemanagement.v1.OperationMetadata\xDAA(service_name,config_source,validate_only\x82\xD3\xE4\x93\x02/\"*/v1/services/{service_name}/configs:submit:\x01*\x12\xD4\x01\x0A\x13ListServiceRollouts\x12;.google.api.servicemanagement.v1.ListServiceRolloutsRequest\x1A<.google.api.servicemanagement.v1.ListServiceRolloutsResponse\"B\xDAA\x13service_name,filter\x82\xD3\xE4\x93\x02&\x12\$/v1/services/{service_name}/rollouts\x12\xCD\x01\x0A\x11GetServiceRollout\x129.google.api.servicemanagement.v1.GetServiceRolloutRequest\x1A(.google.api.servicemanagement.v1.Rollout\"S\xDAA\x17service_name,rollout_id\x82\xD3\xE4\x93\x023\x121/v1/services/{service_name}/rollouts/{rollout_id}\x12\xA1\x02\x0A\x14CreateServiceRollout\x12<.google.api.servicemanagement.v1.CreateServiceRolloutRequest\x1A\x1D.google.longrunning.Operation\"\xAB\x01\xCAA\\\x0A'google.api.servicemanagement.v1.Rollout\x121google.api.servicemanagement.v1.OperationMetadata\xDAA\x14service_name,rollout\x82\xD3\xE4\x93\x02/\"\$/v1/services/{service_name}/rollouts:\x07rollout\x12\xD9\x01\x0A\x14GenerateConfigReport\x12<.google.api.servicemanagement.v1.GenerateConfigReportRequest\x1A=.google.api.servicemanagement.v1.GenerateConfigReportResponse\"D\xDAA\x15new_config,old_config\x82\xD3\xE4\x93\x02&\"!/v1/services:generateConfigReport:\x01*\x1A\xFD\x01\xCAA servicemanagement.googleapis.com\xD2A\xD6\x01https://www.googleapis.com/auth/cloud-platform,https://www.googleapis.com/auth/cloud-platform.read-only,https://www.googleapis.com/auth/service.management,https://www.googleapis.com/auth/service.management.readonlyB\x87\x02\x0A#com.google.api.servicemanagement.v1B\x13ServiceManagerProtoP\x01ZScloud.google.com/go/servicemanagement/apiv1/servicemanagementpb;servicemanagementpb\xA2\x02\x04GASM\xAA\x02!Google.Cloud.ServiceManagement.V1\xCA\x02!Google\\Cloud\\ServiceManagement\\V1\xEA\x02\$Google::Cloud::ServiceManagement::V1b\x06proto3" - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ChangeReport.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ChangeReport.php deleted file mode 100644 index b0ebbfc0c19a..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ChangeReport.php +++ /dev/null @@ -1,85 +0,0 @@ -google.api.servicemanagement.v1.ChangeReport - */ -class ChangeReport extends \Google\Protobuf\Internal\Message -{ - /** - * List of changes between two service configurations. - * The changes will be alphabetically sorted based on the identifier - * of each change. - * A ConfigChange identifier is a dot separated path to the configuration. - * Example: visibility.rules[selector='LibraryService.CreateBook'].restriction - * - * Generated from protobuf field repeated .google.api.ConfigChange config_changes = 1; - */ - private $config_changes; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Api\ConfigChange[] $config_changes - * List of changes between two service configurations. - * The changes will be alphabetically sorted based on the identifier - * of each change. - * A ConfigChange identifier is a dot separated path to the configuration. - * Example: visibility.rules[selector='LibraryService.CreateBook'].restriction - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Servicemanagement\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * List of changes between two service configurations. - * The changes will be alphabetically sorted based on the identifier - * of each change. - * A ConfigChange identifier is a dot separated path to the configuration. - * Example: visibility.rules[selector='LibraryService.CreateBook'].restriction - * - * Generated from protobuf field repeated .google.api.ConfigChange config_changes = 1; - * @return RepeatedField<\Google\Api\ConfigChange> - */ - public function getConfigChanges() - { - return $this->config_changes; - } - - /** - * List of changes between two service configurations. - * The changes will be alphabetically sorted based on the identifier - * of each change. - * A ConfigChange identifier is a dot separated path to the configuration. - * Example: visibility.rules[selector='LibraryService.CreateBook'].restriction - * - * Generated from protobuf field repeated .google.api.ConfigChange config_changes = 1; - * @param \Google\Api\ConfigChange[] $var - * @return $this - */ - public function setConfigChanges($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Api\ConfigChange::class); - $this->config_changes = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ConfigFile.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ConfigFile.php deleted file mode 100644 index 2d558c9d1844..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ConfigFile.php +++ /dev/null @@ -1,135 +0,0 @@ -google.api.servicemanagement.v1.ConfigFile - */ -class ConfigFile extends \Google\Protobuf\Internal\Message -{ - /** - * The file name of the configuration file (full or relative path). - * - * Generated from protobuf field string file_path = 1; - */ - protected $file_path = ''; - /** - * The bytes that constitute the file. - * - * Generated from protobuf field bytes file_contents = 3; - */ - protected $file_contents = ''; - /** - * The type of configuration file this represents. - * - * Generated from protobuf field .google.api.servicemanagement.v1.ConfigFile.FileType file_type = 4; - */ - protected $file_type = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $file_path - * The file name of the configuration file (full or relative path). - * @type string $file_contents - * The bytes that constitute the file. - * @type int $file_type - * The type of configuration file this represents. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Servicemanagement\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * The file name of the configuration file (full or relative path). - * - * Generated from protobuf field string file_path = 1; - * @return string - */ - public function getFilePath() - { - return $this->file_path; - } - - /** - * The file name of the configuration file (full or relative path). - * - * Generated from protobuf field string file_path = 1; - * @param string $var - * @return $this - */ - public function setFilePath($var) - { - GPBUtil::checkString($var, True); - $this->file_path = $var; - - return $this; - } - - /** - * The bytes that constitute the file. - * - * Generated from protobuf field bytes file_contents = 3; - * @return string - */ - public function getFileContents() - { - return $this->file_contents; - } - - /** - * The bytes that constitute the file. - * - * Generated from protobuf field bytes file_contents = 3; - * @param string $var - * @return $this - */ - public function setFileContents($var) - { - GPBUtil::checkString($var, False); - $this->file_contents = $var; - - return $this; - } - - /** - * The type of configuration file this represents. - * - * Generated from protobuf field .google.api.servicemanagement.v1.ConfigFile.FileType file_type = 4; - * @return int - */ - public function getFileType() - { - return $this->file_type; - } - - /** - * The type of configuration file this represents. - * - * Generated from protobuf field .google.api.servicemanagement.v1.ConfigFile.FileType file_type = 4; - * @param int $var - * @return $this - */ - public function setFileType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\ServiceManagement\V1\ConfigFile\FileType::class); - $this->file_type = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ConfigFile/FileType.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ConfigFile/FileType.php deleted file mode 100644 index b74e194525ef..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ConfigFile/FileType.php +++ /dev/null @@ -1,88 +0,0 @@ -google.api.servicemanagement.v1.ConfigFile.FileType - */ -class FileType -{ - /** - * Unknown file type. - * - * Generated from protobuf enum FILE_TYPE_UNSPECIFIED = 0; - */ - const FILE_TYPE_UNSPECIFIED = 0; - /** - * YAML-specification of service. - * - * Generated from protobuf enum SERVICE_CONFIG_YAML = 1; - */ - const SERVICE_CONFIG_YAML = 1; - /** - * OpenAPI specification, serialized in JSON. - * - * Generated from protobuf enum OPEN_API_JSON = 2; - */ - const OPEN_API_JSON = 2; - /** - * OpenAPI specification, serialized in YAML. - * - * Generated from protobuf enum OPEN_API_YAML = 3; - */ - const OPEN_API_YAML = 3; - /** - * FileDescriptorSet, generated by protoc. - * To generate, use protoc with imports and source info included. - * For an example test.proto file, the following command would put the value - * in a new file named out.pb. - * $protoc --include_imports --include_source_info test.proto -o out.pb - * - * Generated from protobuf enum FILE_DESCRIPTOR_SET_PROTO = 4; - */ - const FILE_DESCRIPTOR_SET_PROTO = 4; - /** - * Uncompiled Proto file. Used for storage and display purposes only, - * currently server-side compilation is not supported. Should match the - * inputs to 'protoc' command used to generated FILE_DESCRIPTOR_SET_PROTO. A - * file of this type can only be included if at least one file of type - * FILE_DESCRIPTOR_SET_PROTO is included. - * - * Generated from protobuf enum PROTO_FILE = 6; - */ - const PROTO_FILE = 6; - - private static $valueToName = [ - self::FILE_TYPE_UNSPECIFIED => 'FILE_TYPE_UNSPECIFIED', - self::SERVICE_CONFIG_YAML => 'SERVICE_CONFIG_YAML', - self::OPEN_API_JSON => 'OPEN_API_JSON', - self::OPEN_API_YAML => 'OPEN_API_YAML', - self::FILE_DESCRIPTOR_SET_PROTO => 'FILE_DESCRIPTOR_SET_PROTO', - self::PROTO_FILE => 'PROTO_FILE', - ]; - - 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/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ConfigRef.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ConfigRef.php deleted file mode 100644 index 9b311d9c1bf1..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ConfigRef.php +++ /dev/null @@ -1,71 +0,0 @@ -google.api.servicemanagement.v1.ConfigRef - */ -class ConfigRef extends \Google\Protobuf\Internal\Message -{ - /** - * Resource name of a service config. It must have the following - * format: "services/{service name}/configs/{config id}". - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Resource name of a service config. It must have the following - * format: "services/{service name}/configs/{config id}". - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Servicemanagement\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * Resource name of a service config. It must have the following - * format: "services/{service name}/configs/{config id}". - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Resource name of a service config. It must have the following - * format: "services/{service name}/configs/{config id}". - * - * 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; - } - -} - diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ConfigSource.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ConfigSource.php deleted file mode 100644 index dfedb93e6ceb..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ConfigSource.php +++ /dev/null @@ -1,114 +0,0 @@ -google.api.servicemanagement.v1.ConfigSource - */ -class ConfigSource extends \Google\Protobuf\Internal\Message -{ - /** - * A unique ID for a specific instance of this message, typically assigned - * by the client for tracking purpose. If empty, the server may choose to - * generate one instead. - * - * Generated from protobuf field string id = 5; - */ - protected $id = ''; - /** - * Set of source configuration files that are used to generate a service - * configuration (`google.api.Service`). - * - * Generated from protobuf field repeated .google.api.servicemanagement.v1.ConfigFile files = 2; - */ - private $files; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $id - * A unique ID for a specific instance of this message, typically assigned - * by the client for tracking purpose. If empty, the server may choose to - * generate one instead. - * @type \Google\Cloud\ServiceManagement\V1\ConfigFile[] $files - * Set of source configuration files that are used to generate a service - * configuration (`google.api.Service`). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Servicemanagement\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * A unique ID for a specific instance of this message, typically assigned - * by the client for tracking purpose. If empty, the server may choose to - * generate one instead. - * - * Generated from protobuf field string id = 5; - * @return string - */ - public function getId() - { - return $this->id; - } - - /** - * A unique ID for a specific instance of this message, typically assigned - * by the client for tracking purpose. If empty, the server may choose to - * generate one instead. - * - * 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; - } - - /** - * Set of source configuration files that are used to generate a service - * configuration (`google.api.Service`). - * - * Generated from protobuf field repeated .google.api.servicemanagement.v1.ConfigFile files = 2; - * @return RepeatedField<\Google\Cloud\ServiceManagement\V1\ConfigFile> - */ - public function getFiles() - { - return $this->files; - } - - /** - * Set of source configuration files that are used to generate a service - * configuration (`google.api.Service`). - * - * Generated from protobuf field repeated .google.api.servicemanagement.v1.ConfigFile files = 2; - * @param \Google\Cloud\ServiceManagement\V1\ConfigFile[] $var - * @return $this - */ - public function setFiles($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\ServiceManagement\V1\ConfigFile::class); - $this->files = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/CreateServiceConfigRequest.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/CreateServiceConfigRequest.php deleted file mode 100644 index da1e6bd4ac95..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/CreateServiceConfigRequest.php +++ /dev/null @@ -1,136 +0,0 @@ -google.api.servicemanagement.v1.CreateServiceConfigRequest - */ -class CreateServiceConfigRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * - * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $service_name = ''; - /** - * Required. The service configuration resource. - * - * Generated from protobuf field .google.api.Service service_config = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $service_config = null; - - /** - * @param string $serviceName Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * @param \Google\Api\Service $serviceConfig Required. The service configuration resource. - * - * @return \Google\Cloud\ServiceManagement\V1\CreateServiceConfigRequest - * - * @experimental - */ - public static function build(string $serviceName, \Google\Api\Service $serviceConfig): self - { - return (new self()) - ->setServiceName($serviceName) - ->setServiceConfig($serviceConfig); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $service_name - * Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * @type \Google\Api\Service $service_config - * Required. The service configuration resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Servicemanagement\V1\Servicemanager::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * - * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getServiceName() - { - return $this->service_name; - } - - /** - * Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * - * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setServiceName($var) - { - GPBUtil::checkString($var, True); - $this->service_name = $var; - - return $this; - } - - /** - * Required. The service configuration resource. - * - * Generated from protobuf field .google.api.Service service_config = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Api\Service|null - */ - public function getServiceConfig() - { - return $this->service_config; - } - - public function hasServiceConfig() - { - return isset($this->service_config); - } - - public function clearServiceConfig() - { - unset($this->service_config); - } - - /** - * Required. The service configuration resource. - * - * Generated from protobuf field .google.api.Service service_config = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Api\Service $var - * @return $this - */ - public function setServiceConfig($var) - { - GPBUtil::checkMessage($var, \Google\Api\Service::class); - $this->service_config = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/CreateServiceRequest.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/CreateServiceRequest.php deleted file mode 100644 index 056fb0ea7c2a..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/CreateServiceRequest.php +++ /dev/null @@ -1,90 +0,0 @@ -google.api.servicemanagement.v1.CreateServiceRequest - */ -class CreateServiceRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Initial values for the service resource. - * - * Generated from protobuf field .google.api.servicemanagement.v1.ManagedService service = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $service = null; - - /** - * @param \Google\Cloud\ServiceManagement\V1\ManagedService $service Required. Initial values for the service resource. - * - * @return \Google\Cloud\ServiceManagement\V1\CreateServiceRequest - * - * @experimental - */ - public static function build(\Google\Cloud\ServiceManagement\V1\ManagedService $service): self - { - return (new self()) - ->setService($service); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\ServiceManagement\V1\ManagedService $service - * Required. Initial values for the service resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Servicemanagement\V1\Servicemanager::initOnce(); - parent::__construct($data); - } - - /** - * Required. Initial values for the service resource. - * - * Generated from protobuf field .google.api.servicemanagement.v1.ManagedService service = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\ServiceManagement\V1\ManagedService|null - */ - public function getService() - { - return $this->service; - } - - public function hasService() - { - return isset($this->service); - } - - public function clearService() - { - unset($this->service); - } - - /** - * Required. Initial values for the service resource. - * - * Generated from protobuf field .google.api.servicemanagement.v1.ManagedService service = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\ServiceManagement\V1\ManagedService $var - * @return $this - */ - public function setService($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\ServiceManagement\V1\ManagedService::class); - $this->service = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/CreateServiceRolloutRequest.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/CreateServiceRolloutRequest.php deleted file mode 100644 index 6b0e1aa82d88..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/CreateServiceRolloutRequest.php +++ /dev/null @@ -1,136 +0,0 @@ -google.api.servicemanagement.v1.CreateServiceRolloutRequest - */ -class CreateServiceRolloutRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * - * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $service_name = ''; - /** - * Required. The rollout resource. The `service_name` field is output only. - * - * Generated from protobuf field .google.api.servicemanagement.v1.Rollout rollout = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $rollout = null; - - /** - * @param string $serviceName Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * @param \Google\Cloud\ServiceManagement\V1\Rollout $rollout Required. The rollout resource. The `service_name` field is output only. - * - * @return \Google\Cloud\ServiceManagement\V1\CreateServiceRolloutRequest - * - * @experimental - */ - public static function build(string $serviceName, \Google\Cloud\ServiceManagement\V1\Rollout $rollout): self - { - return (new self()) - ->setServiceName($serviceName) - ->setRollout($rollout); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $service_name - * Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * @type \Google\Cloud\ServiceManagement\V1\Rollout $rollout - * Required. The rollout resource. The `service_name` field is output only. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Servicemanagement\V1\Servicemanager::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * - * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getServiceName() - { - return $this->service_name; - } - - /** - * Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * - * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setServiceName($var) - { - GPBUtil::checkString($var, True); - $this->service_name = $var; - - return $this; - } - - /** - * Required. The rollout resource. The `service_name` field is output only. - * - * Generated from protobuf field .google.api.servicemanagement.v1.Rollout rollout = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\ServiceManagement\V1\Rollout|null - */ - public function getRollout() - { - return $this->rollout; - } - - public function hasRollout() - { - return isset($this->rollout); - } - - public function clearRollout() - { - unset($this->rollout); - } - - /** - * Required. The rollout resource. The `service_name` field is output only. - * - * Generated from protobuf field .google.api.servicemanagement.v1.Rollout rollout = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\ServiceManagement\V1\Rollout $var - * @return $this - */ - public function setRollout($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\ServiceManagement\V1\Rollout::class); - $this->rollout = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/DeleteServiceRequest.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/DeleteServiceRequest.php deleted file mode 100644 index 7ba4f70e3f0f..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/DeleteServiceRequest.php +++ /dev/null @@ -1,90 +0,0 @@ -google.api.servicemanagement.v1.DeleteServiceRequest - */ -class DeleteServiceRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * - * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $service_name = ''; - - /** - * @param string $serviceName Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * - * @return \Google\Cloud\ServiceManagement\V1\DeleteServiceRequest - * - * @experimental - */ - public static function build(string $serviceName): self - { - return (new self()) - ->setServiceName($serviceName); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $service_name - * Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Servicemanagement\V1\Servicemanager::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * - * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getServiceName() - { - return $this->service_name; - } - - /** - * Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * - * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setServiceName($var) - { - GPBUtil::checkString($var, True); - $this->service_name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Diagnostic.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Diagnostic.php deleted file mode 100644 index 95491e9167af..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Diagnostic.php +++ /dev/null @@ -1,135 +0,0 @@ -google.api.servicemanagement.v1.Diagnostic - */ -class Diagnostic extends \Google\Protobuf\Internal\Message -{ - /** - * File name and line number of the error or warning. - * - * Generated from protobuf field string location = 1; - */ - protected $location = ''; - /** - * The kind of diagnostic information provided. - * - * Generated from protobuf field .google.api.servicemanagement.v1.Diagnostic.Kind kind = 2; - */ - protected $kind = 0; - /** - * Message describing the error or warning. - * - * Generated from protobuf field string message = 3; - */ - protected $message = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $location - * File name and line number of the error or warning. - * @type int $kind - * The kind of diagnostic information provided. - * @type string $message - * Message describing the error or warning. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Servicemanagement\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * File name and line number of the error or warning. - * - * Generated from protobuf field string location = 1; - * @return string - */ - public function getLocation() - { - return $this->location; - } - - /** - * File name and line number of the error or warning. - * - * 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 kind of diagnostic information provided. - * - * Generated from protobuf field .google.api.servicemanagement.v1.Diagnostic.Kind kind = 2; - * @return int - */ - public function getKind() - { - return $this->kind; - } - - /** - * The kind of diagnostic information provided. - * - * Generated from protobuf field .google.api.servicemanagement.v1.Diagnostic.Kind kind = 2; - * @param int $var - * @return $this - */ - public function setKind($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\ServiceManagement\V1\Diagnostic\Kind::class); - $this->kind = $var; - - return $this; - } - - /** - * Message describing the error or warning. - * - * Generated from protobuf field string message = 3; - * @return string - */ - public function getMessage() - { - return $this->message; - } - - /** - * Message describing the error or warning. - * - * Generated from protobuf field string message = 3; - * @param string $var - * @return $this - */ - public function setMessage($var) - { - GPBUtil::checkString($var, True); - $this->message = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Diagnostic/Kind.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Diagnostic/Kind.php deleted file mode 100644 index 731e0996f661..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Diagnostic/Kind.php +++ /dev/null @@ -1,54 +0,0 @@ -google.api.servicemanagement.v1.Diagnostic.Kind - */ -class Kind -{ - /** - * Warnings and errors - * - * Generated from protobuf enum WARNING = 0; - */ - const WARNING = 0; - /** - * Only errors - * - * Generated from protobuf enum ERROR = 1; - */ - const ERROR = 1; - - private static $valueToName = [ - self::WARNING => 'WARNING', - 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); - } -} - diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/EnableServiceResponse.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/EnableServiceResponse.php deleted file mode 100644 index e5727a714c09..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/EnableServiceResponse.php +++ /dev/null @@ -1,33 +0,0 @@ -google.api.servicemanagement.v1.EnableServiceResponse - */ -class EnableServiceResponse extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Servicemanagement\V1\Servicemanager::initOnce(); - parent::__construct($data); - } - -} - diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GenerateConfigReportRequest.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GenerateConfigReportRequest.php deleted file mode 100644 index 22bd179831be..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GenerateConfigReportRequest.php +++ /dev/null @@ -1,176 +0,0 @@ -google.api.servicemanagement.v1.GenerateConfigReportRequest - */ -class GenerateConfigReportRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Service configuration for which we want to generate the report. - * For this version of API, the supported types are - * [google.api.servicemanagement.v1.ConfigRef][google.api.servicemanagement.v1.ConfigRef], - * [google.api.servicemanagement.v1.ConfigSource][google.api.servicemanagement.v1.ConfigSource], - * and [google.api.Service][google.api.Service] - * - * Generated from protobuf field .google.protobuf.Any new_config = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $new_config = null; - /** - * Optional. Service configuration against which the comparison will be done. - * For this version of API, the supported types are - * [google.api.servicemanagement.v1.ConfigRef][google.api.servicemanagement.v1.ConfigRef], - * [google.api.servicemanagement.v1.ConfigSource][google.api.servicemanagement.v1.ConfigSource], - * and [google.api.Service][google.api.Service] - * - * Generated from protobuf field .google.protobuf.Any old_config = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $old_config = null; - - /** - * @param \Google\Protobuf\Any $newConfig Required. Service configuration for which we want to generate the report. - * For this version of API, the supported types are - * [google.api.servicemanagement.v1.ConfigRef][google.api.servicemanagement.v1.ConfigRef], - * [google.api.servicemanagement.v1.ConfigSource][google.api.servicemanagement.v1.ConfigSource], - * and [google.api.Service][google.api.Service] - * @param \Google\Protobuf\Any $oldConfig Optional. Service configuration against which the comparison will be done. - * For this version of API, the supported types are - * [google.api.servicemanagement.v1.ConfigRef][google.api.servicemanagement.v1.ConfigRef], - * [google.api.servicemanagement.v1.ConfigSource][google.api.servicemanagement.v1.ConfigSource], - * and [google.api.Service][google.api.Service] - * - * @return \Google\Cloud\ServiceManagement\V1\GenerateConfigReportRequest - * - * @experimental - */ - public static function build(\Google\Protobuf\Any $newConfig, \Google\Protobuf\Any $oldConfig): self - { - return (new self()) - ->setNewConfig($newConfig) - ->setOldConfig($oldConfig); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Protobuf\Any $new_config - * Required. Service configuration for which we want to generate the report. - * For this version of API, the supported types are - * [google.api.servicemanagement.v1.ConfigRef][google.api.servicemanagement.v1.ConfigRef], - * [google.api.servicemanagement.v1.ConfigSource][google.api.servicemanagement.v1.ConfigSource], - * and [google.api.Service][google.api.Service] - * @type \Google\Protobuf\Any $old_config - * Optional. Service configuration against which the comparison will be done. - * For this version of API, the supported types are - * [google.api.servicemanagement.v1.ConfigRef][google.api.servicemanagement.v1.ConfigRef], - * [google.api.servicemanagement.v1.ConfigSource][google.api.servicemanagement.v1.ConfigSource], - * and [google.api.Service][google.api.Service] - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Servicemanagement\V1\Servicemanager::initOnce(); - parent::__construct($data); - } - - /** - * Required. Service configuration for which we want to generate the report. - * For this version of API, the supported types are - * [google.api.servicemanagement.v1.ConfigRef][google.api.servicemanagement.v1.ConfigRef], - * [google.api.servicemanagement.v1.ConfigSource][google.api.servicemanagement.v1.ConfigSource], - * and [google.api.Service][google.api.Service] - * - * Generated from protobuf field .google.protobuf.Any new_config = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Any|null - */ - public function getNewConfig() - { - return $this->new_config; - } - - public function hasNewConfig() - { - return isset($this->new_config); - } - - public function clearNewConfig() - { - unset($this->new_config); - } - - /** - * Required. Service configuration for which we want to generate the report. - * For this version of API, the supported types are - * [google.api.servicemanagement.v1.ConfigRef][google.api.servicemanagement.v1.ConfigRef], - * [google.api.servicemanagement.v1.ConfigSource][google.api.servicemanagement.v1.ConfigSource], - * and [google.api.Service][google.api.Service] - * - * Generated from protobuf field .google.protobuf.Any new_config = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Protobuf\Any $var - * @return $this - */ - public function setNewConfig($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Any::class); - $this->new_config = $var; - - return $this; - } - - /** - * Optional. Service configuration against which the comparison will be done. - * For this version of API, the supported types are - * [google.api.servicemanagement.v1.ConfigRef][google.api.servicemanagement.v1.ConfigRef], - * [google.api.servicemanagement.v1.ConfigSource][google.api.servicemanagement.v1.ConfigSource], - * and [google.api.Service][google.api.Service] - * - * Generated from protobuf field .google.protobuf.Any old_config = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Any|null - */ - public function getOldConfig() - { - return $this->old_config; - } - - public function hasOldConfig() - { - return isset($this->old_config); - } - - public function clearOldConfig() - { - unset($this->old_config); - } - - /** - * Optional. Service configuration against which the comparison will be done. - * For this version of API, the supported types are - * [google.api.servicemanagement.v1.ConfigRef][google.api.servicemanagement.v1.ConfigRef], - * [google.api.servicemanagement.v1.ConfigSource][google.api.servicemanagement.v1.ConfigSource], - * and [google.api.Service][google.api.Service] - * - * Generated from protobuf field .google.protobuf.Any old_config = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Protobuf\Any $var - * @return $this - */ - public function setOldConfig($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Any::class); - $this->old_config = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GenerateConfigReportResponse.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GenerateConfigReportResponse.php deleted file mode 100644 index f9b8439d72bc..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GenerateConfigReportResponse.php +++ /dev/null @@ -1,181 +0,0 @@ -google.api.servicemanagement.v1.GenerateConfigReportResponse - */ -class GenerateConfigReportResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Name of the service this report belongs to. - * - * Generated from protobuf field string service_name = 1; - */ - protected $service_name = ''; - /** - * ID of the service configuration this report belongs to. - * - * Generated from protobuf field string id = 2; - */ - protected $id = ''; - /** - * list of ChangeReport, each corresponding to comparison between two - * service configurations. - * - * Generated from protobuf field repeated .google.api.servicemanagement.v1.ChangeReport change_reports = 3; - */ - private $change_reports; - /** - * Errors / Linter warnings associated with the service definition this - * report - * belongs to. - * - * Generated from protobuf field repeated .google.api.servicemanagement.v1.Diagnostic diagnostics = 4; - */ - private $diagnostics; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $service_name - * Name of the service this report belongs to. - * @type string $id - * ID of the service configuration this report belongs to. - * @type \Google\Cloud\ServiceManagement\V1\ChangeReport[] $change_reports - * list of ChangeReport, each corresponding to comparison between two - * service configurations. - * @type \Google\Cloud\ServiceManagement\V1\Diagnostic[] $diagnostics - * Errors / Linter warnings associated with the service definition this - * report - * belongs to. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Servicemanagement\V1\Servicemanager::initOnce(); - parent::__construct($data); - } - - /** - * Name of the service this report belongs to. - * - * Generated from protobuf field string service_name = 1; - * @return string - */ - public function getServiceName() - { - return $this->service_name; - } - - /** - * Name of the service this report belongs to. - * - * Generated from protobuf field string service_name = 1; - * @param string $var - * @return $this - */ - public function setServiceName($var) - { - GPBUtil::checkString($var, True); - $this->service_name = $var; - - return $this; - } - - /** - * ID of the service configuration this report belongs to. - * - * Generated from protobuf field string id = 2; - * @return string - */ - public function getId() - { - return $this->id; - } - - /** - * ID of the service configuration this report belongs to. - * - * Generated from protobuf field string id = 2; - * @param string $var - * @return $this - */ - public function setId($var) - { - GPBUtil::checkString($var, True); - $this->id = $var; - - return $this; - } - - /** - * list of ChangeReport, each corresponding to comparison between two - * service configurations. - * - * Generated from protobuf field repeated .google.api.servicemanagement.v1.ChangeReport change_reports = 3; - * @return RepeatedField<\Google\Cloud\ServiceManagement\V1\ChangeReport> - */ - public function getChangeReports() - { - return $this->change_reports; - } - - /** - * list of ChangeReport, each corresponding to comparison between two - * service configurations. - * - * Generated from protobuf field repeated .google.api.servicemanagement.v1.ChangeReport change_reports = 3; - * @param \Google\Cloud\ServiceManagement\V1\ChangeReport[] $var - * @return $this - */ - public function setChangeReports($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\ServiceManagement\V1\ChangeReport::class); - $this->change_reports = $arr; - - return $this; - } - - /** - * Errors / Linter warnings associated with the service definition this - * report - * belongs to. - * - * Generated from protobuf field repeated .google.api.servicemanagement.v1.Diagnostic diagnostics = 4; - * @return RepeatedField<\Google\Cloud\ServiceManagement\V1\Diagnostic> - */ - public function getDiagnostics() - { - return $this->diagnostics; - } - - /** - * Errors / Linter warnings associated with the service definition this - * report - * belongs to. - * - * Generated from protobuf field repeated .google.api.servicemanagement.v1.Diagnostic diagnostics = 4; - * @param \Google\Cloud\ServiceManagement\V1\Diagnostic[] $var - * @return $this - */ - public function setDiagnostics($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\ServiceManagement\V1\Diagnostic::class); - $this->diagnostics = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GetServiceConfigRequest.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GetServiceConfigRequest.php deleted file mode 100644 index 8cfb83bc796d..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GetServiceConfigRequest.php +++ /dev/null @@ -1,179 +0,0 @@ -google.api.servicemanagement.v1.GetServiceConfigRequest - */ -class GetServiceConfigRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * - * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $service_name = ''; - /** - * Required. The id of the service configuration resource. - * This field must be specified for the server to return all fields, including - * `SourceInfo`. - * - * Generated from protobuf field string config_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $config_id = ''; - /** - * Specifies which parts of the Service Config should be returned in the - * response. - * - * Generated from protobuf field .google.api.servicemanagement.v1.GetServiceConfigRequest.ConfigView view = 3; - */ - protected $view = 0; - - /** - * @param string $serviceName Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * @param string $configId Required. The id of the service configuration resource. - * - * This field must be specified for the server to return all fields, including - * `SourceInfo`. - * @param int $view Specifies which parts of the Service Config should be returned in the - * response. - * For allowed values, use constants defined on {@see \Google\Cloud\ServiceManagement\V1\GetServiceConfigRequest\ConfigView} - * - * @return \Google\Cloud\ServiceManagement\V1\GetServiceConfigRequest - * - * @experimental - */ - public static function build(string $serviceName, string $configId, int $view): self - { - return (new self()) - ->setServiceName($serviceName) - ->setConfigId($configId) - ->setView($view); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $service_name - * Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * @type string $config_id - * Required. The id of the service configuration resource. - * This field must be specified for the server to return all fields, including - * `SourceInfo`. - * @type int $view - * Specifies which parts of the Service Config should be returned in the - * response. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Servicemanagement\V1\Servicemanager::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * - * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getServiceName() - { - return $this->service_name; - } - - /** - * Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * - * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setServiceName($var) - { - GPBUtil::checkString($var, True); - $this->service_name = $var; - - return $this; - } - - /** - * Required. The id of the service configuration resource. - * This field must be specified for the server to return all fields, including - * `SourceInfo`. - * - * Generated from protobuf field string config_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getConfigId() - { - return $this->config_id; - } - - /** - * Required. The id of the service configuration resource. - * This field must be specified for the server to return all fields, including - * `SourceInfo`. - * - * Generated from protobuf field string config_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setConfigId($var) - { - GPBUtil::checkString($var, True); - $this->config_id = $var; - - return $this; - } - - /** - * Specifies which parts of the Service Config should be returned in the - * response. - * - * Generated from protobuf field .google.api.servicemanagement.v1.GetServiceConfigRequest.ConfigView view = 3; - * @return int - */ - public function getView() - { - return $this->view; - } - - /** - * Specifies which parts of the Service Config should be returned in the - * response. - * - * Generated from protobuf field .google.api.servicemanagement.v1.GetServiceConfigRequest.ConfigView view = 3; - * @param int $var - * @return $this - */ - public function setView($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\ServiceManagement\V1\GetServiceConfigRequest\ConfigView::class); - $this->view = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GetServiceConfigRequest/ConfigView.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GetServiceConfigRequest/ConfigView.php deleted file mode 100644 index c79893bdeb0e..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GetServiceConfigRequest/ConfigView.php +++ /dev/null @@ -1,55 +0,0 @@ -google.api.servicemanagement.v1.GetServiceConfigRequest.ConfigView - */ -class ConfigView -{ - /** - * Server response includes all fields except SourceInfo. - * - * Generated from protobuf enum BASIC = 0; - */ - const BASIC = 0; - /** - * Server response includes all fields including SourceInfo. - * SourceFiles are of type 'google.api.servicemanagement.v1.ConfigFile' - * and are only available for configs created using the - * SubmitConfigSource method. - * - * Generated from protobuf enum FULL = 1; - */ - const FULL = 1; - - private static $valueToName = [ - self::BASIC => 'BASIC', - self::FULL => 'FULL', - ]; - - 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/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GetServiceRequest.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GetServiceRequest.php deleted file mode 100644 index 3b1510cda0bb..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GetServiceRequest.php +++ /dev/null @@ -1,85 +0,0 @@ -google.api.servicemanagement.v1.GetServiceRequest - */ -class GetServiceRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the service. See the `ServiceManager` overview for - * naming requirements. For example: `example.googleapis.com`. - * - * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $service_name = ''; - - /** - * @param string $serviceName Required. The name of the service. See the `ServiceManager` overview for - * naming requirements. For example: `example.googleapis.com`. - * - * @return \Google\Cloud\ServiceManagement\V1\GetServiceRequest - * - * @experimental - */ - public static function build(string $serviceName): self - { - return (new self()) - ->setServiceName($serviceName); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $service_name - * Required. The name of the service. See the `ServiceManager` overview for - * naming requirements. For example: `example.googleapis.com`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Servicemanagement\V1\Servicemanager::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the service. See the `ServiceManager` overview for - * naming requirements. For example: `example.googleapis.com`. - * - * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getServiceName() - { - return $this->service_name; - } - - /** - * Required. The name of the service. See the `ServiceManager` overview for - * naming requirements. For example: `example.googleapis.com`. - * - * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setServiceName($var) - { - GPBUtil::checkString($var, True); - $this->service_name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GetServiceRolloutRequest.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GetServiceRolloutRequest.php deleted file mode 100644 index 42ce21668e8b..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/GetServiceRolloutRequest.php +++ /dev/null @@ -1,126 +0,0 @@ -google.api.servicemanagement.v1.GetServiceRolloutRequest - */ -class GetServiceRolloutRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * - * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $service_name = ''; - /** - * Required. The id of the rollout resource. - * - * Generated from protobuf field string rollout_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $rollout_id = ''; - - /** - * @param string $serviceName Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * @param string $rolloutId Required. The id of the rollout resource. - * - * @return \Google\Cloud\ServiceManagement\V1\GetServiceRolloutRequest - * - * @experimental - */ - public static function build(string $serviceName, string $rolloutId): self - { - return (new self()) - ->setServiceName($serviceName) - ->setRolloutId($rolloutId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $service_name - * Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * @type string $rollout_id - * Required. The id of the rollout resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Servicemanagement\V1\Servicemanager::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * - * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getServiceName() - { - return $this->service_name; - } - - /** - * Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * - * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setServiceName($var) - { - GPBUtil::checkString($var, True); - $this->service_name = $var; - - return $this; - } - - /** - * Required. The id of the rollout resource. - * - * Generated from protobuf field string rollout_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getRolloutId() - { - return $this->rollout_id; - } - - /** - * Required. The id of the rollout resource. - * - * Generated from protobuf field string rollout_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setRolloutId($var) - { - GPBUtil::checkString($var, True); - $this->rollout_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServiceConfigsRequest.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServiceConfigsRequest.php deleted file mode 100644 index cbce1951eaac..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServiceConfigsRequest.php +++ /dev/null @@ -1,162 +0,0 @@ -google.api.servicemanagement.v1.ListServiceConfigsRequest - */ -class ListServiceConfigsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * - * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $service_name = ''; - /** - * The token of the page to retrieve. - * - * Generated from protobuf field string page_token = 2; - */ - protected $page_token = ''; - /** - * The max number of items to include in the response list. Page size is 50 - * if not specified. Maximum value is 100. - * - * Generated from protobuf field int32 page_size = 3; - */ - protected $page_size = 0; - - /** - * @param string $serviceName Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * - * @return \Google\Cloud\ServiceManagement\V1\ListServiceConfigsRequest - * - * @experimental - */ - public static function build(string $serviceName): self - { - return (new self()) - ->setServiceName($serviceName); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $service_name - * Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * @type string $page_token - * The token of the page to retrieve. - * @type int $page_size - * The max number of items to include in the response list. Page size is 50 - * if not specified. Maximum value is 100. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Servicemanagement\V1\Servicemanager::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * - * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getServiceName() - { - return $this->service_name; - } - - /** - * Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * - * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setServiceName($var) - { - GPBUtil::checkString($var, True); - $this->service_name = $var; - - return $this; - } - - /** - * The token of the page to retrieve. - * - * Generated from protobuf field string page_token = 2; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The token of the page to retrieve. - * - * Generated from protobuf field string page_token = 2; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * The max number of items to include in the response list. Page size is 50 - * if not specified. Maximum value is 100. - * - * Generated from protobuf field int32 page_size = 3; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The max number of items to include in the response list. Page size is 50 - * if not specified. Maximum value is 100. - * - * 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; - } - -} - diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServiceConfigsResponse.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServiceConfigsResponse.php deleted file mode 100644 index b26fc9f7284a..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServiceConfigsResponse.php +++ /dev/null @@ -1,101 +0,0 @@ -google.api.servicemanagement.v1.ListServiceConfigsResponse - */ -class ListServiceConfigsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The list of service configuration resources. - * - * Generated from protobuf field repeated .google.api.Service service_configs = 1; - */ - private $service_configs; - /** - * The token of 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 \Google\Api\Service[] $service_configs - * The list of service configuration resources. - * @type string $next_page_token - * The token of the next page of results. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Servicemanagement\V1\Servicemanager::initOnce(); - parent::__construct($data); - } - - /** - * The list of service configuration resources. - * - * Generated from protobuf field repeated .google.api.Service service_configs = 1; - * @return RepeatedField<\Google\Api\Service> - */ - public function getServiceConfigs() - { - return $this->service_configs; - } - - /** - * The list of service configuration resources. - * - * Generated from protobuf field repeated .google.api.Service service_configs = 1; - * @param \Google\Api\Service[] $var - * @return $this - */ - public function setServiceConfigs($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Api\Service::class); - $this->service_configs = $arr; - - return $this; - } - - /** - * The token of 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 token of 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/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServiceRolloutsRequest.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServiceRolloutsRequest.php deleted file mode 100644 index 7feecf9a34b9..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServiceRolloutsRequest.php +++ /dev/null @@ -1,235 +0,0 @@ -google.api.servicemanagement.v1.ListServiceRolloutsRequest - */ -class ListServiceRolloutsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * - * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $service_name = ''; - /** - * The token of the page to retrieve. - * - * Generated from protobuf field string page_token = 2; - */ - protected $page_token = ''; - /** - * The max number of items to include in the response list. Page size is 50 - * if not specified. Maximum value is 100. - * - * Generated from protobuf field int32 page_size = 3; - */ - protected $page_size = 0; - /** - * Required. Use `filter` to return subset of rollouts. - * The following filters are supported: - * -- By [status] - * [google.api.servicemanagement.v1.Rollout.RolloutStatus]. For example, - * `filter='status=SUCCESS'` - * -- By [strategy] - * [google.api.servicemanagement.v1.Rollout.strategy]. For example, - * `filter='strategy=TrafficPercentStrategy'` - * - * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $filter = ''; - - /** - * @param string $serviceName Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * @param string $filter Required. Use `filter` to return subset of rollouts. - * The following filters are supported: - * - * -- By [status] - * [google.api.servicemanagement.v1.Rollout.RolloutStatus]. For example, - * `filter='status=SUCCESS'` - * - * -- By [strategy] - * [google.api.servicemanagement.v1.Rollout.strategy]. For example, - * `filter='strategy=TrafficPercentStrategy'` - * - * @return \Google\Cloud\ServiceManagement\V1\ListServiceRolloutsRequest - * - * @experimental - */ - public static function build(string $serviceName, string $filter): self - { - return (new self()) - ->setServiceName($serviceName) - ->setFilter($filter); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $service_name - * Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * @type string $page_token - * The token of the page to retrieve. - * @type int $page_size - * The max number of items to include in the response list. Page size is 50 - * if not specified. Maximum value is 100. - * @type string $filter - * Required. Use `filter` to return subset of rollouts. - * The following filters are supported: - * -- By [status] - * [google.api.servicemanagement.v1.Rollout.RolloutStatus]. For example, - * `filter='status=SUCCESS'` - * -- By [strategy] - * [google.api.servicemanagement.v1.Rollout.strategy]. For example, - * `filter='strategy=TrafficPercentStrategy'` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Servicemanagement\V1\Servicemanager::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * - * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getServiceName() - { - return $this->service_name; - } - - /** - * Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * - * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setServiceName($var) - { - GPBUtil::checkString($var, True); - $this->service_name = $var; - - return $this; - } - - /** - * The token of the page to retrieve. - * - * Generated from protobuf field string page_token = 2; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * The token of the page to retrieve. - * - * Generated from protobuf field string page_token = 2; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * The max number of items to include in the response list. Page size is 50 - * if not specified. Maximum value is 100. - * - * Generated from protobuf field int32 page_size = 3; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The max number of items to include in the response list. Page size is 50 - * if not specified. Maximum value is 100. - * - * 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; - } - - /** - * Required. Use `filter` to return subset of rollouts. - * The following filters are supported: - * -- By [status] - * [google.api.servicemanagement.v1.Rollout.RolloutStatus]. For example, - * `filter='status=SUCCESS'` - * -- By [strategy] - * [google.api.servicemanagement.v1.Rollout.strategy]. For example, - * `filter='strategy=TrafficPercentStrategy'` - * - * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Required. Use `filter` to return subset of rollouts. - * The following filters are supported: - * -- By [status] - * [google.api.servicemanagement.v1.Rollout.RolloutStatus]. For example, - * `filter='status=SUCCESS'` - * -- By [strategy] - * [google.api.servicemanagement.v1.Rollout.strategy]. For example, - * `filter='strategy=TrafficPercentStrategy'` - * - * Generated from protobuf field string filter = 4 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServiceRolloutsResponse.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServiceRolloutsResponse.php deleted file mode 100644 index 3372213c1ab7..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServiceRolloutsResponse.php +++ /dev/null @@ -1,101 +0,0 @@ -google.api.servicemanagement.v1.ListServiceRolloutsResponse - */ -class ListServiceRolloutsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The list of rollout resources. - * - * Generated from protobuf field repeated .google.api.servicemanagement.v1.Rollout rollouts = 1; - */ - private $rollouts; - /** - * The token of 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 \Google\Cloud\ServiceManagement\V1\Rollout[] $rollouts - * The list of rollout resources. - * @type string $next_page_token - * The token of the next page of results. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Servicemanagement\V1\Servicemanager::initOnce(); - parent::__construct($data); - } - - /** - * The list of rollout resources. - * - * Generated from protobuf field repeated .google.api.servicemanagement.v1.Rollout rollouts = 1; - * @return RepeatedField<\Google\Cloud\ServiceManagement\V1\Rollout> - */ - public function getRollouts() - { - return $this->rollouts; - } - - /** - * The list of rollout resources. - * - * Generated from protobuf field repeated .google.api.servicemanagement.v1.Rollout rollouts = 1; - * @param \Google\Cloud\ServiceManagement\V1\Rollout[] $var - * @return $this - */ - public function setRollouts($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\ServiceManagement\V1\Rollout::class); - $this->rollouts = $arr; - - return $this; - } - - /** - * The token of 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 token of 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/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServicesRequest.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServicesRequest.php deleted file mode 100644 index 68fba0f9cde6..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServicesRequest.php +++ /dev/null @@ -1,215 +0,0 @@ -google.api.servicemanagement.v1.ListServicesRequest - */ -class ListServicesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Include services produced by the specified project. - * - * Generated from protobuf field string producer_project_id = 1; - */ - protected $producer_project_id = ''; - /** - * The max number of items to include in the response list. Page size is 50 - * if not specified. Maximum value is 500. - * - * Generated from protobuf field int32 page_size = 5; - */ - protected $page_size = 0; - /** - * Token identifying which result to start with; returned by a previous list - * call. - * - * Generated from protobuf field string page_token = 6; - */ - protected $page_token = ''; - /** - * Include services consumed by the specified consumer. - * The Google Service Management implementation accepts the following - * forms: - * - project: - * - * Generated from protobuf field string consumer_id = 7 [deprecated = true]; - * @deprecated - */ - protected $consumer_id = ''; - - /** - * @param string $producerProjectId Include services produced by the specified project. - * @param string $consumerId Include services consumed by the specified consumer. - * - * The Google Service Management implementation accepts the following - * forms: - * - project: - * - * @return \Google\Cloud\ServiceManagement\V1\ListServicesRequest - * - * @experimental - */ - public static function build(string $producerProjectId, string $consumerId): self - { - return (new self()) - ->setProducerProjectId($producerProjectId) - ->setConsumerId($consumerId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $producer_project_id - * Include services produced by the specified project. - * @type int $page_size - * The max number of items to include in the response list. Page size is 50 - * if not specified. Maximum value is 500. - * @type string $page_token - * Token identifying which result to start with; returned by a previous list - * call. - * @type string $consumer_id - * Include services consumed by the specified consumer. - * The Google Service Management implementation accepts the following - * forms: - * - project: - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Servicemanagement\V1\Servicemanager::initOnce(); - parent::__construct($data); - } - - /** - * Include services produced by the specified project. - * - * Generated from protobuf field string producer_project_id = 1; - * @return string - */ - public function getProducerProjectId() - { - return $this->producer_project_id; - } - - /** - * Include services produced by the specified project. - * - * Generated from protobuf field string producer_project_id = 1; - * @param string $var - * @return $this - */ - public function setProducerProjectId($var) - { - GPBUtil::checkString($var, True); - $this->producer_project_id = $var; - - return $this; - } - - /** - * The max number of items to include in the response list. Page size is 50 - * if not specified. Maximum value is 500. - * - * Generated from protobuf field int32 page_size = 5; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The max number of items to include in the response list. Page size is 50 - * if not specified. Maximum value is 500. - * - * Generated from protobuf field int32 page_size = 5; - * @param int $var - * @return $this - */ - public function setPageSize($var) - { - GPBUtil::checkInt32($var); - $this->page_size = $var; - - return $this; - } - - /** - * Token identifying which result to start with; returned by a previous list - * call. - * - * Generated from protobuf field string page_token = 6; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Token identifying which result to start with; returned by a previous list - * call. - * - * Generated from protobuf field string page_token = 6; - * @param string $var - * @return $this - */ - public function setPageToken($var) - { - GPBUtil::checkString($var, True); - $this->page_token = $var; - - return $this; - } - - /** - * Include services consumed by the specified consumer. - * The Google Service Management implementation accepts the following - * forms: - * - project: - * - * Generated from protobuf field string consumer_id = 7 [deprecated = true]; - * @return string - * @deprecated - */ - public function getConsumerId() - { - if ($this->consumer_id !== '') { - @trigger_error('consumer_id is deprecated.', E_USER_DEPRECATED); - } - return $this->consumer_id; - } - - /** - * Include services consumed by the specified consumer. - * The Google Service Management implementation accepts the following - * forms: - * - project: - * - * Generated from protobuf field string consumer_id = 7 [deprecated = true]; - * @param string $var - * @return $this - * @deprecated - */ - public function setConsumerId($var) - { - @trigger_error('consumer_id is deprecated.', E_USER_DEPRECATED); - GPBUtil::checkString($var, True); - $this->consumer_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServicesResponse.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServicesResponse.php deleted file mode 100644 index ea93c6d6a7bc..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ListServicesResponse.php +++ /dev/null @@ -1,101 +0,0 @@ -google.api.servicemanagement.v1.ListServicesResponse - */ -class ListServicesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The returned services will only have the name field set. - * - * Generated from protobuf field repeated .google.api.servicemanagement.v1.ManagedService services = 1; - */ - private $services; - /** - * Token that can be passed to `ListServices` to resume a paginated query. - * - * 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 \Google\Cloud\ServiceManagement\V1\ManagedService[] $services - * The returned services will only have the name field set. - * @type string $next_page_token - * Token that can be passed to `ListServices` to resume a paginated query. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Servicemanagement\V1\Servicemanager::initOnce(); - parent::__construct($data); - } - - /** - * The returned services will only have the name field set. - * - * Generated from protobuf field repeated .google.api.servicemanagement.v1.ManagedService services = 1; - * @return RepeatedField<\Google\Cloud\ServiceManagement\V1\ManagedService> - */ - public function getServices() - { - return $this->services; - } - - /** - * The returned services will only have the name field set. - * - * Generated from protobuf field repeated .google.api.servicemanagement.v1.ManagedService services = 1; - * @param \Google\Cloud\ServiceManagement\V1\ManagedService[] $var - * @return $this - */ - public function setServices($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\ServiceManagement\V1\ManagedService::class); - $this->services = $arr; - - return $this; - } - - /** - * Token that can be passed to `ListServices` to resume a paginated query. - * - * Generated from protobuf field string next_page_token = 2; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * Token that can be passed to `ListServices` to resume a paginated query. - * - * 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/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ManagedService.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ManagedService.php deleted file mode 100644 index b31101bae384..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/ManagedService.php +++ /dev/null @@ -1,110 +0,0 @@ -google.api.servicemanagement.v1.ManagedService - */ -class ManagedService extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the service. See the - * [overview](https://cloud.google.com/service-infrastructure/docs/overview) - * for naming requirements. - * - * Generated from protobuf field string service_name = 2; - */ - protected $service_name = ''; - /** - * ID of the project that produces and owns this service. - * - * Generated from protobuf field string producer_project_id = 3; - */ - protected $producer_project_id = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $service_name - * The name of the service. See the - * [overview](https://cloud.google.com/service-infrastructure/docs/overview) - * for naming requirements. - * @type string $producer_project_id - * ID of the project that produces and owns this service. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Servicemanagement\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * The name of the service. See the - * [overview](https://cloud.google.com/service-infrastructure/docs/overview) - * for naming requirements. - * - * Generated from protobuf field string service_name = 2; - * @return string - */ - public function getServiceName() - { - return $this->service_name; - } - - /** - * The name of the service. See the - * [overview](https://cloud.google.com/service-infrastructure/docs/overview) - * for naming requirements. - * - * Generated from protobuf field string service_name = 2; - * @param string $var - * @return $this - */ - public function setServiceName($var) - { - GPBUtil::checkString($var, True); - $this->service_name = $var; - - return $this; - } - - /** - * ID of the project that produces and owns this service. - * - * Generated from protobuf field string producer_project_id = 3; - * @return string - */ - public function getProducerProjectId() - { - return $this->producer_project_id; - } - - /** - * ID of the project that produces and owns this service. - * - * Generated from protobuf field string producer_project_id = 3; - * @param string $var - * @return $this - */ - public function setProducerProjectId($var) - { - GPBUtil::checkString($var, True); - $this->producer_project_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/OperationMetadata.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/OperationMetadata.php deleted file mode 100644 index 8c8bc1bc1be9..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/OperationMetadata.php +++ /dev/null @@ -1,183 +0,0 @@ -google.api.servicemanagement.v1.OperationMetadata - */ -class OperationMetadata extends \Google\Protobuf\Internal\Message -{ - /** - * The full name of the resources that this operation is directly - * associated with. - * - * Generated from protobuf field repeated string resource_names = 1; - */ - private $resource_names; - /** - * Detailed status information for each step. The order is undetermined. - * - * Generated from protobuf field repeated .google.api.servicemanagement.v1.OperationMetadata.Step steps = 2; - */ - private $steps; - /** - * Percentage of completion of this operation, ranging from 0 to 100. - * - * Generated from protobuf field int32 progress_percentage = 3; - */ - protected $progress_percentage = 0; - /** - * The start time of the operation. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 4; - */ - protected $start_time = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string[] $resource_names - * The full name of the resources that this operation is directly - * associated with. - * @type \Google\Cloud\ServiceManagement\V1\OperationMetadata\Step[] $steps - * Detailed status information for each step. The order is undetermined. - * @type int $progress_percentage - * Percentage of completion of this operation, ranging from 0 to 100. - * @type \Google\Protobuf\Timestamp $start_time - * The start time of the operation. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Servicemanagement\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * The full name of the resources that this operation is directly - * associated with. - * - * Generated from protobuf field repeated string resource_names = 1; - * @return RepeatedField - */ - public function getResourceNames() - { - return $this->resource_names; - } - - /** - * The full name of the resources that this operation is directly - * associated with. - * - * Generated from protobuf field repeated string resource_names = 1; - * @param string[] $var - * @return $this - */ - public function setResourceNames($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->resource_names = $arr; - - return $this; - } - - /** - * Detailed status information for each step. The order is undetermined. - * - * Generated from protobuf field repeated .google.api.servicemanagement.v1.OperationMetadata.Step steps = 2; - * @return RepeatedField<\Google\Cloud\ServiceManagement\V1\OperationMetadata\Step> - */ - public function getSteps() - { - return $this->steps; - } - - /** - * Detailed status information for each step. The order is undetermined. - * - * Generated from protobuf field repeated .google.api.servicemanagement.v1.OperationMetadata.Step steps = 2; - * @param \Google\Cloud\ServiceManagement\V1\OperationMetadata\Step[] $var - * @return $this - */ - public function setSteps($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\ServiceManagement\V1\OperationMetadata\Step::class); - $this->steps = $arr; - - return $this; - } - - /** - * Percentage of completion of this operation, ranging from 0 to 100. - * - * Generated from protobuf field int32 progress_percentage = 3; - * @return int - */ - public function getProgressPercentage() - { - return $this->progress_percentage; - } - - /** - * Percentage of completion of this operation, ranging from 0 to 100. - * - * Generated from protobuf field int32 progress_percentage = 3; - * @param int $var - * @return $this - */ - public function setProgressPercentage($var) - { - GPBUtil::checkInt32($var); - $this->progress_percentage = $var; - - return $this; - } - - /** - * The start time of the operation. - * - * 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 time of the operation. - * - * 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; - } - -} - diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/OperationMetadata/Status.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/OperationMetadata/Status.php deleted file mode 100644 index 9a84bb364388..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/OperationMetadata/Status.php +++ /dev/null @@ -1,83 +0,0 @@ -google.api.servicemanagement.v1.OperationMetadata.Status - */ -class Status -{ - /** - * Unspecifed code. - * - * Generated from protobuf enum STATUS_UNSPECIFIED = 0; - */ - const STATUS_UNSPECIFIED = 0; - /** - * The operation or step has completed without errors. - * - * Generated from protobuf enum DONE = 1; - */ - const DONE = 1; - /** - * The operation or step has not started yet. - * - * Generated from protobuf enum NOT_STARTED = 2; - */ - const NOT_STARTED = 2; - /** - * The operation or step is in progress. - * - * Generated from protobuf enum IN_PROGRESS = 3; - */ - const IN_PROGRESS = 3; - /** - * The operation or step has completed with errors. If the operation is - * rollbackable, the rollback completed with errors too. - * - * Generated from protobuf enum FAILED = 4; - */ - const FAILED = 4; - /** - * The operation or step has completed with cancellation. - * - * Generated from protobuf enum CANCELLED = 5; - */ - const CANCELLED = 5; - - private static $valueToName = [ - self::STATUS_UNSPECIFIED => 'STATUS_UNSPECIFIED', - self::DONE => 'DONE', - self::NOT_STARTED => 'NOT_STARTED', - self::IN_PROGRESS => 'IN_PROGRESS', - self::FAILED => 'FAILED', - 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); - } -} - diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/OperationMetadata/Step.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/OperationMetadata/Step.php deleted file mode 100644 index 695727dfdb86..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/OperationMetadata/Step.php +++ /dev/null @@ -1,101 +0,0 @@ -google.api.servicemanagement.v1.OperationMetadata.Step - */ -class Step extends \Google\Protobuf\Internal\Message -{ - /** - * The short description of the step. - * - * Generated from protobuf field string description = 2; - */ - protected $description = ''; - /** - * The status code. - * - * Generated from protobuf field .google.api.servicemanagement.v1.OperationMetadata.Status status = 4; - */ - protected $status = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $description - * The short description of the step. - * @type int $status - * The status code. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Servicemanagement\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * The short description of the step. - * - * Generated from protobuf field string description = 2; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * The short description of the step. - * - * 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; - } - - /** - * The status code. - * - * Generated from protobuf field .google.api.servicemanagement.v1.OperationMetadata.Status status = 4; - * @return int - */ - public function getStatus() - { - return $this->status; - } - - /** - * The status code. - * - * Generated from protobuf field .google.api.servicemanagement.v1.OperationMetadata.Status status = 4; - * @param int $var - * @return $this - */ - public function setStatus($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\ServiceManagement\V1\OperationMetadata\Status::class); - $this->status = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Rollout.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Rollout.php deleted file mode 100644 index f4fc4a99bd85..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Rollout.php +++ /dev/null @@ -1,332 +0,0 @@ -google.api.servicemanagement.v1.Rollout - */ -class Rollout extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. Unique identifier of this Rollout. Must be no longer than 63 - * characters and only lower case letters, digits, '.', '_' and '-' are - * allowed. - * If not specified by client, the server will generate one. The generated id - * will have the form of , where "date" is the create - * date in ISO 8601 format. "revision number" is a monotonically increasing - * positive number that is reset every day for each service. - * An example of the generated rollout_id is '2016-02-16r1' - * - * Generated from protobuf field string rollout_id = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $rollout_id = ''; - /** - * Creation time of the rollout. Readonly. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2; - */ - protected $create_time = null; - /** - * The user who created the Rollout. Readonly. - * - * Generated from protobuf field string created_by = 3; - */ - protected $created_by = ''; - /** - * The status of this rollout. Readonly. In case of a failed rollout, - * the system will automatically rollback to the current Rollout - * version. Readonly. - * - * Generated from protobuf field .google.api.servicemanagement.v1.Rollout.RolloutStatus status = 4; - */ - protected $status = 0; - /** - * The name of the service associated with this Rollout. - * - * Generated from protobuf field string service_name = 8; - */ - protected $service_name = ''; - protected $strategy; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $rollout_id - * Optional. Unique identifier of this Rollout. Must be no longer than 63 - * characters and only lower case letters, digits, '.', '_' and '-' are - * allowed. - * If not specified by client, the server will generate one. The generated id - * will have the form of , where "date" is the create - * date in ISO 8601 format. "revision number" is a monotonically increasing - * positive number that is reset every day for each service. - * An example of the generated rollout_id is '2016-02-16r1' - * @type \Google\Protobuf\Timestamp $create_time - * Creation time of the rollout. Readonly. - * @type string $created_by - * The user who created the Rollout. Readonly. - * @type int $status - * The status of this rollout. Readonly. In case of a failed rollout, - * the system will automatically rollback to the current Rollout - * version. Readonly. - * @type \Google\Cloud\ServiceManagement\V1\Rollout\TrafficPercentStrategy $traffic_percent_strategy - * Google Service Control selects service configurations based on - * traffic percentage. - * @type \Google\Cloud\ServiceManagement\V1\Rollout\DeleteServiceStrategy $delete_service_strategy - * The strategy associated with a rollout to delete a `ManagedService`. - * Readonly. - * @type string $service_name - * The name of the service associated with this Rollout. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Servicemanagement\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * Optional. Unique identifier of this Rollout. Must be no longer than 63 - * characters and only lower case letters, digits, '.', '_' and '-' are - * allowed. - * If not specified by client, the server will generate one. The generated id - * will have the form of , where "date" is the create - * date in ISO 8601 format. "revision number" is a monotonically increasing - * positive number that is reset every day for each service. - * An example of the generated rollout_id is '2016-02-16r1' - * - * Generated from protobuf field string rollout_id = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getRolloutId() - { - return $this->rollout_id; - } - - /** - * Optional. Unique identifier of this Rollout. Must be no longer than 63 - * characters and only lower case letters, digits, '.', '_' and '-' are - * allowed. - * If not specified by client, the server will generate one. The generated id - * will have the form of , where "date" is the create - * date in ISO 8601 format. "revision number" is a monotonically increasing - * positive number that is reset every day for each service. - * An example of the generated rollout_id is '2016-02-16r1' - * - * Generated from protobuf field string rollout_id = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setRolloutId($var) - { - GPBUtil::checkString($var, True); - $this->rollout_id = $var; - - return $this; - } - - /** - * Creation time of the rollout. Readonly. - * - * 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); - } - - /** - * Creation time of the rollout. Readonly. - * - * 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; - } - - /** - * The user who created the Rollout. Readonly. - * - * Generated from protobuf field string created_by = 3; - * @return string - */ - public function getCreatedBy() - { - return $this->created_by; - } - - /** - * The user who created the Rollout. Readonly. - * - * Generated from protobuf field string created_by = 3; - * @param string $var - * @return $this - */ - public function setCreatedBy($var) - { - GPBUtil::checkString($var, True); - $this->created_by = $var; - - return $this; - } - - /** - * The status of this rollout. Readonly. In case of a failed rollout, - * the system will automatically rollback to the current Rollout - * version. Readonly. - * - * Generated from protobuf field .google.api.servicemanagement.v1.Rollout.RolloutStatus status = 4; - * @return int - */ - public function getStatus() - { - return $this->status; - } - - /** - * The status of this rollout. Readonly. In case of a failed rollout, - * the system will automatically rollback to the current Rollout - * version. Readonly. - * - * Generated from protobuf field .google.api.servicemanagement.v1.Rollout.RolloutStatus status = 4; - * @param int $var - * @return $this - */ - public function setStatus($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\ServiceManagement\V1\Rollout\RolloutStatus::class); - $this->status = $var; - - return $this; - } - - /** - * Google Service Control selects service configurations based on - * traffic percentage. - * - * Generated from protobuf field .google.api.servicemanagement.v1.Rollout.TrafficPercentStrategy traffic_percent_strategy = 5; - * @return \Google\Cloud\ServiceManagement\V1\Rollout\TrafficPercentStrategy|null - */ - public function getTrafficPercentStrategy() - { - return $this->readOneof(5); - } - - public function hasTrafficPercentStrategy() - { - return $this->hasOneof(5); - } - - /** - * Google Service Control selects service configurations based on - * traffic percentage. - * - * Generated from protobuf field .google.api.servicemanagement.v1.Rollout.TrafficPercentStrategy traffic_percent_strategy = 5; - * @param \Google\Cloud\ServiceManagement\V1\Rollout\TrafficPercentStrategy $var - * @return $this - */ - public function setTrafficPercentStrategy($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\ServiceManagement\V1\Rollout\TrafficPercentStrategy::class); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * The strategy associated with a rollout to delete a `ManagedService`. - * Readonly. - * - * Generated from protobuf field .google.api.servicemanagement.v1.Rollout.DeleteServiceStrategy delete_service_strategy = 200; - * @return \Google\Cloud\ServiceManagement\V1\Rollout\DeleteServiceStrategy|null - */ - public function getDeleteServiceStrategy() - { - return $this->readOneof(200); - } - - public function hasDeleteServiceStrategy() - { - return $this->hasOneof(200); - } - - /** - * The strategy associated with a rollout to delete a `ManagedService`. - * Readonly. - * - * Generated from protobuf field .google.api.servicemanagement.v1.Rollout.DeleteServiceStrategy delete_service_strategy = 200; - * @param \Google\Cloud\ServiceManagement\V1\Rollout\DeleteServiceStrategy $var - * @return $this - */ - public function setDeleteServiceStrategy($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\ServiceManagement\V1\Rollout\DeleteServiceStrategy::class); - $this->writeOneof(200, $var); - - return $this; - } - - /** - * The name of the service associated with this Rollout. - * - * Generated from protobuf field string service_name = 8; - * @return string - */ - public function getServiceName() - { - return $this->service_name; - } - - /** - * The name of the service associated with this Rollout. - * - * Generated from protobuf field string service_name = 8; - * @param string $var - * @return $this - */ - public function setServiceName($var) - { - GPBUtil::checkString($var, True); - $this->service_name = $var; - - return $this; - } - - /** - * @return string - */ - public function getStrategy() - { - return $this->whichOneof("strategy"); - } - -} - diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Rollout/DeleteServiceStrategy.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Rollout/DeleteServiceStrategy.php deleted file mode 100644 index e99cb79827d8..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Rollout/DeleteServiceStrategy.php +++ /dev/null @@ -1,34 +0,0 @@ -google.api.servicemanagement.v1.Rollout.DeleteServiceStrategy - */ -class DeleteServiceStrategy extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Servicemanagement\V1\Resources::initOnce(); - parent::__construct($data); - } - -} - diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Rollout/RolloutStatus.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Rollout/RolloutStatus.php deleted file mode 100644 index 66c23dce9241..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Rollout/RolloutStatus.php +++ /dev/null @@ -1,91 +0,0 @@ -google.api.servicemanagement.v1.Rollout.RolloutStatus - */ -class RolloutStatus -{ - /** - * No status specified. - * - * Generated from protobuf enum ROLLOUT_STATUS_UNSPECIFIED = 0; - */ - const ROLLOUT_STATUS_UNSPECIFIED = 0; - /** - * The Rollout is in progress. - * - * Generated from protobuf enum IN_PROGRESS = 1; - */ - const IN_PROGRESS = 1; - /** - * The Rollout has completed successfully. - * - * Generated from protobuf enum SUCCESS = 2; - */ - const SUCCESS = 2; - /** - * The Rollout has been cancelled. This can happen if you have overlapping - * Rollout pushes, and the previous ones will be cancelled. - * - * Generated from protobuf enum CANCELLED = 3; - */ - const CANCELLED = 3; - /** - * The Rollout has failed and the rollback attempt has failed too. - * - * Generated from protobuf enum FAILED = 4; - */ - const FAILED = 4; - /** - * The Rollout has not started yet and is pending for execution. - * - * Generated from protobuf enum PENDING = 5; - */ - const PENDING = 5; - /** - * The Rollout has failed and rolled back to the previous successful - * Rollout. - * - * Generated from protobuf enum FAILED_ROLLED_BACK = 6; - */ - const FAILED_ROLLED_BACK = 6; - - private static $valueToName = [ - self::ROLLOUT_STATUS_UNSPECIFIED => 'ROLLOUT_STATUS_UNSPECIFIED', - self::IN_PROGRESS => 'IN_PROGRESS', - self::SUCCESS => 'SUCCESS', - self::CANCELLED => 'CANCELLED', - self::FAILED => 'FAILED', - self::PENDING => 'PENDING', - self::FAILED_ROLLED_BACK => 'FAILED_ROLLED_BACK', - ]; - - 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/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Rollout/TrafficPercentStrategy.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Rollout/TrafficPercentStrategy.php deleted file mode 100644 index 200fc2c0bd71..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/Rollout/TrafficPercentStrategy.php +++ /dev/null @@ -1,100 +0,0 @@ -google.api.servicemanagement.v1.Rollout.TrafficPercentStrategy - */ -class TrafficPercentStrategy extends \Google\Protobuf\Internal\Message -{ - /** - * Maps service configuration IDs to their corresponding traffic percentage. - * Key is the service configuration ID, Value is the traffic percentage - * which must be greater than 0.0 and the sum must equal to 100.0. - * - * Generated from protobuf field map percentages = 1; - */ - private $percentages; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\MapField $percentages - * Maps service configuration IDs to their corresponding traffic percentage. - * Key is the service configuration ID, Value is the traffic percentage - * which must be greater than 0.0 and the sum must equal to 100.0. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Servicemanagement\V1\Resources::initOnce(); - parent::__construct($data); - } - - /** - * Maps service configuration IDs to their corresponding traffic percentage. - * Key is the service configuration ID, Value is the traffic percentage - * which must be greater than 0.0 and the sum must equal to 100.0. - * - * Generated from protobuf field map percentages = 1; - * @return \Google\Protobuf\Internal\MapField - */ - public function getPercentages() - { - return $this->percentages; - } - - /** - * Maps service configuration IDs to their corresponding traffic percentage. - * Key is the service configuration ID, Value is the traffic percentage - * which must be greater than 0.0 and the sum must equal to 100.0. - * - * Generated from protobuf field map percentages = 1; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setPercentages($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::DOUBLE); - $this->percentages = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/SubmitConfigSourceRequest.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/SubmitConfigSourceRequest.php deleted file mode 100644 index 33c7dbcdefae..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/SubmitConfigSourceRequest.php +++ /dev/null @@ -1,182 +0,0 @@ -google.api.servicemanagement.v1.SubmitConfigSourceRequest - */ -class SubmitConfigSourceRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * - * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $service_name = ''; - /** - * Required. The source configuration for the service. - * - * Generated from protobuf field .google.api.servicemanagement.v1.ConfigSource config_source = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $config_source = null; - /** - * Optional. If set, this will result in the generation of a - * `google.api.Service` configuration based on the `ConfigSource` provided, - * but the generated config and the sources will NOT be persisted. - * - * Generated from protobuf field bool validate_only = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $validate_only = false; - - /** - * @param string $serviceName Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * @param \Google\Cloud\ServiceManagement\V1\ConfigSource $configSource Required. The source configuration for the service. - * @param bool $validateOnly Optional. If set, this will result in the generation of a - * `google.api.Service` configuration based on the `ConfigSource` provided, - * but the generated config and the sources will NOT be persisted. - * - * @return \Google\Cloud\ServiceManagement\V1\SubmitConfigSourceRequest - * - * @experimental - */ - public static function build(string $serviceName, \Google\Cloud\ServiceManagement\V1\ConfigSource $configSource, bool $validateOnly): self - { - return (new self()) - ->setServiceName($serviceName) - ->setConfigSource($configSource) - ->setValidateOnly($validateOnly); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $service_name - * Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * @type \Google\Cloud\ServiceManagement\V1\ConfigSource $config_source - * Required. The source configuration for the service. - * @type bool $validate_only - * Optional. If set, this will result in the generation of a - * `google.api.Service` configuration based on the `ConfigSource` provided, - * but the generated config and the sources will NOT be persisted. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Servicemanagement\V1\Servicemanager::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * - * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getServiceName() - { - return $this->service_name; - } - - /** - * Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * - * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setServiceName($var) - { - GPBUtil::checkString($var, True); - $this->service_name = $var; - - return $this; - } - - /** - * Required. The source configuration for the service. - * - * Generated from protobuf field .google.api.servicemanagement.v1.ConfigSource config_source = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\ServiceManagement\V1\ConfigSource|null - */ - public function getConfigSource() - { - return $this->config_source; - } - - public function hasConfigSource() - { - return isset($this->config_source); - } - - public function clearConfigSource() - { - unset($this->config_source); - } - - /** - * Required. The source configuration for the service. - * - * Generated from protobuf field .google.api.servicemanagement.v1.ConfigSource config_source = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\ServiceManagement\V1\ConfigSource $var - * @return $this - */ - public function setConfigSource($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\ServiceManagement\V1\ConfigSource::class); - $this->config_source = $var; - - return $this; - } - - /** - * Optional. If set, this will result in the generation of a - * `google.api.Service` configuration based on the `ConfigSource` provided, - * but the generated config and the sources will NOT be persisted. - * - * 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, this will result in the generation of a - * `google.api.Service` configuration based on the `ConfigSource` provided, - * but the generated config and the sources will NOT be persisted. - * - * 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/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/SubmitConfigSourceResponse.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/SubmitConfigSourceResponse.php deleted file mode 100644 index 92bd4f1d3637..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/SubmitConfigSourceResponse.php +++ /dev/null @@ -1,77 +0,0 @@ -google.api.servicemanagement.v1.SubmitConfigSourceResponse - */ -class SubmitConfigSourceResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The generated service configuration. - * - * Generated from protobuf field .google.api.Service service_config = 1; - */ - protected $service_config = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Api\Service $service_config - * The generated service configuration. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Servicemanagement\V1\Servicemanager::initOnce(); - parent::__construct($data); - } - - /** - * The generated service configuration. - * - * Generated from protobuf field .google.api.Service service_config = 1; - * @return \Google\Api\Service|null - */ - public function getServiceConfig() - { - return $this->service_config; - } - - public function hasServiceConfig() - { - return isset($this->service_config); - } - - public function clearServiceConfig() - { - unset($this->service_config); - } - - /** - * The generated service configuration. - * - * Generated from protobuf field .google.api.Service service_config = 1; - * @param \Google\Api\Service $var - * @return $this - */ - public function setServiceConfig($var) - { - GPBUtil::checkMessage($var, \Google\Api\Service::class); - $this->service_config = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/UndeleteServiceRequest.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/UndeleteServiceRequest.php deleted file mode 100644 index 3db84cbf537a..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/UndeleteServiceRequest.php +++ /dev/null @@ -1,90 +0,0 @@ -google.api.servicemanagement.v1.UndeleteServiceRequest - */ -class UndeleteServiceRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * - * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $service_name = ''; - - /** - * @param string $serviceName Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * - * @return \Google\Cloud\ServiceManagement\V1\UndeleteServiceRequest - * - * @experimental - */ - public static function build(string $serviceName): self - { - return (new self()) - ->setServiceName($serviceName); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $service_name - * Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Servicemanagement\V1\Servicemanager::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * - * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getServiceName() - { - return $this->service_name; - } - - /** - * Required. The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - * - * Generated from protobuf field string service_name = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setServiceName($var) - { - GPBUtil::checkString($var, True); - $this->service_name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/UndeleteServiceResponse.php b/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/UndeleteServiceResponse.php deleted file mode 100644 index 3062350a4ed8..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/proto/src/Google/Cloud/ServiceManagement/V1/UndeleteServiceResponse.php +++ /dev/null @@ -1,77 +0,0 @@ -google.api.servicemanagement.v1.UndeleteServiceResponse - */ -class UndeleteServiceResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Revived service resource. - * - * Generated from protobuf field .google.api.servicemanagement.v1.ManagedService service = 1; - */ - protected $service = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\ServiceManagement\V1\ManagedService $service - * Revived service resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Api\Servicemanagement\V1\Servicemanager::initOnce(); - parent::__construct($data); - } - - /** - * Revived service resource. - * - * Generated from protobuf field .google.api.servicemanagement.v1.ManagedService service = 1; - * @return \Google\Cloud\ServiceManagement\V1\ManagedService|null - */ - public function getService() - { - return $this->service; - } - - public function hasService() - { - return isset($this->service); - } - - public function clearService() - { - unset($this->service); - } - - /** - * Revived service resource. - * - * Generated from protobuf field .google.api.servicemanagement.v1.ManagedService service = 1; - * @param \Google\Cloud\ServiceManagement\V1\ManagedService $var - * @return $this - */ - public function setService($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\ServiceManagement\V1\ManagedService::class); - $this->service = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/create_service.php b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/create_service.php deleted file mode 100644 index df7d257431cc..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/create_service.php +++ /dev/null @@ -1,81 +0,0 @@ - - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function create_service_sample(): void -{ - // Create a client. - $serviceManagerClient = new ServiceManagerClient(); - - // Prepare the request message. - $service = new ManagedService(); - $request = (new CreateServiceRequest()) - ->setService($service); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $serviceManagerClient->createService($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var ManagedService $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 servicemanagement_v1_generated_ServiceManager_CreateService_sync] diff --git a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/create_service_config.php b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/create_service_config.php deleted file mode 100644 index 317eb97b1af6..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/create_service_config.php +++ /dev/null @@ -1,81 +0,0 @@ -setServiceName($serviceName) - ->setServiceConfig($serviceConfig); - - // Call the API and handle any network failures. - try { - /** @var Service $response */ - $response = $serviceManagerClient->createServiceConfig($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 -{ - $serviceName = '[SERVICE_NAME]'; - - create_service_config_sample($serviceName); -} -// [END servicemanagement_v1_generated_ServiceManager_CreateServiceConfig_sync] diff --git a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/create_service_rollout.php b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/create_service_rollout.php deleted file mode 100644 index 4a5ca5f55829..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/create_service_rollout.php +++ /dev/null @@ -1,99 +0,0 @@ - - * - * @param string $serviceName The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - */ -function create_service_rollout_sample(string $serviceName): void -{ - // Create a client. - $serviceManagerClient = new ServiceManagerClient(); - - // Prepare the request message. - $rollout = new Rollout(); - $request = (new CreateServiceRolloutRequest()) - ->setServiceName($serviceName) - ->setRollout($rollout); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $serviceManagerClient->createServiceRollout($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var Rollout $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 -{ - $serviceName = '[SERVICE_NAME]'; - - create_service_rollout_sample($serviceName); -} -// [END servicemanagement_v1_generated_ServiceManager_CreateServiceRollout_sync] diff --git a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/delete_service.php b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/delete_service.php deleted file mode 100644 index c47fe9bb41bd..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/delete_service.php +++ /dev/null @@ -1,88 +0,0 @@ - - * - * @param string $serviceName The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - */ -function delete_service_sample(string $serviceName): void -{ - // Create a client. - $serviceManagerClient = new ServiceManagerClient(); - - // Prepare the request message. - $request = (new DeleteServiceRequest()) - ->setServiceName($serviceName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $serviceManagerClient->deleteService($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 -{ - $serviceName = '[SERVICE_NAME]'; - - delete_service_sample($serviceName); -} -// [END servicemanagement_v1_generated_ServiceManager_DeleteService_sync] diff --git a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/generate_config_report.php b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/generate_config_report.php deleted file mode 100644 index be4f1ff3e5c1..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/generate_config_report.php +++ /dev/null @@ -1,70 +0,0 @@ -setNewConfig($newConfig); - - // Call the API and handle any network failures. - try { - /** @var GenerateConfigReportResponse $response */ - $response = $serviceManagerClient->generateConfigReport($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END servicemanagement_v1_generated_ServiceManager_GenerateConfigReport_sync] diff --git a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/get_iam_policy.php b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/get_iam_policy.php deleted file mode 100644 index 2f64048d9e30..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/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 = $serviceManagerClient->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 servicemanagement_v1_generated_ServiceManager_GetIamPolicy_sync] diff --git a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/get_service.php b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/get_service.php deleted file mode 100644 index e0674df1d8d3..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/get_service.php +++ /dev/null @@ -1,72 +0,0 @@ -setServiceName($serviceName); - - // Call the API and handle any network failures. - try { - /** @var ManagedService $response */ - $response = $serviceManagerClient->getService($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 -{ - $serviceName = '[SERVICE_NAME]'; - - get_service_sample($serviceName); -} -// [END servicemanagement_v1_generated_ServiceManager_GetService_sync] diff --git a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/get_service_config.php b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/get_service_config.php deleted file mode 100644 index 5199d5758add..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/get_service_config.php +++ /dev/null @@ -1,78 +0,0 @@ -setServiceName($serviceName) - ->setConfigId($configId); - - // Call the API and handle any network failures. - try { - /** @var Service $response */ - $response = $serviceManagerClient->getServiceConfig($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 -{ - $serviceName = '[SERVICE_NAME]'; - $configId = '[CONFIG_ID]'; - - get_service_config_sample($serviceName, $configId); -} -// [END servicemanagement_v1_generated_ServiceManager_GetServiceConfig_sync] diff --git a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/get_service_rollout.php b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/get_service_rollout.php deleted file mode 100644 index 306dbb817d53..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/get_service_rollout.php +++ /dev/null @@ -1,76 +0,0 @@ -setServiceName($serviceName) - ->setRolloutId($rolloutId); - - // Call the API and handle any network failures. - try { - /** @var Rollout $response */ - $response = $serviceManagerClient->getServiceRollout($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 -{ - $serviceName = '[SERVICE_NAME]'; - $rolloutId = '[ROLLOUT_ID]'; - - get_service_rollout_sample($serviceName, $rolloutId); -} -// [END servicemanagement_v1_generated_ServiceManager_GetServiceRollout_sync] diff --git a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/list_service_configs.php b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/list_service_configs.php deleted file mode 100644 index b3d94fe588cd..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/list_service_configs.php +++ /dev/null @@ -1,78 +0,0 @@ -setServiceName($serviceName); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $serviceManagerClient->listServiceConfigs($request); - - /** @var Service $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 -{ - $serviceName = '[SERVICE_NAME]'; - - list_service_configs_sample($serviceName); -} -// [END servicemanagement_v1_generated_ServiceManager_ListServiceConfigs_sync] diff --git a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/list_service_rollouts.php b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/list_service_rollouts.php deleted file mode 100644 index 1d46ced4f5fc..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/list_service_rollouts.php +++ /dev/null @@ -1,90 +0,0 @@ -setServiceName($serviceName) - ->setFilter($filter); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $serviceManagerClient->listServiceRollouts($request); - - /** @var Rollout $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 -{ - $serviceName = '[SERVICE_NAME]'; - $filter = '[FILTER]'; - - list_service_rollouts_sample($serviceName, $filter); -} -// [END servicemanagement_v1_generated_ServiceManager_ListServiceRollouts_sync] diff --git a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/list_services.php b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/list_services.php deleted file mode 100644 index ccea027535d2..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/list_services.php +++ /dev/null @@ -1,66 +0,0 @@ -listServices($request); - - /** @var ManagedService $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 servicemanagement_v1_generated_ServiceManager_ListServices_sync] diff --git a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/set_iam_policy.php b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/set_iam_policy.php deleted file mode 100644 index 7f22549ebd66..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/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 = $serviceManagerClient->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 servicemanagement_v1_generated_ServiceManager_SetIamPolicy_sync] diff --git a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/submit_config_source.php b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/submit_config_source.php deleted file mode 100644 index f7bc8a36cc42..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/submit_config_source.php +++ /dev/null @@ -1,100 +0,0 @@ - - * - * @param string $serviceName The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - */ -function submit_config_source_sample(string $serviceName): void -{ - // Create a client. - $serviceManagerClient = new ServiceManagerClient(); - - // Prepare the request message. - $configSource = new ConfigSource(); - $request = (new SubmitConfigSourceRequest()) - ->setServiceName($serviceName) - ->setConfigSource($configSource); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $serviceManagerClient->submitConfigSource($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var SubmitConfigSourceResponse $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 -{ - $serviceName = '[SERVICE_NAME]'; - - submit_config_source_sample($serviceName); -} -// [END servicemanagement_v1_generated_ServiceManager_SubmitConfigSource_sync] diff --git a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/test_iam_permissions.php b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/test_iam_permissions.php deleted file mode 100644 index 311f3a94380e..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/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 = $serviceManagerClient->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 servicemanagement_v1_generated_ServiceManager_TestIamPermissions_sync] diff --git a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/undelete_service.php b/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/undelete_service.php deleted file mode 100644 index f3c4b43f8825..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/samples/V1/ServiceManagerClient/undelete_service.php +++ /dev/null @@ -1,89 +0,0 @@ - - * - * @param string $serviceName The name of the service. See the - * [overview](https://cloud.google.com/service-management/overview) for naming - * requirements. For example: `example.googleapis.com`. - */ -function undelete_service_sample(string $serviceName): void -{ - // Create a client. - $serviceManagerClient = new ServiceManagerClient(); - - // Prepare the request message. - $request = (new UndeleteServiceRequest()) - ->setServiceName($serviceName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $serviceManagerClient->undeleteService($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var UndeleteServiceResponse $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 -{ - $serviceName = '[SERVICE_NAME]'; - - undelete_service_sample($serviceName); -} -// [END servicemanagement_v1_generated_ServiceManager_UndeleteService_sync] diff --git a/owl-bot-staging/ServiceManagement/v1/src/V1/Client/ServiceManagerClient.php b/owl-bot-staging/ServiceManagement/v1/src/V1/Client/ServiceManagerClient.php deleted file mode 100644 index 91d0b60eb5aa..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/src/V1/Client/ServiceManagerClient.php +++ /dev/null @@ -1,775 +0,0 @@ - createServiceAsync(CreateServiceRequest $request, array $optionalArgs = []) - * @method PromiseInterface createServiceConfigAsync(CreateServiceConfigRequest $request, array $optionalArgs = []) - * @method PromiseInterface createServiceRolloutAsync(CreateServiceRolloutRequest $request, array $optionalArgs = []) - * @method PromiseInterface deleteServiceAsync(DeleteServiceRequest $request, array $optionalArgs = []) - * @method PromiseInterface generateConfigReportAsync(GenerateConfigReportRequest $request, array $optionalArgs = []) - * @method PromiseInterface getServiceAsync(GetServiceRequest $request, array $optionalArgs = []) - * @method PromiseInterface getServiceConfigAsync(GetServiceConfigRequest $request, array $optionalArgs = []) - * @method PromiseInterface getServiceRolloutAsync(GetServiceRolloutRequest $request, array $optionalArgs = []) - * @method PromiseInterface listServiceConfigsAsync(ListServiceConfigsRequest $request, array $optionalArgs = []) - * @method PromiseInterface listServiceRolloutsAsync(ListServiceRolloutsRequest $request, array $optionalArgs = []) - * @method PromiseInterface listServicesAsync(ListServicesRequest $request, array $optionalArgs = []) - * @method PromiseInterface submitConfigSourceAsync(SubmitConfigSourceRequest $request, array $optionalArgs = []) - * @method PromiseInterface undeleteServiceAsync(UndeleteServiceRequest $request, array $optionalArgs = []) - * @method PromiseInterface getIamPolicyAsync(GetIamPolicyRequest $request, array $optionalArgs = []) - * @method PromiseInterface setIamPolicyAsync(SetIamPolicyRequest $request, array $optionalArgs = []) - * @method PromiseInterface testIamPermissionsAsync(TestIamPermissionsRequest $request, array $optionalArgs = []) - */ -final class ServiceManagerClient -{ - use GapicClientTrait; - - /** The name of the service. */ - private const SERVICE_NAME = 'google.api.servicemanagement.v1.ServiceManager'; - - /** - * The default address of the service. - * - * @deprecated SERVICE_ADDRESS_TEMPLATE should be used instead. - */ - private const SERVICE_ADDRESS = 'servicemanagement.googleapis.com'; - - /** The address template of the service. */ - private const SERVICE_ADDRESS_TEMPLATE = 'servicemanagement.UNIVERSE_DOMAIN'; - - /** The default port of the service. */ - private const DEFAULT_SERVICE_PORT = 443; - - /** The name of the code generator, to be included in the agent header. */ - private 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', - 'https://www.googleapis.com/auth/service.management', - 'https://www.googleapis.com/auth/service.management.readonly', - ]; - - private $operationsClient; - - private static function getClientDefaults() - { - return [ - 'serviceName' => self::SERVICE_NAME, - 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, - 'clientConfig' => __DIR__ . '/../resources/service_manager_client_config.json', - 'descriptorsConfigPath' => __DIR__ . '/../resources/service_manager_descriptor_config.php', - 'gcpApiConfigPath' => __DIR__ . '/../resources/service_manager_grpc_config.json', - 'credentialsConfig' => [ - 'defaultScopes' => self::$serviceScopes, - ], - 'transportConfig' => [ - 'rest' => [ - 'restClientConfigPath' => __DIR__ . '/../resources/service_manager_rest_client_config.php', - ], - ], - ]; - } - - /** - * 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 = $this->descriptors[$methodName]['longRunning'] ?? []; - $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); - $operation->reload(); - return $operation; - } - - /** - * Create the default operation client for the service. - * - * @param array $options ClientOptions for the client. - * - * @return OperationsClient - */ - private function createOperationsClient(array $options) - { - // Unset client-specific configuration options - unset($options['serviceName'], $options['clientConfig'], $options['descriptorsConfigPath']); - - if (isset($options['operationsClient'])) { - return $options['operationsClient']; - } - - return new OperationsClient($options); - } - - /** - * Constructor. - * - * @param array|ClientOptions $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 'servicemanagement.googleapis.com:443'. - * @type FetchAuthTokenInterface|CredentialsWrapper $credentials - * This option should only be used with a pre-constructed - * {@see FetchAuthTokenInterface} or {@see CredentialsWrapper} object. Note that - * when one of these objects are provided, any settings in $credentialsConfig will - * be ignored. - * **Important**: If you are providing a path to a credentials file, or a decoded - * credentials file as a PHP array, this usage is now DEPRECATED. Providing an - * unvalidated credential configuration to Google APIs can compromise the security - * of your systems and data. It is recommended to create the credentials explicitly - * ``` - * use Google\Auth\Credentials\ServiceAccountCredentials; - * use Google\Cloud\ServiceManagement\V1\ServiceManagerClient; - * $creds = new ServiceAccountCredentials($scopes, $json); - * $options = new ServiceManagerClient(['credentials' => $creds]); - * ``` - * {@see - * https://cloud.google.com/docs/authentication/external/externally-sourced-credentials} - * @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. - * @type false|LoggerInterface $logger - * A PSR-3 compliant logger. If set to false, logging is disabled, ignoring the - * 'GOOGLE_SDK_PHP_LOGGING' environment flag - * @type string $universeDomain - * The service domain for the client. Defaults to 'googleapis.com'. - * } - * - * @throws ValidationException - */ - public function __construct(array|ClientOptions $options = []) - { - $clientOptions = $this->buildClientOptions($options); - $this->setClientOptions($clientOptions); - $this->operationsClient = $this->createOperationsClient($clientOptions); - } - - /** Handles execution of the async variants for each documented method. */ - public function __call($method, $args) - { - if (substr($method, -5) !== 'Async') { - trigger_error('Call to undefined method ' . __CLASS__ . "::$method()", E_USER_ERROR); - } - - array_unshift($args, substr($method, 0, -5)); - return call_user_func_array([$this, 'startAsyncCall'], $args); - } - - /** - * Creates a new managed service. - * - * A managed service is immutable, and is subject to mandatory 30-day - * data retention. You cannot move a service or recreate it within 30 days - * after deletion. - * - * One producer project can own no more than 500 services. For security and - * reliability purposes, a production service should be hosted in a - * dedicated producer project. - * - * Operation - * - * The async variant is {@see ServiceManagerClient::createServiceAsync()} . - * - * @example samples/V1/ServiceManagerClient/create_service.php - * - * @param CreateServiceRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function createService(CreateServiceRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('CreateService', $request, $callOptions)->wait(); - } - - /** - * Creates a new service configuration (version) for a managed service. - * This method only stores the service configuration. To roll out the service - * configuration to backend systems please call - * [CreateServiceRollout][google.api.servicemanagement.v1.ServiceManager.CreateServiceRollout]. - * - * Only the 100 most recent service configurations and ones referenced by - * existing rollouts are kept for each service. The rest will be deleted - * eventually. - * - * The async variant is {@see ServiceManagerClient::createServiceConfigAsync()} . - * - * @example samples/V1/ServiceManagerClient/create_service_config.php - * - * @param CreateServiceConfigRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Service - * - * @throws ApiException Thrown if the API call fails. - */ - public function createServiceConfig(CreateServiceConfigRequest $request, array $callOptions = []): Service - { - return $this->startApiCall('CreateServiceConfig', $request, $callOptions)->wait(); - } - - /** - * Creates a new service configuration rollout. Based on rollout, the - * Google Service Management will roll out the service configurations to - * different backend services. For example, the logging configuration will be - * pushed to Google Cloud Logging. - * - * Please note that any previous pending and running Rollouts and associated - * Operations will be automatically cancelled so that the latest Rollout will - * not be blocked by previous Rollouts. - * - * Only the 100 most recent (in any state) and the last 10 successful (if not - * already part of the set of 100 most recent) rollouts are kept for each - * service. The rest will be deleted eventually. - * - * Operation - * - * The async variant is {@see ServiceManagerClient::createServiceRolloutAsync()} . - * - * @example samples/V1/ServiceManagerClient/create_service_rollout.php - * - * @param CreateServiceRolloutRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function createServiceRollout(CreateServiceRolloutRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('CreateServiceRollout', $request, $callOptions)->wait(); - } - - /** - * Deletes a managed service. This method will change the service to the - * `Soft-Delete` state for 30 days. Within this period, service producers may - * call - * [UndeleteService][google.api.servicemanagement.v1.ServiceManager.UndeleteService] - * to restore the service. After 30 days, the service will be permanently - * deleted. - * - * Operation - * - * The async variant is {@see ServiceManagerClient::deleteServiceAsync()} . - * - * @example samples/V1/ServiceManagerClient/delete_service.php - * - * @param DeleteServiceRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function deleteService(DeleteServiceRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('DeleteService', $request, $callOptions)->wait(); - } - - /** - * Generates and returns a report (errors, warnings and changes from - * existing configurations) associated with - * GenerateConfigReportRequest.new_value - * - * If GenerateConfigReportRequest.old_value is specified, - * GenerateConfigReportRequest will contain a single ChangeReport based on the - * comparison between GenerateConfigReportRequest.new_value and - * GenerateConfigReportRequest.old_value. - * If GenerateConfigReportRequest.old_value is not specified, this method - * will compare GenerateConfigReportRequest.new_value with the last pushed - * service configuration. - * - * The async variant is {@see ServiceManagerClient::generateConfigReportAsync()} . - * - * @example samples/V1/ServiceManagerClient/generate_config_report.php - * - * @param GenerateConfigReportRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 GenerateConfigReportResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function generateConfigReport(GenerateConfigReportRequest $request, array $callOptions = []): GenerateConfigReportResponse - { - return $this->startApiCall('GenerateConfigReport', $request, $callOptions)->wait(); - } - - /** - * Gets a managed service. Authentication is required unless the service is - * public. - * - * The async variant is {@see ServiceManagerClient::getServiceAsync()} . - * - * @example samples/V1/ServiceManagerClient/get_service.php - * - * @param GetServiceRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 ManagedService - * - * @throws ApiException Thrown if the API call fails. - */ - public function getService(GetServiceRequest $request, array $callOptions = []): ManagedService - { - return $this->startApiCall('GetService', $request, $callOptions)->wait(); - } - - /** - * Gets a service configuration (version) for a managed service. - * - * The async variant is {@see ServiceManagerClient::getServiceConfigAsync()} . - * - * @example samples/V1/ServiceManagerClient/get_service_config.php - * - * @param GetServiceConfigRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Service - * - * @throws ApiException Thrown if the API call fails. - */ - public function getServiceConfig(GetServiceConfigRequest $request, array $callOptions = []): Service - { - return $this->startApiCall('GetServiceConfig', $request, $callOptions)->wait(); - } - - /** - * Gets a service configuration - * [rollout][google.api.servicemanagement.v1.Rollout]. - * - * The async variant is {@see ServiceManagerClient::getServiceRolloutAsync()} . - * - * @example samples/V1/ServiceManagerClient/get_service_rollout.php - * - * @param GetServiceRolloutRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Rollout - * - * @throws ApiException Thrown if the API call fails. - */ - public function getServiceRollout(GetServiceRolloutRequest $request, array $callOptions = []): Rollout - { - return $this->startApiCall('GetServiceRollout', $request, $callOptions)->wait(); - } - - /** - * Lists the history of the service configuration for a managed service, - * from the newest to the oldest. - * - * The async variant is {@see ServiceManagerClient::listServiceConfigsAsync()} . - * - * @example samples/V1/ServiceManagerClient/list_service_configs.php - * - * @param ListServiceConfigsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listServiceConfigs(ListServiceConfigsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListServiceConfigs', $request, $callOptions); - } - - /** - * Lists the history of the service configuration rollouts for a managed - * service, from the newest to the oldest. - * - * The async variant is {@see ServiceManagerClient::listServiceRolloutsAsync()} . - * - * @example samples/V1/ServiceManagerClient/list_service_rollouts.php - * - * @param ListServiceRolloutsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listServiceRollouts(ListServiceRolloutsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListServiceRollouts', $request, $callOptions); - } - - /** - * Lists managed services. - * - * Returns all public services. For authenticated users, also returns all - * services the calling user has "servicemanagement.services.get" permission - * for. - * - * The async variant is {@see ServiceManagerClient::listServicesAsync()} . - * - * @example samples/V1/ServiceManagerClient/list_services.php - * - * @param ListServicesRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listServices(ListServicesRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListServices', $request, $callOptions); - } - - /** - * Creates a new service configuration (version) for a managed service based - * on - * user-supplied configuration source files (for example: OpenAPI - * Specification). This method stores the source configurations as well as the - * generated service configuration. To rollout the service configuration to - * other services, - * please call - * [CreateServiceRollout][google.api.servicemanagement.v1.ServiceManager.CreateServiceRollout]. - * - * Only the 100 most recent configuration sources and ones referenced by - * existing service configurtions are kept for each service. The rest will be - * deleted eventually. - * - * Operation - * - * The async variant is {@see ServiceManagerClient::submitConfigSourceAsync()} . - * - * @example samples/V1/ServiceManagerClient/submit_config_source.php - * - * @param SubmitConfigSourceRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function submitConfigSource(SubmitConfigSourceRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('SubmitConfigSource', $request, $callOptions)->wait(); - } - - /** - * Revives a previously deleted managed service. The method restores the - * service using the configuration at the time the service was deleted. - * The target service must exist and must have been deleted within the - * last 30 days. - * - * Operation - * - * The async variant is {@see ServiceManagerClient::undeleteServiceAsync()} . - * - * @example samples/V1/ServiceManagerClient/undelete_service.php - * - * @param UndeleteServiceRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function undeleteService(UndeleteServiceRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('UndeleteService', $request, $callOptions)->wait(); - } - - /** - * Gets the access control policy for a resource. Returns an empty policy - * if the resource exists and does not have a policy set. - * - * The async variant is {@see ServiceManagerClient::getIamPolicyAsync()} . - * - * @example samples/V1/ServiceManagerClient/get_iam_policy.php - * - * @param GetIamPolicyRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Policy - * - * @throws ApiException Thrown if the API call fails. - */ - public function getIamPolicy(GetIamPolicyRequest $request, array $callOptions = []): Policy - { - return $this->startApiCall('GetIamPolicy', $request, $callOptions)->wait(); - } - - /** - * Sets the access control policy on the specified resource. Replaces - * any existing policy. - * - * Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` - * errors. - * - * The async variant is {@see ServiceManagerClient::setIamPolicyAsync()} . - * - * @example samples/V1/ServiceManagerClient/set_iam_policy.php - * - * @param SetIamPolicyRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Policy - * - * @throws ApiException Thrown if the API call fails. - */ - public function setIamPolicy(SetIamPolicyRequest $request, array $callOptions = []): Policy - { - return $this->startApiCall('SetIamPolicy', $request, $callOptions)->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. - * - * The async variant is {@see ServiceManagerClient::testIamPermissionsAsync()} . - * - * @example samples/V1/ServiceManagerClient/test_iam_permissions.php - * - * @param TestIamPermissionsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 TestIamPermissionsResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function testIamPermissions(TestIamPermissionsRequest $request, array $callOptions = []): TestIamPermissionsResponse - { - return $this->startApiCall('TestIamPermissions', $request, $callOptions)->wait(); - } -} diff --git a/owl-bot-staging/ServiceManagement/v1/src/V1/gapic_metadata.json b/owl-bot-staging/ServiceManagement/v1/src/V1/gapic_metadata.json deleted file mode 100644 index a49b2d300c46..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/src/V1/gapic_metadata.json +++ /dev/null @@ -1,98 +0,0 @@ -{ - "schema": "1.0", - "comment": "This file maps proto services\/RPCs to the corresponding library clients\/methods", - "language": "php", - "protoPackage": "google.api.servicemanagement.v1", - "libraryPackage": "Google\\Cloud\\ServiceManagement\\V1", - "services": { - "ServiceManager": { - "clients": { - "grpc": { - "libraryClient": "ServiceManagerGapicClient", - "rpcs": { - "CreateService": { - "methods": [ - "createService" - ] - }, - "CreateServiceConfig": { - "methods": [ - "createServiceConfig" - ] - }, - "CreateServiceRollout": { - "methods": [ - "createServiceRollout" - ] - }, - "DeleteService": { - "methods": [ - "deleteService" - ] - }, - "GenerateConfigReport": { - "methods": [ - "generateConfigReport" - ] - }, - "GetService": { - "methods": [ - "getService" - ] - }, - "GetServiceConfig": { - "methods": [ - "getServiceConfig" - ] - }, - "GetServiceRollout": { - "methods": [ - "getServiceRollout" - ] - }, - "ListServiceConfigs": { - "methods": [ - "listServiceConfigs" - ] - }, - "ListServiceRollouts": { - "methods": [ - "listServiceRollouts" - ] - }, - "ListServices": { - "methods": [ - "listServices" - ] - }, - "SubmitConfigSource": { - "methods": [ - "submitConfigSource" - ] - }, - "UndeleteService": { - "methods": [ - "undeleteService" - ] - }, - "GetIamPolicy": { - "methods": [ - "getIamPolicy" - ] - }, - "SetIamPolicy": { - "methods": [ - "setIamPolicy" - ] - }, - "TestIamPermissions": { - "methods": [ - "testIamPermissions" - ] - } - } - } - } - } - } -} \ No newline at end of file diff --git a/owl-bot-staging/ServiceManagement/v1/src/V1/resources/service_manager_client_config.json b/owl-bot-staging/ServiceManagement/v1/src/V1/resources/service_manager_client_config.json deleted file mode 100644 index 50c8109082f2..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/src/V1/resources/service_manager_client_config.json +++ /dev/null @@ -1,112 +0,0 @@ -{ - "interfaces": { - "google.api.servicemanagement.v1.ServiceManager": { - "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": { - "CreateService": { - "timeout_millis": 10000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "CreateServiceConfig": { - "timeout_millis": 10000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "CreateServiceRollout": { - "timeout_millis": 10000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "DeleteService": { - "timeout_millis": 10000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "GenerateConfigReport": { - "timeout_millis": 10000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "GetService": { - "timeout_millis": 10000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "GetServiceConfig": { - "timeout_millis": 10000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "GetServiceRollout": { - "timeout_millis": 10000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "ListServiceConfigs": { - "timeout_millis": 10000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "ListServiceRollouts": { - "timeout_millis": 10000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "ListServices": { - "timeout_millis": 10000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "SubmitConfigSource": { - "timeout_millis": 10000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "UndeleteService": { - "timeout_millis": 10000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "GetIamPolicy": { - "timeout_millis": 10000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "SetIamPolicy": { - "timeout_millis": 10000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "TestIamPermissions": { - "timeout_millis": 10000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - } - } - } - } -} diff --git a/owl-bot-staging/ServiceManagement/v1/src/V1/resources/service_manager_descriptor_config.php b/owl-bot-staging/ServiceManagement/v1/src/V1/resources/service_manager_descriptor_config.php deleted file mode 100644 index 76ccc9a45e6b..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/src/V1/resources/service_manager_descriptor_config.php +++ /dev/null @@ -1,270 +0,0 @@ - [ - 'google.api.servicemanagement.v1.ServiceManager' => [ - 'CreateService' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\ServiceManagement\V1\ManagedService', - 'metadataReturnType' => '\Google\Cloud\ServiceManagement\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - ], - 'CreateServiceRollout' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\ServiceManagement\V1\Rollout', - 'metadataReturnType' => '\Google\Cloud\ServiceManagement\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'service_name', - 'fieldAccessors' => [ - 'getServiceName', - ], - ], - ], - ], - 'DeleteService' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\ServiceManagement\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'service_name', - 'fieldAccessors' => [ - 'getServiceName', - ], - ], - ], - ], - 'SubmitConfigSource' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\ServiceManagement\V1\SubmitConfigSourceResponse', - 'metadataReturnType' => '\Google\Cloud\ServiceManagement\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'service_name', - 'fieldAccessors' => [ - 'getServiceName', - ], - ], - ], - ], - 'UndeleteService' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\ServiceManagement\V1\UndeleteServiceResponse', - 'metadataReturnType' => '\Google\Cloud\ServiceManagement\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'service_name', - 'fieldAccessors' => [ - 'getServiceName', - ], - ], - ], - ], - 'CreateServiceConfig' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Api\Service', - 'headerParams' => [ - [ - 'keyName' => 'service_name', - 'fieldAccessors' => [ - 'getServiceName', - ], - ], - ], - ], - 'GenerateConfigReport' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\ServiceManagement\V1\GenerateConfigReportResponse', - ], - 'GetService' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\ServiceManagement\V1\ManagedService', - 'headerParams' => [ - [ - 'keyName' => 'service_name', - 'fieldAccessors' => [ - 'getServiceName', - ], - ], - ], - ], - 'GetServiceConfig' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Api\Service', - 'headerParams' => [ - [ - 'keyName' => 'service_name', - 'fieldAccessors' => [ - 'getServiceName', - ], - ], - [ - 'keyName' => 'config_id', - 'fieldAccessors' => [ - 'getConfigId', - ], - ], - ], - ], - 'GetServiceRollout' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\ServiceManagement\V1\Rollout', - 'headerParams' => [ - [ - 'keyName' => 'service_name', - 'fieldAccessors' => [ - 'getServiceName', - ], - ], - [ - 'keyName' => 'rollout_id', - 'fieldAccessors' => [ - 'getRolloutId', - ], - ], - ], - ], - 'ListServiceConfigs' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getServiceConfigs', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\ServiceManagement\V1\ListServiceConfigsResponse', - 'headerParams' => [ - [ - 'keyName' => 'service_name', - 'fieldAccessors' => [ - 'getServiceName', - ], - ], - ], - ], - 'ListServiceRollouts' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getRollouts', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\ServiceManagement\V1\ListServiceRolloutsResponse', - 'headerParams' => [ - [ - 'keyName' => 'service_name', - 'fieldAccessors' => [ - 'getServiceName', - ], - ], - ], - ], - 'ListServices' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getServices', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\ServiceManagement\V1\ListServicesResponse', - ], - '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', - ], - ], - ], -]; diff --git a/owl-bot-staging/ServiceManagement/v1/src/V1/resources/service_manager_rest_client_config.php b/owl-bot-staging/ServiceManagement/v1/src/V1/resources/service_manager_rest_client_config.php deleted file mode 100644 index 2265223866be..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/src/V1/resources/service_manager_rest_client_config.php +++ /dev/null @@ -1,240 +0,0 @@ - [ - 'google.api.servicemanagement.v1.ServiceManager' => [ - 'CreateService' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/services', - 'body' => 'service', - ], - 'CreateServiceConfig' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/services/{service_name}/configs', - 'body' => 'service_config', - 'placeholders' => [ - 'service_name' => [ - 'getters' => [ - 'getServiceName', - ], - ], - ], - ], - 'CreateServiceRollout' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/services/{service_name}/rollouts', - 'body' => 'rollout', - 'placeholders' => [ - 'service_name' => [ - 'getters' => [ - 'getServiceName', - ], - ], - ], - ], - 'DeleteService' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/services/{service_name}', - 'placeholders' => [ - 'service_name' => [ - 'getters' => [ - 'getServiceName', - ], - ], - ], - ], - 'GenerateConfigReport' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/services:generateConfigReport', - 'body' => '*', - ], - 'GetService' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/services/{service_name}', - 'placeholders' => [ - 'service_name' => [ - 'getters' => [ - 'getServiceName', - ], - ], - ], - ], - 'GetServiceConfig' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/services/{service_name}/configs/{config_id}', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v1/services/{service_name}/config', - ], - ], - 'placeholders' => [ - 'config_id' => [ - 'getters' => [ - 'getConfigId', - ], - ], - 'service_name' => [ - 'getters' => [ - 'getServiceName', - ], - ], - ], - ], - 'GetServiceRollout' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/services/{service_name}/rollouts/{rollout_id}', - 'placeholders' => [ - 'rollout_id' => [ - 'getters' => [ - 'getRolloutId', - ], - ], - 'service_name' => [ - 'getters' => [ - 'getServiceName', - ], - ], - ], - ], - 'ListServiceConfigs' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/services/{service_name}/configs', - 'placeholders' => [ - 'service_name' => [ - 'getters' => [ - 'getServiceName', - ], - ], - ], - ], - 'ListServiceRollouts' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/services/{service_name}/rollouts', - 'placeholders' => [ - 'service_name' => [ - 'getters' => [ - 'getServiceName', - ], - ], - ], - 'queryParams' => [ - 'filter', - ], - ], - 'ListServices' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/services', - ], - 'SubmitConfigSource' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/services/{service_name}/configs:submit', - 'body' => '*', - 'placeholders' => [ - 'service_name' => [ - 'getters' => [ - 'getServiceName', - ], - ], - ], - ], - 'UndeleteService' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/services/{service_name}:undelete', - 'placeholders' => [ - 'service_name' => [ - 'getters' => [ - 'getServiceName', - ], - ], - ], - ], - ], - 'google.iam.v1.IAMPolicy' => [ - 'GetIamPolicy' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=services/*}:getIamPolicy', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=services/*/consumers/*}:getIamPolicy', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'SetIamPolicy' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=services/*}:setIamPolicy', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=services/*/consumers/*}:setIamPolicy', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'TestIamPermissions' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=services/*}:testIamPermissions', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=services/*/consumers/*}:testIamPermissions', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - ], - 'google.longrunning.Operations' => [ - 'ListOperations' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/operations', - ], - ], - ], - 'numericEnums' => true, -]; diff --git a/owl-bot-staging/ServiceManagement/v1/tests/Unit/V1/Client/ServiceManagerClientTest.php b/owl-bot-staging/ServiceManagement/v1/tests/Unit/V1/Client/ServiceManagerClientTest.php deleted file mode 100644 index 87e7797273e9..000000000000 --- a/owl-bot-staging/ServiceManagement/v1/tests/Unit/V1/Client/ServiceManagerClientTest.php +++ /dev/null @@ -1,1566 +0,0 @@ -getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); - } - - /** @return ServiceManagerClient */ - private function createClient(array $options = []) - { - $options += [ - 'credentials' => $this->createCredentials(), - ]; - return new ServiceManagerClient($options); - } - - /** @test */ - public function createServiceTest() - { - $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/createServiceTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $serviceName = 'serviceName359880149'; - $producerProjectId = 'producerProjectId1450187470'; - $expectedResponse = new ManagedService(); - $expectedResponse->setServiceName($serviceName); - $expectedResponse->setProducerProjectId($producerProjectId); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createServiceTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $service = new ManagedService(); - $request = (new CreateServiceRequest()) - ->setService($service); - $response = $gapicClient->createService($request); - $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.servicemanagement.v1.ServiceManager/CreateService', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getService(); - $this->assertProtobufEquals($service, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createServiceTest'); - $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 createServiceExceptionTest() - { - $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/createServiceTest'); - $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 - $service = new ManagedService(); - $request = (new CreateServiceRequest()) - ->setService($service); - $response = $gapicClient->createService($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createServiceTest'); - 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 createServiceConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $title = 'title110371416'; - $producerProjectId = 'producerProjectId1450187470'; - $id = 'id3355'; - $expectedResponse = new Service(); - $expectedResponse->setName($name); - $expectedResponse->setTitle($title); - $expectedResponse->setProducerProjectId($producerProjectId); - $expectedResponse->setId($id); - $transport->addResponse($expectedResponse); - // Mock request - $serviceName = 'serviceName359880149'; - $serviceConfig = new Service(); - $request = (new CreateServiceConfigRequest()) - ->setServiceName($serviceName) - ->setServiceConfig($serviceConfig); - $response = $gapicClient->createServiceConfig($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.api.servicemanagement.v1.ServiceManager/CreateServiceConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getServiceName(); - $this->assertProtobufEquals($serviceName, $actualValue); - $actualValue = $actualRequestObject->getServiceConfig(); - $this->assertProtobufEquals($serviceConfig, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createServiceConfigExceptionTest() - { - $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 - $serviceName = 'serviceName359880149'; - $serviceConfig = new Service(); - $request = (new CreateServiceConfigRequest()) - ->setServiceName($serviceName) - ->setServiceConfig($serviceConfig); - try { - $gapicClient->createServiceConfig($request); - // 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 createServiceRolloutTest() - { - $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/createServiceRolloutTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $rolloutId = 'rolloutId-91142551'; - $createdBy = 'createdBy1369680142'; - $serviceName2 = 'serviceName2-2047524792'; - $expectedResponse = new Rollout(); - $expectedResponse->setRolloutId($rolloutId); - $expectedResponse->setCreatedBy($createdBy); - $expectedResponse->setServiceName($serviceName2); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createServiceRolloutTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $serviceName = 'serviceName359880149'; - $rollout = new Rollout(); - $request = (new CreateServiceRolloutRequest()) - ->setServiceName($serviceName) - ->setRollout($rollout); - $response = $gapicClient->createServiceRollout($request); - $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.servicemanagement.v1.ServiceManager/CreateServiceRollout', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getServiceName(); - $this->assertProtobufEquals($serviceName, $actualValue); - $actualValue = $actualApiRequestObject->getRollout(); - $this->assertProtobufEquals($rollout, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createServiceRolloutTest'); - $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 createServiceRolloutExceptionTest() - { - $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/createServiceRolloutTest'); - $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 - $serviceName = 'serviceName359880149'; - $rollout = new Rollout(); - $request = (new CreateServiceRolloutRequest()) - ->setServiceName($serviceName) - ->setRollout($rollout); - $response = $gapicClient->createServiceRollout($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createServiceRolloutTest'); - 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 deleteServiceTest() - { - $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/deleteServiceTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteServiceTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $serviceName = 'serviceName359880149'; - $request = (new DeleteServiceRequest()) - ->setServiceName($serviceName); - $response = $gapicClient->deleteService($request); - $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.servicemanagement.v1.ServiceManager/DeleteService', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getServiceName(); - $this->assertProtobufEquals($serviceName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteServiceTest'); - $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 deleteServiceExceptionTest() - { - $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/deleteServiceTest'); - $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 - $serviceName = 'serviceName359880149'; - $request = (new DeleteServiceRequest()) - ->setServiceName($serviceName); - $response = $gapicClient->deleteService($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteServiceTest'); - 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 generateConfigReportTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $serviceName = 'serviceName359880149'; - $id = 'id3355'; - $expectedResponse = new GenerateConfigReportResponse(); - $expectedResponse->setServiceName($serviceName); - $expectedResponse->setId($id); - $transport->addResponse($expectedResponse); - // Mock request - $newConfig = new Any(); - $request = (new GenerateConfigReportRequest()) - ->setNewConfig($newConfig); - $response = $gapicClient->generateConfigReport($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.api.servicemanagement.v1.ServiceManager/GenerateConfigReport', $actualFuncCall); - $actualValue = $actualRequestObject->getNewConfig(); - $this->assertProtobufEquals($newConfig, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function generateConfigReportExceptionTest() - { - $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 - $newConfig = new Any(); - $request = (new GenerateConfigReportRequest()) - ->setNewConfig($newConfig); - try { - $gapicClient->generateConfigReport($request); - // 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 getServiceTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $serviceName2 = 'serviceName2-2047524792'; - $producerProjectId = 'producerProjectId1450187470'; - $expectedResponse = new ManagedService(); - $expectedResponse->setServiceName($serviceName2); - $expectedResponse->setProducerProjectId($producerProjectId); - $transport->addResponse($expectedResponse); - // Mock request - $serviceName = 'serviceName359880149'; - $request = (new GetServiceRequest()) - ->setServiceName($serviceName); - $response = $gapicClient->getService($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.api.servicemanagement.v1.ServiceManager/GetService', $actualFuncCall); - $actualValue = $actualRequestObject->getServiceName(); - $this->assertProtobufEquals($serviceName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getServiceExceptionTest() - { - $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 - $serviceName = 'serviceName359880149'; - $request = (new GetServiceRequest()) - ->setServiceName($serviceName); - try { - $gapicClient->getService($request); - // 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 getServiceConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $title = 'title110371416'; - $producerProjectId = 'producerProjectId1450187470'; - $id = 'id3355'; - $expectedResponse = new Service(); - $expectedResponse->setName($name); - $expectedResponse->setTitle($title); - $expectedResponse->setProducerProjectId($producerProjectId); - $expectedResponse->setId($id); - $transport->addResponse($expectedResponse); - // Mock request - $serviceName = 'serviceName359880149'; - $configId = 'configId-804450504'; - $request = (new GetServiceConfigRequest()) - ->setServiceName($serviceName) - ->setConfigId($configId); - $response = $gapicClient->getServiceConfig($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.api.servicemanagement.v1.ServiceManager/GetServiceConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getServiceName(); - $this->assertProtobufEquals($serviceName, $actualValue); - $actualValue = $actualRequestObject->getConfigId(); - $this->assertProtobufEquals($configId, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getServiceConfigExceptionTest() - { - $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 - $serviceName = 'serviceName359880149'; - $configId = 'configId-804450504'; - $request = (new GetServiceConfigRequest()) - ->setServiceName($serviceName) - ->setConfigId($configId); - try { - $gapicClient->getServiceConfig($request); - // 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 getServiceRolloutTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $rolloutId2 = 'rolloutId2-1688642596'; - $createdBy = 'createdBy1369680142'; - $serviceName2 = 'serviceName2-2047524792'; - $expectedResponse = new Rollout(); - $expectedResponse->setRolloutId($rolloutId2); - $expectedResponse->setCreatedBy($createdBy); - $expectedResponse->setServiceName($serviceName2); - $transport->addResponse($expectedResponse); - // Mock request - $serviceName = 'serviceName359880149'; - $rolloutId = 'rolloutId-91142551'; - $request = (new GetServiceRolloutRequest()) - ->setServiceName($serviceName) - ->setRolloutId($rolloutId); - $response = $gapicClient->getServiceRollout($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.api.servicemanagement.v1.ServiceManager/GetServiceRollout', $actualFuncCall); - $actualValue = $actualRequestObject->getServiceName(); - $this->assertProtobufEquals($serviceName, $actualValue); - $actualValue = $actualRequestObject->getRolloutId(); - $this->assertProtobufEquals($rolloutId, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getServiceRolloutExceptionTest() - { - $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 - $serviceName = 'serviceName359880149'; - $rolloutId = 'rolloutId-91142551'; - $request = (new GetServiceRolloutRequest()) - ->setServiceName($serviceName) - ->setRolloutId($rolloutId); - try { - $gapicClient->getServiceRollout($request); - // 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 listServiceConfigsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $serviceConfigsElement = new Service(); - $serviceConfigs = [ - $serviceConfigsElement, - ]; - $expectedResponse = new ListServiceConfigsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setServiceConfigs($serviceConfigs); - $transport->addResponse($expectedResponse); - // Mock request - $serviceName = 'serviceName359880149'; - $request = (new ListServiceConfigsRequest()) - ->setServiceName($serviceName); - $response = $gapicClient->listServiceConfigs($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getServiceConfigs()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.api.servicemanagement.v1.ServiceManager/ListServiceConfigs', $actualFuncCall); - $actualValue = $actualRequestObject->getServiceName(); - $this->assertProtobufEquals($serviceName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listServiceConfigsExceptionTest() - { - $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 - $serviceName = 'serviceName359880149'; - $request = (new ListServiceConfigsRequest()) - ->setServiceName($serviceName); - try { - $gapicClient->listServiceConfigs($request); - // 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 listServiceRolloutsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $rolloutsElement = new Rollout(); - $rollouts = [ - $rolloutsElement, - ]; - $expectedResponse = new ListServiceRolloutsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setRollouts($rollouts); - $transport->addResponse($expectedResponse); - // Mock request - $serviceName = 'serviceName359880149'; - $filter = 'filter-1274492040'; - $request = (new ListServiceRolloutsRequest()) - ->setServiceName($serviceName) - ->setFilter($filter); - $response = $gapicClient->listServiceRollouts($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getRollouts()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.api.servicemanagement.v1.ServiceManager/ListServiceRollouts', $actualFuncCall); - $actualValue = $actualRequestObject->getServiceName(); - $this->assertProtobufEquals($serviceName, $actualValue); - $actualValue = $actualRequestObject->getFilter(); - $this->assertProtobufEquals($filter, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listServiceRolloutsExceptionTest() - { - $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 - $serviceName = 'serviceName359880149'; - $filter = 'filter-1274492040'; - $request = (new ListServiceRolloutsRequest()) - ->setServiceName($serviceName) - ->setFilter($filter); - try { - $gapicClient->listServiceRollouts($request); - // 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 listServicesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $servicesElement = new ManagedService(); - $services = [ - $servicesElement, - ]; - $expectedResponse = new ListServicesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setServices($services); - $transport->addResponse($expectedResponse); - $request = new ListServicesRequest(); - $response = $gapicClient->listServices($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getServices()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.api.servicemanagement.v1.ServiceManager/ListServices', $actualFuncCall); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listServicesExceptionTest() - { - $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); - $request = new ListServicesRequest(); - try { - $gapicClient->listServices($request); - // 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 submitConfigSourceTest() - { - $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/submitConfigSourceTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new SubmitConfigSourceResponse(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/submitConfigSourceTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $serviceName = 'serviceName359880149'; - $configSource = new ConfigSource(); - $request = (new SubmitConfigSourceRequest()) - ->setServiceName($serviceName) - ->setConfigSource($configSource); - $response = $gapicClient->submitConfigSource($request); - $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.servicemanagement.v1.ServiceManager/SubmitConfigSource', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getServiceName(); - $this->assertProtobufEquals($serviceName, $actualValue); - $actualValue = $actualApiRequestObject->getConfigSource(); - $this->assertProtobufEquals($configSource, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/submitConfigSourceTest'); - $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 submitConfigSourceExceptionTest() - { - $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/submitConfigSourceTest'); - $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 - $serviceName = 'serviceName359880149'; - $configSource = new ConfigSource(); - $request = (new SubmitConfigSourceRequest()) - ->setServiceName($serviceName) - ->setConfigSource($configSource); - $response = $gapicClient->submitConfigSource($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/submitConfigSourceTest'); - 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 undeleteServiceTest() - { - $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/undeleteServiceTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new UndeleteServiceResponse(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/undeleteServiceTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $serviceName = 'serviceName359880149'; - $request = (new UndeleteServiceRequest()) - ->setServiceName($serviceName); - $response = $gapicClient->undeleteService($request); - $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.servicemanagement.v1.ServiceManager/UndeleteService', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getServiceName(); - $this->assertProtobufEquals($serviceName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/undeleteServiceTest'); - $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 undeleteServiceExceptionTest() - { - $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/undeleteServiceTest'); - $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 - $serviceName = 'serviceName359880149'; - $request = (new UndeleteServiceRequest()) - ->setServiceName($serviceName); - $response = $gapicClient->undeleteService($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/undeleteServiceTest'); - 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'; - $request = (new GetIamPolicyRequest()) - ->setResource($resource); - $response = $gapicClient->getIamPolicy($request); - $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'; - $request = (new GetIamPolicyRequest()) - ->setResource($resource); - try { - $gapicClient->getIamPolicy($request); - // 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(); - $request = (new SetIamPolicyRequest()) - ->setResource($resource) - ->setPolicy($policy); - $response = $gapicClient->setIamPolicy($request); - $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(); - $request = (new SetIamPolicyRequest()) - ->setResource($resource) - ->setPolicy($policy); - try { - $gapicClient->setIamPolicy($request); - // 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 = []; - $request = (new TestIamPermissionsRequest()) - ->setResource($resource) - ->setPermissions($permissions); - $response = $gapicClient->testIamPermissions($request); - $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 = []; - $request = (new TestIamPermissionsRequest()) - ->setResource($resource) - ->setPermissions($permissions); - try { - $gapicClient->testIamPermissions($request); - // 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 createServiceAsyncTest() - { - $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/createServiceTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $serviceName = 'serviceName359880149'; - $producerProjectId = 'producerProjectId1450187470'; - $expectedResponse = new ManagedService(); - $expectedResponse->setServiceName($serviceName); - $expectedResponse->setProducerProjectId($producerProjectId); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createServiceTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $service = new ManagedService(); - $request = (new CreateServiceRequest()) - ->setService($service); - $response = $gapicClient->createServiceAsync($request)->wait(); - $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.servicemanagement.v1.ServiceManager/CreateService', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getService(); - $this->assertProtobufEquals($service, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createServiceTest'); - $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()); - } -} diff --git a/owl-bot-staging/Speech/v2/proto/src/GPBMetadata/Google/Cloud/Speech/V2/CloudSpeech.php b/owl-bot-staging/Speech/v2/proto/src/GPBMetadata/Google/Cloud/Speech/V2/CloudSpeech.php deleted file mode 100644 index 4d6500ad185b..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/GPBMetadata/Google/Cloud/Speech/V2/CloudSpeech.php +++ /dev/null @@ -1,34 +0,0 @@ -internalAddGeneratedFile( - "\x0A\xF1\xA5\x01\x0A)google/cloud/speech/v2/cloud_speech.proto\x12\x16google.cloud.speech.v2\x1A\x17google/api/client.proto\x1A\x1Fgoogle/api/field_behavior.proto\x1A\x1Bgoogle/api/field_info.proto\x1A\x19google/api/resource.proto\x1A#google/longrunning/operations.proto\x1A\x1Egoogle/protobuf/duration.proto\x1A google/protobuf/field_mask.proto\x1A\x1Fgoogle/protobuf/timestamp.proto\x1A\x17google/rpc/status.proto\"\xBE\x01\x0A\x17CreateRecognizerRequest\x12;\x0A\x0Arecognizer\x18\x01 \x01(\x0B2\".google.cloud.speech.v2.RecognizerB\x03\xE0A\x02\x12\x15\x0A\x0Dvalidate_only\x18\x02 \x01(\x08\x12\x15\x0A\x0Drecognizer_id\x18\x03 \x01(\x09\x128\x0A\x06parent\x18\x04 \x01(\x09B(\xE0A\x02\xFAA\"\x12 speech.googleapis.com/Recognizer\"\xE7\x0C\x0A\x11OperationMetadata\x12/\x0A\x0Bcreate_time\x18\x01 \x01(\x0B2\x1A.google.protobuf.Timestamp\x12/\x0A\x0Bupdate_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.Timestamp\x12\x10\x0A\x08resource\x18\x03 \x01(\x09\x12\x0E\x0A\x06method\x18\x04 \x01(\x09\x12<\x0A\x0Ckms_key_name\x18\x06 \x01(\x09B&\xFAA#\x0A!cloudkms.googleapis.com/CryptoKey\x12K\x0A\x14kms_key_version_name\x18\x07 \x01(\x09B-\xFAA*\x0A(cloudkms.googleapis.com/CryptoKeyVersion\x12P\x0A\x17batch_recognize_request\x18\x08 \x01(\x0B2-.google.cloud.speech.v2.BatchRecognizeRequestH\x00\x12T\x0A\x19create_recognizer_request\x18\x09 \x01(\x0B2/.google.cloud.speech.v2.CreateRecognizerRequestH\x00\x12T\x0A\x19update_recognizer_request\x18\x0A \x01(\x0B2/.google.cloud.speech.v2.UpdateRecognizerRequestH\x00\x12T\x0A\x19delete_recognizer_request\x18\x0B \x01(\x0B2/.google.cloud.speech.v2.DeleteRecognizerRequestH\x00\x12X\x0A\x1Bundelete_recognizer_request\x18\x0C \x01(\x0B21.google.cloud.speech.v2.UndeleteRecognizerRequestH\x00\x12W\x0A\x1Bcreate_custom_class_request\x18\x0D \x01(\x0B20.google.cloud.speech.v2.CreateCustomClassRequestH\x00\x12W\x0A\x1Bupdate_custom_class_request\x18\x0E \x01(\x0B20.google.cloud.speech.v2.UpdateCustomClassRequestH\x00\x12W\x0A\x1Bdelete_custom_class_request\x18\x0F \x01(\x0B20.google.cloud.speech.v2.DeleteCustomClassRequestH\x00\x12[\x0A\x1Dundelete_custom_class_request\x18\x10 \x01(\x0B22.google.cloud.speech.v2.UndeleteCustomClassRequestH\x00\x12S\x0A\x19create_phrase_set_request\x18\x11 \x01(\x0B2..google.cloud.speech.v2.CreatePhraseSetRequestH\x00\x12S\x0A\x19update_phrase_set_request\x18\x12 \x01(\x0B2..google.cloud.speech.v2.UpdatePhraseSetRequestH\x00\x12S\x0A\x19delete_phrase_set_request\x18\x13 \x01(\x0B2..google.cloud.speech.v2.DeletePhraseSetRequestH\x00\x12W\x0A\x1Bundelete_phrase_set_request\x18\x14 \x01(\x0B20.google.cloud.speech.v2.UndeletePhraseSetRequestH\x00\x12P\x0A\x15update_config_request\x18\x15 \x01(\x0B2+.google.cloud.speech.v2.UpdateConfigRequestB\x02\x18\x01H\x00\x12\x18\x0A\x10progress_percent\x18\x16 \x01(\x05\x12R\x0A\x18batch_recognize_metadata\x18\x17 \x01(\x0B2..google.cloud.speech.v2.BatchRecognizeMetadataH\x01B\x09\x0A\x07requestB\x0A\x0A\x08metadata\"\x90\x01\x0A\x16ListRecognizersRequest\x129\x0A\x06parent\x18\x01 \x01(\x09B)\xE0A\x02\xFAA#\x0A!locations.googleapis.com/Location\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\x12\x14\x0A\x0Cshow_deleted\x18\x04 \x01(\x08\"k\x0A\x17ListRecognizersResponse\x127\x0A\x0Brecognizers\x18\x01 \x03(\x0B2\".google.cloud.speech.v2.Recognizer\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\"N\x0A\x14GetRecognizerRequest\x126\x0A\x04name\x18\x01 \x01(\x09B(\xE0A\x02\xFAA\"\x0A speech.googleapis.com/Recognizer\"\x9E\x01\x0A\x17UpdateRecognizerRequest\x12;\x0A\x0Arecognizer\x18\x01 \x01(\x0B2\".google.cloud.speech.v2.RecognizerB\x03\xE0A\x02\x12/\x0A\x0Bupdate_mask\x18\x02 \x01(\x0B2\x1A.google.protobuf.FieldMask\x12\x15\x0A\x0Dvalidate_only\x18\x04 \x01(\x08\"\x8D\x01\x0A\x17DeleteRecognizerRequest\x126\x0A\x04name\x18\x01 \x01(\x09B(\xE0A\x02\xFAA\"\x0A speech.googleapis.com/Recognizer\x12\x15\x0A\x0Dvalidate_only\x18\x02 \x01(\x08\x12\x15\x0A\x0Dallow_missing\x18\x04 \x01(\x08\x12\x0C\x0A\x04etag\x18\x03 \x01(\x09\"x\x0A\x19UndeleteRecognizerRequest\x126\x0A\x04name\x18\x01 \x01(\x09B(\xE0A\x02\xFAA\"\x0A speech.googleapis.com/Recognizer\x12\x15\x0A\x0Dvalidate_only\x18\x03 \x01(\x08\x12\x0C\x0A\x04etag\x18\x04 \x01(\x09\"\xC5\x07\x0A\x0ARecognizer\x12\x14\x0A\x04name\x18\x01 \x01(\x09B\x06\xE0A\x03\xE0A\x08\x12\x10\x0A\x03uid\x18\x02 \x01(\x09B\x03\xE0A\x03\x12\x14\x0A\x0Cdisplay_name\x18\x03 \x01(\x09\x12\x14\x0A\x05model\x18\x04 \x01(\x09B\x05\x18\x01\xE0A\x01\x12\x1D\x0A\x0Elanguage_codes\x18\x11 \x03(\x09B\x05\x18\x01\xE0A\x01\x12M\x0A\x1Adefault_recognition_config\x18\x06 \x01(\x0B2).google.cloud.speech.v2.RecognitionConfig\x12H\x0A\x0Bannotations\x18\x07 \x03(\x0B23.google.cloud.speech.v2.Recognizer.AnnotationsEntry\x12<\x0A\x05state\x18\x08 \x01(\x0E2(.google.cloud.speech.v2.Recognizer.StateB\x03\xE0A\x03\x124\x0A\x0Bcreate_time\x18\x09 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x0A \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bdelete_time\x18\x0B \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bexpire_time\x18\x0E \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12\x11\x0A\x04etag\x18\x0C \x01(\x09B\x03\xE0A\x03\x12\x18\x0A\x0Breconciling\x18\x0D \x01(\x08B\x03\xE0A\x03\x12?\x0A\x0Ckms_key_name\x18\x0F \x01(\x09B)\xE0A\x03\xFAA#\x0A!cloudkms.googleapis.com/CryptoKey\x12N\x0A\x14kms_key_version_name\x18\x10 \x01(\x09B0\xE0A\x03\xFAA*\x0A(cloudkms.googleapis.com/CryptoKeyVersion\x1A2\x0A\x10AnnotationsEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12\x0D\x0A\x05value\x18\x02 \x01(\x09:\x028\x01\"7\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x0A\x0A\x06ACTIVE\x10\x02\x12\x0B\x0A\x07DELETED\x10\x04:j\xEAAg\x0A speech.googleapis.com/Recognizer\x12@projects/{project}/locations/{location}/recognizers/{recognizer}R\x01\x01\"\x1A\x0A\x18AutoDetectDecodingConfig\"\xF0\x02\x0A\x16ExplicitDecodingConfig\x12S\x0A\x08encoding\x18\x01 \x01(\x0E2<.google.cloud.speech.v2.ExplicitDecodingConfig.AudioEncodingB\x03\xE0A\x02\x12\x1E\x0A\x11sample_rate_hertz\x18\x02 \x01(\x05B\x03\xE0A\x01\x12 \x0A\x13audio_channel_count\x18\x03 \x01(\x05B\x03\xE0A\x01\"\xBE\x01\x0A\x0DAudioEncoding\x12\x1E\x0A\x1AAUDIO_ENCODING_UNSPECIFIED\x10\x00\x12\x0C\x0A\x08LINEAR16\x10\x01\x12\x09\x0A\x05MULAW\x10\x02\x12\x08\x0A\x04ALAW\x10\x03\x12\x07\x0A\x03AMR\x10\x04\x12\x0A\x0A\x06AMR_WB\x10\x05\x12\x08\x0A\x04FLAC\x10\x06\x12\x07\x0A\x03MP3\x10\x07\x12\x0C\x0A\x08OGG_OPUS\x10\x08\x12\x0D\x0A\x09WEBM_OPUS\x10\x09\x12\x0B\x0A\x07MP4_AAC\x10\x0A\x12\x0B\x0A\x07M4A_AAC\x10\x0B\x12\x0B\x0A\x07MOV_AAC\x10\x0C\"Z\x0A\x18SpeakerDiarizationConfig\x12\x1E\x0A\x11min_speaker_count\x18\x02 \x01(\x05B\x03\xE0A\x01\x12\x1E\x0A\x11max_speaker_count\x18\x03 \x01(\x05B\x03\xE0A\x01\"0\x0A\x12CustomPromptConfig\x12\x1A\x0A\x0Dcustom_prompt\x18\x01 \x01(\x09B\x03\xE0A\x01\"\xC7\x04\x0A\x13RecognitionFeatures\x12\x18\x0A\x10profanity_filter\x18\x01 \x01(\x08\x12 \x0A\x18enable_word_time_offsets\x18\x02 \x01(\x08\x12\x1E\x0A\x16enable_word_confidence\x18\x03 \x01(\x08\x12\$\x0A\x1Cenable_automatic_punctuation\x18\x04 \x01(\x08\x12!\x0A\x19enable_spoken_punctuation\x18\x0E \x01(\x08\x12\x1C\x0A\x14enable_spoken_emojis\x18\x0F \x01(\x08\x12X\x0A\x12multi_channel_mode\x18\x11 \x01(\x0E2<.google.cloud.speech.v2.RecognitionFeatures.MultiChannelMode\x12L\x0A\x12diarization_config\x18\x09 \x01(\x0B20.google.cloud.speech.v2.SpeakerDiarizationConfig\x12\x18\x0A\x10max_alternatives\x18\x10 \x01(\x05\x12M\x0A\x14custom_prompt_config\x18\x12 \x01(\x0B2*.google.cloud.speech.v2.CustomPromptConfigB\x03\xE0A\x01\"\\\x0A\x10MultiChannelMode\x12\"\x0A\x1EMULTI_CHANNEL_MODE_UNSPECIFIED\x10\x00\x12\$\x0A SEPARATE_RECOGNITION_PER_CHANNEL\x10\x01\"\xA3\x01\x0A\x17TranscriptNormalization\x12F\x0A\x07entries\x18\x01 \x03(\x0B25.google.cloud.speech.v2.TranscriptNormalization.Entry\x1A@\x0A\x05Entry\x12\x0E\x0A\x06search\x18\x01 \x01(\x09\x12\x0F\x0A\x07replace\x18\x02 \x01(\x09\x12\x16\x0A\x0Ecase_sensitive\x18\x03 \x01(\x08\"1\x0A\x11TranslationConfig\x12\x1C\x0A\x0Ftarget_language\x18\x01 \x01(\x09B\x03\xE0A\x02\"\xBF\x02\x0A\x10SpeechAdaptation\x12Q\x0A\x0Bphrase_sets\x18\x01 \x03(\x0B2<.google.cloud.speech.v2.SpeechAdaptation.AdaptationPhraseSet\x12;\x0A\x0Ecustom_classes\x18\x02 \x03(\x0B2#.google.cloud.speech.v2.CustomClass\x1A\x9A\x01\x0A\x13AdaptationPhraseSet\x12:\x0A\x0Aphrase_set\x18\x01 \x01(\x09B\$\xFAA!\x0A\x1Fspeech.googleapis.com/PhraseSetH\x00\x12>\x0A\x11inline_phrase_set\x18\x02 \x01(\x0B2!.google.cloud.speech.v2.PhraseSetH\x00B\x07\x0A\x05value\">\x0A\x0EDenoiserConfig\x12\x15\x0A\x0Ddenoise_audio\x18\x01 \x01(\x08\x12\x15\x0A\x0Dsnr_threshold\x18\x02 \x01(\x02\"\xE4\x04\x0A\x11RecognitionConfig\x12P\x0A\x14auto_decoding_config\x18\x07 \x01(\x0B20.google.cloud.speech.v2.AutoDetectDecodingConfigH\x00\x12R\x0A\x18explicit_decoding_config\x18\x08 \x01(\x0B2..google.cloud.speech.v2.ExplicitDecodingConfigH\x00\x12\x12\x0A\x05model\x18\x09 \x01(\x09B\x03\xE0A\x01\x12\x1B\x0A\x0Elanguage_codes\x18\x0A \x03(\x09B\x03\xE0A\x01\x12=\x0A\x08features\x18\x02 \x01(\x0B2+.google.cloud.speech.v2.RecognitionFeatures\x12<\x0A\x0Aadaptation\x18\x06 \x01(\x0B2(.google.cloud.speech.v2.SpeechAdaptation\x12V\x0A\x18transcript_normalization\x18\x0B \x01(\x0B2/.google.cloud.speech.v2.TranscriptNormalizationB\x03\xE0A\x01\x12J\x0A\x12translation_config\x18\x0F \x01(\x0B2).google.cloud.speech.v2.TranslationConfigB\x03\xE0A\x01\x12D\x0A\x0Fdenoiser_config\x18\x10 \x01(\x0B2&.google.cloud.speech.v2.DenoiserConfigB\x03\xE0A\x01B\x11\x0A\x0Fdecoding_config\"\xEE\x01\x0A\x10RecognizeRequest\x12<\x0A\x0Arecognizer\x18\x03 \x01(\x09B(\xE0A\x02\xFAA\"\x0A speech.googleapis.com/Recognizer\x129\x0A\x06config\x18\x01 \x01(\x0B2).google.cloud.speech.v2.RecognitionConfig\x12/\x0A\x0Bconfig_mask\x18\x08 \x01(\x0B2\x1A.google.protobuf.FieldMask\x12\x11\x0A\x07content\x18\x05 \x01(\x0CH\x00\x12\x0D\x0A\x03uri\x18\x06 \x01(\x09H\x00B\x0E\x0A\x0Caudio_source\"\x9D\x01\x0A\x1BRecognitionResponseMetadata\x12\x1C\x0A\x0Arequest_id\x18\x09 \x01(\x09B\x08\xE2\x8C\xCF\xD7\x08\x02\x08\x01\x128\x0A\x15total_billed_duration\x18\x06 \x01(\x0B2\x19.google.protobuf.Duration\x12\x1B\x0A\x06prompt\x18\x0A \x01(\x09B\x06\xE0A\x03\xE0A\x01H\x00\x88\x01\x01B\x09\x0A\x07_prompt\"w\x0A\x1CSpeechRecognitionAlternative\x12\x12\x0A\x0Atranscript\x18\x01 \x01(\x09\x12\x12\x0A\x0Aconfidence\x18\x02 \x01(\x02\x12/\x0A\x05words\x18\x03 \x03(\x0B2 .google.cloud.speech.v2.WordInfo\"\xA3\x01\x0A\x08WordInfo\x12/\x0A\x0Cstart_offset\x18\x01 \x01(\x0B2\x19.google.protobuf.Duration\x12-\x0A\x0Aend_offset\x18\x02 \x01(\x0B2\x19.google.protobuf.Duration\x12\x0C\x0A\x04word\x18\x03 \x01(\x09\x12\x12\x0A\x0Aconfidence\x18\x04 \x01(\x02\x12\x15\x0A\x0Dspeaker_label\x18\x06 \x01(\x09\"\xCC\x01\x0A\x17SpeechRecognitionResult\x12J\x0A\x0Calternatives\x18\x01 \x03(\x0B24.google.cloud.speech.v2.SpeechRecognitionAlternative\x12\x13\x0A\x0Bchannel_tag\x18\x02 \x01(\x05\x124\x0A\x11result_end_offset\x18\x04 \x01(\x0B2\x19.google.protobuf.Duration\x12\x1A\x0A\x0Dlanguage_code\x18\x05 \x01(\x09B\x03\xE0A\x03\"\x9C\x01\x0A\x11RecognizeResponse\x12@\x0A\x07results\x18\x03 \x03(\x0B2/.google.cloud.speech.v2.SpeechRecognitionResult\x12E\x0A\x08metadata\x18\x02 \x01(\x0B23.google.cloud.speech.v2.RecognitionResponseMetadata\"\xF9\x04\x0A\x1CStreamingRecognitionFeatures\x12\$\x0A\x1Cenable_voice_activity_events\x18\x01 \x01(\x08\x12\x17\x0A\x0Finterim_results\x18\x02 \x01(\x08\x12i\x0A\x16voice_activity_timeout\x18\x03 \x01(\x0B2I.google.cloud.speech.v2.StreamingRecognitionFeatures.VoiceActivityTimeout\x12q\x0A\x17endpointing_sensitivity\x18\x08 \x01(\x0E2K.google.cloud.speech.v2.StreamingRecognitionFeatures.EndpointingSensitivityB\x03\xE0A\x01\x1A\x86\x01\x0A\x14VoiceActivityTimeout\x127\x0A\x14speech_start_timeout\x18\x01 \x01(\x0B2\x19.google.protobuf.Duration\x125\x0A\x12speech_end_timeout\x18\x02 \x01(\x0B2\x19.google.protobuf.Duration\"\xB2\x01\x0A\x16EndpointingSensitivity\x12'\x0A#ENDPOINTING_SENSITIVITY_UNSPECIFIED\x10\x00\x12\$\x0A ENDPOINTING_SENSITIVITY_STANDARD\x10\x01\x12&\x0A\"ENDPOINTING_SENSITIVITY_SUPERSHORT\x10\x02\x12!\x0A\x1DENDPOINTING_SENSITIVITY_SHORT\x10\x03\"\xDF\x01\x0A\x1AStreamingRecognitionConfig\x12>\x0A\x06config\x18\x01 \x01(\x0B2).google.cloud.speech.v2.RecognitionConfigB\x03\xE0A\x02\x12/\x0A\x0Bconfig_mask\x18\x03 \x01(\x0B2\x1A.google.protobuf.FieldMask\x12P\x0A\x12streaming_features\x18\x02 \x01(\x0B24.google.cloud.speech.v2.StreamingRecognitionFeatures\"\xCF\x01\x0A\x19StreamingRecognizeRequest\x12<\x0A\x0Arecognizer\x18\x03 \x01(\x09B(\xE0A\x02\xFAA\"\x0A speech.googleapis.com/Recognizer\x12N\x0A\x10streaming_config\x18\x06 \x01(\x0B22.google.cloud.speech.v2.StreamingRecognitionConfigH\x00\x12\x0F\x0A\x05audio\x18\x05 \x01(\x0CH\x00B\x13\x0A\x11streaming_request\"\x88\x04\x0A\x15BatchRecognizeRequest\x12<\x0A\x0Arecognizer\x18\x01 \x01(\x09B(\xE0A\x02\xFAA\"\x0A speech.googleapis.com/Recognizer\x129\x0A\x06config\x18\x04 \x01(\x0B2).google.cloud.speech.v2.RecognitionConfig\x12/\x0A\x0Bconfig_mask\x18\x05 \x01(\x0B2\x1A.google.protobuf.FieldMask\x12A\x0A\x05files\x18\x03 \x03(\x0B22.google.cloud.speech.v2.BatchRecognizeFileMetadata\x12R\x0A\x19recognition_output_config\x18\x06 \x01(\x0B2/.google.cloud.speech.v2.RecognitionOutputConfig\x12]\x0A\x13processing_strategy\x18\x07 \x01(\x0E2@.google.cloud.speech.v2.BatchRecognizeRequest.ProcessingStrategy\"O\x0A\x12ProcessingStrategy\x12#\x0A\x1FPROCESSING_STRATEGY_UNSPECIFIED\x10\x00\x12\x14\x0A\x10DYNAMIC_BATCHING\x10\x01\"\x1E\x0A\x0FGcsOutputConfig\x12\x0B\x0A\x03uri\x18\x01 \x01(\x09\"\x14\x0A\x12InlineOutputConfig\"\x1E\x0A\x1CNativeOutputFileFormatConfig\"\x1B\x0A\x19VttOutputFileFormatConfig\"\x1B\x0A\x19SrtOutputFileFormatConfig\"\xDA\x01\x0A\x12OutputFormatConfig\x12D\x0A\x06native\x18\x01 \x01(\x0B24.google.cloud.speech.v2.NativeOutputFileFormatConfig\x12>\x0A\x03vtt\x18\x02 \x01(\x0B21.google.cloud.speech.v2.VttOutputFileFormatConfig\x12>\x0A\x03srt\x18\x03 \x01(\x0B21.google.cloud.speech.v2.SrtOutputFileFormatConfig\"\x86\x02\x0A\x17RecognitionOutputConfig\x12D\x0A\x11gcs_output_config\x18\x01 \x01(\x0B2'.google.cloud.speech.v2.GcsOutputConfigH\x00\x12L\x0A\x16inline_response_config\x18\x02 \x01(\x0B2*.google.cloud.speech.v2.InlineOutputConfigH\x00\x12M\x0A\x14output_format_config\x18\x03 \x01(\x0B2*.google.cloud.speech.v2.OutputFormatConfigB\x03\xE0A\x01B\x08\x0A\x06output\"\x82\x02\x0A\x16BatchRecognizeResponse\x12L\x0A\x07results\x18\x01 \x03(\x0B2;.google.cloud.speech.v2.BatchRecognizeResponse.ResultsEntry\x128\x0A\x15total_billed_duration\x18\x02 \x01(\x0B2\x19.google.protobuf.Duration\x1A`\x0A\x0CResultsEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12?\x0A\x05value\x18\x02 \x01(\x0B20.google.cloud.speech.v2.BatchRecognizeFileResult:\x028\x01\"\xA0\x01\x0A\x15BatchRecognizeResults\x12@\x0A\x07results\x18\x01 \x03(\x0B2/.google.cloud.speech.v2.SpeechRecognitionResult\x12E\x0A\x08metadata\x18\x02 \x01(\x0B23.google.cloud.speech.v2.RecognitionResponseMetadata\"Q\x0A\x12CloudStorageResult\x12\x0B\x0A\x03uri\x18\x01 \x01(\x09\x12\x16\x0A\x0Evtt_format_uri\x18\x02 \x01(\x09\x12\x16\x0A\x0Esrt_format_uri\x18\x03 \x01(\x09\"}\x0A\x0CInlineResult\x12A\x0A\x0Atranscript\x18\x01 \x01(\x0B2-.google.cloud.speech.v2.BatchRecognizeResults\x12\x14\x0A\x0Cvtt_captions\x18\x02 \x01(\x09\x12\x14\x0A\x0Csrt_captions\x18\x03 \x01(\x09\"\xF1\x02\x0A\x18BatchRecognizeFileResult\x12!\x0A\x05error\x18\x02 \x01(\x0B2\x12.google.rpc.Status\x12E\x0A\x08metadata\x18\x03 \x01(\x0B23.google.cloud.speech.v2.RecognitionResponseMetadata\x12J\x0A\x14cloud_storage_result\x18\x05 \x01(\x0B2*.google.cloud.speech.v2.CloudStorageResultH\x00\x12=\x0A\x0Dinline_result\x18\x06 \x01(\x0B2\$.google.cloud.speech.v2.InlineResultH\x00\x12\x0F\x0A\x03uri\x18\x01 \x01(\x09B\x02\x18\x01\x12E\x0A\x0Atranscript\x18\x04 \x01(\x0B2-.google.cloud.speech.v2.BatchRecognizeResultsB\x02\x18\x01B\x08\x0A\x06result\"o\x0A#BatchRecognizeTranscriptionMetadata\x12\x18\x0A\x10progress_percent\x18\x01 \x01(\x05\x12!\x0A\x05error\x18\x02 \x01(\x0B2\x12.google.rpc.Status\x12\x0B\x0A\x03uri\x18\x03 \x01(\x09\"\xFE\x01\x0A\x16BatchRecognizeMetadata\x12i\x0A\x16transcription_metadata\x18\x01 \x03(\x0B2I.google.cloud.speech.v2.BatchRecognizeMetadata.TranscriptionMetadataEntry\x1Ay\x0A\x1ATranscriptionMetadataEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12J\x0A\x05value\x18\x02 \x01(\x0B2;.google.cloud.speech.v2.BatchRecognizeTranscriptionMetadata:\x028\x01\"\xA7\x01\x0A\x1ABatchRecognizeFileMetadata\x12\x0D\x0A\x03uri\x18\x01 \x01(\x09H\x00\x129\x0A\x06config\x18\x04 \x01(\x0B2).google.cloud.speech.v2.RecognitionConfig\x12/\x0A\x0Bconfig_mask\x18\x05 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x0E\x0A\x0Caudio_source\"\xF4\x01\x0A\x1AStreamingRecognitionResult\x12J\x0A\x0Calternatives\x18\x01 \x03(\x0B24.google.cloud.speech.v2.SpeechRecognitionAlternative\x12\x10\x0A\x08is_final\x18\x02 \x01(\x08\x12\x11\x0A\x09stability\x18\x03 \x01(\x02\x124\x0A\x11result_end_offset\x18\x04 \x01(\x0B2\x19.google.protobuf.Duration\x12\x13\x0A\x0Bchannel_tag\x18\x05 \x01(\x05\x12\x1A\x0A\x0Dlanguage_code\x18\x06 \x01(\x09B\x03\xE0A\x03\"\xC7\x03\x0A\x1AStreamingRecognizeResponse\x12C\x0A\x07results\x18\x06 \x03(\x0B22.google.cloud.speech.v2.StreamingRecognitionResult\x12]\x0A\x11speech_event_type\x18\x03 \x01(\x0E2B.google.cloud.speech.v2.StreamingRecognizeResponse.SpeechEventType\x126\x0A\x13speech_event_offset\x18\x07 \x01(\x0B2\x19.google.protobuf.Duration\x12E\x0A\x08metadata\x18\x05 \x01(\x0B23.google.cloud.speech.v2.RecognitionResponseMetadata\"\x85\x01\x0A\x0FSpeechEventType\x12!\x0A\x1DSPEECH_EVENT_TYPE_UNSPECIFIED\x10\x00\x12\x1B\x0A\x17END_OF_SINGLE_UTTERANCE\x10\x01\x12\x19\x0A\x15SPEECH_ACTIVITY_BEGIN\x10\x02\x12\x17\x0A\x13SPEECH_ACTIVITY_END\x10\x03\"\xE8\x01\x0A\x06Config\x12\x14\x0A\x04name\x18\x01 \x01(\x09B\x06\xE0A\x03\xE0A\x08\x12?\x0A\x0Ckms_key_name\x18\x02 \x01(\x09B)\xE0A\x01\xFAA#\x0A!cloudkms.googleapis.com/CryptoKey\x124\x0A\x0Bupdate_time\x18\x03 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03:Q\xEAAN\x0A\x1Cspeech.googleapis.com/Config\x12.projects/{project}/locations/{location}/config\"F\x0A\x10GetConfigRequest\x122\x0A\x04name\x18\x01 \x01(\x09B\$\xE0A\x02\xFAA\x1E\x0A\x1Cspeech.googleapis.com/Config\"{\x0A\x13UpdateConfigRequest\x123\x0A\x06config\x18\x01 \x01(\x0B2\x1E.google.cloud.speech.v2.ConfigB\x03\xE0A\x02\x12/\x0A\x0Bupdate_mask\x18\x02 \x01(\x0B2\x1A.google.protobuf.FieldMask\"\xAD\x07\x0A\x0BCustomClass\x12\x14\x0A\x04name\x18\x01 \x01(\x09B\x06\xE0A\x03\xE0A\x08\x12\x10\x0A\x03uid\x18\x02 \x01(\x09B\x03\xE0A\x03\x12\x19\x0A\x0Cdisplay_name\x18\x04 \x01(\x09B\x03\xE0A\x01\x12<\x0A\x05items\x18\x05 \x03(\x0B2-.google.cloud.speech.v2.CustomClass.ClassItem\x12=\x0A\x05state\x18\x0F \x01(\x0E2).google.cloud.speech.v2.CustomClass.StateB\x03\xE0A\x03\x124\x0A\x0Bcreate_time\x18\x06 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x07 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bdelete_time\x18\x08 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bexpire_time\x18\x09 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12N\x0A\x0Bannotations\x18\x0A \x03(\x0B24.google.cloud.speech.v2.CustomClass.AnnotationsEntryB\x03\xE0A\x01\x12\x11\x0A\x04etag\x18\x0B \x01(\x09B\x03\xE0A\x03\x12\x18\x0A\x0Breconciling\x18\x0C \x01(\x08B\x03\xE0A\x03\x12?\x0A\x0Ckms_key_name\x18\x0D \x01(\x09B)\xE0A\x03\xFAA#\x0A!cloudkms.googleapis.com/CryptoKey\x12N\x0A\x14kms_key_version_name\x18\x0E \x01(\x09B0\xE0A\x03\xFAA*\x0A(cloudkms.googleapis.com/CryptoKeyVersion\x1A\x1A\x0A\x09ClassItem\x12\x0D\x0A\x05value\x18\x01 \x01(\x09\x1A2\x0A\x10AnnotationsEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12\x0D\x0A\x05value\x18\x02 \x01(\x09:\x028\x01\"7\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x0A\x0A\x06ACTIVE\x10\x02\x12\x0B\x0A\x07DELETED\x10\x04:o\xEAAl\x0A!speech.googleapis.com/CustomClass\x12Dprojects/{project}/locations/{location}/customClasses/{custom_class}R\x01\x01\"\xAE\x07\x0A\x09PhraseSet\x12\x14\x0A\x04name\x18\x01 \x01(\x09B\x06\xE0A\x03\xE0A\x08\x12\x10\x0A\x03uid\x18\x02 \x01(\x09B\x03\xE0A\x03\x129\x0A\x07phrases\x18\x03 \x03(\x0B2(.google.cloud.speech.v2.PhraseSet.Phrase\x12\x0D\x0A\x05boost\x18\x04 \x01(\x02\x12\x14\x0A\x0Cdisplay_name\x18\x05 \x01(\x09\x12;\x0A\x05state\x18\x0F \x01(\x0E2'.google.cloud.speech.v2.PhraseSet.StateB\x03\xE0A\x03\x124\x0A\x0Bcreate_time\x18\x06 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x07 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bdelete_time\x18\x08 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bexpire_time\x18\x09 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12G\x0A\x0Bannotations\x18\x0A \x03(\x0B22.google.cloud.speech.v2.PhraseSet.AnnotationsEntry\x12\x11\x0A\x04etag\x18\x0B \x01(\x09B\x03\xE0A\x03\x12\x18\x0A\x0Breconciling\x18\x0C \x01(\x08B\x03\xE0A\x03\x12?\x0A\x0Ckms_key_name\x18\x0D \x01(\x09B)\xE0A\x03\xFAA#\x0A!cloudkms.googleapis.com/CryptoKey\x12N\x0A\x14kms_key_version_name\x18\x0E \x01(\x09B0\xE0A\x03\xFAA*\x0A(cloudkms.googleapis.com/CryptoKeyVersion\x1A&\x0A\x06Phrase\x12\x0D\x0A\x05value\x18\x01 \x01(\x09\x12\x0D\x0A\x05boost\x18\x02 \x01(\x02\x1A2\x0A\x10AnnotationsEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12\x0D\x0A\x05value\x18\x02 \x01(\x09:\x028\x01\"7\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x0A\x0A\x06ACTIVE\x10\x02\x12\x0B\x0A\x07DELETED\x10\x04:h\xEAAe\x0A\x1Fspeech.googleapis.com/PhraseSet\x12?projects/{project}/locations/{location}/phraseSets/{phrase_set}R\x01\x01\"\xC5\x01\x0A\x18CreateCustomClassRequest\x12>\x0A\x0Ccustom_class\x18\x01 \x01(\x0B2#.google.cloud.speech.v2.CustomClassB\x03\xE0A\x02\x12\x15\x0A\x0Dvalidate_only\x18\x02 \x01(\x08\x12\x17\x0A\x0Fcustom_class_id\x18\x03 \x01(\x09\x129\x0A\x06parent\x18\x04 \x01(\x09B)\xE0A\x02\xFAA#\x12!speech.googleapis.com/CustomClass\"\x92\x01\x0A\x18ListCustomClassesRequest\x129\x0A\x06parent\x18\x01 \x01(\x09B)\xE0A\x02\xFAA#\x0A!locations.googleapis.com/Location\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\x12\x14\x0A\x0Cshow_deleted\x18\x04 \x01(\x08\"q\x0A\x19ListCustomClassesResponse\x12;\x0A\x0Ecustom_classes\x18\x01 \x03(\x0B2#.google.cloud.speech.v2.CustomClass\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\"P\x0A\x15GetCustomClassRequest\x127\x0A\x04name\x18\x01 \x01(\x09B)\xE0A\x02\xFAA#\x0A!speech.googleapis.com/CustomClass\"\xA2\x01\x0A\x18UpdateCustomClassRequest\x12>\x0A\x0Ccustom_class\x18\x01 \x01(\x0B2#.google.cloud.speech.v2.CustomClassB\x03\xE0A\x02\x12/\x0A\x0Bupdate_mask\x18\x02 \x01(\x0B2\x1A.google.protobuf.FieldMask\x12\x15\x0A\x0Dvalidate_only\x18\x04 \x01(\x08\"\x8F\x01\x0A\x18DeleteCustomClassRequest\x127\x0A\x04name\x18\x01 \x01(\x09B)\xE0A\x02\xFAA#\x0A!speech.googleapis.com/CustomClass\x12\x15\x0A\x0Dvalidate_only\x18\x02 \x01(\x08\x12\x15\x0A\x0Dallow_missing\x18\x04 \x01(\x08\x12\x0C\x0A\x04etag\x18\x03 \x01(\x09\"z\x0A\x1AUndeleteCustomClassRequest\x127\x0A\x04name\x18\x01 \x01(\x09B)\xE0A\x02\xFAA#\x0A!speech.googleapis.com/CustomClass\x12\x15\x0A\x0Dvalidate_only\x18\x03 \x01(\x08\x12\x0C\x0A\x04etag\x18\x04 \x01(\x09\"\xBB\x01\x0A\x16CreatePhraseSetRequest\x12:\x0A\x0Aphrase_set\x18\x01 \x01(\x0B2!.google.cloud.speech.v2.PhraseSetB\x03\xE0A\x02\x12\x15\x0A\x0Dvalidate_only\x18\x02 \x01(\x08\x12\x15\x0A\x0Dphrase_set_id\x18\x03 \x01(\x09\x127\x0A\x06parent\x18\x04 \x01(\x09B'\xE0A\x02\xFAA!\x12\x1Fspeech.googleapis.com/PhraseSet\"\x8F\x01\x0A\x15ListPhraseSetsRequest\x129\x0A\x06parent\x18\x01 \x01(\x09B)\xE0A\x02\xFAA#\x0A!locations.googleapis.com/Location\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\x12\x14\x0A\x0Cshow_deleted\x18\x04 \x01(\x08\"i\x0A\x16ListPhraseSetsResponse\x126\x0A\x0Bphrase_sets\x18\x01 \x03(\x0B2!.google.cloud.speech.v2.PhraseSet\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\"L\x0A\x13GetPhraseSetRequest\x125\x0A\x04name\x18\x01 \x01(\x09B'\xE0A\x02\xFAA!\x0A\x1Fspeech.googleapis.com/PhraseSet\"\x9C\x01\x0A\x16UpdatePhraseSetRequest\x12:\x0A\x0Aphrase_set\x18\x01 \x01(\x0B2!.google.cloud.speech.v2.PhraseSetB\x03\xE0A\x02\x12/\x0A\x0Bupdate_mask\x18\x02 \x01(\x0B2\x1A.google.protobuf.FieldMask\x12\x15\x0A\x0Dvalidate_only\x18\x04 \x01(\x08\"\x8B\x01\x0A\x16DeletePhraseSetRequest\x125\x0A\x04name\x18\x01 \x01(\x09B'\xE0A\x02\xFAA!\x0A\x1Fspeech.googleapis.com/PhraseSet\x12\x15\x0A\x0Dvalidate_only\x18\x02 \x01(\x08\x12\x15\x0A\x0Dallow_missing\x18\x04 \x01(\x08\x12\x0C\x0A\x04etag\x18\x03 \x01(\x09\"v\x0A\x18UndeletePhraseSetRequest\x125\x0A\x04name\x18\x01 \x01(\x09B'\xE0A\x02\xFAA!\x0A\x1Fspeech.googleapis.com/PhraseSet\x12\x15\x0A\x0Dvalidate_only\x18\x03 \x01(\x08\x12\x0C\x0A\x04etag\x18\x04 \x01(\x092\xBF%\x0A\x06Speech\x12\xEC\x01\x0A\x10CreateRecognizer\x12/.google.cloud.speech.v2.CreateRecognizerRequest\x1A\x1D.google.longrunning.Operation\"\x87\x01\xCAA\x1F\x0A\x0ARecognizer\x12\x11OperationMetadata\xDAA\x1Fparent,recognizer,recognizer_id\x82\xD3\xE4\x93\x02=\"//v2/{parent=projects/*/locations/*}/recognizers:\x0Arecognizer\x12\xB4\x01\x0A\x0FListRecognizers\x12..google.cloud.speech.v2.ListRecognizersRequest\x1A/.google.cloud.speech.v2.ListRecognizersResponse\"@\xDAA\x06parent\x82\xD3\xE4\x93\x021\x12//v2/{parent=projects/*/locations/*}/recognizers\x12\xA1\x01\x0A\x0DGetRecognizer\x12,.google.cloud.speech.v2.GetRecognizerRequest\x1A\".google.cloud.speech.v2.Recognizer\">\xDAA\x04name\x82\xD3\xE4\x93\x021\x12//v2/{name=projects/*/locations/*/recognizers/*}\x12\xEE\x01\x0A\x10UpdateRecognizer\x12/.google.cloud.speech.v2.UpdateRecognizerRequest\x1A\x1D.google.longrunning.Operation\"\x89\x01\xCAA\x1F\x0A\x0ARecognizer\x12\x11OperationMetadata\xDAA\x16recognizer,update_mask\x82\xD3\xE4\x93\x02H2:/v2/{recognizer.name=projects/*/locations/*/recognizers/*}:\x0Arecognizer\x12\xC4\x01\x0A\x10DeleteRecognizer\x12/.google.cloud.speech.v2.DeleteRecognizerRequest\x1A\x1D.google.longrunning.Operation\"`\xCAA\x1F\x0A\x0ARecognizer\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x021*//v2/{name=projects/*/locations/*/recognizers/*}\x12\xD4\x01\x0A\x12UndeleteRecognizer\x121.google.cloud.speech.v2.UndeleteRecognizerRequest\x1A\x1D.google.longrunning.Operation\"l\xCAA\x1F\x0A\x0ARecognizer\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x02=\"8/v2/{name=projects/*/locations/*/recognizers/*}:undelete:\x01*\x12\xF9\x01\x0A\x09Recognize\x12(.google.cloud.speech.v2.RecognizeRequest\x1A).google.cloud.speech.v2.RecognizeResponse\"\x96\x01\xDAA%recognizer,config,config_mask,content\xDAA!recognizer,config,config_mask,uri\x82\xD3\xE4\x93\x02D\"?/v2/{recognizer=projects/*/locations/*/recognizers/*}:recognize:\x01*\x12\x81\x01\x0A\x12StreamingRecognize\x121.google.cloud.speech.v2.StreamingRecognizeRequest\x1A2.google.cloud.speech.v2.StreamingRecognizeResponse\"\x00(\x010\x01\x12\x84\x02\x0A\x0EBatchRecognize\x12-.google.cloud.speech.v2.BatchRecognizeRequest\x1A\x1D.google.longrunning.Operation\"\xA3\x01\xCAA+\x0A\x16BatchRecognizeResponse\x12\x11OperationMetadata\xDAA#recognizer,config,config_mask,files\x82\xD3\xE4\x93\x02I\"D/v2/{recognizer=projects/*/locations/*/recognizers/*}:batchRecognize:\x01*\x12\x8E\x01\x0A\x09GetConfig\x12(.google.cloud.speech.v2.GetConfigRequest\x1A\x1E.google.cloud.speech.v2.Config\"7\xDAA\x04name\x82\xD3\xE4\x93\x02*\x12(/v2/{name=projects/*/locations/*/config}\x12\xB1\x01\x0A\x0CUpdateConfig\x12+.google.cloud.speech.v2.UpdateConfigRequest\x1A\x1E.google.cloud.speech.v2.Config\"T\xDAA\x12config,update_mask\x82\xD3\xE4\x93\x0292//v2/{config.name=projects/*/locations/*/config}:\x06config\x12\xF7\x01\x0A\x11CreateCustomClass\x120.google.cloud.speech.v2.CreateCustomClassRequest\x1A\x1D.google.longrunning.Operation\"\x90\x01\xCAA \x0A\x0BCustomClass\x12\x11OperationMetadata\xDAA#parent,custom_class,custom_class_id\x82\xD3\xE4\x93\x02A\"1/v2/{parent=projects/*/locations/*}/customClasses:\x0Ccustom_class\x12\xBC\x01\x0A\x11ListCustomClasses\x120.google.cloud.speech.v2.ListCustomClassesRequest\x1A1.google.cloud.speech.v2.ListCustomClassesResponse\"B\xDAA\x06parent\x82\xD3\xE4\x93\x023\x121/v2/{parent=projects/*/locations/*}/customClasses\x12\xA6\x01\x0A\x0EGetCustomClass\x12-.google.cloud.speech.v2.GetCustomClassRequest\x1A#.google.cloud.speech.v2.CustomClass\"@\xDAA\x04name\x82\xD3\xE4\x93\x023\x121/v2/{name=projects/*/locations/*/customClasses/*}\x12\xF9\x01\x0A\x11UpdateCustomClass\x120.google.cloud.speech.v2.UpdateCustomClassRequest\x1A\x1D.google.longrunning.Operation\"\x92\x01\xCAA \x0A\x0BCustomClass\x12\x11OperationMetadata\xDAA\x18custom_class,update_mask\x82\xD3\xE4\x93\x02N2>/v2/{custom_class.name=projects/*/locations/*/customClasses/*}:\x0Ccustom_class\x12\xC9\x01\x0A\x11DeleteCustomClass\x120.google.cloud.speech.v2.DeleteCustomClassRequest\x1A\x1D.google.longrunning.Operation\"c\xCAA \x0A\x0BCustomClass\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x023*1/v2/{name=projects/*/locations/*/customClasses/*}\x12\xD9\x01\x0A\x13UndeleteCustomClass\x122.google.cloud.speech.v2.UndeleteCustomClassRequest\x1A\x1D.google.longrunning.Operation\"o\xCAA \x0A\x0BCustomClass\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x02?\":/v2/{name=projects/*/locations/*/customClasses/*}:undelete:\x01*\x12\xE8\x01\x0A\x0FCreatePhraseSet\x12..google.cloud.speech.v2.CreatePhraseSetRequest\x1A\x1D.google.longrunning.Operation\"\x85\x01\xCAA\x1E\x0A\x09PhraseSet\x12\x11OperationMetadata\xDAA\x1Fparent,phrase_set,phrase_set_id\x82\xD3\xE4\x93\x02<\"./v2/{parent=projects/*/locations/*}/phraseSets:\x0Aphrase_set\x12\xB0\x01\x0A\x0EListPhraseSets\x12-.google.cloud.speech.v2.ListPhraseSetsRequest\x1A..google.cloud.speech.v2.ListPhraseSetsResponse\"?\xDAA\x06parent\x82\xD3\xE4\x93\x020\x12./v2/{parent=projects/*/locations/*}/phraseSets\x12\x9D\x01\x0A\x0CGetPhraseSet\x12+.google.cloud.speech.v2.GetPhraseSetRequest\x1A!.google.cloud.speech.v2.PhraseSet\"=\xDAA\x04name\x82\xD3\xE4\x93\x020\x12./v2/{name=projects/*/locations/*/phraseSets/*}\x12\xEA\x01\x0A\x0FUpdatePhraseSet\x12..google.cloud.speech.v2.UpdatePhraseSetRequest\x1A\x1D.google.longrunning.Operation\"\x87\x01\xCAA\x1E\x0A\x09PhraseSet\x12\x11OperationMetadata\xDAA\x16phrase_set,update_mask\x82\xD3\xE4\x93\x02G29/v2/{phrase_set.name=projects/*/locations/*/phraseSets/*}:\x0Aphrase_set\x12\xC0\x01\x0A\x0FDeletePhraseSet\x12..google.cloud.speech.v2.DeletePhraseSetRequest\x1A\x1D.google.longrunning.Operation\"^\xCAA\x1E\x0A\x09PhraseSet\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x020*./v2/{name=projects/*/locations/*/phraseSets/*}\x12\xD0\x01\x0A\x11UndeletePhraseSet\x120.google.cloud.speech.v2.UndeletePhraseSetRequest\x1A\x1D.google.longrunning.Operation\"j\xCAA\x1E\x0A\x09PhraseSet\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x02<\"7/v2/{name=projects/*/locations/*/phraseSets/*}:undelete:\x01*\x1AI\xCAA\x15speech.googleapis.com\xD2A.https://www.googleapis.com/auth/cloud-platformB\x89\x03\x0A\x1Acom.google.cloud.speech.v2B\x10CloudSpeechProtoP\x01Z2cloud.google.com/go/speech/apiv2/speechpb;speechpb\xEAAx\x0A!cloudkms.googleapis.com/CryptoKey\x12Sprojects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}\xEAA\xA6\x01\x0A(cloudkms.googleapis.com/CryptoKeyVersion\x12zprojects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}/cryptoKeyVersions/{crypto_key_version}b\x06proto3" - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/GPBMetadata/Google/Cloud/Speech/V2/LocationsMetadata.php b/owl-bot-staging/Speech/v2/proto/src/GPBMetadata/Google/Cloud/Speech/V2/LocationsMetadata.php deleted file mode 100644 index 9c8963af8a3d..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/GPBMetadata/Google/Cloud/Speech/V2/LocationsMetadata.php +++ /dev/null @@ -1,24 +0,0 @@ -internalAddGeneratedFile( - "\x0A\x94\x08\x0A/google/cloud/speech/v2/locations_metadata.proto\x12\x16google.cloud.speech.v2\"6\x0A\x0CModelFeature\x12\x0F\x0A\x07feature\x18\x01 \x01(\x09\x12\x15\x0A\x0Drelease_state\x18\x02 \x01(\x09\"L\x0A\x0DModelFeatures\x12;\x0A\x0Dmodel_feature\x18\x01 \x03(\x0B2\$.google.cloud.speech.v2.ModelFeature\"\xBE\x01\x0A\x0DModelMetadata\x12P\x0A\x0Emodel_features\x18\x01 \x03(\x0B28.google.cloud.speech.v2.ModelMetadata.ModelFeaturesEntry\x1A[\x0A\x12ModelFeaturesEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x124\x0A\x05value\x18\x02 \x01(\x0B2%.google.cloud.speech.v2.ModelFeatures:\x028\x01\"\xAE\x01\x0A\x10LanguageMetadata\x12D\x0A\x06models\x18\x01 \x03(\x0B24.google.cloud.speech.v2.LanguageMetadata.ModelsEntry\x1AT\x0A\x0BModelsEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x124\x0A\x05value\x18\x02 \x01(\x0B2%.google.cloud.speech.v2.ModelMetadata:\x028\x01\"\xC8\x01\x0A\x0EAccessMetadata\x12N\x0A\x0Fconstraint_type\x18\x01 \x01(\x0E25.google.cloud.speech.v2.AccessMetadata.ConstraintType\"f\x0A\x0EConstraintType\x12\x1F\x0A\x1BCONSTRAINT_TYPE_UNSPECIFIED\x10\x00\x123\x0A/RESOURCE_LOCATIONS_ORG_POLICY_CREATE_CONSTRAINT\x10\x01\"\x91\x01\x0A\x11LocationsMetadata\x12;\x0A\x09languages\x18\x01 \x01(\x0B2(.google.cloud.speech.v2.LanguageMetadata\x12?\x0A\x0Faccess_metadata\x18\x02 \x01(\x0B2&.google.cloud.speech.v2.AccessMetadataBj\x0A\x1Acom.google.cloud.speech.v2B\x16LocationsMetadataProtoP\x01Z2cloud.google.com/go/speech/apiv2/speechpb;speechpbb\x06proto3" - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/AccessMetadata.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/AccessMetadata.php deleted file mode 100644 index c9bd403692d7..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/AccessMetadata.php +++ /dev/null @@ -1,68 +0,0 @@ -google.cloud.speech.v2.AccessMetadata - */ -class AccessMetadata extends \Google\Protobuf\Internal\Message -{ - /** - * Describes the different types of constraints that are applied. - * - * Generated from protobuf field .google.cloud.speech.v2.AccessMetadata.ConstraintType constraint_type = 1; - */ - protected $constraint_type = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $constraint_type - * Describes the different types of constraints that are applied. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\LocationsMetadata::initOnce(); - parent::__construct($data); - } - - /** - * Describes the different types of constraints that are applied. - * - * Generated from protobuf field .google.cloud.speech.v2.AccessMetadata.ConstraintType constraint_type = 1; - * @return int - */ - public function getConstraintType() - { - return $this->constraint_type; - } - - /** - * Describes the different types of constraints that are applied. - * - * Generated from protobuf field .google.cloud.speech.v2.AccessMetadata.ConstraintType constraint_type = 1; - * @param int $var - * @return $this - */ - public function setConstraintType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Speech\V2\AccessMetadata\ConstraintType::class); - $this->constraint_type = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/AccessMetadata/ConstraintType.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/AccessMetadata/ConstraintType.php deleted file mode 100644 index 6a80c5844629..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/AccessMetadata/ConstraintType.php +++ /dev/null @@ -1,55 +0,0 @@ -google.cloud.speech.v2.AccessMetadata.ConstraintType - */ -class ConstraintType -{ - /** - * Unspecified constraint applied. - * - * Generated from protobuf enum CONSTRAINT_TYPE_UNSPECIFIED = 0; - */ - const CONSTRAINT_TYPE_UNSPECIFIED = 0; - /** - * The project's org policy disallows the given region. - * - * Generated from protobuf enum RESOURCE_LOCATIONS_ORG_POLICY_CREATE_CONSTRAINT = 1; - */ - const RESOURCE_LOCATIONS_ORG_POLICY_CREATE_CONSTRAINT = 1; - - private static $valueToName = [ - self::CONSTRAINT_TYPE_UNSPECIFIED => 'CONSTRAINT_TYPE_UNSPECIFIED', - self::RESOURCE_LOCATIONS_ORG_POLICY_CREATE_CONSTRAINT => 'RESOURCE_LOCATIONS_ORG_POLICY_CREATE_CONSTRAINT', - ]; - - 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/Speech/v2/proto/src/Google/Cloud/Speech/V2/AutoDetectDecodingConfig.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/AutoDetectDecodingConfig.php deleted file mode 100644 index 9a3b7986454e..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/AutoDetectDecodingConfig.php +++ /dev/null @@ -1,46 +0,0 @@ -google.cloud.speech.v2.AutoDetectDecodingConfig - */ -class AutoDetectDecodingConfig extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeFileMetadata.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeFileMetadata.php deleted file mode 100644 index 88bd91f81ca1..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeFileMetadata.php +++ /dev/null @@ -1,239 +0,0 @@ -google.cloud.speech.v2.BatchRecognizeFileMetadata - */ -class BatchRecognizeFileMetadata extends \Google\Protobuf\Internal\Message -{ - /** - * Features and audio metadata to use for the Automatic Speech Recognition. - * This field in combination with the - * [config_mask][google.cloud.speech.v2.BatchRecognizeFileMetadata.config_mask] - * field can be used to override parts of the - * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] - * of the Recognizer resource as well as the - * [config][google.cloud.speech.v2.BatchRecognizeRequest.config] at the - * request level. - * - * Generated from protobuf field .google.cloud.speech.v2.RecognitionConfig config = 4; - */ - protected $config = null; - /** - * The list of fields in - * [config][google.cloud.speech.v2.BatchRecognizeFileMetadata.config] that - * override the values in the - * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] - * of the recognizer during this recognition request. If no mask is provided, - * all non-default valued fields in - * [config][google.cloud.speech.v2.BatchRecognizeFileMetadata.config] override - * the values in the recognizer for this recognition request. If a mask is - * provided, only the fields listed in the mask override the config in the - * recognizer for this recognition request. If a wildcard (`*`) is provided, - * [config][google.cloud.speech.v2.BatchRecognizeFileMetadata.config] - * completely overrides and replaces the config in the recognizer for this - * recognition request. - * - * Generated from protobuf field .google.protobuf.FieldMask config_mask = 5; - */ - protected $config_mask = null; - protected $audio_source; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $uri - * Cloud Storage URI for the audio file. - * @type \Google\Cloud\Speech\V2\RecognitionConfig $config - * Features and audio metadata to use for the Automatic Speech Recognition. - * This field in combination with the - * [config_mask][google.cloud.speech.v2.BatchRecognizeFileMetadata.config_mask] - * field can be used to override parts of the - * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] - * of the Recognizer resource as well as the - * [config][google.cloud.speech.v2.BatchRecognizeRequest.config] at the - * request level. - * @type \Google\Protobuf\FieldMask $config_mask - * The list of fields in - * [config][google.cloud.speech.v2.BatchRecognizeFileMetadata.config] that - * override the values in the - * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] - * of the recognizer during this recognition request. If no mask is provided, - * all non-default valued fields in - * [config][google.cloud.speech.v2.BatchRecognizeFileMetadata.config] override - * the values in the recognizer for this recognition request. If a mask is - * provided, only the fields listed in the mask override the config in the - * recognizer for this recognition request. If a wildcard (`*`) is provided, - * [config][google.cloud.speech.v2.BatchRecognizeFileMetadata.config] - * completely overrides and replaces the config in the recognizer for this - * recognition request. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Cloud Storage URI for the audio file. - * - * Generated from protobuf field string uri = 1; - * @return string - */ - public function getUri() - { - return $this->readOneof(1); - } - - public function hasUri() - { - return $this->hasOneof(1); - } - - /** - * Cloud Storage URI for the audio file. - * - * Generated from protobuf field string uri = 1; - * @param string $var - * @return $this - */ - public function setUri($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * Features and audio metadata to use for the Automatic Speech Recognition. - * This field in combination with the - * [config_mask][google.cloud.speech.v2.BatchRecognizeFileMetadata.config_mask] - * field can be used to override parts of the - * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] - * of the Recognizer resource as well as the - * [config][google.cloud.speech.v2.BatchRecognizeRequest.config] at the - * request level. - * - * Generated from protobuf field .google.cloud.speech.v2.RecognitionConfig config = 4; - * @return \Google\Cloud\Speech\V2\RecognitionConfig|null - */ - public function getConfig() - { - return $this->config; - } - - public function hasConfig() - { - return isset($this->config); - } - - public function clearConfig() - { - unset($this->config); - } - - /** - * Features and audio metadata to use for the Automatic Speech Recognition. - * This field in combination with the - * [config_mask][google.cloud.speech.v2.BatchRecognizeFileMetadata.config_mask] - * field can be used to override parts of the - * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] - * of the Recognizer resource as well as the - * [config][google.cloud.speech.v2.BatchRecognizeRequest.config] at the - * request level. - * - * Generated from protobuf field .google.cloud.speech.v2.RecognitionConfig config = 4; - * @param \Google\Cloud\Speech\V2\RecognitionConfig $var - * @return $this - */ - public function setConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\RecognitionConfig::class); - $this->config = $var; - - return $this; - } - - /** - * The list of fields in - * [config][google.cloud.speech.v2.BatchRecognizeFileMetadata.config] that - * override the values in the - * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] - * of the recognizer during this recognition request. If no mask is provided, - * all non-default valued fields in - * [config][google.cloud.speech.v2.BatchRecognizeFileMetadata.config] override - * the values in the recognizer for this recognition request. If a mask is - * provided, only the fields listed in the mask override the config in the - * recognizer for this recognition request. If a wildcard (`*`) is provided, - * [config][google.cloud.speech.v2.BatchRecognizeFileMetadata.config] - * completely overrides and replaces the config in the recognizer for this - * recognition request. - * - * Generated from protobuf field .google.protobuf.FieldMask config_mask = 5; - * @return \Google\Protobuf\FieldMask|null - */ - public function getConfigMask() - { - return $this->config_mask; - } - - public function hasConfigMask() - { - return isset($this->config_mask); - } - - public function clearConfigMask() - { - unset($this->config_mask); - } - - /** - * The list of fields in - * [config][google.cloud.speech.v2.BatchRecognizeFileMetadata.config] that - * override the values in the - * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] - * of the recognizer during this recognition request. If no mask is provided, - * all non-default valued fields in - * [config][google.cloud.speech.v2.BatchRecognizeFileMetadata.config] override - * the values in the recognizer for this recognition request. If a mask is - * provided, only the fields listed in the mask override the config in the - * recognizer for this recognition request. If a wildcard (`*`) is provided, - * [config][google.cloud.speech.v2.BatchRecognizeFileMetadata.config] - * completely overrides and replaces the config in the recognizer for this - * recognition request. - * - * Generated from protobuf field .google.protobuf.FieldMask config_mask = 5; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setConfigMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->config_mask = $var; - - return $this; - } - - /** - * @return string - */ - public function getAudioSource() - { - return $this->whichOneof("audio_source"); - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeFileResult.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeFileResult.php deleted file mode 100644 index 57c5452e8231..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeFileResult.php +++ /dev/null @@ -1,306 +0,0 @@ -google.cloud.speech.v2.BatchRecognizeFileResult - */ -class BatchRecognizeFileResult extends \Google\Protobuf\Internal\Message -{ - /** - * Error if one was encountered. - * - * Generated from protobuf field .google.rpc.Status error = 2; - */ - protected $error = null; - /** - * Generated from protobuf field .google.cloud.speech.v2.RecognitionResponseMetadata metadata = 3; - */ - protected $metadata = null; - /** - * Deprecated. Use `cloud_storage_result.native_format_uri` instead. - * - * Generated from protobuf field string uri = 1 [deprecated = true]; - * @deprecated - */ - protected $uri = ''; - /** - * Deprecated. Use `inline_result.transcript` instead. - * - * Generated from protobuf field .google.cloud.speech.v2.BatchRecognizeResults transcript = 4 [deprecated = true]; - * @deprecated - */ - protected $transcript = null; - protected $result; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Rpc\Status $error - * Error if one was encountered. - * @type \Google\Cloud\Speech\V2\RecognitionResponseMetadata $metadata - * @type \Google\Cloud\Speech\V2\CloudStorageResult $cloud_storage_result - * Recognition results written to Cloud Storage. This is - * populated only when - * [GcsOutputConfig][google.cloud.speech.v2.GcsOutputConfig] is set in - * the - * [RecognitionOutputConfig][[google.cloud.speech.v2.RecognitionOutputConfig]. - * @type \Google\Cloud\Speech\V2\InlineResult $inline_result - * Recognition results. This is populated only when - * [InlineOutputConfig][google.cloud.speech.v2.InlineOutputConfig] is set in - * the - * [RecognitionOutputConfig][[google.cloud.speech.v2.RecognitionOutputConfig]. - * @type string $uri - * Deprecated. Use `cloud_storage_result.native_format_uri` instead. - * @type \Google\Cloud\Speech\V2\BatchRecognizeResults $transcript - * Deprecated. Use `inline_result.transcript` instead. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Error if one was encountered. - * - * Generated from protobuf field .google.rpc.Status error = 2; - * @return \Google\Rpc\Status|null - */ - public function getError() - { - return $this->error; - } - - public function hasError() - { - return isset($this->error); - } - - public function clearError() - { - unset($this->error); - } - - /** - * Error if one was encountered. - * - * Generated from protobuf field .google.rpc.Status error = 2; - * @param \Google\Rpc\Status $var - * @return $this - */ - public function setError($var) - { - GPBUtil::checkMessage($var, \Google\Rpc\Status::class); - $this->error = $var; - - return $this; - } - - /** - * Generated from protobuf field .google.cloud.speech.v2.RecognitionResponseMetadata metadata = 3; - * @return \Google\Cloud\Speech\V2\RecognitionResponseMetadata|null - */ - public function getMetadata() - { - return $this->metadata; - } - - public function hasMetadata() - { - return isset($this->metadata); - } - - public function clearMetadata() - { - unset($this->metadata); - } - - /** - * Generated from protobuf field .google.cloud.speech.v2.RecognitionResponseMetadata metadata = 3; - * @param \Google\Cloud\Speech\V2\RecognitionResponseMetadata $var - * @return $this - */ - public function setMetadata($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\RecognitionResponseMetadata::class); - $this->metadata = $var; - - return $this; - } - - /** - * Recognition results written to Cloud Storage. This is - * populated only when - * [GcsOutputConfig][google.cloud.speech.v2.GcsOutputConfig] is set in - * the - * [RecognitionOutputConfig][[google.cloud.speech.v2.RecognitionOutputConfig]. - * - * Generated from protobuf field .google.cloud.speech.v2.CloudStorageResult cloud_storage_result = 5; - * @return \Google\Cloud\Speech\V2\CloudStorageResult|null - */ - public function getCloudStorageResult() - { - return $this->readOneof(5); - } - - public function hasCloudStorageResult() - { - return $this->hasOneof(5); - } - - /** - * Recognition results written to Cloud Storage. This is - * populated only when - * [GcsOutputConfig][google.cloud.speech.v2.GcsOutputConfig] is set in - * the - * [RecognitionOutputConfig][[google.cloud.speech.v2.RecognitionOutputConfig]. - * - * Generated from protobuf field .google.cloud.speech.v2.CloudStorageResult cloud_storage_result = 5; - * @param \Google\Cloud\Speech\V2\CloudStorageResult $var - * @return $this - */ - public function setCloudStorageResult($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\CloudStorageResult::class); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * Recognition results. This is populated only when - * [InlineOutputConfig][google.cloud.speech.v2.InlineOutputConfig] is set in - * the - * [RecognitionOutputConfig][[google.cloud.speech.v2.RecognitionOutputConfig]. - * - * Generated from protobuf field .google.cloud.speech.v2.InlineResult inline_result = 6; - * @return \Google\Cloud\Speech\V2\InlineResult|null - */ - public function getInlineResult() - { - return $this->readOneof(6); - } - - public function hasInlineResult() - { - return $this->hasOneof(6); - } - - /** - * Recognition results. This is populated only when - * [InlineOutputConfig][google.cloud.speech.v2.InlineOutputConfig] is set in - * the - * [RecognitionOutputConfig][[google.cloud.speech.v2.RecognitionOutputConfig]. - * - * Generated from protobuf field .google.cloud.speech.v2.InlineResult inline_result = 6; - * @param \Google\Cloud\Speech\V2\InlineResult $var - * @return $this - */ - public function setInlineResult($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\InlineResult::class); - $this->writeOneof(6, $var); - - return $this; - } - - /** - * Deprecated. Use `cloud_storage_result.native_format_uri` instead. - * - * Generated from protobuf field string uri = 1 [deprecated = true]; - * @return string - * @deprecated - */ - public function getUri() - { - if ($this->uri !== '') { - @trigger_error('uri is deprecated.', E_USER_DEPRECATED); - } - return $this->uri; - } - - /** - * Deprecated. Use `cloud_storage_result.native_format_uri` instead. - * - * Generated from protobuf field string uri = 1 [deprecated = true]; - * @param string $var - * @return $this - * @deprecated - */ - public function setUri($var) - { - @trigger_error('uri is deprecated.', E_USER_DEPRECATED); - GPBUtil::checkString($var, True); - $this->uri = $var; - - return $this; - } - - /** - * Deprecated. Use `inline_result.transcript` instead. - * - * Generated from protobuf field .google.cloud.speech.v2.BatchRecognizeResults transcript = 4 [deprecated = true]; - * @return \Google\Cloud\Speech\V2\BatchRecognizeResults|null - * @deprecated - */ - public function getTranscript() - { - if (isset($this->transcript)) { - @trigger_error('transcript is deprecated.', E_USER_DEPRECATED); - } - return $this->transcript; - } - - public function hasTranscript() - { - if (isset($this->transcript)) { - @trigger_error('transcript is deprecated.', E_USER_DEPRECATED); - } - return isset($this->transcript); - } - - public function clearTranscript() - { - @trigger_error('transcript is deprecated.', E_USER_DEPRECATED); - unset($this->transcript); - } - - /** - * Deprecated. Use `inline_result.transcript` instead. - * - * Generated from protobuf field .google.cloud.speech.v2.BatchRecognizeResults transcript = 4 [deprecated = true]; - * @param \Google\Cloud\Speech\V2\BatchRecognizeResults $var - * @return $this - * @deprecated - */ - public function setTranscript($var) - { - @trigger_error('transcript is deprecated.', E_USER_DEPRECATED); - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\BatchRecognizeResults::class); - $this->transcript = $var; - - return $this; - } - - /** - * @return string - */ - public function getResult() - { - return $this->whichOneof("result"); - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeMetadata.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeMetadata.php deleted file mode 100644 index 43ba95327d4d..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeMetadata.php +++ /dev/null @@ -1,68 +0,0 @@ -google.cloud.speech.v2.BatchRecognizeMetadata - */ -class BatchRecognizeMetadata extends \Google\Protobuf\Internal\Message -{ - /** - * Map from provided filename to the transcription metadata for that file. - * - * Generated from protobuf field map transcription_metadata = 1; - */ - private $transcription_metadata; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\MapField $transcription_metadata - * Map from provided filename to the transcription metadata for that file. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Map from provided filename to the transcription metadata for that file. - * - * Generated from protobuf field map transcription_metadata = 1; - * @return \Google\Protobuf\Internal\MapField - */ - public function getTranscriptionMetadata() - { - return $this->transcription_metadata; - } - - /** - * Map from provided filename to the transcription metadata for that file. - * - * Generated from protobuf field map transcription_metadata = 1; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setTranscriptionMetadata($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Speech\V2\BatchRecognizeTranscriptionMetadata::class); - $this->transcription_metadata = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeRequest.php deleted file mode 100644 index d3e2d3d9b300..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeRequest.php +++ /dev/null @@ -1,394 +0,0 @@ -google.cloud.speech.v2.BatchRecognizeRequest - */ -class BatchRecognizeRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the Recognizer to use during recognition. The - * expected format is - * `projects/{project}/locations/{location}/recognizers/{recognizer}`. The - * {recognizer} segment may be set to `_` to use an empty implicit Recognizer. - * - * Generated from protobuf field string recognizer = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $recognizer = ''; - /** - * Features and audio metadata to use for the Automatic Speech Recognition. - * This field in combination with the - * [config_mask][google.cloud.speech.v2.BatchRecognizeRequest.config_mask] - * field can be used to override parts of the - * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] - * of the Recognizer resource. - * - * Generated from protobuf field .google.cloud.speech.v2.RecognitionConfig config = 4; - */ - protected $config = null; - /** - * The list of fields in - * [config][google.cloud.speech.v2.BatchRecognizeRequest.config] that override - * the values in the - * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] - * of the recognizer during this recognition request. If no mask is provided, - * all given fields in - * [config][google.cloud.speech.v2.BatchRecognizeRequest.config] override the - * values in the recognizer for this recognition request. If a mask is - * provided, only the fields listed in the mask override the config in the - * recognizer for this recognition request. If a wildcard (`*`) is provided, - * [config][google.cloud.speech.v2.BatchRecognizeRequest.config] completely - * overrides and replaces the config in the recognizer for this recognition - * request. - * - * Generated from protobuf field .google.protobuf.FieldMask config_mask = 5; - */ - protected $config_mask = null; - /** - * Audio files with file metadata for ASR. - * The maximum number of files allowed to be specified is 15. - * - * Generated from protobuf field repeated .google.cloud.speech.v2.BatchRecognizeFileMetadata files = 3; - */ - private $files; - /** - * Configuration options for where to output the transcripts of each file. - * - * Generated from protobuf field .google.cloud.speech.v2.RecognitionOutputConfig recognition_output_config = 6; - */ - protected $recognition_output_config = null; - /** - * Processing strategy to use for this request. - * - * Generated from protobuf field .google.cloud.speech.v2.BatchRecognizeRequest.ProcessingStrategy processing_strategy = 7; - */ - protected $processing_strategy = 0; - - /** - * @param string $recognizer Required. The name of the Recognizer to use during recognition. The - * expected format is - * `projects/{project}/locations/{location}/recognizers/{recognizer}`. The - * {recognizer} segment may be set to `_` to use an empty implicit Recognizer. Please see - * {@see SpeechClient::recognizerName()} for help formatting this field. - * @param \Google\Cloud\Speech\V2\RecognitionConfig $config Features and audio metadata to use for the Automatic Speech Recognition. - * This field in combination with the - * [config_mask][google.cloud.speech.v2.BatchRecognizeRequest.config_mask] - * field can be used to override parts of the - * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] - * of the Recognizer resource. - * @param \Google\Protobuf\FieldMask $configMask The list of fields in - * [config][google.cloud.speech.v2.BatchRecognizeRequest.config] that override - * the values in the - * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] - * of the recognizer during this recognition request. If no mask is provided, - * all given fields in - * [config][google.cloud.speech.v2.BatchRecognizeRequest.config] override the - * values in the recognizer for this recognition request. If a mask is - * provided, only the fields listed in the mask override the config in the - * recognizer for this recognition request. If a wildcard (`*`) is provided, - * [config][google.cloud.speech.v2.BatchRecognizeRequest.config] completely - * overrides and replaces the config in the recognizer for this recognition - * request. - * @param \Google\Cloud\Speech\V2\BatchRecognizeFileMetadata[] $files Audio files with file metadata for ASR. - * The maximum number of files allowed to be specified is 15. - * - * @return \Google\Cloud\Speech\V2\BatchRecognizeRequest - * - * @experimental - */ - public static function build(string $recognizer, \Google\Cloud\Speech\V2\RecognitionConfig $config, \Google\Protobuf\FieldMask $configMask, array $files): self - { - return (new self()) - ->setRecognizer($recognizer) - ->setConfig($config) - ->setConfigMask($configMask) - ->setFiles($files); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $recognizer - * Required. The name of the Recognizer to use during recognition. The - * expected format is - * `projects/{project}/locations/{location}/recognizers/{recognizer}`. The - * {recognizer} segment may be set to `_` to use an empty implicit Recognizer. - * @type \Google\Cloud\Speech\V2\RecognitionConfig $config - * Features and audio metadata to use for the Automatic Speech Recognition. - * This field in combination with the - * [config_mask][google.cloud.speech.v2.BatchRecognizeRequest.config_mask] - * field can be used to override parts of the - * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] - * of the Recognizer resource. - * @type \Google\Protobuf\FieldMask $config_mask - * The list of fields in - * [config][google.cloud.speech.v2.BatchRecognizeRequest.config] that override - * the values in the - * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] - * of the recognizer during this recognition request. If no mask is provided, - * all given fields in - * [config][google.cloud.speech.v2.BatchRecognizeRequest.config] override the - * values in the recognizer for this recognition request. If a mask is - * provided, only the fields listed in the mask override the config in the - * recognizer for this recognition request. If a wildcard (`*`) is provided, - * [config][google.cloud.speech.v2.BatchRecognizeRequest.config] completely - * overrides and replaces the config in the recognizer for this recognition - * request. - * @type \Google\Cloud\Speech\V2\BatchRecognizeFileMetadata[] $files - * Audio files with file metadata for ASR. - * The maximum number of files allowed to be specified is 15. - * @type \Google\Cloud\Speech\V2\RecognitionOutputConfig $recognition_output_config - * Configuration options for where to output the transcripts of each file. - * @type int $processing_strategy - * Processing strategy to use for this request. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the Recognizer to use during recognition. The - * expected format is - * `projects/{project}/locations/{location}/recognizers/{recognizer}`. The - * {recognizer} segment may be set to `_` to use an empty implicit Recognizer. - * - * Generated from protobuf field string recognizer = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getRecognizer() - { - return $this->recognizer; - } - - /** - * Required. The name of the Recognizer to use during recognition. The - * expected format is - * `projects/{project}/locations/{location}/recognizers/{recognizer}`. The - * {recognizer} segment may be set to `_` to use an empty implicit Recognizer. - * - * Generated from protobuf field string recognizer = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setRecognizer($var) - { - GPBUtil::checkString($var, True); - $this->recognizer = $var; - - return $this; - } - - /** - * Features and audio metadata to use for the Automatic Speech Recognition. - * This field in combination with the - * [config_mask][google.cloud.speech.v2.BatchRecognizeRequest.config_mask] - * field can be used to override parts of the - * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] - * of the Recognizer resource. - * - * Generated from protobuf field .google.cloud.speech.v2.RecognitionConfig config = 4; - * @return \Google\Cloud\Speech\V2\RecognitionConfig|null - */ - public function getConfig() - { - return $this->config; - } - - public function hasConfig() - { - return isset($this->config); - } - - public function clearConfig() - { - unset($this->config); - } - - /** - * Features and audio metadata to use for the Automatic Speech Recognition. - * This field in combination with the - * [config_mask][google.cloud.speech.v2.BatchRecognizeRequest.config_mask] - * field can be used to override parts of the - * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] - * of the Recognizer resource. - * - * Generated from protobuf field .google.cloud.speech.v2.RecognitionConfig config = 4; - * @param \Google\Cloud\Speech\V2\RecognitionConfig $var - * @return $this - */ - public function setConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\RecognitionConfig::class); - $this->config = $var; - - return $this; - } - - /** - * The list of fields in - * [config][google.cloud.speech.v2.BatchRecognizeRequest.config] that override - * the values in the - * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] - * of the recognizer during this recognition request. If no mask is provided, - * all given fields in - * [config][google.cloud.speech.v2.BatchRecognizeRequest.config] override the - * values in the recognizer for this recognition request. If a mask is - * provided, only the fields listed in the mask override the config in the - * recognizer for this recognition request. If a wildcard (`*`) is provided, - * [config][google.cloud.speech.v2.BatchRecognizeRequest.config] completely - * overrides and replaces the config in the recognizer for this recognition - * request. - * - * Generated from protobuf field .google.protobuf.FieldMask config_mask = 5; - * @return \Google\Protobuf\FieldMask|null - */ - public function getConfigMask() - { - return $this->config_mask; - } - - public function hasConfigMask() - { - return isset($this->config_mask); - } - - public function clearConfigMask() - { - unset($this->config_mask); - } - - /** - * The list of fields in - * [config][google.cloud.speech.v2.BatchRecognizeRequest.config] that override - * the values in the - * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] - * of the recognizer during this recognition request. If no mask is provided, - * all given fields in - * [config][google.cloud.speech.v2.BatchRecognizeRequest.config] override the - * values in the recognizer for this recognition request. If a mask is - * provided, only the fields listed in the mask override the config in the - * recognizer for this recognition request. If a wildcard (`*`) is provided, - * [config][google.cloud.speech.v2.BatchRecognizeRequest.config] completely - * overrides and replaces the config in the recognizer for this recognition - * request. - * - * Generated from protobuf field .google.protobuf.FieldMask config_mask = 5; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setConfigMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->config_mask = $var; - - return $this; - } - - /** - * Audio files with file metadata for ASR. - * The maximum number of files allowed to be specified is 15. - * - * Generated from protobuf field repeated .google.cloud.speech.v2.BatchRecognizeFileMetadata files = 3; - * @return RepeatedField<\Google\Cloud\Speech\V2\BatchRecognizeFileMetadata> - */ - public function getFiles() - { - return $this->files; - } - - /** - * Audio files with file metadata for ASR. - * The maximum number of files allowed to be specified is 15. - * - * Generated from protobuf field repeated .google.cloud.speech.v2.BatchRecognizeFileMetadata files = 3; - * @param \Google\Cloud\Speech\V2\BatchRecognizeFileMetadata[] $var - * @return $this - */ - public function setFiles($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Speech\V2\BatchRecognizeFileMetadata::class); - $this->files = $arr; - - return $this; - } - - /** - * Configuration options for where to output the transcripts of each file. - * - * Generated from protobuf field .google.cloud.speech.v2.RecognitionOutputConfig recognition_output_config = 6; - * @return \Google\Cloud\Speech\V2\RecognitionOutputConfig|null - */ - public function getRecognitionOutputConfig() - { - return $this->recognition_output_config; - } - - public function hasRecognitionOutputConfig() - { - return isset($this->recognition_output_config); - } - - public function clearRecognitionOutputConfig() - { - unset($this->recognition_output_config); - } - - /** - * Configuration options for where to output the transcripts of each file. - * - * Generated from protobuf field .google.cloud.speech.v2.RecognitionOutputConfig recognition_output_config = 6; - * @param \Google\Cloud\Speech\V2\RecognitionOutputConfig $var - * @return $this - */ - public function setRecognitionOutputConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\RecognitionOutputConfig::class); - $this->recognition_output_config = $var; - - return $this; - } - - /** - * Processing strategy to use for this request. - * - * Generated from protobuf field .google.cloud.speech.v2.BatchRecognizeRequest.ProcessingStrategy processing_strategy = 7; - * @return int - */ - public function getProcessingStrategy() - { - return $this->processing_strategy; - } - - /** - * Processing strategy to use for this request. - * - * Generated from protobuf field .google.cloud.speech.v2.BatchRecognizeRequest.ProcessingStrategy processing_strategy = 7; - * @param int $var - * @return $this - */ - public function setProcessingStrategy($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Speech\V2\BatchRecognizeRequest\ProcessingStrategy::class); - $this->processing_strategy = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeRequest/ProcessingStrategy.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeRequest/ProcessingStrategy.php deleted file mode 100644 index fdf6905d01af..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeRequest/ProcessingStrategy.php +++ /dev/null @@ -1,56 +0,0 @@ -google.cloud.speech.v2.BatchRecognizeRequest.ProcessingStrategy - */ -class ProcessingStrategy -{ - /** - * Default value for the processing strategy. The request is processed as - * soon as its received. - * - * Generated from protobuf enum PROCESSING_STRATEGY_UNSPECIFIED = 0; - */ - const PROCESSING_STRATEGY_UNSPECIFIED = 0; - /** - * If selected, processes the request during lower utilization periods for a - * price discount. The request is fulfilled within 24 hours. - * - * Generated from protobuf enum DYNAMIC_BATCHING = 1; - */ - const DYNAMIC_BATCHING = 1; - - private static $valueToName = [ - self::PROCESSING_STRATEGY_UNSPECIFIED => 'PROCESSING_STRATEGY_UNSPECIFIED', - self::DYNAMIC_BATCHING => 'DYNAMIC_BATCHING', - ]; - - 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/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeResponse.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeResponse.php deleted file mode 100644 index 36b1bf9542dd..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeResponse.php +++ /dev/null @@ -1,113 +0,0 @@ -google.cloud.speech.v2.BatchRecognizeResponse - */ -class BatchRecognizeResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Map from filename to the final result for that file. - * - * Generated from protobuf field map results = 1; - */ - private $results; - /** - * When available, billed audio seconds for the corresponding request. - * - * Generated from protobuf field .google.protobuf.Duration total_billed_duration = 2; - */ - protected $total_billed_duration = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\MapField $results - * Map from filename to the final result for that file. - * @type \Google\Protobuf\Duration $total_billed_duration - * When available, billed audio seconds for the corresponding request. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Map from filename to the final result for that file. - * - * Generated from protobuf field map results = 1; - * @return \Google\Protobuf\Internal\MapField - */ - public function getResults() - { - return $this->results; - } - - /** - * Map from filename to the final result for that file. - * - * Generated from protobuf field map results = 1; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setResults($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Speech\V2\BatchRecognizeFileResult::class); - $this->results = $arr; - - return $this; - } - - /** - * When available, billed audio seconds for the corresponding request. - * - * Generated from protobuf field .google.protobuf.Duration total_billed_duration = 2; - * @return \Google\Protobuf\Duration|null - */ - public function getTotalBilledDuration() - { - return $this->total_billed_duration; - } - - public function hasTotalBilledDuration() - { - return isset($this->total_billed_duration); - } - - public function clearTotalBilledDuration() - { - unset($this->total_billed_duration); - } - - /** - * When available, billed audio seconds for the corresponding request. - * - * Generated from protobuf field .google.protobuf.Duration total_billed_duration = 2; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setTotalBilledDuration($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->total_billed_duration = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeResults.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeResults.php deleted file mode 100644 index be39c6e4a3f8..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeResults.php +++ /dev/null @@ -1,117 +0,0 @@ -google.cloud.speech.v2.BatchRecognizeResults - */ -class BatchRecognizeResults extends \Google\Protobuf\Internal\Message -{ - /** - * Sequential list of transcription results corresponding to sequential - * portions of audio. - * - * Generated from protobuf field repeated .google.cloud.speech.v2.SpeechRecognitionResult results = 1; - */ - private $results; - /** - * Metadata about the recognition. - * - * Generated from protobuf field .google.cloud.speech.v2.RecognitionResponseMetadata metadata = 2; - */ - protected $metadata = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Speech\V2\SpeechRecognitionResult[] $results - * Sequential list of transcription results corresponding to sequential - * portions of audio. - * @type \Google\Cloud\Speech\V2\RecognitionResponseMetadata $metadata - * Metadata about the recognition. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Sequential list of transcription results corresponding to sequential - * portions of audio. - * - * Generated from protobuf field repeated .google.cloud.speech.v2.SpeechRecognitionResult results = 1; - * @return RepeatedField<\Google\Cloud\Speech\V2\SpeechRecognitionResult> - */ - public function getResults() - { - return $this->results; - } - - /** - * Sequential list of transcription results corresponding to sequential - * portions of audio. - * - * Generated from protobuf field repeated .google.cloud.speech.v2.SpeechRecognitionResult results = 1; - * @param \Google\Cloud\Speech\V2\SpeechRecognitionResult[] $var - * @return $this - */ - public function setResults($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Speech\V2\SpeechRecognitionResult::class); - $this->results = $arr; - - return $this; - } - - /** - * Metadata about the recognition. - * - * Generated from protobuf field .google.cloud.speech.v2.RecognitionResponseMetadata metadata = 2; - * @return \Google\Cloud\Speech\V2\RecognitionResponseMetadata|null - */ - public function getMetadata() - { - return $this->metadata; - } - - public function hasMetadata() - { - return isset($this->metadata); - } - - public function clearMetadata() - { - unset($this->metadata); - } - - /** - * Metadata about the recognition. - * - * Generated from protobuf field .google.cloud.speech.v2.RecognitionResponseMetadata metadata = 2; - * @param \Google\Cloud\Speech\V2\RecognitionResponseMetadata $var - * @return $this - */ - public function setMetadata($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\RecognitionResponseMetadata::class); - $this->metadata = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeTranscriptionMetadata.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeTranscriptionMetadata.php deleted file mode 100644 index e51976e1e846..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/BatchRecognizeTranscriptionMetadata.php +++ /dev/null @@ -1,146 +0,0 @@ -google.cloud.speech.v2.BatchRecognizeTranscriptionMetadata - */ -class BatchRecognizeTranscriptionMetadata extends \Google\Protobuf\Internal\Message -{ - /** - * How much of the file has been transcribed so far. - * - * Generated from protobuf field int32 progress_percent = 1; - */ - protected $progress_percent = 0; - /** - * Error if one was encountered. - * - * Generated from protobuf field .google.rpc.Status error = 2; - */ - protected $error = null; - /** - * The Cloud Storage URI to which recognition results will be written. - * - * Generated from protobuf field string uri = 3; - */ - protected $uri = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $progress_percent - * How much of the file has been transcribed so far. - * @type \Google\Rpc\Status $error - * Error if one was encountered. - * @type string $uri - * The Cloud Storage URI to which recognition results will be written. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * How much of the file has been transcribed so far. - * - * Generated from protobuf field int32 progress_percent = 1; - * @return int - */ - public function getProgressPercent() - { - return $this->progress_percent; - } - - /** - * How much of the file has been transcribed so far. - * - * Generated from protobuf field int32 progress_percent = 1; - * @param int $var - * @return $this - */ - public function setProgressPercent($var) - { - GPBUtil::checkInt32($var); - $this->progress_percent = $var; - - return $this; - } - - /** - * Error if one was encountered. - * - * Generated from protobuf field .google.rpc.Status error = 2; - * @return \Google\Rpc\Status|null - */ - public function getError() - { - return $this->error; - } - - public function hasError() - { - return isset($this->error); - } - - public function clearError() - { - unset($this->error); - } - - /** - * Error if one was encountered. - * - * Generated from protobuf field .google.rpc.Status error = 2; - * @param \Google\Rpc\Status $var - * @return $this - */ - public function setError($var) - { - GPBUtil::checkMessage($var, \Google\Rpc\Status::class); - $this->error = $var; - - return $this; - } - - /** - * The Cloud Storage URI to which recognition results will be written. - * - * Generated from protobuf field string uri = 3; - * @return string - */ - public function getUri() - { - return $this->uri; - } - - /** - * The Cloud Storage URI to which recognition results will be written. - * - * Generated from protobuf field string uri = 3; - * @param string $var - * @return $this - */ - public function setUri($var) - { - GPBUtil::checkString($var, True); - $this->uri = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CloudStorageResult.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CloudStorageResult.php deleted file mode 100644 index 41e59d91553a..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CloudStorageResult.php +++ /dev/null @@ -1,143 +0,0 @@ -google.cloud.speech.v2.CloudStorageResult - */ -class CloudStorageResult extends \Google\Protobuf\Internal\Message -{ - /** - * The Cloud Storage URI to which recognition results were written. - * - * Generated from protobuf field string uri = 1; - */ - protected $uri = ''; - /** - * The Cloud Storage URI to which recognition results were written as VTT - * formatted captions. This is populated only when `VTT` output is requested. - * - * Generated from protobuf field string vtt_format_uri = 2; - */ - protected $vtt_format_uri = ''; - /** - * The Cloud Storage URI to which recognition results were written as SRT - * formatted captions. This is populated only when `SRT` output is requested. - * - * Generated from protobuf field string srt_format_uri = 3; - */ - protected $srt_format_uri = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $uri - * The Cloud Storage URI to which recognition results were written. - * @type string $vtt_format_uri - * The Cloud Storage URI to which recognition results were written as VTT - * formatted captions. This is populated only when `VTT` output is requested. - * @type string $srt_format_uri - * The Cloud Storage URI to which recognition results were written as SRT - * formatted captions. This is populated only when `SRT` output is requested. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * The Cloud Storage URI to which recognition results were written. - * - * Generated from protobuf field string uri = 1; - * @return string - */ - public function getUri() - { - return $this->uri; - } - - /** - * The Cloud Storage URI to which recognition results were written. - * - * 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; - } - - /** - * The Cloud Storage URI to which recognition results were written as VTT - * formatted captions. This is populated only when `VTT` output is requested. - * - * Generated from protobuf field string vtt_format_uri = 2; - * @return string - */ - public function getVttFormatUri() - { - return $this->vtt_format_uri; - } - - /** - * The Cloud Storage URI to which recognition results were written as VTT - * formatted captions. This is populated only when `VTT` output is requested. - * - * Generated from protobuf field string vtt_format_uri = 2; - * @param string $var - * @return $this - */ - public function setVttFormatUri($var) - { - GPBUtil::checkString($var, True); - $this->vtt_format_uri = $var; - - return $this; - } - - /** - * The Cloud Storage URI to which recognition results were written as SRT - * formatted captions. This is populated only when `SRT` output is requested. - * - * Generated from protobuf field string srt_format_uri = 3; - * @return string - */ - public function getSrtFormatUri() - { - return $this->srt_format_uri; - } - - /** - * The Cloud Storage URI to which recognition results were written as SRT - * formatted captions. This is populated only when `SRT` output is requested. - * - * Generated from protobuf field string srt_format_uri = 3; - * @param string $var - * @return $this - */ - public function setSrtFormatUri($var) - { - GPBUtil::checkString($var, True); - $this->srt_format_uri = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/Config.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/Config.php deleted file mode 100644 index 97cbf042f620..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/Config.php +++ /dev/null @@ -1,175 +0,0 @@ -google.cloud.speech.v2.Config - */ -class Config extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. Identifier. The name of the config resource. There is exactly - * one config resource per project per location. The expected format is - * `projects/{project}/locations/{location}/config`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IDENTIFIER]; - */ - protected $name = ''; - /** - * Optional. An optional [KMS key - * name](https://cloud.google.com/kms/docs/resource-hierarchy#keys) that if - * present, will be used to encrypt Speech-to-Text resources at-rest. Updating - * this key will not encrypt existing resources using this key; only new - * resources will be encrypted using this key. The expected format is - * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. - * - * Generated from protobuf field string kms_key_name = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { - */ - protected $kms_key_name = ''; - /** - * Output only. The most recent time this resource was modified. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. Identifier. The name of the config resource. There is exactly - * one config resource per project per location. The expected format is - * `projects/{project}/locations/{location}/config`. - * @type string $kms_key_name - * Optional. An optional [KMS key - * name](https://cloud.google.com/kms/docs/resource-hierarchy#keys) that if - * present, will be used to encrypt Speech-to-Text resources at-rest. Updating - * this key will not encrypt existing resources using this key; only new - * resources will be encrypted using this key. The expected format is - * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. The most recent time this resource was modified. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Output only. Identifier. The name of the config resource. There is exactly - * one config resource per project per location. The expected format is - * `projects/{project}/locations/{location}/config`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IDENTIFIER]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Output only. Identifier. The name of the config resource. There is exactly - * one config resource per project per location. The expected format is - * `projects/{project}/locations/{location}/config`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IDENTIFIER]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Optional. An optional [KMS key - * name](https://cloud.google.com/kms/docs/resource-hierarchy#keys) that if - * present, will be used to encrypt Speech-to-Text resources at-rest. Updating - * this key will not encrypt existing resources using this key; only new - * resources will be encrypted using this key. The expected format is - * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. - * - * Generated from protobuf field string kms_key_name = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { - * @return string - */ - public function getKmsKeyName() - { - return $this->kms_key_name; - } - - /** - * Optional. An optional [KMS key - * name](https://cloud.google.com/kms/docs/resource-hierarchy#keys) that if - * present, will be used to encrypt Speech-to-Text resources at-rest. Updating - * this key will not encrypt existing resources using this key; only new - * resources will be encrypted using this key. The expected format is - * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. - * - * Generated from protobuf field string kms_key_name = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setKmsKeyName($var) - { - GPBUtil::checkString($var, True); - $this->kms_key_name = $var; - - return $this; - } - - /** - * Output only. The most recent time this resource was 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. The most recent time this resource was 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; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CreateCustomClassRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CreateCustomClassRequest.php deleted file mode 100644 index fe0f6a6171dc..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CreateCustomClassRequest.php +++ /dev/null @@ -1,223 +0,0 @@ -google.cloud.speech.v2.CreateCustomClassRequest - */ -class CreateCustomClassRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The CustomClass to create. - * - * Generated from protobuf field .google.cloud.speech.v2.CustomClass custom_class = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $custom_class = null; - /** - * If set, validate the request and preview the CustomClass, but do not - * actually create it. - * - * Generated from protobuf field bool validate_only = 2; - */ - protected $validate_only = false; - /** - * The ID to use for the CustomClass, which will become the final component of - * the CustomClass's resource name. - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. - * - * Generated from protobuf field string custom_class_id = 3; - */ - protected $custom_class_id = ''; - /** - * Required. The project and location where this CustomClass will be created. - * The expected format is `projects/{project}/locations/{location}`. - * - * Generated from protobuf field string parent = 4 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - - /** - * @param string $parent Required. The project and location where this CustomClass will be created. - * The expected format is `projects/{project}/locations/{location}`. Please see - * {@see SpeechClient::locationName()} for help formatting this field. - * @param \Google\Cloud\Speech\V2\CustomClass $customClass Required. The CustomClass to create. - * @param string $customClassId The ID to use for the CustomClass, which will become the final component of - * the CustomClass's resource name. - * - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. - * - * @return \Google\Cloud\Speech\V2\CreateCustomClassRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\Speech\V2\CustomClass $customClass, string $customClassId): self - { - return (new self()) - ->setParent($parent) - ->setCustomClass($customClass) - ->setCustomClassId($customClassId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Speech\V2\CustomClass $custom_class - * Required. The CustomClass to create. - * @type bool $validate_only - * If set, validate the request and preview the CustomClass, but do not - * actually create it. - * @type string $custom_class_id - * The ID to use for the CustomClass, which will become the final component of - * the CustomClass's resource name. - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. - * @type string $parent - * Required. The project and location where this CustomClass will be created. - * The expected format is `projects/{project}/locations/{location}`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Required. The CustomClass to create. - * - * Generated from protobuf field .google.cloud.speech.v2.CustomClass custom_class = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Speech\V2\CustomClass|null - */ - public function getCustomClass() - { - return $this->custom_class; - } - - public function hasCustomClass() - { - return isset($this->custom_class); - } - - public function clearCustomClass() - { - unset($this->custom_class); - } - - /** - * Required. The CustomClass to create. - * - * Generated from protobuf field .google.cloud.speech.v2.CustomClass custom_class = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Speech\V2\CustomClass $var - * @return $this - */ - public function setCustomClass($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\CustomClass::class); - $this->custom_class = $var; - - return $this; - } - - /** - * If set, validate the request and preview the CustomClass, but do not - * actually create it. - * - * Generated from protobuf field bool validate_only = 2; - * @return bool - */ - public function getValidateOnly() - { - return $this->validate_only; - } - - /** - * If set, validate the request and preview the CustomClass, but do not - * actually create it. - * - * Generated from protobuf field bool validate_only = 2; - * @param bool $var - * @return $this - */ - public function setValidateOnly($var) - { - GPBUtil::checkBool($var); - $this->validate_only = $var; - - return $this; - } - - /** - * The ID to use for the CustomClass, which will become the final component of - * the CustomClass's resource name. - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. - * - * Generated from protobuf field string custom_class_id = 3; - * @return string - */ - public function getCustomClassId() - { - return $this->custom_class_id; - } - - /** - * The ID to use for the CustomClass, which will become the final component of - * the CustomClass's resource name. - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. - * - * Generated from protobuf field string custom_class_id = 3; - * @param string $var - * @return $this - */ - public function setCustomClassId($var) - { - GPBUtil::checkString($var, True); - $this->custom_class_id = $var; - - return $this; - } - - /** - * Required. The project and location where this CustomClass will be created. - * The expected format is `projects/{project}/locations/{location}`. - * - * Generated from protobuf field string parent = 4 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The project and location where this CustomClass will be created. - * The expected format is `projects/{project}/locations/{location}`. - * - * Generated from protobuf field string parent = 4 [(.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; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CreatePhraseSetRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CreatePhraseSetRequest.php deleted file mode 100644 index 1c9779ed145b..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CreatePhraseSetRequest.php +++ /dev/null @@ -1,223 +0,0 @@ -google.cloud.speech.v2.CreatePhraseSetRequest - */ -class CreatePhraseSetRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The PhraseSet to create. - * - * Generated from protobuf field .google.cloud.speech.v2.PhraseSet phrase_set = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $phrase_set = null; - /** - * If set, validate the request and preview the PhraseSet, but do not - * actually create it. - * - * Generated from protobuf field bool validate_only = 2; - */ - protected $validate_only = false; - /** - * The ID to use for the PhraseSet, which will become the final component of - * the PhraseSet's resource name. - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. - * - * Generated from protobuf field string phrase_set_id = 3; - */ - protected $phrase_set_id = ''; - /** - * Required. The project and location where this PhraseSet will be created. - * The expected format is `projects/{project}/locations/{location}`. - * - * Generated from protobuf field string parent = 4 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - - /** - * @param string $parent Required. The project and location where this PhraseSet will be created. - * The expected format is `projects/{project}/locations/{location}`. Please see - * {@see SpeechClient::locationName()} for help formatting this field. - * @param \Google\Cloud\Speech\V2\PhraseSet $phraseSet Required. The PhraseSet to create. - * @param string $phraseSetId The ID to use for the PhraseSet, which will become the final component of - * the PhraseSet's resource name. - * - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. - * - * @return \Google\Cloud\Speech\V2\CreatePhraseSetRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\Speech\V2\PhraseSet $phraseSet, string $phraseSetId): self - { - return (new self()) - ->setParent($parent) - ->setPhraseSet($phraseSet) - ->setPhraseSetId($phraseSetId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Speech\V2\PhraseSet $phrase_set - * Required. The PhraseSet to create. - * @type bool $validate_only - * If set, validate the request and preview the PhraseSet, but do not - * actually create it. - * @type string $phrase_set_id - * The ID to use for the PhraseSet, which will become the final component of - * the PhraseSet's resource name. - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. - * @type string $parent - * Required. The project and location where this PhraseSet will be created. - * The expected format is `projects/{project}/locations/{location}`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Required. The PhraseSet to create. - * - * Generated from protobuf field .google.cloud.speech.v2.PhraseSet phrase_set = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Speech\V2\PhraseSet|null - */ - public function getPhraseSet() - { - return $this->phrase_set; - } - - public function hasPhraseSet() - { - return isset($this->phrase_set); - } - - public function clearPhraseSet() - { - unset($this->phrase_set); - } - - /** - * Required. The PhraseSet to create. - * - * Generated from protobuf field .google.cloud.speech.v2.PhraseSet phrase_set = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Speech\V2\PhraseSet $var - * @return $this - */ - public function setPhraseSet($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\PhraseSet::class); - $this->phrase_set = $var; - - return $this; - } - - /** - * If set, validate the request and preview the PhraseSet, but do not - * actually create it. - * - * Generated from protobuf field bool validate_only = 2; - * @return bool - */ - public function getValidateOnly() - { - return $this->validate_only; - } - - /** - * If set, validate the request and preview the PhraseSet, but do not - * actually create it. - * - * Generated from protobuf field bool validate_only = 2; - * @param bool $var - * @return $this - */ - public function setValidateOnly($var) - { - GPBUtil::checkBool($var); - $this->validate_only = $var; - - return $this; - } - - /** - * The ID to use for the PhraseSet, which will become the final component of - * the PhraseSet's resource name. - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. - * - * Generated from protobuf field string phrase_set_id = 3; - * @return string - */ - public function getPhraseSetId() - { - return $this->phrase_set_id; - } - - /** - * The ID to use for the PhraseSet, which will become the final component of - * the PhraseSet's resource name. - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. - * - * Generated from protobuf field string phrase_set_id = 3; - * @param string $var - * @return $this - */ - public function setPhraseSetId($var) - { - GPBUtil::checkString($var, True); - $this->phrase_set_id = $var; - - return $this; - } - - /** - * Required. The project and location where this PhraseSet will be created. - * The expected format is `projects/{project}/locations/{location}`. - * - * Generated from protobuf field string parent = 4 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The project and location where this PhraseSet will be created. - * The expected format is `projects/{project}/locations/{location}`. - * - * Generated from protobuf field string parent = 4 [(.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; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CreateRecognizerRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CreateRecognizerRequest.php deleted file mode 100644 index bf9c8bd3aa14..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CreateRecognizerRequest.php +++ /dev/null @@ -1,223 +0,0 @@ -google.cloud.speech.v2.CreateRecognizerRequest - */ -class CreateRecognizerRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The Recognizer to create. - * - * Generated from protobuf field .google.cloud.speech.v2.Recognizer recognizer = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $recognizer = null; - /** - * If set, validate the request and preview the Recognizer, but do not - * actually create it. - * - * Generated from protobuf field bool validate_only = 2; - */ - protected $validate_only = false; - /** - * The ID to use for the Recognizer, which will become the final component of - * the Recognizer's resource name. - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. - * - * Generated from protobuf field string recognizer_id = 3; - */ - protected $recognizer_id = ''; - /** - * Required. The project and location where this Recognizer will be created. - * The expected format is `projects/{project}/locations/{location}`. - * - * Generated from protobuf field string parent = 4 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - - /** - * @param string $parent Required. The project and location where this Recognizer will be created. - * The expected format is `projects/{project}/locations/{location}`. Please see - * {@see SpeechClient::locationName()} for help formatting this field. - * @param \Google\Cloud\Speech\V2\Recognizer $recognizer Required. The Recognizer to create. - * @param string $recognizerId The ID to use for the Recognizer, which will become the final component of - * the Recognizer's resource name. - * - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. - * - * @return \Google\Cloud\Speech\V2\CreateRecognizerRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\Speech\V2\Recognizer $recognizer, string $recognizerId): self - { - return (new self()) - ->setParent($parent) - ->setRecognizer($recognizer) - ->setRecognizerId($recognizerId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Speech\V2\Recognizer $recognizer - * Required. The Recognizer to create. - * @type bool $validate_only - * If set, validate the request and preview the Recognizer, but do not - * actually create it. - * @type string $recognizer_id - * The ID to use for the Recognizer, which will become the final component of - * the Recognizer's resource name. - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. - * @type string $parent - * Required. The project and location where this Recognizer will be created. - * The expected format is `projects/{project}/locations/{location}`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Required. The Recognizer to create. - * - * Generated from protobuf field .google.cloud.speech.v2.Recognizer recognizer = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Speech\V2\Recognizer|null - */ - public function getRecognizer() - { - return $this->recognizer; - } - - public function hasRecognizer() - { - return isset($this->recognizer); - } - - public function clearRecognizer() - { - unset($this->recognizer); - } - - /** - * Required. The Recognizer to create. - * - * Generated from protobuf field .google.cloud.speech.v2.Recognizer recognizer = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Speech\V2\Recognizer $var - * @return $this - */ - public function setRecognizer($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\Recognizer::class); - $this->recognizer = $var; - - return $this; - } - - /** - * If set, validate the request and preview the Recognizer, but do not - * actually create it. - * - * Generated from protobuf field bool validate_only = 2; - * @return bool - */ - public function getValidateOnly() - { - return $this->validate_only; - } - - /** - * If set, validate the request and preview the Recognizer, but do not - * actually create it. - * - * Generated from protobuf field bool validate_only = 2; - * @param bool $var - * @return $this - */ - public function setValidateOnly($var) - { - GPBUtil::checkBool($var); - $this->validate_only = $var; - - return $this; - } - - /** - * The ID to use for the Recognizer, which will become the final component of - * the Recognizer's resource name. - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. - * - * Generated from protobuf field string recognizer_id = 3; - * @return string - */ - public function getRecognizerId() - { - return $this->recognizer_id; - } - - /** - * The ID to use for the Recognizer, which will become the final component of - * the Recognizer's resource name. - * This value should be 4-63 characters, and valid characters - * are /[a-z][0-9]-/. - * - * Generated from protobuf field string recognizer_id = 3; - * @param string $var - * @return $this - */ - public function setRecognizerId($var) - { - GPBUtil::checkString($var, True); - $this->recognizer_id = $var; - - return $this; - } - - /** - * Required. The project and location where this Recognizer will be created. - * The expected format is `projects/{project}/locations/{location}`. - * - * Generated from protobuf field string parent = 4 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The project and location where this Recognizer will be created. - * The expected format is `projects/{project}/locations/{location}`. - * - * Generated from protobuf field string parent = 4 [(.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; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CustomClass.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CustomClass.php deleted file mode 100644 index 21b809a7e6a9..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CustomClass.php +++ /dev/null @@ -1,607 +0,0 @@ -google.cloud.speech.v2.CustomClass - */ -class CustomClass extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. Identifier. The resource name of the CustomClass. - * Format: - * `projects/{project}/locations/{location}/customClasses/{custom_class}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IDENTIFIER]; - */ - protected $name = ''; - /** - * Output only. System-assigned unique identifier for the CustomClass. - * - * Generated from protobuf field string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $uid = ''; - /** - * Optional. User-settable, human-readable name for the CustomClass. Must be - * 63 characters or less. - * - * Generated from protobuf field string display_name = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $display_name = ''; - /** - * A collection of class items. - * - * Generated from protobuf field repeated .google.cloud.speech.v2.CustomClass.ClassItem items = 5; - */ - private $items; - /** - * Output only. The CustomClass lifecycle state. - * - * Generated from protobuf field .google.cloud.speech.v2.CustomClass.State state = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = 0; - /** - * Output only. Creation time. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The most recent time this resource was modified. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Output only. The time at which this resource was requested for deletion. - * - * Generated from protobuf field .google.protobuf.Timestamp delete_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $delete_time = null; - /** - * Output only. The time at which this resource will be purged. - * - * Generated from protobuf field .google.protobuf.Timestamp expire_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $expire_time = null; - /** - * Optional. Allows users to store small amounts of arbitrary data. - * Both the key and the value must be 63 characters or less each. - * At most 100 annotations. - * - * Generated from protobuf field map annotations = 10 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $annotations; - /** - * Output only. This checksum is computed by the server based on the value of - * other fields. This may be sent on update, undelete, and delete requests to - * ensure 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 = ''; - /** - * Output only. Whether or not this CustomClass is in the process of being - * updated. - * - * Generated from protobuf field bool reconciling = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $reconciling = false; - /** - * Output only. The [KMS key - * name](https://cloud.google.com/kms/docs/resource-hierarchy#keys) with which - * the CustomClass is encrypted. The expected format is - * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. - * - * Generated from protobuf field string kms_key_name = 13 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { - */ - protected $kms_key_name = ''; - /** - * Output only. The [KMS key version - * name](https://cloud.google.com/kms/docs/resource-hierarchy#key_versions) - * with which the CustomClass is encrypted. The expected format is - * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}/cryptoKeyVersions/{crypto_key_version}`. - * - * Generated from protobuf field string kms_key_version_name = 14 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { - */ - protected $kms_key_version_name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. Identifier. The resource name of the CustomClass. - * Format: - * `projects/{project}/locations/{location}/customClasses/{custom_class}`. - * @type string $uid - * Output only. System-assigned unique identifier for the CustomClass. - * @type string $display_name - * Optional. User-settable, human-readable name for the CustomClass. Must be - * 63 characters or less. - * @type \Google\Cloud\Speech\V2\CustomClass\ClassItem[] $items - * A collection of class items. - * @type int $state - * Output only. The CustomClass lifecycle state. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. Creation time. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. The most recent time this resource was modified. - * @type \Google\Protobuf\Timestamp $delete_time - * Output only. The time at which this resource was requested for deletion. - * @type \Google\Protobuf\Timestamp $expire_time - * Output only. The time at which this resource will be purged. - * @type array|\Google\Protobuf\Internal\MapField $annotations - * Optional. Allows users to store small amounts of arbitrary data. - * Both the key and the value must be 63 characters or less each. - * At most 100 annotations. - * @type string $etag - * Output only. This checksum is computed by the server based on the value of - * other fields. This may be sent on update, undelete, and delete requests to - * ensure the client has an up-to-date value before proceeding. - * @type bool $reconciling - * Output only. Whether or not this CustomClass is in the process of being - * updated. - * @type string $kms_key_name - * Output only. The [KMS key - * name](https://cloud.google.com/kms/docs/resource-hierarchy#keys) with which - * the CustomClass is encrypted. The expected format is - * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. - * @type string $kms_key_version_name - * Output only. The [KMS key version - * name](https://cloud.google.com/kms/docs/resource-hierarchy#key_versions) - * with which the CustomClass is encrypted. The expected format is - * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}/cryptoKeyVersions/{crypto_key_version}`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Output only. Identifier. The resource name of the CustomClass. - * Format: - * `projects/{project}/locations/{location}/customClasses/{custom_class}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IDENTIFIER]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Output only. Identifier. The resource name of the CustomClass. - * Format: - * `projects/{project}/locations/{location}/customClasses/{custom_class}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IDENTIFIER]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Output only. System-assigned unique identifier for the CustomClass. - * - * Generated from protobuf field string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getUid() - { - return $this->uid; - } - - /** - * Output only. System-assigned unique identifier for the CustomClass. - * - * 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; - } - - /** - * Optional. User-settable, human-readable name for the CustomClass. Must be - * 63 characters or less. - * - * Generated from protobuf field string display_name = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * Optional. User-settable, human-readable name for the CustomClass. Must be - * 63 characters or less. - * - * 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; - } - - /** - * A collection of class items. - * - * Generated from protobuf field repeated .google.cloud.speech.v2.CustomClass.ClassItem items = 5; - * @return RepeatedField<\Google\Cloud\Speech\V2\CustomClass\ClassItem> - */ - public function getItems() - { - return $this->items; - } - - /** - * A collection of class items. - * - * Generated from protobuf field repeated .google.cloud.speech.v2.CustomClass.ClassItem items = 5; - * @param \Google\Cloud\Speech\V2\CustomClass\ClassItem[] $var - * @return $this - */ - public function setItems($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Speech\V2\CustomClass\ClassItem::class); - $this->items = $arr; - - return $this; - } - - /** - * Output only. The CustomClass lifecycle state. - * - * Generated from protobuf field .google.cloud.speech.v2.CustomClass.State state = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Output only. The CustomClass lifecycle state. - * - * Generated from protobuf field .google.cloud.speech.v2.CustomClass.State state = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Speech\V2\CustomClass\State::class); - $this->state = $var; - - return $this; - } - - /** - * Output only. Creation time. - * - * 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. Creation time. - * - * 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. The most recent time this resource was modified. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 7 [(.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 most recent time this resource was modified. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 7 [(.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 time at which this resource was requested for deletion. - * - * Generated from protobuf field .google.protobuf.Timestamp delete_time = 8 [(.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. The time at which this resource was requested for deletion. - * - * Generated from protobuf field .google.protobuf.Timestamp delete_time = 8 [(.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. The time at which this resource will be purged. - * - * Generated from protobuf field .google.protobuf.Timestamp expire_time = 9 [(.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 resource will be purged. - * - * Generated from protobuf field .google.protobuf.Timestamp expire_time = 9 [(.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; - } - - /** - * Optional. Allows users to store small amounts of arbitrary data. - * Both the key and the value must be 63 characters or less each. - * At most 100 annotations. - * - * Generated from protobuf field map annotations = 10 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\MapField - */ - public function getAnnotations() - { - return $this->annotations; - } - - /** - * Optional. Allows users to store small amounts of arbitrary data. - * Both the key and the value must be 63 characters or less each. - * At most 100 annotations. - * - * Generated from protobuf field map annotations = 10 [(.google.api.field_behavior) = OPTIONAL]; - * @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. This checksum is computed by the server based on the value of - * other fields. This may be sent on update, undelete, and delete requests to - * ensure 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. This checksum is computed by the server based on the value of - * other fields. This may be sent on update, undelete, and delete requests to - * ensure 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; - } - - /** - * Output only. Whether or not this CustomClass is in the process of being - * updated. - * - * Generated from protobuf field bool reconciling = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return bool - */ - public function getReconciling() - { - return $this->reconciling; - } - - /** - * Output only. Whether or not this CustomClass is in the process of being - * updated. - * - * Generated from protobuf field bool reconciling = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param bool $var - * @return $this - */ - public function setReconciling($var) - { - GPBUtil::checkBool($var); - $this->reconciling = $var; - - return $this; - } - - /** - * Output only. The [KMS key - * name](https://cloud.google.com/kms/docs/resource-hierarchy#keys) with which - * the CustomClass is encrypted. The expected format is - * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. - * - * Generated from protobuf field string kms_key_name = 13 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { - * @return string - */ - public function getKmsKeyName() - { - return $this->kms_key_name; - } - - /** - * Output only. The [KMS key - * name](https://cloud.google.com/kms/docs/resource-hierarchy#keys) with which - * the CustomClass is encrypted. The expected format is - * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. - * - * Generated from protobuf field string kms_key_name = 13 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setKmsKeyName($var) - { - GPBUtil::checkString($var, True); - $this->kms_key_name = $var; - - return $this; - } - - /** - * Output only. The [KMS key version - * name](https://cloud.google.com/kms/docs/resource-hierarchy#key_versions) - * with which the CustomClass is encrypted. The expected format is - * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}/cryptoKeyVersions/{crypto_key_version}`. - * - * Generated from protobuf field string kms_key_version_name = 14 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { - * @return string - */ - public function getKmsKeyVersionName() - { - return $this->kms_key_version_name; - } - - /** - * Output only. The [KMS key version - * name](https://cloud.google.com/kms/docs/resource-hierarchy#key_versions) - * with which the CustomClass is encrypted. The expected format is - * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}/cryptoKeyVersions/{crypto_key_version}`. - * - * Generated from protobuf field string kms_key_version_name = 14 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setKmsKeyVersionName($var) - { - GPBUtil::checkString($var, True); - $this->kms_key_version_name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CustomClass/ClassItem.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CustomClass/ClassItem.php deleted file mode 100644 index e22137bed692..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CustomClass/ClassItem.php +++ /dev/null @@ -1,67 +0,0 @@ -google.cloud.speech.v2.CustomClass.ClassItem - */ -class ClassItem extends \Google\Protobuf\Internal\Message -{ - /** - * The class item's value. - * - * Generated from protobuf field string value = 1; - */ - protected $value = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $value - * The class item's value. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * The class item's value. - * - * Generated from protobuf field string value = 1; - * @return string - */ - public function getValue() - { - return $this->value; - } - - /** - * The class item's value. - * - * Generated from protobuf field string value = 1; - * @param string $var - * @return $this - */ - public function setValue($var) - { - GPBUtil::checkString($var, True); - $this->value = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CustomClass/State.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CustomClass/State.php deleted file mode 100644 index 07612958ca0f..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CustomClass/State.php +++ /dev/null @@ -1,62 +0,0 @@ -google.cloud.speech.v2.CustomClass.State - */ -class State -{ - /** - * Unspecified state. This is only used/useful for distinguishing - * unset values. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * The normal and active state. - * - * Generated from protobuf enum ACTIVE = 2; - */ - const ACTIVE = 2; - /** - * This CustomClass has been deleted. - * - * Generated from protobuf enum DELETED = 4; - */ - const DELETED = 4; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::ACTIVE => 'ACTIVE', - 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); - } -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CustomPromptConfig.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CustomPromptConfig.php deleted file mode 100644 index 182cf73370b0..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/CustomPromptConfig.php +++ /dev/null @@ -1,71 +0,0 @@ -google.cloud.speech.v2.CustomPromptConfig - */ -class CustomPromptConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. The custom instructions to override the existing instructions for - * chirp3. - * - * Generated from protobuf field string custom_prompt = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $custom_prompt = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $custom_prompt - * Optional. The custom instructions to override the existing instructions for - * chirp3. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Optional. The custom instructions to override the existing instructions for - * chirp3. - * - * Generated from protobuf field string custom_prompt = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getCustomPrompt() - { - return $this->custom_prompt; - } - - /** - * Optional. The custom instructions to override the existing instructions for - * chirp3. - * - * Generated from protobuf field string custom_prompt = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setCustomPrompt($var) - { - GPBUtil::checkString($var, True); - $this->custom_prompt = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/DeleteCustomClassRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/DeleteCustomClassRequest.php deleted file mode 100644 index 7017bfe4cfcf..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/DeleteCustomClassRequest.php +++ /dev/null @@ -1,210 +0,0 @@ -google.cloud.speech.v2.DeleteCustomClassRequest - */ -class DeleteCustomClassRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the CustomClass to delete. - * Format: - * `projects/{project}/locations/{location}/customClasses/{custom_class}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * If set, validate the request and preview the deleted CustomClass, but do - * not actually delete it. - * - * Generated from protobuf field bool validate_only = 2; - */ - protected $validate_only = false; - /** - * If set to true, and the CustomClass is not found, the request will succeed - * and be a no-op (no Operation is recorded in this case). - * - * Generated from protobuf field bool allow_missing = 4; - */ - protected $allow_missing = false; - /** - * This checksum is computed by the server based on the value of other - * fields. This may be sent on update, undelete, and delete requests to ensure - * the client has an up-to-date value before proceeding. - * - * Generated from protobuf field string etag = 3; - */ - protected $etag = ''; - - /** - * @param string $name Required. The name of the CustomClass to delete. - * Format: - * `projects/{project}/locations/{location}/customClasses/{custom_class}` - * Please see {@see SpeechClient::customClassName()} for help formatting this field. - * - * @return \Google\Cloud\Speech\V2\DeleteCustomClassRequest - * - * @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 CustomClass to delete. - * Format: - * `projects/{project}/locations/{location}/customClasses/{custom_class}` - * @type bool $validate_only - * If set, validate the request and preview the deleted CustomClass, but do - * not actually delete it. - * @type bool $allow_missing - * If set to true, and the CustomClass is not found, the request will succeed - * and be a no-op (no Operation is recorded in this case). - * @type string $etag - * This checksum is computed by the server based on the value of other - * fields. This may be sent on update, undelete, and delete requests to ensure - * the client has an up-to-date value before proceeding. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the CustomClass to delete. - * Format: - * `projects/{project}/locations/{location}/customClasses/{custom_class}` - * - * 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 CustomClass to delete. - * Format: - * `projects/{project}/locations/{location}/customClasses/{custom_class}` - * - * 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, validate the request and preview the deleted CustomClass, but do - * not actually delete it. - * - * Generated from protobuf field bool validate_only = 2; - * @return bool - */ - public function getValidateOnly() - { - return $this->validate_only; - } - - /** - * If set, validate the request and preview the deleted CustomClass, but do - * not actually delete it. - * - * Generated from protobuf field bool validate_only = 2; - * @param bool $var - * @return $this - */ - public function setValidateOnly($var) - { - GPBUtil::checkBool($var); - $this->validate_only = $var; - - return $this; - } - - /** - * If set to true, and the CustomClass is not found, the request will succeed - * and be a no-op (no Operation is recorded in this case). - * - * Generated from protobuf field bool allow_missing = 4; - * @return bool - */ - public function getAllowMissing() - { - return $this->allow_missing; - } - - /** - * If set to true, and the CustomClass is not found, the request will succeed - * and be a no-op (no Operation is recorded in this case). - * - * Generated from protobuf field bool allow_missing = 4; - * @param bool $var - * @return $this - */ - public function setAllowMissing($var) - { - GPBUtil::checkBool($var); - $this->allow_missing = $var; - - return $this; - } - - /** - * This checksum is computed by the server based on the value of other - * fields. This may be sent on update, undelete, and delete requests to ensure - * the client has an up-to-date value before proceeding. - * - * Generated from protobuf field string etag = 3; - * @return string - */ - public function getEtag() - { - return $this->etag; - } - - /** - * This checksum is computed by the server based on the value of other - * fields. This may be sent on update, undelete, and delete requests to ensure - * the client has an up-to-date value before proceeding. - * - * Generated from protobuf field string etag = 3; - * @param string $var - * @return $this - */ - public function setEtag($var) - { - GPBUtil::checkString($var, True); - $this->etag = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/DeletePhraseSetRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/DeletePhraseSetRequest.php deleted file mode 100644 index cc17160faabc..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/DeletePhraseSetRequest.php +++ /dev/null @@ -1,205 +0,0 @@ -google.cloud.speech.v2.DeletePhraseSetRequest - */ -class DeletePhraseSetRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the PhraseSet to delete. - * Format: `projects/{project}/locations/{location}/phraseSets/{phrase_set}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * If set, validate the request and preview the deleted PhraseSet, but do not - * actually delete it. - * - * Generated from protobuf field bool validate_only = 2; - */ - protected $validate_only = false; - /** - * If set to true, and the PhraseSet is not found, the request will succeed - * and be a no-op (no Operation is recorded in this case). - * - * Generated from protobuf field bool allow_missing = 4; - */ - protected $allow_missing = false; - /** - * This checksum is computed by the server based on the value of other - * fields. This may be sent on update, undelete, and delete requests to ensure - * the client has an up-to-date value before proceeding. - * - * Generated from protobuf field string etag = 3; - */ - protected $etag = ''; - - /** - * @param string $name Required. The name of the PhraseSet to delete. - * Format: `projects/{project}/locations/{location}/phraseSets/{phrase_set}` - * Please see {@see SpeechClient::phraseSetName()} for help formatting this field. - * - * @return \Google\Cloud\Speech\V2\DeletePhraseSetRequest - * - * @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 PhraseSet to delete. - * Format: `projects/{project}/locations/{location}/phraseSets/{phrase_set}` - * @type bool $validate_only - * If set, validate the request and preview the deleted PhraseSet, but do not - * actually delete it. - * @type bool $allow_missing - * If set to true, and the PhraseSet is not found, the request will succeed - * and be a no-op (no Operation is recorded in this case). - * @type string $etag - * This checksum is computed by the server based on the value of other - * fields. This may be sent on update, undelete, and delete requests to ensure - * the client has an up-to-date value before proceeding. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the PhraseSet to delete. - * Format: `projects/{project}/locations/{location}/phraseSets/{phrase_set}` - * - * 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 PhraseSet to delete. - * Format: `projects/{project}/locations/{location}/phraseSets/{phrase_set}` - * - * 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, validate the request and preview the deleted PhraseSet, but do not - * actually delete it. - * - * Generated from protobuf field bool validate_only = 2; - * @return bool - */ - public function getValidateOnly() - { - return $this->validate_only; - } - - /** - * If set, validate the request and preview the deleted PhraseSet, but do not - * actually delete it. - * - * Generated from protobuf field bool validate_only = 2; - * @param bool $var - * @return $this - */ - public function setValidateOnly($var) - { - GPBUtil::checkBool($var); - $this->validate_only = $var; - - return $this; - } - - /** - * If set to true, and the PhraseSet is not found, the request will succeed - * and be a no-op (no Operation is recorded in this case). - * - * Generated from protobuf field bool allow_missing = 4; - * @return bool - */ - public function getAllowMissing() - { - return $this->allow_missing; - } - - /** - * If set to true, and the PhraseSet is not found, the request will succeed - * and be a no-op (no Operation is recorded in this case). - * - * Generated from protobuf field bool allow_missing = 4; - * @param bool $var - * @return $this - */ - public function setAllowMissing($var) - { - GPBUtil::checkBool($var); - $this->allow_missing = $var; - - return $this; - } - - /** - * This checksum is computed by the server based on the value of other - * fields. This may be sent on update, undelete, and delete requests to ensure - * the client has an up-to-date value before proceeding. - * - * Generated from protobuf field string etag = 3; - * @return string - */ - public function getEtag() - { - return $this->etag; - } - - /** - * This checksum is computed by the server based on the value of other - * fields. This may be sent on update, undelete, and delete requests to ensure - * the client has an up-to-date value before proceeding. - * - * Generated from protobuf field string etag = 3; - * @param string $var - * @return $this - */ - public function setEtag($var) - { - GPBUtil::checkString($var, True); - $this->etag = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/DeleteRecognizerRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/DeleteRecognizerRequest.php deleted file mode 100644 index fa3564d85019..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/DeleteRecognizerRequest.php +++ /dev/null @@ -1,205 +0,0 @@ -google.cloud.speech.v2.DeleteRecognizerRequest - */ -class DeleteRecognizerRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the Recognizer to delete. - * Format: `projects/{project}/locations/{location}/recognizers/{recognizer}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * If set, validate the request and preview the deleted Recognizer, but do not - * actually delete it. - * - * Generated from protobuf field bool validate_only = 2; - */ - protected $validate_only = false; - /** - * If set to true, and the Recognizer is not found, the request will succeed - * and be a no-op (no Operation is recorded in this case). - * - * Generated from protobuf field bool allow_missing = 4; - */ - protected $allow_missing = false; - /** - * This checksum is computed by the server based on the value of other - * fields. This may be sent on update, undelete, and delete requests to ensure - * the client has an up-to-date value before proceeding. - * - * Generated from protobuf field string etag = 3; - */ - protected $etag = ''; - - /** - * @param string $name Required. The name of the Recognizer to delete. - * Format: `projects/{project}/locations/{location}/recognizers/{recognizer}` - * Please see {@see SpeechClient::recognizerName()} for help formatting this field. - * - * @return \Google\Cloud\Speech\V2\DeleteRecognizerRequest - * - * @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 Recognizer to delete. - * Format: `projects/{project}/locations/{location}/recognizers/{recognizer}` - * @type bool $validate_only - * If set, validate the request and preview the deleted Recognizer, but do not - * actually delete it. - * @type bool $allow_missing - * If set to true, and the Recognizer is not found, the request will succeed - * and be a no-op (no Operation is recorded in this case). - * @type string $etag - * This checksum is computed by the server based on the value of other - * fields. This may be sent on update, undelete, and delete requests to ensure - * the client has an up-to-date value before proceeding. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the Recognizer to delete. - * Format: `projects/{project}/locations/{location}/recognizers/{recognizer}` - * - * 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 Recognizer to delete. - * Format: `projects/{project}/locations/{location}/recognizers/{recognizer}` - * - * 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, validate the request and preview the deleted Recognizer, but do not - * actually delete it. - * - * Generated from protobuf field bool validate_only = 2; - * @return bool - */ - public function getValidateOnly() - { - return $this->validate_only; - } - - /** - * If set, validate the request and preview the deleted Recognizer, but do not - * actually delete it. - * - * Generated from protobuf field bool validate_only = 2; - * @param bool $var - * @return $this - */ - public function setValidateOnly($var) - { - GPBUtil::checkBool($var); - $this->validate_only = $var; - - return $this; - } - - /** - * If set to true, and the Recognizer is not found, the request will succeed - * and be a no-op (no Operation is recorded in this case). - * - * Generated from protobuf field bool allow_missing = 4; - * @return bool - */ - public function getAllowMissing() - { - return $this->allow_missing; - } - - /** - * If set to true, and the Recognizer is not found, the request will succeed - * and be a no-op (no Operation is recorded in this case). - * - * Generated from protobuf field bool allow_missing = 4; - * @param bool $var - * @return $this - */ - public function setAllowMissing($var) - { - GPBUtil::checkBool($var); - $this->allow_missing = $var; - - return $this; - } - - /** - * This checksum is computed by the server based on the value of other - * fields. This may be sent on update, undelete, and delete requests to ensure - * the client has an up-to-date value before proceeding. - * - * Generated from protobuf field string etag = 3; - * @return string - */ - public function getEtag() - { - return $this->etag; - } - - /** - * This checksum is computed by the server based on the value of other - * fields. This may be sent on update, undelete, and delete requests to ensure - * the client has an up-to-date value before proceeding. - * - * Generated from protobuf field string etag = 3; - * @param string $var - * @return $this - */ - public function setEtag($var) - { - GPBUtil::checkString($var, True); - $this->etag = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/DenoiserConfig.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/DenoiserConfig.php deleted file mode 100644 index 7c384f363d6e..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/DenoiserConfig.php +++ /dev/null @@ -1,118 +0,0 @@ -google.cloud.speech.v2.DenoiserConfig - */ -class DenoiserConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Denoise audio before sending to the transcription model. - * - * Generated from protobuf field bool denoise_audio = 1; - */ - protected $denoise_audio = false; - /** - * Signal-to-Noise Ratio (SNR) threshold for the denoiser. Here SNR means the - * loudness of the speech signal. Audio with an SNR below this threshold, - * meaning the speech is too quiet, will be prevented from being sent to the - * transcription model. - * If snr_threshold=0, no filtering will be applied. - * - * Generated from protobuf field float snr_threshold = 2; - */ - protected $snr_threshold = 0.0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type bool $denoise_audio - * Denoise audio before sending to the transcription model. - * @type float $snr_threshold - * Signal-to-Noise Ratio (SNR) threshold for the denoiser. Here SNR means the - * loudness of the speech signal. Audio with an SNR below this threshold, - * meaning the speech is too quiet, will be prevented from being sent to the - * transcription model. - * If snr_threshold=0, no filtering will be applied. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Denoise audio before sending to the transcription model. - * - * Generated from protobuf field bool denoise_audio = 1; - * @return bool - */ - public function getDenoiseAudio() - { - return $this->denoise_audio; - } - - /** - * Denoise audio before sending to the transcription model. - * - * Generated from protobuf field bool denoise_audio = 1; - * @param bool $var - * @return $this - */ - public function setDenoiseAudio($var) - { - GPBUtil::checkBool($var); - $this->denoise_audio = $var; - - return $this; - } - - /** - * Signal-to-Noise Ratio (SNR) threshold for the denoiser. Here SNR means the - * loudness of the speech signal. Audio with an SNR below this threshold, - * meaning the speech is too quiet, will be prevented from being sent to the - * transcription model. - * If snr_threshold=0, no filtering will be applied. - * - * Generated from protobuf field float snr_threshold = 2; - * @return float - */ - public function getSnrThreshold() - { - return $this->snr_threshold; - } - - /** - * Signal-to-Noise Ratio (SNR) threshold for the denoiser. Here SNR means the - * loudness of the speech signal. Audio with an SNR below this threshold, - * meaning the speech is too quiet, will be prevented from being sent to the - * transcription model. - * If snr_threshold=0, no filtering will be applied. - * - * Generated from protobuf field float snr_threshold = 2; - * @param float $var - * @return $this - */ - public function setSnrThreshold($var) - { - GPBUtil::checkFloat($var); - $this->snr_threshold = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ExplicitDecodingConfig.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ExplicitDecodingConfig.php deleted file mode 100644 index 9eccc86ac02b..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ExplicitDecodingConfig.php +++ /dev/null @@ -1,167 +0,0 @@ -google.cloud.speech.v2.ExplicitDecodingConfig - */ -class ExplicitDecodingConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Encoding of the audio data sent for recognition. - * - * Generated from protobuf field .google.cloud.speech.v2.ExplicitDecodingConfig.AudioEncoding encoding = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $encoding = 0; - /** - * Optional. Sample rate in Hertz of the audio data sent for recognition. - * Valid values are: 8000-48000, and 16000 is optimal. For best results, set - * the sampling rate of the audio source to 16000 Hz. If that's not possible, - * use the native sample rate of the audio source (instead of resampling). - * Note that this field is marked as OPTIONAL for backward compatibility - * reasons. It is (and has always been) effectively REQUIRED. - * - * Generated from protobuf field int32 sample_rate_hertz = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $sample_rate_hertz = 0; - /** - * Optional. Number of channels present in the audio data sent for - * recognition. Note that this field is marked as OPTIONAL for backward - * compatibility reasons. It is (and has always been) effectively REQUIRED. - * The maximum allowed value is 8. - * - * Generated from protobuf field int32 audio_channel_count = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $audio_channel_count = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $encoding - * Required. Encoding of the audio data sent for recognition. - * @type int $sample_rate_hertz - * Optional. Sample rate in Hertz of the audio data sent for recognition. - * Valid values are: 8000-48000, and 16000 is optimal. For best results, set - * the sampling rate of the audio source to 16000 Hz. If that's not possible, - * use the native sample rate of the audio source (instead of resampling). - * Note that this field is marked as OPTIONAL for backward compatibility - * reasons. It is (and has always been) effectively REQUIRED. - * @type int $audio_channel_count - * Optional. Number of channels present in the audio data sent for - * recognition. Note that this field is marked as OPTIONAL for backward - * compatibility reasons. It is (and has always been) effectively REQUIRED. - * The maximum allowed value is 8. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Required. Encoding of the audio data sent for recognition. - * - * Generated from protobuf field .google.cloud.speech.v2.ExplicitDecodingConfig.AudioEncoding encoding = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getEncoding() - { - return $this->encoding; - } - - /** - * Required. Encoding of the audio data sent for recognition. - * - * Generated from protobuf field .google.cloud.speech.v2.ExplicitDecodingConfig.AudioEncoding encoding = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setEncoding($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Speech\V2\ExplicitDecodingConfig\AudioEncoding::class); - $this->encoding = $var; - - return $this; - } - - /** - * Optional. Sample rate in Hertz of the audio data sent for recognition. - * Valid values are: 8000-48000, and 16000 is optimal. For best results, set - * the sampling rate of the audio source to 16000 Hz. If that's not possible, - * use the native sample rate of the audio source (instead of resampling). - * Note that this field is marked as OPTIONAL for backward compatibility - * reasons. It is (and has always been) effectively REQUIRED. - * - * Generated from protobuf field int32 sample_rate_hertz = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getSampleRateHertz() - { - return $this->sample_rate_hertz; - } - - /** - * Optional. Sample rate in Hertz of the audio data sent for recognition. - * Valid values are: 8000-48000, and 16000 is optimal. For best results, set - * the sampling rate of the audio source to 16000 Hz. If that's not possible, - * use the native sample rate of the audio source (instead of resampling). - * Note that this field is marked as OPTIONAL for backward compatibility - * reasons. It is (and has always been) effectively REQUIRED. - * - * Generated from protobuf field int32 sample_rate_hertz = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setSampleRateHertz($var) - { - GPBUtil::checkInt32($var); - $this->sample_rate_hertz = $var; - - return $this; - } - - /** - * Optional. Number of channels present in the audio data sent for - * recognition. Note that this field is marked as OPTIONAL for backward - * compatibility reasons. It is (and has always been) effectively REQUIRED. - * The maximum allowed value is 8. - * - * Generated from protobuf field int32 audio_channel_count = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getAudioChannelCount() - { - return $this->audio_channel_count; - } - - /** - * Optional. Number of channels present in the audio data sent for - * recognition. Note that this field is marked as OPTIONAL for backward - * compatibility reasons. It is (and has always been) effectively REQUIRED. - * The maximum allowed value is 8. - * - * Generated from protobuf field int32 audio_channel_count = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setAudioChannelCount($var) - { - GPBUtil::checkInt32($var); - $this->audio_channel_count = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ExplicitDecodingConfig/AudioEncoding.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ExplicitDecodingConfig/AudioEncoding.php deleted file mode 100644 index 48bc6ce0950c..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ExplicitDecodingConfig/AudioEncoding.php +++ /dev/null @@ -1,131 +0,0 @@ -google.cloud.speech.v2.ExplicitDecodingConfig.AudioEncoding - */ -class AudioEncoding -{ - /** - * Default value. This value is unused. - * - * Generated from protobuf enum AUDIO_ENCODING_UNSPECIFIED = 0; - */ - const AUDIO_ENCODING_UNSPECIFIED = 0; - /** - * Headerless 16-bit signed little-endian PCM samples. - * - * Generated from protobuf enum LINEAR16 = 1; - */ - const LINEAR16 = 1; - /** - * Headerless 8-bit companded mulaw samples. - * - * Generated from protobuf enum MULAW = 2; - */ - const MULAW = 2; - /** - * Headerless 8-bit companded alaw samples. - * - * Generated from protobuf enum ALAW = 3; - */ - const ALAW = 3; - /** - * AMR frames with an rfc4867.5 header. - * - * Generated from protobuf enum AMR = 4; - */ - const AMR = 4; - /** - * AMR-WB frames with an rfc4867.5 header. - * - * Generated from protobuf enum AMR_WB = 5; - */ - const AMR_WB = 5; - /** - * FLAC frames in the "native FLAC" container format. - * - * Generated from protobuf enum FLAC = 6; - */ - const FLAC = 6; - /** - * MPEG audio frames with optional (ignored) ID3 metadata. - * - * Generated from protobuf enum MP3 = 7; - */ - const MP3 = 7; - /** - * Opus audio frames in an Ogg container. - * - * Generated from protobuf enum OGG_OPUS = 8; - */ - const OGG_OPUS = 8; - /** - * Opus audio frames in a WebM container. - * - * Generated from protobuf enum WEBM_OPUS = 9; - */ - const WEBM_OPUS = 9; - /** - * AAC audio frames in an MP4 container. - * - * Generated from protobuf enum MP4_AAC = 10; - */ - const MP4_AAC = 10; - /** - * AAC audio frames in an M4A container. - * - * Generated from protobuf enum M4A_AAC = 11; - */ - const M4A_AAC = 11; - /** - * AAC audio frames in an MOV container. - * - * Generated from protobuf enum MOV_AAC = 12; - */ - const MOV_AAC = 12; - - private static $valueToName = [ - self::AUDIO_ENCODING_UNSPECIFIED => 'AUDIO_ENCODING_UNSPECIFIED', - self::LINEAR16 => 'LINEAR16', - self::MULAW => 'MULAW', - self::ALAW => 'ALAW', - self::AMR => 'AMR', - self::AMR_WB => 'AMR_WB', - self::FLAC => 'FLAC', - self::MP3 => 'MP3', - self::OGG_OPUS => 'OGG_OPUS', - self::WEBM_OPUS => 'WEBM_OPUS', - self::MP4_AAC => 'MP4_AAC', - self::M4A_AAC => 'M4A_AAC', - self::MOV_AAC => 'MOV_AAC', - ]; - - 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/Speech/v2/proto/src/Google/Cloud/Speech/V2/GcsOutputConfig.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/GcsOutputConfig.php deleted file mode 100644 index 25fa8b2bd1d9..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/GcsOutputConfig.php +++ /dev/null @@ -1,71 +0,0 @@ -google.cloud.speech.v2.GcsOutputConfig - */ -class GcsOutputConfig extends \Google\Protobuf\Internal\Message -{ - /** - * The Cloud Storage URI prefix with which recognition results will be - * written. - * - * Generated from protobuf field string uri = 1; - */ - protected $uri = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $uri - * The Cloud Storage URI prefix with which recognition results will be - * written. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * The Cloud Storage URI prefix with which recognition results will be - * written. - * - * Generated from protobuf field string uri = 1; - * @return string - */ - public function getUri() - { - return $this->uri; - } - - /** - * The Cloud Storage URI prefix with which recognition results will be - * written. - * - * 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; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/GetConfigRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/GetConfigRequest.php deleted file mode 100644 index c5f17826a4f9..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/GetConfigRequest.php +++ /dev/null @@ -1,92 +0,0 @@ -google.cloud.speech.v2.GetConfigRequest - */ -class GetConfigRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the config to retrieve. There is exactly one config - * resource per project per location. The expected format is - * `projects/{project}/locations/{location}/config`. - * - * 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 config to retrieve. There is exactly one config - * resource per project per location. The expected format is - * `projects/{project}/locations/{location}/config`. Please see - * {@see SpeechClient::configName()} for help formatting this field. - * - * @return \Google\Cloud\Speech\V2\GetConfigRequest - * - * @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 config to retrieve. There is exactly one config - * resource per project per location. The expected format is - * `projects/{project}/locations/{location}/config`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the config to retrieve. There is exactly one config - * resource per project per location. The expected format is - * `projects/{project}/locations/{location}/config`. - * - * 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 config to retrieve. There is exactly one config - * resource per project per location. The expected format is - * `projects/{project}/locations/{location}/config`. - * - * 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/Speech/v2/proto/src/Google/Cloud/Speech/V2/GetCustomClassRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/GetCustomClassRequest.php deleted file mode 100644 index 08f98671cf7a..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/GetCustomClassRequest.php +++ /dev/null @@ -1,87 +0,0 @@ -google.cloud.speech.v2.GetCustomClassRequest - */ -class GetCustomClassRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the CustomClass to retrieve. The expected format is - * `projects/{project}/locations/{location}/customClasses/{custom_class}`. - * - * 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 CustomClass to retrieve. The expected format is - * `projects/{project}/locations/{location}/customClasses/{custom_class}`. Please see - * {@see SpeechClient::customClassName()} for help formatting this field. - * - * @return \Google\Cloud\Speech\V2\GetCustomClassRequest - * - * @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 CustomClass to retrieve. The expected format is - * `projects/{project}/locations/{location}/customClasses/{custom_class}`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the CustomClass to retrieve. The expected format is - * `projects/{project}/locations/{location}/customClasses/{custom_class}`. - * - * 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 CustomClass to retrieve. The expected format is - * `projects/{project}/locations/{location}/customClasses/{custom_class}`. - * - * 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/Speech/v2/proto/src/Google/Cloud/Speech/V2/GetPhraseSetRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/GetPhraseSetRequest.php deleted file mode 100644 index c9026b85bc8d..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/GetPhraseSetRequest.php +++ /dev/null @@ -1,87 +0,0 @@ -google.cloud.speech.v2.GetPhraseSetRequest - */ -class GetPhraseSetRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the PhraseSet to retrieve. The expected format is - * `projects/{project}/locations/{location}/phraseSets/{phrase_set}`. - * - * 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 PhraseSet to retrieve. The expected format is - * `projects/{project}/locations/{location}/phraseSets/{phrase_set}`. Please see - * {@see SpeechClient::phraseSetName()} for help formatting this field. - * - * @return \Google\Cloud\Speech\V2\GetPhraseSetRequest - * - * @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 PhraseSet to retrieve. The expected format is - * `projects/{project}/locations/{location}/phraseSets/{phrase_set}`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the PhraseSet to retrieve. The expected format is - * `projects/{project}/locations/{location}/phraseSets/{phrase_set}`. - * - * 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 PhraseSet to retrieve. The expected format is - * `projects/{project}/locations/{location}/phraseSets/{phrase_set}`. - * - * 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/Speech/v2/proto/src/Google/Cloud/Speech/V2/GetRecognizerRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/GetRecognizerRequest.php deleted file mode 100644 index 1354b86ebb1f..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/GetRecognizerRequest.php +++ /dev/null @@ -1,87 +0,0 @@ -google.cloud.speech.v2.GetRecognizerRequest - */ -class GetRecognizerRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the Recognizer to retrieve. The expected format is - * `projects/{project}/locations/{location}/recognizers/{recognizer}`. - * - * 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 Recognizer to retrieve. The expected format is - * `projects/{project}/locations/{location}/recognizers/{recognizer}`. Please see - * {@see SpeechClient::recognizerName()} for help formatting this field. - * - * @return \Google\Cloud\Speech\V2\GetRecognizerRequest - * - * @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 Recognizer to retrieve. The expected format is - * `projects/{project}/locations/{location}/recognizers/{recognizer}`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the Recognizer to retrieve. The expected format is - * `projects/{project}/locations/{location}/recognizers/{recognizer}`. - * - * 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 Recognizer to retrieve. The expected format is - * `projects/{project}/locations/{location}/recognizers/{recognizer}`. - * - * 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/Speech/v2/proto/src/Google/Cloud/Speech/V2/InlineOutputConfig.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/InlineOutputConfig.php deleted file mode 100644 index a938828e68d7..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/InlineOutputConfig.php +++ /dev/null @@ -1,33 +0,0 @@ -google.cloud.speech.v2.InlineOutputConfig - */ -class InlineOutputConfig extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/InlineResult.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/InlineResult.php deleted file mode 100644 index 54e5635ac508..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/InlineResult.php +++ /dev/null @@ -1,153 +0,0 @@ -google.cloud.speech.v2.InlineResult - */ -class InlineResult extends \Google\Protobuf\Internal\Message -{ - /** - * The transcript for the audio file. - * - * Generated from protobuf field .google.cloud.speech.v2.BatchRecognizeResults transcript = 1; - */ - protected $transcript = null; - /** - * The transcript for the audio file as VTT formatted captions. This is - * populated only when `VTT` output is requested. - * - * Generated from protobuf field string vtt_captions = 2; - */ - protected $vtt_captions = ''; - /** - * The transcript for the audio file as SRT formatted captions. This is - * populated only when `SRT` output is requested. - * - * Generated from protobuf field string srt_captions = 3; - */ - protected $srt_captions = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Speech\V2\BatchRecognizeResults $transcript - * The transcript for the audio file. - * @type string $vtt_captions - * The transcript for the audio file as VTT formatted captions. This is - * populated only when `VTT` output is requested. - * @type string $srt_captions - * The transcript for the audio file as SRT formatted captions. This is - * populated only when `SRT` output is requested. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * The transcript for the audio file. - * - * Generated from protobuf field .google.cloud.speech.v2.BatchRecognizeResults transcript = 1; - * @return \Google\Cloud\Speech\V2\BatchRecognizeResults|null - */ - public function getTranscript() - { - return $this->transcript; - } - - public function hasTranscript() - { - return isset($this->transcript); - } - - public function clearTranscript() - { - unset($this->transcript); - } - - /** - * The transcript for the audio file. - * - * Generated from protobuf field .google.cloud.speech.v2.BatchRecognizeResults transcript = 1; - * @param \Google\Cloud\Speech\V2\BatchRecognizeResults $var - * @return $this - */ - public function setTranscript($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\BatchRecognizeResults::class); - $this->transcript = $var; - - return $this; - } - - /** - * The transcript for the audio file as VTT formatted captions. This is - * populated only when `VTT` output is requested. - * - * Generated from protobuf field string vtt_captions = 2; - * @return string - */ - public function getVttCaptions() - { - return $this->vtt_captions; - } - - /** - * The transcript for the audio file as VTT formatted captions. This is - * populated only when `VTT` output is requested. - * - * Generated from protobuf field string vtt_captions = 2; - * @param string $var - * @return $this - */ - public function setVttCaptions($var) - { - GPBUtil::checkString($var, True); - $this->vtt_captions = $var; - - return $this; - } - - /** - * The transcript for the audio file as SRT formatted captions. This is - * populated only when `SRT` output is requested. - * - * Generated from protobuf field string srt_captions = 3; - * @return string - */ - public function getSrtCaptions() - { - return $this->srt_captions; - } - - /** - * The transcript for the audio file as SRT formatted captions. This is - * populated only when `SRT` output is requested. - * - * Generated from protobuf field string srt_captions = 3; - * @param string $var - * @return $this - */ - public function setSrtCaptions($var) - { - GPBUtil::checkString($var, True); - $this->srt_captions = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/LanguageMetadata.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/LanguageMetadata.php deleted file mode 100644 index 4b4e79d1cf4b..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/LanguageMetadata.php +++ /dev/null @@ -1,68 +0,0 @@ -google.cloud.speech.v2.LanguageMetadata - */ -class LanguageMetadata extends \Google\Protobuf\Internal\Message -{ - /** - * Map of locale (language code) -> models - * - * Generated from protobuf field map models = 1; - */ - private $models; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\MapField $models - * Map of locale (language code) -> models - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\LocationsMetadata::initOnce(); - parent::__construct($data); - } - - /** - * Map of locale (language code) -> models - * - * Generated from protobuf field map models = 1; - * @return \Google\Protobuf\Internal\MapField - */ - public function getModels() - { - return $this->models; - } - - /** - * Map of locale (language code) -> models - * - * Generated from protobuf field map models = 1; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setModels($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Speech\V2\ModelMetadata::class); - $this->models = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListCustomClassesRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListCustomClassesRequest.php deleted file mode 100644 index 4cb52ef136a0..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListCustomClassesRequest.php +++ /dev/null @@ -1,221 +0,0 @@ -google.cloud.speech.v2.ListCustomClassesRequest - */ -class ListCustomClassesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The project and location of CustomClass resources to list. The - * expected format is `projects/{project}/locations/{location}`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Number of results per requests. A valid page_size ranges from 0 to 100 - * inclusive. If the page_size is zero or unspecified, a page size of 5 will - * be chosen. If the page size exceeds 100, it will be coerced down to 100. - * Note that a call might return fewer results than the requested page size. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * A page token, received from a previous - * [ListCustomClasses][google.cloud.speech.v2.Speech.ListCustomClasses] call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * [ListCustomClasses][google.cloud.speech.v2.Speech.ListCustomClasses] must - * match the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - /** - * Whether, or not, to show resources that have been deleted. - * - * Generated from protobuf field bool show_deleted = 4; - */ - protected $show_deleted = false; - - /** - * @param string $parent Required. The project and location of CustomClass resources to list. The - * expected format is `projects/{project}/locations/{location}`. Please see - * {@see SpeechClient::locationName()} for help formatting this field. - * - * @return \Google\Cloud\Speech\V2\ListCustomClassesRequest - * - * @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 CustomClass resources to list. The - * expected format is `projects/{project}/locations/{location}`. - * @type int $page_size - * Number of results per requests. A valid page_size ranges from 0 to 100 - * inclusive. If the page_size is zero or unspecified, a page size of 5 will - * be chosen. If the page size exceeds 100, it will be coerced down to 100. - * Note that a call might return fewer results than the requested page size. - * @type string $page_token - * A page token, received from a previous - * [ListCustomClasses][google.cloud.speech.v2.Speech.ListCustomClasses] call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * [ListCustomClasses][google.cloud.speech.v2.Speech.ListCustomClasses] must - * match the call that provided the page token. - * @type bool $show_deleted - * Whether, or not, to show resources that have been deleted. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Required. The project and location of CustomClass resources to list. The - * expected format is `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 of CustomClass resources to list. The - * expected format is `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; - } - - /** - * Number of results per requests. A valid page_size ranges from 0 to 100 - * inclusive. If the page_size is zero or unspecified, a page size of 5 will - * be chosen. If the page size exceeds 100, it will be coerced down to 100. - * Note that a call might return fewer results than the requested page size. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Number of results per requests. A valid page_size ranges from 0 to 100 - * inclusive. If the page_size is zero or unspecified, a page size of 5 will - * be chosen. If the page size exceeds 100, it will be coerced down to 100. - * Note that a call might return fewer results than the requested 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; - } - - /** - * A page token, received from a previous - * [ListCustomClasses][google.cloud.speech.v2.Speech.ListCustomClasses] call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * [ListCustomClasses][google.cloud.speech.v2.Speech.ListCustomClasses] 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 - * [ListCustomClasses][google.cloud.speech.v2.Speech.ListCustomClasses] call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * [ListCustomClasses][google.cloud.speech.v2.Speech.ListCustomClasses] 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; - } - - /** - * Whether, or not, to show resources that have been deleted. - * - * Generated from protobuf field bool show_deleted = 4; - * @return bool - */ - public function getShowDeleted() - { - return $this->show_deleted; - } - - /** - * Whether, or not, to show resources that have been deleted. - * - * Generated from protobuf field bool show_deleted = 4; - * @param bool $var - * @return $this - */ - public function setShowDeleted($var) - { - GPBUtil::checkBool($var); - $this->show_deleted = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListCustomClassesResponse.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListCustomClassesResponse.php deleted file mode 100644 index 77814cc3dd35..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListCustomClassesResponse.php +++ /dev/null @@ -1,114 +0,0 @@ -google.cloud.speech.v2.ListCustomClassesResponse - */ -class ListCustomClassesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The list of requested CustomClasses. - * - * Generated from protobuf field repeated .google.cloud.speech.v2.CustomClass custom_classes = 1; - */ - private $custom_classes; - /** - * A token, which can be sent as - * [page_token][google.cloud.speech.v2.ListCustomClassesRequest.page_token] to - * retrieve the next page. If this field is omitted, there are no subsequent - * pages. This token expires after 72 hours. - * - * 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 \Google\Cloud\Speech\V2\CustomClass[] $custom_classes - * The list of requested CustomClasses. - * @type string $next_page_token - * A token, which can be sent as - * [page_token][google.cloud.speech.v2.ListCustomClassesRequest.page_token] to - * retrieve the next page. If this field is omitted, there are no subsequent - * pages. This token expires after 72 hours. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * The list of requested CustomClasses. - * - * Generated from protobuf field repeated .google.cloud.speech.v2.CustomClass custom_classes = 1; - * @return RepeatedField<\Google\Cloud\Speech\V2\CustomClass> - */ - public function getCustomClasses() - { - return $this->custom_classes; - } - - /** - * The list of requested CustomClasses. - * - * Generated from protobuf field repeated .google.cloud.speech.v2.CustomClass custom_classes = 1; - * @param \Google\Cloud\Speech\V2\CustomClass[] $var - * @return $this - */ - public function setCustomClasses($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Speech\V2\CustomClass::class); - $this->custom_classes = $arr; - - return $this; - } - - /** - * A token, which can be sent as - * [page_token][google.cloud.speech.v2.ListCustomClassesRequest.page_token] to - * retrieve the next page. If this field is omitted, there are no subsequent - * pages. This token expires after 72 hours. - * - * 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][google.cloud.speech.v2.ListCustomClassesRequest.page_token] to - * retrieve the next page. If this field is omitted, there are no subsequent - * pages. This token expires after 72 hours. - * - * 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/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListPhraseSetsRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListPhraseSetsRequest.php deleted file mode 100644 index 56b81259bf6c..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListPhraseSetsRequest.php +++ /dev/null @@ -1,217 +0,0 @@ -google.cloud.speech.v2.ListPhraseSetsRequest - */ -class ListPhraseSetsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The project and location of PhraseSet resources to list. The - * expected format is `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 PhraseSets to return. The service may return fewer - * than this value. If unspecified, at most 5 PhraseSets will be returned. - * The maximum value is 100; values above 100 will be coerced to 100. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * A page token, received from a previous - * [ListPhraseSets][google.cloud.speech.v2.Speech.ListPhraseSets] call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * [ListPhraseSets][google.cloud.speech.v2.Speech.ListPhraseSets] must match - * the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - /** - * Whether, or not, to show resources that have been deleted. - * - * Generated from protobuf field bool show_deleted = 4; - */ - protected $show_deleted = false; - - /** - * @param string $parent Required. The project and location of PhraseSet resources to list. The - * expected format is `projects/{project}/locations/{location}`. Please see - * {@see SpeechClient::locationName()} for help formatting this field. - * - * @return \Google\Cloud\Speech\V2\ListPhraseSetsRequest - * - * @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 PhraseSet resources to list. The - * expected format is `projects/{project}/locations/{location}`. - * @type int $page_size - * The maximum number of PhraseSets to return. The service may return fewer - * than this value. If unspecified, at most 5 PhraseSets will be returned. - * The maximum value is 100; values above 100 will be coerced to 100. - * @type string $page_token - * A page token, received from a previous - * [ListPhraseSets][google.cloud.speech.v2.Speech.ListPhraseSets] call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * [ListPhraseSets][google.cloud.speech.v2.Speech.ListPhraseSets] must match - * the call that provided the page token. - * @type bool $show_deleted - * Whether, or not, to show resources that have been deleted. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Required. The project and location of PhraseSet resources to list. The - * expected format is `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 of PhraseSet resources to list. The - * expected format is `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 PhraseSets to return. The service may return fewer - * than this value. If unspecified, at most 5 PhraseSets will be returned. - * The maximum value is 100; values above 100 will be coerced to 100. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of PhraseSets to return. The service may return fewer - * than this value. If unspecified, at most 5 PhraseSets will be returned. - * The maximum value is 100; values above 100 will be coerced 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; - } - - /** - * A page token, received from a previous - * [ListPhraseSets][google.cloud.speech.v2.Speech.ListPhraseSets] call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * [ListPhraseSets][google.cloud.speech.v2.Speech.ListPhraseSets] 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 - * [ListPhraseSets][google.cloud.speech.v2.Speech.ListPhraseSets] call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * [ListPhraseSets][google.cloud.speech.v2.Speech.ListPhraseSets] 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; - } - - /** - * Whether, or not, to show resources that have been deleted. - * - * Generated from protobuf field bool show_deleted = 4; - * @return bool - */ - public function getShowDeleted() - { - return $this->show_deleted; - } - - /** - * Whether, or not, to show resources that have been deleted. - * - * Generated from protobuf field bool show_deleted = 4; - * @param bool $var - * @return $this - */ - public function setShowDeleted($var) - { - GPBUtil::checkBool($var); - $this->show_deleted = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListPhraseSetsResponse.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListPhraseSetsResponse.php deleted file mode 100644 index 7a088dc8f8c9..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListPhraseSetsResponse.php +++ /dev/null @@ -1,114 +0,0 @@ -google.cloud.speech.v2.ListPhraseSetsResponse - */ -class ListPhraseSetsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The list of requested PhraseSets. - * - * Generated from protobuf field repeated .google.cloud.speech.v2.PhraseSet phrase_sets = 1; - */ - private $phrase_sets; - /** - * A token, which can be sent as - * [page_token][google.cloud.speech.v2.ListPhraseSetsRequest.page_token] to - * retrieve the next page. If this field is omitted, there are no subsequent - * pages. This token expires after 72 hours. - * - * 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 \Google\Cloud\Speech\V2\PhraseSet[] $phrase_sets - * The list of requested PhraseSets. - * @type string $next_page_token - * A token, which can be sent as - * [page_token][google.cloud.speech.v2.ListPhraseSetsRequest.page_token] to - * retrieve the next page. If this field is omitted, there are no subsequent - * pages. This token expires after 72 hours. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * The list of requested PhraseSets. - * - * Generated from protobuf field repeated .google.cloud.speech.v2.PhraseSet phrase_sets = 1; - * @return RepeatedField<\Google\Cloud\Speech\V2\PhraseSet> - */ - public function getPhraseSets() - { - return $this->phrase_sets; - } - - /** - * The list of requested PhraseSets. - * - * Generated from protobuf field repeated .google.cloud.speech.v2.PhraseSet phrase_sets = 1; - * @param \Google\Cloud\Speech\V2\PhraseSet[] $var - * @return $this - */ - public function setPhraseSets($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Speech\V2\PhraseSet::class); - $this->phrase_sets = $arr; - - return $this; - } - - /** - * A token, which can be sent as - * [page_token][google.cloud.speech.v2.ListPhraseSetsRequest.page_token] to - * retrieve the next page. If this field is omitted, there are no subsequent - * pages. This token expires after 72 hours. - * - * 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][google.cloud.speech.v2.ListPhraseSetsRequest.page_token] to - * retrieve the next page. If this field is omitted, there are no subsequent - * pages. This token expires after 72 hours. - * - * 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/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListRecognizersRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListRecognizersRequest.php deleted file mode 100644 index c3f35333b9ec..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListRecognizersRequest.php +++ /dev/null @@ -1,217 +0,0 @@ -google.cloud.speech.v2.ListRecognizersRequest - */ -class ListRecognizersRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The project and location of Recognizers to list. The expected - * format is `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 Recognizers to return. The service may return fewer - * than this value. If unspecified, at most 5 Recognizers will be returned. - * The maximum value is 100; values above 100 will be coerced to 100. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * A page token, received from a previous - * [ListRecognizers][google.cloud.speech.v2.Speech.ListRecognizers] call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * [ListRecognizers][google.cloud.speech.v2.Speech.ListRecognizers] must match - * the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - /** - * Whether, or not, to show resources that have been deleted. - * - * Generated from protobuf field bool show_deleted = 4; - */ - protected $show_deleted = false; - - /** - * @param string $parent Required. The project and location of Recognizers to list. The expected - * format is `projects/{project}/locations/{location}`. Please see - * {@see SpeechClient::locationName()} for help formatting this field. - * - * @return \Google\Cloud\Speech\V2\ListRecognizersRequest - * - * @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 Recognizers to list. The expected - * format is `projects/{project}/locations/{location}`. - * @type int $page_size - * The maximum number of Recognizers to return. The service may return fewer - * than this value. If unspecified, at most 5 Recognizers will be returned. - * The maximum value is 100; values above 100 will be coerced to 100. - * @type string $page_token - * A page token, received from a previous - * [ListRecognizers][google.cloud.speech.v2.Speech.ListRecognizers] call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * [ListRecognizers][google.cloud.speech.v2.Speech.ListRecognizers] must match - * the call that provided the page token. - * @type bool $show_deleted - * Whether, or not, to show resources that have been deleted. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Required. The project and location of Recognizers to list. The expected - * format is `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 of Recognizers to list. The expected - * format is `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 Recognizers to return. The service may return fewer - * than this value. If unspecified, at most 5 Recognizers will be returned. - * The maximum value is 100; values above 100 will be coerced to 100. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of Recognizers to return. The service may return fewer - * than this value. If unspecified, at most 5 Recognizers will be returned. - * The maximum value is 100; values above 100 will be coerced 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; - } - - /** - * A page token, received from a previous - * [ListRecognizers][google.cloud.speech.v2.Speech.ListRecognizers] call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * [ListRecognizers][google.cloud.speech.v2.Speech.ListRecognizers] 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 - * [ListRecognizers][google.cloud.speech.v2.Speech.ListRecognizers] call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * [ListRecognizers][google.cloud.speech.v2.Speech.ListRecognizers] 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; - } - - /** - * Whether, or not, to show resources that have been deleted. - * - * Generated from protobuf field bool show_deleted = 4; - * @return bool - */ - public function getShowDeleted() - { - return $this->show_deleted; - } - - /** - * Whether, or not, to show resources that have been deleted. - * - * Generated from protobuf field bool show_deleted = 4; - * @param bool $var - * @return $this - */ - public function setShowDeleted($var) - { - GPBUtil::checkBool($var); - $this->show_deleted = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListRecognizersResponse.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListRecognizersResponse.php deleted file mode 100644 index 18e076469df5..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ListRecognizersResponse.php +++ /dev/null @@ -1,114 +0,0 @@ -google.cloud.speech.v2.ListRecognizersResponse - */ -class ListRecognizersResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The list of requested Recognizers. - * - * Generated from protobuf field repeated .google.cloud.speech.v2.Recognizer recognizers = 1; - */ - private $recognizers; - /** - * A token, which can be sent as - * [page_token][google.cloud.speech.v2.ListRecognizersRequest.page_token] to - * retrieve the next page. If this field is omitted, there are no subsequent - * pages. This token expires after 72 hours. - * - * 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 \Google\Cloud\Speech\V2\Recognizer[] $recognizers - * The list of requested Recognizers. - * @type string $next_page_token - * A token, which can be sent as - * [page_token][google.cloud.speech.v2.ListRecognizersRequest.page_token] to - * retrieve the next page. If this field is omitted, there are no subsequent - * pages. This token expires after 72 hours. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * The list of requested Recognizers. - * - * Generated from protobuf field repeated .google.cloud.speech.v2.Recognizer recognizers = 1; - * @return RepeatedField<\Google\Cloud\Speech\V2\Recognizer> - */ - public function getRecognizers() - { - return $this->recognizers; - } - - /** - * The list of requested Recognizers. - * - * Generated from protobuf field repeated .google.cloud.speech.v2.Recognizer recognizers = 1; - * @param \Google\Cloud\Speech\V2\Recognizer[] $var - * @return $this - */ - public function setRecognizers($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Speech\V2\Recognizer::class); - $this->recognizers = $arr; - - return $this; - } - - /** - * A token, which can be sent as - * [page_token][google.cloud.speech.v2.ListRecognizersRequest.page_token] to - * retrieve the next page. If this field is omitted, there are no subsequent - * pages. This token expires after 72 hours. - * - * 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][google.cloud.speech.v2.ListRecognizersRequest.page_token] to - * retrieve the next page. If this field is omitted, there are no subsequent - * pages. This token expires after 72 hours. - * - * 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/Speech/v2/proto/src/Google/Cloud/Speech/V2/LocationsMetadata.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/LocationsMetadata.php deleted file mode 100644 index cd051e7e965f..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/LocationsMetadata.php +++ /dev/null @@ -1,126 +0,0 @@ -google.cloud.speech.v2.LocationsMetadata - */ -class LocationsMetadata extends \Google\Protobuf\Internal\Message -{ - /** - * Information about available locales, models, and features represented in - * the hierarchical structure of locales -> models -> features - * - * Generated from protobuf field .google.cloud.speech.v2.LanguageMetadata languages = 1; - */ - protected $languages = null; - /** - * Information about access metadata for the region and given project. - * - * Generated from protobuf field .google.cloud.speech.v2.AccessMetadata access_metadata = 2; - */ - protected $access_metadata = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Speech\V2\LanguageMetadata $languages - * Information about available locales, models, and features represented in - * the hierarchical structure of locales -> models -> features - * @type \Google\Cloud\Speech\V2\AccessMetadata $access_metadata - * Information about access metadata for the region and given project. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\LocationsMetadata::initOnce(); - parent::__construct($data); - } - - /** - * Information about available locales, models, and features represented in - * the hierarchical structure of locales -> models -> features - * - * Generated from protobuf field .google.cloud.speech.v2.LanguageMetadata languages = 1; - * @return \Google\Cloud\Speech\V2\LanguageMetadata|null - */ - public function getLanguages() - { - return $this->languages; - } - - public function hasLanguages() - { - return isset($this->languages); - } - - public function clearLanguages() - { - unset($this->languages); - } - - /** - * Information about available locales, models, and features represented in - * the hierarchical structure of locales -> models -> features - * - * Generated from protobuf field .google.cloud.speech.v2.LanguageMetadata languages = 1; - * @param \Google\Cloud\Speech\V2\LanguageMetadata $var - * @return $this - */ - public function setLanguages($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\LanguageMetadata::class); - $this->languages = $var; - - return $this; - } - - /** - * Information about access metadata for the region and given project. - * - * Generated from protobuf field .google.cloud.speech.v2.AccessMetadata access_metadata = 2; - * @return \Google\Cloud\Speech\V2\AccessMetadata|null - */ - public function getAccessMetadata() - { - return $this->access_metadata; - } - - public function hasAccessMetadata() - { - return isset($this->access_metadata); - } - - public function clearAccessMetadata() - { - unset($this->access_metadata); - } - - /** - * Information about access metadata for the region and given project. - * - * Generated from protobuf field .google.cloud.speech.v2.AccessMetadata access_metadata = 2; - * @param \Google\Cloud\Speech\V2\AccessMetadata $var - * @return $this - */ - public function setAccessMetadata($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\AccessMetadata::class); - $this->access_metadata = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ModelFeature.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ModelFeature.php deleted file mode 100644 index d64773c74d73..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ModelFeature.php +++ /dev/null @@ -1,102 +0,0 @@ -google.cloud.speech.v2.ModelFeature - */ -class ModelFeature extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the feature (Note: the feature can be `recognizer`) - * - * Generated from protobuf field string feature = 1; - */ - protected $feature = ''; - /** - * The release state of the feature - * - * Generated from protobuf field string release_state = 2; - */ - protected $release_state = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $feature - * The name of the feature (Note: the feature can be `recognizer`) - * @type string $release_state - * The release state of the feature - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\LocationsMetadata::initOnce(); - parent::__construct($data); - } - - /** - * The name of the feature (Note: the feature can be `recognizer`) - * - * Generated from protobuf field string feature = 1; - * @return string - */ - public function getFeature() - { - return $this->feature; - } - - /** - * The name of the feature (Note: the feature can be `recognizer`) - * - * Generated from protobuf field string feature = 1; - * @param string $var - * @return $this - */ - public function setFeature($var) - { - GPBUtil::checkString($var, True); - $this->feature = $var; - - return $this; - } - - /** - * The release state of the feature - * - * Generated from protobuf field string release_state = 2; - * @return string - */ - public function getReleaseState() - { - return $this->release_state; - } - - /** - * The release state of the feature - * - * Generated from protobuf field string release_state = 2; - * @param string $var - * @return $this - */ - public function setReleaseState($var) - { - GPBUtil::checkString($var, True); - $this->release_state = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ModelFeatures.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ModelFeatures.php deleted file mode 100644 index b001870bbf47..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ModelFeatures.php +++ /dev/null @@ -1,67 +0,0 @@ -google.cloud.speech.v2.ModelFeatures - */ -class ModelFeatures extends \Google\Protobuf\Internal\Message -{ - /** - * Repeated field that contains all features of the model - * - * Generated from protobuf field repeated .google.cloud.speech.v2.ModelFeature model_feature = 1; - */ - private $model_feature; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Speech\V2\ModelFeature[] $model_feature - * Repeated field that contains all features of the model - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\LocationsMetadata::initOnce(); - parent::__construct($data); - } - - /** - * Repeated field that contains all features of the model - * - * Generated from protobuf field repeated .google.cloud.speech.v2.ModelFeature model_feature = 1; - * @return RepeatedField<\Google\Cloud\Speech\V2\ModelFeature> - */ - public function getModelFeature() - { - return $this->model_feature; - } - - /** - * Repeated field that contains all features of the model - * - * Generated from protobuf field repeated .google.cloud.speech.v2.ModelFeature model_feature = 1; - * @param \Google\Cloud\Speech\V2\ModelFeature[] $var - * @return $this - */ - public function setModelFeature($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Speech\V2\ModelFeature::class); - $this->model_feature = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ModelMetadata.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ModelMetadata.php deleted file mode 100644 index e111a6f3f5c1..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/ModelMetadata.php +++ /dev/null @@ -1,68 +0,0 @@ -google.cloud.speech.v2.ModelMetadata - */ -class ModelMetadata extends \Google\Protobuf\Internal\Message -{ - /** - * Map of the model name -> features of that model - * - * Generated from protobuf field map model_features = 1; - */ - private $model_features; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\MapField $model_features - * Map of the model name -> features of that model - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\LocationsMetadata::initOnce(); - parent::__construct($data); - } - - /** - * Map of the model name -> features of that model - * - * Generated from protobuf field map model_features = 1; - * @return \Google\Protobuf\Internal\MapField - */ - public function getModelFeatures() - { - return $this->model_features; - } - - /** - * Map of the model name -> features of that model - * - * Generated from protobuf field map model_features = 1; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setModelFeatures($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Speech\V2\ModelFeatures::class); - $this->model_features = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/NativeOutputFileFormatConfig.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/NativeOutputFileFormatConfig.php deleted file mode 100644 index 3eec04a2e96b..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/NativeOutputFileFormatConfig.php +++ /dev/null @@ -1,33 +0,0 @@ -google.cloud.speech.v2.NativeOutputFileFormatConfig - */ -class NativeOutputFileFormatConfig extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/OperationMetadata.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/OperationMetadata.php deleted file mode 100644 index 39511aee9bce..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/OperationMetadata.php +++ /dev/null @@ -1,841 +0,0 @@ -google.cloud.speech.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; - */ - protected $create_time = null; - /** - * The time the operation was last updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 2; - */ - protected $update_time = null; - /** - * The resource path for the target of the operation. - * - * Generated from protobuf field string resource = 3; - */ - protected $resource = ''; - /** - * The method that triggered the operation. - * - * Generated from protobuf field string method = 4; - */ - protected $method = ''; - /** - * The [KMS key - * name](https://cloud.google.com/kms/docs/resource-hierarchy#keys) with which - * the content of the Operation is encrypted. The expected format is - * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. - * - * Generated from protobuf field string kms_key_name = 6 [(.google.api.resource_reference) = { - */ - protected $kms_key_name = ''; - /** - * The [KMS key version - * name](https://cloud.google.com/kms/docs/resource-hierarchy#key_versions) - * with which content of the Operation is encrypted. The expected format is - * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}/cryptoKeyVersions/{crypto_key_version}`. - * - * Generated from protobuf field string kms_key_version_name = 7 [(.google.api.resource_reference) = { - */ - protected $kms_key_version_name = ''; - /** - * The percent progress of the Operation. Values can range from 0-100. If the - * value is 100, then the operation is finished. - * - * Generated from protobuf field int32 progress_percent = 22; - */ - protected $progress_percent = 0; - protected $request; - protected $metadata; - - /** - * 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 $update_time - * The time the operation was last updated. - * @type string $resource - * The resource path for the target of the operation. - * @type string $method - * The method that triggered the operation. - * @type string $kms_key_name - * The [KMS key - * name](https://cloud.google.com/kms/docs/resource-hierarchy#keys) with which - * the content of the Operation is encrypted. The expected format is - * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. - * @type string $kms_key_version_name - * The [KMS key version - * name](https://cloud.google.com/kms/docs/resource-hierarchy#key_versions) - * with which content of the Operation is encrypted. The expected format is - * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}/cryptoKeyVersions/{crypto_key_version}`. - * @type \Google\Cloud\Speech\V2\BatchRecognizeRequest $batch_recognize_request - * The BatchRecognizeRequest that spawned the Operation. - * @type \Google\Cloud\Speech\V2\CreateRecognizerRequest $create_recognizer_request - * The CreateRecognizerRequest that spawned the Operation. - * @type \Google\Cloud\Speech\V2\UpdateRecognizerRequest $update_recognizer_request - * The UpdateRecognizerRequest that spawned the Operation. - * @type \Google\Cloud\Speech\V2\DeleteRecognizerRequest $delete_recognizer_request - * The DeleteRecognizerRequest that spawned the Operation. - * @type \Google\Cloud\Speech\V2\UndeleteRecognizerRequest $undelete_recognizer_request - * The UndeleteRecognizerRequest that spawned the Operation. - * @type \Google\Cloud\Speech\V2\CreateCustomClassRequest $create_custom_class_request - * The CreateCustomClassRequest that spawned the Operation. - * @type \Google\Cloud\Speech\V2\UpdateCustomClassRequest $update_custom_class_request - * The UpdateCustomClassRequest that spawned the Operation. - * @type \Google\Cloud\Speech\V2\DeleteCustomClassRequest $delete_custom_class_request - * The DeleteCustomClassRequest that spawned the Operation. - * @type \Google\Cloud\Speech\V2\UndeleteCustomClassRequest $undelete_custom_class_request - * The UndeleteCustomClassRequest that spawned the Operation. - * @type \Google\Cloud\Speech\V2\CreatePhraseSetRequest $create_phrase_set_request - * The CreatePhraseSetRequest that spawned the Operation. - * @type \Google\Cloud\Speech\V2\UpdatePhraseSetRequest $update_phrase_set_request - * The UpdatePhraseSetRequest that spawned the Operation. - * @type \Google\Cloud\Speech\V2\DeletePhraseSetRequest $delete_phrase_set_request - * The DeletePhraseSetRequest that spawned the Operation. - * @type \Google\Cloud\Speech\V2\UndeletePhraseSetRequest $undelete_phrase_set_request - * The UndeletePhraseSetRequest that spawned the Operation. - * @type \Google\Cloud\Speech\V2\UpdateConfigRequest $update_config_request - * The UpdateConfigRequest that spawned the Operation. - * @type int $progress_percent - * The percent progress of the Operation. Values can range from 0-100. If the - * value is 100, then the operation is finished. - * @type \Google\Cloud\Speech\V2\BatchRecognizeMetadata $batch_recognize_metadata - * Metadata specific to the BatchRecognize method. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::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 was last updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 2; - * @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); - } - - /** - * The time the operation was last updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 2; - * @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 resource path for the target of the operation. - * - * Generated from protobuf field string resource = 3; - * @return string - */ - public function getResource() - { - return $this->resource; - } - - /** - * The resource path for the target of the operation. - * - * Generated from protobuf field string resource = 3; - * @param string $var - * @return $this - */ - public function setResource($var) - { - GPBUtil::checkString($var, True); - $this->resource = $var; - - return $this; - } - - /** - * The method that triggered the operation. - * - * Generated from protobuf field string method = 4; - * @return string - */ - public function getMethod() - { - return $this->method; - } - - /** - * The method that triggered the operation. - * - * Generated from protobuf field string method = 4; - * @param string $var - * @return $this - */ - public function setMethod($var) - { - GPBUtil::checkString($var, True); - $this->method = $var; - - return $this; - } - - /** - * The [KMS key - * name](https://cloud.google.com/kms/docs/resource-hierarchy#keys) with which - * the content of the Operation is encrypted. The expected format is - * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. - * - * Generated from protobuf field string kms_key_name = 6 [(.google.api.resource_reference) = { - * @return string - */ - public function getKmsKeyName() - { - return $this->kms_key_name; - } - - /** - * The [KMS key - * name](https://cloud.google.com/kms/docs/resource-hierarchy#keys) with which - * the content of the Operation is encrypted. The expected format is - * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. - * - * Generated from protobuf field string kms_key_name = 6 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setKmsKeyName($var) - { - GPBUtil::checkString($var, True); - $this->kms_key_name = $var; - - return $this; - } - - /** - * The [KMS key version - * name](https://cloud.google.com/kms/docs/resource-hierarchy#key_versions) - * with which content of the Operation is encrypted. The expected format is - * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}/cryptoKeyVersions/{crypto_key_version}`. - * - * Generated from protobuf field string kms_key_version_name = 7 [(.google.api.resource_reference) = { - * @return string - */ - public function getKmsKeyVersionName() - { - return $this->kms_key_version_name; - } - - /** - * The [KMS key version - * name](https://cloud.google.com/kms/docs/resource-hierarchy#key_versions) - * with which content of the Operation is encrypted. The expected format is - * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}/cryptoKeyVersions/{crypto_key_version}`. - * - * Generated from protobuf field string kms_key_version_name = 7 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setKmsKeyVersionName($var) - { - GPBUtil::checkString($var, True); - $this->kms_key_version_name = $var; - - return $this; - } - - /** - * The BatchRecognizeRequest that spawned the Operation. - * - * Generated from protobuf field .google.cloud.speech.v2.BatchRecognizeRequest batch_recognize_request = 8; - * @return \Google\Cloud\Speech\V2\BatchRecognizeRequest|null - */ - public function getBatchRecognizeRequest() - { - return $this->readOneof(8); - } - - public function hasBatchRecognizeRequest() - { - return $this->hasOneof(8); - } - - /** - * The BatchRecognizeRequest that spawned the Operation. - * - * Generated from protobuf field .google.cloud.speech.v2.BatchRecognizeRequest batch_recognize_request = 8; - * @param \Google\Cloud\Speech\V2\BatchRecognizeRequest $var - * @return $this - */ - public function setBatchRecognizeRequest($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\BatchRecognizeRequest::class); - $this->writeOneof(8, $var); - - return $this; - } - - /** - * The CreateRecognizerRequest that spawned the Operation. - * - * Generated from protobuf field .google.cloud.speech.v2.CreateRecognizerRequest create_recognizer_request = 9; - * @return \Google\Cloud\Speech\V2\CreateRecognizerRequest|null - */ - public function getCreateRecognizerRequest() - { - return $this->readOneof(9); - } - - public function hasCreateRecognizerRequest() - { - return $this->hasOneof(9); - } - - /** - * The CreateRecognizerRequest that spawned the Operation. - * - * Generated from protobuf field .google.cloud.speech.v2.CreateRecognizerRequest create_recognizer_request = 9; - * @param \Google\Cloud\Speech\V2\CreateRecognizerRequest $var - * @return $this - */ - public function setCreateRecognizerRequest($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\CreateRecognizerRequest::class); - $this->writeOneof(9, $var); - - return $this; - } - - /** - * The UpdateRecognizerRequest that spawned the Operation. - * - * Generated from protobuf field .google.cloud.speech.v2.UpdateRecognizerRequest update_recognizer_request = 10; - * @return \Google\Cloud\Speech\V2\UpdateRecognizerRequest|null - */ - public function getUpdateRecognizerRequest() - { - return $this->readOneof(10); - } - - public function hasUpdateRecognizerRequest() - { - return $this->hasOneof(10); - } - - /** - * The UpdateRecognizerRequest that spawned the Operation. - * - * Generated from protobuf field .google.cloud.speech.v2.UpdateRecognizerRequest update_recognizer_request = 10; - * @param \Google\Cloud\Speech\V2\UpdateRecognizerRequest $var - * @return $this - */ - public function setUpdateRecognizerRequest($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\UpdateRecognizerRequest::class); - $this->writeOneof(10, $var); - - return $this; - } - - /** - * The DeleteRecognizerRequest that spawned the Operation. - * - * Generated from protobuf field .google.cloud.speech.v2.DeleteRecognizerRequest delete_recognizer_request = 11; - * @return \Google\Cloud\Speech\V2\DeleteRecognizerRequest|null - */ - public function getDeleteRecognizerRequest() - { - return $this->readOneof(11); - } - - public function hasDeleteRecognizerRequest() - { - return $this->hasOneof(11); - } - - /** - * The DeleteRecognizerRequest that spawned the Operation. - * - * Generated from protobuf field .google.cloud.speech.v2.DeleteRecognizerRequest delete_recognizer_request = 11; - * @param \Google\Cloud\Speech\V2\DeleteRecognizerRequest $var - * @return $this - */ - public function setDeleteRecognizerRequest($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\DeleteRecognizerRequest::class); - $this->writeOneof(11, $var); - - return $this; - } - - /** - * The UndeleteRecognizerRequest that spawned the Operation. - * - * Generated from protobuf field .google.cloud.speech.v2.UndeleteRecognizerRequest undelete_recognizer_request = 12; - * @return \Google\Cloud\Speech\V2\UndeleteRecognizerRequest|null - */ - public function getUndeleteRecognizerRequest() - { - return $this->readOneof(12); - } - - public function hasUndeleteRecognizerRequest() - { - return $this->hasOneof(12); - } - - /** - * The UndeleteRecognizerRequest that spawned the Operation. - * - * Generated from protobuf field .google.cloud.speech.v2.UndeleteRecognizerRequest undelete_recognizer_request = 12; - * @param \Google\Cloud\Speech\V2\UndeleteRecognizerRequest $var - * @return $this - */ - public function setUndeleteRecognizerRequest($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\UndeleteRecognizerRequest::class); - $this->writeOneof(12, $var); - - return $this; - } - - /** - * The CreateCustomClassRequest that spawned the Operation. - * - * Generated from protobuf field .google.cloud.speech.v2.CreateCustomClassRequest create_custom_class_request = 13; - * @return \Google\Cloud\Speech\V2\CreateCustomClassRequest|null - */ - public function getCreateCustomClassRequest() - { - return $this->readOneof(13); - } - - public function hasCreateCustomClassRequest() - { - return $this->hasOneof(13); - } - - /** - * The CreateCustomClassRequest that spawned the Operation. - * - * Generated from protobuf field .google.cloud.speech.v2.CreateCustomClassRequest create_custom_class_request = 13; - * @param \Google\Cloud\Speech\V2\CreateCustomClassRequest $var - * @return $this - */ - public function setCreateCustomClassRequest($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\CreateCustomClassRequest::class); - $this->writeOneof(13, $var); - - return $this; - } - - /** - * The UpdateCustomClassRequest that spawned the Operation. - * - * Generated from protobuf field .google.cloud.speech.v2.UpdateCustomClassRequest update_custom_class_request = 14; - * @return \Google\Cloud\Speech\V2\UpdateCustomClassRequest|null - */ - public function getUpdateCustomClassRequest() - { - return $this->readOneof(14); - } - - public function hasUpdateCustomClassRequest() - { - return $this->hasOneof(14); - } - - /** - * The UpdateCustomClassRequest that spawned the Operation. - * - * Generated from protobuf field .google.cloud.speech.v2.UpdateCustomClassRequest update_custom_class_request = 14; - * @param \Google\Cloud\Speech\V2\UpdateCustomClassRequest $var - * @return $this - */ - public function setUpdateCustomClassRequest($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\UpdateCustomClassRequest::class); - $this->writeOneof(14, $var); - - return $this; - } - - /** - * The DeleteCustomClassRequest that spawned the Operation. - * - * Generated from protobuf field .google.cloud.speech.v2.DeleteCustomClassRequest delete_custom_class_request = 15; - * @return \Google\Cloud\Speech\V2\DeleteCustomClassRequest|null - */ - public function getDeleteCustomClassRequest() - { - return $this->readOneof(15); - } - - public function hasDeleteCustomClassRequest() - { - return $this->hasOneof(15); - } - - /** - * The DeleteCustomClassRequest that spawned the Operation. - * - * Generated from protobuf field .google.cloud.speech.v2.DeleteCustomClassRequest delete_custom_class_request = 15; - * @param \Google\Cloud\Speech\V2\DeleteCustomClassRequest $var - * @return $this - */ - public function setDeleteCustomClassRequest($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\DeleteCustomClassRequest::class); - $this->writeOneof(15, $var); - - return $this; - } - - /** - * The UndeleteCustomClassRequest that spawned the Operation. - * - * Generated from protobuf field .google.cloud.speech.v2.UndeleteCustomClassRequest undelete_custom_class_request = 16; - * @return \Google\Cloud\Speech\V2\UndeleteCustomClassRequest|null - */ - public function getUndeleteCustomClassRequest() - { - return $this->readOneof(16); - } - - public function hasUndeleteCustomClassRequest() - { - return $this->hasOneof(16); - } - - /** - * The UndeleteCustomClassRequest that spawned the Operation. - * - * Generated from protobuf field .google.cloud.speech.v2.UndeleteCustomClassRequest undelete_custom_class_request = 16; - * @param \Google\Cloud\Speech\V2\UndeleteCustomClassRequest $var - * @return $this - */ - public function setUndeleteCustomClassRequest($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\UndeleteCustomClassRequest::class); - $this->writeOneof(16, $var); - - return $this; - } - - /** - * The CreatePhraseSetRequest that spawned the Operation. - * - * Generated from protobuf field .google.cloud.speech.v2.CreatePhraseSetRequest create_phrase_set_request = 17; - * @return \Google\Cloud\Speech\V2\CreatePhraseSetRequest|null - */ - public function getCreatePhraseSetRequest() - { - return $this->readOneof(17); - } - - public function hasCreatePhraseSetRequest() - { - return $this->hasOneof(17); - } - - /** - * The CreatePhraseSetRequest that spawned the Operation. - * - * Generated from protobuf field .google.cloud.speech.v2.CreatePhraseSetRequest create_phrase_set_request = 17; - * @param \Google\Cloud\Speech\V2\CreatePhraseSetRequest $var - * @return $this - */ - public function setCreatePhraseSetRequest($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\CreatePhraseSetRequest::class); - $this->writeOneof(17, $var); - - return $this; - } - - /** - * The UpdatePhraseSetRequest that spawned the Operation. - * - * Generated from protobuf field .google.cloud.speech.v2.UpdatePhraseSetRequest update_phrase_set_request = 18; - * @return \Google\Cloud\Speech\V2\UpdatePhraseSetRequest|null - */ - public function getUpdatePhraseSetRequest() - { - return $this->readOneof(18); - } - - public function hasUpdatePhraseSetRequest() - { - return $this->hasOneof(18); - } - - /** - * The UpdatePhraseSetRequest that spawned the Operation. - * - * Generated from protobuf field .google.cloud.speech.v2.UpdatePhraseSetRequest update_phrase_set_request = 18; - * @param \Google\Cloud\Speech\V2\UpdatePhraseSetRequest $var - * @return $this - */ - public function setUpdatePhraseSetRequest($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\UpdatePhraseSetRequest::class); - $this->writeOneof(18, $var); - - return $this; - } - - /** - * The DeletePhraseSetRequest that spawned the Operation. - * - * Generated from protobuf field .google.cloud.speech.v2.DeletePhraseSetRequest delete_phrase_set_request = 19; - * @return \Google\Cloud\Speech\V2\DeletePhraseSetRequest|null - */ - public function getDeletePhraseSetRequest() - { - return $this->readOneof(19); - } - - public function hasDeletePhraseSetRequest() - { - return $this->hasOneof(19); - } - - /** - * The DeletePhraseSetRequest that spawned the Operation. - * - * Generated from protobuf field .google.cloud.speech.v2.DeletePhraseSetRequest delete_phrase_set_request = 19; - * @param \Google\Cloud\Speech\V2\DeletePhraseSetRequest $var - * @return $this - */ - public function setDeletePhraseSetRequest($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\DeletePhraseSetRequest::class); - $this->writeOneof(19, $var); - - return $this; - } - - /** - * The UndeletePhraseSetRequest that spawned the Operation. - * - * Generated from protobuf field .google.cloud.speech.v2.UndeletePhraseSetRequest undelete_phrase_set_request = 20; - * @return \Google\Cloud\Speech\V2\UndeletePhraseSetRequest|null - */ - public function getUndeletePhraseSetRequest() - { - return $this->readOneof(20); - } - - public function hasUndeletePhraseSetRequest() - { - return $this->hasOneof(20); - } - - /** - * The UndeletePhraseSetRequest that spawned the Operation. - * - * Generated from protobuf field .google.cloud.speech.v2.UndeletePhraseSetRequest undelete_phrase_set_request = 20; - * @param \Google\Cloud\Speech\V2\UndeletePhraseSetRequest $var - * @return $this - */ - public function setUndeletePhraseSetRequest($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\UndeletePhraseSetRequest::class); - $this->writeOneof(20, $var); - - return $this; - } - - /** - * The UpdateConfigRequest that spawned the Operation. - * - * Generated from protobuf field .google.cloud.speech.v2.UpdateConfigRequest update_config_request = 21 [deprecated = true]; - * @return \Google\Cloud\Speech\V2\UpdateConfigRequest|null - * @deprecated - */ - public function getUpdateConfigRequest() - { - if ($this->hasOneof(21)) { - @trigger_error('update_config_request is deprecated.', E_USER_DEPRECATED); - } - return $this->readOneof(21); - } - - public function hasUpdateConfigRequest() - { - if ($this->hasOneof(21)) { - @trigger_error('update_config_request is deprecated.', E_USER_DEPRECATED); - } - return $this->hasOneof(21); - } - - /** - * The UpdateConfigRequest that spawned the Operation. - * - * Generated from protobuf field .google.cloud.speech.v2.UpdateConfigRequest update_config_request = 21 [deprecated = true]; - * @param \Google\Cloud\Speech\V2\UpdateConfigRequest $var - * @return $this - * @deprecated - */ - public function setUpdateConfigRequest($var) - { - @trigger_error('update_config_request is deprecated.', E_USER_DEPRECATED); - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\UpdateConfigRequest::class); - $this->writeOneof(21, $var); - - return $this; - } - - /** - * The percent progress of the Operation. Values can range from 0-100. If the - * value is 100, then the operation is finished. - * - * Generated from protobuf field int32 progress_percent = 22; - * @return int - */ - public function getProgressPercent() - { - return $this->progress_percent; - } - - /** - * The percent progress of the Operation. Values can range from 0-100. If the - * value is 100, then the operation is finished. - * - * Generated from protobuf field int32 progress_percent = 22; - * @param int $var - * @return $this - */ - public function setProgressPercent($var) - { - GPBUtil::checkInt32($var); - $this->progress_percent = $var; - - return $this; - } - - /** - * Metadata specific to the BatchRecognize method. - * - * Generated from protobuf field .google.cloud.speech.v2.BatchRecognizeMetadata batch_recognize_metadata = 23; - * @return \Google\Cloud\Speech\V2\BatchRecognizeMetadata|null - */ - public function getBatchRecognizeMetadata() - { - return $this->readOneof(23); - } - - public function hasBatchRecognizeMetadata() - { - return $this->hasOneof(23); - } - - /** - * Metadata specific to the BatchRecognize method. - * - * Generated from protobuf field .google.cloud.speech.v2.BatchRecognizeMetadata batch_recognize_metadata = 23; - * @param \Google\Cloud\Speech\V2\BatchRecognizeMetadata $var - * @return $this - */ - public function setBatchRecognizeMetadata($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\BatchRecognizeMetadata::class); - $this->writeOneof(23, $var); - - return $this; - } - - /** - * @return string - */ - public function getRequest() - { - return $this->whichOneof("request"); - } - - /** - * @return string - */ - public function getMetadata() - { - return $this->whichOneof("metadata"); - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/OutputFormatConfig.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/OutputFormatConfig.php deleted file mode 100644 index 066ea0a2354d..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/OutputFormatConfig.php +++ /dev/null @@ -1,181 +0,0 @@ -google.cloud.speech.v2.OutputFormatConfig - */ -class OutputFormatConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Configuration for the native output format. If this field is set or if no - * other output format field is set, then transcripts will be written to the - * sink in the native format. - * - * Generated from protobuf field .google.cloud.speech.v2.NativeOutputFileFormatConfig native = 1; - */ - protected $native = null; - /** - * Configuration for the VTT output format. If this field is set, then - * transcripts will be written to the sink in the VTT format. - * - * Generated from protobuf field .google.cloud.speech.v2.VttOutputFileFormatConfig vtt = 2; - */ - protected $vtt = null; - /** - * Configuration for the SRT output format. If this field is set, then - * transcripts will be written to the sink in the SRT format. - * - * Generated from protobuf field .google.cloud.speech.v2.SrtOutputFileFormatConfig srt = 3; - */ - protected $srt = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Speech\V2\NativeOutputFileFormatConfig $native - * Configuration for the native output format. If this field is set or if no - * other output format field is set, then transcripts will be written to the - * sink in the native format. - * @type \Google\Cloud\Speech\V2\VttOutputFileFormatConfig $vtt - * Configuration for the VTT output format. If this field is set, then - * transcripts will be written to the sink in the VTT format. - * @type \Google\Cloud\Speech\V2\SrtOutputFileFormatConfig $srt - * Configuration for the SRT output format. If this field is set, then - * transcripts will be written to the sink in the SRT format. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Configuration for the native output format. If this field is set or if no - * other output format field is set, then transcripts will be written to the - * sink in the native format. - * - * Generated from protobuf field .google.cloud.speech.v2.NativeOutputFileFormatConfig native = 1; - * @return \Google\Cloud\Speech\V2\NativeOutputFileFormatConfig|null - */ - public function getNative() - { - return $this->native; - } - - public function hasNative() - { - return isset($this->native); - } - - public function clearNative() - { - unset($this->native); - } - - /** - * Configuration for the native output format. If this field is set or if no - * other output format field is set, then transcripts will be written to the - * sink in the native format. - * - * Generated from protobuf field .google.cloud.speech.v2.NativeOutputFileFormatConfig native = 1; - * @param \Google\Cloud\Speech\V2\NativeOutputFileFormatConfig $var - * @return $this - */ - public function setNative($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\NativeOutputFileFormatConfig::class); - $this->native = $var; - - return $this; - } - - /** - * Configuration for the VTT output format. If this field is set, then - * transcripts will be written to the sink in the VTT format. - * - * Generated from protobuf field .google.cloud.speech.v2.VttOutputFileFormatConfig vtt = 2; - * @return \Google\Cloud\Speech\V2\VttOutputFileFormatConfig|null - */ - public function getVtt() - { - return $this->vtt; - } - - public function hasVtt() - { - return isset($this->vtt); - } - - public function clearVtt() - { - unset($this->vtt); - } - - /** - * Configuration for the VTT output format. If this field is set, then - * transcripts will be written to the sink in the VTT format. - * - * Generated from protobuf field .google.cloud.speech.v2.VttOutputFileFormatConfig vtt = 2; - * @param \Google\Cloud\Speech\V2\VttOutputFileFormatConfig $var - * @return $this - */ - public function setVtt($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\VttOutputFileFormatConfig::class); - $this->vtt = $var; - - return $this; - } - - /** - * Configuration for the SRT output format. If this field is set, then - * transcripts will be written to the sink in the SRT format. - * - * Generated from protobuf field .google.cloud.speech.v2.SrtOutputFileFormatConfig srt = 3; - * @return \Google\Cloud\Speech\V2\SrtOutputFileFormatConfig|null - */ - public function getSrt() - { - return $this->srt; - } - - public function hasSrt() - { - return isset($this->srt); - } - - public function clearSrt() - { - unset($this->srt); - } - - /** - * Configuration for the SRT output format. If this field is set, then - * transcripts will be written to the sink in the SRT format. - * - * Generated from protobuf field .google.cloud.speech.v2.SrtOutputFileFormatConfig srt = 3; - * @param \Google\Cloud\Speech\V2\SrtOutputFileFormatConfig $var - * @return $this - */ - public function setSrt($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\SrtOutputFileFormatConfig::class); - $this->srt = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/PhraseSet.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/PhraseSet.php deleted file mode 100644 index e6f62ab78c9c..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/PhraseSet.php +++ /dev/null @@ -1,657 +0,0 @@ -google.cloud.speech.v2.PhraseSet - */ -class PhraseSet extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. Identifier. The resource name of the PhraseSet. - * Format: `projects/{project}/locations/{location}/phraseSets/{phrase_set}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IDENTIFIER]; - */ - protected $name = ''; - /** - * Output only. System-assigned unique identifier for the PhraseSet. - * - * Generated from protobuf field string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $uid = ''; - /** - * A list of word and phrases. - * - * Generated from protobuf field repeated .google.cloud.speech.v2.PhraseSet.Phrase phrases = 3; - */ - private $phrases; - /** - * Hint Boost. Positive value will increase the probability that a specific - * phrase will be recognized over other similar sounding phrases. The higher - * the boost, the higher the chance of false positive recognition as well. - * Valid `boost` values are between 0 (exclusive) and 20. We recommend using a - * binary search approach to finding the optimal value for your use case as - * well as adding phrases both with and without boost to your requests. - * - * Generated from protobuf field float boost = 4; - */ - protected $boost = 0.0; - /** - * User-settable, human-readable name for the PhraseSet. Must be 63 - * characters or less. - * - * Generated from protobuf field string display_name = 5; - */ - protected $display_name = ''; - /** - * Output only. The PhraseSet lifecycle state. - * - * Generated from protobuf field .google.cloud.speech.v2.PhraseSet.State state = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = 0; - /** - * Output only. Creation time. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The most recent time this resource was modified. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Output only. The time at which this resource was requested for deletion. - * - * Generated from protobuf field .google.protobuf.Timestamp delete_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $delete_time = null; - /** - * Output only. The time at which this resource will be purged. - * - * Generated from protobuf field .google.protobuf.Timestamp expire_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $expire_time = null; - /** - * Allows users to store small amounts of arbitrary data. - * Both the key and the value must be 63 characters or less each. - * At most 100 annotations. - * - * Generated from protobuf field map annotations = 10; - */ - private $annotations; - /** - * Output only. This checksum is computed by the server based on the value of - * other fields. This may be sent on update, undelete, and delete requests to - * ensure 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 = ''; - /** - * Output only. Whether or not this PhraseSet is in the process of being - * updated. - * - * Generated from protobuf field bool reconciling = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $reconciling = false; - /** - * Output only. The [KMS key - * name](https://cloud.google.com/kms/docs/resource-hierarchy#keys) with which - * the PhraseSet is encrypted. The expected format is - * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. - * - * Generated from protobuf field string kms_key_name = 13 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { - */ - protected $kms_key_name = ''; - /** - * Output only. The [KMS key version - * name](https://cloud.google.com/kms/docs/resource-hierarchy#key_versions) - * with which the PhraseSet is encrypted. The expected format is - * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}/cryptoKeyVersions/{crypto_key_version}`. - * - * Generated from protobuf field string kms_key_version_name = 14 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { - */ - protected $kms_key_version_name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. Identifier. The resource name of the PhraseSet. - * Format: `projects/{project}/locations/{location}/phraseSets/{phrase_set}`. - * @type string $uid - * Output only. System-assigned unique identifier for the PhraseSet. - * @type \Google\Cloud\Speech\V2\PhraseSet\Phrase[] $phrases - * A list of word and phrases. - * @type float $boost - * Hint Boost. Positive value will increase the probability that a specific - * phrase will be recognized over other similar sounding phrases. The higher - * the boost, the higher the chance of false positive recognition as well. - * Valid `boost` values are between 0 (exclusive) and 20. We recommend using a - * binary search approach to finding the optimal value for your use case as - * well as adding phrases both with and without boost to your requests. - * @type string $display_name - * User-settable, human-readable name for the PhraseSet. Must be 63 - * characters or less. - * @type int $state - * Output only. The PhraseSet lifecycle state. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. Creation time. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. The most recent time this resource was modified. - * @type \Google\Protobuf\Timestamp $delete_time - * Output only. The time at which this resource was requested for deletion. - * @type \Google\Protobuf\Timestamp $expire_time - * Output only. The time at which this resource will be purged. - * @type array|\Google\Protobuf\Internal\MapField $annotations - * Allows users to store small amounts of arbitrary data. - * Both the key and the value must be 63 characters or less each. - * At most 100 annotations. - * @type string $etag - * Output only. This checksum is computed by the server based on the value of - * other fields. This may be sent on update, undelete, and delete requests to - * ensure the client has an up-to-date value before proceeding. - * @type bool $reconciling - * Output only. Whether or not this PhraseSet is in the process of being - * updated. - * @type string $kms_key_name - * Output only. The [KMS key - * name](https://cloud.google.com/kms/docs/resource-hierarchy#keys) with which - * the PhraseSet is encrypted. The expected format is - * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. - * @type string $kms_key_version_name - * Output only. The [KMS key version - * name](https://cloud.google.com/kms/docs/resource-hierarchy#key_versions) - * with which the PhraseSet is encrypted. The expected format is - * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}/cryptoKeyVersions/{crypto_key_version}`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Output only. Identifier. The resource name of the PhraseSet. - * Format: `projects/{project}/locations/{location}/phraseSets/{phrase_set}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IDENTIFIER]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Output only. Identifier. The resource name of the PhraseSet. - * Format: `projects/{project}/locations/{location}/phraseSets/{phrase_set}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IDENTIFIER]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Output only. System-assigned unique identifier for the PhraseSet. - * - * Generated from protobuf field string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getUid() - { - return $this->uid; - } - - /** - * Output only. System-assigned unique identifier for the PhraseSet. - * - * 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; - } - - /** - * A list of word and phrases. - * - * Generated from protobuf field repeated .google.cloud.speech.v2.PhraseSet.Phrase phrases = 3; - * @return RepeatedField<\Google\Cloud\Speech\V2\PhraseSet\Phrase> - */ - public function getPhrases() - { - return $this->phrases; - } - - /** - * A list of word and phrases. - * - * Generated from protobuf field repeated .google.cloud.speech.v2.PhraseSet.Phrase phrases = 3; - * @param \Google\Cloud\Speech\V2\PhraseSet\Phrase[] $var - * @return $this - */ - public function setPhrases($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Speech\V2\PhraseSet\Phrase::class); - $this->phrases = $arr; - - return $this; - } - - /** - * Hint Boost. Positive value will increase the probability that a specific - * phrase will be recognized over other similar sounding phrases. The higher - * the boost, the higher the chance of false positive recognition as well. - * Valid `boost` values are between 0 (exclusive) and 20. We recommend using a - * binary search approach to finding the optimal value for your use case as - * well as adding phrases both with and without boost to your requests. - * - * Generated from protobuf field float boost = 4; - * @return float - */ - public function getBoost() - { - return $this->boost; - } - - /** - * Hint Boost. Positive value will increase the probability that a specific - * phrase will be recognized over other similar sounding phrases. The higher - * the boost, the higher the chance of false positive recognition as well. - * Valid `boost` values are between 0 (exclusive) and 20. We recommend using a - * binary search approach to finding the optimal value for your use case as - * well as adding phrases both with and without boost to your requests. - * - * Generated from protobuf field float boost = 4; - * @param float $var - * @return $this - */ - public function setBoost($var) - { - GPBUtil::checkFloat($var); - $this->boost = $var; - - return $this; - } - - /** - * User-settable, human-readable name for the PhraseSet. Must be 63 - * characters or less. - * - * Generated from protobuf field string display_name = 5; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * User-settable, human-readable name for the PhraseSet. Must be 63 - * characters or less. - * - * Generated from protobuf field string display_name = 5; - * @param string $var - * @return $this - */ - public function setDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->display_name = $var; - - return $this; - } - - /** - * Output only. The PhraseSet lifecycle state. - * - * Generated from protobuf field .google.cloud.speech.v2.PhraseSet.State state = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Output only. The PhraseSet lifecycle state. - * - * Generated from protobuf field .google.cloud.speech.v2.PhraseSet.State state = 15 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Speech\V2\PhraseSet\State::class); - $this->state = $var; - - return $this; - } - - /** - * Output only. Creation time. - * - * 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. Creation time. - * - * 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. The most recent time this resource was modified. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 7 [(.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 most recent time this resource was modified. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 7 [(.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 time at which this resource was requested for deletion. - * - * Generated from protobuf field .google.protobuf.Timestamp delete_time = 8 [(.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. The time at which this resource was requested for deletion. - * - * Generated from protobuf field .google.protobuf.Timestamp delete_time = 8 [(.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. The time at which this resource will be purged. - * - * Generated from protobuf field .google.protobuf.Timestamp expire_time = 9 [(.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 resource will be purged. - * - * Generated from protobuf field .google.protobuf.Timestamp expire_time = 9 [(.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; - } - - /** - * Allows users to store small amounts of arbitrary data. - * Both the key and the value must be 63 characters or less each. - * At most 100 annotations. - * - * Generated from protobuf field map annotations = 10; - * @return \Google\Protobuf\Internal\MapField - */ - public function getAnnotations() - { - return $this->annotations; - } - - /** - * Allows users to store small amounts of arbitrary data. - * Both the key and the value must be 63 characters or less each. - * At most 100 annotations. - * - * 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; - } - - /** - * Output only. This checksum is computed by the server based on the value of - * other fields. This may be sent on update, undelete, and delete requests to - * ensure 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. This checksum is computed by the server based on the value of - * other fields. This may be sent on update, undelete, and delete requests to - * ensure 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; - } - - /** - * Output only. Whether or not this PhraseSet is in the process of being - * updated. - * - * Generated from protobuf field bool reconciling = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return bool - */ - public function getReconciling() - { - return $this->reconciling; - } - - /** - * Output only. Whether or not this PhraseSet is in the process of being - * updated. - * - * Generated from protobuf field bool reconciling = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param bool $var - * @return $this - */ - public function setReconciling($var) - { - GPBUtil::checkBool($var); - $this->reconciling = $var; - - return $this; - } - - /** - * Output only. The [KMS key - * name](https://cloud.google.com/kms/docs/resource-hierarchy#keys) with which - * the PhraseSet is encrypted. The expected format is - * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. - * - * Generated from protobuf field string kms_key_name = 13 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { - * @return string - */ - public function getKmsKeyName() - { - return $this->kms_key_name; - } - - /** - * Output only. The [KMS key - * name](https://cloud.google.com/kms/docs/resource-hierarchy#keys) with which - * the PhraseSet is encrypted. The expected format is - * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. - * - * Generated from protobuf field string kms_key_name = 13 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setKmsKeyName($var) - { - GPBUtil::checkString($var, True); - $this->kms_key_name = $var; - - return $this; - } - - /** - * Output only. The [KMS key version - * name](https://cloud.google.com/kms/docs/resource-hierarchy#key_versions) - * with which the PhraseSet is encrypted. The expected format is - * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}/cryptoKeyVersions/{crypto_key_version}`. - * - * Generated from protobuf field string kms_key_version_name = 14 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { - * @return string - */ - public function getKmsKeyVersionName() - { - return $this->kms_key_version_name; - } - - /** - * Output only. The [KMS key version - * name](https://cloud.google.com/kms/docs/resource-hierarchy#key_versions) - * with which the PhraseSet is encrypted. The expected format is - * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}/cryptoKeyVersions/{crypto_key_version}`. - * - * Generated from protobuf field string kms_key_version_name = 14 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setKmsKeyVersionName($var) - { - GPBUtil::checkString($var, True); - $this->kms_key_version_name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/PhraseSet/Phrase.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/PhraseSet/Phrase.php deleted file mode 100644 index e081f239c9a9..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/PhraseSet/Phrase.php +++ /dev/null @@ -1,143 +0,0 @@ -google.cloud.speech.v2.PhraseSet.Phrase - */ -class Phrase extends \Google\Protobuf\Internal\Message -{ - /** - * The phrase itself. - * - * Generated from protobuf field string value = 1; - */ - protected $value = ''; - /** - * Hint Boost. Overrides the boost set at the phrase set level. - * Positive value will increase the probability that a specific phrase will - * be recognized over other similar sounding phrases. The higher the boost, - * the higher the chance of false positive recognition as well. Negative - * boost values would correspond to anti-biasing. Anti-biasing is not - * enabled, so negative boost values will return an error. Boost values must - * be between 0 and 20. Any values outside that range will return an error. - * We recommend using a binary search approach to finding the optimal value - * for your use case as well as adding phrases both with and without boost - * to your requests. - * - * Generated from protobuf field float boost = 2; - */ - protected $boost = 0.0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $value - * The phrase itself. - * @type float $boost - * Hint Boost. Overrides the boost set at the phrase set level. - * Positive value will increase the probability that a specific phrase will - * be recognized over other similar sounding phrases. The higher the boost, - * the higher the chance of false positive recognition as well. Negative - * boost values would correspond to anti-biasing. Anti-biasing is not - * enabled, so negative boost values will return an error. Boost values must - * be between 0 and 20. Any values outside that range will return an error. - * We recommend using a binary search approach to finding the optimal value - * for your use case as well as adding phrases both with and without boost - * to your requests. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * The phrase itself. - * - * Generated from protobuf field string value = 1; - * @return string - */ - public function getValue() - { - return $this->value; - } - - /** - * The phrase itself. - * - * Generated from protobuf field string value = 1; - * @param string $var - * @return $this - */ - public function setValue($var) - { - GPBUtil::checkString($var, True); - $this->value = $var; - - return $this; - } - - /** - * Hint Boost. Overrides the boost set at the phrase set level. - * Positive value will increase the probability that a specific phrase will - * be recognized over other similar sounding phrases. The higher the boost, - * the higher the chance of false positive recognition as well. Negative - * boost values would correspond to anti-biasing. Anti-biasing is not - * enabled, so negative boost values will return an error. Boost values must - * be between 0 and 20. Any values outside that range will return an error. - * We recommend using a binary search approach to finding the optimal value - * for your use case as well as adding phrases both with and without boost - * to your requests. - * - * Generated from protobuf field float boost = 2; - * @return float - */ - public function getBoost() - { - return $this->boost; - } - - /** - * Hint Boost. Overrides the boost set at the phrase set level. - * Positive value will increase the probability that a specific phrase will - * be recognized over other similar sounding phrases. The higher the boost, - * the higher the chance of false positive recognition as well. Negative - * boost values would correspond to anti-biasing. Anti-biasing is not - * enabled, so negative boost values will return an error. Boost values must - * be between 0 and 20. Any values outside that range will return an error. - * We recommend using a binary search approach to finding the optimal value - * for your use case as well as adding phrases both with and without boost - * to your requests. - * - * Generated from protobuf field float boost = 2; - * @param float $var - * @return $this - */ - public function setBoost($var) - { - GPBUtil::checkFloat($var); - $this->boost = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/PhraseSet/State.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/PhraseSet/State.php deleted file mode 100644 index d905b2637de1..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/PhraseSet/State.php +++ /dev/null @@ -1,62 +0,0 @@ -google.cloud.speech.v2.PhraseSet.State - */ -class State -{ - /** - * Unspecified state. This is only used/useful for distinguishing - * unset values. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * The normal and active state. - * - * Generated from protobuf enum ACTIVE = 2; - */ - const ACTIVE = 2; - /** - * This PhraseSet has been deleted. - * - * Generated from protobuf enum DELETED = 4; - */ - const DELETED = 4; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::ACTIVE => 'ACTIVE', - 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); - } -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognitionConfig.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognitionConfig.php deleted file mode 100644 index 1a832099cb6f..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognitionConfig.php +++ /dev/null @@ -1,487 +0,0 @@ -google.cloud.speech.v2.RecognitionConfig - */ -class RecognitionConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. Which model to use for recognition requests. Select the model - * best suited to your domain to get best results. - * Guidance for choosing which model to use can be found in the [Transcription - * Models - * Documentation](https://cloud.google.com/speech-to-text/v2/docs/transcription-model) - * and the models supported in each region can be found in the [Table Of - * Supported - * Models](https://cloud.google.com/speech-to-text/v2/docs/speech-to-text-supported-languages). - * - * Generated from protobuf field string model = 9 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $model = ''; - /** - * Optional. The language of the supplied audio as a - * [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) language tag. - * Language tags are normalized to BCP-47 before they are used eg "en-us" - * becomes "en-US". - * Supported languages for each model are listed in the [Table of Supported - * Models](https://cloud.google.com/speech-to-text/v2/docs/speech-to-text-supported-languages). - * If additional languages are provided, recognition result will contain - * recognition in the most likely language detected. The recognition result - * will include the language tag of the language detected in the audio. - * - * Generated from protobuf field repeated string language_codes = 10 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $language_codes; - /** - * Speech recognition features to enable. - * - * Generated from protobuf field .google.cloud.speech.v2.RecognitionFeatures features = 2; - */ - protected $features = null; - /** - * Speech adaptation context that weights recognizer predictions for specific - * words and phrases. - * - * Generated from protobuf field .google.cloud.speech.v2.SpeechAdaptation adaptation = 6; - */ - protected $adaptation = null; - /** - * Optional. Use transcription normalization to automatically replace parts of - * the transcript with phrases of your choosing. For StreamingRecognize, this - * normalization only applies to stable partial transcripts (stability > 0.8) - * and final transcripts. - * - * Generated from protobuf field .google.cloud.speech.v2.TranscriptNormalization transcript_normalization = 11 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $transcript_normalization = null; - /** - * Optional. Optional configuration used to automatically run translation on - * the given audio to the desired language for supported models. - * - * Generated from protobuf field .google.cloud.speech.v2.TranslationConfig translation_config = 15 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $translation_config = null; - /** - * Optional. Optional denoiser config. May not be supported for all models - * and may have no effect. - * - * Generated from protobuf field .google.cloud.speech.v2.DenoiserConfig denoiser_config = 16 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $denoiser_config = null; - protected $decoding_config; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Speech\V2\AutoDetectDecodingConfig $auto_decoding_config - * Automatically detect decoding parameters. - * Preferred for supported formats. - * @type \Google\Cloud\Speech\V2\ExplicitDecodingConfig $explicit_decoding_config - * Explicitly specified decoding parameters. - * Required if using headerless PCM audio (linear16, mulaw, alaw). - * @type string $model - * Optional. Which model to use for recognition requests. Select the model - * best suited to your domain to get best results. - * Guidance for choosing which model to use can be found in the [Transcription - * Models - * Documentation](https://cloud.google.com/speech-to-text/v2/docs/transcription-model) - * and the models supported in each region can be found in the [Table Of - * Supported - * Models](https://cloud.google.com/speech-to-text/v2/docs/speech-to-text-supported-languages). - * @type string[] $language_codes - * Optional. The language of the supplied audio as a - * [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) language tag. - * Language tags are normalized to BCP-47 before they are used eg "en-us" - * becomes "en-US". - * Supported languages for each model are listed in the [Table of Supported - * Models](https://cloud.google.com/speech-to-text/v2/docs/speech-to-text-supported-languages). - * If additional languages are provided, recognition result will contain - * recognition in the most likely language detected. The recognition result - * will include the language tag of the language detected in the audio. - * @type \Google\Cloud\Speech\V2\RecognitionFeatures $features - * Speech recognition features to enable. - * @type \Google\Cloud\Speech\V2\SpeechAdaptation $adaptation - * Speech adaptation context that weights recognizer predictions for specific - * words and phrases. - * @type \Google\Cloud\Speech\V2\TranscriptNormalization $transcript_normalization - * Optional. Use transcription normalization to automatically replace parts of - * the transcript with phrases of your choosing. For StreamingRecognize, this - * normalization only applies to stable partial transcripts (stability > 0.8) - * and final transcripts. - * @type \Google\Cloud\Speech\V2\TranslationConfig $translation_config - * Optional. Optional configuration used to automatically run translation on - * the given audio to the desired language for supported models. - * @type \Google\Cloud\Speech\V2\DenoiserConfig $denoiser_config - * Optional. Optional denoiser config. May not be supported for all models - * and may have no effect. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Automatically detect decoding parameters. - * Preferred for supported formats. - * - * Generated from protobuf field .google.cloud.speech.v2.AutoDetectDecodingConfig auto_decoding_config = 7; - * @return \Google\Cloud\Speech\V2\AutoDetectDecodingConfig|null - */ - public function getAutoDecodingConfig() - { - return $this->readOneof(7); - } - - public function hasAutoDecodingConfig() - { - return $this->hasOneof(7); - } - - /** - * Automatically detect decoding parameters. - * Preferred for supported formats. - * - * Generated from protobuf field .google.cloud.speech.v2.AutoDetectDecodingConfig auto_decoding_config = 7; - * @param \Google\Cloud\Speech\V2\AutoDetectDecodingConfig $var - * @return $this - */ - public function setAutoDecodingConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\AutoDetectDecodingConfig::class); - $this->writeOneof(7, $var); - - return $this; - } - - /** - * Explicitly specified decoding parameters. - * Required if using headerless PCM audio (linear16, mulaw, alaw). - * - * Generated from protobuf field .google.cloud.speech.v2.ExplicitDecodingConfig explicit_decoding_config = 8; - * @return \Google\Cloud\Speech\V2\ExplicitDecodingConfig|null - */ - public function getExplicitDecodingConfig() - { - return $this->readOneof(8); - } - - public function hasExplicitDecodingConfig() - { - return $this->hasOneof(8); - } - - /** - * Explicitly specified decoding parameters. - * Required if using headerless PCM audio (linear16, mulaw, alaw). - * - * Generated from protobuf field .google.cloud.speech.v2.ExplicitDecodingConfig explicit_decoding_config = 8; - * @param \Google\Cloud\Speech\V2\ExplicitDecodingConfig $var - * @return $this - */ - public function setExplicitDecodingConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\ExplicitDecodingConfig::class); - $this->writeOneof(8, $var); - - return $this; - } - - /** - * Optional. Which model to use for recognition requests. Select the model - * best suited to your domain to get best results. - * Guidance for choosing which model to use can be found in the [Transcription - * Models - * Documentation](https://cloud.google.com/speech-to-text/v2/docs/transcription-model) - * and the models supported in each region can be found in the [Table Of - * Supported - * Models](https://cloud.google.com/speech-to-text/v2/docs/speech-to-text-supported-languages). - * - * Generated from protobuf field string model = 9 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getModel() - { - return $this->model; - } - - /** - * Optional. Which model to use for recognition requests. Select the model - * best suited to your domain to get best results. - * Guidance for choosing which model to use can be found in the [Transcription - * Models - * Documentation](https://cloud.google.com/speech-to-text/v2/docs/transcription-model) - * and the models supported in each region can be found in the [Table Of - * Supported - * Models](https://cloud.google.com/speech-to-text/v2/docs/speech-to-text-supported-languages). - * - * Generated from protobuf field string model = 9 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setModel($var) - { - GPBUtil::checkString($var, True); - $this->model = $var; - - return $this; - } - - /** - * Optional. The language of the supplied audio as a - * [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) language tag. - * Language tags are normalized to BCP-47 before they are used eg "en-us" - * becomes "en-US". - * Supported languages for each model are listed in the [Table of Supported - * Models](https://cloud.google.com/speech-to-text/v2/docs/speech-to-text-supported-languages). - * If additional languages are provided, recognition result will contain - * recognition in the most likely language detected. The recognition result - * will include the language tag of the language detected in the audio. - * - * Generated from protobuf field repeated string language_codes = 10 [(.google.api.field_behavior) = OPTIONAL]; - * @return RepeatedField - */ - public function getLanguageCodes() - { - return $this->language_codes; - } - - /** - * Optional. The language of the supplied audio as a - * [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) language tag. - * Language tags are normalized to BCP-47 before they are used eg "en-us" - * becomes "en-US". - * Supported languages for each model are listed in the [Table of Supported - * Models](https://cloud.google.com/speech-to-text/v2/docs/speech-to-text-supported-languages). - * If additional languages are provided, recognition result will contain - * recognition in the most likely language detected. The recognition result - * will include the language tag of the language detected in the audio. - * - * Generated from protobuf field repeated string language_codes = 10 [(.google.api.field_behavior) = OPTIONAL]; - * @param string[] $var - * @return $this - */ - public function setLanguageCodes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->language_codes = $arr; - - return $this; - } - - /** - * Speech recognition features to enable. - * - * Generated from protobuf field .google.cloud.speech.v2.RecognitionFeatures features = 2; - * @return \Google\Cloud\Speech\V2\RecognitionFeatures|null - */ - public function getFeatures() - { - return $this->features; - } - - public function hasFeatures() - { - return isset($this->features); - } - - public function clearFeatures() - { - unset($this->features); - } - - /** - * Speech recognition features to enable. - * - * Generated from protobuf field .google.cloud.speech.v2.RecognitionFeatures features = 2; - * @param \Google\Cloud\Speech\V2\RecognitionFeatures $var - * @return $this - */ - public function setFeatures($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\RecognitionFeatures::class); - $this->features = $var; - - return $this; - } - - /** - * Speech adaptation context that weights recognizer predictions for specific - * words and phrases. - * - * Generated from protobuf field .google.cloud.speech.v2.SpeechAdaptation adaptation = 6; - * @return \Google\Cloud\Speech\V2\SpeechAdaptation|null - */ - public function getAdaptation() - { - return $this->adaptation; - } - - public function hasAdaptation() - { - return isset($this->adaptation); - } - - public function clearAdaptation() - { - unset($this->adaptation); - } - - /** - * Speech adaptation context that weights recognizer predictions for specific - * words and phrases. - * - * Generated from protobuf field .google.cloud.speech.v2.SpeechAdaptation adaptation = 6; - * @param \Google\Cloud\Speech\V2\SpeechAdaptation $var - * @return $this - */ - public function setAdaptation($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\SpeechAdaptation::class); - $this->adaptation = $var; - - return $this; - } - - /** - * Optional. Use transcription normalization to automatically replace parts of - * the transcript with phrases of your choosing. For StreamingRecognize, this - * normalization only applies to stable partial transcripts (stability > 0.8) - * and final transcripts. - * - * Generated from protobuf field .google.cloud.speech.v2.TranscriptNormalization transcript_normalization = 11 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\Speech\V2\TranscriptNormalization|null - */ - public function getTranscriptNormalization() - { - return $this->transcript_normalization; - } - - public function hasTranscriptNormalization() - { - return isset($this->transcript_normalization); - } - - public function clearTranscriptNormalization() - { - unset($this->transcript_normalization); - } - - /** - * Optional. Use transcription normalization to automatically replace parts of - * the transcript with phrases of your choosing. For StreamingRecognize, this - * normalization only applies to stable partial transcripts (stability > 0.8) - * and final transcripts. - * - * Generated from protobuf field .google.cloud.speech.v2.TranscriptNormalization transcript_normalization = 11 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\Speech\V2\TranscriptNormalization $var - * @return $this - */ - public function setTranscriptNormalization($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\TranscriptNormalization::class); - $this->transcript_normalization = $var; - - return $this; - } - - /** - * Optional. Optional configuration used to automatically run translation on - * the given audio to the desired language for supported models. - * - * Generated from protobuf field .google.cloud.speech.v2.TranslationConfig translation_config = 15 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\Speech\V2\TranslationConfig|null - */ - public function getTranslationConfig() - { - return $this->translation_config; - } - - public function hasTranslationConfig() - { - return isset($this->translation_config); - } - - public function clearTranslationConfig() - { - unset($this->translation_config); - } - - /** - * Optional. Optional configuration used to automatically run translation on - * the given audio to the desired language for supported models. - * - * Generated from protobuf field .google.cloud.speech.v2.TranslationConfig translation_config = 15 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\Speech\V2\TranslationConfig $var - * @return $this - */ - public function setTranslationConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\TranslationConfig::class); - $this->translation_config = $var; - - return $this; - } - - /** - * Optional. Optional denoiser config. May not be supported for all models - * and may have no effect. - * - * Generated from protobuf field .google.cloud.speech.v2.DenoiserConfig denoiser_config = 16 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\Speech\V2\DenoiserConfig|null - */ - public function getDenoiserConfig() - { - return $this->denoiser_config; - } - - public function hasDenoiserConfig() - { - return isset($this->denoiser_config); - } - - public function clearDenoiserConfig() - { - unset($this->denoiser_config); - } - - /** - * Optional. Optional denoiser config. May not be supported for all models - * and may have no effect. - * - * Generated from protobuf field .google.cloud.speech.v2.DenoiserConfig denoiser_config = 16 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\Speech\V2\DenoiserConfig $var - * @return $this - */ - public function setDenoiserConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\DenoiserConfig::class); - $this->denoiser_config = $var; - - return $this; - } - - /** - * @return string - */ - public function getDecodingConfig() - { - return $this->whichOneof("decoding_config"); - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognitionFeatures.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognitionFeatures.php deleted file mode 100644 index f53614654057..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognitionFeatures.php +++ /dev/null @@ -1,473 +0,0 @@ -google.cloud.speech.v2.RecognitionFeatures - */ -class RecognitionFeatures extends \Google\Protobuf\Internal\Message -{ - /** - * If set to `true`, the server will attempt to filter out profanities, - * replacing all but the initial character in each filtered word with - * asterisks, for instance, "f***". If set to `false` or omitted, profanities - * won't be filtered out. - * - * Generated from protobuf field bool profanity_filter = 1; - */ - protected $profanity_filter = false; - /** - * If `true`, the top result includes a list of words and the start and end - * time offsets (timestamps) for those words. If `false`, no word-level time - * offset information is returned. The default is `false`. - * - * Generated from protobuf field bool enable_word_time_offsets = 2; - */ - protected $enable_word_time_offsets = false; - /** - * If `true`, the top result includes a list of words and the confidence for - * those words. If `false`, no word-level confidence information is returned. - * The default is `false`. - * - * Generated from protobuf field bool enable_word_confidence = 3; - */ - protected $enable_word_confidence = false; - /** - * If `true`, adds punctuation to recognition result hypotheses. This feature - * is only available in select languages. The default `false` value does not - * add punctuation to result hypotheses. - * - * Generated from protobuf field bool enable_automatic_punctuation = 4; - */ - protected $enable_automatic_punctuation = false; - /** - * The spoken punctuation behavior for the call. If `true`, replaces spoken - * punctuation with the corresponding symbols in the request. For example, - * "how are you question mark" becomes "how are you?". See - * https://cloud.google.com/speech-to-text/docs/spoken-punctuation for - * support. If `false`, spoken punctuation is not replaced. - * - * Generated from protobuf field bool enable_spoken_punctuation = 14; - */ - protected $enable_spoken_punctuation = false; - /** - * The spoken emoji behavior for the call. If `true`, adds spoken emoji - * formatting for the request. This will replace spoken emojis with the - * corresponding Unicode symbols in the final transcript. If `false`, spoken - * emojis are not replaced. - * - * Generated from protobuf field bool enable_spoken_emojis = 15; - */ - protected $enable_spoken_emojis = false; - /** - * Mode for recognizing multi-channel audio. - * - * Generated from protobuf field .google.cloud.speech.v2.RecognitionFeatures.MultiChannelMode multi_channel_mode = 17; - */ - protected $multi_channel_mode = 0; - /** - * Configuration to enable speaker diarization. To enable diarization, set - * this field to an empty SpeakerDiarizationConfig message. - * - * Generated from protobuf field .google.cloud.speech.v2.SpeakerDiarizationConfig diarization_config = 9; - */ - protected $diarization_config = null; - /** - * Maximum number of recognition hypotheses to be returned. - * The server may return fewer than `max_alternatives`. - * Valid values are `0`-`30`. A value of `0` or `1` will return a maximum of - * one. If omitted, will return a maximum of one. - * - * Generated from protobuf field int32 max_alternatives = 16; - */ - protected $max_alternatives = 0; - /** - * Optional. Configuration to enable custom prompt for chirp3. - * - * Generated from protobuf field .google.cloud.speech.v2.CustomPromptConfig custom_prompt_config = 18 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $custom_prompt_config = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type bool $profanity_filter - * If set to `true`, the server will attempt to filter out profanities, - * replacing all but the initial character in each filtered word with - * asterisks, for instance, "f***". If set to `false` or omitted, profanities - * won't be filtered out. - * @type bool $enable_word_time_offsets - * If `true`, the top result includes a list of words and the start and end - * time offsets (timestamps) for those words. If `false`, no word-level time - * offset information is returned. The default is `false`. - * @type bool $enable_word_confidence - * If `true`, the top result includes a list of words and the confidence for - * those words. If `false`, no word-level confidence information is returned. - * The default is `false`. - * @type bool $enable_automatic_punctuation - * If `true`, adds punctuation to recognition result hypotheses. This feature - * is only available in select languages. The default `false` value does not - * add punctuation to result hypotheses. - * @type bool $enable_spoken_punctuation - * The spoken punctuation behavior for the call. If `true`, replaces spoken - * punctuation with the corresponding symbols in the request. For example, - * "how are you question mark" becomes "how are you?". See - * https://cloud.google.com/speech-to-text/docs/spoken-punctuation for - * support. If `false`, spoken punctuation is not replaced. - * @type bool $enable_spoken_emojis - * The spoken emoji behavior for the call. If `true`, adds spoken emoji - * formatting for the request. This will replace spoken emojis with the - * corresponding Unicode symbols in the final transcript. If `false`, spoken - * emojis are not replaced. - * @type int $multi_channel_mode - * Mode for recognizing multi-channel audio. - * @type \Google\Cloud\Speech\V2\SpeakerDiarizationConfig $diarization_config - * Configuration to enable speaker diarization. To enable diarization, set - * this field to an empty SpeakerDiarizationConfig message. - * @type int $max_alternatives - * Maximum number of recognition hypotheses to be returned. - * The server may return fewer than `max_alternatives`. - * Valid values are `0`-`30`. A value of `0` or `1` will return a maximum of - * one. If omitted, will return a maximum of one. - * @type \Google\Cloud\Speech\V2\CustomPromptConfig $custom_prompt_config - * Optional. Configuration to enable custom prompt for chirp3. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * If set to `true`, the server will attempt to filter out profanities, - * replacing all but the initial character in each filtered word with - * asterisks, for instance, "f***". If set to `false` or omitted, profanities - * won't be filtered out. - * - * Generated from protobuf field bool profanity_filter = 1; - * @return bool - */ - public function getProfanityFilter() - { - return $this->profanity_filter; - } - - /** - * If set to `true`, the server will attempt to filter out profanities, - * replacing all but the initial character in each filtered word with - * asterisks, for instance, "f***". If set to `false` or omitted, profanities - * won't be filtered out. - * - * Generated from protobuf field bool profanity_filter = 1; - * @param bool $var - * @return $this - */ - public function setProfanityFilter($var) - { - GPBUtil::checkBool($var); - $this->profanity_filter = $var; - - return $this; - } - - /** - * If `true`, the top result includes a list of words and the start and end - * time offsets (timestamps) for those words. If `false`, no word-level time - * offset information is returned. The default is `false`. - * - * Generated from protobuf field bool enable_word_time_offsets = 2; - * @return bool - */ - public function getEnableWordTimeOffsets() - { - return $this->enable_word_time_offsets; - } - - /** - * If `true`, the top result includes a list of words and the start and end - * time offsets (timestamps) for those words. If `false`, no word-level time - * offset information is returned. The default is `false`. - * - * Generated from protobuf field bool enable_word_time_offsets = 2; - * @param bool $var - * @return $this - */ - public function setEnableWordTimeOffsets($var) - { - GPBUtil::checkBool($var); - $this->enable_word_time_offsets = $var; - - return $this; - } - - /** - * If `true`, the top result includes a list of words and the confidence for - * those words. If `false`, no word-level confidence information is returned. - * The default is `false`. - * - * Generated from protobuf field bool enable_word_confidence = 3; - * @return bool - */ - public function getEnableWordConfidence() - { - return $this->enable_word_confidence; - } - - /** - * If `true`, the top result includes a list of words and the confidence for - * those words. If `false`, no word-level confidence information is returned. - * The default is `false`. - * - * Generated from protobuf field bool enable_word_confidence = 3; - * @param bool $var - * @return $this - */ - public function setEnableWordConfidence($var) - { - GPBUtil::checkBool($var); - $this->enable_word_confidence = $var; - - return $this; - } - - /** - * If `true`, adds punctuation to recognition result hypotheses. This feature - * is only available in select languages. The default `false` value does not - * add punctuation to result hypotheses. - * - * Generated from protobuf field bool enable_automatic_punctuation = 4; - * @return bool - */ - public function getEnableAutomaticPunctuation() - { - return $this->enable_automatic_punctuation; - } - - /** - * If `true`, adds punctuation to recognition result hypotheses. This feature - * is only available in select languages. The default `false` value does not - * add punctuation to result hypotheses. - * - * Generated from protobuf field bool enable_automatic_punctuation = 4; - * @param bool $var - * @return $this - */ - public function setEnableAutomaticPunctuation($var) - { - GPBUtil::checkBool($var); - $this->enable_automatic_punctuation = $var; - - return $this; - } - - /** - * The spoken punctuation behavior for the call. If `true`, replaces spoken - * punctuation with the corresponding symbols in the request. For example, - * "how are you question mark" becomes "how are you?". See - * https://cloud.google.com/speech-to-text/docs/spoken-punctuation for - * support. If `false`, spoken punctuation is not replaced. - * - * Generated from protobuf field bool enable_spoken_punctuation = 14; - * @return bool - */ - public function getEnableSpokenPunctuation() - { - return $this->enable_spoken_punctuation; - } - - /** - * The spoken punctuation behavior for the call. If `true`, replaces spoken - * punctuation with the corresponding symbols in the request. For example, - * "how are you question mark" becomes "how are you?". See - * https://cloud.google.com/speech-to-text/docs/spoken-punctuation for - * support. If `false`, spoken punctuation is not replaced. - * - * Generated from protobuf field bool enable_spoken_punctuation = 14; - * @param bool $var - * @return $this - */ - public function setEnableSpokenPunctuation($var) - { - GPBUtil::checkBool($var); - $this->enable_spoken_punctuation = $var; - - return $this; - } - - /** - * The spoken emoji behavior for the call. If `true`, adds spoken emoji - * formatting for the request. This will replace spoken emojis with the - * corresponding Unicode symbols in the final transcript. If `false`, spoken - * emojis are not replaced. - * - * Generated from protobuf field bool enable_spoken_emojis = 15; - * @return bool - */ - public function getEnableSpokenEmojis() - { - return $this->enable_spoken_emojis; - } - - /** - * The spoken emoji behavior for the call. If `true`, adds spoken emoji - * formatting for the request. This will replace spoken emojis with the - * corresponding Unicode symbols in the final transcript. If `false`, spoken - * emojis are not replaced. - * - * Generated from protobuf field bool enable_spoken_emojis = 15; - * @param bool $var - * @return $this - */ - public function setEnableSpokenEmojis($var) - { - GPBUtil::checkBool($var); - $this->enable_spoken_emojis = $var; - - return $this; - } - - /** - * Mode for recognizing multi-channel audio. - * - * Generated from protobuf field .google.cloud.speech.v2.RecognitionFeatures.MultiChannelMode multi_channel_mode = 17; - * @return int - */ - public function getMultiChannelMode() - { - return $this->multi_channel_mode; - } - - /** - * Mode for recognizing multi-channel audio. - * - * Generated from protobuf field .google.cloud.speech.v2.RecognitionFeatures.MultiChannelMode multi_channel_mode = 17; - * @param int $var - * @return $this - */ - public function setMultiChannelMode($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Speech\V2\RecognitionFeatures\MultiChannelMode::class); - $this->multi_channel_mode = $var; - - return $this; - } - - /** - * Configuration to enable speaker diarization. To enable diarization, set - * this field to an empty SpeakerDiarizationConfig message. - * - * Generated from protobuf field .google.cloud.speech.v2.SpeakerDiarizationConfig diarization_config = 9; - * @return \Google\Cloud\Speech\V2\SpeakerDiarizationConfig|null - */ - public function getDiarizationConfig() - { - return $this->diarization_config; - } - - public function hasDiarizationConfig() - { - return isset($this->diarization_config); - } - - public function clearDiarizationConfig() - { - unset($this->diarization_config); - } - - /** - * Configuration to enable speaker diarization. To enable diarization, set - * this field to an empty SpeakerDiarizationConfig message. - * - * Generated from protobuf field .google.cloud.speech.v2.SpeakerDiarizationConfig diarization_config = 9; - * @param \Google\Cloud\Speech\V2\SpeakerDiarizationConfig $var - * @return $this - */ - public function setDiarizationConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\SpeakerDiarizationConfig::class); - $this->diarization_config = $var; - - return $this; - } - - /** - * Maximum number of recognition hypotheses to be returned. - * The server may return fewer than `max_alternatives`. - * Valid values are `0`-`30`. A value of `0` or `1` will return a maximum of - * one. If omitted, will return a maximum of one. - * - * Generated from protobuf field int32 max_alternatives = 16; - * @return int - */ - public function getMaxAlternatives() - { - return $this->max_alternatives; - } - - /** - * Maximum number of recognition hypotheses to be returned. - * The server may return fewer than `max_alternatives`. - * Valid values are `0`-`30`. A value of `0` or `1` will return a maximum of - * one. If omitted, will return a maximum of one. - * - * Generated from protobuf field int32 max_alternatives = 16; - * @param int $var - * @return $this - */ - public function setMaxAlternatives($var) - { - GPBUtil::checkInt32($var); - $this->max_alternatives = $var; - - return $this; - } - - /** - * Optional. Configuration to enable custom prompt for chirp3. - * - * Generated from protobuf field .google.cloud.speech.v2.CustomPromptConfig custom_prompt_config = 18 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\Speech\V2\CustomPromptConfig|null - */ - public function getCustomPromptConfig() - { - return $this->custom_prompt_config; - } - - public function hasCustomPromptConfig() - { - return isset($this->custom_prompt_config); - } - - public function clearCustomPromptConfig() - { - unset($this->custom_prompt_config); - } - - /** - * Optional. Configuration to enable custom prompt for chirp3. - * - * Generated from protobuf field .google.cloud.speech.v2.CustomPromptConfig custom_prompt_config = 18 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\Speech\V2\CustomPromptConfig $var - * @return $this - */ - public function setCustomPromptConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\CustomPromptConfig::class); - $this->custom_prompt_config = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognitionFeatures/MultiChannelMode.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognitionFeatures/MultiChannelMode.php deleted file mode 100644 index a1b656025dfa..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognitionFeatures/MultiChannelMode.php +++ /dev/null @@ -1,58 +0,0 @@ -google.cloud.speech.v2.RecognitionFeatures.MultiChannelMode - */ -class MultiChannelMode -{ - /** - * Default value for the multi-channel mode. If the audio contains - * multiple channels, only the first channel will be transcribed; other - * channels will be ignored. - * - * Generated from protobuf enum MULTI_CHANNEL_MODE_UNSPECIFIED = 0; - */ - const MULTI_CHANNEL_MODE_UNSPECIFIED = 0; - /** - * If selected, each channel in the provided audio is transcribed - * independently. This cannot be selected if the selected - * [model][google.cloud.speech.v2.Recognizer.model] is `latest_short`. - * - * Generated from protobuf enum SEPARATE_RECOGNITION_PER_CHANNEL = 1; - */ - const SEPARATE_RECOGNITION_PER_CHANNEL = 1; - - private static $valueToName = [ - self::MULTI_CHANNEL_MODE_UNSPECIFIED => 'MULTI_CHANNEL_MODE_UNSPECIFIED', - self::SEPARATE_RECOGNITION_PER_CHANNEL => 'SEPARATE_RECOGNITION_PER_CHANNEL', - ]; - - 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/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognitionOutputConfig.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognitionOutputConfig.php deleted file mode 100644 index 41054fa5bf14..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognitionOutputConfig.php +++ /dev/null @@ -1,171 +0,0 @@ -google.cloud.speech.v2.RecognitionOutputConfig - */ -class RecognitionOutputConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. Configuration for the format of the results stored to `output`. - * If unspecified transcripts will be written in the `NATIVE` format only. - * - * Generated from protobuf field .google.cloud.speech.v2.OutputFormatConfig output_format_config = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $output_format_config = null; - protected $output; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Speech\V2\GcsOutputConfig $gcs_output_config - * If this message is populated, recognition results are written to the - * provided Google Cloud Storage URI. - * @type \Google\Cloud\Speech\V2\InlineOutputConfig $inline_response_config - * If this message is populated, recognition results are provided in the - * [BatchRecognizeResponse][google.cloud.speech.v2.BatchRecognizeResponse] - * message of the Operation when completed. This is only supported when - * calling [BatchRecognize][google.cloud.speech.v2.Speech.BatchRecognize] - * with just one audio file. - * @type \Google\Cloud\Speech\V2\OutputFormatConfig $output_format_config - * Optional. Configuration for the format of the results stored to `output`. - * If unspecified transcripts will be written in the `NATIVE` format only. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * If this message is populated, recognition results are written to the - * provided Google Cloud Storage URI. - * - * Generated from protobuf field .google.cloud.speech.v2.GcsOutputConfig gcs_output_config = 1; - * @return \Google\Cloud\Speech\V2\GcsOutputConfig|null - */ - public function getGcsOutputConfig() - { - return $this->readOneof(1); - } - - public function hasGcsOutputConfig() - { - return $this->hasOneof(1); - } - - /** - * If this message is populated, recognition results are written to the - * provided Google Cloud Storage URI. - * - * Generated from protobuf field .google.cloud.speech.v2.GcsOutputConfig gcs_output_config = 1; - * @param \Google\Cloud\Speech\V2\GcsOutputConfig $var - * @return $this - */ - public function setGcsOutputConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\GcsOutputConfig::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * If this message is populated, recognition results are provided in the - * [BatchRecognizeResponse][google.cloud.speech.v2.BatchRecognizeResponse] - * message of the Operation when completed. This is only supported when - * calling [BatchRecognize][google.cloud.speech.v2.Speech.BatchRecognize] - * with just one audio file. - * - * Generated from protobuf field .google.cloud.speech.v2.InlineOutputConfig inline_response_config = 2; - * @return \Google\Cloud\Speech\V2\InlineOutputConfig|null - */ - public function getInlineResponseConfig() - { - return $this->readOneof(2); - } - - public function hasInlineResponseConfig() - { - return $this->hasOneof(2); - } - - /** - * If this message is populated, recognition results are provided in the - * [BatchRecognizeResponse][google.cloud.speech.v2.BatchRecognizeResponse] - * message of the Operation when completed. This is only supported when - * calling [BatchRecognize][google.cloud.speech.v2.Speech.BatchRecognize] - * with just one audio file. - * - * Generated from protobuf field .google.cloud.speech.v2.InlineOutputConfig inline_response_config = 2; - * @param \Google\Cloud\Speech\V2\InlineOutputConfig $var - * @return $this - */ - public function setInlineResponseConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\InlineOutputConfig::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * Optional. Configuration for the format of the results stored to `output`. - * If unspecified transcripts will be written in the `NATIVE` format only. - * - * Generated from protobuf field .google.cloud.speech.v2.OutputFormatConfig output_format_config = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\Speech\V2\OutputFormatConfig|null - */ - public function getOutputFormatConfig() - { - return $this->output_format_config; - } - - public function hasOutputFormatConfig() - { - return isset($this->output_format_config); - } - - public function clearOutputFormatConfig() - { - unset($this->output_format_config); - } - - /** - * Optional. Configuration for the format of the results stored to `output`. - * If unspecified transcripts will be written in the `NATIVE` format only. - * - * Generated from protobuf field .google.cloud.speech.v2.OutputFormatConfig output_format_config = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\Speech\V2\OutputFormatConfig $var - * @return $this - */ - public function setOutputFormatConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\OutputFormatConfig::class); - $this->output_format_config = $var; - - return $this; - } - - /** - * @return string - */ - public function getOutput() - { - return $this->whichOneof("output"); - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognitionResponseMetadata.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognitionResponseMetadata.php deleted file mode 100644 index 1fd568b071ec..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognitionResponseMetadata.php +++ /dev/null @@ -1,159 +0,0 @@ -google.cloud.speech.v2.RecognitionResponseMetadata - */ -class RecognitionResponseMetadata extends \Google\Protobuf\Internal\Message -{ - /** - * Global request identifier auto-generated by the API. - * - * Generated from protobuf field string request_id = 9 [(.google.api.field_info) = { - */ - protected $request_id = ''; - /** - * When available, billed audio seconds for the corresponding request. - * - * Generated from protobuf field .google.protobuf.Duration total_billed_duration = 6; - */ - protected $total_billed_duration = null; - /** - * Optional. Output only. Provides the prompt used for the recognition - * request. - * - * Generated from protobuf field optional string prompt = 10 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = OPTIONAL]; - */ - protected $prompt = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $request_id - * Global request identifier auto-generated by the API. - * @type \Google\Protobuf\Duration $total_billed_duration - * When available, billed audio seconds for the corresponding request. - * @type string $prompt - * Optional. Output only. Provides the prompt used for the recognition - * request. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Global request identifier auto-generated by the API. - * - * Generated from protobuf field string request_id = 9 [(.google.api.field_info) = { - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Global request identifier auto-generated by the API. - * - * Generated from protobuf field string request_id = 9 [(.google.api.field_info) = { - * @param string $var - * @return $this - */ - public function setRequestId($var) - { - GPBUtil::checkString($var, True); - $this->request_id = $var; - - return $this; - } - - /** - * When available, billed audio seconds for the corresponding request. - * - * Generated from protobuf field .google.protobuf.Duration total_billed_duration = 6; - * @return \Google\Protobuf\Duration|null - */ - public function getTotalBilledDuration() - { - return $this->total_billed_duration; - } - - public function hasTotalBilledDuration() - { - return isset($this->total_billed_duration); - } - - public function clearTotalBilledDuration() - { - unset($this->total_billed_duration); - } - - /** - * When available, billed audio seconds for the corresponding request. - * - * Generated from protobuf field .google.protobuf.Duration total_billed_duration = 6; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setTotalBilledDuration($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->total_billed_duration = $var; - - return $this; - } - - /** - * Optional. Output only. Provides the prompt used for the recognition - * request. - * - * Generated from protobuf field optional string prompt = 10 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getPrompt() - { - return isset($this->prompt) ? $this->prompt : ''; - } - - public function hasPrompt() - { - return isset($this->prompt); - } - - public function clearPrompt() - { - unset($this->prompt); - } - - /** - * Optional. Output only. Provides the prompt used for the recognition - * request. - * - * Generated from protobuf field optional string prompt = 10 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setPrompt($var) - { - GPBUtil::checkString($var, True); - $this->prompt = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognizeRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognizeRequest.php deleted file mode 100644 index 823ef1be1a1c..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognizeRequest.php +++ /dev/null @@ -1,434 +0,0 @@ -google.cloud.speech.v2.RecognizeRequest - */ -class RecognizeRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the Recognizer to use during recognition. The - * expected format is - * `projects/{project}/locations/{location}/recognizers/{recognizer}`. The - * {recognizer} segment may be set to `_` to use an empty implicit Recognizer. - * - * Generated from protobuf field string recognizer = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $recognizer = ''; - /** - * Features and audio metadata to use for the Automatic Speech Recognition. - * This field in combination with the - * [config_mask][google.cloud.speech.v2.RecognizeRequest.config_mask] field - * can be used to override parts of the - * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] - * of the Recognizer resource. - * - * Generated from protobuf field .google.cloud.speech.v2.RecognitionConfig config = 1; - */ - protected $config = null; - /** - * The list of fields in - * [config][google.cloud.speech.v2.RecognizeRequest.config] that override the - * values in the - * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] - * of the recognizer during this recognition request. If no mask is provided, - * all non-default valued fields in - * [config][google.cloud.speech.v2.RecognizeRequest.config] override the - * values in the recognizer for this recognition request. If a mask is - * provided, only the fields listed in the mask override the config in the - * recognizer for this recognition request. If a wildcard (`*`) is provided, - * [config][google.cloud.speech.v2.RecognizeRequest.config] completely - * overrides and replaces the config in the recognizer for this recognition - * request. - * - * Generated from protobuf field .google.protobuf.FieldMask config_mask = 8; - */ - protected $config_mask = null; - protected $audio_source; - - /** - * @param string $recognizer Required. The name of the Recognizer to use during recognition. The - * expected format is - * `projects/{project}/locations/{location}/recognizers/{recognizer}`. The - * {recognizer} segment may be set to `_` to use an empty implicit Recognizer. Please see - * {@see SpeechClient::recognizerName()} for help formatting this field. - * @param \Google\Cloud\Speech\V2\RecognitionConfig $config Features and audio metadata to use for the Automatic Speech Recognition. - * This field in combination with the - * [config_mask][google.cloud.speech.v2.RecognizeRequest.config_mask] field - * can be used to override parts of the - * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] - * of the Recognizer resource. - * @param \Google\Protobuf\FieldMask $configMask The list of fields in - * [config][google.cloud.speech.v2.RecognizeRequest.config] that override the - * values in the - * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] - * of the recognizer during this recognition request. If no mask is provided, - * all non-default valued fields in - * [config][google.cloud.speech.v2.RecognizeRequest.config] override the - * values in the recognizer for this recognition request. If a mask is - * provided, only the fields listed in the mask override the config in the - * recognizer for this recognition request. If a wildcard (`*`) is provided, - * [config][google.cloud.speech.v2.RecognizeRequest.config] completely - * overrides and replaces the config in the recognizer for this recognition - * request. - * @param string $content The audio data bytes encoded as specified in - * [RecognitionConfig][google.cloud.speech.v2.RecognitionConfig]. As - * with all bytes fields, proto buffers use a pure binary representation, - * whereas JSON representations use base64. - * - * @return \Google\Cloud\Speech\V2\RecognizeRequest - * - * @experimental - */ - public static function build(string $recognizer, \Google\Cloud\Speech\V2\RecognitionConfig $config, \Google\Protobuf\FieldMask $configMask, string $content): self - { - return (new self()) - ->setRecognizer($recognizer) - ->setConfig($config) - ->setConfigMask($configMask) - ->setContent($content); - } - - /** - * @param string $recognizer Required. The name of the Recognizer to use during recognition. The - * expected format is - * `projects/{project}/locations/{location}/recognizers/{recognizer}`. The - * {recognizer} segment may be set to `_` to use an empty implicit Recognizer. Please see - * {@see SpeechClient::recognizerName()} for help formatting this field. - * @param \Google\Cloud\Speech\V2\RecognitionConfig $config Features and audio metadata to use for the Automatic Speech Recognition. - * This field in combination with the - * [config_mask][google.cloud.speech.v2.RecognizeRequest.config_mask] field - * can be used to override parts of the - * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] - * of the Recognizer resource. - * @param \Google\Protobuf\FieldMask $configMask The list of fields in - * [config][google.cloud.speech.v2.RecognizeRequest.config] that override the - * values in the - * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] - * of the recognizer during this recognition request. If no mask is provided, - * all non-default valued fields in - * [config][google.cloud.speech.v2.RecognizeRequest.config] override the - * values in the recognizer for this recognition request. If a mask is - * provided, only the fields listed in the mask override the config in the - * recognizer for this recognition request. If a wildcard (`*`) is provided, - * [config][google.cloud.speech.v2.RecognizeRequest.config] completely - * overrides and replaces the config in the recognizer for this recognition - * request. - * @param string $uri URI that points to a file that contains audio data bytes as specified in - * [RecognitionConfig][google.cloud.speech.v2.RecognitionConfig]. The file - * must not be compressed (for example, gzip). Currently, only Google Cloud - * Storage URIs are supported, which must be specified in the following - * format: `gs://bucket_name/object_name` (other URI formats return - * [INVALID_ARGUMENT][google.rpc.Code.INVALID_ARGUMENT]). For more - * information, see [Request - * URIs](https://cloud.google.com/storage/docs/reference-uris). - * - * @return \Google\Cloud\Speech\V2\RecognizeRequest - * - * @experimental - */ - public static function buildFromRecognizerConfigConfigMaskUri(string $recognizer, \Google\Cloud\Speech\V2\RecognitionConfig $config, \Google\Protobuf\FieldMask $configMask, string $uri): self - { - return (new self()) - ->setRecognizer($recognizer) - ->setConfig($config) - ->setConfigMask($configMask) - ->setUri($uri); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $recognizer - * Required. The name of the Recognizer to use during recognition. The - * expected format is - * `projects/{project}/locations/{location}/recognizers/{recognizer}`. The - * {recognizer} segment may be set to `_` to use an empty implicit Recognizer. - * @type \Google\Cloud\Speech\V2\RecognitionConfig $config - * Features and audio metadata to use for the Automatic Speech Recognition. - * This field in combination with the - * [config_mask][google.cloud.speech.v2.RecognizeRequest.config_mask] field - * can be used to override parts of the - * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] - * of the Recognizer resource. - * @type \Google\Protobuf\FieldMask $config_mask - * The list of fields in - * [config][google.cloud.speech.v2.RecognizeRequest.config] that override the - * values in the - * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] - * of the recognizer during this recognition request. If no mask is provided, - * all non-default valued fields in - * [config][google.cloud.speech.v2.RecognizeRequest.config] override the - * values in the recognizer for this recognition request. If a mask is - * provided, only the fields listed in the mask override the config in the - * recognizer for this recognition request. If a wildcard (`*`) is provided, - * [config][google.cloud.speech.v2.RecognizeRequest.config] completely - * overrides and replaces the config in the recognizer for this recognition - * request. - * @type string $content - * The audio data bytes encoded as specified in - * [RecognitionConfig][google.cloud.speech.v2.RecognitionConfig]. As - * with all bytes fields, proto buffers use a pure binary representation, - * whereas JSON representations use base64. - * @type string $uri - * URI that points to a file that contains audio data bytes as specified in - * [RecognitionConfig][google.cloud.speech.v2.RecognitionConfig]. The file - * must not be compressed (for example, gzip). Currently, only Google Cloud - * Storage URIs are supported, which must be specified in the following - * format: `gs://bucket_name/object_name` (other URI formats return - * [INVALID_ARGUMENT][google.rpc.Code.INVALID_ARGUMENT]). For more - * information, see [Request - * URIs](https://cloud.google.com/storage/docs/reference-uris). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the Recognizer to use during recognition. The - * expected format is - * `projects/{project}/locations/{location}/recognizers/{recognizer}`. The - * {recognizer} segment may be set to `_` to use an empty implicit Recognizer. - * - * Generated from protobuf field string recognizer = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getRecognizer() - { - return $this->recognizer; - } - - /** - * Required. The name of the Recognizer to use during recognition. The - * expected format is - * `projects/{project}/locations/{location}/recognizers/{recognizer}`. The - * {recognizer} segment may be set to `_` to use an empty implicit Recognizer. - * - * Generated from protobuf field string recognizer = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setRecognizer($var) - { - GPBUtil::checkString($var, True); - $this->recognizer = $var; - - return $this; - } - - /** - * Features and audio metadata to use for the Automatic Speech Recognition. - * This field in combination with the - * [config_mask][google.cloud.speech.v2.RecognizeRequest.config_mask] field - * can be used to override parts of the - * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] - * of the Recognizer resource. - * - * Generated from protobuf field .google.cloud.speech.v2.RecognitionConfig config = 1; - * @return \Google\Cloud\Speech\V2\RecognitionConfig|null - */ - public function getConfig() - { - return $this->config; - } - - public function hasConfig() - { - return isset($this->config); - } - - public function clearConfig() - { - unset($this->config); - } - - /** - * Features and audio metadata to use for the Automatic Speech Recognition. - * This field in combination with the - * [config_mask][google.cloud.speech.v2.RecognizeRequest.config_mask] field - * can be used to override parts of the - * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] - * of the Recognizer resource. - * - * Generated from protobuf field .google.cloud.speech.v2.RecognitionConfig config = 1; - * @param \Google\Cloud\Speech\V2\RecognitionConfig $var - * @return $this - */ - public function setConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\RecognitionConfig::class); - $this->config = $var; - - return $this; - } - - /** - * The list of fields in - * [config][google.cloud.speech.v2.RecognizeRequest.config] that override the - * values in the - * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] - * of the recognizer during this recognition request. If no mask is provided, - * all non-default valued fields in - * [config][google.cloud.speech.v2.RecognizeRequest.config] override the - * values in the recognizer for this recognition request. If a mask is - * provided, only the fields listed in the mask override the config in the - * recognizer for this recognition request. If a wildcard (`*`) is provided, - * [config][google.cloud.speech.v2.RecognizeRequest.config] completely - * overrides and replaces the config in the recognizer for this recognition - * request. - * - * Generated from protobuf field .google.protobuf.FieldMask config_mask = 8; - * @return \Google\Protobuf\FieldMask|null - */ - public function getConfigMask() - { - return $this->config_mask; - } - - public function hasConfigMask() - { - return isset($this->config_mask); - } - - public function clearConfigMask() - { - unset($this->config_mask); - } - - /** - * The list of fields in - * [config][google.cloud.speech.v2.RecognizeRequest.config] that override the - * values in the - * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] - * of the recognizer during this recognition request. If no mask is provided, - * all non-default valued fields in - * [config][google.cloud.speech.v2.RecognizeRequest.config] override the - * values in the recognizer for this recognition request. If a mask is - * provided, only the fields listed in the mask override the config in the - * recognizer for this recognition request. If a wildcard (`*`) is provided, - * [config][google.cloud.speech.v2.RecognizeRequest.config] completely - * overrides and replaces the config in the recognizer for this recognition - * request. - * - * Generated from protobuf field .google.protobuf.FieldMask config_mask = 8; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setConfigMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->config_mask = $var; - - return $this; - } - - /** - * The audio data bytes encoded as specified in - * [RecognitionConfig][google.cloud.speech.v2.RecognitionConfig]. As - * with all bytes fields, proto buffers use a pure binary representation, - * whereas JSON representations use base64. - * - * Generated from protobuf field bytes content = 5; - * @return string - */ - public function getContent() - { - return $this->readOneof(5); - } - - public function hasContent() - { - return $this->hasOneof(5); - } - - /** - * The audio data bytes encoded as specified in - * [RecognitionConfig][google.cloud.speech.v2.RecognitionConfig]. As - * with all bytes fields, proto buffers use a pure binary representation, - * whereas JSON representations use base64. - * - * Generated from protobuf field bytes content = 5; - * @param string $var - * @return $this - */ - public function setContent($var) - { - GPBUtil::checkString($var, False); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * URI that points to a file that contains audio data bytes as specified in - * [RecognitionConfig][google.cloud.speech.v2.RecognitionConfig]. The file - * must not be compressed (for example, gzip). Currently, only Google Cloud - * Storage URIs are supported, which must be specified in the following - * format: `gs://bucket_name/object_name` (other URI formats return - * [INVALID_ARGUMENT][google.rpc.Code.INVALID_ARGUMENT]). For more - * information, see [Request - * URIs](https://cloud.google.com/storage/docs/reference-uris). - * - * Generated from protobuf field string uri = 6; - * @return string - */ - public function getUri() - { - return $this->readOneof(6); - } - - public function hasUri() - { - return $this->hasOneof(6); - } - - /** - * URI that points to a file that contains audio data bytes as specified in - * [RecognitionConfig][google.cloud.speech.v2.RecognitionConfig]. The file - * must not be compressed (for example, gzip). Currently, only Google Cloud - * Storage URIs are supported, which must be specified in the following - * format: `gs://bucket_name/object_name` (other URI formats return - * [INVALID_ARGUMENT][google.rpc.Code.INVALID_ARGUMENT]). For more - * information, see [Request - * URIs](https://cloud.google.com/storage/docs/reference-uris). - * - * Generated from protobuf field string uri = 6; - * @param string $var - * @return $this - */ - public function setUri($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(6, $var); - - return $this; - } - - /** - * @return string - */ - public function getAudioSource() - { - return $this->whichOneof("audio_source"); - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognizeResponse.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognizeResponse.php deleted file mode 100644 index ff783930527a..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/RecognizeResponse.php +++ /dev/null @@ -1,116 +0,0 @@ -google.cloud.speech.v2.RecognizeResponse - */ -class RecognizeResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Sequential list of transcription results corresponding to sequential - * portions of audio. - * - * Generated from protobuf field repeated .google.cloud.speech.v2.SpeechRecognitionResult results = 3; - */ - private $results; - /** - * Metadata about the recognition. - * - * Generated from protobuf field .google.cloud.speech.v2.RecognitionResponseMetadata metadata = 2; - */ - protected $metadata = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Speech\V2\SpeechRecognitionResult[] $results - * Sequential list of transcription results corresponding to sequential - * portions of audio. - * @type \Google\Cloud\Speech\V2\RecognitionResponseMetadata $metadata - * Metadata about the recognition. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Sequential list of transcription results corresponding to sequential - * portions of audio. - * - * Generated from protobuf field repeated .google.cloud.speech.v2.SpeechRecognitionResult results = 3; - * @return RepeatedField<\Google\Cloud\Speech\V2\SpeechRecognitionResult> - */ - public function getResults() - { - return $this->results; - } - - /** - * Sequential list of transcription results corresponding to sequential - * portions of audio. - * - * Generated from protobuf field repeated .google.cloud.speech.v2.SpeechRecognitionResult results = 3; - * @param \Google\Cloud\Speech\V2\SpeechRecognitionResult[] $var - * @return $this - */ - public function setResults($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Speech\V2\SpeechRecognitionResult::class); - $this->results = $arr; - - return $this; - } - - /** - * Metadata about the recognition. - * - * Generated from protobuf field .google.cloud.speech.v2.RecognitionResponseMetadata metadata = 2; - * @return \Google\Cloud\Speech\V2\RecognitionResponseMetadata|null - */ - public function getMetadata() - { - return $this->metadata; - } - - public function hasMetadata() - { - return isset($this->metadata); - } - - public function clearMetadata() - { - unset($this->metadata); - } - - /** - * Metadata about the recognition. - * - * Generated from protobuf field .google.cloud.speech.v2.RecognitionResponseMetadata metadata = 2; - * @param \Google\Cloud\Speech\V2\RecognitionResponseMetadata $var - * @return $this - */ - public function setMetadata($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\RecognitionResponseMetadata::class); - $this->metadata = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/Recognizer.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/Recognizer.php deleted file mode 100644 index dc1b0485f5ce..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/Recognizer.php +++ /dev/null @@ -1,799 +0,0 @@ -google.cloud.speech.v2.Recognizer - */ -class Recognizer extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. Identifier. The resource name of the Recognizer. - * Format: `projects/{project}/locations/{location}/recognizers/{recognizer}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IDENTIFIER]; - */ - protected $name = ''; - /** - * Output only. System-assigned unique identifier for the Recognizer. - * - * Generated from protobuf field string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $uid = ''; - /** - * User-settable, human-readable name for the Recognizer. Must be 63 - * characters or less. - * - * Generated from protobuf field string display_name = 3; - */ - protected $display_name = ''; - /** - * Optional. This field is now deprecated. Prefer the - * [`model`][google.cloud.speech.v2.RecognitionConfig.model] field in the - * [`RecognitionConfig`][google.cloud.speech.v2.RecognitionConfig] message. - * Which model to use for recognition requests. Select the model best suited - * to your domain to get best results. - * Guidance for choosing which model to use can be found in the [Transcription - * Models - * Documentation](https://cloud.google.com/speech-to-text/v2/docs/transcription-model) - * and the models supported in each region can be found in the [Table Of - * Supported - * Models](https://cloud.google.com/speech-to-text/v2/docs/speech-to-text-supported-languages). - * - * Generated from protobuf field string model = 4 [deprecated = true, (.google.api.field_behavior) = OPTIONAL]; - * @deprecated - */ - protected $model = ''; - /** - * Optional. This field is now deprecated. Prefer the - * [`language_codes`][google.cloud.speech.v2.RecognitionConfig.language_codes] - * field in the - * [`RecognitionConfig`][google.cloud.speech.v2.RecognitionConfig] message. - * The language of the supplied audio as a - * [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) language tag. - * Supported languages for each model are listed in the [Table of Supported - * Models](https://cloud.google.com/speech-to-text/v2/docs/speech-to-text-supported-languages). - * If additional languages are provided, recognition result will contain - * recognition in the most likely language detected. The recognition result - * will include the language tag of the language detected in the audio. - * When you create or update a Recognizer, these values are - * stored in normalized BCP-47 form. For example, "en-us" is stored as - * "en-US". - * - * Generated from protobuf field repeated string language_codes = 17 [deprecated = true, (.google.api.field_behavior) = OPTIONAL]; - * @deprecated - */ - private $language_codes; - /** - * Default configuration to use for requests with this Recognizer. - * This can be overwritten by inline configuration in the - * [RecognizeRequest.config][google.cloud.speech.v2.RecognizeRequest.config] - * field. - * - * Generated from protobuf field .google.cloud.speech.v2.RecognitionConfig default_recognition_config = 6; - */ - protected $default_recognition_config = null; - /** - * Allows users to store small amounts of arbitrary data. - * Both the key and the value must be 63 characters or less each. - * At most 100 annotations. - * - * Generated from protobuf field map annotations = 7; - */ - private $annotations; - /** - * Output only. The Recognizer lifecycle state. - * - * Generated from protobuf field .google.cloud.speech.v2.Recognizer.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = 0; - /** - * Output only. Creation time. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. The most recent time this Recognizer was modified. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Output only. The time at which this Recognizer was requested for deletion. - * - * Generated from protobuf field .google.protobuf.Timestamp delete_time = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $delete_time = null; - /** - * Output only. The time at which this Recognizer will be purged. - * - * Generated from protobuf field .google.protobuf.Timestamp expire_time = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $expire_time = null; - /** - * Output only. This checksum is computed by the server based on the value of - * other fields. This may be sent on update, undelete, and delete requests to - * ensure the client has an up-to-date value before proceeding. - * - * Generated from protobuf field string etag = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $etag = ''; - /** - * Output only. Whether or not this Recognizer is in the process of being - * updated. - * - * Generated from protobuf field bool reconciling = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $reconciling = false; - /** - * Output only. The [KMS key - * name](https://cloud.google.com/kms/docs/resource-hierarchy#keys) with which - * the Recognizer is encrypted. The expected format is - * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. - * - * Generated from protobuf field string kms_key_name = 15 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { - */ - protected $kms_key_name = ''; - /** - * Output only. The [KMS key version - * name](https://cloud.google.com/kms/docs/resource-hierarchy#key_versions) - * with which the Recognizer is encrypted. The expected format is - * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}/cryptoKeyVersions/{crypto_key_version}`. - * - * Generated from protobuf field string kms_key_version_name = 16 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { - */ - protected $kms_key_version_name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. Identifier. The resource name of the Recognizer. - * Format: `projects/{project}/locations/{location}/recognizers/{recognizer}`. - * @type string $uid - * Output only. System-assigned unique identifier for the Recognizer. - * @type string $display_name - * User-settable, human-readable name for the Recognizer. Must be 63 - * characters or less. - * @type string $model - * Optional. This field is now deprecated. Prefer the - * [`model`][google.cloud.speech.v2.RecognitionConfig.model] field in the - * [`RecognitionConfig`][google.cloud.speech.v2.RecognitionConfig] message. - * Which model to use for recognition requests. Select the model best suited - * to your domain to get best results. - * Guidance for choosing which model to use can be found in the [Transcription - * Models - * Documentation](https://cloud.google.com/speech-to-text/v2/docs/transcription-model) - * and the models supported in each region can be found in the [Table Of - * Supported - * Models](https://cloud.google.com/speech-to-text/v2/docs/speech-to-text-supported-languages). - * @type string[] $language_codes - * Optional. This field is now deprecated. Prefer the - * [`language_codes`][google.cloud.speech.v2.RecognitionConfig.language_codes] - * field in the - * [`RecognitionConfig`][google.cloud.speech.v2.RecognitionConfig] message. - * The language of the supplied audio as a - * [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) language tag. - * Supported languages for each model are listed in the [Table of Supported - * Models](https://cloud.google.com/speech-to-text/v2/docs/speech-to-text-supported-languages). - * If additional languages are provided, recognition result will contain - * recognition in the most likely language detected. The recognition result - * will include the language tag of the language detected in the audio. - * When you create or update a Recognizer, these values are - * stored in normalized BCP-47 form. For example, "en-us" is stored as - * "en-US". - * @type \Google\Cloud\Speech\V2\RecognitionConfig $default_recognition_config - * Default configuration to use for requests with this Recognizer. - * This can be overwritten by inline configuration in the - * [RecognizeRequest.config][google.cloud.speech.v2.RecognizeRequest.config] - * field. - * @type array|\Google\Protobuf\Internal\MapField $annotations - * Allows users to store small amounts of arbitrary data. - * Both the key and the value must be 63 characters or less each. - * At most 100 annotations. - * @type int $state - * Output only. The Recognizer lifecycle state. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. Creation time. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. The most recent time this Recognizer was modified. - * @type \Google\Protobuf\Timestamp $delete_time - * Output only. The time at which this Recognizer was requested for deletion. - * @type \Google\Protobuf\Timestamp $expire_time - * Output only. The time at which this Recognizer will be purged. - * @type string $etag - * Output only. This checksum is computed by the server based on the value of - * other fields. This may be sent on update, undelete, and delete requests to - * ensure the client has an up-to-date value before proceeding. - * @type bool $reconciling - * Output only. Whether or not this Recognizer is in the process of being - * updated. - * @type string $kms_key_name - * Output only. The [KMS key - * name](https://cloud.google.com/kms/docs/resource-hierarchy#keys) with which - * the Recognizer is encrypted. The expected format is - * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. - * @type string $kms_key_version_name - * Output only. The [KMS key version - * name](https://cloud.google.com/kms/docs/resource-hierarchy#key_versions) - * with which the Recognizer is encrypted. The expected format is - * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}/cryptoKeyVersions/{crypto_key_version}`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Output only. Identifier. The resource name of the Recognizer. - * Format: `projects/{project}/locations/{location}/recognizers/{recognizer}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IDENTIFIER]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Output only. Identifier. The resource name of the Recognizer. - * Format: `projects/{project}/locations/{location}/recognizers/{recognizer}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.field_behavior) = IDENTIFIER]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Output only. System-assigned unique identifier for the Recognizer. - * - * Generated from protobuf field string uid = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getUid() - { - return $this->uid; - } - - /** - * Output only. System-assigned unique identifier for the Recognizer. - * - * 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; - } - - /** - * User-settable, human-readable name for the Recognizer. Must be 63 - * characters or less. - * - * Generated from protobuf field string display_name = 3; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * User-settable, human-readable name for the Recognizer. Must be 63 - * characters or less. - * - * Generated from protobuf field string display_name = 3; - * @param string $var - * @return $this - */ - public function setDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->display_name = $var; - - return $this; - } - - /** - * Optional. This field is now deprecated. Prefer the - * [`model`][google.cloud.speech.v2.RecognitionConfig.model] field in the - * [`RecognitionConfig`][google.cloud.speech.v2.RecognitionConfig] message. - * Which model to use for recognition requests. Select the model best suited - * to your domain to get best results. - * Guidance for choosing which model to use can be found in the [Transcription - * Models - * Documentation](https://cloud.google.com/speech-to-text/v2/docs/transcription-model) - * and the models supported in each region can be found in the [Table Of - * Supported - * Models](https://cloud.google.com/speech-to-text/v2/docs/speech-to-text-supported-languages). - * - * Generated from protobuf field string model = 4 [deprecated = true, (.google.api.field_behavior) = OPTIONAL]; - * @return string - * @deprecated - */ - public function getModel() - { - if ($this->model !== '') { - @trigger_error('model is deprecated.', E_USER_DEPRECATED); - } - return $this->model; - } - - /** - * Optional. This field is now deprecated. Prefer the - * [`model`][google.cloud.speech.v2.RecognitionConfig.model] field in the - * [`RecognitionConfig`][google.cloud.speech.v2.RecognitionConfig] message. - * Which model to use for recognition requests. Select the model best suited - * to your domain to get best results. - * Guidance for choosing which model to use can be found in the [Transcription - * Models - * Documentation](https://cloud.google.com/speech-to-text/v2/docs/transcription-model) - * and the models supported in each region can be found in the [Table Of - * Supported - * Models](https://cloud.google.com/speech-to-text/v2/docs/speech-to-text-supported-languages). - * - * Generated from protobuf field string model = 4 [deprecated = true, (.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - * @deprecated - */ - public function setModel($var) - { - @trigger_error('model is deprecated.', E_USER_DEPRECATED); - GPBUtil::checkString($var, True); - $this->model = $var; - - return $this; - } - - /** - * Optional. This field is now deprecated. Prefer the - * [`language_codes`][google.cloud.speech.v2.RecognitionConfig.language_codes] - * field in the - * [`RecognitionConfig`][google.cloud.speech.v2.RecognitionConfig] message. - * The language of the supplied audio as a - * [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) language tag. - * Supported languages for each model are listed in the [Table of Supported - * Models](https://cloud.google.com/speech-to-text/v2/docs/speech-to-text-supported-languages). - * If additional languages are provided, recognition result will contain - * recognition in the most likely language detected. The recognition result - * will include the language tag of the language detected in the audio. - * When you create or update a Recognizer, these values are - * stored in normalized BCP-47 form. For example, "en-us" is stored as - * "en-US". - * - * Generated from protobuf field repeated string language_codes = 17 [deprecated = true, (.google.api.field_behavior) = OPTIONAL]; - * @return RepeatedField - * @deprecated - */ - public function getLanguageCodes() - { - if ($this->language_codes->count() !== 0) { - @trigger_error('language_codes is deprecated.', E_USER_DEPRECATED); - } - return $this->language_codes; - } - - /** - * Optional. This field is now deprecated. Prefer the - * [`language_codes`][google.cloud.speech.v2.RecognitionConfig.language_codes] - * field in the - * [`RecognitionConfig`][google.cloud.speech.v2.RecognitionConfig] message. - * The language of the supplied audio as a - * [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) language tag. - * Supported languages for each model are listed in the [Table of Supported - * Models](https://cloud.google.com/speech-to-text/v2/docs/speech-to-text-supported-languages). - * If additional languages are provided, recognition result will contain - * recognition in the most likely language detected. The recognition result - * will include the language tag of the language detected in the audio. - * When you create or update a Recognizer, these values are - * stored in normalized BCP-47 form. For example, "en-us" is stored as - * "en-US". - * - * Generated from protobuf field repeated string language_codes = 17 [deprecated = true, (.google.api.field_behavior) = OPTIONAL]; - * @param string[] $var - * @return $this - * @deprecated - */ - public function setLanguageCodes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - if ($arr->count() !== 0) { - @trigger_error('language_codes is deprecated.', E_USER_DEPRECATED); - } - $this->language_codes = $arr; - - return $this; - } - - /** - * Default configuration to use for requests with this Recognizer. - * This can be overwritten by inline configuration in the - * [RecognizeRequest.config][google.cloud.speech.v2.RecognizeRequest.config] - * field. - * - * Generated from protobuf field .google.cloud.speech.v2.RecognitionConfig default_recognition_config = 6; - * @return \Google\Cloud\Speech\V2\RecognitionConfig|null - */ - public function getDefaultRecognitionConfig() - { - return $this->default_recognition_config; - } - - public function hasDefaultRecognitionConfig() - { - return isset($this->default_recognition_config); - } - - public function clearDefaultRecognitionConfig() - { - unset($this->default_recognition_config); - } - - /** - * Default configuration to use for requests with this Recognizer. - * This can be overwritten by inline configuration in the - * [RecognizeRequest.config][google.cloud.speech.v2.RecognizeRequest.config] - * field. - * - * Generated from protobuf field .google.cloud.speech.v2.RecognitionConfig default_recognition_config = 6; - * @param \Google\Cloud\Speech\V2\RecognitionConfig $var - * @return $this - */ - public function setDefaultRecognitionConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\RecognitionConfig::class); - $this->default_recognition_config = $var; - - return $this; - } - - /** - * Allows users to store small amounts of arbitrary data. - * Both the key and the value must be 63 characters or less each. - * At most 100 annotations. - * - * Generated from protobuf field map annotations = 7; - * @return \Google\Protobuf\Internal\MapField - */ - public function getAnnotations() - { - return $this->annotations; - } - - /** - * Allows users to store small amounts of arbitrary data. - * Both the key and the value must be 63 characters or less each. - * At most 100 annotations. - * - * Generated from protobuf field map annotations = 7; - * @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. The Recognizer lifecycle state. - * - * Generated from protobuf field .google.cloud.speech.v2.Recognizer.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Output only. The Recognizer lifecycle state. - * - * Generated from protobuf field .google.cloud.speech.v2.Recognizer.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Speech\V2\Recognizer\State::class); - $this->state = $var; - - return $this; - } - - /** - * Output only. Creation time. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 9 [(.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 time. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 9 [(.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 most recent time this Recognizer was modified. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 10 [(.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 most recent time this Recognizer was modified. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 10 [(.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 time at which this Recognizer was requested for deletion. - * - * Generated from protobuf field .google.protobuf.Timestamp delete_time = 11 [(.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. The time at which this Recognizer was requested for deletion. - * - * Generated from protobuf field .google.protobuf.Timestamp delete_time = 11 [(.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. The time at which this Recognizer will be purged. - * - * Generated from protobuf field .google.protobuf.Timestamp expire_time = 14 [(.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 Recognizer will be purged. - * - * Generated from protobuf field .google.protobuf.Timestamp expire_time = 14 [(.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. This checksum is computed by the server based on the value of - * other fields. This may be sent on update, undelete, and delete requests to - * ensure the client has an up-to-date value before proceeding. - * - * Generated from protobuf field string etag = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getEtag() - { - return $this->etag; - } - - /** - * Output only. This checksum is computed by the server based on the value of - * other fields. This may be sent on update, undelete, and delete requests to - * ensure the client has an up-to-date value before proceeding. - * - * Generated from protobuf field string etag = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setEtag($var) - { - GPBUtil::checkString($var, True); - $this->etag = $var; - - return $this; - } - - /** - * Output only. Whether or not this Recognizer is in the process of being - * updated. - * - * Generated from protobuf field bool reconciling = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return bool - */ - public function getReconciling() - { - return $this->reconciling; - } - - /** - * Output only. Whether or not this Recognizer is in the process of being - * updated. - * - * Generated from protobuf field bool reconciling = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param bool $var - * @return $this - */ - public function setReconciling($var) - { - GPBUtil::checkBool($var); - $this->reconciling = $var; - - return $this; - } - - /** - * Output only. The [KMS key - * name](https://cloud.google.com/kms/docs/resource-hierarchy#keys) with which - * the Recognizer is encrypted. The expected format is - * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. - * - * Generated from protobuf field string kms_key_name = 15 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { - * @return string - */ - public function getKmsKeyName() - { - return $this->kms_key_name; - } - - /** - * Output only. The [KMS key - * name](https://cloud.google.com/kms/docs/resource-hierarchy#keys) with which - * the Recognizer is encrypted. The expected format is - * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. - * - * Generated from protobuf field string kms_key_name = 15 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setKmsKeyName($var) - { - GPBUtil::checkString($var, True); - $this->kms_key_name = $var; - - return $this; - } - - /** - * Output only. The [KMS key version - * name](https://cloud.google.com/kms/docs/resource-hierarchy#key_versions) - * with which the Recognizer is encrypted. The expected format is - * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}/cryptoKeyVersions/{crypto_key_version}`. - * - * Generated from protobuf field string kms_key_version_name = 16 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { - * @return string - */ - public function getKmsKeyVersionName() - { - return $this->kms_key_version_name; - } - - /** - * Output only. The [KMS key version - * name](https://cloud.google.com/kms/docs/resource-hierarchy#key_versions) - * with which the Recognizer is encrypted. The expected format is - * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}/cryptoKeyVersions/{crypto_key_version}`. - * - * Generated from protobuf field string kms_key_version_name = 16 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setKmsKeyVersionName($var) - { - GPBUtil::checkString($var, True); - $this->kms_key_version_name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/Recognizer/State.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/Recognizer/State.php deleted file mode 100644 index 1bc8bcec0b83..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/Recognizer/State.php +++ /dev/null @@ -1,61 +0,0 @@ -google.cloud.speech.v2.Recognizer.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 Recognizer is active and ready for use. - * - * Generated from protobuf enum ACTIVE = 2; - */ - const ACTIVE = 2; - /** - * This Recognizer has been deleted. - * - * Generated from protobuf enum DELETED = 4; - */ - const DELETED = 4; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::ACTIVE => 'ACTIVE', - 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); - } -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SpeakerDiarizationConfig.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SpeakerDiarizationConfig.php deleted file mode 100644 index e9b16ce24755..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SpeakerDiarizationConfig.php +++ /dev/null @@ -1,109 +0,0 @@ -google.cloud.speech.v2.SpeakerDiarizationConfig - */ -class SpeakerDiarizationConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. The system automatically determines the number of speakers. This - * value is not currently used. - * - * Generated from protobuf field int32 min_speaker_count = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $min_speaker_count = 0; - /** - * Optional. The system automatically determines the number of speakers. This - * value is not currently used. - * - * Generated from protobuf field int32 max_speaker_count = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $max_speaker_count = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $min_speaker_count - * Optional. The system automatically determines the number of speakers. This - * value is not currently used. - * @type int $max_speaker_count - * Optional. The system automatically determines the number of speakers. This - * value is not currently used. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Optional. The system automatically determines the number of speakers. This - * value is not currently used. - * - * Generated from protobuf field int32 min_speaker_count = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getMinSpeakerCount() - { - return $this->min_speaker_count; - } - - /** - * Optional. The system automatically determines the number of speakers. This - * value is not currently used. - * - * Generated from protobuf field int32 min_speaker_count = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setMinSpeakerCount($var) - { - GPBUtil::checkInt32($var); - $this->min_speaker_count = $var; - - return $this; - } - - /** - * Optional. The system automatically determines the number of speakers. This - * value is not currently used. - * - * Generated from protobuf field int32 max_speaker_count = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getMaxSpeakerCount() - { - return $this->max_speaker_count; - } - - /** - * Optional. The system automatically determines the number of speakers. This - * value is not currently used. - * - * Generated from protobuf field int32 max_speaker_count = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setMaxSpeakerCount($var) - { - GPBUtil::checkInt32($var); - $this->max_speaker_count = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SpeechAdaptation.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SpeechAdaptation.php deleted file mode 100644 index c0cdfd7c6b5f..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SpeechAdaptation.php +++ /dev/null @@ -1,107 +0,0 @@ -google.cloud.speech.v2.SpeechAdaptation - */ -class SpeechAdaptation extends \Google\Protobuf\Internal\Message -{ - /** - * A list of inline or referenced PhraseSets. - * - * Generated from protobuf field repeated .google.cloud.speech.v2.SpeechAdaptation.AdaptationPhraseSet phrase_sets = 1; - */ - private $phrase_sets; - /** - * A list of inline CustomClasses. Existing CustomClass resources can be - * referenced directly in a PhraseSet. - * - * Generated from protobuf field repeated .google.cloud.speech.v2.CustomClass custom_classes = 2; - */ - private $custom_classes; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Speech\V2\SpeechAdaptation\AdaptationPhraseSet[] $phrase_sets - * A list of inline or referenced PhraseSets. - * @type \Google\Cloud\Speech\V2\CustomClass[] $custom_classes - * A list of inline CustomClasses. Existing CustomClass resources can be - * referenced directly in a PhraseSet. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * A list of inline or referenced PhraseSets. - * - * Generated from protobuf field repeated .google.cloud.speech.v2.SpeechAdaptation.AdaptationPhraseSet phrase_sets = 1; - * @return RepeatedField<\Google\Cloud\Speech\V2\SpeechAdaptation\AdaptationPhraseSet> - */ - public function getPhraseSets() - { - return $this->phrase_sets; - } - - /** - * A list of inline or referenced PhraseSets. - * - * Generated from protobuf field repeated .google.cloud.speech.v2.SpeechAdaptation.AdaptationPhraseSet phrase_sets = 1; - * @param \Google\Cloud\Speech\V2\SpeechAdaptation\AdaptationPhraseSet[] $var - * @return $this - */ - public function setPhraseSets($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Speech\V2\SpeechAdaptation\AdaptationPhraseSet::class); - $this->phrase_sets = $arr; - - return $this; - } - - /** - * A list of inline CustomClasses. Existing CustomClass resources can be - * referenced directly in a PhraseSet. - * - * Generated from protobuf field repeated .google.cloud.speech.v2.CustomClass custom_classes = 2; - * @return RepeatedField<\Google\Cloud\Speech\V2\CustomClass> - */ - public function getCustomClasses() - { - return $this->custom_classes; - } - - /** - * A list of inline CustomClasses. Existing CustomClass resources can be - * referenced directly in a PhraseSet. - * - * Generated from protobuf field repeated .google.cloud.speech.v2.CustomClass custom_classes = 2; - * @param \Google\Cloud\Speech\V2\CustomClass[] $var - * @return $this - */ - public function setCustomClasses($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Speech\V2\CustomClass::class); - $this->custom_classes = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SpeechAdaptation/AdaptationPhraseSet.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SpeechAdaptation/AdaptationPhraseSet.php deleted file mode 100644 index 8228d4de3a48..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SpeechAdaptation/AdaptationPhraseSet.php +++ /dev/null @@ -1,112 +0,0 @@ -google.cloud.speech.v2.SpeechAdaptation.AdaptationPhraseSet - */ -class AdaptationPhraseSet extends \Google\Protobuf\Internal\Message -{ - protected $value; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $phrase_set - * The name of an existing PhraseSet resource. The user must have read - * access to the resource and it must not be deleted. - * @type \Google\Cloud\Speech\V2\PhraseSet $inline_phrase_set - * An inline defined PhraseSet. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * The name of an existing PhraseSet resource. The user must have read - * access to the resource and it must not be deleted. - * - * Generated from protobuf field string phrase_set = 1 [(.google.api.resource_reference) = { - * @return string - */ - public function getPhraseSet() - { - return $this->readOneof(1); - } - - public function hasPhraseSet() - { - return $this->hasOneof(1); - } - - /** - * The name of an existing PhraseSet resource. The user must have read - * access to the resource and it must not be deleted. - * - * Generated from protobuf field string phrase_set = 1 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setPhraseSet($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * An inline defined PhraseSet. - * - * Generated from protobuf field .google.cloud.speech.v2.PhraseSet inline_phrase_set = 2; - * @return \Google\Cloud\Speech\V2\PhraseSet|null - */ - public function getInlinePhraseSet() - { - return $this->readOneof(2); - } - - public function hasInlinePhraseSet() - { - return $this->hasOneof(2); - } - - /** - * An inline defined PhraseSet. - * - * Generated from protobuf field .google.cloud.speech.v2.PhraseSet inline_phrase_set = 2; - * @param \Google\Cloud\Speech\V2\PhraseSet $var - * @return $this - */ - public function setInlinePhraseSet($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\PhraseSet::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * @return string - */ - public function getValue() - { - return $this->whichOneof("value"); - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SpeechRecognitionAlternative.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SpeechRecognitionAlternative.php deleted file mode 100644 index 78b109df6ad0..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SpeechRecognitionAlternative.php +++ /dev/null @@ -1,175 +0,0 @@ -google.cloud.speech.v2.SpeechRecognitionAlternative - */ -class SpeechRecognitionAlternative extends \Google\Protobuf\Internal\Message -{ - /** - * Transcript text representing the words that the user spoke. - * - * Generated from protobuf field string transcript = 1; - */ - protected $transcript = ''; - /** - * The confidence estimate between 0.0 and 1.0. A higher number - * indicates an estimated greater likelihood that the recognized words are - * correct. This field is set only for the top alternative of a non-streaming - * result or, of a streaming result where - * [is_final][google.cloud.speech.v2.StreamingRecognitionResult.is_final] is - * set to `true`. This field is not guaranteed to be accurate and users should - * not rely on it to be always provided. The default of 0.0 is a sentinel - * value indicating `confidence` was not set. - * - * Generated from protobuf field float confidence = 2; - */ - protected $confidence = 0.0; - /** - * A list of word-specific information for each recognized word. - * When the - * [SpeakerDiarizationConfig][google.cloud.speech.v2.SpeakerDiarizationConfig] - * is set, you will see all the words from the beginning of the audio. - * - * Generated from protobuf field repeated .google.cloud.speech.v2.WordInfo words = 3; - */ - private $words; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $transcript - * Transcript text representing the words that the user spoke. - * @type float $confidence - * The confidence estimate between 0.0 and 1.0. A higher number - * indicates an estimated greater likelihood that the recognized words are - * correct. This field is set only for the top alternative of a non-streaming - * result or, of a streaming result where - * [is_final][google.cloud.speech.v2.StreamingRecognitionResult.is_final] is - * set to `true`. This field is not guaranteed to be accurate and users should - * not rely on it to be always provided. The default of 0.0 is a sentinel - * value indicating `confidence` was not set. - * @type \Google\Cloud\Speech\V2\WordInfo[] $words - * A list of word-specific information for each recognized word. - * When the - * [SpeakerDiarizationConfig][google.cloud.speech.v2.SpeakerDiarizationConfig] - * is set, you will see all the words from the beginning of the audio. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Transcript text representing the words that the user spoke. - * - * Generated from protobuf field string transcript = 1; - * @return string - */ - public function getTranscript() - { - return $this->transcript; - } - - /** - * Transcript text representing the words that the user spoke. - * - * Generated from protobuf field string transcript = 1; - * @param string $var - * @return $this - */ - public function setTranscript($var) - { - GPBUtil::checkString($var, True); - $this->transcript = $var; - - return $this; - } - - /** - * The confidence estimate between 0.0 and 1.0. A higher number - * indicates an estimated greater likelihood that the recognized words are - * correct. This field is set only for the top alternative of a non-streaming - * result or, of a streaming result where - * [is_final][google.cloud.speech.v2.StreamingRecognitionResult.is_final] is - * set to `true`. This field is not guaranteed to be accurate and users should - * not rely on it to be always provided. The default of 0.0 is a sentinel - * value indicating `confidence` was not set. - * - * Generated from protobuf field float confidence = 2; - * @return float - */ - public function getConfidence() - { - return $this->confidence; - } - - /** - * The confidence estimate between 0.0 and 1.0. A higher number - * indicates an estimated greater likelihood that the recognized words are - * correct. This field is set only for the top alternative of a non-streaming - * result or, of a streaming result where - * [is_final][google.cloud.speech.v2.StreamingRecognitionResult.is_final] is - * set to `true`. This field is not guaranteed to be accurate and users should - * not rely on it to be always provided. The default of 0.0 is a sentinel - * value indicating `confidence` was not set. - * - * Generated from protobuf field float confidence = 2; - * @param float $var - * @return $this - */ - public function setConfidence($var) - { - GPBUtil::checkFloat($var); - $this->confidence = $var; - - return $this; - } - - /** - * A list of word-specific information for each recognized word. - * When the - * [SpeakerDiarizationConfig][google.cloud.speech.v2.SpeakerDiarizationConfig] - * is set, you will see all the words from the beginning of the audio. - * - * Generated from protobuf field repeated .google.cloud.speech.v2.WordInfo words = 3; - * @return RepeatedField<\Google\Cloud\Speech\V2\WordInfo> - */ - public function getWords() - { - return $this->words; - } - - /** - * A list of word-specific information for each recognized word. - * When the - * [SpeakerDiarizationConfig][google.cloud.speech.v2.SpeakerDiarizationConfig] - * is set, you will see all the words from the beginning of the audio. - * - * Generated from protobuf field repeated .google.cloud.speech.v2.WordInfo words = 3; - * @param \Google\Cloud\Speech\V2\WordInfo[] $var - * @return $this - */ - public function setWords($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Speech\V2\WordInfo::class); - $this->words = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SpeechRecognitionResult.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SpeechRecognitionResult.php deleted file mode 100644 index fa0fed2c6e3c..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SpeechRecognitionResult.php +++ /dev/null @@ -1,211 +0,0 @@ -google.cloud.speech.v2.SpeechRecognitionResult - */ -class SpeechRecognitionResult extends \Google\Protobuf\Internal\Message -{ - /** - * May contain one or more recognition hypotheses. These alternatives are - * ordered in terms of accuracy, with the top (first) alternative being the - * most probable, as ranked by the recognizer. - * - * Generated from protobuf field repeated .google.cloud.speech.v2.SpeechRecognitionAlternative alternatives = 1; - */ - private $alternatives; - /** - * For multi-channel audio, this is the channel number corresponding to the - * recognized result for the audio from that channel. - * For `audio_channel_count` = `N`, its output values can range from `1` to - * `N`. - * - * Generated from protobuf field int32 channel_tag = 2; - */ - protected $channel_tag = 0; - /** - * Time offset of the end of this result relative to the beginning of the - * audio. - * - * Generated from protobuf field .google.protobuf.Duration result_end_offset = 4; - */ - protected $result_end_offset = null; - /** - * Output only. The [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) - * language tag of the language in this result. This language code was - * detected to have the most likelihood of being spoken in the audio. - * - * Generated from protobuf field string language_code = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $language_code = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Speech\V2\SpeechRecognitionAlternative[] $alternatives - * May contain one or more recognition hypotheses. These alternatives are - * ordered in terms of accuracy, with the top (first) alternative being the - * most probable, as ranked by the recognizer. - * @type int $channel_tag - * For multi-channel audio, this is the channel number corresponding to the - * recognized result for the audio from that channel. - * For `audio_channel_count` = `N`, its output values can range from `1` to - * `N`. - * @type \Google\Protobuf\Duration $result_end_offset - * Time offset of the end of this result relative to the beginning of the - * audio. - * @type string $language_code - * Output only. The [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) - * language tag of the language in this result. This language code was - * detected to have the most likelihood of being spoken in the audio. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * May contain one or more recognition hypotheses. These alternatives are - * ordered in terms of accuracy, with the top (first) alternative being the - * most probable, as ranked by the recognizer. - * - * Generated from protobuf field repeated .google.cloud.speech.v2.SpeechRecognitionAlternative alternatives = 1; - * @return RepeatedField<\Google\Cloud\Speech\V2\SpeechRecognitionAlternative> - */ - public function getAlternatives() - { - return $this->alternatives; - } - - /** - * May contain one or more recognition hypotheses. These alternatives are - * ordered in terms of accuracy, with the top (first) alternative being the - * most probable, as ranked by the recognizer. - * - * Generated from protobuf field repeated .google.cloud.speech.v2.SpeechRecognitionAlternative alternatives = 1; - * @param \Google\Cloud\Speech\V2\SpeechRecognitionAlternative[] $var - * @return $this - */ - public function setAlternatives($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Speech\V2\SpeechRecognitionAlternative::class); - $this->alternatives = $arr; - - return $this; - } - - /** - * For multi-channel audio, this is the channel number corresponding to the - * recognized result for the audio from that channel. - * For `audio_channel_count` = `N`, its output values can range from `1` to - * `N`. - * - * Generated from protobuf field int32 channel_tag = 2; - * @return int - */ - public function getChannelTag() - { - return $this->channel_tag; - } - - /** - * For multi-channel audio, this is the channel number corresponding to the - * recognized result for the audio from that channel. - * For `audio_channel_count` = `N`, its output values can range from `1` to - * `N`. - * - * Generated from protobuf field int32 channel_tag = 2; - * @param int $var - * @return $this - */ - public function setChannelTag($var) - { - GPBUtil::checkInt32($var); - $this->channel_tag = $var; - - return $this; - } - - /** - * Time offset of the end of this result relative to the beginning of the - * audio. - * - * Generated from protobuf field .google.protobuf.Duration result_end_offset = 4; - * @return \Google\Protobuf\Duration|null - */ - public function getResultEndOffset() - { - return $this->result_end_offset; - } - - public function hasResultEndOffset() - { - return isset($this->result_end_offset); - } - - public function clearResultEndOffset() - { - unset($this->result_end_offset); - } - - /** - * Time offset of the end of this result relative to the beginning of the - * audio. - * - * Generated from protobuf field .google.protobuf.Duration result_end_offset = 4; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setResultEndOffset($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->result_end_offset = $var; - - return $this; - } - - /** - * Output only. The [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) - * language tag of the language in this result. This language code was - * detected to have the most likelihood of being spoken in the audio. - * - * Generated from protobuf field string language_code = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getLanguageCode() - { - return $this->language_code; - } - - /** - * Output only. The [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) - * language tag of the language in this result. This language code was - * detected to have the most likelihood of being spoken in the audio. - * - * Generated from protobuf field string language_code = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setLanguageCode($var) - { - GPBUtil::checkString($var, True); - $this->language_code = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SrtOutputFileFormatConfig.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SrtOutputFileFormatConfig.php deleted file mode 100644 index 13554265d0c1..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/SrtOutputFileFormatConfig.php +++ /dev/null @@ -1,35 +0,0 @@ -google.cloud.speech.v2.SrtOutputFileFormatConfig - */ -class SrtOutputFileFormatConfig extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognitionConfig.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognitionConfig.php deleted file mode 100644 index b62e4795bd44..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognitionConfig.php +++ /dev/null @@ -1,237 +0,0 @@ -google.cloud.speech.v2.StreamingRecognitionConfig - */ -class StreamingRecognitionConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Features and audio metadata to use for the Automatic Speech - * Recognition. This field in combination with the - * [config_mask][google.cloud.speech.v2.StreamingRecognitionConfig.config_mask] - * field can be used to override parts of the - * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] - * of the Recognizer resource. - * - * Generated from protobuf field .google.cloud.speech.v2.RecognitionConfig config = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $config = null; - /** - * The list of fields in - * [config][google.cloud.speech.v2.StreamingRecognitionConfig.config] that - * override the values in the - * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] - * of the recognizer during this recognition request. If no mask is provided, - * all non-default valued fields in - * [config][google.cloud.speech.v2.StreamingRecognitionConfig.config] override - * the values in the Recognizer for this recognition request. If a mask is - * provided, only the fields listed in the mask override the config in the - * Recognizer for this recognition request. If a wildcard (`*`) is provided, - * [config][google.cloud.speech.v2.StreamingRecognitionConfig.config] - * completely overrides and replaces the config in the recognizer for this - * recognition request. - * - * Generated from protobuf field .google.protobuf.FieldMask config_mask = 3; - */ - protected $config_mask = null; - /** - * Speech recognition features to enable specific to streaming audio - * recognition requests. - * - * Generated from protobuf field .google.cloud.speech.v2.StreamingRecognitionFeatures streaming_features = 2; - */ - protected $streaming_features = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Speech\V2\RecognitionConfig $config - * Required. Features and audio metadata to use for the Automatic Speech - * Recognition. This field in combination with the - * [config_mask][google.cloud.speech.v2.StreamingRecognitionConfig.config_mask] - * field can be used to override parts of the - * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] - * of the Recognizer resource. - * @type \Google\Protobuf\FieldMask $config_mask - * The list of fields in - * [config][google.cloud.speech.v2.StreamingRecognitionConfig.config] that - * override the values in the - * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] - * of the recognizer during this recognition request. If no mask is provided, - * all non-default valued fields in - * [config][google.cloud.speech.v2.StreamingRecognitionConfig.config] override - * the values in the Recognizer for this recognition request. If a mask is - * provided, only the fields listed in the mask override the config in the - * Recognizer for this recognition request. If a wildcard (`*`) is provided, - * [config][google.cloud.speech.v2.StreamingRecognitionConfig.config] - * completely overrides and replaces the config in the recognizer for this - * recognition request. - * @type \Google\Cloud\Speech\V2\StreamingRecognitionFeatures $streaming_features - * Speech recognition features to enable specific to streaming audio - * recognition requests. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Required. Features and audio metadata to use for the Automatic Speech - * Recognition. This field in combination with the - * [config_mask][google.cloud.speech.v2.StreamingRecognitionConfig.config_mask] - * field can be used to override parts of the - * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] - * of the Recognizer resource. - * - * Generated from protobuf field .google.cloud.speech.v2.RecognitionConfig config = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Speech\V2\RecognitionConfig|null - */ - public function getConfig() - { - return $this->config; - } - - public function hasConfig() - { - return isset($this->config); - } - - public function clearConfig() - { - unset($this->config); - } - - /** - * Required. Features and audio metadata to use for the Automatic Speech - * Recognition. This field in combination with the - * [config_mask][google.cloud.speech.v2.StreamingRecognitionConfig.config_mask] - * field can be used to override parts of the - * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] - * of the Recognizer resource. - * - * Generated from protobuf field .google.cloud.speech.v2.RecognitionConfig config = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Speech\V2\RecognitionConfig $var - * @return $this - */ - public function setConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\RecognitionConfig::class); - $this->config = $var; - - return $this; - } - - /** - * The list of fields in - * [config][google.cloud.speech.v2.StreamingRecognitionConfig.config] that - * override the values in the - * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] - * of the recognizer during this recognition request. If no mask is provided, - * all non-default valued fields in - * [config][google.cloud.speech.v2.StreamingRecognitionConfig.config] override - * the values in the Recognizer for this recognition request. If a mask is - * provided, only the fields listed in the mask override the config in the - * Recognizer for this recognition request. If a wildcard (`*`) is provided, - * [config][google.cloud.speech.v2.StreamingRecognitionConfig.config] - * completely overrides and replaces the config in the recognizer for this - * recognition request. - * - * Generated from protobuf field .google.protobuf.FieldMask config_mask = 3; - * @return \Google\Protobuf\FieldMask|null - */ - public function getConfigMask() - { - return $this->config_mask; - } - - public function hasConfigMask() - { - return isset($this->config_mask); - } - - public function clearConfigMask() - { - unset($this->config_mask); - } - - /** - * The list of fields in - * [config][google.cloud.speech.v2.StreamingRecognitionConfig.config] that - * override the values in the - * [default_recognition_config][google.cloud.speech.v2.Recognizer.default_recognition_config] - * of the recognizer during this recognition request. If no mask is provided, - * all non-default valued fields in - * [config][google.cloud.speech.v2.StreamingRecognitionConfig.config] override - * the values in the Recognizer for this recognition request. If a mask is - * provided, only the fields listed in the mask override the config in the - * Recognizer for this recognition request. If a wildcard (`*`) is provided, - * [config][google.cloud.speech.v2.StreamingRecognitionConfig.config] - * completely overrides and replaces the config in the recognizer for this - * recognition request. - * - * Generated from protobuf field .google.protobuf.FieldMask config_mask = 3; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setConfigMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->config_mask = $var; - - return $this; - } - - /** - * Speech recognition features to enable specific to streaming audio - * recognition requests. - * - * Generated from protobuf field .google.cloud.speech.v2.StreamingRecognitionFeatures streaming_features = 2; - * @return \Google\Cloud\Speech\V2\StreamingRecognitionFeatures|null - */ - public function getStreamingFeatures() - { - return $this->streaming_features; - } - - public function hasStreamingFeatures() - { - return isset($this->streaming_features); - } - - public function clearStreamingFeatures() - { - unset($this->streaming_features); - } - - /** - * Speech recognition features to enable specific to streaming audio - * recognition requests. - * - * Generated from protobuf field .google.cloud.speech.v2.StreamingRecognitionFeatures streaming_features = 2; - * @param \Google\Cloud\Speech\V2\StreamingRecognitionFeatures $var - * @return $this - */ - public function setStreamingFeatures($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\StreamingRecognitionFeatures::class); - $this->streaming_features = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognitionFeatures.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognitionFeatures.php deleted file mode 100644 index 4ae1a513ac4f..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognitionFeatures.php +++ /dev/null @@ -1,199 +0,0 @@ -google.cloud.speech.v2.StreamingRecognitionFeatures - */ -class StreamingRecognitionFeatures extends \Google\Protobuf\Internal\Message -{ - /** - * If `true`, responses with voice activity speech events will be returned as - * they are detected. - * - * Generated from protobuf field bool enable_voice_activity_events = 1; - */ - protected $enable_voice_activity_events = false; - /** - * Whether or not to stream interim results to the client. If set to true, - * interim results will be streamed to the client. Otherwise, only the final - * response will be streamed back. - * - * Generated from protobuf field bool interim_results = 2; - */ - protected $interim_results = false; - /** - * If set, the server will automatically close the stream after the specified - * duration has elapsed after the last VOICE_ACTIVITY speech event has been - * sent. The field `voice_activity_events` must also be set to true. - * - * Generated from protobuf field .google.cloud.speech.v2.StreamingRecognitionFeatures.VoiceActivityTimeout voice_activity_timeout = 3; - */ - protected $voice_activity_timeout = null; - /** - * Optional. Endpointing sensitivity for this stream. - * - * Generated from protobuf field .google.cloud.speech.v2.StreamingRecognitionFeatures.EndpointingSensitivity endpointing_sensitivity = 8 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $endpointing_sensitivity = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type bool $enable_voice_activity_events - * If `true`, responses with voice activity speech events will be returned as - * they are detected. - * @type bool $interim_results - * Whether or not to stream interim results to the client. If set to true, - * interim results will be streamed to the client. Otherwise, only the final - * response will be streamed back. - * @type \Google\Cloud\Speech\V2\StreamingRecognitionFeatures\VoiceActivityTimeout $voice_activity_timeout - * If set, the server will automatically close the stream after the specified - * duration has elapsed after the last VOICE_ACTIVITY speech event has been - * sent. The field `voice_activity_events` must also be set to true. - * @type int $endpointing_sensitivity - * Optional. Endpointing sensitivity for this stream. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * If `true`, responses with voice activity speech events will be returned as - * they are detected. - * - * Generated from protobuf field bool enable_voice_activity_events = 1; - * @return bool - */ - public function getEnableVoiceActivityEvents() - { - return $this->enable_voice_activity_events; - } - - /** - * If `true`, responses with voice activity speech events will be returned as - * they are detected. - * - * Generated from protobuf field bool enable_voice_activity_events = 1; - * @param bool $var - * @return $this - */ - public function setEnableVoiceActivityEvents($var) - { - GPBUtil::checkBool($var); - $this->enable_voice_activity_events = $var; - - return $this; - } - - /** - * Whether or not to stream interim results to the client. If set to true, - * interim results will be streamed to the client. Otherwise, only the final - * response will be streamed back. - * - * Generated from protobuf field bool interim_results = 2; - * @return bool - */ - public function getInterimResults() - { - return $this->interim_results; - } - - /** - * Whether or not to stream interim results to the client. If set to true, - * interim results will be streamed to the client. Otherwise, only the final - * response will be streamed back. - * - * Generated from protobuf field bool interim_results = 2; - * @param bool $var - * @return $this - */ - public function setInterimResults($var) - { - GPBUtil::checkBool($var); - $this->interim_results = $var; - - return $this; - } - - /** - * If set, the server will automatically close the stream after the specified - * duration has elapsed after the last VOICE_ACTIVITY speech event has been - * sent. The field `voice_activity_events` must also be set to true. - * - * Generated from protobuf field .google.cloud.speech.v2.StreamingRecognitionFeatures.VoiceActivityTimeout voice_activity_timeout = 3; - * @return \Google\Cloud\Speech\V2\StreamingRecognitionFeatures\VoiceActivityTimeout|null - */ - public function getVoiceActivityTimeout() - { - return $this->voice_activity_timeout; - } - - public function hasVoiceActivityTimeout() - { - return isset($this->voice_activity_timeout); - } - - public function clearVoiceActivityTimeout() - { - unset($this->voice_activity_timeout); - } - - /** - * If set, the server will automatically close the stream after the specified - * duration has elapsed after the last VOICE_ACTIVITY speech event has been - * sent. The field `voice_activity_events` must also be set to true. - * - * Generated from protobuf field .google.cloud.speech.v2.StreamingRecognitionFeatures.VoiceActivityTimeout voice_activity_timeout = 3; - * @param \Google\Cloud\Speech\V2\StreamingRecognitionFeatures\VoiceActivityTimeout $var - * @return $this - */ - public function setVoiceActivityTimeout($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\StreamingRecognitionFeatures\VoiceActivityTimeout::class); - $this->voice_activity_timeout = $var; - - return $this; - } - - /** - * Optional. Endpointing sensitivity for this stream. - * - * Generated from protobuf field .google.cloud.speech.v2.StreamingRecognitionFeatures.EndpointingSensitivity endpointing_sensitivity = 8 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getEndpointingSensitivity() - { - return $this->endpointing_sensitivity; - } - - /** - * Optional. Endpointing sensitivity for this stream. - * - * Generated from protobuf field .google.cloud.speech.v2.StreamingRecognitionFeatures.EndpointingSensitivity endpointing_sensitivity = 8 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setEndpointingSensitivity($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Speech\V2\StreamingRecognitionFeatures\EndpointingSensitivity::class); - $this->endpointing_sensitivity = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognitionFeatures/EndpointingSensitivity.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognitionFeatures/EndpointingSensitivity.php deleted file mode 100644 index 1d90bf17eca9..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognitionFeatures/EndpointingSensitivity.php +++ /dev/null @@ -1,75 +0,0 @@ -google.cloud.speech.v2.StreamingRecognitionFeatures.EndpointingSensitivity - */ -class EndpointingSensitivity -{ - /** - * If no value is specified, the values for - * ENDPOINTING_SENSITIVITY_STANDARD will be used. - * - * Generated from protobuf enum ENDPOINTING_SENSITIVITY_UNSPECIFIED = 0; - */ - const ENDPOINTING_SENSITIVITY_UNSPECIFIED = 0; - /** - * Standard sensitivity, no optimization for latency. - * - * Generated from protobuf enum ENDPOINTING_SENSITIVITY_STANDARD = 1; - */ - const ENDPOINTING_SENSITIVITY_STANDARD = 1; - /** - * Super short sensitivity, optimized for super short utterances like single - * words ("Yes", "No", "Hello", etc.) or a single phrase, command or short - * query (e.g. "check balance", "five dollars", "call Mom"). - * - * Generated from protobuf enum ENDPOINTING_SENSITIVITY_SUPERSHORT = 2; - */ - const ENDPOINTING_SENSITIVITY_SUPERSHORT = 2; - /** - * Short sensitivity, optimized for short utterances like single sentences. - * (e.g. "Remind me to call the dentist tomorrow morning at nine", - * "Navigate to the nearest coffee shop that is currently open") - * - * Generated from protobuf enum ENDPOINTING_SENSITIVITY_SHORT = 3; - */ - const ENDPOINTING_SENSITIVITY_SHORT = 3; - - private static $valueToName = [ - self::ENDPOINTING_SENSITIVITY_UNSPECIFIED => 'ENDPOINTING_SENSITIVITY_UNSPECIFIED', - self::ENDPOINTING_SENSITIVITY_STANDARD => 'ENDPOINTING_SENSITIVITY_STANDARD', - self::ENDPOINTING_SENSITIVITY_SUPERSHORT => 'ENDPOINTING_SENSITIVITY_SUPERSHORT', - self::ENDPOINTING_SENSITIVITY_SHORT => 'ENDPOINTING_SENSITIVITY_SHORT', - ]; - - 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/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognitionFeatures/VoiceActivityTimeout.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognitionFeatures/VoiceActivityTimeout.php deleted file mode 100644 index e5b711ff4cd6..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognitionFeatures/VoiceActivityTimeout.php +++ /dev/null @@ -1,137 +0,0 @@ -google.cloud.speech.v2.StreamingRecognitionFeatures.VoiceActivityTimeout - */ -class VoiceActivityTimeout extends \Google\Protobuf\Internal\Message -{ - /** - * Duration to timeout the stream if no speech begins. If this is set and - * no speech is detected in this duration at the start of the stream, the - * server will close the stream. - * - * Generated from protobuf field .google.protobuf.Duration speech_start_timeout = 1; - */ - protected $speech_start_timeout = null; - /** - * Duration to timeout the stream after speech ends. If this is set and no - * speech is detected in this duration after speech was detected, the server - * will close the stream. - * - * Generated from protobuf field .google.protobuf.Duration speech_end_timeout = 2; - */ - protected $speech_end_timeout = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Protobuf\Duration $speech_start_timeout - * Duration to timeout the stream if no speech begins. If this is set and - * no speech is detected in this duration at the start of the stream, the - * server will close the stream. - * @type \Google\Protobuf\Duration $speech_end_timeout - * Duration to timeout the stream after speech ends. If this is set and no - * speech is detected in this duration after speech was detected, the server - * will close the stream. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Duration to timeout the stream if no speech begins. If this is set and - * no speech is detected in this duration at the start of the stream, the - * server will close the stream. - * - * Generated from protobuf field .google.protobuf.Duration speech_start_timeout = 1; - * @return \Google\Protobuf\Duration|null - */ - public function getSpeechStartTimeout() - { - return $this->speech_start_timeout; - } - - public function hasSpeechStartTimeout() - { - return isset($this->speech_start_timeout); - } - - public function clearSpeechStartTimeout() - { - unset($this->speech_start_timeout); - } - - /** - * Duration to timeout the stream if no speech begins. If this is set and - * no speech is detected in this duration at the start of the stream, the - * server will close the stream. - * - * Generated from protobuf field .google.protobuf.Duration speech_start_timeout = 1; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setSpeechStartTimeout($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->speech_start_timeout = $var; - - return $this; - } - - /** - * Duration to timeout the stream after speech ends. If this is set and no - * speech is detected in this duration after speech was detected, the server - * will close the stream. - * - * Generated from protobuf field .google.protobuf.Duration speech_end_timeout = 2; - * @return \Google\Protobuf\Duration|null - */ - public function getSpeechEndTimeout() - { - return $this->speech_end_timeout; - } - - public function hasSpeechEndTimeout() - { - return isset($this->speech_end_timeout); - } - - public function clearSpeechEndTimeout() - { - unset($this->speech_end_timeout); - } - - /** - * Duration to timeout the stream after speech ends. If this is set and no - * speech is detected in this duration after speech was detected, the server - * will close the stream. - * - * Generated from protobuf field .google.protobuf.Duration speech_end_timeout = 2; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setSpeechEndTimeout($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->speech_end_timeout = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognitionResult.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognitionResult.php deleted file mode 100644 index d05932b7e0bd..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognitionResult.php +++ /dev/null @@ -1,320 +0,0 @@ -google.cloud.speech.v2.StreamingRecognitionResult - */ -class StreamingRecognitionResult extends \Google\Protobuf\Internal\Message -{ - /** - * May contain one or more recognition hypotheses. These alternatives are - * ordered in terms of accuracy, with the top (first) alternative being the - * most probable, as ranked by the recognizer. - * - * Generated from protobuf field repeated .google.cloud.speech.v2.SpeechRecognitionAlternative alternatives = 1; - */ - private $alternatives; - /** - * If `false`, this - * [StreamingRecognitionResult][google.cloud.speech.v2.StreamingRecognitionResult] - * represents an interim result that may change. If `true`, this is the final - * time the speech service will return this particular - * [StreamingRecognitionResult][google.cloud.speech.v2.StreamingRecognitionResult], - * the recognizer will not return any further hypotheses for this portion of - * the transcript and corresponding audio. - * - * Generated from protobuf field bool is_final = 2; - */ - protected $is_final = false; - /** - * An estimate of the likelihood that the recognizer will not change its guess - * about this interim result. Values range from 0.0 (completely unstable) - * to 1.0 (completely stable). This field is only provided for interim results - * ([is_final][google.cloud.speech.v2.StreamingRecognitionResult.is_final]=`false`). - * The default of 0.0 is a sentinel value indicating `stability` was not set. - * - * Generated from protobuf field float stability = 3; - */ - protected $stability = 0.0; - /** - * Time offset of the end of this result relative to the beginning of the - * audio. - * - * Generated from protobuf field .google.protobuf.Duration result_end_offset = 4; - */ - protected $result_end_offset = null; - /** - * For multi-channel audio, this is the channel number corresponding to the - * recognized result for the audio from that channel. - * For - * `audio_channel_count` = `N`, its output values can range from `1` to `N`. - * - * Generated from protobuf field int32 channel_tag = 5; - */ - protected $channel_tag = 0; - /** - * Output only. The [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) - * language tag of the language in this result. This language code was - * detected to have the most likelihood of being spoken in the audio. - * - * Generated from protobuf field string language_code = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $language_code = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Speech\V2\SpeechRecognitionAlternative[] $alternatives - * May contain one or more recognition hypotheses. These alternatives are - * ordered in terms of accuracy, with the top (first) alternative being the - * most probable, as ranked by the recognizer. - * @type bool $is_final - * If `false`, this - * [StreamingRecognitionResult][google.cloud.speech.v2.StreamingRecognitionResult] - * represents an interim result that may change. If `true`, this is the final - * time the speech service will return this particular - * [StreamingRecognitionResult][google.cloud.speech.v2.StreamingRecognitionResult], - * the recognizer will not return any further hypotheses for this portion of - * the transcript and corresponding audio. - * @type float $stability - * An estimate of the likelihood that the recognizer will not change its guess - * about this interim result. Values range from 0.0 (completely unstable) - * to 1.0 (completely stable). This field is only provided for interim results - * ([is_final][google.cloud.speech.v2.StreamingRecognitionResult.is_final]=`false`). - * The default of 0.0 is a sentinel value indicating `stability` was not set. - * @type \Google\Protobuf\Duration $result_end_offset - * Time offset of the end of this result relative to the beginning of the - * audio. - * @type int $channel_tag - * For multi-channel audio, this is the channel number corresponding to the - * recognized result for the audio from that channel. - * For - * `audio_channel_count` = `N`, its output values can range from `1` to `N`. - * @type string $language_code - * Output only. The [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) - * language tag of the language in this result. This language code was - * detected to have the most likelihood of being spoken in the audio. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * May contain one or more recognition hypotheses. These alternatives are - * ordered in terms of accuracy, with the top (first) alternative being the - * most probable, as ranked by the recognizer. - * - * Generated from protobuf field repeated .google.cloud.speech.v2.SpeechRecognitionAlternative alternatives = 1; - * @return RepeatedField<\Google\Cloud\Speech\V2\SpeechRecognitionAlternative> - */ - public function getAlternatives() - { - return $this->alternatives; - } - - /** - * May contain one or more recognition hypotheses. These alternatives are - * ordered in terms of accuracy, with the top (first) alternative being the - * most probable, as ranked by the recognizer. - * - * Generated from protobuf field repeated .google.cloud.speech.v2.SpeechRecognitionAlternative alternatives = 1; - * @param \Google\Cloud\Speech\V2\SpeechRecognitionAlternative[] $var - * @return $this - */ - public function setAlternatives($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Speech\V2\SpeechRecognitionAlternative::class); - $this->alternatives = $arr; - - return $this; - } - - /** - * If `false`, this - * [StreamingRecognitionResult][google.cloud.speech.v2.StreamingRecognitionResult] - * represents an interim result that may change. If `true`, this is the final - * time the speech service will return this particular - * [StreamingRecognitionResult][google.cloud.speech.v2.StreamingRecognitionResult], - * the recognizer will not return any further hypotheses for this portion of - * the transcript and corresponding audio. - * - * Generated from protobuf field bool is_final = 2; - * @return bool - */ - public function getIsFinal() - { - return $this->is_final; - } - - /** - * If `false`, this - * [StreamingRecognitionResult][google.cloud.speech.v2.StreamingRecognitionResult] - * represents an interim result that may change. If `true`, this is the final - * time the speech service will return this particular - * [StreamingRecognitionResult][google.cloud.speech.v2.StreamingRecognitionResult], - * the recognizer will not return any further hypotheses for this portion of - * the transcript and corresponding audio. - * - * Generated from protobuf field bool is_final = 2; - * @param bool $var - * @return $this - */ - public function setIsFinal($var) - { - GPBUtil::checkBool($var); - $this->is_final = $var; - - return $this; - } - - /** - * An estimate of the likelihood that the recognizer will not change its guess - * about this interim result. Values range from 0.0 (completely unstable) - * to 1.0 (completely stable). This field is only provided for interim results - * ([is_final][google.cloud.speech.v2.StreamingRecognitionResult.is_final]=`false`). - * The default of 0.0 is a sentinel value indicating `stability` was not set. - * - * Generated from protobuf field float stability = 3; - * @return float - */ - public function getStability() - { - return $this->stability; - } - - /** - * An estimate of the likelihood that the recognizer will not change its guess - * about this interim result. Values range from 0.0 (completely unstable) - * to 1.0 (completely stable). This field is only provided for interim results - * ([is_final][google.cloud.speech.v2.StreamingRecognitionResult.is_final]=`false`). - * The default of 0.0 is a sentinel value indicating `stability` was not set. - * - * Generated from protobuf field float stability = 3; - * @param float $var - * @return $this - */ - public function setStability($var) - { - GPBUtil::checkFloat($var); - $this->stability = $var; - - return $this; - } - - /** - * Time offset of the end of this result relative to the beginning of the - * audio. - * - * Generated from protobuf field .google.protobuf.Duration result_end_offset = 4; - * @return \Google\Protobuf\Duration|null - */ - public function getResultEndOffset() - { - return $this->result_end_offset; - } - - public function hasResultEndOffset() - { - return isset($this->result_end_offset); - } - - public function clearResultEndOffset() - { - unset($this->result_end_offset); - } - - /** - * Time offset of the end of this result relative to the beginning of the - * audio. - * - * Generated from protobuf field .google.protobuf.Duration result_end_offset = 4; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setResultEndOffset($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->result_end_offset = $var; - - return $this; - } - - /** - * For multi-channel audio, this is the channel number corresponding to the - * recognized result for the audio from that channel. - * For - * `audio_channel_count` = `N`, its output values can range from `1` to `N`. - * - * Generated from protobuf field int32 channel_tag = 5; - * @return int - */ - public function getChannelTag() - { - return $this->channel_tag; - } - - /** - * For multi-channel audio, this is the channel number corresponding to the - * recognized result for the audio from that channel. - * For - * `audio_channel_count` = `N`, its output values can range from `1` to `N`. - * - * Generated from protobuf field int32 channel_tag = 5; - * @param int $var - * @return $this - */ - public function setChannelTag($var) - { - GPBUtil::checkInt32($var); - $this->channel_tag = $var; - - return $this; - } - - /** - * Output only. The [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) - * language tag of the language in this result. This language code was - * detected to have the most likelihood of being spoken in the audio. - * - * Generated from protobuf field string language_code = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getLanguageCode() - { - return $this->language_code; - } - - /** - * Output only. The [BCP-47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt) - * language tag of the language in this result. This language code was - * detected to have the most likelihood of being spoken in the audio. - * - * Generated from protobuf field string language_code = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setLanguageCode($var) - { - GPBUtil::checkString($var, True); - $this->language_code = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognizeRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognizeRequest.php deleted file mode 100644 index 7555eef97584..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognizeRequest.php +++ /dev/null @@ -1,180 +0,0 @@ -google.cloud.speech.v2.StreamingRecognizeRequest - */ -class StreamingRecognizeRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the Recognizer to use during recognition. The - * expected format is - * `projects/{project}/locations/{location}/recognizers/{recognizer}`. The - * {recognizer} segment may be set to `_` to use an empty implicit Recognizer. - * - * Generated from protobuf field string recognizer = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $recognizer = ''; - protected $streaming_request; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $recognizer - * Required. The name of the Recognizer to use during recognition. The - * expected format is - * `projects/{project}/locations/{location}/recognizers/{recognizer}`. The - * {recognizer} segment may be set to `_` to use an empty implicit Recognizer. - * @type \Google\Cloud\Speech\V2\StreamingRecognitionConfig $streaming_config - * StreamingRecognitionConfig to be used in this recognition attempt. - * If provided, it will override the default RecognitionConfig stored in the - * Recognizer. - * @type string $audio - * Inline audio bytes to be Recognized. - * Maximum size for this field is 15 KB per request. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the Recognizer to use during recognition. The - * expected format is - * `projects/{project}/locations/{location}/recognizers/{recognizer}`. The - * {recognizer} segment may be set to `_` to use an empty implicit Recognizer. - * - * Generated from protobuf field string recognizer = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getRecognizer() - { - return $this->recognizer; - } - - /** - * Required. The name of the Recognizer to use during recognition. The - * expected format is - * `projects/{project}/locations/{location}/recognizers/{recognizer}`. The - * {recognizer} segment may be set to `_` to use an empty implicit Recognizer. - * - * Generated from protobuf field string recognizer = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setRecognizer($var) - { - GPBUtil::checkString($var, True); - $this->recognizer = $var; - - return $this; - } - - /** - * StreamingRecognitionConfig to be used in this recognition attempt. - * If provided, it will override the default RecognitionConfig stored in the - * Recognizer. - * - * Generated from protobuf field .google.cloud.speech.v2.StreamingRecognitionConfig streaming_config = 6; - * @return \Google\Cloud\Speech\V2\StreamingRecognitionConfig|null - */ - public function getStreamingConfig() - { - return $this->readOneof(6); - } - - public function hasStreamingConfig() - { - return $this->hasOneof(6); - } - - /** - * StreamingRecognitionConfig to be used in this recognition attempt. - * If provided, it will override the default RecognitionConfig stored in the - * Recognizer. - * - * Generated from protobuf field .google.cloud.speech.v2.StreamingRecognitionConfig streaming_config = 6; - * @param \Google\Cloud\Speech\V2\StreamingRecognitionConfig $var - * @return $this - */ - public function setStreamingConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\StreamingRecognitionConfig::class); - $this->writeOneof(6, $var); - - return $this; - } - - /** - * Inline audio bytes to be Recognized. - * Maximum size for this field is 15 KB per request. - * - * Generated from protobuf field bytes audio = 5; - * @return string - */ - public function getAudio() - { - return $this->readOneof(5); - } - - public function hasAudio() - { - return $this->hasOneof(5); - } - - /** - * Inline audio bytes to be Recognized. - * Maximum size for this field is 15 KB per request. - * - * Generated from protobuf field bytes audio = 5; - * @param string $var - * @return $this - */ - public function setAudio($var) - { - GPBUtil::checkString($var, False); - $this->writeOneof(5, $var); - - return $this; - } - - /** - * @return string - */ - public function getStreamingRequest() - { - return $this->whichOneof("streaming_request"); - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognizeResponse.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognizeResponse.php deleted file mode 100644 index ce2d5e061ab2..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognizeResponse.php +++ /dev/null @@ -1,247 +0,0 @@ -google.cloud.speech.v2.StreamingRecognizeResponse - */ -class StreamingRecognizeResponse extends \Google\Protobuf\Internal\Message -{ - /** - * This repeated list contains zero or more results that - * correspond to consecutive portions of the audio currently being processed. - * It contains zero or one - * [is_final][google.cloud.speech.v2.StreamingRecognitionResult.is_final]=`true` - * result (the newly settled portion), followed by zero or more - * [is_final][google.cloud.speech.v2.StreamingRecognitionResult.is_final]=`false` - * results (the interim results). - * - * Generated from protobuf field repeated .google.cloud.speech.v2.StreamingRecognitionResult results = 6; - */ - private $results; - /** - * Indicates the type of speech event. - * - * Generated from protobuf field .google.cloud.speech.v2.StreamingRecognizeResponse.SpeechEventType speech_event_type = 3; - */ - protected $speech_event_type = 0; - /** - * Time offset between the beginning of the audio and event emission. - * - * Generated from protobuf field .google.protobuf.Duration speech_event_offset = 7; - */ - protected $speech_event_offset = null; - /** - * Metadata about the recognition. - * - * Generated from protobuf field .google.cloud.speech.v2.RecognitionResponseMetadata metadata = 5; - */ - protected $metadata = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Speech\V2\StreamingRecognitionResult[] $results - * This repeated list contains zero or more results that - * correspond to consecutive portions of the audio currently being processed. - * It contains zero or one - * [is_final][google.cloud.speech.v2.StreamingRecognitionResult.is_final]=`true` - * result (the newly settled portion), followed by zero or more - * [is_final][google.cloud.speech.v2.StreamingRecognitionResult.is_final]=`false` - * results (the interim results). - * @type int $speech_event_type - * Indicates the type of speech event. - * @type \Google\Protobuf\Duration $speech_event_offset - * Time offset between the beginning of the audio and event emission. - * @type \Google\Cloud\Speech\V2\RecognitionResponseMetadata $metadata - * Metadata about the recognition. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * This repeated list contains zero or more results that - * correspond to consecutive portions of the audio currently being processed. - * It contains zero or one - * [is_final][google.cloud.speech.v2.StreamingRecognitionResult.is_final]=`true` - * result (the newly settled portion), followed by zero or more - * [is_final][google.cloud.speech.v2.StreamingRecognitionResult.is_final]=`false` - * results (the interim results). - * - * Generated from protobuf field repeated .google.cloud.speech.v2.StreamingRecognitionResult results = 6; - * @return RepeatedField<\Google\Cloud\Speech\V2\StreamingRecognitionResult> - */ - public function getResults() - { - return $this->results; - } - - /** - * This repeated list contains zero or more results that - * correspond to consecutive portions of the audio currently being processed. - * It contains zero or one - * [is_final][google.cloud.speech.v2.StreamingRecognitionResult.is_final]=`true` - * result (the newly settled portion), followed by zero or more - * [is_final][google.cloud.speech.v2.StreamingRecognitionResult.is_final]=`false` - * results (the interim results). - * - * Generated from protobuf field repeated .google.cloud.speech.v2.StreamingRecognitionResult results = 6; - * @param \Google\Cloud\Speech\V2\StreamingRecognitionResult[] $var - * @return $this - */ - public function setResults($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Speech\V2\StreamingRecognitionResult::class); - $this->results = $arr; - - return $this; - } - - /** - * Indicates the type of speech event. - * - * Generated from protobuf field .google.cloud.speech.v2.StreamingRecognizeResponse.SpeechEventType speech_event_type = 3; - * @return int - */ - public function getSpeechEventType() - { - return $this->speech_event_type; - } - - /** - * Indicates the type of speech event. - * - * Generated from protobuf field .google.cloud.speech.v2.StreamingRecognizeResponse.SpeechEventType speech_event_type = 3; - * @param int $var - * @return $this - */ - public function setSpeechEventType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\Speech\V2\StreamingRecognizeResponse\SpeechEventType::class); - $this->speech_event_type = $var; - - return $this; - } - - /** - * Time offset between the beginning of the audio and event emission. - * - * Generated from protobuf field .google.protobuf.Duration speech_event_offset = 7; - * @return \Google\Protobuf\Duration|null - */ - public function getSpeechEventOffset() - { - return $this->speech_event_offset; - } - - public function hasSpeechEventOffset() - { - return isset($this->speech_event_offset); - } - - public function clearSpeechEventOffset() - { - unset($this->speech_event_offset); - } - - /** - * Time offset between the beginning of the audio and event emission. - * - * Generated from protobuf field .google.protobuf.Duration speech_event_offset = 7; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setSpeechEventOffset($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->speech_event_offset = $var; - - return $this; - } - - /** - * Metadata about the recognition. - * - * Generated from protobuf field .google.cloud.speech.v2.RecognitionResponseMetadata metadata = 5; - * @return \Google\Cloud\Speech\V2\RecognitionResponseMetadata|null - */ - public function getMetadata() - { - return $this->metadata; - } - - public function hasMetadata() - { - return isset($this->metadata); - } - - public function clearMetadata() - { - unset($this->metadata); - } - - /** - * Metadata about the recognition. - * - * Generated from protobuf field .google.cloud.speech.v2.RecognitionResponseMetadata metadata = 5; - * @param \Google\Cloud\Speech\V2\RecognitionResponseMetadata $var - * @return $this - */ - public function setMetadata($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\RecognitionResponseMetadata::class); - $this->metadata = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognizeResponse/SpeechEventType.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognizeResponse/SpeechEventType.php deleted file mode 100644 index 4d09423db8da..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/StreamingRecognizeResponse/SpeechEventType.php +++ /dev/null @@ -1,79 +0,0 @@ -google.cloud.speech.v2.StreamingRecognizeResponse.SpeechEventType - */ -class SpeechEventType -{ - /** - * No speech event specified. - * - * Generated from protobuf enum SPEECH_EVENT_TYPE_UNSPECIFIED = 0; - */ - const SPEECH_EVENT_TYPE_UNSPECIFIED = 0; - /** - * This event indicates that the server has detected the end of the user's - * speech utterance and expects no additional speech. Therefore, the server - * will not process additional audio and will close the gRPC bidirectional - * stream. This event is only sent if there was a force cutoff due to - * silence being detected early. This event is only available through the - * `latest_short` [model][google.cloud.speech.v2.Recognizer.model]. - * - * Generated from protobuf enum END_OF_SINGLE_UTTERANCE = 1; - */ - const END_OF_SINGLE_UTTERANCE = 1; - /** - * This event indicates that the server has detected the beginning of human - * voice activity in the stream. This event can be returned multiple times - * if speech starts and stops repeatedly throughout the stream. This event - * is only sent if `voice_activity_events` is set to true. - * - * Generated from protobuf enum SPEECH_ACTIVITY_BEGIN = 2; - */ - const SPEECH_ACTIVITY_BEGIN = 2; - /** - * This event indicates that the server has detected the end of human voice - * activity in the stream. This event can be returned multiple times if - * speech starts and stops repeatedly throughout the stream. This event is - * only sent if `voice_activity_events` is set to true. - * - * Generated from protobuf enum SPEECH_ACTIVITY_END = 3; - */ - const SPEECH_ACTIVITY_END = 3; - - private static $valueToName = [ - self::SPEECH_EVENT_TYPE_UNSPECIFIED => 'SPEECH_EVENT_TYPE_UNSPECIFIED', - self::END_OF_SINGLE_UTTERANCE => 'END_OF_SINGLE_UTTERANCE', - self::SPEECH_ACTIVITY_BEGIN => 'SPEECH_ACTIVITY_BEGIN', - self::SPEECH_ACTIVITY_END => 'SPEECH_ACTIVITY_END', - ]; - - 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/Speech/v2/proto/src/Google/Cloud/Speech/V2/TranscriptNormalization.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/TranscriptNormalization.php deleted file mode 100644 index 8b6ccebc21cd..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/TranscriptNormalization.php +++ /dev/null @@ -1,82 +0,0 @@ - 0.8) and final transcripts. - * - * Generated from protobuf message google.cloud.speech.v2.TranscriptNormalization - */ -class TranscriptNormalization extends \Google\Protobuf\Internal\Message -{ - /** - * A list of replacement entries. We will perform replacement with one entry - * at a time. For example, the second entry in ["cat" => "dog", "mountain cat" - * => "mountain dog"] will never be applied because we will always process the - * first entry before it. At most 100 entries. - * - * Generated from protobuf field repeated .google.cloud.speech.v2.TranscriptNormalization.Entry entries = 1; - */ - private $entries; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Speech\V2\TranscriptNormalization\Entry[] $entries - * A list of replacement entries. We will perform replacement with one entry - * at a time. For example, the second entry in ["cat" => "dog", "mountain cat" - * => "mountain dog"] will never be applied because we will always process the - * first entry before it. At most 100 entries. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * A list of replacement entries. We will perform replacement with one entry - * at a time. For example, the second entry in ["cat" => "dog", "mountain cat" - * => "mountain dog"] will never be applied because we will always process the - * first entry before it. At most 100 entries. - * - * Generated from protobuf field repeated .google.cloud.speech.v2.TranscriptNormalization.Entry entries = 1; - * @return RepeatedField<\Google\Cloud\Speech\V2\TranscriptNormalization\Entry> - */ - public function getEntries() - { - return $this->entries; - } - - /** - * A list of replacement entries. We will perform replacement with one entry - * at a time. For example, the second entry in ["cat" => "dog", "mountain cat" - * => "mountain dog"] will never be applied because we will always process the - * first entry before it. At most 100 entries. - * - * Generated from protobuf field repeated .google.cloud.speech.v2.TranscriptNormalization.Entry entries = 1; - * @param \Google\Cloud\Speech\V2\TranscriptNormalization\Entry[] $var - * @return $this - */ - public function setEntries($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\Speech\V2\TranscriptNormalization\Entry::class); - $this->entries = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/TranscriptNormalization/Entry.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/TranscriptNormalization/Entry.php deleted file mode 100644 index 266f1a7f7982..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/TranscriptNormalization/Entry.php +++ /dev/null @@ -1,135 +0,0 @@ -google.cloud.speech.v2.TranscriptNormalization.Entry - */ -class Entry extends \Google\Protobuf\Internal\Message -{ - /** - * What to replace. Max length is 100 characters. - * - * Generated from protobuf field string search = 1; - */ - protected $search = ''; - /** - * What to replace with. Max length is 100 characters. - * - * Generated from protobuf field string replace = 2; - */ - protected $replace = ''; - /** - * Whether the search is case sensitive. - * - * Generated from protobuf field bool case_sensitive = 3; - */ - protected $case_sensitive = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $search - * What to replace. Max length is 100 characters. - * @type string $replace - * What to replace with. Max length is 100 characters. - * @type bool $case_sensitive - * Whether the search is case sensitive. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * What to replace. Max length is 100 characters. - * - * Generated from protobuf field string search = 1; - * @return string - */ - public function getSearch() - { - return $this->search; - } - - /** - * What to replace. Max length is 100 characters. - * - * Generated from protobuf field string search = 1; - * @param string $var - * @return $this - */ - public function setSearch($var) - { - GPBUtil::checkString($var, True); - $this->search = $var; - - return $this; - } - - /** - * What to replace with. Max length is 100 characters. - * - * Generated from protobuf field string replace = 2; - * @return string - */ - public function getReplace() - { - return $this->replace; - } - - /** - * What to replace with. Max length is 100 characters. - * - * Generated from protobuf field string replace = 2; - * @param string $var - * @return $this - */ - public function setReplace($var) - { - GPBUtil::checkString($var, True); - $this->replace = $var; - - return $this; - } - - /** - * Whether the search is case sensitive. - * - * Generated from protobuf field bool case_sensitive = 3; - * @return bool - */ - public function getCaseSensitive() - { - return $this->case_sensitive; - } - - /** - * Whether the search is case sensitive. - * - * Generated from protobuf field bool case_sensitive = 3; - * @param bool $var - * @return $this - */ - public function setCaseSensitive($var) - { - GPBUtil::checkBool($var); - $this->case_sensitive = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/TranslationConfig.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/TranslationConfig.php deleted file mode 100644 index 5a980886f570..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/TranslationConfig.php +++ /dev/null @@ -1,68 +0,0 @@ -google.cloud.speech.v2.TranslationConfig - */ -class TranslationConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The language code to translate to. - * - * Generated from protobuf field string target_language = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $target_language = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $target_language - * Required. The language code to translate to. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Required. The language code to translate to. - * - * Generated from protobuf field string target_language = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getTargetLanguage() - { - return $this->target_language; - } - - /** - * Required. The language code to translate to. - * - * Generated from protobuf field string target_language = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setTargetLanguage($var) - { - GPBUtil::checkString($var, True); - $this->target_language = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UndeleteCustomClassRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UndeleteCustomClassRequest.php deleted file mode 100644 index fd41ece79277..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UndeleteCustomClassRequest.php +++ /dev/null @@ -1,173 +0,0 @@ -google.cloud.speech.v2.UndeleteCustomClassRequest - */ -class UndeleteCustomClassRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the CustomClass to undelete. - * Format: - * `projects/{project}/locations/{location}/customClasses/{custom_class}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * If set, validate the request and preview the undeleted CustomClass, but do - * not actually undelete it. - * - * Generated from protobuf field bool validate_only = 3; - */ - protected $validate_only = false; - /** - * This checksum is computed by the server based on the value of other - * fields. This may be sent on update, undelete, and delete requests to ensure - * the client has an up-to-date value before proceeding. - * - * Generated from protobuf field string etag = 4; - */ - protected $etag = ''; - - /** - * @param string $name Required. The name of the CustomClass to undelete. - * Format: - * `projects/{project}/locations/{location}/customClasses/{custom_class}` - * Please see {@see SpeechClient::customClassName()} for help formatting this field. - * - * @return \Google\Cloud\Speech\V2\UndeleteCustomClassRequest - * - * @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 CustomClass to undelete. - * Format: - * `projects/{project}/locations/{location}/customClasses/{custom_class}` - * @type bool $validate_only - * If set, validate the request and preview the undeleted CustomClass, but do - * not actually undelete it. - * @type string $etag - * This checksum is computed by the server based on the value of other - * fields. This may be sent on update, undelete, and delete requests to ensure - * the client has an up-to-date value before proceeding. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the CustomClass to undelete. - * Format: - * `projects/{project}/locations/{location}/customClasses/{custom_class}` - * - * 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 CustomClass to undelete. - * Format: - * `projects/{project}/locations/{location}/customClasses/{custom_class}` - * - * 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, validate the request and preview the undeleted CustomClass, but do - * not actually undelete it. - * - * Generated from protobuf field bool validate_only = 3; - * @return bool - */ - public function getValidateOnly() - { - return $this->validate_only; - } - - /** - * If set, validate the request and preview the undeleted CustomClass, but do - * not actually undelete 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; - } - - /** - * This checksum is computed by the server based on the value of other - * fields. This may be sent on update, undelete, and delete requests to ensure - * the client has an up-to-date value before proceeding. - * - * Generated from protobuf field string etag = 4; - * @return string - */ - public function getEtag() - { - return $this->etag; - } - - /** - * This checksum is computed by the server based on the value of other - * fields. This may be sent on update, undelete, and delete requests to ensure - * the client has an up-to-date value before proceeding. - * - * 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/Speech/v2/proto/src/Google/Cloud/Speech/V2/UndeletePhraseSetRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UndeletePhraseSetRequest.php deleted file mode 100644 index 2c448595d447..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UndeletePhraseSetRequest.php +++ /dev/null @@ -1,168 +0,0 @@ -google.cloud.speech.v2.UndeletePhraseSetRequest - */ -class UndeletePhraseSetRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the PhraseSet to undelete. - * Format: `projects/{project}/locations/{location}/phraseSets/{phrase_set}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * If set, validate the request and preview the undeleted PhraseSet, but do - * not actually undelete it. - * - * Generated from protobuf field bool validate_only = 3; - */ - protected $validate_only = false; - /** - * This checksum is computed by the server based on the value of other - * fields. This may be sent on update, undelete, and delete requests to ensure - * the client has an up-to-date value before proceeding. - * - * Generated from protobuf field string etag = 4; - */ - protected $etag = ''; - - /** - * @param string $name Required. The name of the PhraseSet to undelete. - * Format: `projects/{project}/locations/{location}/phraseSets/{phrase_set}` - * Please see {@see SpeechClient::phraseSetName()} for help formatting this field. - * - * @return \Google\Cloud\Speech\V2\UndeletePhraseSetRequest - * - * @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 PhraseSet to undelete. - * Format: `projects/{project}/locations/{location}/phraseSets/{phrase_set}` - * @type bool $validate_only - * If set, validate the request and preview the undeleted PhraseSet, but do - * not actually undelete it. - * @type string $etag - * This checksum is computed by the server based on the value of other - * fields. This may be sent on update, undelete, and delete requests to ensure - * the client has an up-to-date value before proceeding. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the PhraseSet to undelete. - * Format: `projects/{project}/locations/{location}/phraseSets/{phrase_set}` - * - * 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 PhraseSet to undelete. - * Format: `projects/{project}/locations/{location}/phraseSets/{phrase_set}` - * - * 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, validate the request and preview the undeleted PhraseSet, but do - * not actually undelete it. - * - * Generated from protobuf field bool validate_only = 3; - * @return bool - */ - public function getValidateOnly() - { - return $this->validate_only; - } - - /** - * If set, validate the request and preview the undeleted PhraseSet, but do - * not actually undelete 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; - } - - /** - * This checksum is computed by the server based on the value of other - * fields. This may be sent on update, undelete, and delete requests to ensure - * the client has an up-to-date value before proceeding. - * - * Generated from protobuf field string etag = 4; - * @return string - */ - public function getEtag() - { - return $this->etag; - } - - /** - * This checksum is computed by the server based on the value of other - * fields. This may be sent on update, undelete, and delete requests to ensure - * the client has an up-to-date value before proceeding. - * - * 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/Speech/v2/proto/src/Google/Cloud/Speech/V2/UndeleteRecognizerRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UndeleteRecognizerRequest.php deleted file mode 100644 index b174c06a152d..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UndeleteRecognizerRequest.php +++ /dev/null @@ -1,168 +0,0 @@ -google.cloud.speech.v2.UndeleteRecognizerRequest - */ -class UndeleteRecognizerRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the Recognizer to undelete. - * Format: `projects/{project}/locations/{location}/recognizers/{recognizer}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * If set, validate the request and preview the undeleted Recognizer, but do - * not actually undelete it. - * - * Generated from protobuf field bool validate_only = 3; - */ - protected $validate_only = false; - /** - * This checksum is computed by the server based on the value of other - * fields. This may be sent on update, undelete, and delete requests to ensure - * the client has an up-to-date value before proceeding. - * - * Generated from protobuf field string etag = 4; - */ - protected $etag = ''; - - /** - * @param string $name Required. The name of the Recognizer to undelete. - * Format: `projects/{project}/locations/{location}/recognizers/{recognizer}` - * Please see {@see SpeechClient::recognizerName()} for help formatting this field. - * - * @return \Google\Cloud\Speech\V2\UndeleteRecognizerRequest - * - * @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 Recognizer to undelete. - * Format: `projects/{project}/locations/{location}/recognizers/{recognizer}` - * @type bool $validate_only - * If set, validate the request and preview the undeleted Recognizer, but do - * not actually undelete it. - * @type string $etag - * This checksum is computed by the server based on the value of other - * fields. This may be sent on update, undelete, and delete requests to ensure - * the client has an up-to-date value before proceeding. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the Recognizer to undelete. - * Format: `projects/{project}/locations/{location}/recognizers/{recognizer}` - * - * 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 Recognizer to undelete. - * Format: `projects/{project}/locations/{location}/recognizers/{recognizer}` - * - * 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, validate the request and preview the undeleted Recognizer, but do - * not actually undelete it. - * - * Generated from protobuf field bool validate_only = 3; - * @return bool - */ - public function getValidateOnly() - { - return $this->validate_only; - } - - /** - * If set, validate the request and preview the undeleted Recognizer, but do - * not actually undelete 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; - } - - /** - * This checksum is computed by the server based on the value of other - * fields. This may be sent on update, undelete, and delete requests to ensure - * the client has an up-to-date value before proceeding. - * - * Generated from protobuf field string etag = 4; - * @return string - */ - public function getEtag() - { - return $this->etag; - } - - /** - * This checksum is computed by the server based on the value of other - * fields. This may be sent on update, undelete, and delete requests to ensure - * the client has an up-to-date value before proceeding. - * - * 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/Speech/v2/proto/src/Google/Cloud/Speech/V2/UpdateConfigRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UpdateConfigRequest.php deleted file mode 100644 index 72383c2fca69..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UpdateConfigRequest.php +++ /dev/null @@ -1,148 +0,0 @@ -google.cloud.speech.v2.UpdateConfigRequest - */ -class UpdateConfigRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The config to update. - * The config's `name` field is used to identify the config to be updated. - * The expected format is `projects/{project}/locations/{location}/config`. - * - * Generated from protobuf field .google.cloud.speech.v2.Config config = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $config = null; - /** - * The list of fields to be updated. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - */ - protected $update_mask = null; - - /** - * @param \Google\Cloud\Speech\V2\Config $config Required. The config to update. - * - * The config's `name` field is used to identify the config to be updated. - * The expected format is `projects/{project}/locations/{location}/config`. - * @param \Google\Protobuf\FieldMask $updateMask The list of fields to be updated. - * - * @return \Google\Cloud\Speech\V2\UpdateConfigRequest - * - * @experimental - */ - public static function build(\Google\Cloud\Speech\V2\Config $config, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setConfig($config) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Speech\V2\Config $config - * Required. The config to update. - * The config's `name` field is used to identify the config to be updated. - * The expected format is `projects/{project}/locations/{location}/config`. - * @type \Google\Protobuf\FieldMask $update_mask - * The list of fields to be updated. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Required. The config to update. - * The config's `name` field is used to identify the config to be updated. - * The expected format is `projects/{project}/locations/{location}/config`. - * - * Generated from protobuf field .google.cloud.speech.v2.Config config = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Speech\V2\Config|null - */ - public function getConfig() - { - return $this->config; - } - - public function hasConfig() - { - return isset($this->config); - } - - public function clearConfig() - { - unset($this->config); - } - - /** - * Required. The config to update. - * The config's `name` field is used to identify the config to be updated. - * The expected format is `projects/{project}/locations/{location}/config`. - * - * Generated from protobuf field .google.cloud.speech.v2.Config config = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Speech\V2\Config $var - * @return $this - */ - public function setConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\Config::class); - $this->config = $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; - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UpdateCustomClassRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UpdateCustomClassRequest.php deleted file mode 100644 index 034469cd91b4..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UpdateCustomClassRequest.php +++ /dev/null @@ -1,196 +0,0 @@ -google.cloud.speech.v2.UpdateCustomClassRequest - */ -class UpdateCustomClassRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The CustomClass to update. - * The CustomClass's `name` field is used to identify the CustomClass to - * update. Format: - * `projects/{project}/locations/{location}/customClasses/{custom_class}`. - * - * Generated from protobuf field .google.cloud.speech.v2.CustomClass custom_class = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $custom_class = null; - /** - * The list of fields to be updated. If empty, all fields are considered for - * update. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - */ - protected $update_mask = null; - /** - * If set, validate the request and preview the updated CustomClass, but do - * not actually update it. - * - * Generated from protobuf field bool validate_only = 4; - */ - protected $validate_only = false; - - /** - * @param \Google\Cloud\Speech\V2\CustomClass $customClass Required. The CustomClass to update. - * - * The CustomClass's `name` field is used to identify the CustomClass to - * update. Format: - * `projects/{project}/locations/{location}/customClasses/{custom_class}`. - * @param \Google\Protobuf\FieldMask $updateMask The list of fields to be updated. If empty, all fields are considered for - * update. - * - * @return \Google\Cloud\Speech\V2\UpdateCustomClassRequest - * - * @experimental - */ - public static function build(\Google\Cloud\Speech\V2\CustomClass $customClass, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setCustomClass($customClass) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Speech\V2\CustomClass $custom_class - * Required. The CustomClass to update. - * The CustomClass's `name` field is used to identify the CustomClass to - * update. Format: - * `projects/{project}/locations/{location}/customClasses/{custom_class}`. - * @type \Google\Protobuf\FieldMask $update_mask - * The list of fields to be updated. If empty, all fields are considered for - * update. - * @type bool $validate_only - * If set, validate the request and preview the updated CustomClass, but do - * not actually update it. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Required. The CustomClass to update. - * The CustomClass's `name` field is used to identify the CustomClass to - * update. Format: - * `projects/{project}/locations/{location}/customClasses/{custom_class}`. - * - * Generated from protobuf field .google.cloud.speech.v2.CustomClass custom_class = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Speech\V2\CustomClass|null - */ - public function getCustomClass() - { - return $this->custom_class; - } - - public function hasCustomClass() - { - return isset($this->custom_class); - } - - public function clearCustomClass() - { - unset($this->custom_class); - } - - /** - * Required. The CustomClass to update. - * The CustomClass's `name` field is used to identify the CustomClass to - * update. Format: - * `projects/{project}/locations/{location}/customClasses/{custom_class}`. - * - * Generated from protobuf field .google.cloud.speech.v2.CustomClass custom_class = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Speech\V2\CustomClass $var - * @return $this - */ - public function setCustomClass($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\CustomClass::class); - $this->custom_class = $var; - - return $this; - } - - /** - * The list of fields to be updated. If empty, all fields are considered for - * 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); - } - - /** - * The list of fields to be updated. If empty, all fields are considered for - * 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 updated CustomClass, but do - * not actually update 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 updated CustomClass, but do - * not actually update 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/Speech/v2/proto/src/Google/Cloud/Speech/V2/UpdatePhraseSetRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UpdatePhraseSetRequest.php deleted file mode 100644 index 2e23fe934808..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UpdatePhraseSetRequest.php +++ /dev/null @@ -1,191 +0,0 @@ -google.cloud.speech.v2.UpdatePhraseSetRequest - */ -class UpdatePhraseSetRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The PhraseSet to update. - * The PhraseSet's `name` field is used to identify the PhraseSet to update. - * Format: `projects/{project}/locations/{location}/phraseSets/{phrase_set}`. - * - * Generated from protobuf field .google.cloud.speech.v2.PhraseSet phrase_set = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $phrase_set = null; - /** - * The list of fields to update. If empty, all non-default valued fields are - * considered for update. Use `*` to update the entire PhraseSet resource. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - */ - protected $update_mask = null; - /** - * If set, validate the request and preview the updated PhraseSet, but do not - * actually update it. - * - * Generated from protobuf field bool validate_only = 4; - */ - protected $validate_only = false; - - /** - * @param \Google\Cloud\Speech\V2\PhraseSet $phraseSet Required. The PhraseSet to update. - * - * The PhraseSet's `name` field is used to identify the PhraseSet to update. - * Format: `projects/{project}/locations/{location}/phraseSets/{phrase_set}`. - * @param \Google\Protobuf\FieldMask $updateMask The list of fields to update. If empty, all non-default valued fields are - * considered for update. Use `*` to update the entire PhraseSet resource. - * - * @return \Google\Cloud\Speech\V2\UpdatePhraseSetRequest - * - * @experimental - */ - public static function build(\Google\Cloud\Speech\V2\PhraseSet $phraseSet, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setPhraseSet($phraseSet) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Speech\V2\PhraseSet $phrase_set - * Required. The PhraseSet to update. - * The PhraseSet's `name` field is used to identify the PhraseSet to update. - * Format: `projects/{project}/locations/{location}/phraseSets/{phrase_set}`. - * @type \Google\Protobuf\FieldMask $update_mask - * The list of fields to update. If empty, all non-default valued fields are - * considered for update. Use `*` to update the entire PhraseSet resource. - * @type bool $validate_only - * If set, validate the request and preview the updated PhraseSet, but do not - * actually update it. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Required. The PhraseSet to update. - * The PhraseSet's `name` field is used to identify the PhraseSet to update. - * Format: `projects/{project}/locations/{location}/phraseSets/{phrase_set}`. - * - * Generated from protobuf field .google.cloud.speech.v2.PhraseSet phrase_set = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Speech\V2\PhraseSet|null - */ - public function getPhraseSet() - { - return $this->phrase_set; - } - - public function hasPhraseSet() - { - return isset($this->phrase_set); - } - - public function clearPhraseSet() - { - unset($this->phrase_set); - } - - /** - * Required. The PhraseSet to update. - * The PhraseSet's `name` field is used to identify the PhraseSet to update. - * Format: `projects/{project}/locations/{location}/phraseSets/{phrase_set}`. - * - * Generated from protobuf field .google.cloud.speech.v2.PhraseSet phrase_set = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Speech\V2\PhraseSet $var - * @return $this - */ - public function setPhraseSet($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\PhraseSet::class); - $this->phrase_set = $var; - - return $this; - } - - /** - * The list of fields to update. If empty, all non-default valued fields are - * considered for update. Use `*` to update the entire PhraseSet resource. - * - * 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. If empty, all non-default valued fields are - * considered for update. Use `*` to update the entire PhraseSet resource. - * - * 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 updated PhraseSet, but do not - * actually update 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 updated PhraseSet, but do not - * actually update 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/Speech/v2/proto/src/Google/Cloud/Speech/V2/UpdateRecognizerRequest.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UpdateRecognizerRequest.php deleted file mode 100644 index cf1e9ea1c51a..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/UpdateRecognizerRequest.php +++ /dev/null @@ -1,191 +0,0 @@ -google.cloud.speech.v2.UpdateRecognizerRequest - */ -class UpdateRecognizerRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The Recognizer to update. - * The Recognizer's `name` field is used to identify the Recognizer to update. - * Format: `projects/{project}/locations/{location}/recognizers/{recognizer}`. - * - * Generated from protobuf field .google.cloud.speech.v2.Recognizer recognizer = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $recognizer = null; - /** - * The list of fields to update. If empty, all non-default valued fields are - * considered for update. Use `*` to update the entire Recognizer resource. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2; - */ - protected $update_mask = null; - /** - * If set, validate the request and preview the updated Recognizer, but do not - * actually update it. - * - * Generated from protobuf field bool validate_only = 4; - */ - protected $validate_only = false; - - /** - * @param \Google\Cloud\Speech\V2\Recognizer $recognizer Required. The Recognizer to update. - * - * The Recognizer's `name` field is used to identify the Recognizer to update. - * Format: `projects/{project}/locations/{location}/recognizers/{recognizer}`. - * @param \Google\Protobuf\FieldMask $updateMask The list of fields to update. If empty, all non-default valued fields are - * considered for update. Use `*` to update the entire Recognizer resource. - * - * @return \Google\Cloud\Speech\V2\UpdateRecognizerRequest - * - * @experimental - */ - public static function build(\Google\Cloud\Speech\V2\Recognizer $recognizer, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setRecognizer($recognizer) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\Speech\V2\Recognizer $recognizer - * Required. The Recognizer to update. - * The Recognizer's `name` field is used to identify the Recognizer to update. - * Format: `projects/{project}/locations/{location}/recognizers/{recognizer}`. - * @type \Google\Protobuf\FieldMask $update_mask - * The list of fields to update. If empty, all non-default valued fields are - * considered for update. Use `*` to update the entire Recognizer resource. - * @type bool $validate_only - * If set, validate the request and preview the updated Recognizer, but do not - * actually update it. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Required. The Recognizer to update. - * The Recognizer's `name` field is used to identify the Recognizer to update. - * Format: `projects/{project}/locations/{location}/recognizers/{recognizer}`. - * - * Generated from protobuf field .google.cloud.speech.v2.Recognizer recognizer = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\Speech\V2\Recognizer|null - */ - public function getRecognizer() - { - return $this->recognizer; - } - - public function hasRecognizer() - { - return isset($this->recognizer); - } - - public function clearRecognizer() - { - unset($this->recognizer); - } - - /** - * Required. The Recognizer to update. - * The Recognizer's `name` field is used to identify the Recognizer to update. - * Format: `projects/{project}/locations/{location}/recognizers/{recognizer}`. - * - * Generated from protobuf field .google.cloud.speech.v2.Recognizer recognizer = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\Speech\V2\Recognizer $var - * @return $this - */ - public function setRecognizer($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\Speech\V2\Recognizer::class); - $this->recognizer = $var; - - return $this; - } - - /** - * The list of fields to update. If empty, all non-default valued fields are - * considered for update. Use `*` to update the entire Recognizer resource. - * - * 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. If empty, all non-default valued fields are - * considered for update. Use `*` to update the entire Recognizer resource. - * - * 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 updated Recognizer, but do not - * actually update 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 updated Recognizer, but do not - * actually update 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/Speech/v2/proto/src/Google/Cloud/Speech/V2/VttOutputFileFormatConfig.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/VttOutputFileFormatConfig.php deleted file mode 100644 index ddcd270dc0d4..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/VttOutputFileFormatConfig.php +++ /dev/null @@ -1,34 +0,0 @@ -google.cloud.speech.v2.VttOutputFileFormatConfig - */ -class VttOutputFileFormatConfig extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - -} - diff --git a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/WordInfo.php b/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/WordInfo.php deleted file mode 100644 index 86c599acc13f..000000000000 --- a/owl-bot-staging/Speech/v2/proto/src/Google/Cloud/Speech/V2/WordInfo.php +++ /dev/null @@ -1,307 +0,0 @@ -google.cloud.speech.v2.WordInfo - */ -class WordInfo extends \Google\Protobuf\Internal\Message -{ - /** - * Time offset relative to the beginning of the audio, - * and corresponding to the start of the spoken word. - * This field is only set if - * [enable_word_time_offsets][google.cloud.speech.v2.RecognitionFeatures.enable_word_time_offsets] - * is `true` and only in the top hypothesis. This is an experimental feature - * and the accuracy of the time offset can vary. - * - * Generated from protobuf field .google.protobuf.Duration start_offset = 1; - */ - protected $start_offset = null; - /** - * Time offset relative to the beginning of the audio, - * and corresponding to the end of the spoken word. - * This field is only set if - * [enable_word_time_offsets][google.cloud.speech.v2.RecognitionFeatures.enable_word_time_offsets] - * is `true` and only in the top hypothesis. This is an experimental feature - * and the accuracy of the time offset can vary. - * - * Generated from protobuf field .google.protobuf.Duration end_offset = 2; - */ - protected $end_offset = null; - /** - * The word corresponding to this set of information. - * - * Generated from protobuf field string word = 3; - */ - protected $word = ''; - /** - * The confidence estimate between 0.0 and 1.0. A higher number - * indicates an estimated greater likelihood that the recognized words are - * correct. This field is set only for the top alternative of a non-streaming - * result or, of a streaming result where - * [is_final][google.cloud.speech.v2.StreamingRecognitionResult.is_final] is - * set to `true`. This field is not guaranteed to be accurate and users should - * not rely on it to be always provided. The default of 0.0 is a sentinel - * value indicating `confidence` was not set. - * - * Generated from protobuf field float confidence = 4; - */ - protected $confidence = 0.0; - /** - * A distinct label is assigned for every speaker within the audio. This field - * specifies which one of those speakers was detected to have spoken this - * word. `speaker_label` is set if - * [SpeakerDiarizationConfig][google.cloud.speech.v2.SpeakerDiarizationConfig] - * is given and only in the top alternative. - * - * Generated from protobuf field string speaker_label = 6; - */ - protected $speaker_label = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Protobuf\Duration $start_offset - * Time offset relative to the beginning of the audio, - * and corresponding to the start of the spoken word. - * This field is only set if - * [enable_word_time_offsets][google.cloud.speech.v2.RecognitionFeatures.enable_word_time_offsets] - * is `true` and only in the top hypothesis. This is an experimental feature - * and the accuracy of the time offset can vary. - * @type \Google\Protobuf\Duration $end_offset - * Time offset relative to the beginning of the audio, - * and corresponding to the end of the spoken word. - * This field is only set if - * [enable_word_time_offsets][google.cloud.speech.v2.RecognitionFeatures.enable_word_time_offsets] - * is `true` and only in the top hypothesis. This is an experimental feature - * and the accuracy of the time offset can vary. - * @type string $word - * The word corresponding to this set of information. - * @type float $confidence - * The confidence estimate between 0.0 and 1.0. A higher number - * indicates an estimated greater likelihood that the recognized words are - * correct. This field is set only for the top alternative of a non-streaming - * result or, of a streaming result where - * [is_final][google.cloud.speech.v2.StreamingRecognitionResult.is_final] is - * set to `true`. This field is not guaranteed to be accurate and users should - * not rely on it to be always provided. The default of 0.0 is a sentinel - * value indicating `confidence` was not set. - * @type string $speaker_label - * A distinct label is assigned for every speaker within the audio. This field - * specifies which one of those speakers was detected to have spoken this - * word. `speaker_label` is set if - * [SpeakerDiarizationConfig][google.cloud.speech.v2.SpeakerDiarizationConfig] - * is given and only in the top alternative. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Speech\V2\CloudSpeech::initOnce(); - parent::__construct($data); - } - - /** - * Time offset relative to the beginning of the audio, - * and corresponding to the start of the spoken word. - * This field is only set if - * [enable_word_time_offsets][google.cloud.speech.v2.RecognitionFeatures.enable_word_time_offsets] - * is `true` and only in the top hypothesis. This is an experimental feature - * and the accuracy of the time offset can vary. - * - * Generated from protobuf field .google.protobuf.Duration start_offset = 1; - * @return \Google\Protobuf\Duration|null - */ - public function getStartOffset() - { - return $this->start_offset; - } - - public function hasStartOffset() - { - return isset($this->start_offset); - } - - public function clearStartOffset() - { - unset($this->start_offset); - } - - /** - * Time offset relative to the beginning of the audio, - * and corresponding to the start of the spoken word. - * This field is only set if - * [enable_word_time_offsets][google.cloud.speech.v2.RecognitionFeatures.enable_word_time_offsets] - * is `true` and only in the top hypothesis. This is an experimental feature - * and the accuracy of the time offset can vary. - * - * Generated from protobuf field .google.protobuf.Duration start_offset = 1; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setStartOffset($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->start_offset = $var; - - return $this; - } - - /** - * Time offset relative to the beginning of the audio, - * and corresponding to the end of the spoken word. - * This field is only set if - * [enable_word_time_offsets][google.cloud.speech.v2.RecognitionFeatures.enable_word_time_offsets] - * is `true` and only in the top hypothesis. This is an experimental feature - * and the accuracy of the time offset can vary. - * - * Generated from protobuf field .google.protobuf.Duration end_offset = 2; - * @return \Google\Protobuf\Duration|null - */ - public function getEndOffset() - { - return $this->end_offset; - } - - public function hasEndOffset() - { - return isset($this->end_offset); - } - - public function clearEndOffset() - { - unset($this->end_offset); - } - - /** - * Time offset relative to the beginning of the audio, - * and corresponding to the end of the spoken word. - * This field is only set if - * [enable_word_time_offsets][google.cloud.speech.v2.RecognitionFeatures.enable_word_time_offsets] - * is `true` and only in the top hypothesis. This is an experimental feature - * and the accuracy of the time offset can vary. - * - * Generated from protobuf field .google.protobuf.Duration end_offset = 2; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setEndOffset($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->end_offset = $var; - - return $this; - } - - /** - * The word corresponding to this set of information. - * - * Generated from protobuf field string word = 3; - * @return string - */ - public function getWord() - { - return $this->word; - } - - /** - * The word corresponding to this set of information. - * - * Generated from protobuf field string word = 3; - * @param string $var - * @return $this - */ - public function setWord($var) - { - GPBUtil::checkString($var, True); - $this->word = $var; - - return $this; - } - - /** - * The confidence estimate between 0.0 and 1.0. A higher number - * indicates an estimated greater likelihood that the recognized words are - * correct. This field is set only for the top alternative of a non-streaming - * result or, of a streaming result where - * [is_final][google.cloud.speech.v2.StreamingRecognitionResult.is_final] is - * set to `true`. This field is not guaranteed to be accurate and users should - * not rely on it to be always provided. The default of 0.0 is a sentinel - * value indicating `confidence` was not set. - * - * Generated from protobuf field float confidence = 4; - * @return float - */ - public function getConfidence() - { - return $this->confidence; - } - - /** - * The confidence estimate between 0.0 and 1.0. A higher number - * indicates an estimated greater likelihood that the recognized words are - * correct. This field is set only for the top alternative of a non-streaming - * result or, of a streaming result where - * [is_final][google.cloud.speech.v2.StreamingRecognitionResult.is_final] is - * set to `true`. This field is not guaranteed to be accurate and users should - * not rely on it to be always provided. The default of 0.0 is a sentinel - * value indicating `confidence` was not set. - * - * Generated from protobuf field float confidence = 4; - * @param float $var - * @return $this - */ - public function setConfidence($var) - { - GPBUtil::checkFloat($var); - $this->confidence = $var; - - return $this; - } - - /** - * A distinct label is assigned for every speaker within the audio. This field - * specifies which one of those speakers was detected to have spoken this - * word. `speaker_label` is set if - * [SpeakerDiarizationConfig][google.cloud.speech.v2.SpeakerDiarizationConfig] - * is given and only in the top alternative. - * - * Generated from protobuf field string speaker_label = 6; - * @return string - */ - public function getSpeakerLabel() - { - return $this->speaker_label; - } - - /** - * A distinct label is assigned for every speaker within the audio. This field - * specifies which one of those speakers was detected to have spoken this - * word. `speaker_label` is set if - * [SpeakerDiarizationConfig][google.cloud.speech.v2.SpeakerDiarizationConfig] - * is given and only in the top alternative. - * - * Generated from protobuf field string speaker_label = 6; - * @param string $var - * @return $this - */ - public function setSpeakerLabel($var) - { - GPBUtil::checkString($var, True); - $this->speaker_label = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/batch_recognize.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/batch_recognize.php deleted file mode 100644 index 65d2ac0db81b..000000000000 --- a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/batch_recognize.php +++ /dev/null @@ -1,88 +0,0 @@ -setRecognizer($formattedRecognizer); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $speechClient->batchRecognize($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var BatchRecognizeResponse $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 -{ - $formattedRecognizer = SpeechClient::recognizerName('[PROJECT]', '[LOCATION]', '[RECOGNIZER]'); - - batch_recognize_sample($formattedRecognizer); -} -// [END speech_v2_generated_Speech_BatchRecognize_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/create_custom_class.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/create_custom_class.php deleted file mode 100644 index 5ff6e27b3b79..000000000000 --- a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/create_custom_class.php +++ /dev/null @@ -1,86 +0,0 @@ -setCustomClass($customClass) - ->setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $speechClient->createCustomClass($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var CustomClass $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 = SpeechClient::locationName('[PROJECT]', '[LOCATION]'); - - create_custom_class_sample($formattedParent); -} -// [END speech_v2_generated_Speech_CreateCustomClass_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/create_phrase_set.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/create_phrase_set.php deleted file mode 100644 index 445e6537585f..000000000000 --- a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/create_phrase_set.php +++ /dev/null @@ -1,86 +0,0 @@ -setPhraseSet($phraseSet) - ->setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $speechClient->createPhraseSet($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var PhraseSet $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 = SpeechClient::locationName('[PROJECT]', '[LOCATION]'); - - create_phrase_set_sample($formattedParent); -} -// [END speech_v2_generated_Speech_CreatePhraseSet_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/create_recognizer.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/create_recognizer.php deleted file mode 100644 index f923356ae385..000000000000 --- a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/create_recognizer.php +++ /dev/null @@ -1,86 +0,0 @@ -setRecognizer($recognizer) - ->setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $speechClient->createRecognizer($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var Recognizer $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 = SpeechClient::locationName('[PROJECT]', '[LOCATION]'); - - create_recognizer_sample($formattedParent); -} -// [END speech_v2_generated_Speech_CreateRecognizer_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/delete_custom_class.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/delete_custom_class.php deleted file mode 100644 index ba763fbe24e8..000000000000 --- a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/delete_custom_class.php +++ /dev/null @@ -1,85 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $speechClient->deleteCustomClass($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var CustomClass $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 = SpeechClient::customClassName('[PROJECT]', '[LOCATION]', '[CUSTOM_CLASS]'); - - delete_custom_class_sample($formattedName); -} -// [END speech_v2_generated_Speech_DeleteCustomClass_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/delete_phrase_set.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/delete_phrase_set.php deleted file mode 100644 index 12f7de6cb8f1..000000000000 --- a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/delete_phrase_set.php +++ /dev/null @@ -1,84 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $speechClient->deletePhraseSet($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var PhraseSet $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 = SpeechClient::phraseSetName('[PROJECT]', '[LOCATION]', '[PHRASE_SET]'); - - delete_phrase_set_sample($formattedName); -} -// [END speech_v2_generated_Speech_DeletePhraseSet_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/delete_recognizer.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/delete_recognizer.php deleted file mode 100644 index 8cac60beca4e..000000000000 --- a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/delete_recognizer.php +++ /dev/null @@ -1,84 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $speechClient->deleteRecognizer($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var Recognizer $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 = SpeechClient::recognizerName('[PROJECT]', '[LOCATION]', '[RECOGNIZER]'); - - delete_recognizer_sample($formattedName); -} -// [END speech_v2_generated_Speech_DeleteRecognizer_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/get_config.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/get_config.php deleted file mode 100644 index 791ca668dee0..000000000000 --- a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/get_config.php +++ /dev/null @@ -1,73 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var Config $response */ - $response = $speechClient->getConfig($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 = SpeechClient::configName('[PROJECT]', '[LOCATION]'); - - get_config_sample($formattedName); -} -// [END speech_v2_generated_Speech_GetConfig_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/get_custom_class.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/get_custom_class.php deleted file mode 100644 index 1935c6ca7d3a..000000000000 --- a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/get_custom_class.php +++ /dev/null @@ -1,73 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var CustomClass $response */ - $response = $speechClient->getCustomClass($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 = SpeechClient::customClassName('[PROJECT]', '[LOCATION]', '[CUSTOM_CLASS]'); - - get_custom_class_sample($formattedName); -} -// [END speech_v2_generated_Speech_GetCustomClass_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/get_location.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/get_location.php deleted file mode 100644 index e570d04c6a7e..000000000000 --- a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/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 speech_v2_generated_Speech_GetLocation_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/get_phrase_set.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/get_phrase_set.php deleted file mode 100644 index 2764e2c6e55b..000000000000 --- a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/get_phrase_set.php +++ /dev/null @@ -1,73 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var PhraseSet $response */ - $response = $speechClient->getPhraseSet($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 = SpeechClient::phraseSetName('[PROJECT]', '[LOCATION]', '[PHRASE_SET]'); - - get_phrase_set_sample($formattedName); -} -// [END speech_v2_generated_Speech_GetPhraseSet_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/get_recognizer.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/get_recognizer.php deleted file mode 100644 index a9bdaa424341..000000000000 --- a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/get_recognizer.php +++ /dev/null @@ -1,75 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var Recognizer $response */ - $response = $speechClient->getRecognizer($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 = SpeechClient::recognizerName('[PROJECT]', '[LOCATION]', '[RECOGNIZER]'); - - get_recognizer_sample($formattedName); -} -// [END speech_v2_generated_Speech_GetRecognizer_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/list_custom_classes.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/list_custom_classes.php deleted file mode 100644 index 241c3b5072aa..000000000000 --- a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/list_custom_classes.php +++ /dev/null @@ -1,77 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $speechClient->listCustomClasses($request); - - /** @var CustomClass $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 = SpeechClient::locationName('[PROJECT]', '[LOCATION]'); - - list_custom_classes_sample($formattedParent); -} -// [END speech_v2_generated_Speech_ListCustomClasses_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/list_locations.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/list_locations.php deleted file mode 100644 index 8f437d0d9583..000000000000 --- a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/list_locations.php +++ /dev/null @@ -1,69 +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 speech_v2_generated_Speech_ListLocations_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/list_phrase_sets.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/list_phrase_sets.php deleted file mode 100644 index 24808eff8975..000000000000 --- a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/list_phrase_sets.php +++ /dev/null @@ -1,77 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $speechClient->listPhraseSets($request); - - /** @var PhraseSet $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 = SpeechClient::locationName('[PROJECT]', '[LOCATION]'); - - list_phrase_sets_sample($formattedParent); -} -// [END speech_v2_generated_Speech_ListPhraseSets_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/list_recognizers.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/list_recognizers.php deleted file mode 100644 index 9fc2ff0a2126..000000000000 --- a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/list_recognizers.php +++ /dev/null @@ -1,77 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $speechClient->listRecognizers($request); - - /** @var Recognizer $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 = SpeechClient::locationName('[PROJECT]', '[LOCATION]'); - - list_recognizers_sample($formattedParent); -} -// [END speech_v2_generated_Speech_ListRecognizers_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/recognize.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/recognize.php deleted file mode 100644 index db5043715fad..000000000000 --- a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/recognize.php +++ /dev/null @@ -1,75 +0,0 @@ -setRecognizer($formattedRecognizer); - - // Call the API and handle any network failures. - try { - /** @var RecognizeResponse $response */ - $response = $speechClient->recognize($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 -{ - $formattedRecognizer = SpeechClient::recognizerName('[PROJECT]', '[LOCATION]', '[RECOGNIZER]'); - - recognize_sample($formattedRecognizer); -} -// [END speech_v2_generated_Speech_Recognize_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/streaming_recognize.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/streaming_recognize.php deleted file mode 100644 index f4b1fdb5504a..000000000000 --- a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/streaming_recognize.php +++ /dev/null @@ -1,81 +0,0 @@ -setRecognizer($formattedRecognizer); - - // Call the API and handle any network failures. - try { - /** @var BidiStream $stream */ - $stream = $speechClient->streamingRecognize(); - $stream->writeAll([$request,]); - - /** @var StreamingRecognizeResponse $element */ - foreach ($stream->closeWriteAndReadAll() 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 -{ - $formattedRecognizer = SpeechClient::recognizerName('[PROJECT]', '[LOCATION]', '[RECOGNIZER]'); - - streaming_recognize_sample($formattedRecognizer); -} -// [END speech_v2_generated_Speech_StreamingRecognize_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/undelete_custom_class.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/undelete_custom_class.php deleted file mode 100644 index 40bcd62e88c0..000000000000 --- a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/undelete_custom_class.php +++ /dev/null @@ -1,85 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $speechClient->undeleteCustomClass($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var CustomClass $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 = SpeechClient::customClassName('[PROJECT]', '[LOCATION]', '[CUSTOM_CLASS]'); - - undelete_custom_class_sample($formattedName); -} -// [END speech_v2_generated_Speech_UndeleteCustomClass_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/undelete_phrase_set.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/undelete_phrase_set.php deleted file mode 100644 index 2185309a83f7..000000000000 --- a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/undelete_phrase_set.php +++ /dev/null @@ -1,84 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $speechClient->undeletePhraseSet($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var PhraseSet $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 = SpeechClient::phraseSetName('[PROJECT]', '[LOCATION]', '[PHRASE_SET]'); - - undelete_phrase_set_sample($formattedName); -} -// [END speech_v2_generated_Speech_UndeletePhraseSet_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/undelete_recognizer.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/undelete_recognizer.php deleted file mode 100644 index 96ab483bbbcf..000000000000 --- a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/undelete_recognizer.php +++ /dev/null @@ -1,84 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $speechClient->undeleteRecognizer($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var Recognizer $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 = SpeechClient::recognizerName('[PROJECT]', '[LOCATION]', '[RECOGNIZER]'); - - undelete_recognizer_sample($formattedName); -} -// [END speech_v2_generated_Speech_UndeleteRecognizer_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/update_config.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/update_config.php deleted file mode 100644 index 45cb1763e0f6..000000000000 --- a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/update_config.php +++ /dev/null @@ -1,59 +0,0 @@ -setConfig($config); - - // Call the API and handle any network failures. - try { - /** @var Config $response */ - $response = $speechClient->updateConfig($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END speech_v2_generated_Speech_UpdateConfig_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/update_custom_class.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/update_custom_class.php deleted file mode 100644 index 82c20a85957e..000000000000 --- a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/update_custom_class.php +++ /dev/null @@ -1,71 +0,0 @@ -setCustomClass($customClass); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $speechClient->updateCustomClass($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var CustomClass $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 speech_v2_generated_Speech_UpdateCustomClass_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/update_phrase_set.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/update_phrase_set.php deleted file mode 100644 index e3e0228abd3a..000000000000 --- a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/update_phrase_set.php +++ /dev/null @@ -1,71 +0,0 @@ -setPhraseSet($phraseSet); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $speechClient->updatePhraseSet($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var PhraseSet $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 speech_v2_generated_Speech_UpdatePhraseSet_sync] diff --git a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/update_recognizer.php b/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/update_recognizer.php deleted file mode 100644 index 70edda904635..000000000000 --- a/owl-bot-staging/Speech/v2/samples/V2/SpeechClient/update_recognizer.php +++ /dev/null @@ -1,71 +0,0 @@ -setRecognizer($recognizer); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $speechClient->updateRecognizer($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var Recognizer $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 speech_v2_generated_Speech_UpdateRecognizer_sync] diff --git a/owl-bot-staging/Speech/v2/src/V2/Client/SpeechClient.php b/owl-bot-staging/Speech/v2/src/V2/Client/SpeechClient.php deleted file mode 100644 index 61aba8321f65..000000000000 --- a/owl-bot-staging/Speech/v2/src/V2/Client/SpeechClient.php +++ /dev/null @@ -1,1120 +0,0 @@ - batchRecognizeAsync(BatchRecognizeRequest $request, array $optionalArgs = []) - * @method PromiseInterface createCustomClassAsync(CreateCustomClassRequest $request, array $optionalArgs = []) - * @method PromiseInterface createPhraseSetAsync(CreatePhraseSetRequest $request, array $optionalArgs = []) - * @method PromiseInterface createRecognizerAsync(CreateRecognizerRequest $request, array $optionalArgs = []) - * @method PromiseInterface deleteCustomClassAsync(DeleteCustomClassRequest $request, array $optionalArgs = []) - * @method PromiseInterface deletePhraseSetAsync(DeletePhraseSetRequest $request, array $optionalArgs = []) - * @method PromiseInterface deleteRecognizerAsync(DeleteRecognizerRequest $request, array $optionalArgs = []) - * @method PromiseInterface getConfigAsync(GetConfigRequest $request, array $optionalArgs = []) - * @method PromiseInterface getCustomClassAsync(GetCustomClassRequest $request, array $optionalArgs = []) - * @method PromiseInterface getPhraseSetAsync(GetPhraseSetRequest $request, array $optionalArgs = []) - * @method PromiseInterface getRecognizerAsync(GetRecognizerRequest $request, array $optionalArgs = []) - * @method PromiseInterface listCustomClassesAsync(ListCustomClassesRequest $request, array $optionalArgs = []) - * @method PromiseInterface listPhraseSetsAsync(ListPhraseSetsRequest $request, array $optionalArgs = []) - * @method PromiseInterface listRecognizersAsync(ListRecognizersRequest $request, array $optionalArgs = []) - * @method PromiseInterface recognizeAsync(RecognizeRequest $request, array $optionalArgs = []) - * @method PromiseInterface undeleteCustomClassAsync(UndeleteCustomClassRequest $request, array $optionalArgs = []) - * @method PromiseInterface undeletePhraseSetAsync(UndeletePhraseSetRequest $request, array $optionalArgs = []) - * @method PromiseInterface undeleteRecognizerAsync(UndeleteRecognizerRequest $request, array $optionalArgs = []) - * @method PromiseInterface updateConfigAsync(UpdateConfigRequest $request, array $optionalArgs = []) - * @method PromiseInterface updateCustomClassAsync(UpdateCustomClassRequest $request, array $optionalArgs = []) - * @method PromiseInterface updatePhraseSetAsync(UpdatePhraseSetRequest $request, array $optionalArgs = []) - * @method PromiseInterface updateRecognizerAsync(UpdateRecognizerRequest $request, array $optionalArgs = []) - * @method PromiseInterface getLocationAsync(GetLocationRequest $request, array $optionalArgs = []) - * @method PromiseInterface listLocationsAsync(ListLocationsRequest $request, array $optionalArgs = []) - */ -final class SpeechClient -{ - use GapicClientTrait; - use ResourceHelperTrait; - - /** The name of the service. */ - private const SERVICE_NAME = 'google.cloud.speech.v2.Speech'; - - /** - * The default address of the service. - * - * @deprecated SERVICE_ADDRESS_TEMPLATE should be used instead. - */ - private const SERVICE_ADDRESS = 'speech.googleapis.com'; - - /** The address template of the service. */ - private const SERVICE_ADDRESS_TEMPLATE = 'speech.UNIVERSE_DOMAIN'; - - /** The default port of the service. */ - private const DEFAULT_SERVICE_PORT = 443; - - /** The name of the code generator, to be included in the agent header. */ - private const CODEGEN_NAME = 'gapic'; - - /** The default scopes required by the service. */ - public static $serviceScopes = [ - 'https://www.googleapis.com/auth/cloud-platform', - ]; - - private $operationsClient; - - private static function getClientDefaults() - { - return [ - 'serviceName' => self::SERVICE_NAME, - 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, - 'clientConfig' => __DIR__ . '/../resources/speech_client_config.json', - 'descriptorsConfigPath' => __DIR__ . '/../resources/speech_descriptor_config.php', - 'gcpApiConfigPath' => __DIR__ . '/../resources/speech_grpc_config.json', - 'credentialsConfig' => [ - 'defaultScopes' => self::$serviceScopes, - ], - 'transportConfig' => [ - 'rest' => [ - 'restClientConfigPath' => __DIR__ . '/../resources/speech_rest_client_config.php', - ], - ], - ]; - } - - /** - * 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 = $this->descriptors[$methodName]['longRunning'] ?? []; - $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); - $operation->reload(); - return $operation; - } - - /** - * Create the default operation client for the service. - * - * @param array $options ClientOptions for the client. - * - * @return OperationsClient - */ - private function createOperationsClient(array $options) - { - // Unset client-specific configuration options - unset($options['serviceName'], $options['clientConfig'], $options['descriptorsConfigPath']); - - if (isset($options['operationsClient'])) { - return $options['operationsClient']; - } - - return new OperationsClient($options); - } - - /** - * Formats a string containing the fully-qualified path to represent a config - * resource. - * - * @param string $project - * @param string $location - * - * @return string The formatted config resource. - */ - public static function configName(string $project, string $location): string - { - return self::getPathTemplate('config')->render([ - 'project' => $project, - 'location' => $location, - ]); - } - - /** - * 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(string $project, string $location, string $keyRing, string $cryptoKey): string - { - return self::getPathTemplate('cryptoKey')->render([ - 'project' => $project, - 'location' => $location, - 'key_ring' => $keyRing, - 'crypto_key' => $cryptoKey, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * crypto_key_version resource. - * - * @param string $project - * @param string $location - * @param string $keyRing - * @param string $cryptoKey - * @param string $cryptoKeyVersion - * - * @return string The formatted crypto_key_version resource. - */ - public static function cryptoKeyVersionName(string $project, string $location, string $keyRing, string $cryptoKey, string $cryptoKeyVersion): string - { - return self::getPathTemplate('cryptoKeyVersion')->render([ - 'project' => $project, - 'location' => $location, - 'key_ring' => $keyRing, - 'crypto_key' => $cryptoKey, - 'crypto_key_version' => $cryptoKeyVersion, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a custom_class - * resource. - * - * @param string $project - * @param string $location - * @param string $customClass - * - * @return string The formatted custom_class resource. - */ - public static function customClassName(string $project, string $location, string $customClass): string - { - return self::getPathTemplate('customClass')->render([ - 'project' => $project, - 'location' => $location, - 'custom_class' => $customClass, - ]); - } - - /** - * 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(string $project, string $location): string - { - return self::getPathTemplate('location')->render([ - 'project' => $project, - 'location' => $location, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a phrase_set - * resource. - * - * @param string $project - * @param string $location - * @param string $phraseSet - * - * @return string The formatted phrase_set resource. - */ - public static function phraseSetName(string $project, string $location, string $phraseSet): string - { - return self::getPathTemplate('phraseSet')->render([ - 'project' => $project, - 'location' => $location, - 'phrase_set' => $phraseSet, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a recognizer - * resource. - * - * @param string $project - * @param string $location - * @param string $recognizer - * - * @return string The formatted recognizer resource. - */ - public static function recognizerName(string $project, string $location, string $recognizer): string - { - return self::getPathTemplate('recognizer')->render([ - 'project' => $project, - 'location' => $location, - 'recognizer' => $recognizer, - ]); - } - - /** - * Parses a formatted name string and returns an associative array of the components in the name. - * The following name formats are supported: - * Template: Pattern - * - config: projects/{project}/locations/{location}/config - * - cryptoKey: projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key} - * - cryptoKeyVersion: projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}/cryptoKeyVersions/{crypto_key_version} - * - customClass: projects/{project}/locations/{location}/customClasses/{custom_class} - * - location: projects/{project}/locations/{location} - * - phraseSet: projects/{project}/locations/{location}/phraseSets/{phrase_set} - * - recognizer: projects/{project}/locations/{location}/recognizers/{recognizer} - * - * 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(string $formattedName, ?string $template = null): array - { - return self::parseFormattedName($formattedName, $template); - } - - /** - * Constructor. - * - * @param array|ClientOptions $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 'speech.googleapis.com:443'. - * @type FetchAuthTokenInterface|CredentialsWrapper $credentials - * This option should only be used with a pre-constructed - * {@see FetchAuthTokenInterface} or {@see CredentialsWrapper} object. Note that - * when one of these objects are provided, any settings in $credentialsConfig will - * be ignored. - * **Important**: If you are providing a path to a credentials file, or a decoded - * credentials file as a PHP array, this usage is now DEPRECATED. Providing an - * unvalidated credential configuration to Google APIs can compromise the security - * of your systems and data. It is recommended to create the credentials explicitly - * ``` - * use Google\Auth\Credentials\ServiceAccountCredentials; - * use Google\Cloud\Speech\V2\SpeechClient; - * $creds = new ServiceAccountCredentials($scopes, $json); - * $options = new SpeechClient(['credentials' => $creds]); - * ``` - * {@see - * https://cloud.google.com/docs/authentication/external/externally-sourced-credentials} - * @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. - * @type false|LoggerInterface $logger - * A PSR-3 compliant logger. If set to false, logging is disabled, ignoring the - * 'GOOGLE_SDK_PHP_LOGGING' environment flag - * @type string $universeDomain - * The service domain for the client. Defaults to 'googleapis.com'. - * } - * - * @throws ValidationException - */ - public function __construct(array|ClientOptions $options = []) - { - $clientOptions = $this->buildClientOptions($options); - $this->setClientOptions($clientOptions); - $this->operationsClient = $this->createOperationsClient($clientOptions); - } - - /** Handles execution of the async variants for each documented method. */ - public function __call($method, $args) - { - if (substr($method, -5) !== 'Async') { - trigger_error('Call to undefined method ' . __CLASS__ . "::$method()", E_USER_ERROR); - } - - array_unshift($args, substr($method, 0, -5)); - return call_user_func_array([$this, 'startAsyncCall'], $args); - } - - /** - * Performs batch asynchronous speech recognition: send a request with N - * audio files and receive a long running operation that can be polled to see - * when the transcriptions are finished. - * - * The async variant is {@see SpeechClient::batchRecognizeAsync()} . - * - * @example samples/V2/SpeechClient/batch_recognize.php - * - * @param BatchRecognizeRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function batchRecognize(BatchRecognizeRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('BatchRecognize', $request, $callOptions)->wait(); - } - - /** - * Creates a [CustomClass][google.cloud.speech.v2.CustomClass]. - * - * The async variant is {@see SpeechClient::createCustomClassAsync()} . - * - * @example samples/V2/SpeechClient/create_custom_class.php - * - * @param CreateCustomClassRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function createCustomClass(CreateCustomClassRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('CreateCustomClass', $request, $callOptions)->wait(); - } - - /** - * Creates a [PhraseSet][google.cloud.speech.v2.PhraseSet]. - * - * The async variant is {@see SpeechClient::createPhraseSetAsync()} . - * - * @example samples/V2/SpeechClient/create_phrase_set.php - * - * @param CreatePhraseSetRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function createPhraseSet(CreatePhraseSetRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('CreatePhraseSet', $request, $callOptions)->wait(); - } - - /** - * Creates a [Recognizer][google.cloud.speech.v2.Recognizer]. - * - * The async variant is {@see SpeechClient::createRecognizerAsync()} . - * - * @example samples/V2/SpeechClient/create_recognizer.php - * - * @param CreateRecognizerRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function createRecognizer(CreateRecognizerRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('CreateRecognizer', $request, $callOptions)->wait(); - } - - /** - * Deletes the [CustomClass][google.cloud.speech.v2.CustomClass]. - * - * The async variant is {@see SpeechClient::deleteCustomClassAsync()} . - * - * @example samples/V2/SpeechClient/delete_custom_class.php - * - * @param DeleteCustomClassRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function deleteCustomClass(DeleteCustomClassRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('DeleteCustomClass', $request, $callOptions)->wait(); - } - - /** - * Deletes the [PhraseSet][google.cloud.speech.v2.PhraseSet]. - * - * The async variant is {@see SpeechClient::deletePhraseSetAsync()} . - * - * @example samples/V2/SpeechClient/delete_phrase_set.php - * - * @param DeletePhraseSetRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function deletePhraseSet(DeletePhraseSetRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('DeletePhraseSet', $request, $callOptions)->wait(); - } - - /** - * Deletes the [Recognizer][google.cloud.speech.v2.Recognizer]. - * - * The async variant is {@see SpeechClient::deleteRecognizerAsync()} . - * - * @example samples/V2/SpeechClient/delete_recognizer.php - * - * @param DeleteRecognizerRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function deleteRecognizer(DeleteRecognizerRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('DeleteRecognizer', $request, $callOptions)->wait(); - } - - /** - * Returns the requested [Config][google.cloud.speech.v2.Config]. - * - * The async variant is {@see SpeechClient::getConfigAsync()} . - * - * @example samples/V2/SpeechClient/get_config.php - * - * @param GetConfigRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Config - * - * @throws ApiException Thrown if the API call fails. - */ - public function getConfig(GetConfigRequest $request, array $callOptions = []): Config - { - return $this->startApiCall('GetConfig', $request, $callOptions)->wait(); - } - - /** - * Returns the requested - * [CustomClass][google.cloud.speech.v2.CustomClass]. - * - * The async variant is {@see SpeechClient::getCustomClassAsync()} . - * - * @example samples/V2/SpeechClient/get_custom_class.php - * - * @param GetCustomClassRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 CustomClass - * - * @throws ApiException Thrown if the API call fails. - */ - public function getCustomClass(GetCustomClassRequest $request, array $callOptions = []): CustomClass - { - return $this->startApiCall('GetCustomClass', $request, $callOptions)->wait(); - } - - /** - * Returns the requested - * [PhraseSet][google.cloud.speech.v2.PhraseSet]. - * - * The async variant is {@see SpeechClient::getPhraseSetAsync()} . - * - * @example samples/V2/SpeechClient/get_phrase_set.php - * - * @param GetPhraseSetRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PhraseSet - * - * @throws ApiException Thrown if the API call fails. - */ - public function getPhraseSet(GetPhraseSetRequest $request, array $callOptions = []): PhraseSet - { - return $this->startApiCall('GetPhraseSet', $request, $callOptions)->wait(); - } - - /** - * Returns the requested - * [Recognizer][google.cloud.speech.v2.Recognizer]. Fails with - * [NOT_FOUND][google.rpc.Code.NOT_FOUND] if the requested Recognizer doesn't - * exist. - * - * The async variant is {@see SpeechClient::getRecognizerAsync()} . - * - * @example samples/V2/SpeechClient/get_recognizer.php - * - * @param GetRecognizerRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Recognizer - * - * @throws ApiException Thrown if the API call fails. - */ - public function getRecognizer(GetRecognizerRequest $request, array $callOptions = []): Recognizer - { - return $this->startApiCall('GetRecognizer', $request, $callOptions)->wait(); - } - - /** - * Lists CustomClasses. - * - * The async variant is {@see SpeechClient::listCustomClassesAsync()} . - * - * @example samples/V2/SpeechClient/list_custom_classes.php - * - * @param ListCustomClassesRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listCustomClasses(ListCustomClassesRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListCustomClasses', $request, $callOptions); - } - - /** - * Lists PhraseSets. - * - * The async variant is {@see SpeechClient::listPhraseSetsAsync()} . - * - * @example samples/V2/SpeechClient/list_phrase_sets.php - * - * @param ListPhraseSetsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listPhraseSets(ListPhraseSetsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListPhraseSets', $request, $callOptions); - } - - /** - * Lists Recognizers. - * - * The async variant is {@see SpeechClient::listRecognizersAsync()} . - * - * @example samples/V2/SpeechClient/list_recognizers.php - * - * @param ListRecognizersRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listRecognizers(ListRecognizersRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListRecognizers', $request, $callOptions); - } - - /** - * Performs synchronous Speech recognition: receive results after all audio - * has been sent and processed. - * - * The async variant is {@see SpeechClient::recognizeAsync()} . - * - * @example samples/V2/SpeechClient/recognize.php - * - * @param RecognizeRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 RecognizeResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function recognize(RecognizeRequest $request, array $callOptions = []): RecognizeResponse - { - return $this->startApiCall('Recognize', $request, $callOptions)->wait(); - } - - /** - * Performs bidirectional streaming speech recognition: receive results while - * sending audio. This method is only available via the gRPC API (not REST). - * - * @example samples/V2/SpeechClient/streaming_recognize.php - * - * @param array $callOptions { - * Optional. - * - * @type int $timeoutMillis - * Timeout to use for this call. - * } - * - * @return BidiStream - * - * @throws ApiException Thrown if the API call fails. - */ - public function streamingRecognize(array $callOptions = []): BidiStream - { - return $this->startApiCall('StreamingRecognize', null, $callOptions); - } - - /** - * Undeletes the [CustomClass][google.cloud.speech.v2.CustomClass]. - * - * The async variant is {@see SpeechClient::undeleteCustomClassAsync()} . - * - * @example samples/V2/SpeechClient/undelete_custom_class.php - * - * @param UndeleteCustomClassRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function undeleteCustomClass(UndeleteCustomClassRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('UndeleteCustomClass', $request, $callOptions)->wait(); - } - - /** - * Undeletes the [PhraseSet][google.cloud.speech.v2.PhraseSet]. - * - * The async variant is {@see SpeechClient::undeletePhraseSetAsync()} . - * - * @example samples/V2/SpeechClient/undelete_phrase_set.php - * - * @param UndeletePhraseSetRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function undeletePhraseSet(UndeletePhraseSetRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('UndeletePhraseSet', $request, $callOptions)->wait(); - } - - /** - * Undeletes the [Recognizer][google.cloud.speech.v2.Recognizer]. - * - * The async variant is {@see SpeechClient::undeleteRecognizerAsync()} . - * - * @example samples/V2/SpeechClient/undelete_recognizer.php - * - * @param UndeleteRecognizerRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function undeleteRecognizer(UndeleteRecognizerRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('UndeleteRecognizer', $request, $callOptions)->wait(); - } - - /** - * Updates the [Config][google.cloud.speech.v2.Config]. - * - * The async variant is {@see SpeechClient::updateConfigAsync()} . - * - * @example samples/V2/SpeechClient/update_config.php - * - * @param UpdateConfigRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Config - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateConfig(UpdateConfigRequest $request, array $callOptions = []): Config - { - return $this->startApiCall('UpdateConfig', $request, $callOptions)->wait(); - } - - /** - * Updates the [CustomClass][google.cloud.speech.v2.CustomClass]. - * - * The async variant is {@see SpeechClient::updateCustomClassAsync()} . - * - * @example samples/V2/SpeechClient/update_custom_class.php - * - * @param UpdateCustomClassRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateCustomClass(UpdateCustomClassRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('UpdateCustomClass', $request, $callOptions)->wait(); - } - - /** - * Updates the [PhraseSet][google.cloud.speech.v2.PhraseSet]. - * - * The async variant is {@see SpeechClient::updatePhraseSetAsync()} . - * - * @example samples/V2/SpeechClient/update_phrase_set.php - * - * @param UpdatePhraseSetRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function updatePhraseSet(UpdatePhraseSetRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('UpdatePhraseSet', $request, $callOptions)->wait(); - } - - /** - * Updates the [Recognizer][google.cloud.speech.v2.Recognizer]. - * - * The async variant is {@see SpeechClient::updateRecognizerAsync()} . - * - * @example samples/V2/SpeechClient/update_recognizer.php - * - * @param UpdateRecognizerRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateRecognizer(UpdateRecognizerRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('UpdateRecognizer', $request, $callOptions)->wait(); - } - - /** - * Gets information about a location. - * - * The async variant is {@see SpeechClient::getLocationAsync()} . - * - * @example samples/V2/SpeechClient/get_location.php - * - * @param GetLocationRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Location - * - * @throws ApiException Thrown if the API call fails. - */ - public function getLocation(GetLocationRequest $request, array $callOptions = []): Location - { - return $this->startApiCall('GetLocation', $request, $callOptions)->wait(); - } - - /** - * Lists information about the supported locations for this service. - * This method can be called in two ways: - * - * * **List all public locations:** Use the path `GET /v1/locations`. - * * **List project-visible locations:** Use the path - * `GET /v1/projects/{project_id}/locations`. This may include public - * locations as well as private or other locations specifically visible - * to the project. - * - * The async variant is {@see SpeechClient::listLocationsAsync()} . - * - * @example samples/V2/SpeechClient/list_locations.php - * - * @param ListLocationsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listLocations(ListLocationsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListLocations', $request, $callOptions); - } -} diff --git a/owl-bot-staging/Speech/v2/src/V2/gapic_metadata.json b/owl-bot-staging/Speech/v2/src/V2/gapic_metadata.json deleted file mode 100644 index 1ad2778b344f..000000000000 --- a/owl-bot-staging/Speech/v2/src/V2/gapic_metadata.json +++ /dev/null @@ -1,143 +0,0 @@ -{ - "schema": "1.0", - "comment": "This file maps proto services\/RPCs to the corresponding library clients\/methods", - "language": "php", - "protoPackage": "google.cloud.speech.v2", - "libraryPackage": "Google\\Cloud\\Speech\\V2", - "services": { - "Speech": { - "clients": { - "grpc": { - "libraryClient": "SpeechGapicClient", - "rpcs": { - "BatchRecognize": { - "methods": [ - "batchRecognize" - ] - }, - "CreateCustomClass": { - "methods": [ - "createCustomClass" - ] - }, - "CreatePhraseSet": { - "methods": [ - "createPhraseSet" - ] - }, - "CreateRecognizer": { - "methods": [ - "createRecognizer" - ] - }, - "DeleteCustomClass": { - "methods": [ - "deleteCustomClass" - ] - }, - "DeletePhraseSet": { - "methods": [ - "deletePhraseSet" - ] - }, - "DeleteRecognizer": { - "methods": [ - "deleteRecognizer" - ] - }, - "GetConfig": { - "methods": [ - "getConfig" - ] - }, - "GetCustomClass": { - "methods": [ - "getCustomClass" - ] - }, - "GetPhraseSet": { - "methods": [ - "getPhraseSet" - ] - }, - "GetRecognizer": { - "methods": [ - "getRecognizer" - ] - }, - "ListCustomClasses": { - "methods": [ - "listCustomClasses" - ] - }, - "ListPhraseSets": { - "methods": [ - "listPhraseSets" - ] - }, - "ListRecognizers": { - "methods": [ - "listRecognizers" - ] - }, - "Recognize": { - "methods": [ - "recognize" - ] - }, - "StreamingRecognize": { - "methods": [ - "streamingRecognize" - ] - }, - "UndeleteCustomClass": { - "methods": [ - "undeleteCustomClass" - ] - }, - "UndeletePhraseSet": { - "methods": [ - "undeletePhraseSet" - ] - }, - "UndeleteRecognizer": { - "methods": [ - "undeleteRecognizer" - ] - }, - "UpdateConfig": { - "methods": [ - "updateConfig" - ] - }, - "UpdateCustomClass": { - "methods": [ - "updateCustomClass" - ] - }, - "UpdatePhraseSet": { - "methods": [ - "updatePhraseSet" - ] - }, - "UpdateRecognizer": { - "methods": [ - "updateRecognizer" - ] - }, - "GetLocation": { - "methods": [ - "getLocation" - ] - }, - "ListLocations": { - "methods": [ - "listLocations" - ] - } - } - } - } - } - } -} \ No newline at end of file diff --git a/owl-bot-staging/Speech/v2/src/V2/resources/speech_client_config.json b/owl-bot-staging/Speech/v2/src/V2/resources/speech_client_config.json deleted file mode 100644 index 09ee645f6c5c..000000000000 --- a/owl-bot-staging/Speech/v2/src/V2/resources/speech_client_config.json +++ /dev/null @@ -1,158 +0,0 @@ -{ - "interfaces": { - "google.cloud.speech.v2.Speech": { - "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": 100, - "retry_delay_multiplier": 1.3, - "max_retry_delay_millis": 60000, - "initial_rpc_timeout_millis": 5000000, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 5000000, - "total_timeout_millis": 5000000 - } - }, - "methods": { - "BatchRecognize": { - "timeout_millis": 5000000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "CreateCustomClass": { - "timeout_millis": 5000000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "CreatePhraseSet": { - "timeout_millis": 5000000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "CreateRecognizer": { - "timeout_millis": 5000000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "DeleteCustomClass": { - "timeout_millis": 5000000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "DeletePhraseSet": { - "timeout_millis": 5000000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "DeleteRecognizer": { - "timeout_millis": 5000000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetConfig": { - "timeout_millis": 5000000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetCustomClass": { - "timeout_millis": 5000000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetPhraseSet": { - "timeout_millis": 5000000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetRecognizer": { - "timeout_millis": 5000000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListCustomClasses": { - "timeout_millis": 5000000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListPhraseSets": { - "timeout_millis": 5000000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListRecognizers": { - "timeout_millis": 5000000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "Recognize": { - "timeout_millis": 5000000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "StreamingRecognize": { - "timeout_millis": 5000000 - }, - "UndeleteCustomClass": { - "timeout_millis": 5000000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "UndeletePhraseSet": { - "timeout_millis": 5000000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "UndeleteRecognizer": { - "timeout_millis": 5000000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "UpdateConfig": { - "timeout_millis": 5000000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "UpdateCustomClass": { - "timeout_millis": 5000000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "UpdatePhraseSet": { - "timeout_millis": 5000000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "UpdateRecognizer": { - "timeout_millis": 5000000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetLocation": { - "timeout_millis": 5000000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListLocations": { - "timeout_millis": 5000000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - } - } - } - } -} diff --git a/owl-bot-staging/Speech/v2/src/V2/resources/speech_descriptor_config.php b/owl-bot-staging/Speech/v2/src/V2/resources/speech_descriptor_config.php deleted file mode 100644 index 091a1cff366b..000000000000 --- a/owl-bot-staging/Speech/v2/src/V2/resources/speech_descriptor_config.php +++ /dev/null @@ -1,461 +0,0 @@ - [ - 'google.cloud.speech.v2.Speech' => [ - 'BatchRecognize' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\Speech\V2\BatchRecognizeResponse', - 'metadataReturnType' => '\Google\Cloud\Speech\V2\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'recognizer', - 'fieldAccessors' => [ - 'getRecognizer', - ], - ], - ], - ], - 'CreateCustomClass' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\Speech\V2\CustomClass', - 'metadataReturnType' => '\Google\Cloud\Speech\V2\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreatePhraseSet' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\Speech\V2\PhraseSet', - 'metadataReturnType' => '\Google\Cloud\Speech\V2\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateRecognizer' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\Speech\V2\Recognizer', - 'metadataReturnType' => '\Google\Cloud\Speech\V2\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'DeleteCustomClass' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\Speech\V2\CustomClass', - 'metadataReturnType' => '\Google\Cloud\Speech\V2\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'DeletePhraseSet' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\Speech\V2\PhraseSet', - 'metadataReturnType' => '\Google\Cloud\Speech\V2\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'DeleteRecognizer' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\Speech\V2\Recognizer', - 'metadataReturnType' => '\Google\Cloud\Speech\V2\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'UndeleteCustomClass' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\Speech\V2\CustomClass', - 'metadataReturnType' => '\Google\Cloud\Speech\V2\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'UndeletePhraseSet' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\Speech\V2\PhraseSet', - 'metadataReturnType' => '\Google\Cloud\Speech\V2\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'UndeleteRecognizer' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\Speech\V2\Recognizer', - 'metadataReturnType' => '\Google\Cloud\Speech\V2\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'UpdateCustomClass' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\Speech\V2\CustomClass', - 'metadataReturnType' => '\Google\Cloud\Speech\V2\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'custom_class.name', - 'fieldAccessors' => [ - 'getCustomClass', - 'getName', - ], - ], - ], - ], - 'UpdatePhraseSet' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\Speech\V2\PhraseSet', - 'metadataReturnType' => '\Google\Cloud\Speech\V2\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'phrase_set.name', - 'fieldAccessors' => [ - 'getPhraseSet', - 'getName', - ], - ], - ], - ], - 'UpdateRecognizer' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\Speech\V2\Recognizer', - 'metadataReturnType' => '\Google\Cloud\Speech\V2\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'recognizer.name', - 'fieldAccessors' => [ - 'getRecognizer', - 'getName', - ], - ], - ], - ], - 'GetConfig' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Speech\V2\Config', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetCustomClass' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Speech\V2\CustomClass', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetPhraseSet' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Speech\V2\PhraseSet', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetRecognizer' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Speech\V2\Recognizer', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'ListCustomClasses' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getCustomClasses', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\Speech\V2\ListCustomClassesResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListPhraseSets' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getPhraseSets', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\Speech\V2\ListPhraseSetsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListRecognizers' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getRecognizers', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\Speech\V2\ListRecognizersResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'Recognize' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Speech\V2\RecognizeResponse', - 'headerParams' => [ - [ - 'keyName' => 'recognizer', - 'fieldAccessors' => [ - 'getRecognizer', - ], - ], - ], - ], - 'StreamingRecognize' => [ - 'grpcStreaming' => [ - 'grpcStreamingType' => 'BidiStreaming', - ], - 'callType' => \Google\ApiCore\Call::BIDI_STREAMING_CALL, - 'responseType' => 'Google\Cloud\Speech\V2\StreamingRecognizeResponse', - ], - 'UpdateConfig' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\Speech\V2\Config', - 'headerParams' => [ - [ - 'keyName' => 'config.name', - 'fieldAccessors' => [ - 'getConfig', - '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' => [ - 'config' => 'projects/{project}/locations/{location}/config', - 'cryptoKey' => 'projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}', - 'cryptoKeyVersion' => 'projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}/cryptoKeyVersions/{crypto_key_version}', - 'customClass' => 'projects/{project}/locations/{location}/customClasses/{custom_class}', - 'location' => 'projects/{project}/locations/{location}', - 'phraseSet' => 'projects/{project}/locations/{location}/phraseSets/{phrase_set}', - 'recognizer' => 'projects/{project}/locations/{location}/recognizers/{recognizer}', - ], - ], - ], -]; diff --git a/owl-bot-staging/Speech/v2/src/V2/resources/speech_rest_client_config.php b/owl-bot-staging/Speech/v2/src/V2/resources/speech_rest_client_config.php deleted file mode 100644 index 504f631d5d8a..000000000000 --- a/owl-bot-staging/Speech/v2/src/V2/resources/speech_rest_client_config.php +++ /dev/null @@ -1,358 +0,0 @@ - [ - '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', - ], - ], - ], - ], - ], - 'google.cloud.speech.v2.Speech' => [ - 'BatchRecognize' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{recognizer=projects/*/locations/*/recognizers/*}:batchRecognize', - 'body' => '*', - 'placeholders' => [ - 'recognizer' => [ - 'getters' => [ - 'getRecognizer', - ], - ], - ], - ], - 'CreateCustomClass' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/customClasses', - 'body' => 'custom_class', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'CreatePhraseSet' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/phraseSets', - 'body' => 'phrase_set', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'CreateRecognizer' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/recognizers', - 'body' => 'recognizer', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'DeleteCustomClass' => [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/customClasses/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeletePhraseSet' => [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/phraseSets/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteRecognizer' => [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/recognizers/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetConfig' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/config}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetCustomClass' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/customClasses/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetPhraseSet' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/phraseSets/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetRecognizer' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/recognizers/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListCustomClasses' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/customClasses', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListPhraseSets' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/phraseSets', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListRecognizers' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{parent=projects/*/locations/*}/recognizers', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'Recognize' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{recognizer=projects/*/locations/*/recognizers/*}:recognize', - 'body' => '*', - 'placeholders' => [ - 'recognizer' => [ - 'getters' => [ - 'getRecognizer', - ], - ], - ], - ], - 'UndeleteCustomClass' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/customClasses/*}:undelete', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'UndeletePhraseSet' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/phraseSets/*}:undelete', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'UndeleteRecognizer' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/recognizers/*}:undelete', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'UpdateConfig' => [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{config.name=projects/*/locations/*/config}', - 'body' => 'config', - 'placeholders' => [ - 'config.name' => [ - 'getters' => [ - 'getConfig', - 'getName', - ], - ], - ], - ], - 'UpdateCustomClass' => [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{custom_class.name=projects/*/locations/*/customClasses/*}', - 'body' => 'custom_class', - 'placeholders' => [ - 'custom_class.name' => [ - 'getters' => [ - 'getCustomClass', - 'getName', - ], - ], - ], - ], - 'UpdatePhraseSet' => [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{phrase_set.name=projects/*/locations/*/phraseSets/*}', - 'body' => 'phrase_set', - 'placeholders' => [ - 'phrase_set.name' => [ - 'getters' => [ - 'getPhraseSet', - 'getName', - ], - ], - ], - ], - 'UpdateRecognizer' => [ - 'method' => 'patch', - 'uriTemplate' => '/v2/{recognizer.name=projects/*/locations/*/recognizers/*}', - 'body' => 'recognizer', - 'placeholders' => [ - 'recognizer.name' => [ - 'getters' => [ - 'getRecognizer', - 'getName', - ], - ], - ], - ], - ], - 'google.longrunning.Operations' => [ - 'CancelOperation' => [ - 'method' => 'post', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/operations/*}:cancel', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteOperation' => [ - 'method' => 'delete', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/operations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetOperation' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=projects/*/locations/*/operations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListOperations' => [ - 'method' => 'get', - 'uriTemplate' => '/v2/{name=projects/*/locations/*}/operations', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - ], - ], - 'numericEnums' => true, -]; diff --git a/owl-bot-staging/Speech/v2/tests/Unit/V2/Client/SpeechClientTest.php b/owl-bot-staging/Speech/v2/tests/Unit/V2/Client/SpeechClientTest.php deleted file mode 100644 index af3e0ee40bbe..000000000000 --- a/owl-bot-staging/Speech/v2/tests/Unit/V2/Client/SpeechClientTest.php +++ /dev/null @@ -1,2801 +0,0 @@ -getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); - } - - /** @return SpeechClient */ - private function createClient(array $options = []) - { - $options += [ - 'credentials' => $this->createCredentials(), - ]; - return new SpeechClient($options); - } - - /** @test */ - public function batchRecognizeTest() - { - $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/batchRecognizeTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new BatchRecognizeResponse(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/batchRecognizeTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedRecognizer = $gapicClient->recognizerName('[PROJECT]', '[LOCATION]', '[RECOGNIZER]'); - $request = (new BatchRecognizeRequest()) - ->setRecognizer($formattedRecognizer); - $response = $gapicClient->batchRecognize($request); - $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.speech.v2.Speech/BatchRecognize', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getRecognizer(); - $this->assertProtobufEquals($formattedRecognizer, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/batchRecognizeTest'); - $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 batchRecognizeExceptionTest() - { - $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/batchRecognizeTest'); - $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 - $formattedRecognizer = $gapicClient->recognizerName('[PROJECT]', '[LOCATION]', '[RECOGNIZER]'); - $request = (new BatchRecognizeRequest()) - ->setRecognizer($formattedRecognizer); - $response = $gapicClient->batchRecognize($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/batchRecognizeTest'); - 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 createCustomClassTest() - { - $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/createCustomClassTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $uid = 'uid115792'; - $displayName = 'displayName1615086568'; - $etag = 'etag3123477'; - $reconciling = false; - $kmsKeyName = 'kmsKeyName2094986649'; - $kmsKeyVersionName = 'kmsKeyVersionName-1734350176'; - $expectedResponse = new CustomClass(); - $expectedResponse->setName($name); - $expectedResponse->setUid($uid); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setEtag($etag); - $expectedResponse->setReconciling($reconciling); - $expectedResponse->setKmsKeyName($kmsKeyName); - $expectedResponse->setKmsKeyVersionName($kmsKeyVersionName); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createCustomClassTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $customClass = new CustomClass(); - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $request = (new CreateCustomClassRequest()) - ->setCustomClass($customClass) - ->setParent($formattedParent); - $response = $gapicClient->createCustomClass($request); - $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.speech.v2.Speech/CreateCustomClass', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getCustomClass(); - $this->assertProtobufEquals($customClass, $actualValue); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createCustomClassTest'); - $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 createCustomClassExceptionTest() - { - $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/createCustomClassTest'); - $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 - $customClass = new CustomClass(); - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $request = (new CreateCustomClassRequest()) - ->setCustomClass($customClass) - ->setParent($formattedParent); - $response = $gapicClient->createCustomClass($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createCustomClassTest'); - 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 createPhraseSetTest() - { - $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/createPhraseSetTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $uid = 'uid115792'; - $boost = 9392221; - $displayName = 'displayName1615086568'; - $etag = 'etag3123477'; - $reconciling = false; - $kmsKeyName = 'kmsKeyName2094986649'; - $kmsKeyVersionName = 'kmsKeyVersionName-1734350176'; - $expectedResponse = new PhraseSet(); - $expectedResponse->setName($name); - $expectedResponse->setUid($uid); - $expectedResponse->setBoost($boost); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setEtag($etag); - $expectedResponse->setReconciling($reconciling); - $expectedResponse->setKmsKeyName($kmsKeyName); - $expectedResponse->setKmsKeyVersionName($kmsKeyVersionName); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createPhraseSetTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $phraseSet = new PhraseSet(); - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $request = (new CreatePhraseSetRequest()) - ->setPhraseSet($phraseSet) - ->setParent($formattedParent); - $response = $gapicClient->createPhraseSet($request); - $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.speech.v2.Speech/CreatePhraseSet', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getPhraseSet(); - $this->assertProtobufEquals($phraseSet, $actualValue); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createPhraseSetTest'); - $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 createPhraseSetExceptionTest() - { - $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/createPhraseSetTest'); - $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 - $phraseSet = new PhraseSet(); - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $request = (new CreatePhraseSetRequest()) - ->setPhraseSet($phraseSet) - ->setParent($formattedParent); - $response = $gapicClient->createPhraseSet($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createPhraseSetTest'); - 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 createRecognizerTest() - { - $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/createRecognizerTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $uid = 'uid115792'; - $displayName = 'displayName1615086568'; - $model = 'model104069929'; - $etag = 'etag3123477'; - $reconciling = false; - $kmsKeyName = 'kmsKeyName2094986649'; - $kmsKeyVersionName = 'kmsKeyVersionName-1734350176'; - $expectedResponse = new Recognizer(); - $expectedResponse->setName($name); - $expectedResponse->setUid($uid); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setModel($model); - $expectedResponse->setEtag($etag); - $expectedResponse->setReconciling($reconciling); - $expectedResponse->setKmsKeyName($kmsKeyName); - $expectedResponse->setKmsKeyVersionName($kmsKeyVersionName); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createRecognizerTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $recognizer = new Recognizer(); - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $request = (new CreateRecognizerRequest()) - ->setRecognizer($recognizer) - ->setParent($formattedParent); - $response = $gapicClient->createRecognizer($request); - $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.speech.v2.Speech/CreateRecognizer', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getRecognizer(); - $this->assertProtobufEquals($recognizer, $actualValue); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createRecognizerTest'); - $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 createRecognizerExceptionTest() - { - $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/createRecognizerTest'); - $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 - $recognizer = new Recognizer(); - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $request = (new CreateRecognizerRequest()) - ->setRecognizer($recognizer) - ->setParent($formattedParent); - $response = $gapicClient->createRecognizer($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createRecognizerTest'); - 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 deleteCustomClassTest() - { - $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/deleteCustomClassTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name2 = 'name2-1052831874'; - $uid = 'uid115792'; - $displayName = 'displayName1615086568'; - $etag2 = 'etag2-1293302904'; - $reconciling = false; - $kmsKeyName = 'kmsKeyName2094986649'; - $kmsKeyVersionName = 'kmsKeyVersionName-1734350176'; - $expectedResponse = new CustomClass(); - $expectedResponse->setName($name2); - $expectedResponse->setUid($uid); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setEtag($etag2); - $expectedResponse->setReconciling($reconciling); - $expectedResponse->setKmsKeyName($kmsKeyName); - $expectedResponse->setKmsKeyVersionName($kmsKeyVersionName); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteCustomClassTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->customClassName('[PROJECT]', '[LOCATION]', '[CUSTOM_CLASS]'); - $request = (new DeleteCustomClassRequest()) - ->setName($formattedName); - $response = $gapicClient->deleteCustomClass($request); - $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.speech.v2.Speech/DeleteCustomClass', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteCustomClassTest'); - $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 deleteCustomClassExceptionTest() - { - $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/deleteCustomClassTest'); - $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->customClassName('[PROJECT]', '[LOCATION]', '[CUSTOM_CLASS]'); - $request = (new DeleteCustomClassRequest()) - ->setName($formattedName); - $response = $gapicClient->deleteCustomClass($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteCustomClassTest'); - 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 deletePhraseSetTest() - { - $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/deletePhraseSetTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name2 = 'name2-1052831874'; - $uid = 'uid115792'; - $boost = 9392221; - $displayName = 'displayName1615086568'; - $etag2 = 'etag2-1293302904'; - $reconciling = false; - $kmsKeyName = 'kmsKeyName2094986649'; - $kmsKeyVersionName = 'kmsKeyVersionName-1734350176'; - $expectedResponse = new PhraseSet(); - $expectedResponse->setName($name2); - $expectedResponse->setUid($uid); - $expectedResponse->setBoost($boost); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setEtag($etag2); - $expectedResponse->setReconciling($reconciling); - $expectedResponse->setKmsKeyName($kmsKeyName); - $expectedResponse->setKmsKeyVersionName($kmsKeyVersionName); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deletePhraseSetTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->phraseSetName('[PROJECT]', '[LOCATION]', '[PHRASE_SET]'); - $request = (new DeletePhraseSetRequest()) - ->setName($formattedName); - $response = $gapicClient->deletePhraseSet($request); - $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.speech.v2.Speech/DeletePhraseSet', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deletePhraseSetTest'); - $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 deletePhraseSetExceptionTest() - { - $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/deletePhraseSetTest'); - $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->phraseSetName('[PROJECT]', '[LOCATION]', '[PHRASE_SET]'); - $request = (new DeletePhraseSetRequest()) - ->setName($formattedName); - $response = $gapicClient->deletePhraseSet($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deletePhraseSetTest'); - 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 deleteRecognizerTest() - { - $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/deleteRecognizerTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name2 = 'name2-1052831874'; - $uid = 'uid115792'; - $displayName = 'displayName1615086568'; - $model = 'model104069929'; - $etag2 = 'etag2-1293302904'; - $reconciling = false; - $kmsKeyName = 'kmsKeyName2094986649'; - $kmsKeyVersionName = 'kmsKeyVersionName-1734350176'; - $expectedResponse = new Recognizer(); - $expectedResponse->setName($name2); - $expectedResponse->setUid($uid); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setModel($model); - $expectedResponse->setEtag($etag2); - $expectedResponse->setReconciling($reconciling); - $expectedResponse->setKmsKeyName($kmsKeyName); - $expectedResponse->setKmsKeyVersionName($kmsKeyVersionName); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteRecognizerTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->recognizerName('[PROJECT]', '[LOCATION]', '[RECOGNIZER]'); - $request = (new DeleteRecognizerRequest()) - ->setName($formattedName); - $response = $gapicClient->deleteRecognizer($request); - $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.speech.v2.Speech/DeleteRecognizer', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteRecognizerTest'); - $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 deleteRecognizerExceptionTest() - { - $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/deleteRecognizerTest'); - $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->recognizerName('[PROJECT]', '[LOCATION]', '[RECOGNIZER]'); - $request = (new DeleteRecognizerRequest()) - ->setName($formattedName); - $response = $gapicClient->deleteRecognizer($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteRecognizerTest'); - 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 getConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $kmsKeyName = 'kmsKeyName2094986649'; - $expectedResponse = new Config(); - $expectedResponse->setName($name2); - $expectedResponse->setKmsKeyName($kmsKeyName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->configName('[PROJECT]', '[LOCATION]'); - $request = (new GetConfigRequest()) - ->setName($formattedName); - $response = $gapicClient->getConfig($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.speech.v2.Speech/GetConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getConfigExceptionTest() - { - $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->configName('[PROJECT]', '[LOCATION]'); - $request = (new GetConfigRequest()) - ->setName($formattedName); - try { - $gapicClient->getConfig($request); - // 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 getCustomClassTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $uid = 'uid115792'; - $displayName = 'displayName1615086568'; - $etag = 'etag3123477'; - $reconciling = false; - $kmsKeyName = 'kmsKeyName2094986649'; - $kmsKeyVersionName = 'kmsKeyVersionName-1734350176'; - $expectedResponse = new CustomClass(); - $expectedResponse->setName($name2); - $expectedResponse->setUid($uid); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setEtag($etag); - $expectedResponse->setReconciling($reconciling); - $expectedResponse->setKmsKeyName($kmsKeyName); - $expectedResponse->setKmsKeyVersionName($kmsKeyVersionName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->customClassName('[PROJECT]', '[LOCATION]', '[CUSTOM_CLASS]'); - $request = (new GetCustomClassRequest()) - ->setName($formattedName); - $response = $gapicClient->getCustomClass($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.speech.v2.Speech/GetCustomClass', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getCustomClassExceptionTest() - { - $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->customClassName('[PROJECT]', '[LOCATION]', '[CUSTOM_CLASS]'); - $request = (new GetCustomClassRequest()) - ->setName($formattedName); - try { - $gapicClient->getCustomClass($request); - // 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 getPhraseSetTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $uid = 'uid115792'; - $boost = 9392221; - $displayName = 'displayName1615086568'; - $etag = 'etag3123477'; - $reconciling = false; - $kmsKeyName = 'kmsKeyName2094986649'; - $kmsKeyVersionName = 'kmsKeyVersionName-1734350176'; - $expectedResponse = new PhraseSet(); - $expectedResponse->setName($name2); - $expectedResponse->setUid($uid); - $expectedResponse->setBoost($boost); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setEtag($etag); - $expectedResponse->setReconciling($reconciling); - $expectedResponse->setKmsKeyName($kmsKeyName); - $expectedResponse->setKmsKeyVersionName($kmsKeyVersionName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->phraseSetName('[PROJECT]', '[LOCATION]', '[PHRASE_SET]'); - $request = (new GetPhraseSetRequest()) - ->setName($formattedName); - $response = $gapicClient->getPhraseSet($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.speech.v2.Speech/GetPhraseSet', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getPhraseSetExceptionTest() - { - $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->phraseSetName('[PROJECT]', '[LOCATION]', '[PHRASE_SET]'); - $request = (new GetPhraseSetRequest()) - ->setName($formattedName); - try { - $gapicClient->getPhraseSet($request); - // 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 getRecognizerTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $uid = 'uid115792'; - $displayName = 'displayName1615086568'; - $model = 'model104069929'; - $etag = 'etag3123477'; - $reconciling = false; - $kmsKeyName = 'kmsKeyName2094986649'; - $kmsKeyVersionName = 'kmsKeyVersionName-1734350176'; - $expectedResponse = new Recognizer(); - $expectedResponse->setName($name2); - $expectedResponse->setUid($uid); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setModel($model); - $expectedResponse->setEtag($etag); - $expectedResponse->setReconciling($reconciling); - $expectedResponse->setKmsKeyName($kmsKeyName); - $expectedResponse->setKmsKeyVersionName($kmsKeyVersionName); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->recognizerName('[PROJECT]', '[LOCATION]', '[RECOGNIZER]'); - $request = (new GetRecognizerRequest()) - ->setName($formattedName); - $response = $gapicClient->getRecognizer($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.speech.v2.Speech/GetRecognizer', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getRecognizerExceptionTest() - { - $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->recognizerName('[PROJECT]', '[LOCATION]', '[RECOGNIZER]'); - $request = (new GetRecognizerRequest()) - ->setName($formattedName); - try { - $gapicClient->getRecognizer($request); - // 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 listCustomClassesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $customClassesElement = new CustomClass(); - $customClasses = [ - $customClassesElement, - ]; - $expectedResponse = new ListCustomClassesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setCustomClasses($customClasses); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $request = (new ListCustomClassesRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listCustomClasses($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getCustomClasses()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.speech.v2.Speech/ListCustomClasses', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listCustomClassesExceptionTest() - { - $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]'); - $request = (new ListCustomClassesRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listCustomClasses($request); - // 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 listPhraseSetsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $phraseSetsElement = new PhraseSet(); - $phraseSets = [ - $phraseSetsElement, - ]; - $expectedResponse = new ListPhraseSetsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setPhraseSets($phraseSets); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $request = (new ListPhraseSetsRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listPhraseSets($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getPhraseSets()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.speech.v2.Speech/ListPhraseSets', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listPhraseSetsExceptionTest() - { - $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]'); - $request = (new ListPhraseSetsRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listPhraseSets($request); - // 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 listRecognizersTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $recognizersElement = new Recognizer(); - $recognizers = [ - $recognizersElement, - ]; - $expectedResponse = new ListRecognizersResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setRecognizers($recognizers); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $request = (new ListRecognizersRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listRecognizers($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getRecognizers()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.speech.v2.Speech/ListRecognizers', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listRecognizersExceptionTest() - { - $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]'); - $request = (new ListRecognizersRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listRecognizers($request); - // 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 recognizeTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new RecognizeResponse(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedRecognizer = $gapicClient->recognizerName('[PROJECT]', '[LOCATION]', '[RECOGNIZER]'); - $request = (new RecognizeRequest()) - ->setRecognizer($formattedRecognizer); - $response = $gapicClient->recognize($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.speech.v2.Speech/Recognize', $actualFuncCall); - $actualValue = $actualRequestObject->getRecognizer(); - $this->assertProtobufEquals($formattedRecognizer, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function recognizeExceptionTest() - { - $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 - $formattedRecognizer = $gapicClient->recognizerName('[PROJECT]', '[LOCATION]', '[RECOGNIZER]'); - $request = (new RecognizeRequest()) - ->setRecognizer($formattedRecognizer); - try { - $gapicClient->recognize($request); - // 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 streamingRecognizeTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new StreamingRecognizeResponse(); - $transport->addResponse($expectedResponse); - $expectedResponse2 = new StreamingRecognizeResponse(); - $transport->addResponse($expectedResponse2); - $expectedResponse3 = new StreamingRecognizeResponse(); - $transport->addResponse($expectedResponse3); - // Mock request - $formattedRecognizer = $gapicClient->recognizerName('[PROJECT]', '[LOCATION]', '[RECOGNIZER]'); - $request = new StreamingRecognizeRequest(); - $request->setRecognizer($formattedRecognizer); - $formattedRecognizer2 = $gapicClient->recognizerName('[PROJECT]', '[LOCATION]', '[RECOGNIZER]'); - $request2 = new StreamingRecognizeRequest(); - $request2->setRecognizer($formattedRecognizer2); - $formattedRecognizer3 = $gapicClient->recognizerName('[PROJECT]', '[LOCATION]', '[RECOGNIZER]'); - $request3 = new StreamingRecognizeRequest(); - $request3->setRecognizer($formattedRecognizer3); - $bidi = $gapicClient->streamingRecognize(); - $this->assertInstanceOf(BidiStream::class, $bidi); - $bidi->write($request); - $responses = []; - $responses[] = $bidi->read(); - $bidi->writeAll([ - $request2, - $request3, - ]); - foreach ($bidi->closeWriteAndReadAll() as $response) { - $responses[] = $response; - } - - $expectedResponses = []; - $expectedResponses[] = $expectedResponse; - $expectedResponses[] = $expectedResponse2; - $expectedResponses[] = $expectedResponse3; - $this->assertEquals($expectedResponses, $responses); - $createStreamRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($createStreamRequests)); - $streamFuncCall = $createStreamRequests[0]->getFuncCall(); - $streamRequestObject = $createStreamRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.speech.v2.Speech/StreamingRecognize', $streamFuncCall); - $this->assertNull($streamRequestObject); - $callObjects = $transport->popCallObjects(); - $this->assertSame(1, count($callObjects)); - $bidiCall = $callObjects[0]; - $writeRequests = $bidiCall->popReceivedCalls(); - $expectedRequests = []; - $expectedRequests[] = $request; - $expectedRequests[] = $request2; - $expectedRequests[] = $request3; - $this->assertEquals($expectedRequests, $writeRequests); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function streamingRecognizeExceptionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $status = new stdClass(); - $status->code = 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->setStreamingStatus($status); - $this->assertTrue($transport->isExhausted()); - $bidi = $gapicClient->streamingRecognize(); - $results = $bidi->closeWriteAndReadAll(); - try { - iterator_to_array($results); - // If the close stream method call did not throw, fail the test - $this->fail('Expected an ApiException, 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 undeleteCustomClassTest() - { - $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/undeleteCustomClassTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name2 = 'name2-1052831874'; - $uid = 'uid115792'; - $displayName = 'displayName1615086568'; - $etag2 = 'etag2-1293302904'; - $reconciling = false; - $kmsKeyName = 'kmsKeyName2094986649'; - $kmsKeyVersionName = 'kmsKeyVersionName-1734350176'; - $expectedResponse = new CustomClass(); - $expectedResponse->setName($name2); - $expectedResponse->setUid($uid); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setEtag($etag2); - $expectedResponse->setReconciling($reconciling); - $expectedResponse->setKmsKeyName($kmsKeyName); - $expectedResponse->setKmsKeyVersionName($kmsKeyVersionName); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/undeleteCustomClassTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->customClassName('[PROJECT]', '[LOCATION]', '[CUSTOM_CLASS]'); - $request = (new UndeleteCustomClassRequest()) - ->setName($formattedName); - $response = $gapicClient->undeleteCustomClass($request); - $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.speech.v2.Speech/UndeleteCustomClass', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/undeleteCustomClassTest'); - $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 undeleteCustomClassExceptionTest() - { - $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/undeleteCustomClassTest'); - $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->customClassName('[PROJECT]', '[LOCATION]', '[CUSTOM_CLASS]'); - $request = (new UndeleteCustomClassRequest()) - ->setName($formattedName); - $response = $gapicClient->undeleteCustomClass($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/undeleteCustomClassTest'); - 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 undeletePhraseSetTest() - { - $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/undeletePhraseSetTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name2 = 'name2-1052831874'; - $uid = 'uid115792'; - $boost = 9392221; - $displayName = 'displayName1615086568'; - $etag2 = 'etag2-1293302904'; - $reconciling = false; - $kmsKeyName = 'kmsKeyName2094986649'; - $kmsKeyVersionName = 'kmsKeyVersionName-1734350176'; - $expectedResponse = new PhraseSet(); - $expectedResponse->setName($name2); - $expectedResponse->setUid($uid); - $expectedResponse->setBoost($boost); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setEtag($etag2); - $expectedResponse->setReconciling($reconciling); - $expectedResponse->setKmsKeyName($kmsKeyName); - $expectedResponse->setKmsKeyVersionName($kmsKeyVersionName); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/undeletePhraseSetTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->phraseSetName('[PROJECT]', '[LOCATION]', '[PHRASE_SET]'); - $request = (new UndeletePhraseSetRequest()) - ->setName($formattedName); - $response = $gapicClient->undeletePhraseSet($request); - $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.speech.v2.Speech/UndeletePhraseSet', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/undeletePhraseSetTest'); - $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 undeletePhraseSetExceptionTest() - { - $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/undeletePhraseSetTest'); - $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->phraseSetName('[PROJECT]', '[LOCATION]', '[PHRASE_SET]'); - $request = (new UndeletePhraseSetRequest()) - ->setName($formattedName); - $response = $gapicClient->undeletePhraseSet($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/undeletePhraseSetTest'); - 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 undeleteRecognizerTest() - { - $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/undeleteRecognizerTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name2 = 'name2-1052831874'; - $uid = 'uid115792'; - $displayName = 'displayName1615086568'; - $model = 'model104069929'; - $etag2 = 'etag2-1293302904'; - $reconciling = false; - $kmsKeyName = 'kmsKeyName2094986649'; - $kmsKeyVersionName = 'kmsKeyVersionName-1734350176'; - $expectedResponse = new Recognizer(); - $expectedResponse->setName($name2); - $expectedResponse->setUid($uid); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setModel($model); - $expectedResponse->setEtag($etag2); - $expectedResponse->setReconciling($reconciling); - $expectedResponse->setKmsKeyName($kmsKeyName); - $expectedResponse->setKmsKeyVersionName($kmsKeyVersionName); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/undeleteRecognizerTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->recognizerName('[PROJECT]', '[LOCATION]', '[RECOGNIZER]'); - $request = (new UndeleteRecognizerRequest()) - ->setName($formattedName); - $response = $gapicClient->undeleteRecognizer($request); - $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.speech.v2.Speech/UndeleteRecognizer', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/undeleteRecognizerTest'); - $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 undeleteRecognizerExceptionTest() - { - $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/undeleteRecognizerTest'); - $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->recognizerName('[PROJECT]', '[LOCATION]', '[RECOGNIZER]'); - $request = (new UndeleteRecognizerRequest()) - ->setName($formattedName); - $response = $gapicClient->undeleteRecognizer($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/undeleteRecognizerTest'); - 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 updateConfigTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $kmsKeyName = 'kmsKeyName2094986649'; - $expectedResponse = new Config(); - $expectedResponse->setName($name); - $expectedResponse->setKmsKeyName($kmsKeyName); - $transport->addResponse($expectedResponse); - // Mock request - $config = new Config(); - $request = (new UpdateConfigRequest()) - ->setConfig($config); - $response = $gapicClient->updateConfig($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.speech.v2.Speech/UpdateConfig', $actualFuncCall); - $actualValue = $actualRequestObject->getConfig(); - $this->assertProtobufEquals($config, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateConfigExceptionTest() - { - $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 - $config = new Config(); - $request = (new UpdateConfigRequest()) - ->setConfig($config); - try { - $gapicClient->updateConfig($request); - // 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 updateCustomClassTest() - { - $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/updateCustomClassTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $uid = 'uid115792'; - $displayName = 'displayName1615086568'; - $etag = 'etag3123477'; - $reconciling = false; - $kmsKeyName = 'kmsKeyName2094986649'; - $kmsKeyVersionName = 'kmsKeyVersionName-1734350176'; - $expectedResponse = new CustomClass(); - $expectedResponse->setName($name); - $expectedResponse->setUid($uid); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setEtag($etag); - $expectedResponse->setReconciling($reconciling); - $expectedResponse->setKmsKeyName($kmsKeyName); - $expectedResponse->setKmsKeyVersionName($kmsKeyVersionName); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateCustomClassTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $customClass = new CustomClass(); - $request = (new UpdateCustomClassRequest()) - ->setCustomClass($customClass); - $response = $gapicClient->updateCustomClass($request); - $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.speech.v2.Speech/UpdateCustomClass', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getCustomClass(); - $this->assertProtobufEquals($customClass, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateCustomClassTest'); - $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 updateCustomClassExceptionTest() - { - $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/updateCustomClassTest'); - $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 - $customClass = new CustomClass(); - $request = (new UpdateCustomClassRequest()) - ->setCustomClass($customClass); - $response = $gapicClient->updateCustomClass($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateCustomClassTest'); - 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 updatePhraseSetTest() - { - $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/updatePhraseSetTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $uid = 'uid115792'; - $boost = 9392221; - $displayName = 'displayName1615086568'; - $etag = 'etag3123477'; - $reconciling = false; - $kmsKeyName = 'kmsKeyName2094986649'; - $kmsKeyVersionName = 'kmsKeyVersionName-1734350176'; - $expectedResponse = new PhraseSet(); - $expectedResponse->setName($name); - $expectedResponse->setUid($uid); - $expectedResponse->setBoost($boost); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setEtag($etag); - $expectedResponse->setReconciling($reconciling); - $expectedResponse->setKmsKeyName($kmsKeyName); - $expectedResponse->setKmsKeyVersionName($kmsKeyVersionName); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updatePhraseSetTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $phraseSet = new PhraseSet(); - $request = (new UpdatePhraseSetRequest()) - ->setPhraseSet($phraseSet); - $response = $gapicClient->updatePhraseSet($request); - $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.speech.v2.Speech/UpdatePhraseSet', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getPhraseSet(); - $this->assertProtobufEquals($phraseSet, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updatePhraseSetTest'); - $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 updatePhraseSetExceptionTest() - { - $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/updatePhraseSetTest'); - $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 - $phraseSet = new PhraseSet(); - $request = (new UpdatePhraseSetRequest()) - ->setPhraseSet($phraseSet); - $response = $gapicClient->updatePhraseSet($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updatePhraseSetTest'); - 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 updateRecognizerTest() - { - $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/updateRecognizerTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $uid = 'uid115792'; - $displayName = 'displayName1615086568'; - $model = 'model104069929'; - $etag = 'etag3123477'; - $reconciling = false; - $kmsKeyName = 'kmsKeyName2094986649'; - $kmsKeyVersionName = 'kmsKeyVersionName-1734350176'; - $expectedResponse = new Recognizer(); - $expectedResponse->setName($name); - $expectedResponse->setUid($uid); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setModel($model); - $expectedResponse->setEtag($etag); - $expectedResponse->setReconciling($reconciling); - $expectedResponse->setKmsKeyName($kmsKeyName); - $expectedResponse->setKmsKeyVersionName($kmsKeyVersionName); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateRecognizerTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $recognizer = new Recognizer(); - $request = (new UpdateRecognizerRequest()) - ->setRecognizer($recognizer); - $response = $gapicClient->updateRecognizer($request); - $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.speech.v2.Speech/UpdateRecognizer', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getRecognizer(); - $this->assertProtobufEquals($recognizer, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateRecognizerTest'); - $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 updateRecognizerExceptionTest() - { - $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/updateRecognizerTest'); - $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 - $recognizer = new Recognizer(); - $request = (new UpdateRecognizerRequest()) - ->setRecognizer($recognizer); - $response = $gapicClient->updateRecognizer($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateRecognizerTest'); - 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); - $request = new GetLocationRequest(); - $response = $gapicClient->getLocation($request); - $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); - $request = new GetLocationRequest(); - try { - $gapicClient->getLocation($request); - // 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); - $request = new ListLocationsRequest(); - $response = $gapicClient->listLocations($request); - $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); - $request = new ListLocationsRequest(); - try { - $gapicClient->listLocations($request); - // 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 batchRecognizeAsyncTest() - { - $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/batchRecognizeTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new BatchRecognizeResponse(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/batchRecognizeTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedRecognizer = $gapicClient->recognizerName('[PROJECT]', '[LOCATION]', '[RECOGNIZER]'); - $request = (new BatchRecognizeRequest()) - ->setRecognizer($formattedRecognizer); - $response = $gapicClient->batchRecognizeAsync($request)->wait(); - $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.speech.v2.Speech/BatchRecognize', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getRecognizer(); - $this->assertProtobufEquals($formattedRecognizer, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/batchRecognizeTest'); - $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()); - } -} diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/Common.php b/owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/Common.php deleted file mode 100644 index cd467ddbc772..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/Common.php +++ /dev/null @@ -1,24 +0,0 @@ -internalAddGeneratedFile( - "\x0A\x84\x03\x0A)google/cloud/vectorsearch/v1/common.proto\x12\x1Cgoogle.cloud.vectorsearch.v1*W\x0A\x0EDistanceMetric\x12\x1F\x0A\x1BDISTANCE_METRIC_UNSPECIFIED\x10\x00\x12\x0F\x0A\x0BDOT_PRODUCT\x10\x01\x12\x13\x0A\x0FCOSINE_DISTANCE\x10\x02B\xD7\x01\x0A com.google.cloud.vectorsearch.v1B\x0BCommonProtoP\x01ZDcloud.google.com/go/vectorsearch/apiv1/vectorsearchpb;vectorsearchpb\xAA\x02\x1CGoogle.Cloud.VectorSearch.V1\xCA\x02\x1CGoogle\\Cloud\\VectorSearch\\V1\xEA\x02\x1FGoogle::Cloud::VectorSearch::V1b\x06proto3" - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/DataObject.php b/owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/DataObject.php deleted file mode 100644 index a0be445d7b98..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/DataObject.php +++ /dev/null @@ -1,28 +0,0 @@ -internalAddGeneratedFile( - "\x0A\xB1\x09\x0A.google/cloud/vectorsearch/v1/data_object.proto\x12\x1Cgoogle.cloud.vectorsearch.v1\x1A\x19google/api/resource.proto\x1A\x1Cgoogle/protobuf/struct.proto\x1A\x1Fgoogle/protobuf/timestamp.proto\"\xAD\x04\x0A\x0ADataObject\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x08\x12\x1B\x0A\x0Edata_object_id\x18\x02 \x01(\x09B\x03\xE0A\x03\x124\x0A\x0Bcreate_time\x18\x04 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x05 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12*\x0A\x04data\x18\x06 \x01(\x0B2\x17.google.protobuf.StructB\x03\xE0A\x01\x12K\x0A\x07vectors\x18\x07 \x03(\x0B25.google.cloud.vectorsearch.v1.DataObject.VectorsEntryB\x03\xE0A\x01\x12\x11\x0A\x04etag\x18\x08 \x01(\x09B\x03\xE0A\x01\x1AT\x0A\x0CVectorsEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x123\x0A\x05value\x18\x02 \x01(\x0B2\$.google.cloud.vectorsearch.v1.Vector:\x028\x01:\xA0\x01\xEAA\x9C\x01\x0A&vectorsearch.googleapis.com/DataObject\x12Yprojects/{project}/locations/{location}/collections/{collection}/dataObjects/{dataObject}*\x0BdataObjects2\x0AdataObject\"\x91\x01\x0A\x06Vector\x12:\x0A\x05dense\x18\x02 \x01(\x0B2).google.cloud.vectorsearch.v1.DenseVectorH\x00\x12<\x0A\x06sparse\x18\x03 \x01(\x0B2*.google.cloud.vectorsearch.v1.SparseVectorH\x00B\x0D\x0A\x0Bvector_type\"\"\x0A\x0BDenseVector\x12\x13\x0A\x06values\x18\x01 \x03(\x02B\x03\xE0A\x02\"9\x0A\x0CSparseVector\x12\x13\x0A\x06values\x18\x01 \x03(\x02B\x03\xE0A\x02\x12\x14\x0A\x07indices\x18\x02 \x03(\x05B\x03\xE0A\x02B\xDB\x01\x0A com.google.cloud.vectorsearch.v1B\x0FDataObjectProtoP\x01ZDcloud.google.com/go/vectorsearch/apiv1/vectorsearchpb;vectorsearchpb\xAA\x02\x1CGoogle.Cloud.VectorSearch.V1\xCA\x02\x1CGoogle\\Cloud\\VectorSearch\\V1\xEA\x02\x1FGoogle::Cloud::VectorSearch::V1b\x06proto3" - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/DataObjectSearchService.php b/owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/DataObjectSearchService.php deleted file mode 100644 index 34f80ed9d5b4..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/DataObjectSearchService.php +++ /dev/null @@ -1,32 +0,0 @@ -internalAddGeneratedFile( - "\x0A\xD6)\x0A=google/cloud/vectorsearch/v1/data_object_search_service.proto\x12\x1Cgoogle.cloud.vectorsearch.v1\x1A\x17google/api/client.proto\x1A\x1Fgoogle/api/field_behavior.proto\x1A\x19google/api/resource.proto\x1A)google/cloud/vectorsearch/v1/common.proto\x1A.google/cloud/vectorsearch/v1/data_object.proto\x1A3google/cloud/vectorsearch/v1/embedding_config.proto\x1A\x1Cgoogle/protobuf/struct.proto\"b\x0A\x0COutputFields\x12\x18\x0A\x0Bdata_fields\x18\x01 \x03(\x09B\x03\xE0A\x01\x12\x1A\x0A\x0Dvector_fields\x18\x02 \x03(\x09B\x03\xE0A\x01\x12\x1C\x0A\x0Fmetadata_fields\x18\x03 \x03(\x09B\x03\xE0A\x01\"\x85\x02\x0A\x0ASearchHint\x12I\x0A\x08knn_hint\x18\x03 \x01(\x0B20.google.cloud.vectorsearch.v1.SearchHint.KnnHintB\x03\xE0A\x01H\x00\x12M\x0A\x0Aindex_hint\x18\x04 \x01(\x0B22.google.cloud.vectorsearch.v1.SearchHint.IndexHintB\x03\xE0A\x01H\x00\x1AD\x0A\x09IndexHint\x127\x0A\x04name\x18\x01 \x01(\x09B)\xE0A\x02\xFAA#\x0A!vectorsearch.googleapis.com/Index\x1A\x09\x0A\x07KnnHintB\x0C\x0A\x0Aindex_type\"\xE6\x01\x0A\x06Search\x12C\x0A\x0Dvector_search\x18\x01 \x01(\x0B2*.google.cloud.vectorsearch.v1.VectorSearchH\x00\x12G\x0A\x0Fsemantic_search\x18\x02 \x01(\x0B2,.google.cloud.vectorsearch.v1.SemanticSearchH\x00\x12?\x0A\x0Btext_search\x18\x03 \x01(\x0B2(.google.cloud.vectorsearch.v1.TextSearchH\x00B\x0D\x0A\x0Bsearch_type\"\xE3\x03\x0A\x0CVectorSearch\x12;\x0A\x06vector\x18\x01 \x01(\x0B2).google.cloud.vectorsearch.v1.DenseVectorH\x00\x12C\x0A\x0Dsparse_vector\x18\x02 \x01(\x0B2*.google.cloud.vectorsearch.v1.SparseVectorH\x00\x12\x19\x0A\x0Csearch_field\x18\x08 \x01(\x09B\x03\xE0A\x02\x12,\x0A\x06filter\x18\x04 \x01(\x0B2\x17.google.protobuf.StructB\x03\xE0A\x01\x12\x17\x0A\x05top_k\x18\x05 \x01(\x05B\x03\xE0A\x01H\x01\x88\x01\x01\x12F\x0A\x0Doutput_fields\x18\x07 \x01(\x0B2*.google.cloud.vectorsearch.v1.OutputFieldsB\x03\xE0A\x01\x12B\x0A\x0Bsearch_hint\x18\x09 \x01(\x0B2(.google.cloud.vectorsearch.v1.SearchHintB\x03\xE0A\x01\x12J\x0A\x0Fdistance_metric\x18\x0B \x01(\x0E2,.google.cloud.vectorsearch.v1.DistanceMetricB\x03\xE0A\x01B\x0D\x0A\x0Bvector_typeB\x08\x0A\x06_top_k\"\xEB\x02\x0A\x0ESemanticSearch\x12\x18\x0A\x0Bsearch_text\x18\x01 \x01(\x09B\x03\xE0A\x02\x12\x19\x0A\x0Csearch_field\x18\x02 \x01(\x09B\x03\xE0A\x02\x12G\x0A\x09task_type\x18\x05 \x01(\x0E2/.google.cloud.vectorsearch.v1.EmbeddingTaskTypeB\x03\xE0A\x02\x12F\x0A\x0Doutput_fields\x18\x03 \x01(\x0B2*.google.cloud.vectorsearch.v1.OutputFieldsB\x03\xE0A\x01\x12,\x0A\x06filter\x18\x06 \x01(\x0B2\x17.google.protobuf.StructB\x03\xE0A\x01\x12\x17\x0A\x05top_k\x18\x04 \x01(\x05B\x03\xE0A\x01H\x00\x88\x01\x01\x12B\x0A\x0Bsearch_hint\x18\x07 \x01(\x0B2(.google.cloud.vectorsearch.v1.SearchHintB\x03\xE0A\x01B\x08\x0A\x06_top_k\"\xDE\x01\x0A\x0ATextSearch\x12\x18\x0A\x0Bsearch_text\x18\x01 \x01(\x09B\x03\xE0A\x02\x12\x1D\x0A\x10data_field_names\x18\x02 \x03(\x09B\x03\xE0A\x02\x12F\x0A\x0Doutput_fields\x18\x03 \x01(\x0B2*.google.cloud.vectorsearch.v1.OutputFieldsB\x03\xE0A\x01\x12\x17\x0A\x05top_k\x18\x04 \x01(\x05B\x03\xE0A\x01H\x00\x88\x01\x01\x12,\x0A\x06filter\x18\x05 \x01(\x0B2\x17.google.protobuf.StructB\x03\xE0A\x01B\x08\x0A\x06_top_k\"\xEE\x02\x0A\x18SearchDataObjectsRequest\x12C\x0A\x0Dvector_search\x18\x02 \x01(\x0B2*.google.cloud.vectorsearch.v1.VectorSearchH\x00\x12G\x0A\x0Fsemantic_search\x18\x04 \x01(\x0B2,.google.cloud.vectorsearch.v1.SemanticSearchH\x00\x12D\x0A\x0Btext_search\x18\x07 \x01(\x0B2(.google.cloud.vectorsearch.v1.TextSearchB\x03\xE0A\x01H\x00\x12>\x0A\x06parent\x18\x01 \x01(\x09B.\xE0A\x02\xFAA(\x0A&vectorsearch.googleapis.com/Collection\x12\x16\x0A\x09page_size\x18\x05 \x01(\x05B\x03\xE0A\x01\x12\x17\x0A\x0Apage_token\x18\x06 \x01(\x09B\x03\xE0A\x01B\x0D\x0A\x0Bsearch_type\"{\x0A\x0CSearchResult\x12B\x0A\x0Bdata_object\x18\x01 \x01(\x0B2(.google.cloud.vectorsearch.v1.DataObjectB\x03\xE0A\x03\x12\x1A\x0A\x08distance\x18\x02 \x01(\x01B\x03\xE0A\x03H\x00\x88\x01\x01B\x0B\x0A\x09_distance\"{\x0A\x19SearchDataObjectsResponse\x12@\x0A\x07results\x18\x01 \x03(\x0B2*.google.cloud.vectorsearch.v1.SearchResultB\x03\xE0A\x03\x12\x1C\x0A\x0Fnext_page_token\x18\x02 \x01(\x09B\x03\xE0A\x03\"\xD4\x01\x0A\x1BAggregateDataObjectsRequest\x12>\x0A\x06parent\x18\x01 \x01(\x09B.\xE0A\x02\xFAA(\x0A&vectorsearch.googleapis.com/Collection\x12,\x0A\x06filter\x18\x02 \x01(\x0B2\x17.google.protobuf.StructB\x03\xE0A\x01\x12G\x0A\x09aggregate\x18\x03 \x01(\x0E2/.google.cloud.vectorsearch.v1.AggregationMethodB\x03\xE0A\x02\"W\x0A\x1CAggregateDataObjectsResponse\x127\x0A\x11aggregate_results\x18\x01 \x03(\x0B2\x17.google.protobuf.StructB\x03\xE0A\x03\"\x80\x02\x0A\x17QueryDataObjectsRequest\x12>\x0A\x06parent\x18\x01 \x01(\x09B.\xE0A\x02\xFAA(\x0A&vectorsearch.googleapis.com/Collection\x12,\x0A\x06filter\x18\x02 \x01(\x0B2\x17.google.protobuf.StructB\x03\xE0A\x01\x12F\x0A\x0Doutput_fields\x18\x07 \x01(\x0B2*.google.cloud.vectorsearch.v1.OutputFieldsB\x03\xE0A\x01\x12\x16\x0A\x09page_size\x18\x05 \x01(\x05B\x03\xE0A\x01\x12\x17\x0A\x0Apage_token\x18\x06 \x01(\x09B\x03\xE0A\x01\"}\x0A\x18QueryDataObjectsResponse\x12C\x0A\x0Cdata_objects\x18\x04 \x03(\x0B2(.google.cloud.vectorsearch.v1.DataObjectB\x03\xE0A\x03\x12\x1C\x0A\x0Fnext_page_token\x18\x03 \x01(\x09B\x03\xE0A\x03\"\xB6\x03\x0A\x1DBatchSearchDataObjectsRequest\x12>\x0A\x06parent\x18\x01 \x01(\x09B.\xE0A\x02\xFAA(\x0A&vectorsearch.googleapis.com/Collection\x12;\x0A\x08searches\x18\x02 \x03(\x0B2\$.google.cloud.vectorsearch.v1.SearchB\x03\xE0A\x02\x12g\x0A\x07combine\x18\x03 \x01(\x0B2Q.google.cloud.vectorsearch.v1.BatchSearchDataObjectsRequest.CombineResultsOptionsB\x03\xE0A\x01\x1A\xAE\x01\x0A\x15CombineResultsOptions\x129\x0A\x06ranker\x18\x01 \x01(\x0B2\$.google.cloud.vectorsearch.v1.RankerB\x03\xE0A\x02\x12F\x0A\x0Doutput_fields\x18\x02 \x01(\x0B2*.google.cloud.vectorsearch.v1.OutputFieldsB\x03\xE0A\x01\x12\x12\x0A\x05top_k\x18\x03 \x01(\x05B\x03\xE0A\x01\"U\x0A\x06Ranker\x12A\x0A\x03rrf\x18\x01 \x01(\x0B22.google.cloud.vectorsearch.v1.ReciprocalRankFusionH\x00B\x08\x0A\x06ranker\",\x0A\x14ReciprocalRankFusion\x12\x14\x0A\x07weights\x18\x01 \x03(\x01B\x03\xE0A\x02\"o\x0A\x1EBatchSearchDataObjectsResponse\x12M\x0A\x07results\x18\x01 \x03(\x0B27.google.cloud.vectorsearch.v1.SearchDataObjectsResponseB\x03\xE0A\x03*B\x0A\x11AggregationMethod\x12\"\x0A\x1EAGGREGATION_METHOD_UNSPECIFIED\x10\x00\x12\x09\x0A\x05COUNT\x10\x012\xE6\x07\x0A\x17DataObjectSearchService\x12\xD5\x01\x0A\x11SearchDataObjects\x126.google.cloud.vectorsearch.v1.SearchDataObjectsRequest\x1A7.google.cloud.vectorsearch.v1.SearchDataObjectsResponse\"O\x82\xD3\xE4\x93\x02I\"D/v1/{parent=projects/*/locations/*/collections/*}/dataObjects:search:\x01*\x12\xD1\x01\x0A\x10QueryDataObjects\x125.google.cloud.vectorsearch.v1.QueryDataObjectsRequest\x1A6.google.cloud.vectorsearch.v1.QueryDataObjectsResponse\"N\x82\xD3\xE4\x93\x02H\"C/v1/{parent=projects/*/locations/*/collections/*}/dataObjects:query:\x01*\x12\xE1\x01\x0A\x14AggregateDataObjects\x129.google.cloud.vectorsearch.v1.AggregateDataObjectsRequest\x1A:.google.cloud.vectorsearch.v1.AggregateDataObjectsResponse\"R\x82\xD3\xE4\x93\x02L\"G/v1/{parent=projects/*/locations/*/collections/*}/dataObjects:aggregate:\x01*\x12\xE9\x01\x0A\x16BatchSearchDataObjects\x12;.google.cloud.vectorsearch.v1.BatchSearchDataObjectsRequest\x1A<.google.cloud.vectorsearch.v1.BatchSearchDataObjectsResponse\"T\x82\xD3\xE4\x93\x02N\"I/v1/{parent=projects/*/locations/*/collections/*}/dataObjects:batchSearch:\x01*\x1AO\xCAA\x1Bvectorsearch.googleapis.com\xD2A.https://www.googleapis.com/auth/cloud-platformB\xE8\x01\x0A com.google.cloud.vectorsearch.v1B\x1CDataObjectSearchServiceProtoP\x01ZDcloud.google.com/go/vectorsearch/apiv1/vectorsearchpb;vectorsearchpb\xAA\x02\x1CGoogle.Cloud.VectorSearch.V1\xCA\x02\x1CGoogle\\Cloud\\VectorSearch\\V1\xEA\x02\x1FGoogle::Cloud::VectorSearch::V1b\x06proto3" - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/DataObjectService.php b/owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/DataObjectService.php deleted file mode 100644 index b3cfadbf1eaa..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/DataObjectService.php +++ /dev/null @@ -1,31 +0,0 @@ -internalAddGeneratedFile( - "\x0A\xAC\x1A\x0A6google/cloud/vectorsearch/v1/data_object_service.proto\x12\x1Cgoogle.cloud.vectorsearch.v1\x1A\x17google/api/client.proto\x1A\x1Fgoogle/api/field_behavior.proto\x1A\x19google/api/resource.proto\x1A.google/cloud/vectorsearch/v1/data_object.proto\x1A\x1Bgoogle/protobuf/empty.proto\x1A google/protobuf/field_mask.proto\"\xBA\x01\x0A\x17CreateDataObjectRequest\x12>\x0A\x06parent\x18\x01 \x01(\x09B.\xE0A\x02\xFAA(\x0A&vectorsearch.googleapis.com/Collection\x12\x1B\x0A\x0Edata_object_id\x18\x02 \x01(\x09B\x03\xE0A\x02\x12B\x0A\x0Bdata_object\x18\x03 \x01(\x0B2(.google.cloud.vectorsearch.v1.DataObjectB\x03\xE0A\x02\"\xAD\x01\x0A\x1DBatchCreateDataObjectsRequest\x12>\x0A\x06parent\x18\x01 \x01(\x09B.\xE0A\x02\xFAA(\x0A&vectorsearch.googleapis.com/Collection\x12L\x0A\x08requests\x18\x02 \x03(\x0B25.google.cloud.vectorsearch.v1.CreateDataObjectRequestB\x03\xE0A\x02\"e\x0A\x1EBatchCreateDataObjectsResponse\x12C\x0A\x0Cdata_objects\x18\x01 \x03(\x0B2(.google.cloud.vectorsearch.v1.DataObjectB\x03\xE0A\x03\"T\x0A\x14GetDataObjectRequest\x12<\x0A\x04name\x18\x01 \x01(\x09B.\xE0A\x02\xFAA(\x0A&vectorsearch.googleapis.com/DataObject\"\x93\x01\x0A\x17UpdateDataObjectRequest\x12B\x0A\x0Bdata_object\x18\x01 \x01(\x0B2(.google.cloud.vectorsearch.v1.DataObjectB\x03\xE0A\x02\x124\x0A\x0Bupdate_mask\x18\x02 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x01\"\xAD\x01\x0A\x1DBatchUpdateDataObjectsRequest\x12>\x0A\x06parent\x18\x01 \x01(\x09B.\xE0A\x02\xFAA(\x0A&vectorsearch.googleapis.com/Collection\x12L\x0A\x08requests\x18\x02 \x03(\x0B25.google.cloud.vectorsearch.v1.UpdateDataObjectRequestB\x03\xE0A\x02\" \x0A\x1EBatchUpdateDataObjectsResponse\"j\x0A\x17DeleteDataObjectRequest\x12<\x0A\x04name\x18\x01 \x01(\x09B.\xE0A\x02\xFAA(\x0A&vectorsearch.googleapis.com/DataObject\x12\x11\x0A\x04etag\x18\x02 \x01(\x09B\x03\xE0A\x01\"\xAD\x01\x0A\x1DBatchDeleteDataObjectsRequest\x12>\x0A\x06parent\x18\x01 \x01(\x09B.\xE0A\x02\xFAA(\x0A&vectorsearch.googleapis.com/Collection\x12L\x0A\x08requests\x18\x03 \x03(\x0B25.google.cloud.vectorsearch.v1.DeleteDataObjectRequestB\x03\xE0A\x022\xF4\x0C\x0A\x11DataObjectService\x12\xEB\x01\x0A\x10CreateDataObject\x125.google.cloud.vectorsearch.v1.CreateDataObjectRequest\x1A(.google.cloud.vectorsearch.v1.DataObject\"v\xDAA!parent,data_object,data_object_id\x82\xD3\xE4\x93\x02L\"=/v1/{parent=projects/*/locations/*/collections/*}/dataObjects:\x0Bdata_object\x12\xE9\x01\x0A\x16BatchCreateDataObjects\x12;.google.cloud.vectorsearch.v1.BatchCreateDataObjectsRequest\x1A<.google.cloud.vectorsearch.v1.BatchCreateDataObjectsResponse\"T\x82\xD3\xE4\x93\x02N\"I/v1/{parent=projects/*/locations/*/collections/*}/dataObjects:batchCreate:\x01*\x12\xBB\x01\x0A\x0DGetDataObject\x122.google.cloud.vectorsearch.v1.GetDataObjectRequest\x1A(.google.cloud.vectorsearch.v1.DataObject\"L\xDAA\x04name\x82\xD3\xE4\x93\x02?\x12=/v1/{name=projects/*/locations/*/collections/*/dataObjects/*}\x12\xED\x01\x0A\x10UpdateDataObject\x125.google.cloud.vectorsearch.v1.UpdateDataObjectRequest\x1A(.google.cloud.vectorsearch.v1.DataObject\"x\xDAA\x17data_object,update_mask\x82\xD3\xE4\x93\x02X2I/v1/{data_object.name=projects/*/locations/*/collections/*/dataObjects/*}:\x0Bdata_object\x12\xFB\x01\x0A\x16BatchUpdateDataObjects\x12;.google.cloud.vectorsearch.v1.BatchUpdateDataObjectsRequest\x1A<.google.cloud.vectorsearch.v1.BatchUpdateDataObjectsResponse\"f\xDAA\x0Fparent,requests\x82\xD3\xE4\x93\x02N\"I/v1/{parent=projects/*/locations/*/collections/*}/dataObjects:batchUpdate:\x01*\x12\xAF\x01\x0A\x10DeleteDataObject\x125.google.cloud.vectorsearch.v1.DeleteDataObjectRequest\x1A\x16.google.protobuf.Empty\"L\xDAA\x04name\x82\xD3\xE4\x93\x02?*=/v1/{name=projects/*/locations/*/collections/*/dataObjects/*}\x12\xD5\x01\x0A\x16BatchDeleteDataObjects\x12;.google.cloud.vectorsearch.v1.BatchDeleteDataObjectsRequest\x1A\x16.google.protobuf.Empty\"f\xDAA\x0Fparent,requests\x82\xD3\xE4\x93\x02N\"I/v1/{parent=projects/*/locations/*/collections/*}/dataObjects:batchDelete:\x01*\x1AO\xCAA\x1Bvectorsearch.googleapis.com\xD2A.https://www.googleapis.com/auth/cloud-platformB\xE2\x01\x0A com.google.cloud.vectorsearch.v1B\x16DataObjectServiceProtoP\x01ZDcloud.google.com/go/vectorsearch/apiv1/vectorsearchpb;vectorsearchpb\xAA\x02\x1CGoogle.Cloud.VectorSearch.V1\xCA\x02\x1CGoogle\\Cloud\\VectorSearch\\V1\xEA\x02\x1FGoogle::Cloud::VectorSearch::V1b\x06proto3" - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/EmbeddingConfig.php b/owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/EmbeddingConfig.php deleted file mode 100644 index ac217693e49c..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/EmbeddingConfig.php +++ /dev/null @@ -1,25 +0,0 @@ -internalAddGeneratedFile( - "\x0A\xC2\x05\x0A3google/cloud/vectorsearch/v1/embedding_config.proto\x12\x1Cgoogle.cloud.vectorsearch.v1\"\x93\x01\x0A\x15VertexEmbeddingConfig\x12\x15\x0A\x08model_id\x18\x01 \x01(\x09B\x03\xE0A\x02\x12\x1A\x0A\x0Dtext_template\x18\x02 \x01(\x09B\x03\xE0A\x02\x12G\x0A\x09task_type\x18\x03 \x01(\x0E2/.google.cloud.vectorsearch.v1.EmbeddingTaskTypeB\x03\xE0A\x02*\xEB\x01\x0A\x11EmbeddingTaskType\x12#\x0A\x1FEMBEDDING_TASK_TYPE_UNSPECIFIED\x10\x00\x12\x13\x0A\x0FRETRIEVAL_QUERY\x10\x01\x12\x16\x0A\x12RETRIEVAL_DOCUMENT\x10\x02\x12\x17\x0A\x13SEMANTIC_SIMILARITY\x10\x03\x12\x12\x0A\x0ECLASSIFICATION\x10\x04\x12\x0E\x0A\x0ACLUSTERING\x10\x05\x12\x16\x0A\x12QUESTION_ANSWERING\x10\x06\x12\x15\x0A\x11FACT_VERIFICATION\x10\x07\x12\x18\x0A\x14CODE_RETRIEVAL_QUERY\x10\x08B\xE0\x01\x0A com.google.cloud.vectorsearch.v1B\x14EmbeddingConfigProtoP\x01ZDcloud.google.com/go/vectorsearch/apiv1/vectorsearchpb;vectorsearchpb\xAA\x02\x1CGoogle.Cloud.VectorSearch.V1\xCA\x02\x1CGoogle\\Cloud\\VectorSearch\\V1\xEA\x02\x1FGoogle::Cloud::VectorSearch::V1b\x06proto3" - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/EncryptionSpec.php b/owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/EncryptionSpec.php deleted file mode 100644 index af0cb82e4992..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/EncryptionSpec.php +++ /dev/null @@ -1,26 +0,0 @@ -internalAddGeneratedFile( - "\x0A\xA8\x04\x0A2google/cloud/vectorsearch/v1/encryption_spec.proto\x12\x1Cgoogle.cloud.vectorsearch.v1\x1A\x19google/api/resource.proto\"T\x0A\x0EEncryptionSpec\x12B\x0A\x0Fcrypto_key_name\x18\x01 \x01(\x09B)\xE0A\x02\xFAA#\x0A!cloudkms.googleapis.com/CryptoKeyB\xDA\x02\x0A com.google.cloud.vectorsearch.v1B\x13EncryptionSpecProtoP\x01ZDcloud.google.com/go/vectorsearch/apiv1/vectorsearchpb;vectorsearchpb\xAA\x02\x1CGoogle.Cloud.VectorSearch.V1\xCA\x02\x1CGoogle\\Cloud\\VectorSearch\\V1\xEA\x02\x1FGoogle::Cloud::VectorSearch::V1\xEAAx\x0A!cloudkms.googleapis.com/CryptoKey\x12Sprojects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}b\x06proto3" - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/VectorsearchService.php b/owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/VectorsearchService.php deleted file mode 100644 index 163e08d1aa1e..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/GPBMetadata/Google/Cloud/Vectorsearch/V1/VectorsearchService.php +++ /dev/null @@ -1,38 +0,0 @@ -internalAddGeneratedFile( - "\x0A\xA5G\x0A7google/cloud/vectorsearch/v1/vectorsearch_service.proto\x12\x1Cgoogle.cloud.vectorsearch.v1\x1A\x17google/api/client.proto\x1A\x1Fgoogle/api/field_behavior.proto\x1A\x1Bgoogle/api/field_info.proto\x1A\x19google/api/resource.proto\x1A)google/cloud/vectorsearch/v1/common.proto\x1A3google/cloud/vectorsearch/v1/embedding_config.proto\x1A2google/cloud/vectorsearch/v1/encryption_spec.proto\x1A#google/longrunning/operations.proto\x1A\x1Bgoogle/protobuf/empty.proto\x1A google/protobuf/field_mask.proto\x1A\x1Cgoogle/protobuf/struct.proto\x1A\x1Fgoogle/protobuf/timestamp.proto\x1A\x17google/rpc/status.proto\"\xFE\x05\x0A\x0ACollection\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x08\x12\x19\x0A\x0Cdisplay_name\x18\x08 \x01(\x09B\x03\xE0A\x01\x12\x18\x0A\x0Bdescription\x18\x09 \x01(\x09B\x03\xE0A\x01\x124\x0A\x0Bcreate_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x03 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12I\x0A\x06labels\x18\x04 \x03(\x0B24.google.cloud.vectorsearch.v1.Collection.LabelsEntryB\x03\xE0A\x01\x12V\x0A\x0Dvector_schema\x18\x07 \x03(\x0B2:.google.cloud.vectorsearch.v1.Collection.VectorSchemaEntryB\x03\xE0A\x01\x121\x0A\x0Bdata_schema\x18\x0A \x01(\x0B2\x17.google.protobuf.StructB\x03\xE0A\x01\x12M\x0A\x0Fencryption_spec\x18\x0B \x01(\x0B2,.google.cloud.vectorsearch.v1.EncryptionSpecB\x06\xE0A\x05\xE0A\x01\x1A-\x0A\x0BLabelsEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12\x0D\x0A\x05value\x18\x02 \x01(\x09:\x028\x01\x1A^\x0A\x11VectorSchemaEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x128\x0A\x05value\x18\x02 \x01(\x0B2).google.cloud.vectorsearch.v1.VectorField:\x028\x01:\x87\x01\xEAA\x83\x01\x0A&vectorsearch.googleapis.com/Collection\x12@projects/{project}/locations/{location}/collections/{collection}*\x0Bcollections2\x0Acollection\"\xB5\x01\x0A\x0BVectorField\x12F\x0A\x0Cdense_vector\x18\x03 \x01(\x0B2..google.cloud.vectorsearch.v1.DenseVectorFieldH\x00\x12H\x0A\x0Dsparse_vector\x18\x04 \x01(\x0B2/.google.cloud.vectorsearch.v1.SparseVectorFieldH\x00B\x14\x0A\x12vector_type_config\"\x81\x01\x0A\x10DenseVectorField\x12\x12\x0A\x0Adimensions\x18\x01 \x01(\x05\x12Y\x0A\x17vertex_embedding_config\x18\x03 \x01(\x0B23.google.cloud.vectorsearch.v1.VertexEmbeddingConfigB\x03\xE0A\x01\"\x13\x0A\x11SparseVectorField\"\xB5\x01\x0A\x16ListCollectionsRequest\x12>\x0A\x06parent\x18\x01 \x01(\x09B.\xE0A\x02\xFAA(\x12&vectorsearch.googleapis.com/Collection\x12\x16\x0A\x09page_size\x18\x02 \x01(\x05B\x03\xE0A\x01\x12\x17\x0A\x0Apage_token\x18\x03 \x01(\x09B\x03\xE0A\x01\x12\x13\x0A\x06filter\x18\x04 \x01(\x09B\x03\xE0A\x01\x12\x15\x0A\x08order_by\x18\x05 \x01(\x09B\x03\xE0A\x01\"\x8B\x01\x0A\x17ListCollectionsResponse\x12=\x0A\x0Bcollections\x18\x01 \x03(\x0B2(.google.cloud.vectorsearch.v1.Collection\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\x12\x18\x0A\x0Bunreachable\x18\x03 \x03(\x09B\x03\xE0A\x06\"T\x0A\x14GetCollectionRequest\x12<\x0A\x04name\x18\x01 \x01(\x09B.\xE0A\x02\xFAA(\x0A&vectorsearch.googleapis.com/Collection\"\xD9\x01\x0A\x17CreateCollectionRequest\x12>\x0A\x06parent\x18\x01 \x01(\x09B.\xE0A\x02\xFAA(\x12&vectorsearch.googleapis.com/Collection\x12\x1A\x0A\x0Dcollection_id\x18\x02 \x01(\x09B\x03\xE0A\x02\x12A\x0A\x0Acollection\x18\x03 \x01(\x0B2(.google.cloud.vectorsearch.v1.CollectionB\x03\xE0A\x02\x12\x1F\x0A\x0Arequest_id\x18\x04 \x01(\x09B\x0B\xE0A\x01\xE2\x8C\xCF\xD7\x08\x02\x08\x01\"\xB3\x01\x0A\x17UpdateCollectionRequest\x124\x0A\x0Bupdate_mask\x18\x01 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x01\x12A\x0A\x0Acollection\x18\x02 \x01(\x0B2(.google.cloud.vectorsearch.v1.CollectionB\x03\xE0A\x02\x12\x1F\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x0B\xE0A\x01\xE2\x8C\xCF\xD7\x08\x02\x08\x01\"x\x0A\x17DeleteCollectionRequest\x12<\x0A\x04name\x18\x01 \x01(\x09B.\xE0A\x02\xFAA(\x0A&vectorsearch.googleapis.com/Collection\x12\x1F\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x0B\xE0A\x01\xE2\x8C\xCF\xD7\x08\x02\x08\x01\"\xA0\x06\x0A\x05Index\x12^\x0A\x18dedicated_infrastructure\x18\x0B \x01(\x0B25.google.cloud.vectorsearch.v1.DedicatedInfrastructureB\x03\xE0A\x01H\x00\x12I\x0A\x0Bdense_scann\x18\x0C \x01(\x0B2-.google.cloud.vectorsearch.v1.DenseScannIndexB\x03\xE0A\x01H\x01\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x08\x12\x19\x0A\x0Cdisplay_name\x18\x08 \x01(\x09B\x03\xE0A\x01\x12\x18\x0A\x0Bdescription\x18\x09 \x01(\x09B\x03\xE0A\x01\x12D\x0A\x06labels\x18\x0A \x03(\x0B2/.google.cloud.vectorsearch.v1.Index.LabelsEntryB\x03\xE0A\x01\x124\x0A\x0Bcreate_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x03 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12J\x0A\x0Fdistance_metric\x18\x04 \x01(\x0E2,.google.cloud.vectorsearch.v1.DistanceMetricB\x03\xE0A\x01\x12\x18\x0A\x0Bindex_field\x18\x05 \x01(\x09B\x03\xE0A\x02\x12\x1A\x0A\x0Dfilter_fields\x18\x06 \x03(\x09B\x03\xE0A\x01\x12\x19\x0A\x0Cstore_fields\x18\x07 \x03(\x09B\x03\xE0A\x01\x1A-\x0A\x0BLabelsEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12\x0D\x0A\x05value\x18\x02 \x01(\x09:\x028\x01:\x89\x01\xEAA\x85\x01\x0A!vectorsearch.googleapis.com/Index\x12Pprojects/{project}/locations/{location}/collections/{collection}/indexes/{index}*\x07indexes2\x05indexB\x0C\x0A\x0Ainfra_typeB\x0C\x0A\x0Aindex_type\"\xC5\x01\x0A\x12CreateIndexRequest\x12>\x0A\x06parent\x18\x01 \x01(\x09B.\xE0A\x02\xFAA(\x0A&vectorsearch.googleapis.com/Collection\x12\x15\x0A\x08index_id\x18\x02 \x01(\x09B\x03\xE0A\x02\x127\x0A\x05index\x18\x03 \x01(\x0B2#.google.cloud.vectorsearch.v1.IndexB\x03\xE0A\x02\x12\x1F\x0A\x0Arequest_id\x18\x04 \x01(\x09B\x0B\xE0A\x01\xE2\x8C\xCF\xD7\x08\x02\x08\x01\"\xA4\x01\x0A\x12UpdateIndexRequest\x127\x0A\x05index\x18\x01 \x01(\x0B2#.google.cloud.vectorsearch.v1.IndexB\x03\xE0A\x02\x124\x0A\x0Bupdate_mask\x18\x02 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x01\x12\x1F\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x0B\xE0A\x01\xE2\x8C\xCF\xD7\x08\x02\x08\x01\"n\x0A\x12DeleteIndexRequest\x127\x0A\x04name\x18\x01 \x01(\x09B)\xE0A\x02\xFAA#\x0A!vectorsearch.googleapis.com/Index\x12\x1F\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x0B\xE0A\x01\xE2\x8C\xCF\xD7\x08\x02\x08\x01\"\xAC\x01\x0A\x12ListIndexesRequest\x129\x0A\x06parent\x18\x01 \x01(\x09B)\xE0A\x02\xFAA#\x12!vectorsearch.googleapis.com/Index\x12\x16\x0A\x09page_size\x18\x02 \x01(\x05B\x03\xE0A\x01\x12\x17\x0A\x0Apage_token\x18\x03 \x01(\x09B\x03\xE0A\x01\x12\x13\x0A\x06filter\x18\x04 \x01(\x09B\x03\xE0A\x01\x12\x15\x0A\x08order_by\x18\x05 \x01(\x09B\x03\xE0A\x01\"d\x0A\x13ListIndexesResponse\x124\x0A\x07indexes\x18\x01 \x03(\x0B2#.google.cloud.vectorsearch.v1.Index\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\"J\x0A\x0FGetIndexRequest\x127\x0A\x04name\x18\x01 \x01(\x09B)\xE0A\x02\xFAA#\x0A!vectorsearch.googleapis.com/Index\"\x80\x02\x0A\x11OperationMetadata\x124\x0A\x0Bcreate_time\x18\x01 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x121\x0A\x08end_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12\x13\x0A\x06target\x18\x03 \x01(\x09B\x03\xE0A\x03\x12\x11\x0A\x04verb\x18\x04 \x01(\x09B\x03\xE0A\x03\x12\x1B\x0A\x0Estatus_message\x18\x05 \x01(\x09B\x03\xE0A\x03\x12#\x0A\x16requested_cancellation\x18\x06 \x01(\x08B\x03\xE0A\x03\x12\x18\x0A\x0Bapi_version\x18\x07 \x01(\x09B\x03\xE0A\x03\"\x9F\x02\x0A\x18ImportDataObjectsRequest\x12\\\x0A\x0Agcs_import\x18\x02 \x01(\x0B2F.google.cloud.vectorsearch.v1.ImportDataObjectsRequest.GcsImportConfigH\x00\x12<\x0A\x04name\x18\x01 \x01(\x09B.\xE0A\x02\xFAA(\x0A&vectorsearch.googleapis.com/Collection\x1A]\x0A\x0FGcsImportConfig\x12\x19\x0A\x0Ccontents_uri\x18\x01 \x01(\x09B\x03\xE0A\x02\x12\x16\x0A\x09error_uri\x18\x02 \x01(\x09B\x03\xE0A\x02\x12\x17\x0A\x0Aoutput_uri\x18\x03 \x01(\x09B\x03\xE0A\x01B\x08\x0A\x06config\"\xBF\x01\x0A\x19ImportDataObjectsMetadata\x124\x0A\x0Bcreate_time\x18\x01 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12\x1A\x0A\x0Dsuccess_count\x18\x03 \x01(\x03B\x03\xE0A\x03\x12\x1A\x0A\x0Dfailure_count\x18\x04 \x01(\x03B\x03\xE0A\x03\"?\x0A\x19ImportDataObjectsResponse\x12\"\x0A\x06status\x18\x01 \x01(\x0B2\x12.google.rpc.Status\"\x97\x03\x0A\x18ExportDataObjectsRequest\x12f\x0A\x0Fgcs_destination\x18\x02 \x01(\x0B2K.google.cloud.vectorsearch.v1.ExportDataObjectsRequest.GcsExportDestinationH\x00\x12<\x0A\x04name\x18\x01 \x01(\x09B.\xE0A\x02\xFAA(\x0A&vectorsearch.googleapis.com/Collection\x1A\xC5\x01\x0A\x14GcsExportDestination\x12\x17\x0A\x0Aexport_uri\x18\x01 \x01(\x09B\x03\xE0A\x02\x12g\x0A\x06format\x18\x02 \x01(\x0E2R.google.cloud.vectorsearch.v1.ExportDataObjectsRequest.GcsExportDestination.FormatB\x03\xE0A\x02\"+\x0A\x06Format\x12\x16\x0A\x12FORMAT_UNSPECIFIED\x10\x00\x12\x09\x0A\x05JSONL\x10\x02B\x0D\x0A\x0Bdestination\"\x87\x01\x0A\x19ExportDataObjectsMetadata\x124\x0A\x0Bcreate_time\x18\x01 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bfinish_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\"\x1B\x0A\x19ExportDataObjectsResponse\"\xFF\x02\x0A\x17DedicatedInfrastructure\x12R\x0A\x04mode\x18\x01 \x01(\x0E2:.google.cloud.vectorsearch.v1.DedicatedInfrastructure.ModeB\x03\xE0A\x01H\x00\x88\x01\x01\x12d\x0A\x10autoscaling_spec\x18\x02 \x01(\x0B2E.google.cloud.vectorsearch.v1.DedicatedInfrastructure.AutoscalingSpecB\x03\xE0A\x01\x1AQ\x0A\x0FAutoscalingSpec\x12\x1E\x0A\x11min_replica_count\x18\x01 \x01(\x05B\x03\xE0A\x01\x12\x1E\x0A\x11max_replica_count\x18\x02 \x01(\x05B\x03\xE0A\x01\"N\x0A\x04Mode\x12\x14\x0A\x10MODE_UNSPECIFIED\x10\x00\x12\x15\x0A\x11STORAGE_OPTIMIZED\x10\x01\x12\x19\x0A\x15PERFORMANCE_OPTIMIZED\x10\x02B\x07\x0A\x05_mode\"\xC2\x01\x0A\x0FDenseScannIndex\x12]\x0A\x11feature_norm_type\x18\x02 \x01(\x0E2=.google.cloud.vectorsearch.v1.DenseScannIndex.FeatureNormTypeB\x03\xE0A\x01\"P\x0A\x0FFeatureNormType\x12!\x0A\x1DFEATURE_NORM_TYPE_UNSPECIFIED\x10\x00\x12\x08\x0A\x04NONE\x10\x01\x12\x10\x0A\x0CUNIT_L2_NORM\x10\x022\x8D\x15\x0A\x13VectorSearchService\x12\xC0\x01\x0A\x0FListCollections\x124.google.cloud.vectorsearch.v1.ListCollectionsRequest\x1A5.google.cloud.vectorsearch.v1.ListCollectionsResponse\"@\xDAA\x06parent\x82\xD3\xE4\x93\x021\x12//v1/{parent=projects/*/locations/*}/collections\x12\xAD\x01\x0A\x0DGetCollection\x122.google.cloud.vectorsearch.v1.GetCollectionRequest\x1A(.google.cloud.vectorsearch.v1.Collection\">\xDAA\x04name\x82\xD3\xE4\x93\x021\x12//v1/{name=projects/*/locations/*/collections/*}\x12\xF2\x01\x0A\x10CreateCollection\x125.google.cloud.vectorsearch.v1.CreateCollectionRequest\x1A\x1D.google.longrunning.Operation\"\x87\x01\xCAA\x1F\x0A\x0ACollection\x12\x11OperationMetadata\xDAA\x1Fparent,collection,collection_id\x82\xD3\xE4\x93\x02=\"//v1/{parent=projects/*/locations/*}/collections:\x0Acollection\x12\xF4\x01\x0A\x10UpdateCollection\x125.google.cloud.vectorsearch.v1.UpdateCollectionRequest\x1A\x1D.google.longrunning.Operation\"\x89\x01\xCAA\x1F\x0A\x0ACollection\x12\x11OperationMetadata\xDAA\x16collection,update_mask\x82\xD3\xE4\x93\x02H2:/v1/{collection.name=projects/*/locations/*/collections/*}:\x0Acollection\x12\xD5\x01\x0A\x10DeleteCollection\x125.google.cloud.vectorsearch.v1.DeleteCollectionRequest\x1A\x1D.google.longrunning.Operation\"k\xCAA*\x0A\x15google.protobuf.Empty\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x021*//v1/{name=projects/*/locations/*/collections/*}\x12\xBE\x01\x0A\x0BListIndexes\x120.google.cloud.vectorsearch.v1.ListIndexesRequest\x1A1.google.cloud.vectorsearch.v1.ListIndexesResponse\"J\xDAA\x06parent\x82\xD3\xE4\x93\x02;\x129/v1/{parent=projects/*/locations/*/collections/*}/indexes\x12\xA8\x01\x0A\x08GetIndex\x12-.google.cloud.vectorsearch.v1.GetIndexRequest\x1A#.google.cloud.vectorsearch.v1.Index\"H\xDAA\x04name\x82\xD3\xE4\x93\x02;\x129/v1/{name=projects/*/locations/*/collections/*/indexes/*}\x12\xDD\x01\x0A\x0BCreateIndex\x120.google.cloud.vectorsearch.v1.CreateIndexRequest\x1A\x1D.google.longrunning.Operation\"}\xCAA\x1A\x0A\x05Index\x12\x11OperationMetadata\xDAA\x15parent,index,index_id\x82\xD3\xE4\x93\x02B\"9/v1/{parent=projects/*/locations/*/collections/*}/indexes:\x05index\x12\xDF\x01\x0A\x0BUpdateIndex\x120.google.cloud.vectorsearch.v1.UpdateIndexRequest\x1A\x1D.google.longrunning.Operation\"\x7F\xCAA\x1A\x0A\x05Index\x12\x11OperationMetadata\xDAA\x11index,update_mask\x82\xD3\xE4\x93\x02H2?/v1/{index.name=projects/*/locations/*/collections/*/indexes/*}:\x05index\x12\xD5\x01\x0A\x0BDeleteIndex\x120.google.cloud.vectorsearch.v1.DeleteIndexRequest\x1A\x1D.google.longrunning.Operation\"u\xCAA*\x0A\x15google.protobuf.Empty\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x02;*9/v1/{name=projects/*/locations/*/collections/*/indexes/*}\x12\xF2\x01\x0A\x11ImportDataObjects\x126.google.cloud.vectorsearch.v1.ImportDataObjectsRequest\x1A\x1D.google.longrunning.Operation\"\x85\x01\xCAA6\x0A\x19ImportDataObjectsResponse\x12\x19ImportDataObjectsMetadata\x82\xD3\xE4\x93\x02F\"A/v1/{name=projects/*/locations/*/collections/*}:importDataObjects:\x01*\x12\xF2\x01\x0A\x11ExportDataObjects\x126.google.cloud.vectorsearch.v1.ExportDataObjectsRequest\x1A\x1D.google.longrunning.Operation\"\x85\x01\xCAA6\x0A\x19ExportDataObjectsResponse\x12\x19ExportDataObjectsMetadata\x82\xD3\xE4\x93\x02F\"A/v1/{name=projects/*/locations/*/collections/*}:exportDataObjects:\x01*\x1AO\xCAA\x1Bvectorsearch.googleapis.com\xD2A.https://www.googleapis.com/auth/cloud-platformB\xE4\x01\x0A com.google.cloud.vectorsearch.v1B\x18VectorSearchServiceProtoP\x01ZDcloud.google.com/go/vectorsearch/apiv1/vectorsearchpb;vectorsearchpb\xAA\x02\x1CGoogle.Cloud.VectorSearch.V1\xCA\x02\x1CGoogle\\Cloud\\VectorSearch\\V1\xEA\x02\x1FGoogle::Cloud::VectorSearch::V1b\x06proto3" - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/AggregateDataObjectsRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/AggregateDataObjectsRequest.php deleted file mode 100644 index d5b23e5eed71..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/AggregateDataObjectsRequest.php +++ /dev/null @@ -1,154 +0,0 @@ -google.cloud.vectorsearch.v1.AggregateDataObjectsRequest - */ -class AggregateDataObjectsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the Collection for which to query. - * Format: `projects/{project}/locations/{location}/collections/{collection}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Optional. A JSON filter expression, e.g. {"genre": {"$eq": "sci-fi"}}, - * represented as a google.protobuf.Struct. - * - * Generated from protobuf field .google.protobuf.Struct filter = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $filter = null; - /** - * Required. The aggregation method to apply to the query. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.AggregationMethod aggregate = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $aggregate = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The resource name of the Collection for which to query. - * Format: `projects/{project}/locations/{location}/collections/{collection}` - * @type \Google\Protobuf\Struct $filter - * Optional. A JSON filter expression, e.g. {"genre": {"$eq": "sci-fi"}}, - * represented as a google.protobuf.Struct. - * @type int $aggregate - * Required. The aggregation method to apply to the query. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectSearchService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the Collection for which to query. - * Format: `projects/{project}/locations/{location}/collections/{collection}` - * - * 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 Collection for which to query. - * Format: `projects/{project}/locations/{location}/collections/{collection}` - * - * 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. A JSON filter expression, e.g. {"genre": {"$eq": "sci-fi"}}, - * represented as a google.protobuf.Struct. - * - * Generated from protobuf field .google.protobuf.Struct filter = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Struct|null - */ - public function getFilter() - { - return $this->filter; - } - - public function hasFilter() - { - return isset($this->filter); - } - - public function clearFilter() - { - unset($this->filter); - } - - /** - * Optional. A JSON filter expression, e.g. {"genre": {"$eq": "sci-fi"}}, - * represented as a google.protobuf.Struct. - * - * Generated from protobuf field .google.protobuf.Struct filter = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Protobuf\Struct $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Struct::class); - $this->filter = $var; - - return $this; - } - - /** - * Required. The aggregation method to apply to the query. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.AggregationMethod aggregate = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getAggregate() - { - return $this->aggregate; - } - - /** - * Required. The aggregation method to apply to the query. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.AggregationMethod aggregate = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setAggregate($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\VectorSearch\V1\AggregationMethod::class); - $this->aggregate = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/AggregateDataObjectsResponse.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/AggregateDataObjectsResponse.php deleted file mode 100644 index 8ea65dd63840..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/AggregateDataObjectsResponse.php +++ /dev/null @@ -1,68 +0,0 @@ -google.cloud.vectorsearch.v1.AggregateDataObjectsResponse - */ -class AggregateDataObjectsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The aggregated results of the query. - * - * Generated from protobuf field repeated .google.protobuf.Struct aggregate_results = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - private $aggregate_results; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Protobuf\Struct[] $aggregate_results - * Output only. The aggregated results of the query. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectSearchService::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The aggregated results of the query. - * - * Generated from protobuf field repeated .google.protobuf.Struct aggregate_results = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return RepeatedField<\Google\Protobuf\Struct> - */ - public function getAggregateResults() - { - return $this->aggregate_results; - } - - /** - * Output only. The aggregated results of the query. - * - * Generated from protobuf field repeated .google.protobuf.Struct aggregate_results = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Struct[] $var - * @return $this - */ - public function setAggregateResults($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Protobuf\Struct::class); - $this->aggregate_results = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/AggregationMethod.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/AggregationMethod.php deleted file mode 100644 index fed256de20ce..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/AggregationMethod.php +++ /dev/null @@ -1,54 +0,0 @@ -google.cloud.vectorsearch.v1.AggregationMethod - */ -class AggregationMethod -{ - /** - * Should not be used. - * - * Generated from protobuf enum AGGREGATION_METHOD_UNSPECIFIED = 0; - */ - const AGGREGATION_METHOD_UNSPECIFIED = 0; - /** - * Count the number of data objects that match the filter. - * - * Generated from protobuf enum COUNT = 1; - */ - const COUNT = 1; - - private static $valueToName = [ - self::AGGREGATION_METHOD_UNSPECIFIED => 'AGGREGATION_METHOD_UNSPECIFIED', - self::COUNT => 'COUNT', - ]; - - 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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchCreateDataObjectsRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchCreateDataObjectsRequest.php deleted file mode 100644 index 7312e88d14d3..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchCreateDataObjectsRequest.php +++ /dev/null @@ -1,118 +0,0 @@ -google.cloud.vectorsearch.v1.BatchCreateDataObjectsRequest - */ -class BatchCreateDataObjectsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the Collection to create the DataObjects in. - * Format: `projects/{project}/locations/{location}/collections/{collection}`. - * The parent field in the CreateDataObjectRequest messages must match this - * field. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The request message specifying the resources to create. - * A maximum of 1000 DataObjects can be created in a batch. - * - * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.CreateDataObjectRequest requests = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - private $requests; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The resource name of the Collection to create the DataObjects in. - * Format: `projects/{project}/locations/{location}/collections/{collection}`. - * The parent field in the CreateDataObjectRequest messages must match this - * field. - * @type \Google\Cloud\VectorSearch\V1\CreateDataObjectRequest[] $requests - * Required. The request message specifying the resources to create. - * A maximum of 1000 DataObjects can be created in a batch. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the Collection to create the DataObjects in. - * Format: `projects/{project}/locations/{location}/collections/{collection}`. - * The parent field in the CreateDataObjectRequest messages must 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 resource name of the Collection to create the DataObjects in. - * Format: `projects/{project}/locations/{location}/collections/{collection}`. - * The parent field in the CreateDataObjectRequest messages must 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 message specifying the resources to create. - * A maximum of 1000 DataObjects can be created in a batch. - * - * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.CreateDataObjectRequest requests = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return RepeatedField<\Google\Cloud\VectorSearch\V1\CreateDataObjectRequest> - */ - public function getRequests() - { - return $this->requests; - } - - /** - * Required. The request message specifying the resources to create. - * A maximum of 1000 DataObjects can be created in a batch. - * - * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.CreateDataObjectRequest requests = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\VectorSearch\V1\CreateDataObjectRequest[] $var - * @return $this - */ - public function setRequests($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VectorSearch\V1\CreateDataObjectRequest::class); - $this->requests = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchCreateDataObjectsResponse.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchCreateDataObjectsResponse.php deleted file mode 100644 index 724830369569..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchCreateDataObjectsResponse.php +++ /dev/null @@ -1,68 +0,0 @@ -google.cloud.vectorsearch.v1.BatchCreateDataObjectsResponse - */ -class BatchCreateDataObjectsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. DataObjects created. - * - * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.DataObject data_objects = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - private $data_objects; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\VectorSearch\V1\DataObject[] $data_objects - * Output only. DataObjects created. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectService::initOnce(); - parent::__construct($data); - } - - /** - * Output only. DataObjects created. - * - * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.DataObject data_objects = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return RepeatedField<\Google\Cloud\VectorSearch\V1\DataObject> - */ - public function getDataObjects() - { - return $this->data_objects; - } - - /** - * Output only. DataObjects created. - * - * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.DataObject data_objects = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\VectorSearch\V1\DataObject[] $var - * @return $this - */ - public function setDataObjects($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VectorSearch\V1\DataObject::class); - $this->data_objects = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchDeleteDataObjectsRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchDeleteDataObjectsRequest.php deleted file mode 100644 index 0288323d7c76..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchDeleteDataObjectsRequest.php +++ /dev/null @@ -1,128 +0,0 @@ -google.cloud.vectorsearch.v1.BatchDeleteDataObjectsRequest - */ -class BatchDeleteDataObjectsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the Collection to delete the DataObjects in. - * Format: `projects/{project}/locations/{location}/collections/{collection}`. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The request message specifying the resources to delete. - * A maximum of 1000 DataObjects can be deleted in a batch. - * - * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.DeleteDataObjectRequest requests = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - private $requests; - - /** - * @param string $parent Required. The resource name of the Collection to delete the DataObjects in. - * Format: `projects/{project}/locations/{location}/collections/{collection}`. Please see - * {@see DataObjectServiceClient::collectionName()} for help formatting this field. - * @param \Google\Cloud\VectorSearch\V1\DeleteDataObjectRequest[] $requests Required. The request message specifying the resources to delete. - * A maximum of 1000 DataObjects can be deleted in a batch. - * - * @return \Google\Cloud\VectorSearch\V1\BatchDeleteDataObjectsRequest - * - * @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 resource name of the Collection to delete the DataObjects in. - * Format: `projects/{project}/locations/{location}/collections/{collection}`. - * @type \Google\Cloud\VectorSearch\V1\DeleteDataObjectRequest[] $requests - * Required. The request message specifying the resources to delete. - * A maximum of 1000 DataObjects can be deleted in a batch. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the Collection to delete the DataObjects in. - * Format: `projects/{project}/locations/{location}/collections/{collection}`. - * - * 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 Collection to delete the DataObjects in. - * Format: `projects/{project}/locations/{location}/collections/{collection}`. - * - * 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 message specifying the resources to delete. - * A maximum of 1000 DataObjects can be deleted in a batch. - * - * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.DeleteDataObjectRequest requests = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return RepeatedField<\Google\Cloud\VectorSearch\V1\DeleteDataObjectRequest> - */ - public function getRequests() - { - return $this->requests; - } - - /** - * Required. The request message specifying the resources to delete. - * A maximum of 1000 DataObjects can be deleted in a batch. - * - * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.DeleteDataObjectRequest requests = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\VectorSearch\V1\DeleteDataObjectRequest[] $var - * @return $this - */ - public function setRequests($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VectorSearch\V1\DeleteDataObjectRequest::class); - $this->requests = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchSearchDataObjectsRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchSearchDataObjectsRequest.php deleted file mode 100644 index e0a0b9bef1c4..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchSearchDataObjectsRequest.php +++ /dev/null @@ -1,149 +0,0 @@ -google.cloud.vectorsearch.v1.BatchSearchDataObjectsRequest - */ -class BatchSearchDataObjectsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the Collection for which to search. - * Format: `projects/{project}/locations/{location}/collections/{collection}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. A list of search requests to execute in parallel. - * - * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.Search searches = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - private $searches; - /** - * Optional. Options for combining the results of the batch search operations. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.BatchSearchDataObjectsRequest.CombineResultsOptions combine = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $combine = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The resource name of the Collection for which to search. - * Format: `projects/{project}/locations/{location}/collections/{collection}` - * @type \Google\Cloud\VectorSearch\V1\Search[] $searches - * Required. A list of search requests to execute in parallel. - * @type \Google\Cloud\VectorSearch\V1\BatchSearchDataObjectsRequest\CombineResultsOptions $combine - * Optional. Options for combining the results of the batch search operations. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectSearchService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the Collection for which to search. - * Format: `projects/{project}/locations/{location}/collections/{collection}` - * - * 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 Collection for which to search. - * Format: `projects/{project}/locations/{location}/collections/{collection}` - * - * 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 list of search requests to execute in parallel. - * - * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.Search searches = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return RepeatedField<\Google\Cloud\VectorSearch\V1\Search> - */ - public function getSearches() - { - return $this->searches; - } - - /** - * Required. A list of search requests to execute in parallel. - * - * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.Search searches = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\VectorSearch\V1\Search[] $var - * @return $this - */ - public function setSearches($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VectorSearch\V1\Search::class); - $this->searches = $arr; - - return $this; - } - - /** - * Optional. Options for combining the results of the batch search operations. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.BatchSearchDataObjectsRequest.CombineResultsOptions combine = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\VectorSearch\V1\BatchSearchDataObjectsRequest\CombineResultsOptions|null - */ - public function getCombine() - { - return $this->combine; - } - - public function hasCombine() - { - return isset($this->combine); - } - - public function clearCombine() - { - unset($this->combine); - } - - /** - * Optional. Options for combining the results of the batch search operations. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.BatchSearchDataObjectsRequest.CombineResultsOptions combine = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\VectorSearch\V1\BatchSearchDataObjectsRequest\CombineResultsOptions $var - * @return $this - */ - public function setCombine($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\BatchSearchDataObjectsRequest\CombineResultsOptions::class); - $this->combine = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchSearchDataObjectsRequest/CombineResultsOptions.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchSearchDataObjectsRequest/CombineResultsOptions.php deleted file mode 100644 index 35714245de22..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchSearchDataObjectsRequest/CombineResultsOptions.php +++ /dev/null @@ -1,159 +0,0 @@ -google.cloud.vectorsearch.v1.BatchSearchDataObjectsRequest.CombineResultsOptions - */ -class CombineResultsOptions extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The ranker to use for combining the results. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.Ranker ranker = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $ranker = null; - /** - * Optional. Mask specifying which fields to return. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.OutputFields output_fields = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $output_fields = null; - /** - * Optional. The number of results to return. If not set, a default value - * will be used. - * - * Generated from protobuf field int32 top_k = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $top_k = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\VectorSearch\V1\Ranker $ranker - * Required. The ranker to use for combining the results. - * @type \Google\Cloud\VectorSearch\V1\OutputFields $output_fields - * Optional. Mask specifying which fields to return. - * @type int $top_k - * Optional. The number of results to return. If not set, a default value - * will be used. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectSearchService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The ranker to use for combining the results. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.Ranker ranker = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\VectorSearch\V1\Ranker|null - */ - public function getRanker() - { - return $this->ranker; - } - - public function hasRanker() - { - return isset($this->ranker); - } - - public function clearRanker() - { - unset($this->ranker); - } - - /** - * Required. The ranker to use for combining the results. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.Ranker ranker = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\VectorSearch\V1\Ranker $var - * @return $this - */ - public function setRanker($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\Ranker::class); - $this->ranker = $var; - - return $this; - } - - /** - * Optional. Mask specifying which fields to return. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.OutputFields output_fields = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\VectorSearch\V1\OutputFields|null - */ - public function getOutputFields() - { - return $this->output_fields; - } - - public function hasOutputFields() - { - return isset($this->output_fields); - } - - public function clearOutputFields() - { - unset($this->output_fields); - } - - /** - * Optional. Mask specifying which fields to return. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.OutputFields output_fields = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\VectorSearch\V1\OutputFields $var - * @return $this - */ - public function setOutputFields($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\OutputFields::class); - $this->output_fields = $var; - - return $this; - } - - /** - * Optional. The number of results to return. If not set, a default value - * will be used. - * - * Generated from protobuf field int32 top_k = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getTopK() - { - return $this->top_k; - } - - /** - * Optional. The number of results to return. If not set, a default value - * will be used. - * - * Generated from protobuf field int32 top_k = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setTopK($var) - { - GPBUtil::checkInt32($var); - $this->top_k = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchSearchDataObjectsResponse.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchSearchDataObjectsResponse.php deleted file mode 100644 index d872d51f5956..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchSearchDataObjectsResponse.php +++ /dev/null @@ -1,71 +0,0 @@ -google.cloud.vectorsearch.v1.BatchSearchDataObjectsResponse - */ -class BatchSearchDataObjectsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. A list of search responses, one for each request in the batch. - * If a ranker is used, a single ranked list of results is returned. - * - * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.SearchDataObjectsResponse results = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - private $results; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\VectorSearch\V1\SearchDataObjectsResponse[] $results - * Output only. A list of search responses, one for each request in the batch. - * If a ranker is used, a single ranked list of results is returned. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectSearchService::initOnce(); - parent::__construct($data); - } - - /** - * Output only. A list of search responses, one for each request in the batch. - * If a ranker is used, a single ranked list of results is returned. - * - * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.SearchDataObjectsResponse results = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return RepeatedField<\Google\Cloud\VectorSearch\V1\SearchDataObjectsResponse> - */ - public function getResults() - { - return $this->results; - } - - /** - * Output only. A list of search responses, one for each request in the batch. - * If a ranker is used, a single ranked list of results is returned. - * - * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.SearchDataObjectsResponse results = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\VectorSearch\V1\SearchDataObjectsResponse[] $var - * @return $this - */ - public function setResults($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VectorSearch\V1\SearchDataObjectsResponse::class); - $this->results = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchUpdateDataObjectsRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchUpdateDataObjectsRequest.php deleted file mode 100644 index b2d8e7c61cea..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchUpdateDataObjectsRequest.php +++ /dev/null @@ -1,138 +0,0 @@ -google.cloud.vectorsearch.v1.BatchUpdateDataObjectsRequest - */ -class BatchUpdateDataObjectsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the Collection to update the DataObjects in. - * Format: `projects/{project}/locations/{location}/collections/{collection}`. - * The parent field in the UpdateDataObjectRequest messages must match this - * field. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The request message specifying the resources to update. - * A maximum of 1000 DataObjects can be updated in a batch. - * - * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.UpdateDataObjectRequest requests = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - private $requests; - - /** - * @param string $parent Required. The resource name of the Collection to update the DataObjects in. - * Format: `projects/{project}/locations/{location}/collections/{collection}`. - * The parent field in the UpdateDataObjectRequest messages must match this - * field. Please see - * {@see DataObjectServiceClient::collectionName()} for help formatting this field. - * @param \Google\Cloud\VectorSearch\V1\UpdateDataObjectRequest[] $requests Required. The request message specifying the resources to update. - * A maximum of 1000 DataObjects can be updated in a batch. - * - * @return \Google\Cloud\VectorSearch\V1\BatchUpdateDataObjectsRequest - * - * @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 resource name of the Collection to update the DataObjects in. - * Format: `projects/{project}/locations/{location}/collections/{collection}`. - * The parent field in the UpdateDataObjectRequest messages must match this - * field. - * @type \Google\Cloud\VectorSearch\V1\UpdateDataObjectRequest[] $requests - * Required. The request message specifying the resources to update. - * A maximum of 1000 DataObjects can be updated in a batch. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the Collection to update the DataObjects in. - * Format: `projects/{project}/locations/{location}/collections/{collection}`. - * The parent field in the UpdateDataObjectRequest messages must 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 resource name of the Collection to update the DataObjects in. - * Format: `projects/{project}/locations/{location}/collections/{collection}`. - * The parent field in the UpdateDataObjectRequest messages must 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 message specifying the resources to update. - * A maximum of 1000 DataObjects can be updated in a batch. - * - * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.UpdateDataObjectRequest requests = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return RepeatedField<\Google\Cloud\VectorSearch\V1\UpdateDataObjectRequest> - */ - public function getRequests() - { - return $this->requests; - } - - /** - * Required. The request message specifying the resources to update. - * A maximum of 1000 DataObjects can be updated in a batch. - * - * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.UpdateDataObjectRequest requests = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\VectorSearch\V1\UpdateDataObjectRequest[] $var - * @return $this - */ - public function setRequests($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VectorSearch\V1\UpdateDataObjectRequest::class); - $this->requests = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchUpdateDataObjectsResponse.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchUpdateDataObjectsResponse.php deleted file mode 100644 index dba807289c3b..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/BatchUpdateDataObjectsResponse.php +++ /dev/null @@ -1,34 +0,0 @@ -google.cloud.vectorsearch.v1.BatchUpdateDataObjectsResponse - */ -class BatchUpdateDataObjectsResponse extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectService::initOnce(); - parent::__construct($data); - } - -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/Collection.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/Collection.php deleted file mode 100644 index da1eeca2f43f..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/Collection.php +++ /dev/null @@ -1,411 +0,0 @@ -google.cloud.vectorsearch.v1.Collection - */ -class Collection extends \Google\Protobuf\Internal\Message -{ - /** - * Identifier. name of resource - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; - */ - protected $name = ''; - /** - * Optional. User-specified display name of the collection - * - * Generated from protobuf field string display_name = 8 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $display_name = ''; - /** - * Optional. User-specified description of the collection - * - * Generated from protobuf field string description = 9 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $description = ''; - /** - * 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. Labels as key value pairs. - * - * Generated from protobuf field map labels = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $labels; - /** - * Optional. Schema for vector fields. Only vector fields in this schema will - * be searchable. Field names must contain only alphanumeric characters, - * underscores, and hyphens. - * - * Generated from protobuf field map vector_schema = 7 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $vector_schema; - /** - * Optional. JSON Schema for data. - * Field names must contain only alphanumeric characters, - * underscores, and hyphens. - * The schema must be compliant with - * [JSON Schema Draft 7](https://json-schema.org/draft-07/schema). - * - * Generated from protobuf field .google.protobuf.Struct data_schema = 10 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $data_schema = null; - /** - * Optional. Immutable. Specifies the customer-managed encryption key spec for - * a Collection. If set, this Collection and all sub-resources of this - * Collection will be secured by this key. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.EncryptionSpec encryption_spec = 11 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; - */ - protected $encryption_spec = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Identifier. name of resource - * @type string $display_name - * Optional. User-specified display name of the collection - * @type string $description - * Optional. User-specified description of the collection - * @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 array|\Google\Protobuf\Internal\MapField $labels - * Optional. Labels as key value pairs. - * @type array|\Google\Protobuf\Internal\MapField $vector_schema - * Optional. Schema for vector fields. Only vector fields in this schema will - * be searchable. Field names must contain only alphanumeric characters, - * underscores, and hyphens. - * @type \Google\Protobuf\Struct $data_schema - * Optional. JSON Schema for data. - * Field names must contain only alphanumeric characters, - * underscores, and hyphens. - * The schema must be compliant with - * [JSON Schema Draft 7](https://json-schema.org/draft-07/schema). - * @type \Google\Cloud\VectorSearch\V1\EncryptionSpec $encryption_spec - * Optional. Immutable. Specifies the customer-managed encryption key spec for - * a Collection. If set, this Collection and all sub-resources of this - * Collection will be secured by this key. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\VectorsearchService::initOnce(); - parent::__construct($data); - } - - /** - * Identifier. name of resource - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Identifier. name of resource - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Optional. User-specified display name of the collection - * - * Generated from protobuf field string display_name = 8 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * Optional. User-specified display name of the collection - * - * Generated from protobuf field string display_name = 8 [(.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. User-specified description of the collection - * - * Generated from protobuf field string description = 9 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * Optional. User-specified description of the collection - * - * Generated from protobuf field string description = 9 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $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. Labels as key value pairs. - * - * Generated from protobuf field map labels = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Optional. Labels as key value pairs. - * - * 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. Schema for vector fields. Only vector fields in this schema will - * be searchable. Field names must contain only alphanumeric characters, - * underscores, and hyphens. - * - * Generated from protobuf field map vector_schema = 7 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\MapField - */ - public function getVectorSchema() - { - return $this->vector_schema; - } - - /** - * Optional. Schema for vector fields. Only vector fields in this schema will - * be searchable. Field names must contain only alphanumeric characters, - * underscores, and hyphens. - * - * Generated from protobuf field map vector_schema = 7 [(.google.api.field_behavior) = OPTIONAL]; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setVectorSchema($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VectorSearch\V1\VectorField::class); - $this->vector_schema = $arr; - - return $this; - } - - /** - * Optional. JSON Schema for data. - * Field names must contain only alphanumeric characters, - * underscores, and hyphens. - * The schema must be compliant with - * [JSON Schema Draft 7](https://json-schema.org/draft-07/schema). - * - * Generated from protobuf field .google.protobuf.Struct data_schema = 10 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Struct|null - */ - public function getDataSchema() - { - return $this->data_schema; - } - - public function hasDataSchema() - { - return isset($this->data_schema); - } - - public function clearDataSchema() - { - unset($this->data_schema); - } - - /** - * Optional. JSON Schema for data. - * Field names must contain only alphanumeric characters, - * underscores, and hyphens. - * The schema must be compliant with - * [JSON Schema Draft 7](https://json-schema.org/draft-07/schema). - * - * Generated from protobuf field .google.protobuf.Struct data_schema = 10 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Protobuf\Struct $var - * @return $this - */ - public function setDataSchema($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Struct::class); - $this->data_schema = $var; - - return $this; - } - - /** - * Optional. Immutable. Specifies the customer-managed encryption key spec for - * a Collection. If set, this Collection and all sub-resources of this - * Collection will be secured by this key. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.EncryptionSpec encryption_spec = 11 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\VectorSearch\V1\EncryptionSpec|null - */ - public function getEncryptionSpec() - { - return $this->encryption_spec; - } - - public function hasEncryptionSpec() - { - return isset($this->encryption_spec); - } - - public function clearEncryptionSpec() - { - unset($this->encryption_spec); - } - - /** - * Optional. Immutable. Specifies the customer-managed encryption key spec for - * a Collection. If set, this Collection and all sub-resources of this - * Collection will be secured by this key. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.EncryptionSpec encryption_spec = 11 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\VectorSearch\V1\EncryptionSpec $var - * @return $this - */ - public function setEncryptionSpec($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\EncryptionSpec::class); - $this->encryption_spec = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/CreateCollectionRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/CreateCollectionRequest.php deleted file mode 100644 index ad98dfd9a292..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/CreateCollectionRequest.php +++ /dev/null @@ -1,257 +0,0 @@ -google.cloud.vectorsearch.v1.CreateCollectionRequest - */ -class CreateCollectionRequest 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 = ''; - /** - * Required. ID of the Collection to create. - * The id must be 1-63 characters long, and comply with - * [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). - * Specifically, it must be 1-63 characters long and match the regular - * expression `[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?`. - * - * Generated from protobuf field string collection_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $collection_id = ''; - /** - * Required. The resource being created - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.Collection collection = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $collection = 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, (.google.api.field_info) = { - */ - protected $request_id = ''; - - /** - * @param string $parent Required. Value for parent. Please see - * {@see VectorSearchServiceClient::locationName()} for help formatting this field. - * @param \Google\Cloud\VectorSearch\V1\Collection $collection Required. The resource being created - * @param string $collectionId Required. ID of the Collection to create. - * The id must be 1-63 characters long, and comply with - * [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). - * Specifically, it must be 1-63 characters long and match the regular - * expression `[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?`. - * - * @return \Google\Cloud\VectorSearch\V1\CreateCollectionRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\VectorSearch\V1\Collection $collection, string $collectionId): self - { - return (new self()) - ->setParent($parent) - ->setCollection($collection) - ->setCollectionId($collectionId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. Value for parent. - * @type string $collection_id - * Required. ID of the Collection to create. - * The id must be 1-63 characters long, and comply with - * [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). - * Specifically, it must be 1-63 characters long and match the regular - * expression `[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?`. - * @type \Google\Cloud\VectorSearch\V1\Collection $collection - * 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 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\Vectorsearch\V1\VectorsearchService::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; - } - - /** - * Required. ID of the Collection to create. - * The id must be 1-63 characters long, and comply with - * [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). - * Specifically, it must be 1-63 characters long and match the regular - * expression `[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?`. - * - * Generated from protobuf field string collection_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getCollectionId() - { - return $this->collection_id; - } - - /** - * Required. ID of the Collection to create. - * The id must be 1-63 characters long, and comply with - * [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). - * Specifically, it must be 1-63 characters long and match the regular - * expression `[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?`. - * - * Generated from protobuf field string collection_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setCollectionId($var) - { - GPBUtil::checkString($var, True); - $this->collection_id = $var; - - return $this; - } - - /** - * Required. The resource being created - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.Collection collection = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\VectorSearch\V1\Collection|null - */ - public function getCollection() - { - return $this->collection; - } - - public function hasCollection() - { - return isset($this->collection); - } - - public function clearCollection() - { - unset($this->collection); - } - - /** - * Required. The resource being created - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.Collection collection = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\VectorSearch\V1\Collection $var - * @return $this - */ - public function setCollection($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\Collection::class); - $this->collection = $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, (.google.api.field_info) = { - * @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, (.google.api.field_info) = { - * @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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/CreateDataObjectRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/CreateDataObjectRequest.php deleted file mode 100644 index 48de8c4ab540..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/CreateDataObjectRequest.php +++ /dev/null @@ -1,189 +0,0 @@ -google.cloud.vectorsearch.v1.CreateDataObjectRequest - */ -class CreateDataObjectRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the Collection to create the DataObject in. - * Format: `projects/{project}/locations/{location}/collections/{collection}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The id of the dataObject to create. - * The id must be 1-63 characters long, and comply with - * [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). - * Specifically, it must be 1-63 characters long and match the regular - * expression `[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?`. - * - * Generated from protobuf field string data_object_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $data_object_id = ''; - /** - * Required. The DataObject to create. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.DataObject data_object = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $data_object = null; - - /** - * @param string $parent Required. The resource name of the Collection to create the DataObject in. - * Format: `projects/{project}/locations/{location}/collections/{collection}` - * Please see {@see DataObjectServiceClient::collectionName()} for help formatting this field. - * @param \Google\Cloud\VectorSearch\V1\DataObject $dataObject Required. The DataObject to create. - * @param string $dataObjectId Required. The id of the dataObject to create. - * The id must be 1-63 characters long, and comply with - * [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). - * Specifically, it must be 1-63 characters long and match the regular - * expression `[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?`. - * - * @return \Google\Cloud\VectorSearch\V1\CreateDataObjectRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\VectorSearch\V1\DataObject $dataObject, string $dataObjectId): self - { - return (new self()) - ->setParent($parent) - ->setDataObject($dataObject) - ->setDataObjectId($dataObjectId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The resource name of the Collection to create the DataObject in. - * Format: `projects/{project}/locations/{location}/collections/{collection}` - * @type string $data_object_id - * Required. The id of the dataObject to create. - * The id must be 1-63 characters long, and comply with - * [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). - * Specifically, it must be 1-63 characters long and match the regular - * expression `[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?`. - * @type \Google\Cloud\VectorSearch\V1\DataObject $data_object - * Required. The DataObject to create. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the Collection to create the DataObject in. - * Format: `projects/{project}/locations/{location}/collections/{collection}` - * - * 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 Collection to create the DataObject in. - * Format: `projects/{project}/locations/{location}/collections/{collection}` - * - * 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 dataObject to create. - * The id must be 1-63 characters long, and comply with - * [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). - * Specifically, it must be 1-63 characters long and match the regular - * expression `[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?`. - * - * Generated from protobuf field string data_object_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getDataObjectId() - { - return $this->data_object_id; - } - - /** - * Required. The id of the dataObject to create. - * The id must be 1-63 characters long, and comply with - * [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). - * Specifically, it must be 1-63 characters long and match the regular - * expression `[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?`. - * - * Generated from protobuf field string data_object_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setDataObjectId($var) - { - GPBUtil::checkString($var, True); - $this->data_object_id = $var; - - return $this; - } - - /** - * Required. The DataObject to create. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.DataObject data_object = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\VectorSearch\V1\DataObject|null - */ - public function getDataObject() - { - return $this->data_object; - } - - public function hasDataObject() - { - return isset($this->data_object); - } - - public function clearDataObject() - { - unset($this->data_object); - } - - /** - * Required. The DataObject to create. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.DataObject data_object = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\VectorSearch\V1\DataObject $var - * @return $this - */ - public function setDataObject($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\DataObject::class); - $this->data_object = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/CreateIndexRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/CreateIndexRequest.php deleted file mode 100644 index a97225541f3c..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/CreateIndexRequest.php +++ /dev/null @@ -1,267 +0,0 @@ -google.cloud.vectorsearch.v1.CreateIndexRequest - */ -class CreateIndexRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the Collection for which to create the - * Index. Format: - * `projects/{project}/locations/{location}/collections/{collection}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. ID of the Index to create. - * The id must be 1-63 characters long, and comply with - * [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). - * Specifically, it must be 1-63 characters long and match the regular - * expression `[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?`. - * - * Generated from protobuf field string index_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $index_id = ''; - /** - * Required. The resource being created - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.Index index = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $index = 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, (.google.api.field_info) = { - */ - protected $request_id = ''; - - /** - * @param string $parent Required. The resource name of the Collection for which to create the - * Index. Format: - * `projects/{project}/locations/{location}/collections/{collection}` - * Please see {@see VectorSearchServiceClient::collectionName()} for help formatting this field. - * @param \Google\Cloud\VectorSearch\V1\Index $index Required. The resource being created - * @param string $indexId Required. ID of the Index to create. - * The id must be 1-63 characters long, and comply with - * [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). - * Specifically, it must be 1-63 characters long and match the regular - * expression `[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?`. - * - * @return \Google\Cloud\VectorSearch\V1\CreateIndexRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\VectorSearch\V1\Index $index, string $indexId): self - { - return (new self()) - ->setParent($parent) - ->setIndex($index) - ->setIndexId($indexId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The resource name of the Collection for which to create the - * Index. Format: - * `projects/{project}/locations/{location}/collections/{collection}` - * @type string $index_id - * Required. ID of the Index to create. - * The id must be 1-63 characters long, and comply with - * [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). - * Specifically, it must be 1-63 characters long and match the regular - * expression `[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?`. - * @type \Google\Cloud\VectorSearch\V1\Index $index - * 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 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\Vectorsearch\V1\VectorsearchService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the Collection for which to create the - * Index. Format: - * `projects/{project}/locations/{location}/collections/{collection}` - * - * 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 Collection for which to create the - * Index. Format: - * `projects/{project}/locations/{location}/collections/{collection}` - * - * 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. ID of the Index to create. - * The id must be 1-63 characters long, and comply with - * [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). - * Specifically, it must be 1-63 characters long and match the regular - * expression `[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?`. - * - * Generated from protobuf field string index_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getIndexId() - { - return $this->index_id; - } - - /** - * Required. ID of the Index to create. - * The id must be 1-63 characters long, and comply with - * [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). - * Specifically, it must be 1-63 characters long and match the regular - * expression `[a-z](?:[-a-z0-9]{0,61}[a-z0-9])?`. - * - * Generated from protobuf field string index_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setIndexId($var) - { - GPBUtil::checkString($var, True); - $this->index_id = $var; - - return $this; - } - - /** - * Required. The resource being created - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.Index index = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\VectorSearch\V1\Index|null - */ - public function getIndex() - { - return $this->index; - } - - public function hasIndex() - { - return isset($this->index); - } - - public function clearIndex() - { - unset($this->index); - } - - /** - * Required. The resource being created - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.Index index = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\VectorSearch\V1\Index $var - * @return $this - */ - public function setIndex($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\Index::class); - $this->index = $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, (.google.api.field_info) = { - * @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, (.google.api.field_info) = { - * @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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DataObject.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DataObject.php deleted file mode 100644 index 2501187cbe74..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DataObject.php +++ /dev/null @@ -1,317 +0,0 @@ -google.cloud.vectorsearch.v1.DataObject - */ -class DataObject extends \Google\Protobuf\Internal\Message -{ - /** - * Identifier. The fully qualified resource name of the dataObject. - * Format: - * `projects/{project}/locations/{location}/collections/{collection}/dataObjects/{data_object_id}` - * The data_object_id must be 1-63 characters - * long, and comply with [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; - */ - protected $name = ''; - /** - * Output only. The id of the dataObject. - * - * Generated from protobuf field string data_object_id = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $data_object_id = ''; - /** - * Output only. Timestamp the dataObject was created at. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. Timestamp the dataObject was last updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Optional. The data of the dataObject. - * - * Generated from protobuf field .google.protobuf.Struct data = 6 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $data = null; - /** - * Optional. The vectors of the dataObject. - * - * Generated from protobuf field map vectors = 7 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $vectors; - /** - * Optional. The etag of the dataObject. - * - * Generated from protobuf field string etag = 8 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $etag = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Identifier. The fully qualified resource name of the dataObject. - * Format: - * `projects/{project}/locations/{location}/collections/{collection}/dataObjects/{data_object_id}` - * The data_object_id must be 1-63 characters - * long, and comply with [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). - * @type string $data_object_id - * Output only. The id of the dataObject. - * @type \Google\Protobuf\Timestamp $create_time - * Output only. Timestamp the dataObject was created at. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. Timestamp the dataObject was last updated. - * @type \Google\Protobuf\Struct $data - * Optional. The data of the dataObject. - * @type array|\Google\Protobuf\Internal\MapField $vectors - * Optional. The vectors of the dataObject. - * @type string $etag - * Optional. The etag of the dataObject. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObject::initOnce(); - parent::__construct($data); - } - - /** - * Identifier. The fully qualified resource name of the dataObject. - * Format: - * `projects/{project}/locations/{location}/collections/{collection}/dataObjects/{data_object_id}` - * The data_object_id must be 1-63 characters - * long, and comply with [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Identifier. The fully qualified resource name of the dataObject. - * Format: - * `projects/{project}/locations/{location}/collections/{collection}/dataObjects/{data_object_id}` - * The data_object_id must be 1-63 characters - * long, and comply with [RFC1035](https://www.ietf.org/rfc/rfc1035.txt). - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Output only. The id of the dataObject. - * - * Generated from protobuf field string data_object_id = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getDataObjectId() - { - return $this->data_object_id; - } - - /** - * Output only. The id of the dataObject. - * - * Generated from protobuf field string data_object_id = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setDataObjectId($var) - { - GPBUtil::checkString($var, True); - $this->data_object_id = $var; - - return $this; - } - - /** - * Output only. Timestamp the dataObject was created at. - * - * 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. Timestamp the dataObject was created at. - * - * 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. Timestamp the dataObject was last 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. Timestamp the dataObject was last 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; - } - - /** - * Optional. The data of the dataObject. - * - * Generated from protobuf field .google.protobuf.Struct data = 6 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Struct|null - */ - public function getData() - { - return $this->data; - } - - public function hasData() - { - return isset($this->data); - } - - public function clearData() - { - unset($this->data); - } - - /** - * Optional. The data of the dataObject. - * - * Generated from protobuf field .google.protobuf.Struct data = 6 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Protobuf\Struct $var - * @return $this - */ - public function setData($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Struct::class); - $this->data = $var; - - return $this; - } - - /** - * Optional. The vectors of the dataObject. - * - * Generated from protobuf field map vectors = 7 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\MapField - */ - public function getVectors() - { - return $this->vectors; - } - - /** - * Optional. The vectors of the dataObject. - * - * Generated from protobuf field map vectors = 7 [(.google.api.field_behavior) = OPTIONAL]; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setVectors($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VectorSearch\V1\Vector::class); - $this->vectors = $arr; - - return $this; - } - - /** - * Optional. The etag of the dataObject. - * - * Generated from protobuf field string etag = 8 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getEtag() - { - return $this->etag; - } - - /** - * Optional. The etag of the dataObject. - * - * Generated from protobuf field string etag = 8 [(.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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DedicatedInfrastructure.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DedicatedInfrastructure.php deleted file mode 100644 index 30eb1135250f..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DedicatedInfrastructure.php +++ /dev/null @@ -1,121 +0,0 @@ -google.cloud.vectorsearch.v1.DedicatedInfrastructure - */ -class DedicatedInfrastructure extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. Mode of the dedicated infrastructure. - * - * Generated from protobuf field optional .google.cloud.vectorsearch.v1.DedicatedInfrastructure.Mode mode = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $mode = null; - /** - * Optional. Autoscaling specification. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.DedicatedInfrastructure.AutoscalingSpec autoscaling_spec = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $autoscaling_spec = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $mode - * Optional. Mode of the dedicated infrastructure. - * @type \Google\Cloud\VectorSearch\V1\DedicatedInfrastructure\AutoscalingSpec $autoscaling_spec - * Optional. Autoscaling specification. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\VectorsearchService::initOnce(); - parent::__construct($data); - } - - /** - * Optional. Mode of the dedicated infrastructure. - * - * Generated from protobuf field optional .google.cloud.vectorsearch.v1.DedicatedInfrastructure.Mode mode = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getMode() - { - return isset($this->mode) ? $this->mode : 0; - } - - public function hasMode() - { - return isset($this->mode); - } - - public function clearMode() - { - unset($this->mode); - } - - /** - * Optional. Mode of the dedicated infrastructure. - * - * Generated from protobuf field optional .google.cloud.vectorsearch.v1.DedicatedInfrastructure.Mode mode = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setMode($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\VectorSearch\V1\DedicatedInfrastructure\Mode::class); - $this->mode = $var; - - return $this; - } - - /** - * Optional. Autoscaling specification. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.DedicatedInfrastructure.AutoscalingSpec autoscaling_spec = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\VectorSearch\V1\DedicatedInfrastructure\AutoscalingSpec|null - */ - public function getAutoscalingSpec() - { - return $this->autoscaling_spec; - } - - public function hasAutoscalingSpec() - { - return isset($this->autoscaling_spec); - } - - public function clearAutoscalingSpec() - { - unset($this->autoscaling_spec); - } - - /** - * Optional. Autoscaling specification. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.DedicatedInfrastructure.AutoscalingSpec autoscaling_spec = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\VectorSearch\V1\DedicatedInfrastructure\AutoscalingSpec $var - * @return $this - */ - public function setAutoscalingSpec($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\DedicatedInfrastructure\AutoscalingSpec::class); - $this->autoscaling_spec = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DedicatedInfrastructure/AutoscalingSpec.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DedicatedInfrastructure/AutoscalingSpec.php deleted file mode 100644 index 7435105a9140..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DedicatedInfrastructure/AutoscalingSpec.php +++ /dev/null @@ -1,125 +0,0 @@ -google.cloud.vectorsearch.v1.DedicatedInfrastructure.AutoscalingSpec - */ -class AutoscalingSpec extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. The minimum number of replicas. If not set or set to `0`, - * defaults to `2`. Must be >= `1` and <= `1000`. - * - * Generated from protobuf field int32 min_replica_count = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $min_replica_count = 0; - /** - * Optional. The maximum number of replicas. Must be >= - * `min_replica_count` and <= `1000`. - * For the v1beta version, if not set or set to `0`, defaults to - * the greater of `min_replica_count` and `5`. - * For all other versions, if not set or set to `0`, defaults to - * the greater of `min_replica_count` and `2`. - * - * Generated from protobuf field int32 max_replica_count = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $max_replica_count = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $min_replica_count - * Optional. The minimum number of replicas. If not set or set to `0`, - * defaults to `2`. Must be >= `1` and <= `1000`. - * @type int $max_replica_count - * Optional. The maximum number of replicas. Must be >= - * `min_replica_count` and <= `1000`. - * For the v1beta version, if not set or set to `0`, defaults to - * the greater of `min_replica_count` and `5`. - * For all other versions, if not set or set to `0`, defaults to - * the greater of `min_replica_count` and `2`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\VectorsearchService::initOnce(); - parent::__construct($data); - } - - /** - * Optional. The minimum number of replicas. If not set or set to `0`, - * defaults to `2`. Must be >= `1` and <= `1000`. - * - * Generated from protobuf field int32 min_replica_count = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getMinReplicaCount() - { - return $this->min_replica_count; - } - - /** - * Optional. The minimum number of replicas. If not set or set to `0`, - * defaults to `2`. Must be >= `1` and <= `1000`. - * - * Generated from protobuf field int32 min_replica_count = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setMinReplicaCount($var) - { - GPBUtil::checkInt32($var); - $this->min_replica_count = $var; - - return $this; - } - - /** - * Optional. The maximum number of replicas. Must be >= - * `min_replica_count` and <= `1000`. - * For the v1beta version, if not set or set to `0`, defaults to - * the greater of `min_replica_count` and `5`. - * For all other versions, if not set or set to `0`, defaults to - * the greater of `min_replica_count` and `2`. - * - * Generated from protobuf field int32 max_replica_count = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getMaxReplicaCount() - { - return $this->max_replica_count; - } - - /** - * Optional. The maximum number of replicas. Must be >= - * `min_replica_count` and <= `1000`. - * For the v1beta version, if not set or set to `0`, defaults to - * the greater of `min_replica_count` and `5`. - * For all other versions, if not set or set to `0`, defaults to - * the greater of `min_replica_count` and `2`. - * - * Generated from protobuf field int32 max_replica_count = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setMaxReplicaCount($var) - { - GPBUtil::checkInt32($var); - $this->max_replica_count = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DedicatedInfrastructure/Mode.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DedicatedInfrastructure/Mode.php deleted file mode 100644 index 2a01db202e2d..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DedicatedInfrastructure/Mode.php +++ /dev/null @@ -1,61 +0,0 @@ -google.cloud.vectorsearch.v1.DedicatedInfrastructure.Mode - */ -class Mode -{ - /** - * Default will use `PERFORMANCE_OPTIMIZED`. - * - * Generated from protobuf enum MODE_UNSPECIFIED = 0; - */ - const MODE_UNSPECIFIED = 0; - /** - * This is storage optimized variation. - * - * Generated from protobuf enum STORAGE_OPTIMIZED = 1; - */ - const STORAGE_OPTIMIZED = 1; - /** - * This is Performance optimized on E2 or equivalent family. - * - * Generated from protobuf enum PERFORMANCE_OPTIMIZED = 2; - */ - const PERFORMANCE_OPTIMIZED = 2; - - private static $valueToName = [ - self::MODE_UNSPECIFIED => 'MODE_UNSPECIFIED', - self::STORAGE_OPTIMIZED => 'STORAGE_OPTIMIZED', - self::PERFORMANCE_OPTIMIZED => 'PERFORMANCE_OPTIMIZED', - ]; - - 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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DeleteCollectionRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DeleteCollectionRequest.php deleted file mode 100644 index a15a54e937b2..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DeleteCollectionRequest.php +++ /dev/null @@ -1,155 +0,0 @@ -google.cloud.vectorsearch.v1.DeleteCollectionRequest - */ -class DeleteCollectionRequest 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 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { - */ - protected $request_id = ''; - - /** - * @param string $name Required. Name of the resource - * Please see {@see VectorSearchServiceClient::collectionName()} for help formatting this field. - * - * @return \Google\Cloud\VectorSearch\V1\DeleteCollectionRequest - * - * @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 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\Vectorsearch\V1\VectorsearchService::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 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { - * @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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { - * @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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DeleteDataObjectRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DeleteDataObjectRequest.php deleted file mode 100644 index 7b02cd1fe558..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DeleteDataObjectRequest.php +++ /dev/null @@ -1,134 +0,0 @@ -google.cloud.vectorsearch.v1.DeleteDataObjectRequest - */ -class DeleteDataObjectRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the DataObject resource to be deleted. - * Format: - * `projects/{project}/locations/{location}/collections/{collection}/dataObjects/{dataObject}` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Optional. The current etag of the DataObject. - * If an etag is provided and does not match the current etag of the - * DataObject, deletion will be blocked and an ABORTED error will be returned. - * - * Generated from protobuf field string etag = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $etag = ''; - - /** - * @param string $name Required. The name of the DataObject resource to be deleted. - * Format: - * `projects/{project}/locations/{location}/collections/{collection}/dataObjects/{dataObject}` - * Please see {@see DataObjectServiceClient::dataObjectName()} for help formatting this field. - * - * @return \Google\Cloud\VectorSearch\V1\DeleteDataObjectRequest - * - * @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 DataObject resource to be deleted. - * Format: - * `projects/{project}/locations/{location}/collections/{collection}/dataObjects/{dataObject}` - * @type string $etag - * Optional. The current etag of the DataObject. - * If an etag is provided and does not match the current etag of the - * DataObject, deletion will be blocked and an ABORTED error will be returned. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the DataObject resource to be deleted. - * Format: - * `projects/{project}/locations/{location}/collections/{collection}/dataObjects/{dataObject}` - * - * 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 DataObject resource to be deleted. - * Format: - * `projects/{project}/locations/{location}/collections/{collection}/dataObjects/{dataObject}` - * - * 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 current etag of the DataObject. - * If an etag is provided and does not match the current etag of the - * DataObject, deletion will be blocked and an ABORTED error will be returned. - * - * Generated from protobuf field string etag = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getEtag() - { - return $this->etag; - } - - /** - * Optional. The current etag of the DataObject. - * If an etag is provided and does not match the current etag of the - * DataObject, deletion will be blocked and an ABORTED error will be returned. - * - * 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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DeleteIndexRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DeleteIndexRequest.php deleted file mode 100644 index 312854bce6d7..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DeleteIndexRequest.php +++ /dev/null @@ -1,165 +0,0 @@ -google.cloud.vectorsearch.v1.DeleteIndexRequest - */ -class DeleteIndexRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the Index to delete. - * Format: - * `projects/{project}/locations/{location}/collections/{collection}/indexes/{index}` - * - * 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 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { - */ - protected $request_id = ''; - - /** - * @param string $name Required. The resource name of the Index to delete. - * Format: - * `projects/{project}/locations/{location}/collections/{collection}/indexes/{index}` - * Please see {@see VectorSearchServiceClient::indexName()} for help formatting this field. - * - * @return \Google\Cloud\VectorSearch\V1\DeleteIndexRequest - * - * @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 Index to delete. - * Format: - * `projects/{project}/locations/{location}/collections/{collection}/indexes/{index}` - * @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\Vectorsearch\V1\VectorsearchService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the Index to delete. - * Format: - * `projects/{project}/locations/{location}/collections/{collection}/indexes/{index}` - * - * 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 Index to delete. - * Format: - * `projects/{project}/locations/{location}/collections/{collection}/indexes/{index}` - * - * 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 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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { - * @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 = 2 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { - * @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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DenseScannIndex.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DenseScannIndex.php deleted file mode 100644 index 597ff9a9b6ac..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DenseScannIndex.php +++ /dev/null @@ -1,67 +0,0 @@ -google.cloud.vectorsearch.v1.DenseScannIndex - */ -class DenseScannIndex extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. Feature norm type. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.DenseScannIndex.FeatureNormType feature_norm_type = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $feature_norm_type = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $feature_norm_type - * Optional. Feature norm type. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\VectorsearchService::initOnce(); - parent::__construct($data); - } - - /** - * Optional. Feature norm type. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.DenseScannIndex.FeatureNormType feature_norm_type = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getFeatureNormType() - { - return $this->feature_norm_type; - } - - /** - * Optional. Feature norm type. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.DenseScannIndex.FeatureNormType feature_norm_type = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setFeatureNormType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\VectorSearch\V1\DenseScannIndex\FeatureNormType::class); - $this->feature_norm_type = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DenseScannIndex/FeatureNormType.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DenseScannIndex/FeatureNormType.php deleted file mode 100644 index fb2ac5c5d670..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DenseScannIndex/FeatureNormType.php +++ /dev/null @@ -1,61 +0,0 @@ -google.cloud.vectorsearch.v1.DenseScannIndex.FeatureNormType - */ -class FeatureNormType -{ - /** - * Unspecified feature norm type. - * - * Generated from protobuf enum FEATURE_NORM_TYPE_UNSPECIFIED = 0; - */ - const FEATURE_NORM_TYPE_UNSPECIFIED = 0; - /** - * No norm applied. - * - * Generated from protobuf enum NONE = 1; - */ - const NONE = 1; - /** - * Unit L2 norm. - * - * Generated from protobuf enum UNIT_L2_NORM = 2; - */ - const UNIT_L2_NORM = 2; - - private static $valueToName = [ - self::FEATURE_NORM_TYPE_UNSPECIFIED => 'FEATURE_NORM_TYPE_UNSPECIFIED', - self::NONE => 'NONE', - self::UNIT_L2_NORM => 'UNIT_L2_NORM', - ]; - - 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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DenseVector.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DenseVector.php deleted file mode 100644 index c3e81f1d2b3a..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DenseVector.php +++ /dev/null @@ -1,67 +0,0 @@ -google.cloud.vectorsearch.v1.DenseVector - */ -class DenseVector extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The values of the vector. - * - * Generated from protobuf field repeated float values = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - private $values; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type float[] $values - * Required. The values of the vector. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObject::initOnce(); - parent::__construct($data); - } - - /** - * Required. The values of the vector. - * - * Generated from protobuf field repeated float values = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return RepeatedField - */ - public function getValues() - { - return $this->values; - } - - /** - * Required. The values of the vector. - * - * Generated from protobuf field repeated float values = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param float[] $var - * @return $this - */ - public function setValues($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::FLOAT); - $this->values = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DenseVectorField.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DenseVectorField.php deleted file mode 100644 index bb67c3ad25a6..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DenseVectorField.php +++ /dev/null @@ -1,115 +0,0 @@ -google.cloud.vectorsearch.v1.DenseVectorField - */ -class DenseVectorField extends \Google\Protobuf\Internal\Message -{ - /** - * Dimensionality of the vector field. - * - * Generated from protobuf field int32 dimensions = 1; - */ - protected $dimensions = 0; - /** - * Optional. Configuration for generating embeddings for the vector field. If - * not specified, the embedding field must be populated in the DataObject. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.VertexEmbeddingConfig vertex_embedding_config = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $vertex_embedding_config = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $dimensions - * Dimensionality of the vector field. - * @type \Google\Cloud\VectorSearch\V1\VertexEmbeddingConfig $vertex_embedding_config - * Optional. Configuration for generating embeddings for the vector field. If - * not specified, the embedding field must be populated in the DataObject. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\VectorsearchService::initOnce(); - parent::__construct($data); - } - - /** - * Dimensionality of the vector field. - * - * Generated from protobuf field int32 dimensions = 1; - * @return int - */ - public function getDimensions() - { - return $this->dimensions; - } - - /** - * Dimensionality of the vector field. - * - * Generated from protobuf field int32 dimensions = 1; - * @param int $var - * @return $this - */ - public function setDimensions($var) - { - GPBUtil::checkInt32($var); - $this->dimensions = $var; - - return $this; - } - - /** - * Optional. Configuration for generating embeddings for the vector field. If - * not specified, the embedding field must be populated in the DataObject. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.VertexEmbeddingConfig vertex_embedding_config = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\VectorSearch\V1\VertexEmbeddingConfig|null - */ - public function getVertexEmbeddingConfig() - { - return $this->vertex_embedding_config; - } - - public function hasVertexEmbeddingConfig() - { - return isset($this->vertex_embedding_config); - } - - public function clearVertexEmbeddingConfig() - { - unset($this->vertex_embedding_config); - } - - /** - * Optional. Configuration for generating embeddings for the vector field. If - * not specified, the embedding field must be populated in the DataObject. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.VertexEmbeddingConfig vertex_embedding_config = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\VectorSearch\V1\VertexEmbeddingConfig $var - * @return $this - */ - public function setVertexEmbeddingConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\VertexEmbeddingConfig::class); - $this->vertex_embedding_config = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DistanceMetric.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DistanceMetric.php deleted file mode 100644 index e9956ad6fe10..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/DistanceMetric.php +++ /dev/null @@ -1,61 +0,0 @@ -google.cloud.vectorsearch.v1.DistanceMetric - */ -class DistanceMetric -{ - /** - * Default value, distance metric is not specified. - * - * Generated from protobuf enum DISTANCE_METRIC_UNSPECIFIED = 0; - */ - const DISTANCE_METRIC_UNSPECIFIED = 0; - /** - * Dot product distance metric. - * - * Generated from protobuf enum DOT_PRODUCT = 1; - */ - const DOT_PRODUCT = 1; - /** - * Cosine distance metric. - * - * Generated from protobuf enum COSINE_DISTANCE = 2; - */ - const COSINE_DISTANCE = 2; - - private static $valueToName = [ - self::DISTANCE_METRIC_UNSPECIFIED => 'DISTANCE_METRIC_UNSPECIFIED', - self::DOT_PRODUCT => 'DOT_PRODUCT', - self::COSINE_DISTANCE => 'COSINE_DISTANCE', - ]; - - 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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/EmbeddingTaskType.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/EmbeddingTaskType.php deleted file mode 100644 index 36e86bca6e50..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/EmbeddingTaskType.php +++ /dev/null @@ -1,103 +0,0 @@ -google.cloud.vectorsearch.v1.EmbeddingTaskType - */ -class EmbeddingTaskType -{ - /** - * Unspecified task type. - * - * Generated from protobuf enum EMBEDDING_TASK_TYPE_UNSPECIFIED = 0; - */ - const EMBEDDING_TASK_TYPE_UNSPECIFIED = 0; - /** - * Specifies the given text is a query in a search/retrieval setting. - * - * Generated from protobuf enum RETRIEVAL_QUERY = 1; - */ - const RETRIEVAL_QUERY = 1; - /** - * Specifies the given text is a document from the corpus being searched. - * - * Generated from protobuf enum RETRIEVAL_DOCUMENT = 2; - */ - const RETRIEVAL_DOCUMENT = 2; - /** - * Specifies the given text will be used for STS. - * - * Generated from protobuf enum SEMANTIC_SIMILARITY = 3; - */ - const SEMANTIC_SIMILARITY = 3; - /** - * Specifies that the given text will be classified. - * - * Generated from protobuf enum CLASSIFICATION = 4; - */ - const CLASSIFICATION = 4; - /** - * Specifies that the embeddings will be used for clustering. - * - * Generated from protobuf enum CLUSTERING = 5; - */ - const CLUSTERING = 5; - /** - * Specifies that the embeddings will be used for question answering. - * - * Generated from protobuf enum QUESTION_ANSWERING = 6; - */ - const QUESTION_ANSWERING = 6; - /** - * Specifies that the embeddings will be used for fact verification. - * - * Generated from protobuf enum FACT_VERIFICATION = 7; - */ - const FACT_VERIFICATION = 7; - /** - * Specifies that the embeddings will be used for code retrieval. - * - * Generated from protobuf enum CODE_RETRIEVAL_QUERY = 8; - */ - const CODE_RETRIEVAL_QUERY = 8; - - private static $valueToName = [ - self::EMBEDDING_TASK_TYPE_UNSPECIFIED => 'EMBEDDING_TASK_TYPE_UNSPECIFIED', - self::RETRIEVAL_QUERY => 'RETRIEVAL_QUERY', - self::RETRIEVAL_DOCUMENT => 'RETRIEVAL_DOCUMENT', - self::SEMANTIC_SIMILARITY => 'SEMANTIC_SIMILARITY', - self::CLASSIFICATION => 'CLASSIFICATION', - self::CLUSTERING => 'CLUSTERING', - self::QUESTION_ANSWERING => 'QUESTION_ANSWERING', - self::FACT_VERIFICATION => 'FACT_VERIFICATION', - self::CODE_RETRIEVAL_QUERY => 'CODE_RETRIEVAL_QUERY', - ]; - - 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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/EncryptionSpec.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/EncryptionSpec.php deleted file mode 100644 index 82c9f1b9b187..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/EncryptionSpec.php +++ /dev/null @@ -1,80 +0,0 @@ -google.cloud.vectorsearch.v1.EncryptionSpec - */ -class EncryptionSpec extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Resource name of the Cloud KMS key used to protect the resource. - * The Cloud KMS key must be in the same region as the resource. It must have - * the format - * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. - * - * Generated from protobuf field string crypto_key_name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $crypto_key_name = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $crypto_key_name - * Required. Resource name of the Cloud KMS key used to protect the resource. - * The Cloud KMS key must be in the same region as the resource. It must have - * the format - * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\EncryptionSpec::initOnce(); - parent::__construct($data); - } - - /** - * Required. Resource name of the Cloud KMS key used to protect the resource. - * The Cloud KMS key must be in the same region as the resource. It must have - * the format - * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. - * - * Generated from protobuf field string crypto_key_name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getCryptoKeyName() - { - return $this->crypto_key_name; - } - - /** - * Required. Resource name of the Cloud KMS key used to protect the resource. - * The Cloud KMS key must be in the same region as the resource. It must have - * the format - * `projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}`. - * - * Generated from protobuf field string crypto_key_name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setCryptoKeyName($var) - { - GPBUtil::checkString($var, True); - $this->crypto_key_name = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ExportDataObjectsMetadata.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ExportDataObjectsMetadata.php deleted file mode 100644 index 891402eb6a5a..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ExportDataObjectsMetadata.php +++ /dev/null @@ -1,121 +0,0 @@ -google.cloud.vectorsearch.v1.ExportDataObjectsMetadata - */ -class ExportDataObjectsMetadata 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. - * - * Generated from protobuf field .google.protobuf.Timestamp finish_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $finish_time = null; - - /** - * 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 $finish_time - * Output only. The time the operation finished. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\VectorsearchService::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. - * - * Generated from protobuf field .google.protobuf.Timestamp finish_time = 2 [(.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. The time the operation finished. - * - * Generated from protobuf field .google.protobuf.Timestamp finish_time = 2 [(.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; - } - -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ExportDataObjectsRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ExportDataObjectsRequest.php deleted file mode 100644 index 707456e9a116..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ExportDataObjectsRequest.php +++ /dev/null @@ -1,118 +0,0 @@ -google.cloud.vectorsearch.v1.ExportDataObjectsRequest - */ -class ExportDataObjectsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the Collection from which we want to export - * Data Objects. Format: - * `projects/{project}/locations/{location}/collections/{collection}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - protected $destination; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\VectorSearch\V1\ExportDataObjectsRequest\GcsExportDestination $gcs_destination - * The Cloud Storage location where user wants to export Data Objects. - * @type string $name - * Required. The resource name of the Collection from which we want to export - * Data Objects. Format: - * `projects/{project}/locations/{location}/collections/{collection}`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\VectorsearchService::initOnce(); - parent::__construct($data); - } - - /** - * The Cloud Storage location where user wants to export Data Objects. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.ExportDataObjectsRequest.GcsExportDestination gcs_destination = 2; - * @return \Google\Cloud\VectorSearch\V1\ExportDataObjectsRequest\GcsExportDestination|null - */ - public function getGcsDestination() - { - return $this->readOneof(2); - } - - public function hasGcsDestination() - { - return $this->hasOneof(2); - } - - /** - * The Cloud Storage location where user wants to export Data Objects. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.ExportDataObjectsRequest.GcsExportDestination gcs_destination = 2; - * @param \Google\Cloud\VectorSearch\V1\ExportDataObjectsRequest\GcsExportDestination $var - * @return $this - */ - public function setGcsDestination($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\ExportDataObjectsRequest\GcsExportDestination::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * Required. The resource name of the Collection from which we want to export - * Data Objects. Format: - * `projects/{project}/locations/{location}/collections/{collection}`. - * - * 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 Collection from which we want to export - * Data Objects. Format: - * `projects/{project}/locations/{location}/collections/{collection}`. - * - * 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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ExportDataObjectsRequest/GcsExportDestination.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ExportDataObjectsRequest/GcsExportDestination.php deleted file mode 100644 index 64fa188a3160..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ExportDataObjectsRequest/GcsExportDestination.php +++ /dev/null @@ -1,105 +0,0 @@ -google.cloud.vectorsearch.v1.ExportDataObjectsRequest.GcsExportDestination - */ -class GcsExportDestination extends \Google\Protobuf\Internal\Message -{ - /** - * Required. URI prefix of the Cloud Storage where to export Data Objects. - * The bucket is required to be in the same region as the collection. - * - * Generated from protobuf field string export_uri = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $export_uri = ''; - /** - * Required. The format of the exported Data Objects. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.ExportDataObjectsRequest.GcsExportDestination.Format format = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $format = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $export_uri - * Required. URI prefix of the Cloud Storage where to export Data Objects. - * The bucket is required to be in the same region as the collection. - * @type int $format - * Required. The format of the exported Data Objects. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\VectorsearchService::initOnce(); - parent::__construct($data); - } - - /** - * Required. URI prefix of the Cloud Storage where to export Data Objects. - * The bucket is required to be in the same region as the collection. - * - * Generated from protobuf field string export_uri = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getExportUri() - { - return $this->export_uri; - } - - /** - * Required. URI prefix of the Cloud Storage where to export Data Objects. - * The bucket is required to be in the same region as the collection. - * - * Generated from protobuf field string export_uri = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setExportUri($var) - { - GPBUtil::checkString($var, True); - $this->export_uri = $var; - - return $this; - } - - /** - * Required. The format of the exported Data Objects. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.ExportDataObjectsRequest.GcsExportDestination.Format format = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getFormat() - { - return $this->format; - } - - /** - * Required. The format of the exported Data Objects. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.ExportDataObjectsRequest.GcsExportDestination.Format format = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setFormat($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\VectorSearch\V1\ExportDataObjectsRequest\GcsExportDestination\Format::class); - $this->format = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ExportDataObjectsRequest/GcsExportDestination/Format.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ExportDataObjectsRequest/GcsExportDestination/Format.php deleted file mode 100644 index 18b8f8a0fad6..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ExportDataObjectsRequest/GcsExportDestination/Format.php +++ /dev/null @@ -1,54 +0,0 @@ -google.cloud.vectorsearch.v1.ExportDataObjectsRequest.GcsExportDestination.Format - */ -class Format -{ - /** - * Unspecified format. - * - * Generated from protobuf enum FORMAT_UNSPECIFIED = 0; - */ - const FORMAT_UNSPECIFIED = 0; - /** - * Exports Data Objects in `JSONL` format. - * - * Generated from protobuf enum JSONL = 2; - */ - const JSONL = 2; - - private static $valueToName = [ - self::FORMAT_UNSPECIFIED => 'FORMAT_UNSPECIFIED', - self::JSONL => 'JSONL', - ]; - - 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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ExportDataObjectsResponse.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ExportDataObjectsResponse.php deleted file mode 100644 index bc89240cfc6a..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ExportDataObjectsResponse.php +++ /dev/null @@ -1,33 +0,0 @@ -google.cloud.vectorsearch.v1.ExportDataObjectsResponse - */ -class ExportDataObjectsResponse extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\VectorsearchService::initOnce(); - parent::__construct($data); - } - -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/GetCollectionRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/GetCollectionRequest.php deleted file mode 100644 index 19bffcd2399c..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/GetCollectionRequest.php +++ /dev/null @@ -1,81 +0,0 @@ -google.cloud.vectorsearch.v1.GetCollectionRequest - */ -class GetCollectionRequest 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 VectorSearchServiceClient::collectionName()} for help formatting this field. - * - * @return \Google\Cloud\VectorSearch\V1\GetCollectionRequest - * - * @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\Vectorsearch\V1\VectorsearchService::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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/GetDataObjectRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/GetDataObjectRequest.php deleted file mode 100644 index be7fb8fd8310..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/GetDataObjectRequest.php +++ /dev/null @@ -1,92 +0,0 @@ -google.cloud.vectorsearch.v1.GetDataObjectRequest - */ -class GetDataObjectRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the DataObject resource. - * Format: - * `projects/{project}/locations/{location}/collections/{collection}/dataObjects/{dataObject}` - * - * 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 DataObject resource. - * Format: - * `projects/{project}/locations/{location}/collections/{collection}/dataObjects/{dataObject}` - * Please see {@see DataObjectServiceClient::dataObjectName()} for help formatting this field. - * - * @return \Google\Cloud\VectorSearch\V1\GetDataObjectRequest - * - * @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 DataObject resource. - * Format: - * `projects/{project}/locations/{location}/collections/{collection}/dataObjects/{dataObject}` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the DataObject resource. - * Format: - * `projects/{project}/locations/{location}/collections/{collection}/dataObjects/{dataObject}` - * - * 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 DataObject resource. - * Format: - * `projects/{project}/locations/{location}/collections/{collection}/dataObjects/{dataObject}` - * - * 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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/GetIndexRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/GetIndexRequest.php deleted file mode 100644 index 68af998408f1..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/GetIndexRequest.php +++ /dev/null @@ -1,81 +0,0 @@ -google.cloud.vectorsearch.v1.GetIndexRequest - */ -class GetIndexRequest 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 VectorSearchServiceClient::indexName()} for help formatting this field. - * - * @return \Google\Cloud\VectorSearch\V1\GetIndexRequest - * - * @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\Vectorsearch\V1\VectorsearchService::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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ImportDataObjectsMetadata.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ImportDataObjectsMetadata.php deleted file mode 100644 index 1b6aea8316d2..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ImportDataObjectsMetadata.php +++ /dev/null @@ -1,190 +0,0 @@ -google.cloud.vectorsearch.v1.ImportDataObjectsMetadata - */ -class ImportDataObjectsMetadata 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 was last updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Output only. Number of DataObjects that were processed successfully. - * - * Generated from protobuf field int64 success_count = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $success_count = 0; - /** - * Output only. Number of DataObjects that failed during processing. - * - * Generated from protobuf field int64 failure_count = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $failure_count = 0; - - /** - * 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 $update_time - * Output only. The time the operation was last updated. - * @type int|string $success_count - * Output only. Number of DataObjects that were processed successfully. - * @type int|string $failure_count - * Output only. Number of DataObjects that failed during processing. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\VectorsearchService::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 was last updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 2 [(.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 operation was last updated. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 2 [(.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. Number of DataObjects that were processed successfully. - * - * Generated from protobuf field int64 success_count = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int|string - */ - public function getSuccessCount() - { - return $this->success_count; - } - - /** - * Output only. Number of DataObjects that were processed successfully. - * - * Generated from protobuf field int64 success_count = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int|string $var - * @return $this - */ - public function setSuccessCount($var) - { - GPBUtil::checkInt64($var); - $this->success_count = $var; - - return $this; - } - - /** - * Output only. Number of DataObjects that failed during processing. - * - * Generated from protobuf field int64 failure_count = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int|string - */ - public function getFailureCount() - { - return $this->failure_count; - } - - /** - * Output only. Number of DataObjects that failed during processing. - * - * Generated from protobuf field int64 failure_count = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int|string $var - * @return $this - */ - public function setFailureCount($var) - { - GPBUtil::checkInt64($var); - $this->failure_count = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ImportDataObjectsRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ImportDataObjectsRequest.php deleted file mode 100644 index 7b8aeb8422ab..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ImportDataObjectsRequest.php +++ /dev/null @@ -1,114 +0,0 @@ -google.cloud.vectorsearch.v1.ImportDataObjectsRequest - */ -class ImportDataObjectsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the Collection to import DataObjects into. - * Format: `projects/{project}/locations/{location}/collections/{collection}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - protected $config; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\VectorSearch\V1\ImportDataObjectsRequest\GcsImportConfig $gcs_import - * The Cloud Storage location of the input content. - * @type string $name - * Required. The resource name of the Collection to import DataObjects into. - * Format: `projects/{project}/locations/{location}/collections/{collection}`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\VectorsearchService::initOnce(); - parent::__construct($data); - } - - /** - * The Cloud Storage location of the input content. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.ImportDataObjectsRequest.GcsImportConfig gcs_import = 2; - * @return \Google\Cloud\VectorSearch\V1\ImportDataObjectsRequest\GcsImportConfig|null - */ - public function getGcsImport() - { - return $this->readOneof(2); - } - - public function hasGcsImport() - { - return $this->hasOneof(2); - } - - /** - * The Cloud Storage location of the input content. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.ImportDataObjectsRequest.GcsImportConfig gcs_import = 2; - * @param \Google\Cloud\VectorSearch\V1\ImportDataObjectsRequest\GcsImportConfig $var - * @return $this - */ - public function setGcsImport($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\ImportDataObjectsRequest\GcsImportConfig::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * Required. The resource name of the Collection to import DataObjects into. - * Format: `projects/{project}/locations/{location}/collections/{collection}`. - * - * 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 Collection to import DataObjects into. - * Format: `projects/{project}/locations/{location}/collections/{collection}`. - * - * 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 getConfig() - { - return $this->whichOneof("config"); - } - -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ImportDataObjectsRequest/GcsImportConfig.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ImportDataObjectsRequest/GcsImportConfig.php deleted file mode 100644 index f60f8a784d42..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ImportDataObjectsRequest/GcsImportConfig.php +++ /dev/null @@ -1,151 +0,0 @@ -google.cloud.vectorsearch.v1.ImportDataObjectsRequest.GcsImportConfig - */ -class GcsImportConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Required. URI prefix of the Cloud Storage DataObjects to import. - * - * Generated from protobuf field string contents_uri = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $contents_uri = ''; - /** - * Required. URI prefix of the Cloud Storage location to write any errors - * encountered during the import. - * - * Generated from protobuf field string error_uri = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $error_uri = ''; - /** - * Optional. URI prefix of the Cloud Storage location to write DataObject - * `IDs` and `etags` of DataObjects that were successfully imported. The - * service will write the successfully imported DataObjects to sharded files - * under this prefix. If this field is empty, no output will be written. - * - * Generated from protobuf field string output_uri = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $output_uri = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $contents_uri - * Required. URI prefix of the Cloud Storage DataObjects to import. - * @type string $error_uri - * Required. URI prefix of the Cloud Storage location to write any errors - * encountered during the import. - * @type string $output_uri - * Optional. URI prefix of the Cloud Storage location to write DataObject - * `IDs` and `etags` of DataObjects that were successfully imported. The - * service will write the successfully imported DataObjects to sharded files - * under this prefix. If this field is empty, no output will be written. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\VectorsearchService::initOnce(); - parent::__construct($data); - } - - /** - * Required. URI prefix of the Cloud Storage DataObjects to import. - * - * Generated from protobuf field string contents_uri = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getContentsUri() - { - return $this->contents_uri; - } - - /** - * Required. URI prefix of the Cloud Storage DataObjects to import. - * - * Generated from protobuf field string contents_uri = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setContentsUri($var) - { - GPBUtil::checkString($var, True); - $this->contents_uri = $var; - - return $this; - } - - /** - * Required. URI prefix of the Cloud Storage location to write any errors - * encountered during the import. - * - * Generated from protobuf field string error_uri = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getErrorUri() - { - return $this->error_uri; - } - - /** - * Required. URI prefix of the Cloud Storage location to write any errors - * encountered during the import. - * - * Generated from protobuf field string error_uri = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setErrorUri($var) - { - GPBUtil::checkString($var, True); - $this->error_uri = $var; - - return $this; - } - - /** - * Optional. URI prefix of the Cloud Storage location to write DataObject - * `IDs` and `etags` of DataObjects that were successfully imported. The - * service will write the successfully imported DataObjects to sharded files - * under this prefix. If this field is empty, no output will be written. - * - * Generated from protobuf field string output_uri = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getOutputUri() - { - return $this->output_uri; - } - - /** - * Optional. URI prefix of the Cloud Storage location to write DataObject - * `IDs` and `etags` of DataObjects that were successfully imported. The - * service will write the successfully imported DataObjects to sharded files - * under this prefix. If this field is empty, no output will be written. - * - * Generated from protobuf field string output_uri = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setOutputUri($var) - { - GPBUtil::checkString($var, True); - $this->output_uri = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ImportDataObjectsResponse.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ImportDataObjectsResponse.php deleted file mode 100644 index 7509212d5269..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ImportDataObjectsResponse.php +++ /dev/null @@ -1,78 +0,0 @@ -google.cloud.vectorsearch.v1.ImportDataObjectsResponse - */ -class ImportDataObjectsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Status of the LRO - * - * Generated from protobuf field .google.rpc.Status status = 1; - */ - protected $status = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Rpc\Status $status - * Status of the LRO - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\VectorsearchService::initOnce(); - parent::__construct($data); - } - - /** - * Status of the LRO - * - * Generated from protobuf field .google.rpc.Status status = 1; - * @return \Google\Rpc\Status|null - */ - public function getStatus() - { - return $this->status; - } - - public function hasStatus() - { - return isset($this->status); - } - - public function clearStatus() - { - unset($this->status); - } - - /** - * Status of the LRO - * - * Generated from protobuf field .google.rpc.Status status = 1; - * @param \Google\Rpc\Status $var - * @return $this - */ - public function setStatus($var) - { - GPBUtil::checkMessage($var, \Google\Rpc\Status::class); - $this->status = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/Index.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/Index.php deleted file mode 100644 index 4ff336fedcc6..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/Index.php +++ /dev/null @@ -1,489 +0,0 @@ -google.cloud.vectorsearch.v1.Index - */ -class Index extends \Google\Protobuf\Internal\Message -{ - /** - * Identifier. name of resource - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; - */ - protected $name = ''; - /** - * Optional. User-specified display name of the index - * - * Generated from protobuf field string display_name = 8 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $display_name = ''; - /** - * Optional. User-specified description of the index - * - * Generated from protobuf field string description = 9 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $description = ''; - /** - * Optional. Labels as key value pairs. - * - * Generated from protobuf field map labels = 10 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $labels; - /** - * 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. Distance metric used for indexing. If not specified, will default - * to DOT_PRODUCT. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.DistanceMetric distance_metric = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $distance_metric = 0; - /** - * Required. The collection schema field to index. - * - * Generated from protobuf field string index_field = 5 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $index_field = ''; - /** - * Optional. The fields to push into the index to enable fast ANN inline - * filtering. - * - * Generated from protobuf field repeated string filter_fields = 6 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $filter_fields; - /** - * Optional. The fields to push into the index to enable inline data - * retrieval. - * - * Generated from protobuf field repeated string store_fields = 7 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $store_fields; - protected $infra_type; - protected $index_type; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\VectorSearch\V1\DedicatedInfrastructure $dedicated_infrastructure - * Optional. Dedicated infrastructure for the index. - * @type \Google\Cloud\VectorSearch\V1\DenseScannIndex $dense_scann - * Optional. Dense ScaNN index. - * @type string $name - * Identifier. name of resource - * @type string $display_name - * Optional. User-specified display name of the index - * @type string $description - * Optional. User-specified description of the index - * @type array|\Google\Protobuf\Internal\MapField $labels - * Optional. Labels as key value pairs. - * @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 $distance_metric - * Optional. Distance metric used for indexing. If not specified, will default - * to DOT_PRODUCT. - * @type string $index_field - * Required. The collection schema field to index. - * @type string[] $filter_fields - * Optional. The fields to push into the index to enable fast ANN inline - * filtering. - * @type string[] $store_fields - * Optional. The fields to push into the index to enable inline data - * retrieval. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\VectorsearchService::initOnce(); - parent::__construct($data); - } - - /** - * Optional. Dedicated infrastructure for the index. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.DedicatedInfrastructure dedicated_infrastructure = 11 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\VectorSearch\V1\DedicatedInfrastructure|null - */ - public function getDedicatedInfrastructure() - { - return $this->readOneof(11); - } - - public function hasDedicatedInfrastructure() - { - return $this->hasOneof(11); - } - - /** - * Optional. Dedicated infrastructure for the index. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.DedicatedInfrastructure dedicated_infrastructure = 11 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\VectorSearch\V1\DedicatedInfrastructure $var - * @return $this - */ - public function setDedicatedInfrastructure($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\DedicatedInfrastructure::class); - $this->writeOneof(11, $var); - - return $this; - } - - /** - * Optional. Dense ScaNN index. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.DenseScannIndex dense_scann = 12 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\VectorSearch\V1\DenseScannIndex|null - */ - public function getDenseScann() - { - return $this->readOneof(12); - } - - public function hasDenseScann() - { - return $this->hasOneof(12); - } - - /** - * Optional. Dense ScaNN index. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.DenseScannIndex dense_scann = 12 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\VectorSearch\V1\DenseScannIndex $var - * @return $this - */ - public function setDenseScann($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\DenseScannIndex::class); - $this->writeOneof(12, $var); - - return $this; - } - - /** - * Identifier. name of resource - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Identifier. name of resource - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = IDENTIFIER]; - * @param string $var - * @return $this - */ - public function setName($var) - { - GPBUtil::checkString($var, True); - $this->name = $var; - - return $this; - } - - /** - * Optional. User-specified display name of the index - * - * Generated from protobuf field string display_name = 8 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * Optional. User-specified display name of the index - * - * Generated from protobuf field string display_name = 8 [(.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. User-specified description of the index - * - * Generated from protobuf field string description = 9 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * Optional. User-specified description of the index - * - * Generated from protobuf field string description = 9 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * Optional. Labels as key value pairs. - * - * Generated from protobuf field map labels = 10 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Optional. Labels as key value pairs. - * - * Generated from protobuf field map labels = 10 [(.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; - } - - /** - * 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. Distance metric used for indexing. If not specified, will default - * to DOT_PRODUCT. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.DistanceMetric distance_metric = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getDistanceMetric() - { - return $this->distance_metric; - } - - /** - * Optional. Distance metric used for indexing. If not specified, will default - * to DOT_PRODUCT. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.DistanceMetric distance_metric = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setDistanceMetric($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\VectorSearch\V1\DistanceMetric::class); - $this->distance_metric = $var; - - return $this; - } - - /** - * Required. The collection schema field to index. - * - * Generated from protobuf field string index_field = 5 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getIndexField() - { - return $this->index_field; - } - - /** - * Required. The collection schema field to index. - * - * Generated from protobuf field string index_field = 5 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setIndexField($var) - { - GPBUtil::checkString($var, True); - $this->index_field = $var; - - return $this; - } - - /** - * Optional. The fields to push into the index to enable fast ANN inline - * filtering. - * - * Generated from protobuf field repeated string filter_fields = 6 [(.google.api.field_behavior) = OPTIONAL]; - * @return RepeatedField - */ - public function getFilterFields() - { - return $this->filter_fields; - } - - /** - * Optional. The fields to push into the index to enable fast ANN inline - * filtering. - * - * Generated from protobuf field repeated string filter_fields = 6 [(.google.api.field_behavior) = OPTIONAL]; - * @param string[] $var - * @return $this - */ - public function setFilterFields($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->filter_fields = $arr; - - return $this; - } - - /** - * Optional. The fields to push into the index to enable inline data - * retrieval. - * - * Generated from protobuf field repeated string store_fields = 7 [(.google.api.field_behavior) = OPTIONAL]; - * @return RepeatedField - */ - public function getStoreFields() - { - return $this->store_fields; - } - - /** - * Optional. The fields to push into the index to enable inline data - * retrieval. - * - * Generated from protobuf field repeated string store_fields = 7 [(.google.api.field_behavior) = OPTIONAL]; - * @param string[] $var - * @return $this - */ - public function setStoreFields($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->store_fields = $arr; - - return $this; - } - - /** - * @return string - */ - public function getInfraType() - { - return $this->whichOneof("infra_type"); - } - - /** - * @return string - */ - public function getIndexType() - { - return $this->whichOneof("index_type"); - } - -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ListCollectionsRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ListCollectionsRequest.php deleted file mode 100644 index 274dbd3cbc56..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ListCollectionsRequest.php +++ /dev/null @@ -1,221 +0,0 @@ -google.cloud.vectorsearch.v1.ListCollectionsRequest - */ -class ListCollectionsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Parent value for ListCollectionsRequest - * - * 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 ListCollectionsRequest - * Please see {@see VectorSearchServiceClient::locationName()} for help formatting this field. - * - * @return \Google\Cloud\VectorSearch\V1\ListCollectionsRequest - * - * @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 ListCollectionsRequest - * @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\Vectorsearch\V1\VectorsearchService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Parent value for ListCollectionsRequest - * - * 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 ListCollectionsRequest - * - * 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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ListCollectionsResponse.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ListCollectionsResponse.php deleted file mode 100644 index fe7602172c0a..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ListCollectionsResponse.php +++ /dev/null @@ -1,135 +0,0 @@ -google.cloud.vectorsearch.v1.ListCollectionsResponse - */ -class ListCollectionsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The list of Collection - * - * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.Collection collections = 1; - */ - private $collections; - /** - * A token identifying a page of results the server should return. - * - * Generated from protobuf field string next_page_token = 2; - */ - protected $next_page_token = ''; - /** - * Unordered list. Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3 [(.google.api.field_behavior) = UNORDERED_LIST]; - */ - private $unreachable; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\VectorSearch\V1\Collection[] $collections - * The list of Collection - * @type string $next_page_token - * A token identifying a page of results the server should return. - * @type string[] $unreachable - * Unordered list. Locations that could not be reached. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\VectorsearchService::initOnce(); - parent::__construct($data); - } - - /** - * The list of Collection - * - * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.Collection collections = 1; - * @return RepeatedField<\Google\Cloud\VectorSearch\V1\Collection> - */ - public function getCollections() - { - return $this->collections; - } - - /** - * The list of Collection - * - * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.Collection collections = 1; - * @param \Google\Cloud\VectorSearch\V1\Collection[] $var - * @return $this - */ - public function setCollections($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VectorSearch\V1\Collection::class); - $this->collections = $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; - } - - /** - * Unordered list. Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3 [(.google.api.field_behavior) = UNORDERED_LIST]; - * @return RepeatedField - */ - public function getUnreachable() - { - return $this->unreachable; - } - - /** - * Unordered list. Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3 [(.google.api.field_behavior) = UNORDERED_LIST]; - * @param string[] $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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ListIndexesRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ListIndexesRequest.php deleted file mode 100644 index 8f0becae371a..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ListIndexesRequest.php +++ /dev/null @@ -1,221 +0,0 @@ -google.cloud.vectorsearch.v1.ListIndexesRequest - */ -class ListIndexesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Parent value for ListIndexesRequest - * - * 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 ListIndexesRequest - * Please see {@see VectorSearchServiceClient::collectionName()} for help formatting this field. - * - * @return \Google\Cloud\VectorSearch\V1\ListIndexesRequest - * - * @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 ListIndexesRequest - * @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\Vectorsearch\V1\VectorsearchService::initOnce(); - parent::__construct($data); - } - - /** - * Required. Parent value for ListIndexesRequest - * - * 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 ListIndexesRequest - * - * 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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ListIndexesResponse.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ListIndexesResponse.php deleted file mode 100644 index 48db430c005f..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ListIndexesResponse.php +++ /dev/null @@ -1,101 +0,0 @@ -google.cloud.vectorsearch.v1.ListIndexesResponse - */ -class ListIndexesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The list of Index - * - * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.Index indexes = 1; - */ - private $indexes; - /** - * 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 \Google\Cloud\VectorSearch\V1\Index[] $indexes - * The list of Index - * @type string $next_page_token - * A token identifying a page of results the server should return. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\VectorsearchService::initOnce(); - parent::__construct($data); - } - - /** - * The list of Index - * - * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.Index indexes = 1; - * @return RepeatedField<\Google\Cloud\VectorSearch\V1\Index> - */ - public function getIndexes() - { - return $this->indexes; - } - - /** - * The list of Index - * - * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.Index indexes = 1; - * @param \Google\Cloud\VectorSearch\V1\Index[] $var - * @return $this - */ - public function setIndexes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VectorSearch\V1\Index::class); - $this->indexes = $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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/OperationMetadata.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/OperationMetadata.php deleted file mode 100644 index f8363f5cc8c1..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/OperationMetadata.php +++ /dev/null @@ -1,311 +0,0 @@ -google.cloud.vectorsearch.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 been cancelled successfully - * have - * [google.longrunning.Operation.error][google.longrunning.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 - * [google.longrunning.Operation.error][google.longrunning.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\Vectorsearch\V1\VectorsearchService::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 - * [google.longrunning.Operation.error][google.longrunning.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 - * [google.longrunning.Operation.error][google.longrunning.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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/OutputFields.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/OutputFields.php deleted file mode 100644 index 8fd505929402..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/OutputFields.php +++ /dev/null @@ -1,135 +0,0 @@ -google.cloud.vectorsearch.v1.OutputFields - */ -class OutputFields extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. The fields from the data fields to include in the output. - * - * Generated from protobuf field repeated string data_fields = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $data_fields; - /** - * Optional. The fields from the vector fields to include in the output. - * - * Generated from protobuf field repeated string vector_fields = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $vector_fields; - /** - * Optional. The fields from the DataObject metadata to include in the output. - * - * Generated from protobuf field repeated string metadata_fields = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $metadata_fields; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string[] $data_fields - * Optional. The fields from the data fields to include in the output. - * @type string[] $vector_fields - * Optional. The fields from the vector fields to include in the output. - * @type string[] $metadata_fields - * Optional. The fields from the DataObject metadata to include in the output. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectSearchService::initOnce(); - parent::__construct($data); - } - - /** - * Optional. The fields from the data fields to include in the output. - * - * Generated from protobuf field repeated string data_fields = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @return RepeatedField - */ - public function getDataFields() - { - return $this->data_fields; - } - - /** - * Optional. The fields from the data fields to include in the output. - * - * Generated from protobuf field repeated string data_fields = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @param string[] $var - * @return $this - */ - public function setDataFields($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->data_fields = $arr; - - return $this; - } - - /** - * Optional. The fields from the vector fields to include in the output. - * - * Generated from protobuf field repeated string vector_fields = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return RepeatedField - */ - public function getVectorFields() - { - return $this->vector_fields; - } - - /** - * Optional. The fields from the vector fields to include in the output. - * - * Generated from protobuf field repeated string vector_fields = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param string[] $var - * @return $this - */ - public function setVectorFields($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->vector_fields = $arr; - - return $this; - } - - /** - * Optional. The fields from the DataObject metadata to include in the output. - * - * Generated from protobuf field repeated string metadata_fields = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return RepeatedField - */ - public function getMetadataFields() - { - return $this->metadata_fields; - } - - /** - * Optional. The fields from the DataObject metadata to include in the output. - * - * Generated from protobuf field repeated string metadata_fields = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param string[] $var - * @return $this - */ - public function setMetadataFields($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->metadata_fields = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/QueryDataObjectsRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/QueryDataObjectsRequest.php deleted file mode 100644 index 3541cbbd21d5..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/QueryDataObjectsRequest.php +++ /dev/null @@ -1,256 +0,0 @@ -google.cloud.vectorsearch.v1.QueryDataObjectsRequest - */ -class QueryDataObjectsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the Collection for which to query. - * Format: `projects/{project}/locations/{location}/collections/{collection}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Optional. A JSON filter expression, e.g. {"genre": {"$eq": "sci-fi"}}, - * represented as a google.protobuf.Struct. - * - * Generated from protobuf field .google.protobuf.Struct filter = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $filter = null; - /** - * Optional. Mask specifying which fields to return. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.OutputFields output_fields = 7 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $output_fields = null; - /** - * Optional. The standard list page size. Default is 100. - * The maximum value is 1000; values above 1000 will be coerced to 1000. - * - * Generated from protobuf field int32 page_size = 5 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $page_size = 0; - /** - * Optional. The standard list page token. - * Typically obtained via - * [QueryDataObjectsResponse.next_page_token][google.cloud.vectorsearch.v1.QueryDataObjectsResponse.next_page_token] - * of the previous - * [DataObjectSearchService.QueryDataObjects][google.cloud.vectorsearch.v1.DataObjectSearchService.QueryDataObjects] - * call. - * - * Generated from protobuf field string page_token = 6 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The resource name of the Collection for which to query. - * Format: `projects/{project}/locations/{location}/collections/{collection}` - * @type \Google\Protobuf\Struct $filter - * Optional. A JSON filter expression, e.g. {"genre": {"$eq": "sci-fi"}}, - * represented as a google.protobuf.Struct. - * @type \Google\Cloud\VectorSearch\V1\OutputFields $output_fields - * Optional. Mask specifying which fields to return. - * @type int $page_size - * Optional. The standard list page size. Default is 100. - * The maximum value is 1000; values above 1000 will be coerced to 1000. - * @type string $page_token - * Optional. The standard list page token. - * Typically obtained via - * [QueryDataObjectsResponse.next_page_token][google.cloud.vectorsearch.v1.QueryDataObjectsResponse.next_page_token] - * of the previous - * [DataObjectSearchService.QueryDataObjects][google.cloud.vectorsearch.v1.DataObjectSearchService.QueryDataObjects] - * call. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectSearchService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the Collection for which to query. - * Format: `projects/{project}/locations/{location}/collections/{collection}` - * - * 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 Collection for which to query. - * Format: `projects/{project}/locations/{location}/collections/{collection}` - * - * 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. A JSON filter expression, e.g. {"genre": {"$eq": "sci-fi"}}, - * represented as a google.protobuf.Struct. - * - * Generated from protobuf field .google.protobuf.Struct filter = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Struct|null - */ - public function getFilter() - { - return $this->filter; - } - - public function hasFilter() - { - return isset($this->filter); - } - - public function clearFilter() - { - unset($this->filter); - } - - /** - * Optional. A JSON filter expression, e.g. {"genre": {"$eq": "sci-fi"}}, - * represented as a google.protobuf.Struct. - * - * Generated from protobuf field .google.protobuf.Struct filter = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Protobuf\Struct $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Struct::class); - $this->filter = $var; - - return $this; - } - - /** - * Optional. Mask specifying which fields to return. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.OutputFields output_fields = 7 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\VectorSearch\V1\OutputFields|null - */ - public function getOutputFields() - { - return $this->output_fields; - } - - public function hasOutputFields() - { - return isset($this->output_fields); - } - - public function clearOutputFields() - { - unset($this->output_fields); - } - - /** - * Optional. Mask specifying which fields to return. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.OutputFields output_fields = 7 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\VectorSearch\V1\OutputFields $var - * @return $this - */ - public function setOutputFields($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\OutputFields::class); - $this->output_fields = $var; - - return $this; - } - - /** - * Optional. The standard list page size. Default is 100. - * The maximum value is 1000; values above 1000 will be coerced to 1000. - * - * Generated from protobuf field int32 page_size = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Optional. The standard list page size. Default is 100. - * The maximum value is 1000; values above 1000 will be coerced to 1000. - * - * Generated from protobuf field int32 page_size = 5 [(.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 standard list page token. - * Typically obtained via - * [QueryDataObjectsResponse.next_page_token][google.cloud.vectorsearch.v1.QueryDataObjectsResponse.next_page_token] - * of the previous - * [DataObjectSearchService.QueryDataObjects][google.cloud.vectorsearch.v1.DataObjectSearchService.QueryDataObjects] - * call. - * - * Generated from protobuf field string page_token = 6 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Optional. The standard list page token. - * Typically obtained via - * [QueryDataObjectsResponse.next_page_token][google.cloud.vectorsearch.v1.QueryDataObjectsResponse.next_page_token] - * of the previous - * [DataObjectSearchService.QueryDataObjects][google.cloud.vectorsearch.v1.DataObjectSearchService.QueryDataObjects] - * call. - * - * Generated from protobuf field string page_token = 6 [(.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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/QueryDataObjectsResponse.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/QueryDataObjectsResponse.php deleted file mode 100644 index 4e90b7849c2d..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/QueryDataObjectsResponse.php +++ /dev/null @@ -1,110 +0,0 @@ -google.cloud.vectorsearch.v1.QueryDataObjectsResponse - */ -class QueryDataObjectsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The list of dataObjects that match the query. - * - * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.DataObject data_objects = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - private $data_objects; - /** - * Output only. A token to retrieve next page of results. - * Pass to [DataObjectSearchService.QueryDataObjectsRequest.page_token][] to - * obtain that page. - * - * Generated from protobuf field string next_page_token = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\VectorSearch\V1\DataObject[] $data_objects - * Output only. The list of dataObjects that match the query. - * @type string $next_page_token - * Output only. A token to retrieve next page of results. - * Pass to [DataObjectSearchService.QueryDataObjectsRequest.page_token][] to - * obtain that page. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectSearchService::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The list of dataObjects that match the query. - * - * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.DataObject data_objects = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return RepeatedField<\Google\Cloud\VectorSearch\V1\DataObject> - */ - public function getDataObjects() - { - return $this->data_objects; - } - - /** - * Output only. The list of dataObjects that match the query. - * - * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.DataObject data_objects = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\VectorSearch\V1\DataObject[] $var - * @return $this - */ - public function setDataObjects($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VectorSearch\V1\DataObject::class); - $this->data_objects = $arr; - - return $this; - } - - /** - * Output only. A token to retrieve next page of results. - * Pass to [DataObjectSearchService.QueryDataObjectsRequest.page_token][] to - * obtain that page. - * - * Generated from protobuf field string next_page_token = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * Output only. A token to retrieve next page of results. - * Pass to [DataObjectSearchService.QueryDataObjectsRequest.page_token][] to - * obtain that page. - * - * Generated from protobuf field string next_page_token = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/Ranker.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/Ranker.php deleted file mode 100644 index a0aa74f03057..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/Ranker.php +++ /dev/null @@ -1,75 +0,0 @@ -google.cloud.vectorsearch.v1.Ranker - */ -class Ranker extends \Google\Protobuf\Internal\Message -{ - protected $ranker; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\VectorSearch\V1\ReciprocalRankFusion $rrf - * Reciprocal Rank Fusion ranking. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectSearchService::initOnce(); - parent::__construct($data); - } - - /** - * Reciprocal Rank Fusion ranking. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.ReciprocalRankFusion rrf = 1; - * @return \Google\Cloud\VectorSearch\V1\ReciprocalRankFusion|null - */ - public function getRrf() - { - return $this->readOneof(1); - } - - public function hasRrf() - { - return $this->hasOneof(1); - } - - /** - * Reciprocal Rank Fusion ranking. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.ReciprocalRankFusion rrf = 1; - * @param \Google\Cloud\VectorSearch\V1\ReciprocalRankFusion $var - * @return $this - */ - public function setRrf($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\ReciprocalRankFusion::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * @return string - */ - public function getRanker() - { - return $this->whichOneof("ranker"); - } - -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ReciprocalRankFusion.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ReciprocalRankFusion.php deleted file mode 100644 index 9d529790eaca..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/ReciprocalRankFusion.php +++ /dev/null @@ -1,67 +0,0 @@ -google.cloud.vectorsearch.v1.ReciprocalRankFusion - */ -class ReciprocalRankFusion extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The weights to apply to each search result set during fusion. - * - * Generated from protobuf field repeated double weights = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - private $weights; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type float[] $weights - * Required. The weights to apply to each search result set during fusion. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectSearchService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The weights to apply to each search result set during fusion. - * - * Generated from protobuf field repeated double weights = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return RepeatedField - */ - public function getWeights() - { - return $this->weights; - } - - /** - * Required. The weights to apply to each search result set during fusion. - * - * Generated from protobuf field repeated double weights = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param float[] $var - * @return $this - */ - public function setWeights($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::DOUBLE); - $this->weights = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/Search.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/Search.php deleted file mode 100644 index 911a22fc617a..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/Search.php +++ /dev/null @@ -1,141 +0,0 @@ -google.cloud.vectorsearch.v1.Search - */ -class Search extends \Google\Protobuf\Internal\Message -{ - protected $search_type; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\VectorSearch\V1\VectorSearch $vector_search - * A vector-based search. - * @type \Google\Cloud\VectorSearch\V1\SemanticSearch $semantic_search - * A semantic search. - * @type \Google\Cloud\VectorSearch\V1\TextSearch $text_search - * A text search operation. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectSearchService::initOnce(); - parent::__construct($data); - } - - /** - * A vector-based search. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.VectorSearch vector_search = 1; - * @return \Google\Cloud\VectorSearch\V1\VectorSearch|null - */ - public function getVectorSearch() - { - return $this->readOneof(1); - } - - public function hasVectorSearch() - { - return $this->hasOneof(1); - } - - /** - * A vector-based search. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.VectorSearch vector_search = 1; - * @param \Google\Cloud\VectorSearch\V1\VectorSearch $var - * @return $this - */ - public function setVectorSearch($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\VectorSearch::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * A semantic search. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.SemanticSearch semantic_search = 2; - * @return \Google\Cloud\VectorSearch\V1\SemanticSearch|null - */ - public function getSemanticSearch() - { - return $this->readOneof(2); - } - - public function hasSemanticSearch() - { - return $this->hasOneof(2); - } - - /** - * A semantic search. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.SemanticSearch semantic_search = 2; - * @param \Google\Cloud\VectorSearch\V1\SemanticSearch $var - * @return $this - */ - public function setSemanticSearch($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\SemanticSearch::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * A text search operation. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.TextSearch text_search = 3; - * @return \Google\Cloud\VectorSearch\V1\TextSearch|null - */ - public function getTextSearch() - { - return $this->readOneof(3); - } - - public function hasTextSearch() - { - return $this->hasOneof(3); - } - - /** - * A text search operation. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.TextSearch text_search = 3; - * @param \Google\Cloud\VectorSearch\V1\TextSearch $var - * @return $this - */ - public function setTextSearch($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\TextSearch::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * @return string - */ - public function getSearchType() - { - return $this->whichOneof("search_type"); - } - -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchDataObjectsRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchDataObjectsRequest.php deleted file mode 100644 index d8b0cb20dfe5..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchDataObjectsRequest.php +++ /dev/null @@ -1,275 +0,0 @@ -google.cloud.vectorsearch.v1.SearchDataObjectsRequest - */ -class SearchDataObjectsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the Collection for which to search. - * Format: `projects/{project}/locations/{location}/collections/{collection}` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Optional. The standard list page size. Only supported for KNN. If not set, - * up to search_type.top_k results will be returned. The maximum value is - * 1000; values above 1000 will be coerced to 1000. - * - * Generated from protobuf field int32 page_size = 5 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $page_size = 0; - /** - * Optional. The standard list page token. - * Typically obtained via - * [SearchDataObjectsResponse.next_page_token][google.cloud.vectorsearch.v1.SearchDataObjectsResponse.next_page_token] - * of the previous - * [DataObjectSearchService.SearchDataObjects][google.cloud.vectorsearch.v1.DataObjectSearchService.SearchDataObjects] - * call. - * - * Generated from protobuf field string page_token = 6 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $page_token = ''; - protected $search_type; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\VectorSearch\V1\VectorSearch $vector_search - * A vector search operation. - * @type \Google\Cloud\VectorSearch\V1\SemanticSearch $semantic_search - * A semantic search operation. - * @type \Google\Cloud\VectorSearch\V1\TextSearch $text_search - * Optional. A text search operation. - * @type string $parent - * Required. The resource name of the Collection for which to search. - * Format: `projects/{project}/locations/{location}/collections/{collection}` - * @type int $page_size - * Optional. The standard list page size. Only supported for KNN. If not set, - * up to search_type.top_k results will be returned. The maximum value is - * 1000; values above 1000 will be coerced to 1000. - * @type string $page_token - * Optional. The standard list page token. - * Typically obtained via - * [SearchDataObjectsResponse.next_page_token][google.cloud.vectorsearch.v1.SearchDataObjectsResponse.next_page_token] - * of the previous - * [DataObjectSearchService.SearchDataObjects][google.cloud.vectorsearch.v1.DataObjectSearchService.SearchDataObjects] - * call. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectSearchService::initOnce(); - parent::__construct($data); - } - - /** - * A vector search operation. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.VectorSearch vector_search = 2; - * @return \Google\Cloud\VectorSearch\V1\VectorSearch|null - */ - public function getVectorSearch() - { - return $this->readOneof(2); - } - - public function hasVectorSearch() - { - return $this->hasOneof(2); - } - - /** - * A vector search operation. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.VectorSearch vector_search = 2; - * @param \Google\Cloud\VectorSearch\V1\VectorSearch $var - * @return $this - */ - public function setVectorSearch($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\VectorSearch::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * A semantic search operation. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.SemanticSearch semantic_search = 4; - * @return \Google\Cloud\VectorSearch\V1\SemanticSearch|null - */ - public function getSemanticSearch() - { - return $this->readOneof(4); - } - - public function hasSemanticSearch() - { - return $this->hasOneof(4); - } - - /** - * A semantic search operation. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.SemanticSearch semantic_search = 4; - * @param \Google\Cloud\VectorSearch\V1\SemanticSearch $var - * @return $this - */ - public function setSemanticSearch($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\SemanticSearch::class); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * Optional. A text search operation. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.TextSearch text_search = 7 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\VectorSearch\V1\TextSearch|null - */ - public function getTextSearch() - { - return $this->readOneof(7); - } - - public function hasTextSearch() - { - return $this->hasOneof(7); - } - - /** - * Optional. A text search operation. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.TextSearch text_search = 7 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\VectorSearch\V1\TextSearch $var - * @return $this - */ - public function setTextSearch($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\TextSearch::class); - $this->writeOneof(7, $var); - - return $this; - } - - /** - * Required. The resource name of the Collection for which to search. - * Format: `projects/{project}/locations/{location}/collections/{collection}` - * - * 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 Collection for which to search. - * Format: `projects/{project}/locations/{location}/collections/{collection}` - * - * 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 standard list page size. Only supported for KNN. If not set, - * up to search_type.top_k results will be returned. The maximum value is - * 1000; values above 1000 will be coerced to 1000. - * - * Generated from protobuf field int32 page_size = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * Optional. The standard list page size. Only supported for KNN. If not set, - * up to search_type.top_k results will be returned. The maximum value is - * 1000; values above 1000 will be coerced to 1000. - * - * Generated from protobuf field int32 page_size = 5 [(.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 standard list page token. - * Typically obtained via - * [SearchDataObjectsResponse.next_page_token][google.cloud.vectorsearch.v1.SearchDataObjectsResponse.next_page_token] - * of the previous - * [DataObjectSearchService.SearchDataObjects][google.cloud.vectorsearch.v1.DataObjectSearchService.SearchDataObjects] - * call. - * - * Generated from protobuf field string page_token = 6 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * Optional. The standard list page token. - * Typically obtained via - * [SearchDataObjectsResponse.next_page_token][google.cloud.vectorsearch.v1.SearchDataObjectsResponse.next_page_token] - * of the previous - * [DataObjectSearchService.SearchDataObjects][google.cloud.vectorsearch.v1.DataObjectSearchService.SearchDataObjects] - * call. - * - * Generated from protobuf field string page_token = 6 [(.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 getSearchType() - { - return $this->whichOneof("search_type"); - } - -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchDataObjectsResponse.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchDataObjectsResponse.php deleted file mode 100644 index 72f03ef01dc2..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchDataObjectsResponse.php +++ /dev/null @@ -1,109 +0,0 @@ -google.cloud.vectorsearch.v1.SearchDataObjectsResponse - */ -class SearchDataObjectsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The list of dataObjects that match the search criteria. - * - * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.SearchResult results = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - private $results; - /** - * Output only. A token to retrieve next page of results. - * Pass to [DataObjectSearchService.SearchDataObjectsRequest.page_token][] to - * obtain that page. - * - * Generated from protobuf field string next_page_token = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $next_page_token = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\VectorSearch\V1\SearchResult[] $results - * Output only. The list of dataObjects that match the search criteria. - * @type string $next_page_token - * Output only. A token to retrieve next page of results. - * Pass to [DataObjectSearchService.SearchDataObjectsRequest.page_token][] to - * obtain that page. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectSearchService::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The list of dataObjects that match the search criteria. - * - * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.SearchResult results = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return RepeatedField<\Google\Cloud\VectorSearch\V1\SearchResult> - */ - public function getResults() - { - return $this->results; - } - - /** - * Output only. The list of dataObjects that match the search criteria. - * - * Generated from protobuf field repeated .google.cloud.vectorsearch.v1.SearchResult results = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\VectorSearch\V1\SearchResult[] $var - * @return $this - */ - public function setResults($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VectorSearch\V1\SearchResult::class); - $this->results = $arr; - - return $this; - } - - /** - * Output only. A token to retrieve next page of results. - * Pass to [DataObjectSearchService.SearchDataObjectsRequest.page_token][] to - * obtain that page. - * - * Generated from protobuf field string next_page_token = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getNextPageToken() - { - return $this->next_page_token; - } - - /** - * Output only. A token to retrieve next page of results. - * Pass to [DataObjectSearchService.SearchDataObjectsRequest.page_token][] to - * obtain that page. - * - * Generated from protobuf field string next_page_token = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchHint.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchHint.php deleted file mode 100644 index 5ed0fb6d89b6..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchHint.php +++ /dev/null @@ -1,111 +0,0 @@ -google.cloud.vectorsearch.v1.SearchHint - */ -class SearchHint extends \Google\Protobuf\Internal\Message -{ - protected $index_type; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\VectorSearch\V1\SearchHint\KnnHint $knn_hint - * Optional. If set, the search will use the system's default - * K-Nearest Neighbor (KNN) index engine. - * @type \Google\Cloud\VectorSearch\V1\SearchHint\IndexHint $index_hint - * Optional. Specifies that the search should use a particular index. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectSearchService::initOnce(); - parent::__construct($data); - } - - /** - * Optional. If set, the search will use the system's default - * K-Nearest Neighbor (KNN) index engine. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.SearchHint.KnnHint knn_hint = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\VectorSearch\V1\SearchHint\KnnHint|null - */ - public function getKnnHint() - { - return $this->readOneof(3); - } - - public function hasKnnHint() - { - return $this->hasOneof(3); - } - - /** - * Optional. If set, the search will use the system's default - * K-Nearest Neighbor (KNN) index engine. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.SearchHint.KnnHint knn_hint = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\VectorSearch\V1\SearchHint\KnnHint $var - * @return $this - */ - public function setKnnHint($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\SearchHint\KnnHint::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * Optional. Specifies that the search should use a particular index. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.SearchHint.IndexHint index_hint = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\VectorSearch\V1\SearchHint\IndexHint|null - */ - public function getIndexHint() - { - return $this->readOneof(4); - } - - public function hasIndexHint() - { - return $this->hasOneof(4); - } - - /** - * Optional. Specifies that the search should use a particular index. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.SearchHint.IndexHint index_hint = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\VectorSearch\V1\SearchHint\IndexHint $var - * @return $this - */ - public function setIndexHint($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\SearchHint\IndexHint::class); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * @return string - */ - public function getIndexType() - { - return $this->whichOneof("index_type"); - } - -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchHint/IndexHint.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchHint/IndexHint.php deleted file mode 100644 index e002e515f974..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchHint/IndexHint.php +++ /dev/null @@ -1,79 +0,0 @@ -google.cloud.vectorsearch.v1.SearchHint.IndexHint - */ -class IndexHint extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the index to use for the search. - * The index must be in the same project, location, and collection. - * Format: - * `projects/{project}/locations/{location}/collections/{collection}/indexes/{index}` - * - * 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 index to use for the search. - * The index must be in the same project, location, and collection. - * Format: - * `projects/{project}/locations/{location}/collections/{collection}/indexes/{index}` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectSearchService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the index to use for the search. - * The index must be in the same project, location, and collection. - * Format: - * `projects/{project}/locations/{location}/collections/{collection}/indexes/{index}` - * - * 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 index to use for the search. - * The index must be in the same project, location, and collection. - * Format: - * `projects/{project}/locations/{location}/collections/{collection}/indexes/{index}` - * - * 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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchHint/KnnHint.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchHint/KnnHint.php deleted file mode 100644 index 0253c90e18ef..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchHint/KnnHint.php +++ /dev/null @@ -1,34 +0,0 @@ -google.cloud.vectorsearch.v1.SearchHint.KnnHint - */ -class KnnHint extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectSearchService::initOnce(); - parent::__construct($data); - } - -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchResult.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchResult.php deleted file mode 100644 index 12f1790ab082..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SearchResult.php +++ /dev/null @@ -1,125 +0,0 @@ -google.cloud.vectorsearch.v1.SearchResult - */ -class SearchResult extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The matching data object. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.DataObject data_object = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $data_object = null; - /** - * Output only. Similarity distance or ranker score returned by - * BatchSearchDataObjects. - * - * Generated from protobuf field optional double distance = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $distance = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\VectorSearch\V1\DataObject $data_object - * Output only. The matching data object. - * @type float $distance - * Output only. Similarity distance or ranker score returned by - * BatchSearchDataObjects. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectSearchService::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The matching data object. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.DataObject data_object = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Cloud\VectorSearch\V1\DataObject|null - */ - public function getDataObject() - { - return $this->data_object; - } - - public function hasDataObject() - { - return isset($this->data_object); - } - - public function clearDataObject() - { - unset($this->data_object); - } - - /** - * Output only. The matching data object. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.DataObject data_object = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\VectorSearch\V1\DataObject $var - * @return $this - */ - public function setDataObject($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\DataObject::class); - $this->data_object = $var; - - return $this; - } - - /** - * Output only. Similarity distance or ranker score returned by - * BatchSearchDataObjects. - * - * Generated from protobuf field optional double distance = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return float - */ - public function getDistance() - { - return isset($this->distance) ? $this->distance : 0.0; - } - - public function hasDistance() - { - return isset($this->distance); - } - - public function clearDistance() - { - unset($this->distance); - } - - /** - * Output only. Similarity distance or ranker score returned by - * BatchSearchDataObjects. - * - * Generated from protobuf field optional double distance = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param float $var - * @return $this - */ - public function setDistance($var) - { - GPBUtil::checkDouble($var); - $this->distance = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SemanticSearch.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SemanticSearch.php deleted file mode 100644 index 4dfdde9fb02e..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SemanticSearch.php +++ /dev/null @@ -1,327 +0,0 @@ -google.cloud.vectorsearch.v1.SemanticSearch - */ -class SemanticSearch extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The query text, which is used to generate an embedding according - * to the embedding model specified in the collection config. - * - * Generated from protobuf field string search_text = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $search_text = ''; - /** - * Required. The vector field to search. - * - * Generated from protobuf field string search_field = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $search_field = ''; - /** - * Required. The task type of the query embedding. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.EmbeddingTaskType task_type = 5 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $task_type = 0; - /** - * Optional. The fields to return in the search results. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.OutputFields output_fields = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $output_fields = null; - /** - * Optional. A JSON filter expression, e.g. {"genre": {"$eq": "sci-fi"}}, - * represented as a google.protobuf.Struct. - * - * Generated from protobuf field .google.protobuf.Struct filter = 6 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $filter = null; - /** - * Optional. The number of data objects to return. - * - * Generated from protobuf field optional int32 top_k = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $top_k = null; - /** - * Optional. Sets the search hint. If no strategy is specified, the service - * will use an index if one is available, and fall back to KNN search - * otherwise. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.SearchHint search_hint = 7 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $search_hint = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $search_text - * Required. The query text, which is used to generate an embedding according - * to the embedding model specified in the collection config. - * @type string $search_field - * Required. The vector field to search. - * @type int $task_type - * Required. The task type of the query embedding. - * @type \Google\Cloud\VectorSearch\V1\OutputFields $output_fields - * Optional. The fields to return in the search results. - * @type \Google\Protobuf\Struct $filter - * Optional. A JSON filter expression, e.g. {"genre": {"$eq": "sci-fi"}}, - * represented as a google.protobuf.Struct. - * @type int $top_k - * Optional. The number of data objects to return. - * @type \Google\Cloud\VectorSearch\V1\SearchHint $search_hint - * Optional. Sets the search hint. If no strategy is specified, the service - * will use an index if one is available, and fall back to KNN search - * otherwise. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectSearchService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The query text, which is used to generate an embedding according - * to the embedding model specified in the collection config. - * - * Generated from protobuf field string search_text = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getSearchText() - { - return $this->search_text; - } - - /** - * Required. The query text, which is used to generate an embedding according - * to the embedding model specified in the collection config. - * - * Generated from protobuf field string search_text = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setSearchText($var) - { - GPBUtil::checkString($var, True); - $this->search_text = $var; - - return $this; - } - - /** - * Required. The vector field to search. - * - * Generated from protobuf field string search_field = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getSearchField() - { - return $this->search_field; - } - - /** - * Required. The vector field to search. - * - * Generated from protobuf field string search_field = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setSearchField($var) - { - GPBUtil::checkString($var, True); - $this->search_field = $var; - - return $this; - } - - /** - * Required. The task type of the query embedding. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.EmbeddingTaskType task_type = 5 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getTaskType() - { - return $this->task_type; - } - - /** - * Required. The task type of the query embedding. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.EmbeddingTaskType task_type = 5 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setTaskType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\VectorSearch\V1\EmbeddingTaskType::class); - $this->task_type = $var; - - return $this; - } - - /** - * Optional. The fields to return in the search results. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.OutputFields output_fields = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\VectorSearch\V1\OutputFields|null - */ - public function getOutputFields() - { - return $this->output_fields; - } - - public function hasOutputFields() - { - return isset($this->output_fields); - } - - public function clearOutputFields() - { - unset($this->output_fields); - } - - /** - * Optional. The fields to return in the search results. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.OutputFields output_fields = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\VectorSearch\V1\OutputFields $var - * @return $this - */ - public function setOutputFields($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\OutputFields::class); - $this->output_fields = $var; - - return $this; - } - - /** - * Optional. A JSON filter expression, e.g. {"genre": {"$eq": "sci-fi"}}, - * represented as a google.protobuf.Struct. - * - * Generated from protobuf field .google.protobuf.Struct filter = 6 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Struct|null - */ - public function getFilter() - { - return $this->filter; - } - - public function hasFilter() - { - return isset($this->filter); - } - - public function clearFilter() - { - unset($this->filter); - } - - /** - * Optional. A JSON filter expression, e.g. {"genre": {"$eq": "sci-fi"}}, - * represented as a google.protobuf.Struct. - * - * Generated from protobuf field .google.protobuf.Struct filter = 6 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Protobuf\Struct $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Struct::class); - $this->filter = $var; - - return $this; - } - - /** - * Optional. The number of data objects to return. - * - * Generated from protobuf field optional int32 top_k = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getTopK() - { - return isset($this->top_k) ? $this->top_k : 0; - } - - public function hasTopK() - { - return isset($this->top_k); - } - - public function clearTopK() - { - unset($this->top_k); - } - - /** - * Optional. The number of data objects to return. - * - * Generated from protobuf field optional int32 top_k = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setTopK($var) - { - GPBUtil::checkInt32($var); - $this->top_k = $var; - - return $this; - } - - /** - * Optional. Sets the search hint. If no strategy is specified, the service - * will use an index if one is available, and fall back to KNN search - * otherwise. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.SearchHint search_hint = 7 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\VectorSearch\V1\SearchHint|null - */ - public function getSearchHint() - { - return $this->search_hint; - } - - public function hasSearchHint() - { - return isset($this->search_hint); - } - - public function clearSearchHint() - { - unset($this->search_hint); - } - - /** - * Optional. Sets the search hint. If no strategy is specified, the service - * will use an index if one is available, and fall back to KNN search - * otherwise. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.SearchHint search_hint = 7 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\VectorSearch\V1\SearchHint $var - * @return $this - */ - public function setSearchHint($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\SearchHint::class); - $this->search_hint = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SparseVector.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SparseVector.php deleted file mode 100644 index 21af72420f0c..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SparseVector.php +++ /dev/null @@ -1,101 +0,0 @@ -google.cloud.vectorsearch.v1.SparseVector - */ -class SparseVector extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The values of the vector. - * - * Generated from protobuf field repeated float values = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - private $values; - /** - * Required. The corresponding indices for the values. - * - * Generated from protobuf field repeated int32 indices = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - private $indices; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type float[] $values - * Required. The values of the vector. - * @type int[] $indices - * Required. The corresponding indices for the values. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObject::initOnce(); - parent::__construct($data); - } - - /** - * Required. The values of the vector. - * - * Generated from protobuf field repeated float values = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return RepeatedField - */ - public function getValues() - { - return $this->values; - } - - /** - * Required. The values of the vector. - * - * Generated from protobuf field repeated float values = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param float[] $var - * @return $this - */ - public function setValues($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::FLOAT); - $this->values = $arr; - - return $this; - } - - /** - * Required. The corresponding indices for the values. - * - * Generated from protobuf field repeated int32 indices = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return RepeatedField - */ - public function getIndices() - { - return $this->indices; - } - - /** - * Required. The corresponding indices for the values. - * - * Generated from protobuf field repeated int32 indices = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param int[] $var - * @return $this - */ - public function setIndices($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::INT32); - $this->indices = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SparseVectorField.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SparseVectorField.php deleted file mode 100644 index 65c8ffdbca52..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/SparseVectorField.php +++ /dev/null @@ -1,33 +0,0 @@ -google.cloud.vectorsearch.v1.SparseVectorField - */ -class SparseVectorField extends \Google\Protobuf\Internal\Message -{ - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\VectorsearchService::initOnce(); - parent::__construct($data); - } - -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/TextSearch.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/TextSearch.php deleted file mode 100644 index 60bd53821ac3..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/TextSearch.php +++ /dev/null @@ -1,237 +0,0 @@ -google.cloud.vectorsearch.v1.TextSearch - */ -class TextSearch extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The query text. - * - * Generated from protobuf field string search_text = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $search_text = ''; - /** - * Required. The data field names to search. - * - * Generated from protobuf field repeated string data_field_names = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - private $data_field_names; - /** - * Optional. The fields to return in the search results. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.OutputFields output_fields = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $output_fields = null; - /** - * Optional. The number of results to return. - * - * Generated from protobuf field optional int32 top_k = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $top_k = null; - /** - * Optional. A JSON filter expression, e.g. `{"genre": {"$eq": "sci-fi"}}`, - * represented as a `google.protobuf.Struct`. - * - * Generated from protobuf field .google.protobuf.Struct filter = 5 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $filter = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $search_text - * Required. The query text. - * @type string[] $data_field_names - * Required. The data field names to search. - * @type \Google\Cloud\VectorSearch\V1\OutputFields $output_fields - * Optional. The fields to return in the search results. - * @type int $top_k - * Optional. The number of results to return. - * @type \Google\Protobuf\Struct $filter - * Optional. A JSON filter expression, e.g. `{"genre": {"$eq": "sci-fi"}}`, - * represented as a `google.protobuf.Struct`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectSearchService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The query text. - * - * Generated from protobuf field string search_text = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getSearchText() - { - return $this->search_text; - } - - /** - * Required. The query text. - * - * Generated from protobuf field string search_text = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setSearchText($var) - { - GPBUtil::checkString($var, True); - $this->search_text = $var; - - return $this; - } - - /** - * Required. The data field names to search. - * - * Generated from protobuf field repeated string data_field_names = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return RepeatedField - */ - public function getDataFieldNames() - { - return $this->data_field_names; - } - - /** - * Required. The data field names to search. - * - * Generated from protobuf field repeated string data_field_names = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string[] $var - * @return $this - */ - public function setDataFieldNames($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->data_field_names = $arr; - - return $this; - } - - /** - * Optional. The fields to return in the search results. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.OutputFields output_fields = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\VectorSearch\V1\OutputFields|null - */ - public function getOutputFields() - { - return $this->output_fields; - } - - public function hasOutputFields() - { - return isset($this->output_fields); - } - - public function clearOutputFields() - { - unset($this->output_fields); - } - - /** - * Optional. The fields to return in the search results. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.OutputFields output_fields = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\VectorSearch\V1\OutputFields $var - * @return $this - */ - public function setOutputFields($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\OutputFields::class); - $this->output_fields = $var; - - return $this; - } - - /** - * Optional. The number of results to return. - * - * Generated from protobuf field optional int32 top_k = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getTopK() - { - return isset($this->top_k) ? $this->top_k : 0; - } - - public function hasTopK() - { - return isset($this->top_k); - } - - public function clearTopK() - { - unset($this->top_k); - } - - /** - * Optional. The number of results to return. - * - * Generated from protobuf field optional int32 top_k = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setTopK($var) - { - GPBUtil::checkInt32($var); - $this->top_k = $var; - - return $this; - } - - /** - * Optional. A JSON filter expression, e.g. `{"genre": {"$eq": "sci-fi"}}`, - * represented as a `google.protobuf.Struct`. - * - * Generated from protobuf field .google.protobuf.Struct filter = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Struct|null - */ - public function getFilter() - { - return $this->filter; - } - - public function hasFilter() - { - return isset($this->filter); - } - - public function clearFilter() - { - unset($this->filter); - } - - /** - * Optional. A JSON filter expression, e.g. `{"genre": {"$eq": "sci-fi"}}`, - * represented as a `google.protobuf.Struct`. - * - * Generated from protobuf field .google.protobuf.Struct filter = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Protobuf\Struct $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Struct::class); - $this->filter = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/UpdateCollectionRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/UpdateCollectionRequest.php deleted file mode 100644 index 2aa5781afe3c..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/UpdateCollectionRequest.php +++ /dev/null @@ -1,282 +0,0 @@ -google.cloud.vectorsearch.v1.UpdateCollectionRequest - */ -class UpdateCollectionRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. Field mask is used to specify the fields to be overwritten in the - * Collection 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 present in the request will be - * overwritten. - * The following fields support update: `display_name`, `description`, - * `labels`, `data_schema`, `vector_schema`. - * For `data_schema` and `vector_schema`, fields can only be added, not - * deleted, but `vertex_embedding_config` in `vector_schema` can be added or - * removed. - * Partial updates for `data_schema` and `vector_schema` are also supported - * by using sub-field paths in `update_mask`, e.g. - * `data_schema.properties.foo` or `vector_schema.my_vector_field`. - * If `*` is provided in the update_mask, full replacement will be performed. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $update_mask = null; - /** - * Required. The resource being updated - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.Collection collection = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $collection = 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 = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { - */ - protected $request_id = ''; - - /** - * @param \Google\Cloud\VectorSearch\V1\Collection $collection Required. The resource being updated - * @param \Google\Protobuf\FieldMask $updateMask Optional. Field mask is used to specify the fields to be overwritten in the - * Collection 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 present in the request will be - * overwritten. - * - * The following fields support update: `display_name`, `description`, - * `labels`, `data_schema`, `vector_schema`. - * For `data_schema` and `vector_schema`, fields can only be added, not - * deleted, but `vertex_embedding_config` in `vector_schema` can be added or - * removed. - * Partial updates for `data_schema` and `vector_schema` are also supported - * by using sub-field paths in `update_mask`, e.g. - * `data_schema.properties.foo` or `vector_schema.my_vector_field`. - * - * If `*` is provided in the update_mask, full replacement will be performed. - * - * @return \Google\Cloud\VectorSearch\V1\UpdateCollectionRequest - * - * @experimental - */ - public static function build(\Google\Cloud\VectorSearch\V1\Collection $collection, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setCollection($collection) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Protobuf\FieldMask $update_mask - * Optional. Field mask is used to specify the fields to be overwritten in the - * Collection 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 present in the request will be - * overwritten. - * The following fields support update: `display_name`, `description`, - * `labels`, `data_schema`, `vector_schema`. - * For `data_schema` and `vector_schema`, fields can only be added, not - * deleted, but `vertex_embedding_config` in `vector_schema` can be added or - * removed. - * Partial updates for `data_schema` and `vector_schema` are also supported - * by using sub-field paths in `update_mask`, e.g. - * `data_schema.properties.foo` or `vector_schema.my_vector_field`. - * If `*` is provided in the update_mask, full replacement will be performed. - * @type \Google\Cloud\VectorSearch\V1\Collection $collection - * 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 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\Vectorsearch\V1\VectorsearchService::initOnce(); - parent::__construct($data); - } - - /** - * Optional. Field mask is used to specify the fields to be overwritten in the - * Collection 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 present in the request will be - * overwritten. - * The following fields support update: `display_name`, `description`, - * `labels`, `data_schema`, `vector_schema`. - * For `data_schema` and `vector_schema`, fields can only be added, not - * deleted, but `vertex_embedding_config` in `vector_schema` can be added or - * removed. - * Partial updates for `data_schema` and `vector_schema` are also supported - * by using sub-field paths in `update_mask`, e.g. - * `data_schema.properties.foo` or `vector_schema.my_vector_field`. - * If `*` is provided in the update_mask, full replacement will be performed. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @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); - } - - /** - * Optional. Field mask is used to specify the fields to be overwritten in the - * Collection 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 present in the request will be - * overwritten. - * The following fields support update: `display_name`, `description`, - * `labels`, `data_schema`, `vector_schema`. - * For `data_schema` and `vector_schema`, fields can only be added, not - * deleted, but `vertex_embedding_config` in `vector_schema` can be added or - * removed. - * Partial updates for `data_schema` and `vector_schema` are also supported - * by using sub-field paths in `update_mask`, e.g. - * `data_schema.properties.foo` or `vector_schema.my_vector_field`. - * If `*` is provided in the update_mask, full replacement will be performed. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @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.vectorsearch.v1.Collection collection = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\VectorSearch\V1\Collection|null - */ - public function getCollection() - { - return $this->collection; - } - - public function hasCollection() - { - return isset($this->collection); - } - - public function clearCollection() - { - unset($this->collection); - } - - /** - * Required. The resource being updated - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.Collection collection = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\VectorSearch\V1\Collection $var - * @return $this - */ - public function setCollection($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\Collection::class); - $this->collection = $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 = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { - * @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 = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { - * @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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/UpdateDataObjectRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/UpdateDataObjectRequest.php deleted file mode 100644 index f69018d6edde..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/UpdateDataObjectRequest.php +++ /dev/null @@ -1,142 +0,0 @@ -google.cloud.vectorsearch.v1.UpdateDataObjectRequest - */ -class UpdateDataObjectRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The DataObject which replaces the resource on the server. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.DataObject data_object = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $data_object = null; - /** - * Optional. The update mask applies to the resource. See - * [google.protobuf.FieldMask][google.protobuf.FieldMask]. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $update_mask = null; - - /** - * @param \Google\Cloud\VectorSearch\V1\DataObject $dataObject Required. The DataObject which replaces the resource on the server. - * @param \Google\Protobuf\FieldMask $updateMask Optional. The update mask applies to the resource. See - * [google.protobuf.FieldMask][google.protobuf.FieldMask]. - * - * @return \Google\Cloud\VectorSearch\V1\UpdateDataObjectRequest - * - * @experimental - */ - public static function build(\Google\Cloud\VectorSearch\V1\DataObject $dataObject, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setDataObject($dataObject) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\VectorSearch\V1\DataObject $data_object - * Required. The DataObject which replaces the resource on the server. - * @type \Google\Protobuf\FieldMask $update_mask - * Optional. The update mask applies to the resource. See - * [google.protobuf.FieldMask][google.protobuf.FieldMask]. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The DataObject which replaces the resource on the server. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.DataObject data_object = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\VectorSearch\V1\DataObject|null - */ - public function getDataObject() - { - return $this->data_object; - } - - public function hasDataObject() - { - return isset($this->data_object); - } - - public function clearDataObject() - { - unset($this->data_object); - } - - /** - * Required. The DataObject which replaces the resource on the server. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.DataObject data_object = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\VectorSearch\V1\DataObject $var - * @return $this - */ - public function setDataObject($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\DataObject::class); - $this->data_object = $var; - - return $this; - } - - /** - * Optional. The update mask applies to the resource. See - * [google.protobuf.FieldMask][google.protobuf.FieldMask]. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @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); - } - - /** - * Optional. The update mask applies to the resource. See - * [google.protobuf.FieldMask][google.protobuf.FieldMask]. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/UpdateIndexRequest.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/UpdateIndexRequest.php deleted file mode 100644 index 5591f43847a6..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/UpdateIndexRequest.php +++ /dev/null @@ -1,272 +0,0 @@ -google.cloud.vectorsearch.v1.UpdateIndexRequest - */ -class UpdateIndexRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource being updated. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.Index index = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $index = null; - /** - * Optional. Specifies the fields to be overwritten in the Index 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 present in the - * request with non-empty values will be overwritten. - * The following fields support update: - * * `display_name` - * * `description` - * * `labels` - * * `dedicated_infrastructure.autoscaling_spec.min_replica_count` - * * `dedicated_infrastructure.autoscaling_spec.max_replica_count` - * If `*` is provided in the `update_mask`, full replacement of mutable fields - * will be performed. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $update_mask = 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 = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { - */ - protected $request_id = ''; - - /** - * @param \Google\Cloud\VectorSearch\V1\Index $index Required. The resource being updated. - * @param \Google\Protobuf\FieldMask $updateMask Optional. Specifies the fields to be overwritten in the Index 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 present in the - * request with non-empty values will be overwritten. - * - * The following fields support update: - * * `display_name` - * * `description` - * * `labels` - * * `dedicated_infrastructure.autoscaling_spec.min_replica_count` - * * `dedicated_infrastructure.autoscaling_spec.max_replica_count` - * - * If `*` is provided in the `update_mask`, full replacement of mutable fields - * will be performed. - * - * @return \Google\Cloud\VectorSearch\V1\UpdateIndexRequest - * - * @experimental - */ - public static function build(\Google\Cloud\VectorSearch\V1\Index $index, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setIndex($index) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\VectorSearch\V1\Index $index - * Required. The resource being updated. - * @type \Google\Protobuf\FieldMask $update_mask - * Optional. Specifies the fields to be overwritten in the Index 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 present in the - * request with non-empty values will be overwritten. - * The following fields support update: - * * `display_name` - * * `description` - * * `labels` - * * `dedicated_infrastructure.autoscaling_spec.min_replica_count` - * * `dedicated_infrastructure.autoscaling_spec.max_replica_count` - * If `*` is provided in the `update_mask`, full replacement of mutable fields - * will be performed. - * @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\Vectorsearch\V1\VectorsearchService::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource being updated. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.Index index = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\VectorSearch\V1\Index|null - */ - public function getIndex() - { - return $this->index; - } - - public function hasIndex() - { - return isset($this->index); - } - - public function clearIndex() - { - unset($this->index); - } - - /** - * Required. The resource being updated. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.Index index = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\VectorSearch\V1\Index $var - * @return $this - */ - public function setIndex($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\Index::class); - $this->index = $var; - - return $this; - } - - /** - * Optional. Specifies the fields to be overwritten in the Index 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 present in the - * request with non-empty values will be overwritten. - * The following fields support update: - * * `display_name` - * * `description` - * * `labels` - * * `dedicated_infrastructure.autoscaling_spec.min_replica_count` - * * `dedicated_infrastructure.autoscaling_spec.max_replica_count` - * If `*` is provided in the `update_mask`, full replacement of mutable fields - * will be performed. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @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); - } - - /** - * Optional. Specifies the fields to be overwritten in the Index 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 present in the - * request with non-empty values will be overwritten. - * The following fields support update: - * * `display_name` - * * `description` - * * `labels` - * * `dedicated_infrastructure.autoscaling_spec.min_replica_count` - * * `dedicated_infrastructure.autoscaling_spec.max_replica_count` - * If `*` is provided in the `update_mask`, full replacement of mutable fields - * will be performed. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Protobuf\FieldMask $var - * @return $this - */ - public function setUpdateMask($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\FieldMask::class); - $this->update_mask = $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 = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { - * @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 = 3 [(.google.api.field_behavior) = OPTIONAL, (.google.api.field_info) = { - * @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/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/Vector.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/Vector.php deleted file mode 100644 index a05fb25b7172..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/Vector.php +++ /dev/null @@ -1,108 +0,0 @@ -google.cloud.vectorsearch.v1.Vector - */ -class Vector extends \Google\Protobuf\Internal\Message -{ - protected $vector_type; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\VectorSearch\V1\DenseVector $dense - * A dense vector. - * @type \Google\Cloud\VectorSearch\V1\SparseVector $sparse - * A sparse vector. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObject::initOnce(); - parent::__construct($data); - } - - /** - * A dense vector. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.DenseVector dense = 2; - * @return \Google\Cloud\VectorSearch\V1\DenseVector|null - */ - public function getDense() - { - return $this->readOneof(2); - } - - public function hasDense() - { - return $this->hasOneof(2); - } - - /** - * A dense vector. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.DenseVector dense = 2; - * @param \Google\Cloud\VectorSearch\V1\DenseVector $var - * @return $this - */ - public function setDense($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\DenseVector::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * A sparse vector. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.SparseVector sparse = 3; - * @return \Google\Cloud\VectorSearch\V1\SparseVector|null - */ - public function getSparse() - { - return $this->readOneof(3); - } - - public function hasSparse() - { - return $this->hasOneof(3); - } - - /** - * A sparse vector. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.SparseVector sparse = 3; - * @param \Google\Cloud\VectorSearch\V1\SparseVector $var - * @return $this - */ - public function setSparse($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\SparseVector::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * @return string - */ - public function getVectorType() - { - return $this->whichOneof("vector_type"); - } - -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/VectorField.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/VectorField.php deleted file mode 100644 index dfcb5f2c5683..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/VectorField.php +++ /dev/null @@ -1,108 +0,0 @@ -google.cloud.vectorsearch.v1.VectorField - */ -class VectorField extends \Google\Protobuf\Internal\Message -{ - protected $vector_type_config; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\VectorSearch\V1\DenseVectorField $dense_vector - * Dense vector field. - * @type \Google\Cloud\VectorSearch\V1\SparseVectorField $sparse_vector - * Sparse vector field. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\VectorsearchService::initOnce(); - parent::__construct($data); - } - - /** - * Dense vector field. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.DenseVectorField dense_vector = 3; - * @return \Google\Cloud\VectorSearch\V1\DenseVectorField|null - */ - public function getDenseVector() - { - return $this->readOneof(3); - } - - public function hasDenseVector() - { - return $this->hasOneof(3); - } - - /** - * Dense vector field. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.DenseVectorField dense_vector = 3; - * @param \Google\Cloud\VectorSearch\V1\DenseVectorField $var - * @return $this - */ - public function setDenseVector($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\DenseVectorField::class); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * Sparse vector field. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.SparseVectorField sparse_vector = 4; - * @return \Google\Cloud\VectorSearch\V1\SparseVectorField|null - */ - public function getSparseVector() - { - return $this->readOneof(4); - } - - public function hasSparseVector() - { - return $this->hasOneof(4); - } - - /** - * Sparse vector field. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.SparseVectorField sparse_vector = 4; - * @param \Google\Cloud\VectorSearch\V1\SparseVectorField $var - * @return $this - */ - public function setSparseVector($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\SparseVectorField::class); - $this->writeOneof(4, $var); - - return $this; - } - - /** - * @return string - */ - public function getVectorTypeConfig() - { - return $this->whichOneof("vector_type_config"); - } - -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/VectorSearch.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/VectorSearch.php deleted file mode 100644 index c068f2a4e9d3..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/VectorSearch.php +++ /dev/null @@ -1,368 +0,0 @@ -google.cloud.vectorsearch.v1.VectorSearch - */ -class VectorSearch extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The vector field to search. - * - * Generated from protobuf field string search_field = 8 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $search_field = ''; - /** - * Optional. A JSON filter expression, e.g. {"genre": {"$eq": "sci-fi"}}, - * represented as a google.protobuf.Struct. - * - * Generated from protobuf field .google.protobuf.Struct filter = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $filter = null; - /** - * Optional. The number of nearest neighbors to return. - * - * Generated from protobuf field optional int32 top_k = 5 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $top_k = null; - /** - * Optional. Mask specifying which fields to return. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.OutputFields output_fields = 7 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $output_fields = null; - /** - * Optional. Sets the search hint. If no strategy is specified, the service - * will use an index if one is available, and fall back to the default KNN - * search otherwise. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.SearchHint search_hint = 9 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $search_hint = null; - /** - * Optional. The distance metric to use for the KNN search. If not specified, - * DOT_PRODUCT will be used as the default. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.DistanceMetric distance_metric = 11 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $distance_metric = 0; - protected $vector_type; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\VectorSearch\V1\DenseVector $vector - * A dense vector for the query. - * @type \Google\Cloud\VectorSearch\V1\SparseVector $sparse_vector - * A sparse vector for the query. - * @type string $search_field - * Required. The vector field to search. - * @type \Google\Protobuf\Struct $filter - * Optional. A JSON filter expression, e.g. {"genre": {"$eq": "sci-fi"}}, - * represented as a google.protobuf.Struct. - * @type int $top_k - * Optional. The number of nearest neighbors to return. - * @type \Google\Cloud\VectorSearch\V1\OutputFields $output_fields - * Optional. Mask specifying which fields to return. - * @type \Google\Cloud\VectorSearch\V1\SearchHint $search_hint - * Optional. Sets the search hint. If no strategy is specified, the service - * will use an index if one is available, and fall back to the default KNN - * search otherwise. - * @type int $distance_metric - * Optional. The distance metric to use for the KNN search. If not specified, - * DOT_PRODUCT will be used as the default. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\DataObjectSearchService::initOnce(); - parent::__construct($data); - } - - /** - * A dense vector for the query. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.DenseVector vector = 1; - * @return \Google\Cloud\VectorSearch\V1\DenseVector|null - */ - public function getVector() - { - return $this->readOneof(1); - } - - public function hasVector() - { - return $this->hasOneof(1); - } - - /** - * A dense vector for the query. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.DenseVector vector = 1; - * @param \Google\Cloud\VectorSearch\V1\DenseVector $var - * @return $this - */ - public function setVector($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\DenseVector::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * A sparse vector for the query. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.SparseVector sparse_vector = 2; - * @return \Google\Cloud\VectorSearch\V1\SparseVector|null - */ - public function getSparseVector() - { - return $this->readOneof(2); - } - - public function hasSparseVector() - { - return $this->hasOneof(2); - } - - /** - * A sparse vector for the query. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.SparseVector sparse_vector = 2; - * @param \Google\Cloud\VectorSearch\V1\SparseVector $var - * @return $this - */ - public function setSparseVector($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\SparseVector::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * Required. The vector field to search. - * - * Generated from protobuf field string search_field = 8 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getSearchField() - { - return $this->search_field; - } - - /** - * Required. The vector field to search. - * - * Generated from protobuf field string search_field = 8 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setSearchField($var) - { - GPBUtil::checkString($var, True); - $this->search_field = $var; - - return $this; - } - - /** - * Optional. A JSON filter expression, e.g. {"genre": {"$eq": "sci-fi"}}, - * represented as a google.protobuf.Struct. - * - * Generated from protobuf field .google.protobuf.Struct filter = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Struct|null - */ - public function getFilter() - { - return $this->filter; - } - - public function hasFilter() - { - return isset($this->filter); - } - - public function clearFilter() - { - unset($this->filter); - } - - /** - * Optional. A JSON filter expression, e.g. {"genre": {"$eq": "sci-fi"}}, - * represented as a google.protobuf.Struct. - * - * Generated from protobuf field .google.protobuf.Struct filter = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Protobuf\Struct $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Struct::class); - $this->filter = $var; - - return $this; - } - - /** - * Optional. The number of nearest neighbors to return. - * - * Generated from protobuf field optional int32 top_k = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getTopK() - { - return isset($this->top_k) ? $this->top_k : 0; - } - - public function hasTopK() - { - return isset($this->top_k); - } - - public function clearTopK() - { - unset($this->top_k); - } - - /** - * Optional. The number of nearest neighbors to return. - * - * Generated from protobuf field optional int32 top_k = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setTopK($var) - { - GPBUtil::checkInt32($var); - $this->top_k = $var; - - return $this; - } - - /** - * Optional. Mask specifying which fields to return. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.OutputFields output_fields = 7 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\VectorSearch\V1\OutputFields|null - */ - public function getOutputFields() - { - return $this->output_fields; - } - - public function hasOutputFields() - { - return isset($this->output_fields); - } - - public function clearOutputFields() - { - unset($this->output_fields); - } - - /** - * Optional. Mask specifying which fields to return. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.OutputFields output_fields = 7 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\VectorSearch\V1\OutputFields $var - * @return $this - */ - public function setOutputFields($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\OutputFields::class); - $this->output_fields = $var; - - return $this; - } - - /** - * Optional. Sets the search hint. If no strategy is specified, the service - * will use an index if one is available, and fall back to the default KNN - * search otherwise. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.SearchHint search_hint = 9 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\VectorSearch\V1\SearchHint|null - */ - public function getSearchHint() - { - return $this->search_hint; - } - - public function hasSearchHint() - { - return isset($this->search_hint); - } - - public function clearSearchHint() - { - unset($this->search_hint); - } - - /** - * Optional. Sets the search hint. If no strategy is specified, the service - * will use an index if one is available, and fall back to the default KNN - * search otherwise. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.SearchHint search_hint = 9 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\VectorSearch\V1\SearchHint $var - * @return $this - */ - public function setSearchHint($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VectorSearch\V1\SearchHint::class); - $this->search_hint = $var; - - return $this; - } - - /** - * Optional. The distance metric to use for the KNN search. If not specified, - * DOT_PRODUCT will be used as the default. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.DistanceMetric distance_metric = 11 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getDistanceMetric() - { - return $this->distance_metric; - } - - /** - * Optional. The distance metric to use for the KNN search. If not specified, - * DOT_PRODUCT will be used as the default. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.DistanceMetric distance_metric = 11 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setDistanceMetric($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\VectorSearch\V1\DistanceMetric::class); - $this->distance_metric = $var; - - return $this; - } - - /** - * @return string - */ - public function getVectorType() - { - return $this->whichOneof("vector_type"); - } - -} - diff --git a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/VertexEmbeddingConfig.php b/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/VertexEmbeddingConfig.php deleted file mode 100644 index 441e52948d3e..000000000000 --- a/owl-bot-staging/VectorSearch/v1/proto/src/Google/Cloud/VectorSearch/V1/VertexEmbeddingConfig.php +++ /dev/null @@ -1,152 +0,0 @@ -google.cloud.vectorsearch.v1.VertexEmbeddingConfig - */ -class VertexEmbeddingConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Required: ID of the embedding model to use. See - * https://cloud.google.com/vertex-ai/generative-ai/docs/learn/models#embeddings-models - * for the list of supported models. - * - * Generated from protobuf field string model_id = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $model_id = ''; - /** - * Required. Required: Text template for the input to the model. The template - * must contain one or more references to fields in the DataObject, e.g.: - * "Movie Title: {title} ---- Movie Plot: {plot}". - * - * Generated from protobuf field string text_template = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $text_template = ''; - /** - * Required. Required: Task type for the embeddings. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.EmbeddingTaskType task_type = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $task_type = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $model_id - * Required. Required: ID of the embedding model to use. See - * https://cloud.google.com/vertex-ai/generative-ai/docs/learn/models#embeddings-models - * for the list of supported models. - * @type string $text_template - * Required. Required: Text template for the input to the model. The template - * must contain one or more references to fields in the DataObject, e.g.: - * "Movie Title: {title} ---- Movie Plot: {plot}". - * @type int $task_type - * Required. Required: Task type for the embeddings. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vectorsearch\V1\EmbeddingConfig::initOnce(); - parent::__construct($data); - } - - /** - * Required. Required: ID of the embedding model to use. See - * https://cloud.google.com/vertex-ai/generative-ai/docs/learn/models#embeddings-models - * for the list of supported models. - * - * Generated from protobuf field string model_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getModelId() - { - return $this->model_id; - } - - /** - * Required. Required: ID of the embedding model to use. See - * https://cloud.google.com/vertex-ai/generative-ai/docs/learn/models#embeddings-models - * for the list of supported models. - * - * Generated from protobuf field string model_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setModelId($var) - { - GPBUtil::checkString($var, True); - $this->model_id = $var; - - return $this; - } - - /** - * Required. Required: Text template for the input to the model. The template - * must contain one or more references to fields in the DataObject, e.g.: - * "Movie Title: {title} ---- Movie Plot: {plot}". - * - * Generated from protobuf field string text_template = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getTextTemplate() - { - return $this->text_template; - } - - /** - * Required. Required: Text template for the input to the model. The template - * must contain one or more references to fields in the DataObject, e.g.: - * "Movie Title: {title} ---- Movie Plot: {plot}". - * - * Generated from protobuf field string text_template = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setTextTemplate($var) - { - GPBUtil::checkString($var, True); - $this->text_template = $var; - - return $this; - } - - /** - * Required. Required: Task type for the embeddings. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.EmbeddingTaskType task_type = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getTaskType() - { - return $this->task_type; - } - - /** - * Required. Required: Task type for the embeddings. - * - * Generated from protobuf field .google.cloud.vectorsearch.v1.EmbeddingTaskType task_type = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setTaskType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\VectorSearch\V1\EmbeddingTaskType::class); - $this->task_type = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/aggregate_data_objects.php b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/aggregate_data_objects.php deleted file mode 100644 index 901f38ec5006..000000000000 --- a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/aggregate_data_objects.php +++ /dev/null @@ -1,80 +0,0 @@ -setParent($formattedParent) - ->setAggregate($aggregate); - - // Call the API and handle any network failures. - try { - /** @var AggregateDataObjectsResponse $response */ - $response = $dataObjectSearchServiceClient->aggregateDataObjects($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 = DataObjectSearchServiceClient::collectionName( - '[PROJECT]', - '[LOCATION]', - '[COLLECTION]' - ); - $aggregate = AggregationMethod::AGGREGATION_METHOD_UNSPECIFIED; - - aggregate_data_objects_sample($formattedParent, $aggregate); -} -// [END vectorsearch_v1_generated_DataObjectSearchService_AggregateDataObjects_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/batch_search_data_objects.php b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/batch_search_data_objects.php deleted file mode 100644 index f4c1b6907b50..000000000000 --- a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/batch_search_data_objects.php +++ /dev/null @@ -1,79 +0,0 @@ -setParent($formattedParent) - ->setSearches($searches); - - // Call the API and handle any network failures. - try { - /** @var BatchSearchDataObjectsResponse $response */ - $response = $dataObjectSearchServiceClient->batchSearchDataObjects($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 = DataObjectSearchServiceClient::collectionName( - '[PROJECT]', - '[LOCATION]', - '[COLLECTION]' - ); - - batch_search_data_objects_sample($formattedParent); -} -// [END vectorsearch_v1_generated_DataObjectSearchService_BatchSearchDataObjects_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/get_location.php b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/get_location.php deleted file mode 100644 index 4dd8d9aff4a8..000000000000 --- a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/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 vectorsearch_v1_generated_DataObjectSearchService_GetLocation_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/list_locations.php b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/list_locations.php deleted file mode 100644 index 65a26d857a7f..000000000000 --- a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/list_locations.php +++ /dev/null @@ -1,78 +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 vectorsearch_v1_generated_DataObjectSearchService_ListLocations_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/query_data_objects.php b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/query_data_objects.php deleted file mode 100644 index 84e7266cbc2e..000000000000 --- a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/query_data_objects.php +++ /dev/null @@ -1,81 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $dataObjectSearchServiceClient->queryDataObjects($request); - - /** @var DataObject $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 = DataObjectSearchServiceClient::collectionName( - '[PROJECT]', - '[LOCATION]', - '[COLLECTION]' - ); - - query_data_objects_sample($formattedParent); -} -// [END vectorsearch_v1_generated_DataObjectSearchService_QueryDataObjects_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/search_data_objects.php b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/search_data_objects.php deleted file mode 100644 index 1b87176767b6..000000000000 --- a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectSearchServiceClient/search_data_objects.php +++ /dev/null @@ -1,81 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $dataObjectSearchServiceClient->searchDataObjects($request); - - /** @var SearchResult $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 = DataObjectSearchServiceClient::collectionName( - '[PROJECT]', - '[LOCATION]', - '[COLLECTION]' - ); - - search_data_objects_sample($formattedParent); -} -// [END vectorsearch_v1_generated_DataObjectSearchService_SearchDataObjects_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/batch_create_data_objects.php b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/batch_create_data_objects.php deleted file mode 100644 index 03b5d12f1736..000000000000 --- a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/batch_create_data_objects.php +++ /dev/null @@ -1,104 +0,0 @@ -setParent($formattedRequestsParent) - ->setDataObjectId($requestsDataObjectId) - ->setDataObject($requestsDataObject); - $requests = [$createDataObjectRequest,]; - $request = (new BatchCreateDataObjectsRequest()) - ->setParent($formattedParent) - ->setRequests($requests); - - // Call the API and handle any network failures. - try { - /** @var BatchCreateDataObjectsResponse $response */ - $response = $dataObjectServiceClient->batchCreateDataObjects($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 = DataObjectServiceClient::collectionName( - '[PROJECT]', - '[LOCATION]', - '[COLLECTION]' - ); - $formattedRequestsParent = DataObjectServiceClient::collectionName( - '[PROJECT]', - '[LOCATION]', - '[COLLECTION]' - ); - $requestsDataObjectId = '[DATA_OBJECT_ID]'; - - batch_create_data_objects_sample($formattedParent, $formattedRequestsParent, $requestsDataObjectId); -} -// [END vectorsearch_v1_generated_DataObjectService_BatchCreateDataObjects_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/batch_delete_data_objects.php b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/batch_delete_data_objects.php deleted file mode 100644 index 9bcdc587e81d..000000000000 --- a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/batch_delete_data_objects.php +++ /dev/null @@ -1,91 +0,0 @@ -setName($formattedRequestsName); - $requests = [$deleteDataObjectRequest,]; - $request = (new BatchDeleteDataObjectsRequest()) - ->setParent($formattedParent) - ->setRequests($requests); - - // Call the API and handle any network failures. - try { - $dataObjectServiceClient->batchDeleteDataObjects($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 -{ - $formattedParent = DataObjectServiceClient::collectionName( - '[PROJECT]', - '[LOCATION]', - '[COLLECTION]' - ); - $formattedRequestsName = DataObjectServiceClient::dataObjectName( - '[PROJECT]', - '[LOCATION]', - '[COLLECTION]', - '[DATAOBJECT]' - ); - - batch_delete_data_objects_sample($formattedParent, $formattedRequestsName); -} -// [END vectorsearch_v1_generated_DataObjectService_BatchDeleteDataObjects_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/batch_update_data_objects.php b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/batch_update_data_objects.php deleted file mode 100644 index 148400e360b5..000000000000 --- a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/batch_update_data_objects.php +++ /dev/null @@ -1,85 +0,0 @@ -setDataObject($requestsDataObject); - $requests = [$updateDataObjectRequest,]; - $request = (new BatchUpdateDataObjectsRequest()) - ->setParent($formattedParent) - ->setRequests($requests); - - // Call the API and handle any network failures. - try { - /** @var BatchUpdateDataObjectsResponse $response */ - $response = $dataObjectServiceClient->batchUpdateDataObjects($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 = DataObjectServiceClient::collectionName( - '[PROJECT]', - '[LOCATION]', - '[COLLECTION]' - ); - - batch_update_data_objects_sample($formattedParent); -} -// [END vectorsearch_v1_generated_DataObjectService_BatchUpdateDataObjects_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/create_data_object.php b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/create_data_object.php deleted file mode 100644 index 0adc95b4be0a..000000000000 --- a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/create_data_object.php +++ /dev/null @@ -1,85 +0,0 @@ -setParent($formattedParent) - ->setDataObjectId($dataObjectId) - ->setDataObject($dataObject); - - // Call the API and handle any network failures. - try { - /** @var DataObject $response */ - $response = $dataObjectServiceClient->createDataObject($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 = DataObjectServiceClient::collectionName( - '[PROJECT]', - '[LOCATION]', - '[COLLECTION]' - ); - $dataObjectId = '[DATA_OBJECT_ID]'; - - create_data_object_sample($formattedParent, $dataObjectId); -} -// [END vectorsearch_v1_generated_DataObjectService_CreateDataObject_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/delete_data_object.php b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/delete_data_object.php deleted file mode 100644 index 1f544ed85ecc..000000000000 --- a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/delete_data_object.php +++ /dev/null @@ -1,76 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - $dataObjectServiceClient->deleteDataObject($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 = DataObjectServiceClient::dataObjectName( - '[PROJECT]', - '[LOCATION]', - '[COLLECTION]', - '[DATAOBJECT]' - ); - - delete_data_object_sample($formattedName); -} -// [END vectorsearch_v1_generated_DataObjectService_DeleteDataObject_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/get_data_object.php b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/get_data_object.php deleted file mode 100644 index c9998dfb9cd8..000000000000 --- a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/get_data_object.php +++ /dev/null @@ -1,78 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var DataObject $response */ - $response = $dataObjectServiceClient->getDataObject($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 = DataObjectServiceClient::dataObjectName( - '[PROJECT]', - '[LOCATION]', - '[COLLECTION]', - '[DATAOBJECT]' - ); - - get_data_object_sample($formattedName); -} -// [END vectorsearch_v1_generated_DataObjectService_GetDataObject_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/get_location.php b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/get_location.php deleted file mode 100644 index 9edd13df81e2..000000000000 --- a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/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 vectorsearch_v1_generated_DataObjectService_GetLocation_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/list_locations.php b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/list_locations.php deleted file mode 100644 index 0a4730deaa8c..000000000000 --- a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/list_locations.php +++ /dev/null @@ -1,78 +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 vectorsearch_v1_generated_DataObjectService_ListLocations_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/update_data_object.php b/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/update_data_object.php deleted file mode 100644 index 1fd6306c28dc..000000000000 --- a/owl-bot-staging/VectorSearch/v1/samples/V1/DataObjectServiceClient/update_data_object.php +++ /dev/null @@ -1,59 +0,0 @@ -setDataObject($dataObject); - - // Call the API and handle any network failures. - try { - /** @var DataObject $response */ - $response = $dataObjectServiceClient->updateDataObject($request); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END vectorsearch_v1_generated_DataObjectService_UpdateDataObject_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/create_collection.php b/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/create_collection.php deleted file mode 100644 index b5dba9b52e21..000000000000 --- a/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/create_collection.php +++ /dev/null @@ -1,92 +0,0 @@ -setParent($formattedParent) - ->setCollectionId($collectionId) - ->setCollection($collection); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vectorSearchServiceClient->createCollection($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var Collection $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 = VectorSearchServiceClient::locationName('[PROJECT]', '[LOCATION]'); - $collectionId = '[COLLECTION_ID]'; - - create_collection_sample($formattedParent, $collectionId); -} -// [END vectorsearch_v1_generated_VectorSearchService_CreateCollection_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/create_index.php b/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/create_index.php deleted file mode 100644 index 929e3279b24e..000000000000 --- a/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/create_index.php +++ /dev/null @@ -1,104 +0,0 @@ -setIndexField($indexIndexField); - $request = (new CreateIndexRequest()) - ->setParent($formattedParent) - ->setIndexId($indexId) - ->setIndex($index); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vectorSearchServiceClient->createIndex($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var Index $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 = VectorSearchServiceClient::collectionName( - '[PROJECT]', - '[LOCATION]', - '[COLLECTION]' - ); - $indexId = '[INDEX_ID]'; - $indexIndexField = '[INDEX_FIELD]'; - - create_index_sample($formattedParent, $indexId, $indexIndexField); -} -// [END vectorsearch_v1_generated_VectorSearchService_CreateIndex_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/delete_collection.php b/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/delete_collection.php deleted file mode 100644 index 7ab95231c955..000000000000 --- a/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/delete_collection.php +++ /dev/null @@ -1,84 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vectorSearchServiceClient->deleteCollection($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 = VectorSearchServiceClient::collectionName( - '[PROJECT]', - '[LOCATION]', - '[COLLECTION]' - ); - - delete_collection_sample($formattedName); -} -// [END vectorsearch_v1_generated_VectorSearchService_DeleteCollection_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/delete_index.php b/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/delete_index.php deleted file mode 100644 index ebcaa4e77d8a..000000000000 --- a/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/delete_index.php +++ /dev/null @@ -1,87 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vectorSearchServiceClient->deleteIndex($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 = VectorSearchServiceClient::indexName( - '[PROJECT]', - '[LOCATION]', - '[COLLECTION]', - '[INDEX]' - ); - - delete_index_sample($formattedName); -} -// [END vectorsearch_v1_generated_VectorSearchService_DeleteIndex_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/export_data_objects.php b/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/export_data_objects.php deleted file mode 100644 index c3081a2d0c6f..000000000000 --- a/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/export_data_objects.php +++ /dev/null @@ -1,89 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vectorSearchServiceClient->exportDataObjects($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var ExportDataObjectsResponse $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 = VectorSearchServiceClient::collectionName( - '[PROJECT]', - '[LOCATION]', - '[COLLECTION]' - ); - - export_data_objects_sample($formattedName); -} -// [END vectorsearch_v1_generated_VectorSearchService_ExportDataObjects_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/get_collection.php b/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/get_collection.php deleted file mode 100644 index d02572d30bf2..000000000000 --- a/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/get_collection.php +++ /dev/null @@ -1,75 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var Collection $response */ - $response = $vectorSearchServiceClient->getCollection($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 = VectorSearchServiceClient::collectionName( - '[PROJECT]', - '[LOCATION]', - '[COLLECTION]' - ); - - get_collection_sample($formattedName); -} -// [END vectorsearch_v1_generated_VectorSearchService_GetCollection_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/get_index.php b/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/get_index.php deleted file mode 100644 index 140b096be0dd..000000000000 --- a/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/get_index.php +++ /dev/null @@ -1,76 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var Index $response */ - $response = $vectorSearchServiceClient->getIndex($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 = VectorSearchServiceClient::indexName( - '[PROJECT]', - '[LOCATION]', - '[COLLECTION]', - '[INDEX]' - ); - - get_index_sample($formattedName); -} -// [END vectorsearch_v1_generated_VectorSearchService_GetIndex_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/get_location.php b/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/get_location.php deleted file mode 100644 index 2dac0088703d..000000000000 --- a/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/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 vectorsearch_v1_generated_VectorSearchService_GetLocation_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/import_data_objects.php b/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/import_data_objects.php deleted file mode 100644 index a5c5f7f3da75..000000000000 --- a/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/import_data_objects.php +++ /dev/null @@ -1,88 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vectorSearchServiceClient->importDataObjects($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var ImportDataObjectsResponse $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 = VectorSearchServiceClient::collectionName( - '[PROJECT]', - '[LOCATION]', - '[COLLECTION]' - ); - - import_data_objects_sample($formattedName); -} -// [END vectorsearch_v1_generated_VectorSearchService_ImportDataObjects_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/list_collections.php b/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/list_collections.php deleted file mode 100644 index 5121f672420e..000000000000 --- a/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/list_collections.php +++ /dev/null @@ -1,76 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $vectorSearchServiceClient->listCollections($request); - - /** @var Collection $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 = VectorSearchServiceClient::locationName('[PROJECT]', '[LOCATION]'); - - list_collections_sample($formattedParent); -} -// [END vectorsearch_v1_generated_VectorSearchService_ListCollections_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/list_indexes.php b/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/list_indexes.php deleted file mode 100644 index 6aaa50ebb75a..000000000000 --- a/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/list_indexes.php +++ /dev/null @@ -1,80 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $vectorSearchServiceClient->listIndexes($request); - - /** @var Index $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 = VectorSearchServiceClient::collectionName( - '[PROJECT]', - '[LOCATION]', - '[COLLECTION]' - ); - - list_indexes_sample($formattedParent); -} -// [END vectorsearch_v1_generated_VectorSearchService_ListIndexes_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/list_locations.php b/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/list_locations.php deleted file mode 100644 index 212feaf99516..000000000000 --- a/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/list_locations.php +++ /dev/null @@ -1,78 +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 vectorsearch_v1_generated_VectorSearchService_ListLocations_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/update_collection.php b/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/update_collection.php deleted file mode 100644 index 928fc297b03e..000000000000 --- a/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/update_collection.php +++ /dev/null @@ -1,71 +0,0 @@ -setCollection($collection); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vectorSearchServiceClient->updateCollection($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var Collection $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 vectorsearch_v1_generated_VectorSearchService_UpdateCollection_sync] diff --git a/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/update_index.php b/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/update_index.php deleted file mode 100644 index 91bbca2bab09..000000000000 --- a/owl-bot-staging/VectorSearch/v1/samples/V1/VectorSearchServiceClient/update_index.php +++ /dev/null @@ -1,84 +0,0 @@ -setIndexField($indexIndexField); - $request = (new UpdateIndexRequest()) - ->setIndex($index); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vectorSearchServiceClient->updateIndex($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var Index $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 -{ - $indexIndexField = '[INDEX_FIELD]'; - - update_index_sample($indexIndexField); -} -// [END vectorsearch_v1_generated_VectorSearchService_UpdateIndex_sync] diff --git a/owl-bot-staging/VectorSearch/v1/src/V1/Client/DataObjectSearchServiceClient.php b/owl-bot-staging/VectorSearch/v1/src/V1/Client/DataObjectSearchServiceClient.php deleted file mode 100644 index 7fab589eb36f..000000000000 --- a/owl-bot-staging/VectorSearch/v1/src/V1/Client/DataObjectSearchServiceClient.php +++ /dev/null @@ -1,441 +0,0 @@ - aggregateDataObjectsAsync(AggregateDataObjectsRequest $request, array $optionalArgs = []) - * @method PromiseInterface batchSearchDataObjectsAsync(BatchSearchDataObjectsRequest $request, array $optionalArgs = []) - * @method PromiseInterface queryDataObjectsAsync(QueryDataObjectsRequest $request, array $optionalArgs = []) - * @method PromiseInterface searchDataObjectsAsync(SearchDataObjectsRequest $request, array $optionalArgs = []) - * @method PromiseInterface getLocationAsync(GetLocationRequest $request, array $optionalArgs = []) - * @method PromiseInterface listLocationsAsync(ListLocationsRequest $request, array $optionalArgs = []) - */ -final class DataObjectSearchServiceClient -{ - use GapicClientTrait; - use ResourceHelperTrait; - - /** The name of the service. */ - private const SERVICE_NAME = 'google.cloud.vectorsearch.v1.DataObjectSearchService'; - - /** - * The default address of the service. - * - * @deprecated SERVICE_ADDRESS_TEMPLATE should be used instead. - */ - private const SERVICE_ADDRESS = 'vectorsearch.googleapis.com'; - - /** The address template of the service. */ - private const SERVICE_ADDRESS_TEMPLATE = 'vectorsearch.UNIVERSE_DOMAIN'; - - /** The default port of the service. */ - private const DEFAULT_SERVICE_PORT = 443; - - /** The name of the code generator, to be included in the agent header. */ - private const CODEGEN_NAME = 'gapic'; - - /** The default scopes required by the service. */ - public static $serviceScopes = [ - 'https://www.googleapis.com/auth/cloud-platform', - ]; - - private static function getClientDefaults() - { - return [ - 'serviceName' => self::SERVICE_NAME, - 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, - 'clientConfig' => __DIR__ . '/../resources/data_object_search_service_client_config.json', - 'descriptorsConfigPath' => __DIR__ . '/../resources/data_object_search_service_descriptor_config.php', - 'gcpApiConfigPath' => __DIR__ . '/../resources/data_object_search_service_grpc_config.json', - 'credentialsConfig' => [ - 'defaultScopes' => self::$serviceScopes, - ], - 'transportConfig' => [ - 'rest' => [ - 'restClientConfigPath' => __DIR__ . '/../resources/data_object_search_service_rest_client_config.php', - ], - ], - ]; - } - - /** - * Formats a string containing the fully-qualified path to represent a collection - * resource. - * - * @param string $project - * @param string $location - * @param string $collection - * - * @return string The formatted collection resource. - */ - public static function collectionName(string $project, string $location, string $collection): string - { - return self::getPathTemplate('collection')->render([ - 'project' => $project, - 'location' => $location, - 'collection' => $collection, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a index - * resource. - * - * @param string $project - * @param string $location - * @param string $collection - * @param string $index - * - * @return string The formatted index resource. - */ - public static function indexName(string $project, string $location, string $collection, string $index): string - { - return self::getPathTemplate('index')->render([ - 'project' => $project, - 'location' => $location, - 'collection' => $collection, - 'index' => $index, - ]); - } - - /** - * Parses a formatted name string and returns an associative array of the components in the name. - * The following name formats are supported: - * Template: Pattern - * - collection: projects/{project}/locations/{location}/collections/{collection} - * - index: projects/{project}/locations/{location}/collections/{collection}/indexes/{index} - * - * 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(string $formattedName, ?string $template = null): array - { - return self::parseFormattedName($formattedName, $template); - } - - /** - * Constructor. - * - * @param array|ClientOptions $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 'vectorsearch.googleapis.com:443'. - * @type FetchAuthTokenInterface|CredentialsWrapper $credentials - * This option should only be used with a pre-constructed - * {@see FetchAuthTokenInterface} or {@see CredentialsWrapper} object. Note that - * when one of these objects are provided, any settings in $credentialsConfig will - * be ignored. - * **Important**: If you are providing a path to a credentials file, or a decoded - * credentials file as a PHP array, this usage is now DEPRECATED. Providing an - * unvalidated credential configuration to Google APIs can compromise the security - * of your systems and data. It is recommended to create the credentials explicitly - * ``` - * use Google\Auth\Credentials\ServiceAccountCredentials; - * use Google\Cloud\VectorSearch\V1\DataObjectSearchServiceClient; - * $creds = new ServiceAccountCredentials($scopes, $json); - * $options = new DataObjectSearchServiceClient(['credentials' => $creds]); - * ``` - * {@see - * https://cloud.google.com/docs/authentication/external/externally-sourced-credentials} - * @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. - * @type false|LoggerInterface $logger - * A PSR-3 compliant logger. If set to false, logging is disabled, ignoring the - * 'GOOGLE_SDK_PHP_LOGGING' environment flag - * @type string $universeDomain - * The service domain for the client. Defaults to 'googleapis.com'. - * } - * - * @throws ValidationException - */ - public function __construct(array|ClientOptions $options = []) - { - $clientOptions = $this->buildClientOptions($options); - $this->setClientOptions($clientOptions); - } - - /** Handles execution of the async variants for each documented method. */ - public function __call($method, $args) - { - if (substr($method, -5) !== 'Async') { - trigger_error('Call to undefined method ' . __CLASS__ . "::$method()", E_USER_ERROR); - } - - array_unshift($args, substr($method, 0, -5)); - return call_user_func_array([$this, 'startAsyncCall'], $args); - } - - /** - * Aggregates data objects. - * - * The async variant is - * {@see DataObjectSearchServiceClient::aggregateDataObjectsAsync()} . - * - * @example samples/V1/DataObjectSearchServiceClient/aggregate_data_objects.php - * - * @param AggregateDataObjectsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 AggregateDataObjectsResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function aggregateDataObjects(AggregateDataObjectsRequest $request, array $callOptions = []): AggregateDataObjectsResponse - { - return $this->startApiCall('AggregateDataObjects', $request, $callOptions)->wait(); - } - - /** - * Batch searches data objects. - * - * The async variant is - * {@see DataObjectSearchServiceClient::batchSearchDataObjectsAsync()} . - * - * @example samples/V1/DataObjectSearchServiceClient/batch_search_data_objects.php - * - * @param BatchSearchDataObjectsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 BatchSearchDataObjectsResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function batchSearchDataObjects(BatchSearchDataObjectsRequest $request, array $callOptions = []): BatchSearchDataObjectsResponse - { - return $this->startApiCall('BatchSearchDataObjects', $request, $callOptions)->wait(); - } - - /** - * Queries data objects. - * - * The async variant is - * {@see DataObjectSearchServiceClient::queryDataObjectsAsync()} . - * - * @example samples/V1/DataObjectSearchServiceClient/query_data_objects.php - * - * @param QueryDataObjectsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function queryDataObjects(QueryDataObjectsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('QueryDataObjects', $request, $callOptions); - } - - /** - * Searches data objects. - * - * The async variant is - * {@see DataObjectSearchServiceClient::searchDataObjectsAsync()} . - * - * @example samples/V1/DataObjectSearchServiceClient/search_data_objects.php - * - * @param SearchDataObjectsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function searchDataObjects(SearchDataObjectsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('SearchDataObjects', $request, $callOptions); - } - - /** - * Gets information about a location. - * - * The async variant is {@see DataObjectSearchServiceClient::getLocationAsync()} . - * - * @example samples/V1/DataObjectSearchServiceClient/get_location.php - * - * @param GetLocationRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Location - * - * @throws ApiException Thrown if the API call fails. - */ - public function getLocation(GetLocationRequest $request, array $callOptions = []): Location - { - return $this->startApiCall('GetLocation', $request, $callOptions)->wait(); - } - - /** - * Lists information about the supported locations for this service. - * - * This method lists locations based on the resource scope provided in - * the [ListLocationsRequest.name] field: - * - * * **Global locations**: If `name` is empty, the method lists the - * public locations available to all projects. * **Project-specific - * locations**: If `name` follows the format - * `projects/{project}`, the method lists locations visible to that - * specific project. This includes public, private, or other - * project-specific locations enabled for the project. - * - * For gRPC and client library implementations, the resource name is - * passed as the `name` field. For direct service calls, the resource - * name is - * incorporated into the request path based on the specific service - * implementation and version. - * - * The async variant is {@see DataObjectSearchServiceClient::listLocationsAsync()} - * . - * - * @example samples/V1/DataObjectSearchServiceClient/list_locations.php - * - * @param ListLocationsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listLocations(ListLocationsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListLocations', $request, $callOptions); - } -} diff --git a/owl-bot-staging/VectorSearch/v1/src/V1/Client/DataObjectServiceClient.php b/owl-bot-staging/VectorSearch/v1/src/V1/Client/DataObjectServiceClient.php deleted file mode 100644 index 1eed6ba2f80c..000000000000 --- a/owl-bot-staging/VectorSearch/v1/src/V1/Client/DataObjectServiceClient.php +++ /dev/null @@ -1,520 +0,0 @@ - batchCreateDataObjectsAsync(BatchCreateDataObjectsRequest $request, array $optionalArgs = []) - * @method PromiseInterface batchDeleteDataObjectsAsync(BatchDeleteDataObjectsRequest $request, array $optionalArgs = []) - * @method PromiseInterface batchUpdateDataObjectsAsync(BatchUpdateDataObjectsRequest $request, array $optionalArgs = []) - * @method PromiseInterface createDataObjectAsync(CreateDataObjectRequest $request, array $optionalArgs = []) - * @method PromiseInterface deleteDataObjectAsync(DeleteDataObjectRequest $request, array $optionalArgs = []) - * @method PromiseInterface getDataObjectAsync(GetDataObjectRequest $request, array $optionalArgs = []) - * @method PromiseInterface updateDataObjectAsync(UpdateDataObjectRequest $request, array $optionalArgs = []) - * @method PromiseInterface getLocationAsync(GetLocationRequest $request, array $optionalArgs = []) - * @method PromiseInterface listLocationsAsync(ListLocationsRequest $request, array $optionalArgs = []) - */ -final class DataObjectServiceClient -{ - use GapicClientTrait; - use ResourceHelperTrait; - - /** The name of the service. */ - private const SERVICE_NAME = 'google.cloud.vectorsearch.v1.DataObjectService'; - - /** - * The default address of the service. - * - * @deprecated SERVICE_ADDRESS_TEMPLATE should be used instead. - */ - private const SERVICE_ADDRESS = 'vectorsearch.googleapis.com'; - - /** The address template of the service. */ - private const SERVICE_ADDRESS_TEMPLATE = 'vectorsearch.UNIVERSE_DOMAIN'; - - /** The default port of the service. */ - private const DEFAULT_SERVICE_PORT = 443; - - /** The name of the code generator, to be included in the agent header. */ - private const CODEGEN_NAME = 'gapic'; - - /** The default scopes required by the service. */ - public static $serviceScopes = [ - 'https://www.googleapis.com/auth/cloud-platform', - ]; - - private static function getClientDefaults() - { - return [ - 'serviceName' => self::SERVICE_NAME, - 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, - 'clientConfig' => __DIR__ . '/../resources/data_object_service_client_config.json', - 'descriptorsConfigPath' => __DIR__ . '/../resources/data_object_service_descriptor_config.php', - 'gcpApiConfigPath' => __DIR__ . '/../resources/data_object_service_grpc_config.json', - 'credentialsConfig' => [ - 'defaultScopes' => self::$serviceScopes, - ], - 'transportConfig' => [ - 'rest' => [ - 'restClientConfigPath' => __DIR__ . '/../resources/data_object_service_rest_client_config.php', - ], - ], - ]; - } - - /** - * Formats a string containing the fully-qualified path to represent a collection - * resource. - * - * @param string $project - * @param string $location - * @param string $collection - * - * @return string The formatted collection resource. - */ - public static function collectionName(string $project, string $location, string $collection): string - { - return self::getPathTemplate('collection')->render([ - 'project' => $project, - 'location' => $location, - 'collection' => $collection, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a data_object - * resource. - * - * @param string $project - * @param string $location - * @param string $collection - * @param string $dataObject - * - * @return string The formatted data_object resource. - */ - public static function dataObjectName(string $project, string $location, string $collection, string $dataObject): string - { - return self::getPathTemplate('dataObject')->render([ - 'project' => $project, - 'location' => $location, - 'collection' => $collection, - 'dataObject' => $dataObject, - ]); - } - - /** - * Parses a formatted name string and returns an associative array of the components in the name. - * The following name formats are supported: - * Template: Pattern - * - collection: projects/{project}/locations/{location}/collections/{collection} - * - dataObject: projects/{project}/locations/{location}/collections/{collection}/dataObjects/{dataObject} - * - * 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(string $formattedName, ?string $template = null): array - { - return self::parseFormattedName($formattedName, $template); - } - - /** - * Constructor. - * - * @param array|ClientOptions $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 'vectorsearch.googleapis.com:443'. - * @type FetchAuthTokenInterface|CredentialsWrapper $credentials - * This option should only be used with a pre-constructed - * {@see FetchAuthTokenInterface} or {@see CredentialsWrapper} object. Note that - * when one of these objects are provided, any settings in $credentialsConfig will - * be ignored. - * **Important**: If you are providing a path to a credentials file, or a decoded - * credentials file as a PHP array, this usage is now DEPRECATED. Providing an - * unvalidated credential configuration to Google APIs can compromise the security - * of your systems and data. It is recommended to create the credentials explicitly - * ``` - * use Google\Auth\Credentials\ServiceAccountCredentials; - * use Google\Cloud\VectorSearch\V1\DataObjectServiceClient; - * $creds = new ServiceAccountCredentials($scopes, $json); - * $options = new DataObjectServiceClient(['credentials' => $creds]); - * ``` - * {@see - * https://cloud.google.com/docs/authentication/external/externally-sourced-credentials} - * @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. - * @type false|LoggerInterface $logger - * A PSR-3 compliant logger. If set to false, logging is disabled, ignoring the - * 'GOOGLE_SDK_PHP_LOGGING' environment flag - * @type string $universeDomain - * The service domain for the client. Defaults to 'googleapis.com'. - * } - * - * @throws ValidationException - */ - public function __construct(array|ClientOptions $options = []) - { - $clientOptions = $this->buildClientOptions($options); - $this->setClientOptions($clientOptions); - } - - /** Handles execution of the async variants for each documented method. */ - public function __call($method, $args) - { - if (substr($method, -5) !== 'Async') { - trigger_error('Call to undefined method ' . __CLASS__ . "::$method()", E_USER_ERROR); - } - - array_unshift($args, substr($method, 0, -5)); - return call_user_func_array([$this, 'startAsyncCall'], $args); - } - - /** - * Creates a batch of dataObjects. - * - * The async variant is - * {@see DataObjectServiceClient::batchCreateDataObjectsAsync()} . - * - * @example samples/V1/DataObjectServiceClient/batch_create_data_objects.php - * - * @param BatchCreateDataObjectsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 BatchCreateDataObjectsResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function batchCreateDataObjects(BatchCreateDataObjectsRequest $request, array $callOptions = []): BatchCreateDataObjectsResponse - { - return $this->startApiCall('BatchCreateDataObjects', $request, $callOptions)->wait(); - } - - /** - * Deletes dataObjects in a batch. - * - * The async variant is - * {@see DataObjectServiceClient::batchDeleteDataObjectsAsync()} . - * - * @example samples/V1/DataObjectServiceClient/batch_delete_data_objects.php - * - * @param BatchDeleteDataObjectsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Thrown if the API call fails. - */ - public function batchDeleteDataObjects(BatchDeleteDataObjectsRequest $request, array $callOptions = []): void - { - $this->startApiCall('BatchDeleteDataObjects', $request, $callOptions)->wait(); - } - - /** - * Updates dataObjects in a batch. - * - * The async variant is - * {@see DataObjectServiceClient::batchUpdateDataObjectsAsync()} . - * - * @example samples/V1/DataObjectServiceClient/batch_update_data_objects.php - * - * @param BatchUpdateDataObjectsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 BatchUpdateDataObjectsResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function batchUpdateDataObjects(BatchUpdateDataObjectsRequest $request, array $callOptions = []): BatchUpdateDataObjectsResponse - { - return $this->startApiCall('BatchUpdateDataObjects', $request, $callOptions)->wait(); - } - - /** - * Creates a dataObject. - * - * The async variant is {@see DataObjectServiceClient::createDataObjectAsync()} . - * - * @example samples/V1/DataObjectServiceClient/create_data_object.php - * - * @param CreateDataObjectRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 DataObject - * - * @throws ApiException Thrown if the API call fails. - */ - public function createDataObject(CreateDataObjectRequest $request, array $callOptions = []): DataObject - { - return $this->startApiCall('CreateDataObject', $request, $callOptions)->wait(); - } - - /** - * Deletes a dataObject. - * - * The async variant is {@see DataObjectServiceClient::deleteDataObjectAsync()} . - * - * @example samples/V1/DataObjectServiceClient/delete_data_object.php - * - * @param DeleteDataObjectRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Thrown if the API call fails. - */ - public function deleteDataObject(DeleteDataObjectRequest $request, array $callOptions = []): void - { - $this->startApiCall('DeleteDataObject', $request, $callOptions)->wait(); - } - - /** - * Gets a data object. - * - * The async variant is {@see DataObjectServiceClient::getDataObjectAsync()} . - * - * @example samples/V1/DataObjectServiceClient/get_data_object.php - * - * @param GetDataObjectRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 DataObject - * - * @throws ApiException Thrown if the API call fails. - */ - public function getDataObject(GetDataObjectRequest $request, array $callOptions = []): DataObject - { - return $this->startApiCall('GetDataObject', $request, $callOptions)->wait(); - } - - /** - * Updates a dataObject. - * - * The async variant is {@see DataObjectServiceClient::updateDataObjectAsync()} . - * - * @example samples/V1/DataObjectServiceClient/update_data_object.php - * - * @param UpdateDataObjectRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 DataObject - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateDataObject(UpdateDataObjectRequest $request, array $callOptions = []): DataObject - { - return $this->startApiCall('UpdateDataObject', $request, $callOptions)->wait(); - } - - /** - * Gets information about a location. - * - * The async variant is {@see DataObjectServiceClient::getLocationAsync()} . - * - * @example samples/V1/DataObjectServiceClient/get_location.php - * - * @param GetLocationRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Location - * - * @throws ApiException Thrown if the API call fails. - */ - public function getLocation(GetLocationRequest $request, array $callOptions = []): Location - { - return $this->startApiCall('GetLocation', $request, $callOptions)->wait(); - } - - /** - * Lists information about the supported locations for this service. - * - * This method lists locations based on the resource scope provided in - * the [ListLocationsRequest.name] field: - * - * * **Global locations**: If `name` is empty, the method lists the - * public locations available to all projects. * **Project-specific - * locations**: If `name` follows the format - * `projects/{project}`, the method lists locations visible to that - * specific project. This includes public, private, or other - * project-specific locations enabled for the project. - * - * For gRPC and client library implementations, the resource name is - * passed as the `name` field. For direct service calls, the resource - * name is - * incorporated into the request path based on the specific service - * implementation and version. - * - * The async variant is {@see DataObjectServiceClient::listLocationsAsync()} . - * - * @example samples/V1/DataObjectServiceClient/list_locations.php - * - * @param ListLocationsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listLocations(ListLocationsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListLocations', $request, $callOptions); - } -} diff --git a/owl-bot-staging/VectorSearch/v1/src/V1/Client/VectorSearchServiceClient.php b/owl-bot-staging/VectorSearch/v1/src/V1/Client/VectorSearchServiceClient.php deleted file mode 100644 index 7cf31c22c00b..000000000000 --- a/owl-bot-staging/VectorSearch/v1/src/V1/Client/VectorSearchServiceClient.php +++ /dev/null @@ -1,762 +0,0 @@ - createCollectionAsync(CreateCollectionRequest $request, array $optionalArgs = []) - * @method PromiseInterface createIndexAsync(CreateIndexRequest $request, array $optionalArgs = []) - * @method PromiseInterface deleteCollectionAsync(DeleteCollectionRequest $request, array $optionalArgs = []) - * @method PromiseInterface deleteIndexAsync(DeleteIndexRequest $request, array $optionalArgs = []) - * @method PromiseInterface exportDataObjectsAsync(ExportDataObjectsRequest $request, array $optionalArgs = []) - * @method PromiseInterface getCollectionAsync(GetCollectionRequest $request, array $optionalArgs = []) - * @method PromiseInterface getIndexAsync(GetIndexRequest $request, array $optionalArgs = []) - * @method PromiseInterface importDataObjectsAsync(ImportDataObjectsRequest $request, array $optionalArgs = []) - * @method PromiseInterface listCollectionsAsync(ListCollectionsRequest $request, array $optionalArgs = []) - * @method PromiseInterface listIndexesAsync(ListIndexesRequest $request, array $optionalArgs = []) - * @method PromiseInterface updateCollectionAsync(UpdateCollectionRequest $request, array $optionalArgs = []) - * @method PromiseInterface updateIndexAsync(UpdateIndexRequest $request, array $optionalArgs = []) - * @method PromiseInterface getLocationAsync(GetLocationRequest $request, array $optionalArgs = []) - * @method PromiseInterface listLocationsAsync(ListLocationsRequest $request, array $optionalArgs = []) - */ -final class VectorSearchServiceClient -{ - use GapicClientTrait; - use ResourceHelperTrait; - - /** The name of the service. */ - private const SERVICE_NAME = 'google.cloud.vectorsearch.v1.VectorSearchService'; - - /** - * The default address of the service. - * - * @deprecated SERVICE_ADDRESS_TEMPLATE should be used instead. - */ - private const SERVICE_ADDRESS = 'vectorsearch.googleapis.com'; - - /** The address template of the service. */ - private const SERVICE_ADDRESS_TEMPLATE = 'vectorsearch.UNIVERSE_DOMAIN'; - - /** The default port of the service. */ - private const DEFAULT_SERVICE_PORT = 443; - - /** The name of the code generator, to be included in the agent header. */ - private const CODEGEN_NAME = 'gapic'; - - /** The default scopes required by the service. */ - public static $serviceScopes = [ - 'https://www.googleapis.com/auth/cloud-platform', - ]; - - private $operationsClient; - - private static function getClientDefaults() - { - return [ - 'serviceName' => self::SERVICE_NAME, - 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, - 'clientConfig' => __DIR__ . '/../resources/vector_search_service_client_config.json', - 'descriptorsConfigPath' => __DIR__ . '/../resources/vector_search_service_descriptor_config.php', - 'gcpApiConfigPath' => __DIR__ . '/../resources/vector_search_service_grpc_config.json', - 'credentialsConfig' => [ - 'defaultScopes' => self::$serviceScopes, - ], - 'transportConfig' => [ - 'rest' => [ - 'restClientConfigPath' => __DIR__ . '/../resources/vector_search_service_rest_client_config.php', - ], - ], - ]; - } - - /** - * 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 = $this->descriptors[$methodName]['longRunning'] ?? []; - $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); - $operation->reload(); - return $operation; - } - - /** - * Create the default operation client for the service. - * - * @param array $options ClientOptions for the client. - * - * @return OperationsClient - */ - private function createOperationsClient(array $options) - { - // Unset client-specific configuration options - unset($options['serviceName'], $options['clientConfig'], $options['descriptorsConfigPath']); - - if (isset($options['operationsClient'])) { - return $options['operationsClient']; - } - - return new OperationsClient($options); - } - - /** - * Formats a string containing the fully-qualified path to represent a collection - * resource. - * - * @param string $project - * @param string $location - * @param string $collection - * - * @return string The formatted collection resource. - */ - public static function collectionName(string $project, string $location, string $collection): string - { - return self::getPathTemplate('collection')->render([ - 'project' => $project, - 'location' => $location, - 'collection' => $collection, - ]); - } - - /** - * 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(string $project, string $location, string $keyRing, string $cryptoKey): string - { - return self::getPathTemplate('cryptoKey')->render([ - 'project' => $project, - 'location' => $location, - 'key_ring' => $keyRing, - 'crypto_key' => $cryptoKey, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a index - * resource. - * - * @param string $project - * @param string $location - * @param string $collection - * @param string $index - * - * @return string The formatted index resource. - */ - public static function indexName(string $project, string $location, string $collection, string $index): string - { - return self::getPathTemplate('index')->render([ - 'project' => $project, - 'location' => $location, - 'collection' => $collection, - 'index' => $index, - ]); - } - - /** - * 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(string $project, string $location): string - { - return self::getPathTemplate('location')->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 - * - collection: projects/{project}/locations/{location}/collections/{collection} - * - cryptoKey: projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key} - * - index: projects/{project}/locations/{location}/collections/{collection}/indexes/{index} - * - 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(string $formattedName, ?string $template = null): array - { - return self::parseFormattedName($formattedName, $template); - } - - /** - * Constructor. - * - * @param array|ClientOptions $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 'vectorsearch.googleapis.com:443'. - * @type FetchAuthTokenInterface|CredentialsWrapper $credentials - * This option should only be used with a pre-constructed - * {@see FetchAuthTokenInterface} or {@see CredentialsWrapper} object. Note that - * when one of these objects are provided, any settings in $credentialsConfig will - * be ignored. - * **Important**: If you are providing a path to a credentials file, or a decoded - * credentials file as a PHP array, this usage is now DEPRECATED. Providing an - * unvalidated credential configuration to Google APIs can compromise the security - * of your systems and data. It is recommended to create the credentials explicitly - * ``` - * use Google\Auth\Credentials\ServiceAccountCredentials; - * use Google\Cloud\VectorSearch\V1\VectorSearchServiceClient; - * $creds = new ServiceAccountCredentials($scopes, $json); - * $options = new VectorSearchServiceClient(['credentials' => $creds]); - * ``` - * {@see - * https://cloud.google.com/docs/authentication/external/externally-sourced-credentials} - * @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. - * @type false|LoggerInterface $logger - * A PSR-3 compliant logger. If set to false, logging is disabled, ignoring the - * 'GOOGLE_SDK_PHP_LOGGING' environment flag - * @type string $universeDomain - * The service domain for the client. Defaults to 'googleapis.com'. - * } - * - * @throws ValidationException - */ - public function __construct(array|ClientOptions $options = []) - { - $clientOptions = $this->buildClientOptions($options); - $this->setClientOptions($clientOptions); - $this->operationsClient = $this->createOperationsClient($clientOptions); - } - - /** Handles execution of the async variants for each documented method. */ - public function __call($method, $args) - { - if (substr($method, -5) !== 'Async') { - trigger_error('Call to undefined method ' . __CLASS__ . "::$method()", E_USER_ERROR); - } - - array_unshift($args, substr($method, 0, -5)); - return call_user_func_array([$this, 'startAsyncCall'], $args); - } - - /** - * Creates a new Collection in a given project and location. - * - * The async variant is {@see VectorSearchServiceClient::createCollectionAsync()} . - * - * @example samples/V1/VectorSearchServiceClient/create_collection.php - * - * @param CreateCollectionRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function createCollection(CreateCollectionRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('CreateCollection', $request, $callOptions)->wait(); - } - - /** - * Creates a new Index in a given project and location. - * - * The async variant is {@see VectorSearchServiceClient::createIndexAsync()} . - * - * @example samples/V1/VectorSearchServiceClient/create_index.php - * - * @param CreateIndexRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function createIndex(CreateIndexRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('CreateIndex', $request, $callOptions)->wait(); - } - - /** - * Deletes a single Collection. - * - * The async variant is {@see VectorSearchServiceClient::deleteCollectionAsync()} . - * - * @example samples/V1/VectorSearchServiceClient/delete_collection.php - * - * @param DeleteCollectionRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function deleteCollection(DeleteCollectionRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('DeleteCollection', $request, $callOptions)->wait(); - } - - /** - * Deletes a single Index. - * - * The async variant is {@see VectorSearchServiceClient::deleteIndexAsync()} . - * - * @example samples/V1/VectorSearchServiceClient/delete_index.php - * - * @param DeleteIndexRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function deleteIndex(DeleteIndexRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('DeleteIndex', $request, $callOptions)->wait(); - } - - /** - * Initiates a Long-Running Operation to export DataObjects from a Collection. - * - * The async variant is {@see VectorSearchServiceClient::exportDataObjectsAsync()} - * . - * - * @example samples/V1/VectorSearchServiceClient/export_data_objects.php - * - * @param ExportDataObjectsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function exportDataObjects(ExportDataObjectsRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('ExportDataObjects', $request, $callOptions)->wait(); - } - - /** - * Gets details of a single Collection. - * - * The async variant is {@see VectorSearchServiceClient::getCollectionAsync()} . - * - * @example samples/V1/VectorSearchServiceClient/get_collection.php - * - * @param GetCollectionRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Collection - * - * @throws ApiException Thrown if the API call fails. - */ - public function getCollection(GetCollectionRequest $request, array $callOptions = []): Collection - { - return $this->startApiCall('GetCollection', $request, $callOptions)->wait(); - } - - /** - * Gets details of a single Index. - * - * The async variant is {@see VectorSearchServiceClient::getIndexAsync()} . - * - * @example samples/V1/VectorSearchServiceClient/get_index.php - * - * @param GetIndexRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Index - * - * @throws ApiException Thrown if the API call fails. - */ - public function getIndex(GetIndexRequest $request, array $callOptions = []): Index - { - return $this->startApiCall('GetIndex', $request, $callOptions)->wait(); - } - - /** - * Initiates a Long-Running Operation to import DataObjects into a Collection. - * - * The async variant is {@see VectorSearchServiceClient::importDataObjectsAsync()} - * . - * - * @example samples/V1/VectorSearchServiceClient/import_data_objects.php - * - * @param ImportDataObjectsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function importDataObjects(ImportDataObjectsRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('ImportDataObjects', $request, $callOptions)->wait(); - } - - /** - * Lists Collections in a given project and location. - * - * The async variant is {@see VectorSearchServiceClient::listCollectionsAsync()} . - * - * @example samples/V1/VectorSearchServiceClient/list_collections.php - * - * @param ListCollectionsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listCollections(ListCollectionsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListCollections', $request, $callOptions); - } - - /** - * Lists Indexes in a given project and location. - * - * The async variant is {@see VectorSearchServiceClient::listIndexesAsync()} . - * - * @example samples/V1/VectorSearchServiceClient/list_indexes.php - * - * @param ListIndexesRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listIndexes(ListIndexesRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListIndexes', $request, $callOptions); - } - - /** - * Updates the parameters of a single Collection. - * - * The async variant is {@see VectorSearchServiceClient::updateCollectionAsync()} . - * - * @example samples/V1/VectorSearchServiceClient/update_collection.php - * - * @param UpdateCollectionRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateCollection(UpdateCollectionRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('UpdateCollection', $request, $callOptions)->wait(); - } - - /** - * Updates the parameters of a single Index. - * - * The async variant is {@see VectorSearchServiceClient::updateIndexAsync()} . - * - * @example samples/V1/VectorSearchServiceClient/update_index.php - * - * @param UpdateIndexRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateIndex(UpdateIndexRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('UpdateIndex', $request, $callOptions)->wait(); - } - - /** - * Gets information about a location. - * - * The async variant is {@see VectorSearchServiceClient::getLocationAsync()} . - * - * @example samples/V1/VectorSearchServiceClient/get_location.php - * - * @param GetLocationRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Location - * - * @throws ApiException Thrown if the API call fails. - */ - public function getLocation(GetLocationRequest $request, array $callOptions = []): Location - { - return $this->startApiCall('GetLocation', $request, $callOptions)->wait(); - } - - /** - * Lists information about the supported locations for this service. - * - * This method lists locations based on the resource scope provided in - * the [ListLocationsRequest.name] field: - * - * * **Global locations**: If `name` is empty, the method lists the - * public locations available to all projects. * **Project-specific - * locations**: If `name` follows the format - * `projects/{project}`, the method lists locations visible to that - * specific project. This includes public, private, or other - * project-specific locations enabled for the project. - * - * For gRPC and client library implementations, the resource name is - * passed as the `name` field. For direct service calls, the resource - * name is - * incorporated into the request path based on the specific service - * implementation and version. - * - * The async variant is {@see VectorSearchServiceClient::listLocationsAsync()} . - * - * @example samples/V1/VectorSearchServiceClient/list_locations.php - * - * @param ListLocationsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listLocations(ListLocationsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListLocations', $request, $callOptions); - } -} diff --git a/owl-bot-staging/VectorSearch/v1/src/V1/gapic_metadata.json b/owl-bot-staging/VectorSearch/v1/src/V1/gapic_metadata.json deleted file mode 100644 index 4e80203638a5..000000000000 --- a/owl-bot-staging/VectorSearch/v1/src/V1/gapic_metadata.json +++ /dev/null @@ -1,181 +0,0 @@ -{ - "schema": "1.0", - "comment": "This file maps proto services\/RPCs to the corresponding library clients\/methods", - "language": "php", - "protoPackage": "google.cloud.vectorsearch.v1", - "libraryPackage": "Google\\Cloud\\VectorSearch\\V1", - "services": { - "DataObjectSearchService": { - "clients": { - "grpc": { - "libraryClient": "DataObjectSearchServiceGapicClient", - "rpcs": { - "AggregateDataObjects": { - "methods": [ - "aggregateDataObjects" - ] - }, - "BatchSearchDataObjects": { - "methods": [ - "batchSearchDataObjects" - ] - }, - "QueryDataObjects": { - "methods": [ - "queryDataObjects" - ] - }, - "SearchDataObjects": { - "methods": [ - "searchDataObjects" - ] - }, - "GetLocation": { - "methods": [ - "getLocation" - ] - }, - "ListLocations": { - "methods": [ - "listLocations" - ] - } - } - } - } - }, - "DataObjectService": { - "clients": { - "grpc": { - "libraryClient": "DataObjectServiceGapicClient", - "rpcs": { - "BatchCreateDataObjects": { - "methods": [ - "batchCreateDataObjects" - ] - }, - "BatchDeleteDataObjects": { - "methods": [ - "batchDeleteDataObjects" - ] - }, - "BatchUpdateDataObjects": { - "methods": [ - "batchUpdateDataObjects" - ] - }, - "CreateDataObject": { - "methods": [ - "createDataObject" - ] - }, - "DeleteDataObject": { - "methods": [ - "deleteDataObject" - ] - }, - "GetDataObject": { - "methods": [ - "getDataObject" - ] - }, - "UpdateDataObject": { - "methods": [ - "updateDataObject" - ] - }, - "GetLocation": { - "methods": [ - "getLocation" - ] - }, - "ListLocations": { - "methods": [ - "listLocations" - ] - } - } - } - } - }, - "VectorSearchService": { - "clients": { - "grpc": { - "libraryClient": "VectorSearchServiceGapicClient", - "rpcs": { - "CreateCollection": { - "methods": [ - "createCollection" - ] - }, - "CreateIndex": { - "methods": [ - "createIndex" - ] - }, - "DeleteCollection": { - "methods": [ - "deleteCollection" - ] - }, - "DeleteIndex": { - "methods": [ - "deleteIndex" - ] - }, - "ExportDataObjects": { - "methods": [ - "exportDataObjects" - ] - }, - "GetCollection": { - "methods": [ - "getCollection" - ] - }, - "GetIndex": { - "methods": [ - "getIndex" - ] - }, - "ImportDataObjects": { - "methods": [ - "importDataObjects" - ] - }, - "ListCollections": { - "methods": [ - "listCollections" - ] - }, - "ListIndexes": { - "methods": [ - "listIndexes" - ] - }, - "UpdateCollection": { - "methods": [ - "updateCollection" - ] - }, - "UpdateIndex": { - "methods": [ - "updateIndex" - ] - }, - "GetLocation": { - "methods": [ - "getLocation" - ] - }, - "ListLocations": { - "methods": [ - "listLocations" - ] - } - } - } - } - } - } -} \ No newline at end of file diff --git a/owl-bot-staging/VectorSearch/v1/src/V1/resources/data_object_search_service_client_config.json b/owl-bot-staging/VectorSearch/v1/src/V1/resources/data_object_search_service_client_config.json deleted file mode 100644 index 50aeb62f8c33..000000000000 --- a/owl-bot-staging/VectorSearch/v1/src/V1/resources/data_object_search_service_client_config.json +++ /dev/null @@ -1,64 +0,0 @@ -{ - "interfaces": { - "google.cloud.vectorsearch.v1.DataObjectSearchService": { - "retry_codes": { - "no_retry_codes": [], - "retry_policy_2_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_2_params": { - "initial_retry_delay_millis": 1000, - "retry_delay_multiplier": 1.3, - "max_retry_delay_millis": 10000, - "initial_rpc_timeout_millis": 300000, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 300000, - "total_timeout_millis": 300000 - } - }, - "methods": { - "AggregateDataObjects": { - "timeout_millis": 300000, - "retry_codes_name": "retry_policy_2_codes", - "retry_params_name": "retry_policy_2_params" - }, - "BatchSearchDataObjects": { - "timeout_millis": 300000, - "retry_codes_name": "retry_policy_2_codes", - "retry_params_name": "retry_policy_2_params" - }, - "QueryDataObjects": { - "timeout_millis": 300000, - "retry_codes_name": "retry_policy_2_codes", - "retry_params_name": "retry_policy_2_params" - }, - "SearchDataObjects": { - "timeout_millis": 300000, - "retry_codes_name": "retry_policy_2_codes", - "retry_params_name": "retry_policy_2_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/VectorSearch/v1/src/V1/resources/data_object_search_service_descriptor_config.php b/owl-bot-staging/VectorSearch/v1/src/V1/resources/data_object_search_service_descriptor_config.php deleted file mode 100644 index 8db464a2a450..000000000000 --- a/owl-bot-staging/VectorSearch/v1/src/V1/resources/data_object_search_service_descriptor_config.php +++ /dev/null @@ -1,130 +0,0 @@ - [ - 'google.cloud.vectorsearch.v1.DataObjectSearchService' => [ - 'AggregateDataObjects' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\VectorSearch\V1\AggregateDataObjectsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'BatchSearchDataObjects' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\VectorSearch\V1\BatchSearchDataObjectsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'QueryDataObjects' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getDataObjects', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\VectorSearch\V1\QueryDataObjectsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'SearchDataObjects' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getResults', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\VectorSearch\V1\SearchDataObjectsResponse', - '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' => [ - 'collection' => 'projects/{project}/locations/{location}/collections/{collection}', - 'index' => 'projects/{project}/locations/{location}/collections/{collection}/indexes/{index}', - ], - ], - ], -]; diff --git a/owl-bot-staging/VectorSearch/v1/src/V1/resources/data_object_search_service_rest_client_config.php b/owl-bot-staging/VectorSearch/v1/src/V1/resources/data_object_search_service_rest_client_config.php deleted file mode 100644 index 68333383a6e5..000000000000 --- a/owl-bot-staging/VectorSearch/v1/src/V1/resources/data_object_search_service_rest_client_config.php +++ /dev/null @@ -1,148 +0,0 @@ - [ - '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.cloud.vectorsearch.v1.DataObjectSearchService' => [ - 'AggregateDataObjects' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/collections/*}/dataObjects:aggregate', - 'body' => '*', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'BatchSearchDataObjects' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/collections/*}/dataObjects:batchSearch', - 'body' => '*', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'QueryDataObjects' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/collections/*}/dataObjects:query', - 'body' => '*', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'SearchDataObjects' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/collections/*}/dataObjects:search', - 'body' => '*', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - ], - '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/VectorSearch/v1/src/V1/resources/data_object_service_client_config.json b/owl-bot-staging/VectorSearch/v1/src/V1/resources/data_object_service_client_config.json deleted file mode 100644 index a78004bb0501..000000000000 --- a/owl-bot-staging/VectorSearch/v1/src/V1/resources/data_object_service_client_config.json +++ /dev/null @@ -1,103 +0,0 @@ -{ - "interfaces": { - "google.cloud.vectorsearch.v1.DataObjectService": { - "retry_codes": { - "no_retry_codes": [], - "retry_policy_1_codes": [ - "UNAVAILABLE" - ], - "retry_policy_3_codes": [ - "UNAVAILABLE" - ], - "retry_policy_4_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 - }, - "retry_policy_3_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 - }, - "retry_policy_4_params": { - "initial_retry_delay_millis": 1000, - "retry_delay_multiplier": 1.3, - "max_retry_delay_millis": 10000, - "initial_rpc_timeout_millis": 300000, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 300000, - "total_timeout_millis": 300000 - } - }, - "methods": { - "BatchCreateDataObjects": { - "timeout_millis": 300000, - "retry_codes_name": "retry_policy_4_codes", - "retry_params_name": "retry_policy_4_params" - }, - "BatchDeleteDataObjects": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_3_codes", - "retry_params_name": "retry_policy_3_params" - }, - "BatchUpdateDataObjects": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_3_codes", - "retry_params_name": "retry_policy_3_params" - }, - "CreateDataObject": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_3_codes", - "retry_params_name": "retry_policy_3_params" - }, - "DeleteDataObject": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_3_codes", - "retry_params_name": "retry_policy_3_params" - }, - "GetDataObject": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "UpdateDataObject": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_3_codes", - "retry_params_name": "retry_policy_3_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/VectorSearch/v1/src/V1/resources/data_object_service_descriptor_config.php b/owl-bot-staging/VectorSearch/v1/src/V1/resources/data_object_service_descriptor_config.php deleted file mode 100644 index a66571732eb9..000000000000 --- a/owl-bot-staging/VectorSearch/v1/src/V1/resources/data_object_service_descriptor_config.php +++ /dev/null @@ -1,151 +0,0 @@ - [ - 'google.cloud.vectorsearch.v1.DataObjectService' => [ - 'BatchCreateDataObjects' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\VectorSearch\V1\BatchCreateDataObjectsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'BatchDeleteDataObjects' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Protobuf\GPBEmpty', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'BatchUpdateDataObjects' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\VectorSearch\V1\BatchUpdateDataObjectsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateDataObject' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\VectorSearch\V1\DataObject', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'DeleteDataObject' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Protobuf\GPBEmpty', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetDataObject' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\VectorSearch\V1\DataObject', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'UpdateDataObject' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\VectorSearch\V1\DataObject', - 'headerParams' => [ - [ - 'keyName' => 'data_object.name', - 'fieldAccessors' => [ - 'getDataObject', - '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' => [ - 'collection' => 'projects/{project}/locations/{location}/collections/{collection}', - 'dataObject' => 'projects/{project}/locations/{location}/collections/{collection}/dataObjects/{dataObject}', - ], - ], - ], -]; diff --git a/owl-bot-staging/VectorSearch/v1/src/V1/resources/data_object_service_rest_client_config.php b/owl-bot-staging/VectorSearch/v1/src/V1/resources/data_object_service_rest_client_config.php deleted file mode 100644 index d92a9eabd1e4..000000000000 --- a/owl-bot-staging/VectorSearch/v1/src/V1/resources/data_object_service_rest_client_config.php +++ /dev/null @@ -1,186 +0,0 @@ - [ - '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.cloud.vectorsearch.v1.DataObjectService' => [ - 'BatchCreateDataObjects' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/collections/*}/dataObjects:batchCreate', - 'body' => '*', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'BatchDeleteDataObjects' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/collections/*}/dataObjects:batchDelete', - 'body' => '*', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'BatchUpdateDataObjects' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/collections/*}/dataObjects:batchUpdate', - 'body' => '*', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'CreateDataObject' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/collections/*}/dataObjects', - 'body' => 'data_object', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'data_object_id', - ], - ], - 'DeleteDataObject' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/collections/*/dataObjects/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetDataObject' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/collections/*/dataObjects/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'UpdateDataObject' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{data_object.name=projects/*/locations/*/collections/*/dataObjects/*}', - 'body' => 'data_object', - 'placeholders' => [ - 'data_object.name' => [ - 'getters' => [ - 'getDataObject', - '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/VectorSearch/v1/src/V1/resources/vector_search_service_client_config.json b/owl-bot-staging/VectorSearch/v1/src/V1/resources/vector_search_service_client_config.json deleted file mode 100644 index e055528d9e03..000000000000 --- a/owl-bot-staging/VectorSearch/v1/src/V1/resources/vector_search_service_client_config.json +++ /dev/null @@ -1,116 +0,0 @@ -{ - "interfaces": { - "google.cloud.vectorsearch.v1.VectorSearchService": { - "retry_codes": { - "no_retry_codes": [], - "retry_policy_1_codes": [ - "UNAVAILABLE" - ], - "retry_policy_3_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 - }, - "retry_policy_3_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": { - "CreateCollection": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_3_codes", - "retry_params_name": "retry_policy_3_params" - }, - "CreateIndex": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_3_codes", - "retry_params_name": "retry_policy_3_params" - }, - "DeleteCollection": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_3_codes", - "retry_params_name": "retry_policy_3_params" - }, - "DeleteIndex": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_3_codes", - "retry_params_name": "retry_policy_3_params" - }, - "ExportDataObjects": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_codes", - "retry_params_name": "no_retry_params" - }, - "GetCollection": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetIndex": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ImportDataObjects": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_3_codes", - "retry_params_name": "retry_policy_3_params" - }, - "ListCollections": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListIndexes": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "UpdateCollection": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_3_codes", - "retry_params_name": "retry_policy_3_params" - }, - "UpdateIndex": { - "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" - } - } - } - } -} diff --git a/owl-bot-staging/VectorSearch/v1/src/V1/resources/vector_search_service_descriptor_config.php b/owl-bot-staging/VectorSearch/v1/src/V1/resources/vector_search_service_descriptor_config.php deleted file mode 100644 index 5e588fcd5a52..000000000000 --- a/owl-bot-staging/VectorSearch/v1/src/V1/resources/vector_search_service_descriptor_config.php +++ /dev/null @@ -1,286 +0,0 @@ - [ - 'google.cloud.vectorsearch.v1.VectorSearchService' => [ - 'CreateCollection' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\VectorSearch\V1\Collection', - 'metadataReturnType' => '\Google\Cloud\VectorSearch\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateIndex' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\VectorSearch\V1\Index', - 'metadataReturnType' => '\Google\Cloud\VectorSearch\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'DeleteCollection' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\VectorSearch\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'DeleteIndex' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\VectorSearch\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'ExportDataObjects' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\VectorSearch\V1\ExportDataObjectsResponse', - 'metadataReturnType' => '\Google\Cloud\VectorSearch\V1\ExportDataObjectsMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'ImportDataObjects' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\VectorSearch\V1\ImportDataObjectsResponse', - 'metadataReturnType' => '\Google\Cloud\VectorSearch\V1\ImportDataObjectsMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'UpdateCollection' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\VectorSearch\V1\Collection', - 'metadataReturnType' => '\Google\Cloud\VectorSearch\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'collection.name', - 'fieldAccessors' => [ - 'getCollection', - 'getName', - ], - ], - ], - ], - 'UpdateIndex' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\VectorSearch\V1\Index', - 'metadataReturnType' => '\Google\Cloud\VectorSearch\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'index.name', - 'fieldAccessors' => [ - 'getIndex', - 'getName', - ], - ], - ], - ], - 'GetCollection' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\VectorSearch\V1\Collection', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetIndex' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\VectorSearch\V1\Index', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'ListCollections' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getCollections', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\VectorSearch\V1\ListCollectionsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListIndexes' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getIndexes', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\VectorSearch\V1\ListIndexesResponse', - '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' => [ - 'collection' => 'projects/{project}/locations/{location}/collections/{collection}', - 'cryptoKey' => 'projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}', - 'index' => 'projects/{project}/locations/{location}/collections/{collection}/indexes/{index}', - 'location' => 'projects/{project}/locations/{location}', - ], - ], - ], -]; diff --git a/owl-bot-staging/VectorSearch/v1/src/V1/resources/vector_search_service_rest_client_config.php b/owl-bot-staging/VectorSearch/v1/src/V1/resources/vector_search_service_rest_client_config.php deleted file mode 100644 index e6f18f8e46f2..000000000000 --- a/owl-bot-staging/VectorSearch/v1/src/V1/resources/vector_search_service_rest_client_config.php +++ /dev/null @@ -1,246 +0,0 @@ - [ - '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.cloud.vectorsearch.v1.VectorSearchService' => [ - 'CreateCollection' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/collections', - 'body' => 'collection', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'collection_id', - ], - ], - 'CreateIndex' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/collections/*}/indexes', - 'body' => 'index', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'index_id', - ], - ], - 'DeleteCollection' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/collections/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteIndex' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/collections/*/indexes/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ExportDataObjects' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/collections/*}:exportDataObjects', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetCollection' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/collections/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetIndex' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/collections/*/indexes/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ImportDataObjects' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/collections/*}:importDataObjects', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListCollections' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/collections', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListIndexes' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/collections/*}/indexes', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'UpdateCollection' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{collection.name=projects/*/locations/*/collections/*}', - 'body' => 'collection', - 'placeholders' => [ - 'collection.name' => [ - 'getters' => [ - 'getCollection', - 'getName', - ], - ], - ], - ], - 'UpdateIndex' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{index.name=projects/*/locations/*/collections/*/indexes/*}', - 'body' => 'index', - 'placeholders' => [ - 'index.name' => [ - 'getters' => [ - 'getIndex', - '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/VectorSearch/v1/tests/Unit/V1/Client/DataObjectSearchServiceClientTest.php b/owl-bot-staging/VectorSearch/v1/tests/Unit/V1/Client/DataObjectSearchServiceClientTest.php deleted file mode 100644 index 4fd194a1ff95..000000000000 --- a/owl-bot-staging/VectorSearch/v1/tests/Unit/V1/Client/DataObjectSearchServiceClientTest.php +++ /dev/null @@ -1,510 +0,0 @@ -getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); - } - - /** @return DataObjectSearchServiceClient */ - private function createClient(array $options = []) - { - $options += [ - 'credentials' => $this->createCredentials(), - ]; - return new DataObjectSearchServiceClient($options); - } - - /** @test */ - public function aggregateDataObjectsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new AggregateDataObjectsResponse(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); - $aggregate = AggregationMethod::AGGREGATION_METHOD_UNSPECIFIED; - $request = (new AggregateDataObjectsRequest()) - ->setParent($formattedParent) - ->setAggregate($aggregate); - $response = $gapicClient->aggregateDataObjects($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vectorsearch.v1.DataObjectSearchService/AggregateDataObjects', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getAggregate(); - $this->assertProtobufEquals($aggregate, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function aggregateDataObjectsExceptionTest() - { - $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->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); - $aggregate = AggregationMethod::AGGREGATION_METHOD_UNSPECIFIED; - $request = (new AggregateDataObjectsRequest()) - ->setParent($formattedParent) - ->setAggregate($aggregate); - try { - $gapicClient->aggregateDataObjects($request); - // 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 batchSearchDataObjectsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new BatchSearchDataObjectsResponse(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); - $searches = []; - $request = (new BatchSearchDataObjectsRequest()) - ->setParent($formattedParent) - ->setSearches($searches); - $response = $gapicClient->batchSearchDataObjects($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vectorsearch.v1.DataObjectSearchService/BatchSearchDataObjects', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getSearches(); - $this->assertProtobufEquals($searches, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function batchSearchDataObjectsExceptionTest() - { - $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->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); - $searches = []; - $request = (new BatchSearchDataObjectsRequest()) - ->setParent($formattedParent) - ->setSearches($searches); - try { - $gapicClient->batchSearchDataObjects($request); - // 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 queryDataObjectsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $dataObjectsElement = new DataObject(); - $dataObjects = [ - $dataObjectsElement, - ]; - $expectedResponse = new QueryDataObjectsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setDataObjects($dataObjects); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); - $request = (new QueryDataObjectsRequest()) - ->setParent($formattedParent); - $response = $gapicClient->queryDataObjects($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getDataObjects()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vectorsearch.v1.DataObjectSearchService/QueryDataObjects', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function queryDataObjectsExceptionTest() - { - $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->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); - $request = (new QueryDataObjectsRequest()) - ->setParent($formattedParent); - try { - $gapicClient->queryDataObjects($request); - // 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 searchDataObjectsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $resultsElement = new SearchResult(); - $results = [ - $resultsElement, - ]; - $expectedResponse = new SearchDataObjectsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setResults($results); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); - $request = (new SearchDataObjectsRequest()) - ->setParent($formattedParent); - $response = $gapicClient->searchDataObjects($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getResults()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vectorsearch.v1.DataObjectSearchService/SearchDataObjects', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function searchDataObjectsExceptionTest() - { - $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->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); - $request = (new SearchDataObjectsRequest()) - ->setParent($formattedParent); - try { - $gapicClient->searchDataObjects($request); - // 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); - $request = new GetLocationRequest(); - $response = $gapicClient->getLocation($request); - $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); - $request = new GetLocationRequest(); - try { - $gapicClient->getLocation($request); - // 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); - $request = new ListLocationsRequest(); - $response = $gapicClient->listLocations($request); - $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); - $request = new ListLocationsRequest(); - try { - $gapicClient->listLocations($request); - // 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 aggregateDataObjectsAsyncTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new AggregateDataObjectsResponse(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); - $aggregate = AggregationMethod::AGGREGATION_METHOD_UNSPECIFIED; - $request = (new AggregateDataObjectsRequest()) - ->setParent($formattedParent) - ->setAggregate($aggregate); - $response = $gapicClient->aggregateDataObjectsAsync($request)->wait(); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vectorsearch.v1.DataObjectSearchService/AggregateDataObjects', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getAggregate(); - $this->assertProtobufEquals($aggregate, $actualValue); - $this->assertTrue($transport->isExhausted()); - } -} diff --git a/owl-bot-staging/VectorSearch/v1/tests/Unit/V1/Client/DataObjectServiceClientTest.php b/owl-bot-staging/VectorSearch/v1/tests/Unit/V1/Client/DataObjectServiceClientTest.php deleted file mode 100644 index 4153f2fdcc4f..000000000000 --- a/owl-bot-staging/VectorSearch/v1/tests/Unit/V1/Client/DataObjectServiceClientTest.php +++ /dev/null @@ -1,710 +0,0 @@ -getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); - } - - /** @return DataObjectServiceClient */ - private function createClient(array $options = []) - { - $options += [ - 'credentials' => $this->createCredentials(), - ]; - return new DataObjectServiceClient($options); - } - - /** @test */ - public function batchCreateDataObjectsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new BatchCreateDataObjectsResponse(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); - $requests = []; - $request = (new BatchCreateDataObjectsRequest()) - ->setParent($formattedParent) - ->setRequests($requests); - $response = $gapicClient->batchCreateDataObjects($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vectorsearch.v1.DataObjectService/BatchCreateDataObjects', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getRequests(); - $this->assertProtobufEquals($requests, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function batchCreateDataObjectsExceptionTest() - { - $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->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); - $requests = []; - $request = (new BatchCreateDataObjectsRequest()) - ->setParent($formattedParent) - ->setRequests($requests); - try { - $gapicClient->batchCreateDataObjects($request); - // 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 batchDeleteDataObjectsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); - $requests = []; - $request = (new BatchDeleteDataObjectsRequest()) - ->setParent($formattedParent) - ->setRequests($requests); - $gapicClient->batchDeleteDataObjects($request); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vectorsearch.v1.DataObjectService/BatchDeleteDataObjects', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getRequests(); - $this->assertProtobufEquals($requests, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function batchDeleteDataObjectsExceptionTest() - { - $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->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); - $requests = []; - $request = (new BatchDeleteDataObjectsRequest()) - ->setParent($formattedParent) - ->setRequests($requests); - try { - $gapicClient->batchDeleteDataObjects($request); - // 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 batchUpdateDataObjectsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new BatchUpdateDataObjectsResponse(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); - $requests = []; - $request = (new BatchUpdateDataObjectsRequest()) - ->setParent($formattedParent) - ->setRequests($requests); - $response = $gapicClient->batchUpdateDataObjects($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vectorsearch.v1.DataObjectService/BatchUpdateDataObjects', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getRequests(); - $this->assertProtobufEquals($requests, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function batchUpdateDataObjectsExceptionTest() - { - $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->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); - $requests = []; - $request = (new BatchUpdateDataObjectsRequest()) - ->setParent($formattedParent) - ->setRequests($requests); - try { - $gapicClient->batchUpdateDataObjects($request); - // 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 createDataObjectTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $dataObjectId2 = 'dataObjectId21879679481'; - $etag = 'etag3123477'; - $expectedResponse = new DataObject(); - $expectedResponse->setName($name); - $expectedResponse->setDataObjectId($dataObjectId2); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); - $dataObjectId = 'dataObjectId-806981690'; - $dataObject = new DataObject(); - $request = (new CreateDataObjectRequest()) - ->setParent($formattedParent) - ->setDataObjectId($dataObjectId) - ->setDataObject($dataObject); - $response = $gapicClient->createDataObject($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vectorsearch.v1.DataObjectService/CreateDataObject', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getDataObjectId(); - $this->assertProtobufEquals($dataObjectId, $actualValue); - $actualValue = $actualRequestObject->getDataObject(); - $this->assertProtobufEquals($dataObject, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function createDataObjectExceptionTest() - { - $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->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); - $dataObjectId = 'dataObjectId-806981690'; - $dataObject = new DataObject(); - $request = (new CreateDataObjectRequest()) - ->setParent($formattedParent) - ->setDataObjectId($dataObjectId) - ->setDataObject($dataObject); - try { - $gapicClient->createDataObject($request); - // 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 deleteDataObjectTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new GPBEmpty(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->dataObjectName('[PROJECT]', '[LOCATION]', '[COLLECTION]', '[DATAOBJECT]'); - $request = (new DeleteDataObjectRequest()) - ->setName($formattedName); - $gapicClient->deleteDataObject($request); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vectorsearch.v1.DataObjectService/DeleteDataObject', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function deleteDataObjectExceptionTest() - { - $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->dataObjectName('[PROJECT]', '[LOCATION]', '[COLLECTION]', '[DATAOBJECT]'); - $request = (new DeleteDataObjectRequest()) - ->setName($formattedName); - try { - $gapicClient->deleteDataObject($request); - // 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 getDataObjectTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $dataObjectId = 'dataObjectId-806981690'; - $etag = 'etag3123477'; - $expectedResponse = new DataObject(); - $expectedResponse->setName($name2); - $expectedResponse->setDataObjectId($dataObjectId); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->dataObjectName('[PROJECT]', '[LOCATION]', '[COLLECTION]', '[DATAOBJECT]'); - $request = (new GetDataObjectRequest()) - ->setName($formattedName); - $response = $gapicClient->getDataObject($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vectorsearch.v1.DataObjectService/GetDataObject', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getDataObjectExceptionTest() - { - $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->dataObjectName('[PROJECT]', '[LOCATION]', '[COLLECTION]', '[DATAOBJECT]'); - $request = (new GetDataObjectRequest()) - ->setName($formattedName); - try { - $gapicClient->getDataObject($request); - // 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 updateDataObjectTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name = 'name3373707'; - $dataObjectId = 'dataObjectId-806981690'; - $etag = 'etag3123477'; - $expectedResponse = new DataObject(); - $expectedResponse->setName($name); - $expectedResponse->setDataObjectId($dataObjectId); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $dataObject = new DataObject(); - $request = (new UpdateDataObjectRequest()) - ->setDataObject($dataObject); - $response = $gapicClient->updateDataObject($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vectorsearch.v1.DataObjectService/UpdateDataObject', $actualFuncCall); - $actualValue = $actualRequestObject->getDataObject(); - $this->assertProtobufEquals($dataObject, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function updateDataObjectExceptionTest() - { - $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 - $dataObject = new DataObject(); - $request = (new UpdateDataObjectRequest()) - ->setDataObject($dataObject); - try { - $gapicClient->updateDataObject($request); - // 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); - $request = new GetLocationRequest(); - $response = $gapicClient->getLocation($request); - $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); - $request = new GetLocationRequest(); - try { - $gapicClient->getLocation($request); - // 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); - $request = new ListLocationsRequest(); - $response = $gapicClient->listLocations($request); - $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); - $request = new ListLocationsRequest(); - try { - $gapicClient->listLocations($request); - // 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 batchCreateDataObjectsAsyncTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new BatchCreateDataObjectsResponse(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); - $requests = []; - $request = (new BatchCreateDataObjectsRequest()) - ->setParent($formattedParent) - ->setRequests($requests); - $response = $gapicClient->batchCreateDataObjectsAsync($request)->wait(); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vectorsearch.v1.DataObjectService/BatchCreateDataObjects', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualRequestObject->getRequests(); - $this->assertProtobufEquals($requests, $actualValue); - $this->assertTrue($transport->isExhausted()); - } -} diff --git a/owl-bot-staging/VectorSearch/v1/tests/Unit/V1/Client/VectorSearchServiceClientTest.php b/owl-bot-staging/VectorSearch/v1/tests/Unit/V1/Client/VectorSearchServiceClientTest.php deleted file mode 100644 index e78cd9f0334a..000000000000 --- a/owl-bot-staging/VectorSearch/v1/tests/Unit/V1/Client/VectorSearchServiceClientTest.php +++ /dev/null @@ -1,1599 +0,0 @@ -getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); - } - - /** @return VectorSearchServiceClient */ - private function createClient(array $options = []) - { - $options += [ - 'credentials' => $this->createCredentials(), - ]; - return new VectorSearchServiceClient($options); - } - - /** @test */ - public function createCollectionTest() - { - $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/createCollectionTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $expectedResponse = new Collection(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createCollectionTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $collectionId = 'collectionId-821242276'; - $collection = new Collection(); - $request = (new CreateCollectionRequest()) - ->setParent($formattedParent) - ->setCollectionId($collectionId) - ->setCollection($collection); - $response = $gapicClient->createCollection($request); - $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.vectorsearch.v1.VectorSearchService/CreateCollection', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getCollectionId(); - $this->assertProtobufEquals($collectionId, $actualValue); - $actualValue = $actualApiRequestObject->getCollection(); - $this->assertProtobufEquals($collection, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createCollectionTest'); - $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 createCollectionExceptionTest() - { - $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/createCollectionTest'); - $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]'); - $collectionId = 'collectionId-821242276'; - $collection = new Collection(); - $request = (new CreateCollectionRequest()) - ->setParent($formattedParent) - ->setCollectionId($collectionId) - ->setCollection($collection); - $response = $gapicClient->createCollection($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createCollectionTest'); - 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 createIndexTest() - { - $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/createIndexTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $indexField = 'indexField1673840461'; - $expectedResponse = new Index(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setIndexField($indexField); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createIndexTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); - $indexId = 'indexId112508840'; - $index = new Index(); - $indexIndexField = 'indexIndexField-1984372294'; - $index->setIndexField($indexIndexField); - $request = (new CreateIndexRequest()) - ->setParent($formattedParent) - ->setIndexId($indexId) - ->setIndex($index); - $response = $gapicClient->createIndex($request); - $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.vectorsearch.v1.VectorSearchService/CreateIndex', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getIndexId(); - $this->assertProtobufEquals($indexId, $actualValue); - $actualValue = $actualApiRequestObject->getIndex(); - $this->assertProtobufEquals($index, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createIndexTest'); - $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 createIndexExceptionTest() - { - $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/createIndexTest'); - $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->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); - $indexId = 'indexId112508840'; - $index = new Index(); - $indexIndexField = 'indexIndexField-1984372294'; - $index->setIndexField($indexIndexField); - $request = (new CreateIndexRequest()) - ->setParent($formattedParent) - ->setIndexId($indexId) - ->setIndex($index); - $response = $gapicClient->createIndex($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createIndexTest'); - 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 deleteCollectionTest() - { - $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/deleteCollectionTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteCollectionTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); - $request = (new DeleteCollectionRequest()) - ->setName($formattedName); - $response = $gapicClient->deleteCollection($request); - $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.vectorsearch.v1.VectorSearchService/DeleteCollection', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteCollectionTest'); - $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 deleteCollectionExceptionTest() - { - $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/deleteCollectionTest'); - $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->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); - $request = (new DeleteCollectionRequest()) - ->setName($formattedName); - $response = $gapicClient->deleteCollection($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteCollectionTest'); - 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 deleteIndexTest() - { - $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/deleteIndexTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteIndexTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->indexName('[PROJECT]', '[LOCATION]', '[COLLECTION]', '[INDEX]'); - $request = (new DeleteIndexRequest()) - ->setName($formattedName); - $response = $gapicClient->deleteIndex($request); - $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.vectorsearch.v1.VectorSearchService/DeleteIndex', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteIndexTest'); - $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 deleteIndexExceptionTest() - { - $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/deleteIndexTest'); - $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->indexName('[PROJECT]', '[LOCATION]', '[COLLECTION]', '[INDEX]'); - $request = (new DeleteIndexRequest()) - ->setName($formattedName); - $response = $gapicClient->deleteIndex($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteIndexTest'); - 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 exportDataObjectsTest() - { - $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/exportDataObjectsTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new ExportDataObjectsResponse(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/exportDataObjectsTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); - $request = (new ExportDataObjectsRequest()) - ->setName($formattedName); - $response = $gapicClient->exportDataObjects($request); - $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.vectorsearch.v1.VectorSearchService/ExportDataObjects', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/exportDataObjectsTest'); - $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 exportDataObjectsExceptionTest() - { - $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/exportDataObjectsTest'); - $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->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); - $request = (new ExportDataObjectsRequest()) - ->setName($formattedName); - $response = $gapicClient->exportDataObjects($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/exportDataObjectsTest'); - 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 getCollectionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $expectedResponse = new Collection(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); - $request = (new GetCollectionRequest()) - ->setName($formattedName); - $response = $gapicClient->getCollection($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vectorsearch.v1.VectorSearchService/GetCollection', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getCollectionExceptionTest() - { - $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->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); - $request = (new GetCollectionRequest()) - ->setName($formattedName); - try { - $gapicClient->getCollection($request); - // 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 getIndexTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $indexField = 'indexField1673840461'; - $expectedResponse = new Index(); - $expectedResponse->setName($name2); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setIndexField($indexField); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->indexName('[PROJECT]', '[LOCATION]', '[COLLECTION]', '[INDEX]'); - $request = (new GetIndexRequest()) - ->setName($formattedName); - $response = $gapicClient->getIndex($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vectorsearch.v1.VectorSearchService/GetIndex', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getIndexExceptionTest() - { - $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->indexName('[PROJECT]', '[LOCATION]', '[COLLECTION]', '[INDEX]'); - $request = (new GetIndexRequest()) - ->setName($formattedName); - try { - $gapicClient->getIndex($request); - // 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 importDataObjectsTest() - { - $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/importDataObjectsTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new ImportDataObjectsResponse(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/importDataObjectsTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); - $request = (new ImportDataObjectsRequest()) - ->setName($formattedName); - $response = $gapicClient->importDataObjects($request); - $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.vectorsearch.v1.VectorSearchService/ImportDataObjects', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/importDataObjectsTest'); - $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 importDataObjectsExceptionTest() - { - $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/importDataObjectsTest'); - $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->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); - $request = (new ImportDataObjectsRequest()) - ->setName($formattedName); - $response = $gapicClient->importDataObjects($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/importDataObjectsTest'); - 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 listCollectionsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $collectionsElement = new Collection(); - $collections = [ - $collectionsElement, - ]; - $expectedResponse = new ListCollectionsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setCollections($collections); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $request = (new ListCollectionsRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listCollections($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getCollections()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vectorsearch.v1.VectorSearchService/ListCollections', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listCollectionsExceptionTest() - { - $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]'); - $request = (new ListCollectionsRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listCollections($request); - // 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 listIndexesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $indexesElement = new Index(); - $indexes = [ - $indexesElement, - ]; - $expectedResponse = new ListIndexesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setIndexes($indexes); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); - $request = (new ListIndexesRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listIndexes($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getIndexes()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vectorsearch.v1.VectorSearchService/ListIndexes', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listIndexesExceptionTest() - { - $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->collectionName('[PROJECT]', '[LOCATION]', '[COLLECTION]'); - $request = (new ListIndexesRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listIndexes($request); - // 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 updateCollectionTest() - { - $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/updateCollectionTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $expectedResponse = new Collection(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateCollectionTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $collection = new Collection(); - $request = (new UpdateCollectionRequest()) - ->setCollection($collection); - $response = $gapicClient->updateCollection($request); - $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.vectorsearch.v1.VectorSearchService/UpdateCollection', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getCollection(); - $this->assertProtobufEquals($collection, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateCollectionTest'); - $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 updateCollectionExceptionTest() - { - $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/updateCollectionTest'); - $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 - $collection = new Collection(); - $request = (new UpdateCollectionRequest()) - ->setCollection($collection); - $response = $gapicClient->updateCollection($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateCollectionTest'); - 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 updateIndexTest() - { - $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/updateIndexTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $indexField = 'indexField1673840461'; - $expectedResponse = new Index(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $expectedResponse->setIndexField($indexField); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateIndexTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $index = new Index(); - $indexIndexField = 'indexIndexField-1984372294'; - $index->setIndexField($indexIndexField); - $request = (new UpdateIndexRequest()) - ->setIndex($index); - $response = $gapicClient->updateIndex($request); - $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.vectorsearch.v1.VectorSearchService/UpdateIndex', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getIndex(); - $this->assertProtobufEquals($index, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateIndexTest'); - $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 updateIndexExceptionTest() - { - $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/updateIndexTest'); - $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 - $index = new Index(); - $indexIndexField = 'indexIndexField-1984372294'; - $index->setIndexField($indexIndexField); - $request = (new UpdateIndexRequest()) - ->setIndex($index); - $response = $gapicClient->updateIndex($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateIndexTest'); - 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); - $request = new GetLocationRequest(); - $response = $gapicClient->getLocation($request); - $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); - $request = new GetLocationRequest(); - try { - $gapicClient->getLocation($request); - // 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); - $request = new ListLocationsRequest(); - $response = $gapicClient->listLocations($request); - $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); - $request = new ListLocationsRequest(); - try { - $gapicClient->listLocations($request); - // 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 createCollectionAsyncTest() - { - $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/createCollectionTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $displayName = 'displayName1615086568'; - $description = 'description-1724546052'; - $expectedResponse = new Collection(); - $expectedResponse->setName($name); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setDescription($description); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createCollectionTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $collectionId = 'collectionId-821242276'; - $collection = new Collection(); - $request = (new CreateCollectionRequest()) - ->setParent($formattedParent) - ->setCollectionId($collectionId) - ->setCollection($collection); - $response = $gapicClient->createCollectionAsync($request)->wait(); - $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.vectorsearch.v1.VectorSearchService/CreateCollection', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getCollectionId(); - $this->assertProtobufEquals($collectionId, $actualValue); - $actualValue = $actualApiRequestObject->getCollection(); - $this->assertProtobufEquals($collection, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createCollectionTest'); - $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()); - } -} diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/GPBMetadata/Google/Cloud/Vmwareengine/V1/Vmwareengine.php b/owl-bot-staging/VmwareEngine/v1/proto/src/GPBMetadata/Google/Cloud/Vmwareengine/V1/Vmwareengine.php deleted file mode 100644 index c3d849f4d60b..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/GPBMetadata/Google/Cloud/Vmwareengine/V1/Vmwareengine.php +++ /dev/null @@ -1,34 +0,0 @@ -internalAddGeneratedFile( - "\x0A\x94\x84\x02\x0A/google/cloud/vmwareengine/v1/vmwareengine.proto\x12\x1Cgoogle.cloud.vmwareengine.v1\x1A\x17google/api/client.proto\x1A\x1Fgoogle/api/field_behavior.proto\x1A\x1Bgoogle/api/field_info.proto\x1A\x19google/api/resource.proto\x1A9google/cloud/vmwareengine/v1/vmwareengine_resources.proto\x1A#google/longrunning/operations.proto\x1A\x1Bgoogle/protobuf/empty.proto\x1A google/protobuf/field_mask.proto\x1A\x1Fgoogle/protobuf/timestamp.proto\"\x9E\x01\x0A\x18ListPrivateCloudsRequest\x129\x0A\x06parent\x18\x01 \x01(\x09B)\xE0A\x02\xFAA#\x0A!locations.googleapis.com/Location\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\x12\x0E\x0A\x06filter\x18\x04 \x01(\x09\x12\x10\x0A\x08order_by\x18\x05 \x01(\x09\"\x8D\x01\x0A\x19ListPrivateCloudsResponse\x12B\x0A\x0Eprivate_clouds\x18\x01 \x03(\x0B2*.google.cloud.vmwareengine.v1.PrivateCloud\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\x12\x13\x0A\x0Bunreachable\x18\x03 \x03(\x09\"X\x0A\x16GetPrivateCloudRequest\x12>\x0A\x04name\x18\x01 \x01(\x09B0\xE0A\x02\xFAA*\x0A(vmwareengine.googleapis.com/PrivateCloud\"\xF2\x01\x0A\x19CreatePrivateCloudRequest\x129\x0A\x06parent\x18\x01 \x01(\x09B)\xE0A\x02\xFAA#\x0A!locations.googleapis.com/Location\x12\x1D\x0A\x10private_cloud_id\x18\x02 \x01(\x09B\x03\xE0A\x02\x12F\x0A\x0Dprivate_cloud\x18\x03 \x01(\x0B2*.google.cloud.vmwareengine.v1.PrivateCloudB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x04 \x01(\x09B\x03\xE0A\x01\x12\x1A\x0A\x0Dvalidate_only\x18\x05 \x01(\x08B\x03\xE0A\x01\"\xB2\x01\x0A\x19UpdatePrivateCloudRequest\x12F\x0A\x0Dprivate_cloud\x18\x01 \x01(\x0B2*.google.cloud.vmwareengine.v1.PrivateCloudB\x03\xE0A\x02\x124\x0A\x0Bupdate_mask\x18\x02 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x03\xE0A\x01\"\xB7\x01\x0A\x19DeletePrivateCloudRequest\x12>\x0A\x04name\x18\x01 \x01(\x09B0\xE0A\x02\xFAA*\x0A(vmwareengine.googleapis.com/PrivateCloud\x12\x17\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x03\xE0A\x01\x12\x12\x0A\x05force\x18\x03 \x01(\x08B\x03\xE0A\x01\x12\x1D\x0A\x0Bdelay_hours\x18\x04 \x01(\x05B\x03\xE0A\x01H\x00\x88\x01\x01B\x0E\x0A\x0C_delay_hours\"v\x0A\x1BUndeletePrivateCloudRequest\x12>\x0A\x04name\x18\x01 \x01(\x09B0\xE0A\x02\xFAA*\x0A(vmwareengine.googleapis.com/PrivateCloud\x12\x17\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x03\xE0A\x01\"\xA0\x01\x0A\x13ListClustersRequest\x12@\x0A\x06parent\x18\x01 \x01(\x09B0\xE0A\x02\xFAA*\x0A(vmwareengine.googleapis.com/PrivateCloud\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\x12\x0E\x0A\x06filter\x18\x04 \x01(\x09\x12\x10\x0A\x08order_by\x18\x05 \x01(\x09\"}\x0A\x14ListClustersResponse\x127\x0A\x08clusters\x18\x01 \x03(\x0B2%.google.cloud.vmwareengine.v1.Cluster\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\x12\x13\x0A\x0Bunreachable\x18\x03 \x03(\x09\"N\x0A\x11GetClusterRequest\x129\x0A\x04name\x18\x01 \x01(\x09B+\xE0A\x02\xFAA%\x0A#vmwareengine.googleapis.com/Cluster\"\xE3\x01\x0A\x14CreateClusterRequest\x12@\x0A\x06parent\x18\x01 \x01(\x09B0\xE0A\x02\xFAA*\x0A(vmwareengine.googleapis.com/PrivateCloud\x12\x17\x0A\x0Acluster_id\x18\x02 \x01(\x09B\x03\xE0A\x02\x12;\x0A\x07cluster\x18\x03 \x01(\x0B2%.google.cloud.vmwareengine.v1.ClusterB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x04 \x01(\x09B\x03\xE0A\x01\x12\x1A\x0A\x0Dvalidate_only\x18\x05 \x01(\x08B\x03\xE0A\x01\"\xBE\x01\x0A\x14UpdateClusterRequest\x124\x0A\x0Bupdate_mask\x18\x01 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x02\x12;\x0A\x07cluster\x18\x02 \x01(\x0B2%.google.cloud.vmwareengine.v1.ClusterB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x03\xE0A\x01\x12\x1A\x0A\x0Dvalidate_only\x18\x04 \x01(\x08B\x03\xE0A\x01\"j\x0A\x14DeleteClusterRequest\x129\x0A\x04name\x18\x01 \x01(\x09B+\xE0A\x02\xFAA%\x0A#vmwareengine.googleapis.com/Cluster\x12\x17\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x03\xE0A\x01\"v\x0A\x10ListNodesRequest\x12;\x0A\x06parent\x18\x01 \x01(\x09B+\xE0A\x02\xFAA%\x0A#vmwareengine.googleapis.com/Cluster\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\"_\x0A\x11ListNodesResponse\x121\x0A\x05nodes\x18\x01 \x03(\x0B2\".google.cloud.vmwareengine.v1.Node\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\"H\x0A\x0EGetNodeRequest\x126\x0A\x04name\x18\x01 \x01(\x09B(\xE0A\x02\xFAA\"\x0A vmwareengine.googleapis.com/Node\"\xA9\x01\x0A\x1CListExternalAddressesRequest\x12@\x0A\x06parent\x18\x01 \x01(\x09B0\xE0A\x02\xFAA*\x0A(vmwareengine.googleapis.com/PrivateCloud\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\x12\x0E\x0A\x06filter\x18\x04 \x01(\x09\x12\x10\x0A\x08order_by\x18\x05 \x01(\x09\"\x98\x01\x0A\x1DListExternalAddressesResponse\x12I\x0A\x12external_addresses\x18\x01 \x03(\x0B2-.google.cloud.vmwareengine.v1.ExternalAddress\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\x12\x13\x0A\x0Bunreachable\x18\x03 \x03(\x09\"\x9E\x01\x0A*FetchNetworkPolicyExternalAddressesRequest\x12I\x0A\x0Enetwork_policy\x18\x01 \x01(\x09B1\xE0A\x02\xFAA+\x0A)vmwareengine.googleapis.com/NetworkPolicy\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\"\x91\x01\x0A+FetchNetworkPolicyExternalAddressesResponse\x12I\x0A\x12external_addresses\x18\x01 \x03(\x0B2-.google.cloud.vmwareengine.v1.ExternalAddress\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\"^\x0A\x19GetExternalAddressRequest\x12A\x0A\x04name\x18\x01 \x01(\x09B3\xE0A\x02\xFAA-\x0A+vmwareengine.googleapis.com/ExternalAddress\"\xE9\x01\x0A\x1CCreateExternalAddressRequest\x12@\x0A\x06parent\x18\x01 \x01(\x09B0\xE0A\x02\xFAA*\x0A(vmwareengine.googleapis.com/PrivateCloud\x12L\x0A\x10external_address\x18\x02 \x01(\x0B2-.google.cloud.vmwareengine.v1.ExternalAddressB\x03\xE0A\x02\x12 \x0A\x13external_address_id\x18\x03 \x01(\x09B\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x04 \x01(\x09B\x03\xE0A\x01\"\xBB\x01\x0A\x1CUpdateExternalAddressRequest\x124\x0A\x0Bupdate_mask\x18\x01 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x02\x12L\x0A\x10external_address\x18\x02 \x01(\x0B2-.google.cloud.vmwareengine.v1.ExternalAddressB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x03\xE0A\x01\"z\x0A\x1CDeleteExternalAddressRequest\x12A\x0A\x04name\x18\x01 \x01(\x09B3\xE0A\x02\xFAA-\x0A+vmwareengine.googleapis.com/ExternalAddress\x12\x17\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x03\xE0A\x01\"}\x0A\x12ListSubnetsRequest\x12@\x0A\x06parent\x18\x01 \x01(\x09B0\xE0A\x02\xFAA*\x0A(vmwareengine.googleapis.com/PrivateCloud\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\"z\x0A\x13ListSubnetsResponse\x125\x0A\x07subnets\x18\x01 \x03(\x0B2\$.google.cloud.vmwareengine.v1.Subnet\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\x12\x13\x0A\x0Bunreachable\x18\x03 \x03(\x09\"L\x0A\x10GetSubnetRequest\x128\x0A\x04name\x18\x01 \x01(\x09B*\xE0A\x02\xFAA\$\x0A\"vmwareengine.googleapis.com/Subnet\"\x86\x01\x0A\x13UpdateSubnetRequest\x124\x0A\x0Bupdate_mask\x18\x01 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x02\x129\x0A\x06subnet\x18\x02 \x01(\x0B2\$.google.cloud.vmwareengine.v1.SubnetB\x03\xE0A\x02\"\xAC\x01\x0A\x1EListExternalAccessRulesRequest\x12A\x0A\x06parent\x18\x01 \x01(\x09B1\xE0A\x02\xFAA+\x0A)vmwareengine.googleapis.com/NetworkPolicy\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\x12\x0E\x0A\x06filter\x18\x04 \x01(\x09\x12\x10\x0A\x08order_by\x18\x05 \x01(\x09\"\xA0\x01\x0A\x1FListExternalAccessRulesResponse\x12O\x0A\x15external_access_rules\x18\x01 \x03(\x0B20.google.cloud.vmwareengine.v1.ExternalAccessRule\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\x12\x13\x0A\x0Bunreachable\x18\x03 \x03(\x09\"d\x0A\x1CGetExternalAccessRuleRequest\x12D\x0A\x04name\x18\x01 \x01(\x09B6\xE0A\x02\xFAA0\x0A.vmwareengine.googleapis.com/ExternalAccessRule\"\xF3\x01\x0A\x1FCreateExternalAccessRuleRequest\x12A\x0A\x06parent\x18\x01 \x01(\x09B1\xE0A\x02\xFAA+\x0A)vmwareengine.googleapis.com/NetworkPolicy\x12S\x0A\x14external_access_rule\x18\x02 \x01(\x0B20.google.cloud.vmwareengine.v1.ExternalAccessRuleB\x03\xE0A\x02\x12\$\x0A\x17external_access_rule_id\x18\x03 \x01(\x09B\x03\xE0A\x02\x12\x12\x0A\x0Arequest_id\x18\x04 \x01(\x09\"\xC5\x01\x0A\x1FUpdateExternalAccessRuleRequest\x124\x0A\x0Bupdate_mask\x18\x01 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x02\x12S\x0A\x14external_access_rule\x18\x02 \x01(\x0B20.google.cloud.vmwareengine.v1.ExternalAccessRuleB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x03\xE0A\x01\"\x80\x01\x0A\x1FDeleteExternalAccessRuleRequest\x12D\x0A\x04name\x18\x01 \x01(\x09B6\xE0A\x02\xFAA0\x0A.vmwareengine.googleapis.com/ExternalAccessRule\x12\x17\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x03\xE0A\x01\"\xA6\x01\x0A\x19ListLoggingServersRequest\x12@\x0A\x06parent\x18\x01 \x01(\x09B0\xE0A\x02\xFAA*\x0A(vmwareengine.googleapis.com/PrivateCloud\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\x12\x0E\x0A\x06filter\x18\x04 \x01(\x09\x12\x10\x0A\x08order_by\x18\x05 \x01(\x09\"\x90\x01\x0A\x1AListLoggingServersResponse\x12D\x0A\x0Flogging_servers\x18\x01 \x03(\x0B2+.google.cloud.vmwareengine.v1.LoggingServer\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\x12\x13\x0A\x0Bunreachable\x18\x03 \x03(\x09\"Z\x0A\x17GetLoggingServerRequest\x12?\x0A\x04name\x18\x01 \x01(\x09B1\xE0A\x02\xFAA+\x0A)vmwareengine.googleapis.com/LoggingServer\"\xE1\x01\x0A\x1ACreateLoggingServerRequest\x12@\x0A\x06parent\x18\x01 \x01(\x09B0\xE0A\x02\xFAA*\x0A(vmwareengine.googleapis.com/PrivateCloud\x12H\x0A\x0Elogging_server\x18\x02 \x01(\x0B2+.google.cloud.vmwareengine.v1.LoggingServerB\x03\xE0A\x02\x12\x1E\x0A\x11logging_server_id\x18\x03 \x01(\x09B\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x04 \x01(\x09B\x03\xE0A\x01\"\xB5\x01\x0A\x1AUpdateLoggingServerRequest\x124\x0A\x0Bupdate_mask\x18\x01 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x02\x12H\x0A\x0Elogging_server\x18\x02 \x01(\x0B2+.google.cloud.vmwareengine.v1.LoggingServerB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x03\xE0A\x01\"v\x0A\x1ADeleteLoggingServerRequest\x12?\x0A\x04name\x18\x01 \x01(\x09B1\xE0A\x02\xFAA+\x0A)vmwareengine.googleapis.com/LoggingServer\x12\x17\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x03\xE0A\x01\"\x80\x02\x0A\x11OperationMetadata\x124\x0A\x0Bcreate_time\x18\x01 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x121\x0A\x08end_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12\x13\x0A\x06target\x18\x03 \x01(\x09B\x03\xE0A\x03\x12\x11\x0A\x04verb\x18\x04 \x01(\x09B\x03\xE0A\x03\x12\x1B\x0A\x0Estatus_message\x18\x05 \x01(\x09B\x03\xE0A\x03\x12#\x0A\x16requested_cancellation\x18\x06 \x01(\x08B\x03\xE0A\x03\x12\x18\x0A\x0Bapi_version\x18\x07 \x01(\x09B\x03\xE0A\x03\"\x88\x01\x0A\x14ListNodeTypesRequest\x129\x0A\x06parent\x18\x01 \x01(\x09B)\xE0A\x02\xFAA#\x0A!locations.googleapis.com/Location\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\x12\x0E\x0A\x06filter\x18\x04 \x01(\x09\"\x81\x01\x0A\x15ListNodeTypesResponse\x12:\x0A\x0Anode_types\x18\x01 \x03(\x0B2&.google.cloud.vmwareengine.v1.NodeType\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\x12\x13\x0A\x0Bunreachable\x18\x03 \x03(\x09\"P\x0A\x12GetNodeTypeRequest\x12:\x0A\x04name\x18\x01 \x01(\x09B,\xE0A\x02\xFAA&\x0A\$vmwareengine.googleapis.com/NodeType\"d\x0A\x19ShowNsxCredentialsRequest\x12G\x0A\x0Dprivate_cloud\x18\x01 \x01(\x09B0\xE0A\x02\xFAA*\x0A(vmwareengine.googleapis.com/PrivateCloud\"\x7F\x0A\x1DShowVcenterCredentialsRequest\x12G\x0A\x0Dprivate_cloud\x18\x01 \x01(\x09B0\xE0A\x02\xFAA*\x0A(vmwareengine.googleapis.com/PrivateCloud\x12\x15\x0A\x08username\x18\x02 \x01(\x09B\x03\xE0A\x01\"~\x0A\x1AResetNsxCredentialsRequest\x12G\x0A\x0Dprivate_cloud\x18\x01 \x01(\x09B0\xE0A\x02\xFAA*\x0A(vmwareengine.googleapis.com/PrivateCloud\x12\x17\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x03\xE0A\x01\"\x99\x01\x0A\x1EResetVcenterCredentialsRequest\x12G\x0A\x0Dprivate_cloud\x18\x01 \x01(\x09B0\xE0A\x02\xFAA*\x0A(vmwareengine.googleapis.com/PrivateCloud\x12\x17\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x03\xE0A\x01\x12\x15\x0A\x08username\x18\x03 \x01(\x09B\x03\xE0A\x01\"\x9A\x01\x0A\x1DListHcxActivationKeysResponse\x12K\x0A\x13hcx_activation_keys\x18\x01 \x03(\x0B2..google.cloud.vmwareengine.v1.HcxActivationKey\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\x12\x13\x0A\x0Bunreachable\x18\x03 \x03(\x09\"\x87\x01\x0A\x1CListHcxActivationKeysRequest\x12@\x0A\x06parent\x18\x01 \x01(\x09B0\xE0A\x02\xFAA*\x0A(vmwareengine.googleapis.com/PrivateCloud\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\"`\x0A\x1AGetHcxActivationKeyRequest\x12B\x0A\x04name\x18\x01 \x01(\x09B4\xE0A\x02\xFAA.\x0A,vmwareengine.googleapis.com/HcxActivationKey\"\xEA\x01\x0A\x1DCreateHcxActivationKeyRequest\x12@\x0A\x06parent\x18\x01 \x01(\x09B0\xE0A\x02\xFAA*\x0A(vmwareengine.googleapis.com/PrivateCloud\x12O\x0A\x12hcx_activation_key\x18\x02 \x01(\x0B2..google.cloud.vmwareengine.v1.HcxActivationKeyB\x03\xE0A\x02\x12\"\x0A\x15hcx_activation_key_id\x18\x03 \x01(\x09B\x03\xE0A\x02\x12\x12\x0A\x0Arequest_id\x18\x04 \x01(\x09\"Z\x0A\x17GetDnsForwardingRequest\x12?\x0A\x04name\x18\x01 \x01(\x09B1\xE0A\x02\xFAA+\x0A)vmwareengine.googleapis.com/DnsForwarding\"\xB5\x01\x0A\x1AUpdateDnsForwardingRequest\x12H\x0A\x0Edns_forwarding\x18\x01 \x01(\x0B2+.google.cloud.vmwareengine.v1.DnsForwardingB\x03\xE0A\x02\x124\x0A\x0Bupdate_mask\x18\x02 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x03\xE0A\x01\"\xDE\x01\x0A\x1BCreateNetworkPeeringRequest\x129\x0A\x06parent\x18\x01 \x01(\x09B)\xE0A\x02\xFAA#\x0A!locations.googleapis.com/Location\x12\x1F\x0A\x12network_peering_id\x18\x02 \x01(\x09B\x03\xE0A\x02\x12J\x0A\x0Fnetwork_peering\x18\x03 \x01(\x0B2,.google.cloud.vmwareengine.v1.NetworkPeeringB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x04 \x01(\x09B\x03\xE0A\x01\"x\x0A\x1BDeleteNetworkPeeringRequest\x12@\x0A\x04name\x18\x01 \x01(\x09B2\xE0A\x02\xFAA,\x0A*vmwareengine.googleapis.com/NetworkPeering\x12\x17\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x03\xE0A\x01\"\\\x0A\x18GetNetworkPeeringRequest\x12@\x0A\x04name\x18\x01 \x01(\x09B2\xE0A\x02\xFAA,\x0A*vmwareengine.googleapis.com/NetworkPeering\"\xA9\x01\x0A\x1AListNetworkPeeringsRequest\x12B\x0A\x06parent\x18\x01 \x01(\x09B2\xE0A\x02\xFAA,\x12*vmwareengine.googleapis.com/NetworkPeering\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\x12\x0E\x0A\x06filter\x18\x04 \x01(\x09\x12\x10\x0A\x08order_by\x18\x05 \x01(\x09\"\xB8\x01\x0A\x1BUpdateNetworkPeeringRequest\x12J\x0A\x0Fnetwork_peering\x18\x01 \x01(\x0B2,.google.cloud.vmwareengine.v1.NetworkPeeringB\x03\xE0A\x02\x124\x0A\x0Bupdate_mask\x18\x02 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x03\xE0A\x01\"\x93\x01\x0A\x1BListNetworkPeeringsResponse\x12F\x0A\x10network_peerings\x18\x01 \x03(\x0B2,.google.cloud.vmwareengine.v1.NetworkPeering\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\x12\x13\x0A\x0Bunreachable\x18\x03 \x03(\x09\"\x95\x01\x0A\x18ListPeeringRoutesRequest\x12B\x0A\x06parent\x18\x01 \x01(\x09B2\xE0A\x02\xFAA,\x0A*vmwareengine.googleapis.com/NetworkPeering\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\x12\x0E\x0A\x06filter\x18\x06 \x01(\x09\"x\x0A\x19ListPeeringRoutesResponse\x12B\x0A\x0Epeering_routes\x18\x01 \x03(\x0B2*.google.cloud.vmwareengine.v1.PeeringRoute\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\"\xA8\x01\x0A\x1AListNetworkPoliciesRequest\x12A\x0A\x06parent\x18\x01 \x01(\x09B1\xE0A\x02\xFAA+\x12)vmwareengine.googleapis.com/NetworkPolicy\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\x12\x0E\x0A\x06filter\x18\x04 \x01(\x09\x12\x10\x0A\x08order_by\x18\x05 \x01(\x09\"\x92\x01\x0A\x1BListNetworkPoliciesResponse\x12E\x0A\x10network_policies\x18\x01 \x03(\x0B2+.google.cloud.vmwareengine.v1.NetworkPolicy\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\x12\x13\x0A\x0Bunreachable\x18\x03 \x03(\x09\"Z\x0A\x17GetNetworkPolicyRequest\x12?\x0A\x04name\x18\x01 \x01(\x09B1\xE0A\x02\xFAA+\x0A)vmwareengine.googleapis.com/NetworkPolicy\"\xB5\x01\x0A\x1AUpdateNetworkPolicyRequest\x12H\x0A\x0Enetwork_policy\x18\x01 \x01(\x0B2+.google.cloud.vmwareengine.v1.NetworkPolicyB\x03\xE0A\x02\x124\x0A\x0Bupdate_mask\x18\x02 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x03\xE0A\x01\"\xE2\x01\x0A\x1ACreateNetworkPolicyRequest\x12A\x0A\x06parent\x18\x01 \x01(\x09B1\xE0A\x02\xFAA+\x12)vmwareengine.googleapis.com/NetworkPolicy\x12\x1E\x0A\x11network_policy_id\x18\x02 \x01(\x09B\x03\xE0A\x02\x12H\x0A\x0Enetwork_policy\x18\x03 \x01(\x0B2+.google.cloud.vmwareengine.v1.NetworkPolicyB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x04 \x01(\x09B\x03\xE0A\x01\"v\x0A\x1ADeleteNetworkPolicyRequest\x12?\x0A\x04name\x18\x01 \x01(\x09B1\xE0A\x02\xFAA+\x0A)vmwareengine.googleapis.com/NetworkPolicy\x12\x17\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x03\xE0A\x01\"\xB1\x01\x0A\$ListManagementDnsZoneBindingsRequest\x12@\x0A\x06parent\x18\x01 \x01(\x09B0\xE0A\x02\xFAA*\x0A(vmwareengine.googleapis.com/PrivateCloud\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\x12\x0E\x0A\x06filter\x18\x04 \x01(\x09\x12\x10\x0A\x08order_by\x18\x05 \x01(\x09\"\xB3\x01\x0A%ListManagementDnsZoneBindingsResponse\x12\\\x0A\x1Cmanagement_dns_zone_bindings\x18\x01 \x03(\x0B26.google.cloud.vmwareengine.v1.ManagementDnsZoneBinding\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\x12\x13\x0A\x0Bunreachable\x18\x03 \x03(\x09\"p\x0A\"GetManagementDnsZoneBindingRequest\x12J\x0A\x04name\x18\x01 \x01(\x09B<\xE0A\x02\xFAA6\x0A4vmwareengine.googleapis.com/ManagementDnsZoneBinding\"\x91\x02\x0A%CreateManagementDnsZoneBindingRequest\x12@\x0A\x06parent\x18\x01 \x01(\x09B0\xE0A\x02\xFAA*\x0A(vmwareengine.googleapis.com/PrivateCloud\x12`\x0A\x1Bmanagement_dns_zone_binding\x18\x02 \x01(\x0B26.google.cloud.vmwareengine.v1.ManagementDnsZoneBindingB\x03\xE0A\x02\x12+\x0A\x1Emanagement_dns_zone_binding_id\x18\x03 \x01(\x09B\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x04 \x01(\x09B\x03\xE0A\x01\"\xD8\x01\x0A%UpdateManagementDnsZoneBindingRequest\x124\x0A\x0Bupdate_mask\x18\x01 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x02\x12`\x0A\x1Bmanagement_dns_zone_binding\x18\x02 \x01(\x0B26.google.cloud.vmwareengine.v1.ManagementDnsZoneBindingB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x03\xE0A\x01\"\x8C\x01\x0A%DeleteManagementDnsZoneBindingRequest\x12J\x0A\x04name\x18\x01 \x01(\x09B<\xE0A\x02\xFAA6\x0A4vmwareengine.googleapis.com/ManagementDnsZoneBinding\x12\x17\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x03\xE0A\x01\"\x8C\x01\x0A%RepairManagementDnsZoneBindingRequest\x12J\x0A\x04name\x18\x01 \x01(\x09B<\xE0A\x02\xFAA6\x0A4vmwareengine.googleapis.com/ManagementDnsZoneBinding\x12\x17\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x03\xE0A\x01\"\x82\x02\x0A CreateVmwareEngineNetworkRequest\x12G\x0A\x06parent\x18\x01 \x01(\x09B7\xE0A\x02\xFAA1\x12/vmwareengine.googleapis.com/VmwareEngineNetwork\x12%\x0A\x18vmware_engine_network_id\x18\x02 \x01(\x09B\x03\xE0A\x02\x12U\x0A\x15vmware_engine_network\x18\x03 \x01(\x0B21.google.cloud.vmwareengine.v1.VmwareEngineNetworkB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x04 \x01(\x09B\x03\xE0A\x01\"\xC8\x01\x0A UpdateVmwareEngineNetworkRequest\x12U\x0A\x15vmware_engine_network\x18\x01 \x01(\x0B21.google.cloud.vmwareengine.v1.VmwareEngineNetworkB\x03\xE0A\x02\x124\x0A\x0Bupdate_mask\x18\x02 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x03\xE0A\x01\"\x95\x01\x0A DeleteVmwareEngineNetworkRequest\x12E\x0A\x04name\x18\x01 \x01(\x09B7\xE0A\x02\xFAA1\x0A/vmwareengine.googleapis.com/VmwareEngineNetwork\x12\x17\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x03\xE0A\x01\x12\x11\x0A\x04etag\x18\x03 \x01(\x09B\x03\xE0A\x01\"f\x0A\x1DGetVmwareEngineNetworkRequest\x12E\x0A\x04name\x18\x01 \x01(\x09B7\xE0A\x02\xFAA1\x0A/vmwareengine.googleapis.com/VmwareEngineNetwork\"\xA5\x01\x0A\x1FListVmwareEngineNetworksRequest\x129\x0A\x06parent\x18\x01 \x01(\x09B)\xE0A\x02\xFAA#\x0A!locations.googleapis.com/Location\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\x12\x0E\x0A\x06filter\x18\x04 \x01(\x09\x12\x10\x0A\x08order_by\x18\x05 \x01(\x09\"\xA3\x01\x0A ListVmwareEngineNetworksResponse\x12Q\x0A\x16vmware_engine_networks\x18\x01 \x03(\x0B21.google.cloud.vmwareengine.v1.VmwareEngineNetwork\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\x12\x13\x0A\x0Bunreachable\x18\x03 \x03(\x09\"\xF6\x01\x0A\x1ECreatePrivateConnectionRequest\x12E\x0A\x06parent\x18\x01 \x01(\x09B5\xE0A\x02\xFAA/\x12-vmwareengine.googleapis.com/PrivateConnection\x12\"\x0A\x15private_connection_id\x18\x02 \x01(\x09B\x03\xE0A\x02\x12P\x0A\x12private_connection\x18\x03 \x01(\x0B2/.google.cloud.vmwareengine.v1.PrivateConnectionB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x04 \x01(\x09B\x03\xE0A\x01\"b\x0A\x1BGetPrivateConnectionRequest\x12C\x0A\x04name\x18\x01 \x01(\x09B5\xE0A\x02\xFAA/\x0A-vmwareengine.googleapis.com/PrivateConnection\"\xAF\x01\x0A\x1DListPrivateConnectionsRequest\x12E\x0A\x06parent\x18\x01 \x01(\x09B5\xE0A\x02\xFAA/\x12-vmwareengine.googleapis.com/PrivateConnection\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\x12\x0E\x0A\x06filter\x18\x04 \x01(\x09\x12\x10\x0A\x08order_by\x18\x05 \x01(\x09\"\x9C\x01\x0A\x1EListPrivateConnectionsResponse\x12L\x0A\x13private_connections\x18\x01 \x03(\x0B2/.google.cloud.vmwareengine.v1.PrivateConnection\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\x12\x13\x0A\x0Bunreachable\x18\x03 \x03(\x09\"\xC1\x01\x0A\x1EUpdatePrivateConnectionRequest\x12P\x0A\x12private_connection\x18\x01 \x01(\x0B2/.google.cloud.vmwareengine.v1.PrivateConnectionB\x03\xE0A\x02\x124\x0A\x0Bupdate_mask\x18\x02 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x03\xE0A\x01\"~\x0A\x1EDeletePrivateConnectionRequest\x12C\x0A\x04name\x18\x01 \x01(\x09B5\xE0A\x02\xFAA/\x0A-vmwareengine.googleapis.com/PrivateConnection\x12\x17\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x03\xE0A\x01\"\x99\x01\x0A)ListPrivateConnectionPeeringRoutesRequest\x12E\x0A\x06parent\x18\x01 \x01(\x09B5\xE0A\x02\xFAA/\x0A-vmwareengine.googleapis.com/PrivateConnection\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\"\x89\x01\x0A*ListPrivateConnectionPeeringRoutesResponse\x12B\x0A\x0Epeering_routes\x18\x01 \x03(\x0B2*.google.cloud.vmwareengine.v1.PeeringRoute\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\"\xBE\x01\x0A\x1DGrantDnsBindPermissionRequest\x12C\x0A\x04name\x18\x01 \x01(\x09B5\xE0A\x02\xFAA/\x0A-vmwareengine.googleapis.com/DnsBindPermission\x12?\x0A\x09principal\x18\x02 \x01(\x0B2'.google.cloud.vmwareengine.v1.PrincipalB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x03\xE0A\x01\"\xBF\x01\x0A\x1ERevokeDnsBindPermissionRequest\x12C\x0A\x04name\x18\x01 \x01(\x09B5\xE0A\x02\xFAA/\x0A-vmwareengine.googleapis.com/DnsBindPermission\x12?\x0A\x09principal\x18\x02 \x01(\x0B2'.google.cloud.vmwareengine.v1.PrincipalB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x03\xE0A\x01\"b\x0A\x1BGetDnsBindPermissionRequest\x12C\x0A\x04name\x18\x01 \x01(\x09B5\xE0A\x02\xFAA/\x0A-vmwareengine.googleapis.com/DnsBindPermission2\xDC\x8E\x01\x0A\x0CVmwareEngine\x12\xC8\x01\x0A\x11ListPrivateClouds\x126.google.cloud.vmwareengine.v1.ListPrivateCloudsRequest\x1A7.google.cloud.vmwareengine.v1.ListPrivateCloudsResponse\"B\xDAA\x06parent\x82\xD3\xE4\x93\x023\x121/v1/{parent=projects/*/locations/*}/privateClouds\x12\xB5\x01\x0A\x0FGetPrivateCloud\x124.google.cloud.vmwareengine.v1.GetPrivateCloudRequest\x1A*.google.cloud.vmwareengine.v1.PrivateCloud\"@\xDAA\x04name\x82\xD3\xE4\x93\x023\x121/v1/{name=projects/*/locations/*/privateClouds/*}\x12\x83\x02\x0A\x12CreatePrivateCloud\x127.google.cloud.vmwareengine.v1.CreatePrivateCloudRequest\x1A\x1D.google.longrunning.Operation\"\x94\x01\xCAA!\x0A\x0CPrivateCloud\x12\x11OperationMetadata\xDAA%parent,private_cloud,private_cloud_id\x82\xD3\xE4\x93\x02B\"1/v1/{parent=projects/*/locations/*}/privateClouds:\x0Dprivate_cloud\x12\x85\x02\x0A\x12UpdatePrivateCloud\x127.google.cloud.vmwareengine.v1.UpdatePrivateCloudRequest\x1A\x1D.google.longrunning.Operation\"\x96\x01\xCAA!\x0A\x0CPrivateCloud\x12\x11OperationMetadata\xDAA\x19private_cloud,update_mask\x82\xD3\xE4\x93\x02P2?/v1/{private_cloud.name=projects/*/locations/*/privateClouds/*}:\x0Dprivate_cloud\x12\xD2\x01\x0A\x12DeletePrivateCloud\x127.google.cloud.vmwareengine.v1.DeletePrivateCloudRequest\x1A\x1D.google.longrunning.Operation\"d\xCAA!\x0A\x0CPrivateCloud\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x023*1/v1/{name=projects/*/locations/*/privateClouds/*}\x12\xE2\x01\x0A\x14UndeletePrivateCloud\x129.google.cloud.vmwareengine.v1.UndeletePrivateCloudRequest\x1A\x1D.google.longrunning.Operation\"p\xCAA!\x0A\x0CPrivateCloud\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x02?\":/v1/{name=projects/*/locations/*/privateClouds/*}:undelete:\x01*\x12\xC4\x01\x0A\x0CListClusters\x121.google.cloud.vmwareengine.v1.ListClustersRequest\x1A2.google.cloud.vmwareengine.v1.ListClustersResponse\"M\xDAA\x06parent\x82\xD3\xE4\x93\x02>\x12\x12*\xDAA\x06parent\x82\xD3\xE4\x93\x02/\x12-/v1/{parent=projects/*/locations/*}/nodeTypes\x12\xA5\x01\x0A\x0BGetNodeType\x120.google.cloud.vmwareengine.v1.GetNodeTypeRequest\x1A&.google.cloud.vmwareengine.v1.NodeType\"<\xDAA\x04name\x82\xD3\xE4\x93\x02/\x12-/v1/{name=projects/*/locations/*/nodeTypes/*}\x12\xDF\x01\x0A\x12ShowNsxCredentials\x127.google.cloud.vmwareengine.v1.ShowNsxCredentialsRequest\x1A).google.cloud.vmwareengine.v1.Credentials\"e\xDAA\x0Dprivate_cloud\x82\xD3\xE4\x93\x02O\x12M/v1/{private_cloud=projects/*/locations/*/privateClouds/*}:showNsxCredentials\x12\xEB\x01\x0A\x16ShowVcenterCredentials\x12;.google.cloud.vmwareengine.v1.ShowVcenterCredentialsRequest\x1A).google.cloud.vmwareengine.v1.Credentials\"i\xDAA\x0Dprivate_cloud\x82\xD3\xE4\x93\x02S\x12Q/v1/{private_cloud=projects/*/locations/*/privateClouds/*}:showVcenterCredentials\x12\xFE\x01\x0A\x13ResetNsxCredentials\x128.google.cloud.vmwareengine.v1.ResetNsxCredentialsRequest\x1A\x1D.google.longrunning.Operation\"\x8D\x01\xCAA!\x0A\x0CPrivateCloud\x12\x11OperationMetadata\xDAA\x0Dprivate_cloud\x82\xD3\xE4\x93\x02S\"N/v1/{private_cloud=projects/*/locations/*/privateClouds/*}:resetNsxCredentials:\x01*\x12\x8A\x02\x0A\x17ResetVcenterCredentials\x12<.google.cloud.vmwareengine.v1.ResetVcenterCredentialsRequest\x1A\x1D.google.longrunning.Operation\"\x91\x01\xCAA!\x0A\x0CPrivateCloud\x12\x11OperationMetadata\xDAA\x0Dprivate_cloud\x82\xD3\xE4\x93\x02W\"R/v1/{private_cloud=projects/*/locations/*/privateClouds/*}:resetVcenterCredentials:\x01*\x12\xC6\x01\x0A\x10GetDnsForwarding\x125.google.cloud.vmwareengine.v1.GetDnsForwardingRequest\x1A+.google.cloud.vmwareengine.v1.DnsForwarding\"N\xDAA\x04name\x82\xD3\xE4\x93\x02A\x12?/v1/{name=projects/*/locations/*/privateClouds/*/dnsForwarding}\x12\x99\x02\x0A\x13UpdateDnsForwarding\x128.google.cloud.vmwareengine.v1.UpdateDnsForwardingRequest\x1A\x1D.google.longrunning.Operation\"\xA8\x01\xCAA\"\x0A\x0DDnsForwarding\x12\x11OperationMetadata\xDAA\x1Adns_forwarding,update_mask\x82\xD3\xE4\x93\x02`2N/v1/{dns_forwarding.name=projects/*/locations/*/privateClouds/*/dnsForwarding}:\x0Edns_forwarding\x12\xBD\x01\x0A\x11GetNetworkPeering\x126.google.cloud.vmwareengine.v1.GetNetworkPeeringRequest\x1A,.google.cloud.vmwareengine.v1.NetworkPeering\"B\xDAA\x04name\x82\xD3\xE4\x93\x025\x123/v1/{name=projects/*/locations/*/networkPeerings/*}\x12\xD0\x01\x0A\x13ListNetworkPeerings\x128.google.cloud.vmwareengine.v1.ListNetworkPeeringsRequest\x1A9.google.cloud.vmwareengine.v1.ListNetworkPeeringsResponse\"D\xDAA\x06parent\x82\xD3\xE4\x93\x025\x123/v1/{parent=projects/*/locations/*}/networkPeerings\x12\x91\x02\x0A\x14CreateNetworkPeering\x129.google.cloud.vmwareengine.v1.CreateNetworkPeeringRequest\x1A\x1D.google.longrunning.Operation\"\x9E\x01\xCAA#\x0A\x0ENetworkPeering\x12\x11OperationMetadata\xDAA)parent,network_peering,network_peering_id\x82\xD3\xE4\x93\x02F\"3/v1/{parent=projects/*/locations/*}/networkPeerings:\x0Fnetwork_peering\x12\xE1\x01\x0A\x14DeleteNetworkPeering\x129.google.cloud.vmwareengine.v1.DeleteNetworkPeeringRequest\x1A\x1D.google.longrunning.Operation\"o\xCAA*\x0A\x15google.protobuf.Empty\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x025*3/v1/{name=projects/*/locations/*/networkPeerings/*}\x12\x93\x02\x0A\x14UpdateNetworkPeering\x129.google.cloud.vmwareengine.v1.UpdateNetworkPeeringRequest\x1A\x1D.google.longrunning.Operation\"\xA0\x01\xCAA#\x0A\x0ENetworkPeering\x12\x11OperationMetadata\xDAA\x1Bnetwork_peering,update_mask\x82\xD3\xE4\x93\x02V2C/v1/{network_peering.name=projects/*/locations/*/networkPeerings/*}:\x0Fnetwork_peering\x12\xDA\x01\x0A\x11ListPeeringRoutes\x126.google.cloud.vmwareengine.v1.ListPeeringRoutesRequest\x1A7.google.cloud.vmwareengine.v1.ListPeeringRoutesResponse\"T\xDAA\x06parent\x82\xD3\xE4\x93\x02E\x12C/v1/{parent=projects/*/locations/*/networkPeerings/*}/peeringRoutes\x12\xB2\x02\x0A\x16CreateHcxActivationKey\x12;.google.cloud.vmwareengine.v1.CreateHcxActivationKeyRequest\x1A\x1D.google.longrunning.Operation\"\xBB\x01\xCAA%\x0A\x10HcxActivationKey\x12\x11OperationMetadata\xDAA/parent,hcx_activation_key,hcx_activation_key_id\x82\xD3\xE4\x93\x02[\"E/v1/{parent=projects/*/locations/*/privateClouds/*}/hcxActivationKeys:\x12hcx_activation_key\x12\xE8\x01\x0A\x15ListHcxActivationKeys\x12:.google.cloud.vmwareengine.v1.ListHcxActivationKeysRequest\x1A;.google.cloud.vmwareengine.v1.ListHcxActivationKeysResponse\"V\xDAA\x06parent\x82\xD3\xE4\x93\x02G\x12E/v1/{parent=projects/*/locations/*/privateClouds/*}/hcxActivationKeys\x12\xD5\x01\x0A\x13GetHcxActivationKey\x128.google.cloud.vmwareengine.v1.GetHcxActivationKeyRequest\x1A..google.cloud.vmwareengine.v1.HcxActivationKey\"T\xDAA\x04name\x82\xD3\xE4\x93\x02G\x12E/v1/{name=projects/*/locations/*/privateClouds/*/hcxActivationKeys/*}\x12\xBA\x01\x0A\x10GetNetworkPolicy\x125.google.cloud.vmwareengine.v1.GetNetworkPolicyRequest\x1A+.google.cloud.vmwareengine.v1.NetworkPolicy\"B\xDAA\x04name\x82\xD3\xE4\x93\x025\x123/v1/{name=projects/*/locations/*/networkPolicies/*}\x12\xD0\x01\x0A\x13ListNetworkPolicies\x128.google.cloud.vmwareengine.v1.ListNetworkPoliciesRequest\x1A9.google.cloud.vmwareengine.v1.ListNetworkPoliciesResponse\"D\xDAA\x06parent\x82\xD3\xE4\x93\x025\x123/v1/{parent=projects/*/locations/*}/networkPolicies\x12\x8B\x02\x0A\x13CreateNetworkPolicy\x128.google.cloud.vmwareengine.v1.CreateNetworkPolicyRequest\x1A\x1D.google.longrunning.Operation\"\x9A\x01\xCAA\"\x0A\x0DNetworkPolicy\x12\x11OperationMetadata\xDAA'parent,network_policy,network_policy_id\x82\xD3\xE4\x93\x02E\"3/v1/{parent=projects/*/locations/*}/networkPolicies:\x0Enetwork_policy\x12\x8D\x02\x0A\x13UpdateNetworkPolicy\x128.google.cloud.vmwareengine.v1.UpdateNetworkPolicyRequest\x1A\x1D.google.longrunning.Operation\"\x9C\x01\xCAA\"\x0A\x0DNetworkPolicy\x12\x11OperationMetadata\xDAA\x1Anetwork_policy,update_mask\x82\xD3\xE4\x93\x02T2B/v1/{network_policy.name=projects/*/locations/*/networkPolicies/*}:\x0Enetwork_policy\x12\xDF\x01\x0A\x13DeleteNetworkPolicy\x128.google.cloud.vmwareengine.v1.DeleteNetworkPolicyRequest\x1A\x1D.google.longrunning.Operation\"o\xCAA*\x0A\x15google.protobuf.Empty\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x025*3/v1/{name=projects/*/locations/*/networkPolicies/*}\x12\x88\x02\x0A\x1DListManagementDnsZoneBindings\x12B.google.cloud.vmwareengine.v1.ListManagementDnsZoneBindingsRequest\x1AC.google.cloud.vmwareengine.v1.ListManagementDnsZoneBindingsResponse\"^\xDAA\x06parent\x82\xD3\xE4\x93\x02O\x12M/v1/{parent=projects/*/locations/*/privateClouds/*}/managementDnsZoneBindings\x12\xF5\x01\x0A\x1BGetManagementDnsZoneBinding\x12@.google.cloud.vmwareengine.v1.GetManagementDnsZoneBindingRequest\x1A6.google.cloud.vmwareengine.v1.ManagementDnsZoneBinding\"\\\xDAA\x04name\x82\xD3\xE4\x93\x02O\x12M/v1/{name=projects/*/locations/*/privateClouds/*/managementDnsZoneBindings/*}\x12\xED\x02\x0A\x1ECreateManagementDnsZoneBinding\x12C.google.cloud.vmwareengine.v1.CreateManagementDnsZoneBindingRequest\x1A\x1D.google.longrunning.Operation\"\xE6\x01\xCAA-\x0A\x18ManagementDnsZoneBinding\x12\x11OperationMetadata\xDAAAparent,management_dns_zone_binding,management_dns_zone_binding_id\x82\xD3\xE4\x93\x02l\"M/v1/{parent=projects/*/locations/*/privateClouds/*}/managementDnsZoneBindings:\x1Bmanagement_dns_zone_binding\x12\xF0\x02\x0A\x1EUpdateManagementDnsZoneBinding\x12C.google.cloud.vmwareengine.v1.UpdateManagementDnsZoneBindingRequest\x1A\x1D.google.longrunning.Operation\"\xE9\x01\xCAA-\x0A\x18ManagementDnsZoneBinding\x12\x11OperationMetadata\xDAA'management_dns_zone_binding,update_mask\x82\xD3\xE4\x93\x02\x88\x012i/v1/{management_dns_zone_binding.name=projects/*/locations/*/privateClouds/*/managementDnsZoneBindings/*}:\x1Bmanagement_dns_zone_binding\x12\x90\x02\x0A\x1EDeleteManagementDnsZoneBinding\x12C.google.cloud.vmwareengine.v1.DeleteManagementDnsZoneBindingRequest\x1A\x1D.google.longrunning.Operation\"\x89\x01\xCAA*\x0A\x15google.protobuf.Empty\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x02O*M/v1/{name=projects/*/locations/*/privateClouds/*/managementDnsZoneBindings/*}\x12\x9D\x02\x0A\x1ERepairManagementDnsZoneBinding\x12C.google.cloud.vmwareengine.v1.RepairManagementDnsZoneBindingRequest\x1A\x1D.google.longrunning.Operation\"\x96\x01\xCAA-\x0A\x18ManagementDnsZoneBinding\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x02Y\"T/v1/{name=projects/*/locations/*/privateClouds/*/managementDnsZoneBindings/*}:repair:\x01*\x12\xB7\x02\x0A\x19CreateVmwareEngineNetwork\x12>.google.cloud.vmwareengine.v1.CreateVmwareEngineNetworkRequest\x1A\x1D.google.longrunning.Operation\"\xBA\x01\xCAA(\x0A\x13VmwareEngineNetwork\x12\x11OperationMetadata\xDAA5parent,vmware_engine_network,vmware_engine_network_id\x82\xD3\xE4\x93\x02Q\"8/v1/{parent=projects/*/locations/*}/vmwareEngineNetworks:\x15vmware_engine_network\x12\xB9\x02\x0A\x19UpdateVmwareEngineNetwork\x12>.google.cloud.vmwareengine.v1.UpdateVmwareEngineNetworkRequest\x1A\x1D.google.longrunning.Operation\"\xBC\x01\xCAA(\x0A\x13VmwareEngineNetwork\x12\x11OperationMetadata\xDAA!vmware_engine_network,update_mask\x82\xD3\xE4\x93\x02g2N/v1/{vmware_engine_network.name=projects/*/locations/*/vmwareEngineNetworks/*}:\x15vmware_engine_network\x12\xF0\x01\x0A\x19DeleteVmwareEngineNetwork\x12>.google.cloud.vmwareengine.v1.DeleteVmwareEngineNetworkRequest\x1A\x1D.google.longrunning.Operation\"t\xCAA*\x0A\x15google.protobuf.Empty\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x02:*8/v1/{name=projects/*/locations/*/vmwareEngineNetworks/*}\x12\xD1\x01\x0A\x16GetVmwareEngineNetwork\x12;.google.cloud.vmwareengine.v1.GetVmwareEngineNetworkRequest\x1A1.google.cloud.vmwareengine.v1.VmwareEngineNetwork\"G\xDAA\x04name\x82\xD3\xE4\x93\x02:\x128/v1/{name=projects/*/locations/*/vmwareEngineNetworks/*}\x12\xE4\x01\x0A\x18ListVmwareEngineNetworks\x12=.google.cloud.vmwareengine.v1.ListVmwareEngineNetworksRequest\x1A>.google.cloud.vmwareengine.v1.ListVmwareEngineNetworksResponse\"I\xDAA\x06parent\x82\xD3\xE4\x93\x02:\x128/v1/{parent=projects/*/locations/*}/vmwareEngineNetworks\x12\xA6\x02\x0A\x17CreatePrivateConnection\x12<.google.cloud.vmwareengine.v1.CreatePrivateConnectionRequest\x1A\x1D.google.longrunning.Operation\"\xAD\x01\xCAA&\x0A\x11PrivateConnection\x12\x11OperationMetadata\xDAA/parent,private_connection,private_connection_id\x82\xD3\xE4\x93\x02L\"6/v1/{parent=projects/*/locations/*}/privateConnections:\x12private_connection\x12\xC9\x01\x0A\x14GetPrivateConnection\x129.google.cloud.vmwareengine.v1.GetPrivateConnectionRequest\x1A/.google.cloud.vmwareengine.v1.PrivateConnection\"E\xDAA\x04name\x82\xD3\xE4\x93\x028\x126/v1/{name=projects/*/locations/*/privateConnections/*}\x12\xDC\x01\x0A\x16ListPrivateConnections\x12;.google.cloud.vmwareengine.v1.ListPrivateConnectionsRequest\x1A<.google.cloud.vmwareengine.v1.ListPrivateConnectionsResponse\"G\xDAA\x06parent\x82\xD3\xE4\x93\x028\x126/v1/{parent=projects/*/locations/*}/privateConnections\x12\xA8\x02\x0A\x17UpdatePrivateConnection\x12<.google.cloud.vmwareengine.v1.UpdatePrivateConnectionRequest\x1A\x1D.google.longrunning.Operation\"\xAF\x01\xCAA&\x0A\x11PrivateConnection\x12\x11OperationMetadata\xDAA\x1Eprivate_connection,update_mask\x82\xD3\xE4\x93\x02_2I/v1/{private_connection.name=projects/*/locations/*/privateConnections/*}:\x12private_connection\x12\xEA\x01\x0A\x17DeletePrivateConnection\x12<.google.cloud.vmwareengine.v1.DeletePrivateConnectionRequest\x1A\x1D.google.longrunning.Operation\"r\xCAA*\x0A\x15google.protobuf.Empty\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x028*6/v1/{name=projects/*/locations/*/privateConnections/*}\x12\x90\x02\x0A\"ListPrivateConnectionPeeringRoutes\x12G.google.cloud.vmwareengine.v1.ListPrivateConnectionPeeringRoutesRequest\x1AH.google.cloud.vmwareengine.v1.ListPrivateConnectionPeeringRoutesResponse\"W\xDAA\x06parent\x82\xD3\xE4\x93\x02H\x12F/v1/{parent=projects/*/locations/*/privateConnections/*}/peeringRoutes\x12\xF4\x01\x0A\x16GrantDnsBindPermission\x12;.google.cloud.vmwareengine.v1.GrantDnsBindPermissionRequest\x1A\x1D.google.longrunning.Operation\"~\xCAA&\x0A\x11DnsBindPermission\x12\x11OperationMetadata\xDAA\x0Ename,principal\x82\xD3\xE4\x93\x02>\"9/v1/{name=projects/*/locations/*/dnsBindPermission}:grant:\x01*\x12\xC6\x01\x0A\x14GetDnsBindPermission\x129.google.cloud.vmwareengine.v1.GetDnsBindPermissionRequest\x1A/.google.cloud.vmwareengine.v1.DnsBindPermission\"B\xDAA\x04name\x82\xD3\xE4\x93\x025\x123/v1/{name=projects/*/locations/*/dnsBindPermission}\x12\xF7\x01\x0A\x17RevokeDnsBindPermission\x12<.google.cloud.vmwareengine.v1.RevokeDnsBindPermissionRequest\x1A\x1D.google.longrunning.Operation\"\x7F\xCAA&\x0A\x11DnsBindPermission\x12\x11OperationMetadata\xDAA\x0Ename,principal\x82\xD3\xE4\x93\x02?\":/v1/{name=projects/*/locations/*/dnsBindPermission}:revoke:\x01*\x1AO\xCAA\x1Bvmwareengine.googleapis.com\xD2A.https://www.googleapis.com/auth/cloud-platformB\xAE\x02\x0A com.google.cloud.vmwareengine.v1B\x11VmwareengineProtoP\x01ZDcloud.google.com/go/vmwareengine/apiv1/vmwareenginepb;vmwareenginepb\xAA\x02\x1CGoogle.Cloud.VmwareEngine.V1\xCA\x02\x1CGoogle\\Cloud\\VmwareEngine\\V1\xEA\x02\x1FGoogle::Cloud::VmwareEngine::V1\xEAAN\x0A\x1Ecompute.googleapis.com/Network\x12,projects/{project}/global/networks/{network}b\x06proto3" - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/GPBMetadata/Google/Cloud/Vmwareengine/V1/VmwareengineResources.php b/owl-bot-staging/VmwareEngine/v1/proto/src/GPBMetadata/Google/Cloud/Vmwareengine/V1/VmwareengineResources.php deleted file mode 100644 index ff6a24d52935..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/GPBMetadata/Google/Cloud/Vmwareengine/V1/VmwareengineResources.php +++ /dev/null @@ -1,29 +0,0 @@ -internalAddGeneratedFile( - "\x0A\xB0z\x0A9google/cloud/vmwareengine/v1/vmwareengine_resources.proto\x12\x1Cgoogle.cloud.vmwareengine.v1\x1A\x1Bgoogle/api/field_info.proto\x1A\x19google/api/resource.proto\x1A\x1Egoogle/protobuf/duration.proto\x1A\x1Fgoogle/protobuf/timestamp.proto\"\xB6\x02\x0A\x0DNetworkConfig\x12\x1C\x0A\x0Fmanagement_cidr\x18\x04 \x01(\x09B\x03\xE0A\x02\x12V\x0A\x15vmware_engine_network\x18\x05 \x01(\x09B7\xE0A\x01\xFAA1\x0A/vmwareengine.googleapis.com/VmwareEngineNetwork\x12`\x0A\x1Fvmware_engine_network_canonical\x18\x06 \x01(\x09B7\xE0A\x03\xFAA1\x0A/vmwareengine.googleapis.com/VmwareEngineNetwork\x121\x0A\$management_ip_address_layout_version\x18\x08 \x01(\x05B\x03\xE0A\x03\x12\x1A\x0A\x0Ddns_server_ip\x18\x09 \x01(\x09B\x03\xE0A\x03\"I\x0A\x0ENodeTypeConfig\x12\x17\x0A\x0Anode_count\x18\x01 \x01(\x05B\x03\xE0A\x02\x12\x1E\x0A\x11custom_core_count\x18\x02 \x01(\x05B\x03\xE0A\x01\"\xA6\x01\x0A\x16StretchedClusterConfig\x12E\x0A\x12preferred_location\x18\x01 \x01(\x09B)\xE0A\x02\xFAA#\x0A!locations.googleapis.com/Location\x12E\x0A\x12secondary_location\x18\x02 \x01(\x09B)\xE0A\x02\xFAA#\x0A!locations.googleapis.com/Location\"\xFD\x0A\x0A\x0CPrivateCloud\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x03\x124\x0A\x0Bcreate_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x03 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bdelete_time\x18\x04 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bexpire_time\x18\x05 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12D\x0A\x05state\x18\x08 \x01(\x0E20.google.cloud.vmwareengine.v1.PrivateCloud.StateB\x03\xE0A\x03\x12H\x0A\x0Enetwork_config\x18\x09 \x01(\x0B2+.google.cloud.vmwareengine.v1.NetworkConfigB\x03\xE0A\x02\x12`\x0A\x12management_cluster\x18\x0A \x01(\x0B2<.google.cloud.vmwareengine.v1.PrivateCloud.ManagementClusterB\x06\xE0A\x04\xE0A\x02\x12\x13\x0A\x0Bdescription\x18\x0B \x01(\x09\x123\x0A\x03hcx\x18\x11 \x01(\x0B2!.google.cloud.vmwareengine.v1.HcxB\x03\xE0A\x03\x123\x0A\x03nsx\x18\x12 \x01(\x0B2!.google.cloud.vmwareengine.v1.NsxB\x03\xE0A\x03\x12;\x0A\x07vcenter\x18\x13 \x01(\x0B2%.google.cloud.vmwareengine.v1.VcenterB\x03\xE0A\x03\x12\x10\x0A\x03uid\x18\x14 \x01(\x09B\x03\xE0A\x03\x12B\x0A\x04type\x18\x16 \x01(\x0E2/.google.cloud.vmwareengine.v1.PrivateCloud.TypeB\x03\xE0A\x01\x1A\xE2\x02\x0A\x11ManagementCluster\x12\x17\x0A\x0Acluster_id\x18\x01 \x01(\x09B\x03\xE0A\x02\x12q\x0A\x11node_type_configs\x18\x07 \x03(\x0B2Q.google.cloud.vmwareengine.v1.PrivateCloud.ManagementCluster.NodeTypeConfigsEntryB\x03\xE0A\x02\x12[\x0A\x18stretched_cluster_config\x18\x08 \x01(\x0B24.google.cloud.vmwareengine.v1.StretchedClusterConfigB\x03\xE0A\x01\x1Ad\x0A\x14NodeTypeConfigsEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12;\x0A\x05value\x18\x02 \x01(\x0B2,.google.cloud.vmwareengine.v1.NodeTypeConfig:\x028\x01\"l\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x0A\x0A\x06ACTIVE\x10\x01\x12\x0C\x0A\x08CREATING\x10\x02\x12\x0C\x0A\x08UPDATING\x10\x03\x12\x0A\x0A\x06FAILED\x10\x05\x12\x0B\x0A\x07DELETED\x10\x06\x12\x0B\x0A\x07PURGING\x10\x07\"5\x0A\x04Type\x12\x0C\x0A\x08STANDARD\x10\x00\x12\x10\x0A\x0CTIME_LIMITED\x10\x01\x12\x0D\x0A\x09STRETCHED\x10\x02:t\xEAAq\x0A(vmwareengine.googleapis.com/PrivateCloud\x12Eprojects/{project}/locations/{location}/privateClouds/{private_cloud}\"\xD3\x06\x0A\x07Cluster\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x03\x124\x0A\x0Bcreate_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x03 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12?\x0A\x05state\x18\x06 \x01(\x0E2+.google.cloud.vmwareengine.v1.Cluster.StateB\x03\xE0A\x03\x12\x17\x0A\x0Amanagement\x18\x07 \x01(\x08B\x03\xE0A\x03\x12T\x0A\x14autoscaling_settings\x18\x12 \x01(\x0B21.google.cloud.vmwareengine.v1.AutoscalingSettingsB\x03\xE0A\x01\x12\x10\x0A\x03uid\x18\x0E \x01(\x09B\x03\xE0A\x03\x12Z\x0A\x11node_type_configs\x18\x10 \x03(\x0B2:.google.cloud.vmwareengine.v1.Cluster.NodeTypeConfigsEntryB\x03\xE0A\x02\x12[\x0A\x18stretched_cluster_config\x18\x11 \x01(\x0B24.google.cloud.vmwareengine.v1.StretchedClusterConfigB\x03\xE0A\x01\x1Ad\x0A\x14NodeTypeConfigsEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12;\x0A\x05value\x18\x02 \x01(\x0B2,.google.cloud.vmwareengine.v1.NodeTypeConfig:\x028\x01\"c\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x0A\x0A\x06ACTIVE\x10\x01\x12\x0C\x0A\x08CREATING\x10\x02\x12\x0C\x0A\x08UPDATING\x10\x03\x12\x0C\x0A\x08DELETING\x10\x04\x12\x0D\x0A\x09REPAIRING\x10\x05:\x82\x01\xEAA\x7F\x0A#vmwareengine.googleapis.com/Cluster\x12Xprojects/{project}/locations/{location}/privateClouds/{private_cloud}/clusters/{cluster}\"\xBA\x03\x0A\x04Node\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x03\x12\x11\x0A\x04fqdn\x18\x02 \x01(\x09B\x03\xE0A\x03\x12\x18\x0A\x0Binternal_ip\x18\x03 \x01(\x09B\x03\xE0A\x03\x12\x19\x0A\x0Cnode_type_id\x18\x04 \x01(\x09B\x03\xE0A\x03\x12\x14\x0A\x07version\x18\x05 \x01(\x09B\x03\xE0A\x03\x12\x1E\x0A\x11custom_core_count\x18\x06 \x01(\x03B\x03\xE0A\x03\x12<\x0A\x05state\x18\x07 \x01(\x0E2(.google.cloud.vmwareengine.v1.Node.StateB\x03\xE0A\x03\"S\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x0A\x0A\x06ACTIVE\x10\x01\x12\x0C\x0A\x08CREATING\x10\x02\x12\x0A\x0A\x06FAILED\x10\x03\x12\x0D\x0A\x09UPGRADING\x10\x04:\x8D\x01\xEAA\x89\x01\x0A vmwareengine.googleapis.com/Node\x12eprojects/{project}/locations/{location}/privateClouds/{private_cloud}/clusters/{cluster}/nodes/{node}\"\xA5\x04\x0A\x0FExternalAddress\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x03\x124\x0A\x0Bcreate_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x03 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12\x13\x0A\x0Binternal_ip\x18\x06 \x01(\x09\x12\x18\x0A\x0Bexternal_ip\x18\x07 \x01(\x09B\x03\xE0A\x03\x12G\x0A\x05state\x18\x08 \x01(\x0E23.google.cloud.vmwareengine.v1.ExternalAddress.StateB\x03\xE0A\x03\x12\x10\x0A\x03uid\x18\x09 \x01(\x09B\x03\xE0A\x03\x12\x13\x0A\x0Bdescription\x18\x0B \x01(\x09\"T\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x0A\x0A\x06ACTIVE\x10\x01\x12\x0C\x0A\x08CREATING\x10\x02\x12\x0C\x0A\x08UPDATING\x10\x03\x12\x0C\x0A\x08DELETING\x10\x04:\x9D\x01\xEAA\x99\x01\x0A+vmwareengine.googleapis.com/ExternalAddress\x12jprojects/{project}/locations/{location}/privateClouds/{private_cloud}/externalAddresses/{external_address}\"\xA3\x03\x0A\x06Subnet\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x03\x12\x15\x0A\x0Dip_cidr_range\x18\x07 \x01(\x09\x12\x12\x0A\x0Agateway_ip\x18\x08 \x01(\x09\x12\x11\x0A\x04type\x18\x0B \x01(\x09B\x03\xE0A\x03\x12>\x0A\x05state\x18\x0D \x01(\x0E2*.google.cloud.vmwareengine.v1.Subnet.StateB\x03\xE0A\x03\x12\x14\x0A\x07vlan_id\x18\x10 \x01(\x05B\x03\xE0A\x03\"q\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x0A\x0A\x06ACTIVE\x10\x01\x12\x0C\x0A\x08CREATING\x10\x02\x12\x0C\x0A\x08UPDATING\x10\x03\x12\x0C\x0A\x08DELETING\x10\x04\x12\x0F\x0A\x0BRECONCILING\x10\x05\x12\x0A\x0A\x06FAILED\x10\x06:\x7F\xEAA|\x0A\"vmwareengine.googleapis.com/Subnet\x12Vprojects/{project}/locations/{location}/privateClouds/{private_cloud}/subnets/{subnet}\"\xA5\x08\x0A\x12ExternalAccessRule\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x03\x124\x0A\x0Bcreate_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x03 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12\x13\x0A\x0Bdescription\x18\x05 \x01(\x09\x12\x10\x0A\x08priority\x18\x06 \x01(\x05\x12G\x0A\x06action\x18\x07 \x01(\x0E27.google.cloud.vmwareengine.v1.ExternalAccessRule.Action\x12\x13\x0A\x0Bip_protocol\x18\x08 \x01(\x09\x12R\x0A\x10source_ip_ranges\x18\x09 \x03(\x0B28.google.cloud.vmwareengine.v1.ExternalAccessRule.IpRange\x12\x14\x0A\x0Csource_ports\x18\x0A \x03(\x09\x12W\x0A\x15destination_ip_ranges\x18\x0B \x03(\x0B28.google.cloud.vmwareengine.v1.ExternalAccessRule.IpRange\x12\x19\x0A\x11destination_ports\x18\x0C \x03(\x09\x12J\x0A\x05state\x18\x0D \x01(\x0E26.google.cloud.vmwareengine.v1.ExternalAccessRule.StateB\x03\xE0A\x03\x12\x10\x0A\x03uid\x18\x0E \x01(\x09B\x03\xE0A\x03\x1A\x95\x01\x0A\x07IpRange\x12\x14\x0A\x0Aip_address\x18\x01 \x01(\x09H\x00\x12\x1A\x0A\x10ip_address_range\x18\x02 \x01(\x09H\x00\x12L\x0A\x10external_address\x18\x03 \x01(\x09B0\xFAA-\x0A+vmwareengine.googleapis.com/ExternalAddressH\x00B\x0A\x0A\x08ip_range\"5\x0A\x06Action\x12\x16\x0A\x12ACTION_UNSPECIFIED\x10\x00\x12\x09\x0A\x05ALLOW\x10\x01\x12\x08\x0A\x04DENY\x10\x02\"T\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x0A\x0A\x06ACTIVE\x10\x01\x12\x0C\x0A\x08CREATING\x10\x02\x12\x0C\x0A\x08UPDATING\x10\x03\x12\x0C\x0A\x08DELETING\x10\x04:\xA9\x01\xEAA\xA5\x01\x0A.vmwareengine.googleapis.com/ExternalAccessRule\x12sprojects/{project}/locations/{location}/networkPolicies/{network_policy}/externalAccessRules/{external_access_rule}\"\x95\x05\x0A\x0DLoggingServer\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x03\x124\x0A\x0Bcreate_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x03 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12\x15\x0A\x08hostname\x18\x05 \x01(\x09B\x03\xE0A\x02\x12\x11\x0A\x04port\x18\x07 \x01(\x05B\x03\xE0A\x02\x12K\x0A\x08protocol\x18\x06 \x01(\x0E24.google.cloud.vmwareengine.v1.LoggingServer.ProtocolB\x03\xE0A\x02\x12P\x0A\x0Bsource_type\x18\x0A \x01(\x0E26.google.cloud.vmwareengine.v1.LoggingServer.SourceTypeB\x03\xE0A\x02\x12\x10\x0A\x03uid\x18\x08 \x01(\x09B\x03\xE0A\x03\"R\x0A\x08Protocol\x12\x18\x0A\x14PROTOCOL_UNSPECIFIED\x10\x00\x12\x07\x0A\x03UDP\x10\x01\x12\x07\x0A\x03TCP\x10\x02\x12\x07\x0A\x03TLS\x10\x03\x12\x07\x0A\x03SSL\x10\x04\x12\x08\x0A\x04RELP\x10\x05\"=\x0A\x0ASourceType\x12\x1B\x0A\x17SOURCE_TYPE_UNSPECIFIED\x10\x00\x12\x08\x0A\x04ESXI\x10\x01\x12\x08\x0A\x04VCSA\x10\x02:\x96\x01\xEAA\x92\x01\x0A)vmwareengine.googleapis.com/LoggingServer\x12eprojects/{project}/locations/{location}/privateClouds/{private_cloud}/loggingServers/{logging_server}\"\xFF\x04\x0A\x08NodeType\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x03\x12\x19\x0A\x0Cnode_type_id\x18\x02 \x01(\x09B\x03\xE0A\x03\x12\x19\x0A\x0Cdisplay_name\x18\x03 \x01(\x09B\x03\xE0A\x03\x12\x1E\x0A\x11virtual_cpu_count\x18\x04 \x01(\x05B\x03\xE0A\x03\x12\x1D\x0A\x10total_core_count\x18\x05 \x01(\x05B\x03\xE0A\x03\x12\x16\x0A\x09memory_gb\x18\x07 \x01(\x05B\x03\xE0A\x03\x12\x19\x0A\x0Cdisk_size_gb\x18\x08 \x01(\x05B\x03\xE0A\x03\x12)\x0A\x1Cavailable_custom_core_counts\x18\x0B \x03(\x05B\x03\xE0A\x03\x12>\x0A\x04kind\x18\x0C \x01(\x0E2+.google.cloud.vmwareengine.v1.NodeType.KindB\x03\xE0A\x03\x12\x15\x0A\x08families\x18\x0D \x03(\x09B\x03\xE0A\x03\x12L\x0A\x0Ccapabilities\x18\x0E \x03(\x0E21.google.cloud.vmwareengine.v1.NodeType.CapabilityB\x03\xE0A\x03\"<\x0A\x04Kind\x12\x14\x0A\x10KIND_UNSPECIFIED\x10\x00\x12\x0C\x0A\x08STANDARD\x10\x01\x12\x10\x0A\x0CSTORAGE_ONLY\x10\x02\"@\x0A\x0ACapability\x12\x1A\x0A\x16CAPABILITY_UNSPECIFIED\x10\x00\x12\x16\x0A\x12STRETCHED_CLUSTERS\x10\x01:h\xEAAe\x0A\$vmwareengine.googleapis.com/NodeType\x12=projects/{project}/locations/{location}/nodeTypes/{node_type}\"1\x0A\x0BCredentials\x12\x10\x0A\x08username\x18\x01 \x01(\x09\x12\x10\x0A\x08password\x18\x02 \x01(\x09\"\xC2\x03\x0A\x10HcxActivationKey\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x03\x124\x0A\x0Bcreate_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12H\x0A\x05state\x18\x03 \x01(\x0E24.google.cloud.vmwareengine.v1.HcxActivationKey.StateB\x03\xE0A\x03\x12\x1B\x0A\x0Eactivation_key\x18\x04 \x01(\x09B\x03\xE0A\x03\x12\x10\x0A\x03uid\x18\x05 \x01(\x09B\x03\xE0A\x03\"I\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x0D\x0A\x09AVAILABLE\x10\x01\x12\x0C\x0A\x08CONSUMED\x10\x02\x12\x0C\x0A\x08CREATING\x10\x03:\xA0\x01\xEAA\x9C\x01\x0A,vmwareengine.googleapis.com/HcxActivationKey\x12lprojects/{project}/locations/{location}/privateClouds/{private_cloud}/hcxActivationKeys/{hcx_activation_key}\"\xC0\x01\x0A\x03Hcx\x12\x13\x0A\x0Binternal_ip\x18\x02 \x01(\x09\x12\x0F\x0A\x07version\x18\x04 \x01(\x09\x12;\x0A\x05state\x18\x05 \x01(\x0E2'.google.cloud.vmwareengine.v1.Hcx.StateB\x03\xE0A\x03\x12\x0C\x0A\x04fqdn\x18\x06 \x01(\x09\"H\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x0A\x0A\x06ACTIVE\x10\x01\x12\x0C\x0A\x08CREATING\x10\x02\x12\x0E\x0A\x0AACTIVATING\x10\x03\"\xB0\x01\x0A\x03Nsx\x12\x13\x0A\x0Binternal_ip\x18\x02 \x01(\x09\x12\x0F\x0A\x07version\x18\x04 \x01(\x09\x12;\x0A\x05state\x18\x05 \x01(\x0E2'.google.cloud.vmwareengine.v1.Nsx.StateB\x03\xE0A\x03\x12\x0C\x0A\x04fqdn\x18\x06 \x01(\x09\"8\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x0A\x0A\x06ACTIVE\x10\x01\x12\x0C\x0A\x08CREATING\x10\x02\"\xB8\x01\x0A\x07Vcenter\x12\x13\x0A\x0Binternal_ip\x18\x02 \x01(\x09\x12\x0F\x0A\x07version\x18\x04 \x01(\x09\x12?\x0A\x05state\x18\x05 \x01(\x0E2+.google.cloud.vmwareengine.v1.Vcenter.StateB\x03\xE0A\x03\x12\x0C\x0A\x04fqdn\x18\x06 \x01(\x09\"8\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x0A\x0A\x06ACTIVE\x10\x01\x12\x0C\x0A\x08CREATING\x10\x02\"\x9B\x07\x0A\x13AutoscalingSettings\x12m\x0A\x14autoscaling_policies\x18\x01 \x03(\x0B2J.google.cloud.vmwareengine.v1.AutoscalingSettings.AutoscalingPoliciesEntryB\x03\xE0A\x02\x12#\x0A\x16min_cluster_node_count\x18\x02 \x01(\x05B\x03\xE0A\x01\x12#\x0A\x16max_cluster_node_count\x18\x03 \x01(\x05B\x03\xE0A\x01\x128\x0A\x10cool_down_period\x18\x04 \x01(\x0B2\x19.google.protobuf.DurationB\x03\xE0A\x01\x1A;\x0A\x0AThresholds\x12\x16\x0A\x09scale_out\x18\x01 \x01(\x05B\x03\xE0A\x02\x12\x15\x0A\x08scale_in\x18\x02 \x01(\x05B\x03\xE0A\x02\x1A\xD2\x03\x0A\x11AutoscalingPolicy\x12\x19\x0A\x0Cnode_type_id\x18\x01 \x01(\x09B\x03\xE0A\x02\x12\x1B\x0A\x0Escale_out_size\x18\x02 \x01(\x05B\x03\xE0A\x02\x12Y\x0A\x0Ecpu_thresholds\x18\x0B \x01(\x0B2<.google.cloud.vmwareengine.v1.AutoscalingSettings.ThresholdsB\x03\xE0A\x01\x12d\x0A\x19granted_memory_thresholds\x18\x0C \x01(\x0B2<.google.cloud.vmwareengine.v1.AutoscalingSettings.ThresholdsB\x03\xE0A\x01\x12e\x0A\x1Aconsumed_memory_thresholds\x18\x0D \x01(\x0B2<.google.cloud.vmwareengine.v1.AutoscalingSettings.ThresholdsB\x03\xE0A\x01\x12]\x0A\x12storage_thresholds\x18\x0E \x01(\x0B2<.google.cloud.vmwareengine.v1.AutoscalingSettings.ThresholdsB\x03\xE0A\x01\x1A\x7F\x0A\x18AutoscalingPoliciesEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12R\x0A\x05value\x18\x02 \x01(\x0B2C.google.cloud.vmwareengine.v1.AutoscalingSettings.AutoscalingPolicy:\x028\x01\"\xB2\x03\x0A\x0DDnsForwarding\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x03\x124\x0A\x0Bcreate_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x03 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12Y\x0A\x10forwarding_rules\x18\x04 \x03(\x0B2:.google.cloud.vmwareengine.v1.DnsForwarding.ForwardingRuleB\x03\xE0A\x02\x1A@\x0A\x0EForwardingRule\x12\x13\x0A\x06domain\x18\x01 \x01(\x09B\x03\xE0A\x02\x12\x19\x0A\x0Cname_servers\x18\x02 \x03(\x09B\x03\xE0A\x02:\x84\x01\xEAA\x80\x01\x0A)vmwareengine.googleapis.com/DnsForwarding\x12Sprojects/{project}/locations/{location}/privateClouds/{private_cloud}/dnsForwarding\"\xC4\x0A\x0A\x0ENetworkPeering\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x03\x124\x0A\x0Bcreate_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x03 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12\x19\x0A\x0Cpeer_network\x18\x05 \x01(\x09B\x03\xE0A\x02\x12&\x0A\x14export_custom_routes\x18\x08 \x01(\x08B\x03\xE0A\x01H\x00\x88\x01\x01\x12&\x0A\x14import_custom_routes\x18\x09 \x01(\x08B\x03\xE0A\x01H\x01\x88\x01\x01\x12(\x0A\x16exchange_subnet_routes\x18\x0A \x01(\x08B\x03\xE0A\x01H\x02\x88\x01\x01\x125\x0A#export_custom_routes_with_public_ip\x18\x0B \x01(\x08B\x03\xE0A\x01H\x03\x88\x01\x01\x125\x0A#import_custom_routes_with_public_ip\x18\x0C \x01(\x08B\x03\xE0A\x01H\x04\x88\x01\x01\x12F\x0A\x05state\x18\x0D \x01(\x0E22.google.cloud.vmwareengine.v1.NetworkPeering.StateB\x03\xE0A\x03\x12\x1A\x0A\x0Dstate_details\x18\x07 \x01(\x09B\x03\xE0A\x03\x12\x15\x0A\x08peer_mtu\x18\x0E \x01(\x05B\x03\xE0A\x01\x12\\\x0A\x11peer_network_type\x18\x10 \x01(\x0E2<.google.cloud.vmwareengine.v1.NetworkPeering.PeerNetworkTypeB\x03\xE0A\x02\x12\x10\x0A\x03uid\x18\x11 \x01(\x09B\x03\xE0A\x03\x12V\x0A\x15vmware_engine_network\x18\x14 \x01(\x09B7\xE0A\x02\xFAA1\x0A/vmwareengine.googleapis.com/VmwareEngineNetwork\x12\x18\x0A\x0Bdescription\x18\x15 \x01(\x09B\x03\xE0A\x01\"T\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x0C\x0A\x08INACTIVE\x10\x01\x12\x0A\x0A\x06ACTIVE\x10\x02\x12\x0C\x0A\x08CREATING\x10\x03\x12\x0C\x0A\x08DELETING\x10\x04\"\xE3\x01\x0A\x0FPeerNetworkType\x12!\x0A\x1DPEER_NETWORK_TYPE_UNSPECIFIED\x10\x00\x12\x0C\x0A\x08STANDARD\x10\x01\x12\x19\x0A\x15VMWARE_ENGINE_NETWORK\x10\x02\x12\x1B\x0A\x17PRIVATE_SERVICES_ACCESS\x10\x03\x12\x18\x0A\x14NETAPP_CLOUD_VOLUMES\x10\x04\x12\x17\x0A\x13THIRD_PARTY_SERVICE\x10\x05\x12\x13\x0A\x0FDELL_POWERSCALE\x10\x06\x12\x1F\x0A\x1BGOOGLE_CLOUD_NETAPP_VOLUMES\x10\x07:z\xEAAw\x0A*vmwareengine.googleapis.com/NetworkPeering\x12Iprojects/{project}/locations/{location}/networkPeerings/{network_peering}B\x17\x0A\x15_export_custom_routesB\x17\x0A\x15_import_custom_routesB\x19\x0A\x17_exchange_subnet_routesB&\x0A\$_export_custom_routes_with_public_ipB&\x0A\$_import_custom_routes_with_public_ip\"\xB6\x03\x0A\x0CPeeringRoute\x12\x17\x0A\x0Adest_range\x18\x01 \x01(\x09B\x03\xE0A\x03\x12B\x0A\x04type\x18\x02 \x01(\x0E2/.google.cloud.vmwareengine.v1.PeeringRoute.TypeB\x03\xE0A\x03\x12\x1C\x0A\x0Fnext_hop_region\x18\x03 \x01(\x09B\x03\xE0A\x03\x12\x15\x0A\x08priority\x18\x04 \x01(\x03B\x03\xE0A\x03\x12\x15\x0A\x08imported\x18\x05 \x01(\x08B\x03\xE0A\x03\x12L\x0A\x09direction\x18\x06 \x01(\x0E24.google.cloud.vmwareengine.v1.PeeringRoute.DirectionB\x03\xE0A\x03\"k\x0A\x04Type\x12\x14\x0A\x10TYPE_UNSPECIFIED\x10\x00\x12\x19\x0A\x15DYNAMIC_PEERING_ROUTE\x10\x01\x12\x18\x0A\x14STATIC_PEERING_ROUTE\x10\x02\x12\x18\x0A\x14SUBNET_PEERING_ROUTE\x10\x03\"B\x0A\x09Direction\x12\x19\x0A\x15DIRECTION_UNSPECIFIED\x10\x00\x12\x0C\x0A\x08INCOMING\x10\x01\x12\x0C\x0A\x08OUTGOING\x10\x02\"\xFF\x06\x0A\x0DNetworkPolicy\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x03\x124\x0A\x0Bcreate_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x03 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12S\x0A\x0Finternet_access\x18\x06 \x01(\x0B2:.google.cloud.vmwareengine.v1.NetworkPolicy.NetworkService\x12O\x0A\x0Bexternal_ip\x18\x07 \x01(\x0B2:.google.cloud.vmwareengine.v1.NetworkPolicy.NetworkService\x12\x1F\x0A\x12edge_services_cidr\x18\x09 \x01(\x09B\x03\xE0A\x02\x12\x10\x0A\x03uid\x18\x0A \x01(\x09B\x03\xE0A\x03\x12V\x0A\x15vmware_engine_network\x18\x0C \x01(\x09B7\xE0A\x01\xFAA1\x0A/vmwareengine.googleapis.com/VmwareEngineNetwork\x12\x18\x0A\x0Bdescription\x18\x0D \x01(\x09B\x03\xE0A\x01\x12`\x0A\x1Fvmware_engine_network_canonical\x18\x0E \x01(\x09B7\xE0A\x03\xFAA1\x0A/vmwareengine.googleapis.com/VmwareEngineNetwork\x1A\xC7\x01\x0A\x0ENetworkService\x12\x0F\x0A\x07enabled\x18\x01 \x01(\x08\x12T\x0A\x05state\x18\x02 \x01(\x0E2@.google.cloud.vmwareengine.v1.NetworkPolicy.NetworkService.StateB\x03\xE0A\x03\"N\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x11\x0A\x0DUNPROVISIONED\x10\x01\x12\x0F\x0A\x0BRECONCILING\x10\x02\x12\x0A\x0A\x06ACTIVE\x10\x03:x\xEAAu\x0A)vmwareengine.googleapis.com/NetworkPolicy\x12Hprojects/{project}/locations/{location}/networkPolicies/{network_policy}\"\xD3\x05\x0A\x18ManagementDnsZoneBinding\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x03\x124\x0A\x0Bcreate_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x03 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12P\x0A\x05state\x18\x08 \x01(\x0E2<.google.cloud.vmwareengine.v1.ManagementDnsZoneBinding.StateB\x03\xE0A\x03\x12\x13\x0A\x0Bdescription\x18\x0D \x01(\x09\x12:\x0A\x0Bvpc_network\x18\x0E \x01(\x09B#\xFAA \x0A\x1Ecompute.googleapis.com/NetworkH\x00\x12U\x0A\x15vmware_engine_network\x18\x0F \x01(\x09B4\xFAA1\x0A/vmwareengine.googleapis.com/VmwareEngineNetworkH\x00\x12\x10\x0A\x03uid\x18\x09 \x01(\x09B\x03\xE0A\x03\"`\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x0A\x0A\x06ACTIVE\x10\x01\x12\x0C\x0A\x08CREATING\x10\x02\x12\x0C\x0A\x08UPDATING\x10\x03\x12\x0C\x0A\x08DELETING\x10\x04\x12\x0A\x0A\x06FAILED\x10\x05:\xB9\x01\xEAA\xB5\x01\x0A4vmwareengine.googleapis.com/ManagementDnsZoneBinding\x12}projects/{project}/locations/{location}/privateClouds/{private_cloud}/managementDnsZoneBindings/{management_dns_zone_binding}B\x0E\x0A\x0Cbind_network\"\xC0\x07\x0A\x13VmwareEngineNetwork\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x03\x124\x0A\x0Bcreate_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x03 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12\x13\x0A\x0Bdescription\x18\x05 \x01(\x09\x12W\x0A\x0Cvpc_networks\x18\x06 \x03(\x0B2<.google.cloud.vmwareengine.v1.VmwareEngineNetwork.VpcNetworkB\x03\xE0A\x03\x12K\x0A\x05state\x18\x07 \x01(\x0E27.google.cloud.vmwareengine.v1.VmwareEngineNetwork.StateB\x03\xE0A\x03\x12I\x0A\x04type\x18\x08 \x01(\x0E26.google.cloud.vmwareengine.v1.VmwareEngineNetwork.TypeB\x03\xE0A\x02\x12\x10\x0A\x03uid\x18\x09 \x01(\x09B\x03\xE0A\x03\x12\x0C\x0A\x04etag\x18\x0A \x01(\x09\x1A\xE7\x01\x0A\x0AVpcNetwork\x12T\x0A\x04type\x18\x01 \x01(\x0E2A.google.cloud.vmwareengine.v1.VmwareEngineNetwork.VpcNetwork.TypeB\x03\xE0A\x03\x127\x0A\x07network\x18\x02 \x01(\x09B&\xE0A\x03\xFAA \x0A\x1Ecompute.googleapis.com/Network\"J\x0A\x04Type\x12\x14\x0A\x10TYPE_UNSPECIFIED\x10\x00\x12\x0C\x0A\x08INTRANET\x10\x01\x12\x0C\x0A\x08INTERNET\x10\x02\x12\x10\x0A\x0CGOOGLE_CLOUD\x10\x03\"T\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x0C\x0A\x08CREATING\x10\x01\x12\x0A\x0A\x06ACTIVE\x10\x02\x12\x0C\x0A\x08UPDATING\x10\x03\x12\x0C\x0A\x08DELETING\x10\x04\"6\x0A\x04Type\x12\x14\x0A\x10TYPE_UNSPECIFIED\x10\x00\x12\x0A\x0A\x06LEGACY\x10\x01\x12\x0C\x0A\x08STANDARD\x10\x02:\x8B\x01\xEAA\x87\x01\x0A/vmwareengine.googleapis.com/VmwareEngineNetwork\x12Tprojects/{project}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network}\"\xB7\x0A\x0A\x11PrivateConnection\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x03\x124\x0A\x0Bcreate_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x03 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12\x18\x0A\x0Bdescription\x18\x04 \x01(\x09B\x03\xE0A\x01\x12I\x0A\x05state\x18\x05 \x01(\x0E25.google.cloud.vmwareengine.v1.PrivateConnection.StateB\x03\xE0A\x03\x12V\x0A\x15vmware_engine_network\x18\x08 \x01(\x09B7\xE0A\x02\xFAA1\x0A/vmwareengine.googleapis.com/VmwareEngineNetwork\x12`\x0A\x1Fvmware_engine_network_canonical\x18\x09 \x01(\x09B7\xE0A\x03\xFAA1\x0A/vmwareengine.googleapis.com/VmwareEngineNetwork\x12G\x0A\x04type\x18\x0A \x01(\x0E24.google.cloud.vmwareengine.v1.PrivateConnection.TypeB\x03\xE0A\x02\x12\x17\x0A\x0Apeering_id\x18\x0C \x01(\x09B\x03\xE0A\x03\x12V\x0A\x0Crouting_mode\x18\x0D \x01(\x0E2;.google.cloud.vmwareengine.v1.PrivateConnection.RoutingModeB\x03\xE0A\x01\x12\x10\x0A\x03uid\x18\x0E \x01(\x09B\x03\xE0A\x03\x12?\x0A\x0Fservice_network\x18\x10 \x01(\x09B&\xE0A\x02\xFAA \x0A\x1Ecompute.googleapis.com/Network\x12X\x0A\x0Dpeering_state\x18\x11 \x01(\x0E2<.google.cloud.vmwareengine.v1.PrivateConnection.PeeringStateB\x03\xE0A\x03\"s\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x0C\x0A\x08CREATING\x10\x01\x12\x0A\x0A\x06ACTIVE\x10\x02\x12\x0C\x0A\x08UPDATING\x10\x03\x12\x0C\x0A\x08DELETING\x10\x04\x12\x11\x0A\x0DUNPROVISIONED\x10\x05\x12\x0A\x0A\x06FAILED\x10\x06\"\x80\x01\x0A\x04Type\x12\x14\x0A\x10TYPE_UNSPECIFIED\x10\x00\x12\x1A\x0A\x16PRIVATE_SERVICE_ACCESS\x10\x01\x12\x18\x0A\x14NETAPP_CLOUD_VOLUMES\x10\x02\x12\x13\x0A\x0FDELL_POWERSCALE\x10\x03\x12\x17\x0A\x13THIRD_PARTY_SERVICE\x10\x04\"E\x0A\x0BRoutingMode\x12\x1C\x0A\x18ROUTING_MODE_UNSPECIFIED\x10\x00\x12\x0A\x0A\x06GLOBAL\x10\x01\x12\x0C\x0A\x08REGIONAL\x10\x02\"W\x0A\x0CPeeringState\x12\x1D\x0A\x19PEERING_STATE_UNSPECIFIED\x10\x00\x12\x12\x0A\x0EPEERING_ACTIVE\x10\x01\x12\x14\x0A\x10PEERING_INACTIVE\x10\x02:\x84\x01\xEAA\x80\x01\x0A-vmwareengine.googleapis.com/PrivateConnection\x12Oprojects/{project}/locations/{location}/privateConnections/{private_connection}\"\xAA\x01\x0A\x10LocationMetadata\x12T\x0A\x0Ccapabilities\x18\x01 \x03(\x0E29.google.cloud.vmwareengine.v1.LocationMetadata.CapabilityB\x03\xE0A\x03\"@\x0A\x0ACapability\x12\x1A\x0A\x16CAPABILITY_UNSPECIFIED\x10\x00\x12\x16\x0A\x12STRETCHED_CLUSTERS\x10\x01\"\xD7\x01\x0A\x11DnsBindPermission\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x03\x12@\x0A\x0Aprincipals\x18\x02 \x03(\x0B2'.google.cloud.vmwareengine.v1.PrincipalB\x03\xE0A\x03:m\xEAAj\x0A-vmwareengine.googleapis.com/DnsBindPermission\x129projects/{project}/locations/{location}/dnsBindPermission\"C\x0A\x09Principal\x12\x0E\x0A\x04user\x18\x01 \x01(\x09H\x00\x12\x19\x0A\x0Fservice_account\x18\x02 \x01(\x09H\x00B\x0B\x0A\x09principalB\xE6\x01\x0A com.google.cloud.vmwareengine.v1B\x1AVmwareengineResourcesProtoP\x01ZDcloud.google.com/go/vmwareengine/apiv1/vmwareenginepb;vmwareenginepb\xAA\x02\x1CGoogle.Cloud.VmwareEngine.V1\xCA\x02\x1CGoogle\\Cloud\\VmwareEngine\\V1\xEA\x02\x1FGoogle::Cloud::VmwareEngine::V1b\x06proto3" - , true); - - static::$is_initialized = true; - } -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/AutoscalingSettings.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/AutoscalingSettings.php deleted file mode 100644 index b66fb8fcf96b..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/AutoscalingSettings.php +++ /dev/null @@ -1,240 +0,0 @@ -google.cloud.vmwareengine.v1.AutoscalingSettings - */ -class AutoscalingSettings extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The map with autoscaling policies applied to the cluster. - * The key is the identifier of the policy. - * It must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC - * 1034](https://datatracker.ietf.org/doc/html/rfc1034) (section 3.5) - * Currently there map must contain only one element - * that describes the autoscaling policy for compute nodes. - * - * Generated from protobuf field map autoscaling_policies = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - private $autoscaling_policies; - /** - * Optional. Minimum number of nodes of any type in a cluster. - * If not specified the default limits apply. - * - * Generated from protobuf field int32 min_cluster_node_count = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $min_cluster_node_count = 0; - /** - * Optional. Maximum number of nodes of any type in a cluster. - * If not specified the default limits apply. - * - * Generated from protobuf field int32 max_cluster_node_count = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $max_cluster_node_count = 0; - /** - * Optional. The minimum duration between consecutive autoscale operations. - * It starts once addition or removal of nodes is fully completed. - * Defaults to 30 minutes if not specified. Cool down period must be in whole - * minutes (for example, 30, 31, 50, 180 minutes). - * - * Generated from protobuf field .google.protobuf.Duration cool_down_period = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $cool_down_period = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\MapField $autoscaling_policies - * Required. The map with autoscaling policies applied to the cluster. - * The key is the identifier of the policy. - * It must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC - * 1034](https://datatracker.ietf.org/doc/html/rfc1034) (section 3.5) - * Currently there map must contain only one element - * that describes the autoscaling policy for compute nodes. - * @type int $min_cluster_node_count - * Optional. Minimum number of nodes of any type in a cluster. - * If not specified the default limits apply. - * @type int $max_cluster_node_count - * Optional. Maximum number of nodes of any type in a cluster. - * If not specified the default limits apply. - * @type \Google\Protobuf\Duration $cool_down_period - * Optional. The minimum duration between consecutive autoscale operations. - * It starts once addition or removal of nodes is fully completed. - * Defaults to 30 minutes if not specified. Cool down period must be in whole - * minutes (for example, 30, 31, 50, 180 minutes). - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); - parent::__construct($data); - } - - /** - * Required. The map with autoscaling policies applied to the cluster. - * The key is the identifier of the policy. - * It must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC - * 1034](https://datatracker.ietf.org/doc/html/rfc1034) (section 3.5) - * Currently there map must contain only one element - * that describes the autoscaling policy for compute nodes. - * - * Generated from protobuf field map autoscaling_policies = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Internal\MapField - */ - public function getAutoscalingPolicies() - { - return $this->autoscaling_policies; - } - - /** - * Required. The map with autoscaling policies applied to the cluster. - * The key is the identifier of the policy. - * It must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC - * 1034](https://datatracker.ietf.org/doc/html/rfc1034) (section 3.5) - * Currently there map must contain only one element - * that describes the autoscaling policy for compute nodes. - * - * Generated from protobuf field map autoscaling_policies = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setAutoscalingPolicies($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\AutoscalingSettings\AutoscalingPolicy::class); - $this->autoscaling_policies = $arr; - - return $this; - } - - /** - * Optional. Minimum number of nodes of any type in a cluster. - * If not specified the default limits apply. - * - * Generated from protobuf field int32 min_cluster_node_count = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getMinClusterNodeCount() - { - return $this->min_cluster_node_count; - } - - /** - * Optional. Minimum number of nodes of any type in a cluster. - * If not specified the default limits apply. - * - * Generated from protobuf field int32 min_cluster_node_count = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setMinClusterNodeCount($var) - { - GPBUtil::checkInt32($var); - $this->min_cluster_node_count = $var; - - return $this; - } - - /** - * Optional. Maximum number of nodes of any type in a cluster. - * If not specified the default limits apply. - * - * Generated from protobuf field int32 max_cluster_node_count = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getMaxClusterNodeCount() - { - return $this->max_cluster_node_count; - } - - /** - * Optional. Maximum number of nodes of any type in a cluster. - * If not specified the default limits apply. - * - * Generated from protobuf field int32 max_cluster_node_count = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setMaxClusterNodeCount($var) - { - GPBUtil::checkInt32($var); - $this->max_cluster_node_count = $var; - - return $this; - } - - /** - * Optional. The minimum duration between consecutive autoscale operations. - * It starts once addition or removal of nodes is fully completed. - * Defaults to 30 minutes if not specified. Cool down period must be in whole - * minutes (for example, 30, 31, 50, 180 minutes). - * - * Generated from protobuf field .google.protobuf.Duration cool_down_period = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Protobuf\Duration|null - */ - public function getCoolDownPeriod() - { - return $this->cool_down_period; - } - - public function hasCoolDownPeriod() - { - return isset($this->cool_down_period); - } - - public function clearCoolDownPeriod() - { - unset($this->cool_down_period); - } - - /** - * Optional. The minimum duration between consecutive autoscale operations. - * It starts once addition or removal of nodes is fully completed. - * Defaults to 30 minutes if not specified. Cool down period must be in whole - * minutes (for example, 30, 31, 50, 180 minutes). - * - * Generated from protobuf field .google.protobuf.Duration cool_down_period = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Protobuf\Duration $var - * @return $this - */ - public function setCoolDownPeriod($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Duration::class); - $this->cool_down_period = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/AutoscalingSettings/AutoscalingPolicy.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/AutoscalingSettings/AutoscalingPolicy.php deleted file mode 100644 index ce22510f7520..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/AutoscalingSettings/AutoscalingPolicy.php +++ /dev/null @@ -1,302 +0,0 @@ -google.cloud.vmwareengine.v1.AutoscalingSettings.AutoscalingPolicy - */ -class AutoscalingPolicy extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The canonical identifier of the node type to add or remove. - * Corresponds to the `NodeType`. - * - * Generated from protobuf field string node_type_id = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $node_type_id = ''; - /** - * Required. Number of nodes to add to a cluster during a scale-out - * operation. Must be divisible by 2 for stretched clusters. During a - * scale-in operation only one node (or 2 for stretched clusters) are - * removed in a single iteration. - * - * Generated from protobuf field int32 scale_out_size = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $scale_out_size = 0; - /** - * Optional. Utilization thresholds pertaining to CPU utilization. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.AutoscalingSettings.Thresholds cpu_thresholds = 11 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $cpu_thresholds = null; - /** - * Optional. Utilization thresholds pertaining to amount of granted memory. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.AutoscalingSettings.Thresholds granted_memory_thresholds = 12 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $granted_memory_thresholds = null; - /** - * Optional. Utilization thresholds pertaining to amount of consumed memory. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.AutoscalingSettings.Thresholds consumed_memory_thresholds = 13 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $consumed_memory_thresholds = null; - /** - * Optional. Utilization thresholds pertaining to amount of consumed - * storage. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.AutoscalingSettings.Thresholds storage_thresholds = 14 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $storage_thresholds = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $node_type_id - * Required. The canonical identifier of the node type to add or remove. - * Corresponds to the `NodeType`. - * @type int $scale_out_size - * Required. Number of nodes to add to a cluster during a scale-out - * operation. Must be divisible by 2 for stretched clusters. During a - * scale-in operation only one node (or 2 for stretched clusters) are - * removed in a single iteration. - * @type \Google\Cloud\VmwareEngine\V1\AutoscalingSettings\Thresholds $cpu_thresholds - * Optional. Utilization thresholds pertaining to CPU utilization. - * @type \Google\Cloud\VmwareEngine\V1\AutoscalingSettings\Thresholds $granted_memory_thresholds - * Optional. Utilization thresholds pertaining to amount of granted memory. - * @type \Google\Cloud\VmwareEngine\V1\AutoscalingSettings\Thresholds $consumed_memory_thresholds - * Optional. Utilization thresholds pertaining to amount of consumed memory. - * @type \Google\Cloud\VmwareEngine\V1\AutoscalingSettings\Thresholds $storage_thresholds - * Optional. Utilization thresholds pertaining to amount of consumed - * storage. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); - parent::__construct($data); - } - - /** - * Required. The canonical identifier of the node type to add or remove. - * Corresponds to the `NodeType`. - * - * Generated from protobuf field string node_type_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getNodeTypeId() - { - return $this->node_type_id; - } - - /** - * Required. The canonical identifier of the node type to add or remove. - * Corresponds to the `NodeType`. - * - * Generated from protobuf field string node_type_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setNodeTypeId($var) - { - GPBUtil::checkString($var, True); - $this->node_type_id = $var; - - return $this; - } - - /** - * Required. Number of nodes to add to a cluster during a scale-out - * operation. Must be divisible by 2 for stretched clusters. During a - * scale-in operation only one node (or 2 for stretched clusters) are - * removed in a single iteration. - * - * Generated from protobuf field int32 scale_out_size = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getScaleOutSize() - { - return $this->scale_out_size; - } - - /** - * Required. Number of nodes to add to a cluster during a scale-out - * operation. Must be divisible by 2 for stretched clusters. During a - * scale-in operation only one node (or 2 for stretched clusters) are - * removed in a single iteration. - * - * Generated from protobuf field int32 scale_out_size = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setScaleOutSize($var) - { - GPBUtil::checkInt32($var); - $this->scale_out_size = $var; - - return $this; - } - - /** - * Optional. Utilization thresholds pertaining to CPU utilization. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.AutoscalingSettings.Thresholds cpu_thresholds = 11 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\VmwareEngine\V1\AutoscalingSettings\Thresholds|null - */ - public function getCpuThresholds() - { - return $this->cpu_thresholds; - } - - public function hasCpuThresholds() - { - return isset($this->cpu_thresholds); - } - - public function clearCpuThresholds() - { - unset($this->cpu_thresholds); - } - - /** - * Optional. Utilization thresholds pertaining to CPU utilization. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.AutoscalingSettings.Thresholds cpu_thresholds = 11 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\VmwareEngine\V1\AutoscalingSettings\Thresholds $var - * @return $this - */ - public function setCpuThresholds($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\AutoscalingSettings\Thresholds::class); - $this->cpu_thresholds = $var; - - return $this; - } - - /** - * Optional. Utilization thresholds pertaining to amount of granted memory. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.AutoscalingSettings.Thresholds granted_memory_thresholds = 12 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\VmwareEngine\V1\AutoscalingSettings\Thresholds|null - */ - public function getGrantedMemoryThresholds() - { - return $this->granted_memory_thresholds; - } - - public function hasGrantedMemoryThresholds() - { - return isset($this->granted_memory_thresholds); - } - - public function clearGrantedMemoryThresholds() - { - unset($this->granted_memory_thresholds); - } - - /** - * Optional. Utilization thresholds pertaining to amount of granted memory. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.AutoscalingSettings.Thresholds granted_memory_thresholds = 12 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\VmwareEngine\V1\AutoscalingSettings\Thresholds $var - * @return $this - */ - public function setGrantedMemoryThresholds($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\AutoscalingSettings\Thresholds::class); - $this->granted_memory_thresholds = $var; - - return $this; - } - - /** - * Optional. Utilization thresholds pertaining to amount of consumed memory. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.AutoscalingSettings.Thresholds consumed_memory_thresholds = 13 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\VmwareEngine\V1\AutoscalingSettings\Thresholds|null - */ - public function getConsumedMemoryThresholds() - { - return $this->consumed_memory_thresholds; - } - - public function hasConsumedMemoryThresholds() - { - return isset($this->consumed_memory_thresholds); - } - - public function clearConsumedMemoryThresholds() - { - unset($this->consumed_memory_thresholds); - } - - /** - * Optional. Utilization thresholds pertaining to amount of consumed memory. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.AutoscalingSettings.Thresholds consumed_memory_thresholds = 13 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\VmwareEngine\V1\AutoscalingSettings\Thresholds $var - * @return $this - */ - public function setConsumedMemoryThresholds($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\AutoscalingSettings\Thresholds::class); - $this->consumed_memory_thresholds = $var; - - return $this; - } - - /** - * Optional. Utilization thresholds pertaining to amount of consumed - * storage. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.AutoscalingSettings.Thresholds storage_thresholds = 14 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\VmwareEngine\V1\AutoscalingSettings\Thresholds|null - */ - public function getStorageThresholds() - { - return $this->storage_thresholds; - } - - public function hasStorageThresholds() - { - return isset($this->storage_thresholds); - } - - public function clearStorageThresholds() - { - unset($this->storage_thresholds); - } - - /** - * Optional. Utilization thresholds pertaining to amount of consumed - * storage. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.AutoscalingSettings.Thresholds storage_thresholds = 14 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\VmwareEngine\V1\AutoscalingSettings\Thresholds $var - * @return $this - */ - public function setStorageThresholds($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\AutoscalingSettings\Thresholds::class); - $this->storage_thresholds = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/AutoscalingSettings/Thresholds.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/AutoscalingSettings/Thresholds.php deleted file mode 100644 index cd63eb0853bb..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/AutoscalingSettings/Thresholds.php +++ /dev/null @@ -1,102 +0,0 @@ -google.cloud.vmwareengine.v1.AutoscalingSettings.Thresholds - */ -class Thresholds extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The utilization triggering the scale-out operation in percent. - * - * Generated from protobuf field int32 scale_out = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $scale_out = 0; - /** - * Required. The utilization triggering the scale-in operation in percent. - * - * Generated from protobuf field int32 scale_in = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $scale_in = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $scale_out - * Required. The utilization triggering the scale-out operation in percent. - * @type int $scale_in - * Required. The utilization triggering the scale-in operation in percent. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); - parent::__construct($data); - } - - /** - * Required. The utilization triggering the scale-out operation in percent. - * - * Generated from protobuf field int32 scale_out = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getScaleOut() - { - return $this->scale_out; - } - - /** - * Required. The utilization triggering the scale-out operation in percent. - * - * Generated from protobuf field int32 scale_out = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setScaleOut($var) - { - GPBUtil::checkInt32($var); - $this->scale_out = $var; - - return $this; - } - - /** - * Required. The utilization triggering the scale-in operation in percent. - * - * Generated from protobuf field int32 scale_in = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getScaleIn() - { - return $this->scale_in; - } - - /** - * Required. The utilization triggering the scale-in operation in percent. - * - * Generated from protobuf field int32 scale_in = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setScaleIn($var) - { - GPBUtil::checkInt32($var); - $this->scale_in = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Cluster.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Cluster.php deleted file mode 100644 index fd38ab8ff230..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Cluster.php +++ /dev/null @@ -1,411 +0,0 @@ -google.cloud.vmwareengine.v1.Cluster - */ -class Cluster extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The resource name of this cluster. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * Output only. Creation time of this resource. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. Last update time of this resource. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Output only. State of the resource. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.Cluster.State state = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = 0; - /** - * Output only. True if the cluster is a management cluster; false otherwise. - * There can only be one management cluster in a private cloud - * and it has to be the first one. - * - * Generated from protobuf field bool management = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $management = false; - /** - * Optional. Configuration of the autoscaling applied to this cluster. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.AutoscalingSettings autoscaling_settings = 18 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $autoscaling_settings = null; - /** - * Output only. System-generated unique identifier for the resource. - * - * Generated from protobuf field string uid = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $uid = ''; - /** - * Required. The map of cluster node types in this cluster, where the key is - * canonical identifier of the node type (corresponds to the `NodeType`). - * - * Generated from protobuf field map node_type_configs = 16 [(.google.api.field_behavior) = REQUIRED]; - */ - private $node_type_configs; - /** - * Optional. Configuration of a stretched cluster. Required for clusters that - * belong to a STRETCHED private cloud. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.StretchedClusterConfig stretched_cluster_config = 17 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $stretched_cluster_config = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. The resource name of this cluster. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster` - * @type \Google\Protobuf\Timestamp $create_time - * Output only. Creation time of this resource. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. Last update time of this resource. - * @type int $state - * Output only. State of the resource. - * @type bool $management - * Output only. True if the cluster is a management cluster; false otherwise. - * There can only be one management cluster in a private cloud - * and it has to be the first one. - * @type \Google\Cloud\VmwareEngine\V1\AutoscalingSettings $autoscaling_settings - * Optional. Configuration of the autoscaling applied to this cluster. - * @type string $uid - * Output only. System-generated unique identifier for the resource. - * @type array|\Google\Protobuf\Internal\MapField $node_type_configs - * Required. The map of cluster node types in this cluster, where the key is - * canonical identifier of the node type (corresponds to the `NodeType`). - * @type \Google\Cloud\VmwareEngine\V1\StretchedClusterConfig $stretched_cluster_config - * Optional. Configuration of a stretched cluster. Required for clusters that - * belong to a STRETCHED private cloud. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The resource name of this cluster. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster` - * - * 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 cluster. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster` - * - * 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. Creation time of this resource. - * - * 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 time of this resource. - * - * 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 time of this resource. - * - * 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 time of this resource. - * - * 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. State of the resource. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.Cluster.State state = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Output only. State of the resource. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.Cluster.State state = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\Cluster\State::class); - $this->state = $var; - - return $this; - } - - /** - * Output only. True if the cluster is a management cluster; false otherwise. - * There can only be one management cluster in a private cloud - * and it has to be the first one. - * - * Generated from protobuf field bool management = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return bool - */ - public function getManagement() - { - return $this->management; - } - - /** - * Output only. True if the cluster is a management cluster; false otherwise. - * There can only be one management cluster in a private cloud - * and it has to be the first one. - * - * Generated from protobuf field bool management = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param bool $var - * @return $this - */ - public function setManagement($var) - { - GPBUtil::checkBool($var); - $this->management = $var; - - return $this; - } - - /** - * Optional. Configuration of the autoscaling applied to this cluster. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.AutoscalingSettings autoscaling_settings = 18 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\VmwareEngine\V1\AutoscalingSettings|null - */ - public function getAutoscalingSettings() - { - return $this->autoscaling_settings; - } - - public function hasAutoscalingSettings() - { - return isset($this->autoscaling_settings); - } - - public function clearAutoscalingSettings() - { - unset($this->autoscaling_settings); - } - - /** - * Optional. Configuration of the autoscaling applied to this cluster. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.AutoscalingSettings autoscaling_settings = 18 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\VmwareEngine\V1\AutoscalingSettings $var - * @return $this - */ - public function setAutoscalingSettings($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\AutoscalingSettings::class); - $this->autoscaling_settings = $var; - - return $this; - } - - /** - * Output only. System-generated unique identifier for the resource. - * - * Generated from protobuf field string uid = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getUid() - { - return $this->uid; - } - - /** - * Output only. System-generated unique identifier for the resource. - * - * Generated from protobuf field string uid = 14 [(.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 map of cluster node types in this cluster, where the key is - * canonical identifier of the node type (corresponds to the `NodeType`). - * - * Generated from protobuf field map node_type_configs = 16 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Internal\MapField - */ - public function getNodeTypeConfigs() - { - return $this->node_type_configs; - } - - /** - * Required. The map of cluster node types in this cluster, where the key is - * canonical identifier of the node type (corresponds to the `NodeType`). - * - * Generated from protobuf field map node_type_configs = 16 [(.google.api.field_behavior) = REQUIRED]; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setNodeTypeConfigs($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\NodeTypeConfig::class); - $this->node_type_configs = $arr; - - return $this; - } - - /** - * Optional. Configuration of a stretched cluster. Required for clusters that - * belong to a STRETCHED private cloud. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.StretchedClusterConfig stretched_cluster_config = 17 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\VmwareEngine\V1\StretchedClusterConfig|null - */ - public function getStretchedClusterConfig() - { - return $this->stretched_cluster_config; - } - - public function hasStretchedClusterConfig() - { - return isset($this->stretched_cluster_config); - } - - public function clearStretchedClusterConfig() - { - unset($this->stretched_cluster_config); - } - - /** - * Optional. Configuration of a stretched cluster. Required for clusters that - * belong to a STRETCHED private cloud. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.StretchedClusterConfig stretched_cluster_config = 17 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\VmwareEngine\V1\StretchedClusterConfig $var - * @return $this - */ - public function setStretchedClusterConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\StretchedClusterConfig::class); - $this->stretched_cluster_config = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Cluster/State.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Cluster/State.php deleted file mode 100644 index f95198a8435b..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Cluster/State.php +++ /dev/null @@ -1,84 +0,0 @@ -google.cloud.vmwareengine.v1.Cluster.State - */ -class State -{ - /** - * The default value. This value should never be used. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * The Cluster is operational and can be used by the user. - * - * Generated from protobuf enum ACTIVE = 1; - */ - const ACTIVE = 1; - /** - * The Cluster is being deployed. - * - * Generated from protobuf enum CREATING = 2; - */ - const CREATING = 2; - /** - * Adding or removing of a node to the cluster, any other cluster specific - * updates. - * - * Generated from protobuf enum UPDATING = 3; - */ - const UPDATING = 3; - /** - * The Cluster is being deleted. - * - * Generated from protobuf enum DELETING = 4; - */ - const DELETING = 4; - /** - * The Cluster is undergoing maintenance, for example: a failed node is - * getting replaced. - * - * Generated from protobuf enum REPAIRING = 5; - */ - const REPAIRING = 5; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::ACTIVE => 'ACTIVE', - self::CREATING => 'CREATING', - self::UPDATING => 'UPDATING', - self::DELETING => 'DELETING', - self::REPAIRING => 'REPAIRING', - ]; - - 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateClusterRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateClusterRequest.php deleted file mode 100644 index 27b345cf2581..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateClusterRequest.php +++ /dev/null @@ -1,306 +0,0 @@ -google.cloud.vmwareengine.v1.CreateClusterRequest - */ -class CreateClusterRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the private cloud to create a new cluster - * in. Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The user-provided identifier of the new `Cluster`. - * This identifier must be unique among clusters within the parent and becomes - * the final token in the name URI. - * The identifier must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * Generated from protobuf field string cluster_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $cluster_id = ''; - /** - * Required. The initial description of the new cluster. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.Cluster cluster = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $cluster = null; - /** - * Optional. 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. True if you want the request to be validated and not executed; - * false otherwise. - * - * Generated from protobuf field bool validate_only = 5 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $validate_only = false; - - /** - * @param string $parent Required. The resource name of the private cloud to create a new cluster - * in. Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * Please see {@see VmwareEngineClient::privateCloudName()} for help formatting this field. - * @param \Google\Cloud\VmwareEngine\V1\Cluster $cluster Required. The initial description of the new cluster. - * @param string $clusterId Required. The user-provided identifier of the new `Cluster`. - * This identifier must be unique among clusters within the parent and becomes - * the final token in the name URI. - * The identifier must meet the following requirements: - * - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * @return \Google\Cloud\VmwareEngine\V1\CreateClusterRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\VmwareEngine\V1\Cluster $cluster, string $clusterId): self - { - return (new self()) - ->setParent($parent) - ->setCluster($cluster) - ->setClusterId($clusterId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The resource name of the private cloud to create a new cluster - * in. Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * @type string $cluster_id - * Required. The user-provided identifier of the new `Cluster`. - * This identifier must be unique among clusters within the parent and becomes - * the final token in the name URI. - * The identifier must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * @type \Google\Cloud\VmwareEngine\V1\Cluster $cluster - * Required. The initial description of the new cluster. - * @type string $request_id - * Optional. 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. True if you want the request to be validated and not executed; - * false otherwise. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the private cloud to create a new cluster - * in. Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * 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 private cloud to create a new cluster - * in. Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * 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 user-provided identifier of the new `Cluster`. - * This identifier must be unique among clusters within the parent and becomes - * the final token in the name URI. - * The identifier must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * Generated from protobuf field string cluster_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getClusterId() - { - return $this->cluster_id; - } - - /** - * Required. The user-provided identifier of the new `Cluster`. - * This identifier must be unique among clusters within the parent and becomes - * the final token in the name URI. - * The identifier must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * Generated from protobuf field string cluster_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setClusterId($var) - { - GPBUtil::checkString($var, True); - $this->cluster_id = $var; - - return $this; - } - - /** - * Required. The initial description of the new cluster. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.Cluster cluster = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\VmwareEngine\V1\Cluster|null - */ - public function getCluster() - { - return $this->cluster; - } - - public function hasCluster() - { - return isset($this->cluster); - } - - public function clearCluster() - { - unset($this->cluster); - } - - /** - * Required. The initial description of the new cluster. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.Cluster cluster = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\VmwareEngine\V1\Cluster $var - * @return $this - */ - public function setCluster($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\Cluster::class); - $this->cluster = $var; - - return $this; - } - - /** - * Optional. 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. 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. True if you want the request to be validated and not executed; - * false otherwise. - * - * Generated from protobuf field bool validate_only = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getValidateOnly() - { - return $this->validate_only; - } - - /** - * Optional. True if you want the request to be validated and not executed; - * false otherwise. - * - * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateExternalAccessRuleRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateExternalAccessRuleRequest.php deleted file mode 100644 index cc97d6cdf78f..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateExternalAccessRuleRequest.php +++ /dev/null @@ -1,313 +0,0 @@ -google.cloud.vmwareengine.v1.CreateExternalAccessRuleRequest - */ -class CreateExternalAccessRuleRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the network policy - * to create a new external access firewall rule in. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/networkPolicies/my-policy` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The initial description of a new external access rule. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.ExternalAccessRule external_access_rule = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $external_access_rule = null; - /** - * Required. The user-provided identifier of the `ExternalAccessRule` to be - * created. This identifier must be unique among `ExternalAccessRule` - * resources within the parent and becomes the final token in the name URI. - * The identifier must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * Generated from protobuf field string external_access_rule_id = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $external_access_rule_id = ''; - /** - * A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 the 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; - */ - protected $request_id = ''; - - /** - * @param string $parent Required. The resource name of the network policy - * to create a new external access firewall rule in. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/networkPolicies/my-policy` - * Please see {@see VmwareEngineClient::networkPolicyName()} for help formatting this field. - * @param \Google\Cloud\VmwareEngine\V1\ExternalAccessRule $externalAccessRule Required. The initial description of a new external access rule. - * @param string $externalAccessRuleId Required. The user-provided identifier of the `ExternalAccessRule` to be - * created. This identifier must be unique among `ExternalAccessRule` - * resources within the parent and becomes the final token in the name URI. - * The identifier must meet the following requirements: - * - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * @return \Google\Cloud\VmwareEngine\V1\CreateExternalAccessRuleRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\VmwareEngine\V1\ExternalAccessRule $externalAccessRule, string $externalAccessRuleId): self - { - return (new self()) - ->setParent($parent) - ->setExternalAccessRule($externalAccessRule) - ->setExternalAccessRuleId($externalAccessRuleId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The resource name of the network policy - * to create a new external access firewall rule in. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/networkPolicies/my-policy` - * @type \Google\Cloud\VmwareEngine\V1\ExternalAccessRule $external_access_rule - * Required. The initial description of a new external access rule. - * @type string $external_access_rule_id - * Required. The user-provided identifier of the `ExternalAccessRule` to be - * created. This identifier must be unique among `ExternalAccessRule` - * resources within the parent and becomes the final token in the name URI. - * The identifier must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * @type string $request_id - * A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 the 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\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the network policy - * to create a new external access firewall rule in. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/networkPolicies/my-policy` - * - * 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 network policy - * to create a new external access firewall rule in. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/networkPolicies/my-policy` - * - * 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 initial description of a new external access rule. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.ExternalAccessRule external_access_rule = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\VmwareEngine\V1\ExternalAccessRule|null - */ - public function getExternalAccessRule() - { - return $this->external_access_rule; - } - - public function hasExternalAccessRule() - { - return isset($this->external_access_rule); - } - - public function clearExternalAccessRule() - { - unset($this->external_access_rule); - } - - /** - * Required. The initial description of a new external access rule. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.ExternalAccessRule external_access_rule = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\VmwareEngine\V1\ExternalAccessRule $var - * @return $this - */ - public function setExternalAccessRule($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\ExternalAccessRule::class); - $this->external_access_rule = $var; - - return $this; - } - - /** - * Required. The user-provided identifier of the `ExternalAccessRule` to be - * created. This identifier must be unique among `ExternalAccessRule` - * resources within the parent and becomes the final token in the name URI. - * The identifier must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * Generated from protobuf field string external_access_rule_id = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getExternalAccessRuleId() - { - return $this->external_access_rule_id; - } - - /** - * Required. The user-provided identifier of the `ExternalAccessRule` to be - * created. This identifier must be unique among `ExternalAccessRule` - * resources within the parent and becomes the final token in the name URI. - * The identifier must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * Generated from protobuf field string external_access_rule_id = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setExternalAccessRuleId($var) - { - GPBUtil::checkString($var, True); - $this->external_access_rule_id = $var; - - return $this; - } - - /** - * A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 the 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; - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 the 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; - * @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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateExternalAddressRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateExternalAddressRequest.php deleted file mode 100644 index 19541a175e24..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateExternalAddressRequest.php +++ /dev/null @@ -1,313 +0,0 @@ -google.cloud.vmwareengine.v1.CreateExternalAddressRequest - */ -class CreateExternalAddressRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the private cloud - * to create a new external IP address in. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The initial description of a new external IP address. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.ExternalAddress external_address = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $external_address = null; - /** - * Required. The user-provided identifier of the `ExternalAddress` to be - * created. This identifier must be unique among `ExternalAddress` resources - * within the parent and becomes the final token in the name URI. The - * identifier must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * Generated from protobuf field string external_address_id = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $external_address_id = ''; - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 the 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 resource name of the private cloud - * to create a new external IP address in. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * Please see {@see VmwareEngineClient::privateCloudName()} for help formatting this field. - * @param \Google\Cloud\VmwareEngine\V1\ExternalAddress $externalAddress Required. The initial description of a new external IP address. - * @param string $externalAddressId Required. The user-provided identifier of the `ExternalAddress` to be - * created. This identifier must be unique among `ExternalAddress` resources - * within the parent and becomes the final token in the name URI. The - * identifier must meet the following requirements: - * - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * @return \Google\Cloud\VmwareEngine\V1\CreateExternalAddressRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\VmwareEngine\V1\ExternalAddress $externalAddress, string $externalAddressId): self - { - return (new self()) - ->setParent($parent) - ->setExternalAddress($externalAddress) - ->setExternalAddressId($externalAddressId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The resource name of the private cloud - * to create a new external IP address in. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * @type \Google\Cloud\VmwareEngine\V1\ExternalAddress $external_address - * Required. The initial description of a new external IP address. - * @type string $external_address_id - * Required. The user-provided identifier of the `ExternalAddress` to be - * created. This identifier must be unique among `ExternalAddress` resources - * within the parent and becomes the final token in the name URI. The - * identifier must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * @type string $request_id - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 the 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\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the private cloud - * to create a new external IP address in. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * 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 private cloud - * to create a new external IP address in. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * 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 initial description of a new external IP address. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.ExternalAddress external_address = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\VmwareEngine\V1\ExternalAddress|null - */ - public function getExternalAddress() - { - return $this->external_address; - } - - public function hasExternalAddress() - { - return isset($this->external_address); - } - - public function clearExternalAddress() - { - unset($this->external_address); - } - - /** - * Required. The initial description of a new external IP address. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.ExternalAddress external_address = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\VmwareEngine\V1\ExternalAddress $var - * @return $this - */ - public function setExternalAddress($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\ExternalAddress::class); - $this->external_address = $var; - - return $this; - } - - /** - * Required. The user-provided identifier of the `ExternalAddress` to be - * created. This identifier must be unique among `ExternalAddress` resources - * within the parent and becomes the final token in the name URI. The - * identifier must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * Generated from protobuf field string external_address_id = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getExternalAddressId() - { - return $this->external_address_id; - } - - /** - * Required. The user-provided identifier of the `ExternalAddress` to be - * created. This identifier must be unique among `ExternalAddress` resources - * within the parent and becomes the final token in the name URI. The - * identifier must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * Generated from protobuf field string external_address_id = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setExternalAddressId($var) - { - GPBUtil::checkString($var, True); - $this->external_address_id = $var; - - return $this; - } - - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 the 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. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 the 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateHcxActivationKeyRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateHcxActivationKeyRequest.php deleted file mode 100644 index c5fb6bc649ca..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateHcxActivationKeyRequest.php +++ /dev/null @@ -1,313 +0,0 @@ -google.cloud.vmwareengine.v1.CreateHcxActivationKeyRequest - */ -class CreateHcxActivationKeyRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the private cloud to create the key for. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/privateClouds/my-cloud` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The initial description of a new HCX activation key. When - * creating a new key, this field must be an empty object. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.HcxActivationKey hcx_activation_key = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $hcx_activation_key = null; - /** - * Required. The user-provided identifier of the `HcxActivationKey` to be - * created. This identifier must be unique among `HcxActivationKey` resources - * within the parent and becomes the final token in the name URI. - * The identifier must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * Generated from protobuf field string hcx_activation_key_id = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $hcx_activation_key_id = ''; - /** - * A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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; - */ - protected $request_id = ''; - - /** - * @param string $parent Required. The resource name of the private cloud to create the key for. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/privateClouds/my-cloud` - * Please see {@see VmwareEngineClient::privateCloudName()} for help formatting this field. - * @param \Google\Cloud\VmwareEngine\V1\HcxActivationKey $hcxActivationKey Required. The initial description of a new HCX activation key. When - * creating a new key, this field must be an empty object. - * @param string $hcxActivationKeyId Required. The user-provided identifier of the `HcxActivationKey` to be - * created. This identifier must be unique among `HcxActivationKey` resources - * within the parent and becomes the final token in the name URI. - * The identifier must meet the following requirements: - * - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * @return \Google\Cloud\VmwareEngine\V1\CreateHcxActivationKeyRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\VmwareEngine\V1\HcxActivationKey $hcxActivationKey, string $hcxActivationKeyId): self - { - return (new self()) - ->setParent($parent) - ->setHcxActivationKey($hcxActivationKey) - ->setHcxActivationKeyId($hcxActivationKeyId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The resource name of the private cloud to create the key for. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/privateClouds/my-cloud` - * @type \Google\Cloud\VmwareEngine\V1\HcxActivationKey $hcx_activation_key - * Required. The initial description of a new HCX activation key. When - * creating a new key, this field must be an empty object. - * @type string $hcx_activation_key_id - * Required. The user-provided identifier of the `HcxActivationKey` to be - * created. This identifier must be unique among `HcxActivationKey` resources - * within the parent and becomes the final token in the name URI. - * The identifier must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * @type string $request_id - * A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the private cloud to create the key for. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/privateClouds/my-cloud` - * - * 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 private cloud to create the key for. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/privateClouds/my-cloud` - * - * 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 initial description of a new HCX activation key. When - * creating a new key, this field must be an empty object. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.HcxActivationKey hcx_activation_key = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\VmwareEngine\V1\HcxActivationKey|null - */ - public function getHcxActivationKey() - { - return $this->hcx_activation_key; - } - - public function hasHcxActivationKey() - { - return isset($this->hcx_activation_key); - } - - public function clearHcxActivationKey() - { - unset($this->hcx_activation_key); - } - - /** - * Required. The initial description of a new HCX activation key. When - * creating a new key, this field must be an empty object. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.HcxActivationKey hcx_activation_key = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\VmwareEngine\V1\HcxActivationKey $var - * @return $this - */ - public function setHcxActivationKey($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\HcxActivationKey::class); - $this->hcx_activation_key = $var; - - return $this; - } - - /** - * Required. The user-provided identifier of the `HcxActivationKey` to be - * created. This identifier must be unique among `HcxActivationKey` resources - * within the parent and becomes the final token in the name URI. - * The identifier must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * Generated from protobuf field string hcx_activation_key_id = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getHcxActivationKeyId() - { - return $this->hcx_activation_key_id; - } - - /** - * Required. The user-provided identifier of the `HcxActivationKey` to be - * created. This identifier must be unique among `HcxActivationKey` resources - * within the parent and becomes the final token in the name URI. - * The identifier must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * Generated from protobuf field string hcx_activation_key_id = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setHcxActivationKeyId($var) - { - GPBUtil::checkString($var, True); - $this->hcx_activation_key_id = $var; - - return $this; - } - - /** - * A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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; - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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; - * @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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateLoggingServerRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateLoggingServerRequest.php deleted file mode 100644 index 23fa5f500e60..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateLoggingServerRequest.php +++ /dev/null @@ -1,313 +0,0 @@ -google.cloud.vmwareengine.v1.CreateLoggingServerRequest - */ -class CreateLoggingServerRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the private cloud - * to create a new Logging Server in. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The initial description of a new logging server. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.LoggingServer logging_server = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $logging_server = null; - /** - * Required. The user-provided identifier of the `LoggingServer` to be - * created. This identifier must be unique among `LoggingServer` resources - * within the parent and becomes the final token in the name URI. - * The identifier must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * Generated from protobuf field string logging_server_id = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $logging_server_id = ''; - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 resource name of the private cloud - * to create a new Logging Server in. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * Please see {@see VmwareEngineClient::privateCloudName()} for help formatting this field. - * @param \Google\Cloud\VmwareEngine\V1\LoggingServer $loggingServer Required. The initial description of a new logging server. - * @param string $loggingServerId Required. The user-provided identifier of the `LoggingServer` to be - * created. This identifier must be unique among `LoggingServer` resources - * within the parent and becomes the final token in the name URI. - * The identifier must meet the following requirements: - * - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * @return \Google\Cloud\VmwareEngine\V1\CreateLoggingServerRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\VmwareEngine\V1\LoggingServer $loggingServer, string $loggingServerId): self - { - return (new self()) - ->setParent($parent) - ->setLoggingServer($loggingServer) - ->setLoggingServerId($loggingServerId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The resource name of the private cloud - * to create a new Logging Server in. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * @type \Google\Cloud\VmwareEngine\V1\LoggingServer $logging_server - * Required. The initial description of a new logging server. - * @type string $logging_server_id - * Required. The user-provided identifier of the `LoggingServer` to be - * created. This identifier must be unique among `LoggingServer` resources - * within the parent and becomes the final token in the name URI. - * The identifier must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * @type string $request_id - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the private cloud - * to create a new Logging Server in. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * 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 private cloud - * to create a new Logging Server in. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * 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 initial description of a new logging server. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.LoggingServer logging_server = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\VmwareEngine\V1\LoggingServer|null - */ - public function getLoggingServer() - { - return $this->logging_server; - } - - public function hasLoggingServer() - { - return isset($this->logging_server); - } - - public function clearLoggingServer() - { - unset($this->logging_server); - } - - /** - * Required. The initial description of a new logging server. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.LoggingServer logging_server = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\VmwareEngine\V1\LoggingServer $var - * @return $this - */ - public function setLoggingServer($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\LoggingServer::class); - $this->logging_server = $var; - - return $this; - } - - /** - * Required. The user-provided identifier of the `LoggingServer` to be - * created. This identifier must be unique among `LoggingServer` resources - * within the parent and becomes the final token in the name URI. - * The identifier must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * Generated from protobuf field string logging_server_id = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getLoggingServerId() - { - return $this->logging_server_id; - } - - /** - * Required. The user-provided identifier of the `LoggingServer` to be - * created. This identifier must be unique among `LoggingServer` resources - * within the parent and becomes the final token in the name URI. - * The identifier must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * Generated from protobuf field string logging_server_id = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setLoggingServerId($var) - { - GPBUtil::checkString($var, True); - $this->logging_server_id = $var; - - return $this; - } - - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateManagementDnsZoneBindingRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateManagementDnsZoneBindingRequest.php deleted file mode 100644 index 28fd5cd0a7b2..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateManagementDnsZoneBindingRequest.php +++ /dev/null @@ -1,317 +0,0 @@ -google.cloud.vmwareengine.v1.CreateManagementDnsZoneBindingRequest - */ -class CreateManagementDnsZoneBindingRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the private cloud - * to create a new management DNS zone binding for. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The initial values for a new management DNS zone binding. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.ManagementDnsZoneBinding management_dns_zone_binding = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $management_dns_zone_binding = null; - /** - * Required. The user-provided identifier of the `ManagementDnsZoneBinding` - * resource to be created. This identifier must be unique among - * `ManagementDnsZoneBinding` resources within the parent and becomes the - * final token in the name URI. The identifier must meet the following - * requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * Generated from protobuf field string management_dns_zone_binding_id = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $management_dns_zone_binding_id = ''; - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 the 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 resource name of the private cloud - * to create a new management DNS zone binding for. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * Please see {@see VmwareEngineClient::privateCloudName()} for help formatting this field. - * @param \Google\Cloud\VmwareEngine\V1\ManagementDnsZoneBinding $managementDnsZoneBinding Required. The initial values for a new management DNS zone binding. - * @param string $managementDnsZoneBindingId Required. The user-provided identifier of the `ManagementDnsZoneBinding` - * resource to be created. This identifier must be unique among - * `ManagementDnsZoneBinding` resources within the parent and becomes the - * final token in the name URI. The identifier must meet the following - * requirements: - * - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * @return \Google\Cloud\VmwareEngine\V1\CreateManagementDnsZoneBindingRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\VmwareEngine\V1\ManagementDnsZoneBinding $managementDnsZoneBinding, string $managementDnsZoneBindingId): self - { - return (new self()) - ->setParent($parent) - ->setManagementDnsZoneBinding($managementDnsZoneBinding) - ->setManagementDnsZoneBindingId($managementDnsZoneBindingId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The resource name of the private cloud - * to create a new management DNS zone binding for. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * @type \Google\Cloud\VmwareEngine\V1\ManagementDnsZoneBinding $management_dns_zone_binding - * Required. The initial values for a new management DNS zone binding. - * @type string $management_dns_zone_binding_id - * Required. The user-provided identifier of the `ManagementDnsZoneBinding` - * resource to be created. This identifier must be unique among - * `ManagementDnsZoneBinding` resources within the parent and becomes the - * final token in the name URI. The identifier must meet the following - * requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * @type string $request_id - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 the 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\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the private cloud - * to create a new management DNS zone binding for. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * 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 private cloud - * to create a new management DNS zone binding for. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * 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 initial values for a new management DNS zone binding. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.ManagementDnsZoneBinding management_dns_zone_binding = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\VmwareEngine\V1\ManagementDnsZoneBinding|null - */ - public function getManagementDnsZoneBinding() - { - return $this->management_dns_zone_binding; - } - - public function hasManagementDnsZoneBinding() - { - return isset($this->management_dns_zone_binding); - } - - public function clearManagementDnsZoneBinding() - { - unset($this->management_dns_zone_binding); - } - - /** - * Required. The initial values for a new management DNS zone binding. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.ManagementDnsZoneBinding management_dns_zone_binding = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\VmwareEngine\V1\ManagementDnsZoneBinding $var - * @return $this - */ - public function setManagementDnsZoneBinding($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\ManagementDnsZoneBinding::class); - $this->management_dns_zone_binding = $var; - - return $this; - } - - /** - * Required. The user-provided identifier of the `ManagementDnsZoneBinding` - * resource to be created. This identifier must be unique among - * `ManagementDnsZoneBinding` resources within the parent and becomes the - * final token in the name URI. The identifier must meet the following - * requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * Generated from protobuf field string management_dns_zone_binding_id = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getManagementDnsZoneBindingId() - { - return $this->management_dns_zone_binding_id; - } - - /** - * Required. The user-provided identifier of the `ManagementDnsZoneBinding` - * resource to be created. This identifier must be unique among - * `ManagementDnsZoneBinding` resources within the parent and becomes the - * final token in the name URI. The identifier must meet the following - * requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * Generated from protobuf field string management_dns_zone_binding_id = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setManagementDnsZoneBindingId($var) - { - GPBUtil::checkString($var, True); - $this->management_dns_zone_binding_id = $var; - - return $this; - } - - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 the 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. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 the 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateNetworkPeeringRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateNetworkPeeringRequest.php deleted file mode 100644 index bb3d32182c96..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateNetworkPeeringRequest.php +++ /dev/null @@ -1,308 +0,0 @@ -google.cloud.vmwareengine.v1.CreateNetworkPeeringRequest - */ -class CreateNetworkPeeringRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the location to create the new network - * peering in. This value is always `global`, because `NetworkPeering` is a - * global resource. Resource names are schemeless URIs that follow the - * conventions in https://cloud.google.com/apis/design/resource_names. For - * example: `projects/my-project/locations/global` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The user-provided identifier of the new `NetworkPeering`. - * This identifier must be unique among `NetworkPeering` resources within the - * parent and becomes the final token in the name URI. - * The identifier must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * Generated from protobuf field string network_peering_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $network_peering_id = ''; - /** - * Required. The initial description of the new network peering. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPeering network_peering = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $network_peering = null; - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 resource name of the location to create the new network - * peering in. This value is always `global`, because `NetworkPeering` is a - * global resource. Resource names are schemeless URIs that follow the - * conventions in https://cloud.google.com/apis/design/resource_names. For - * example: `projects/my-project/locations/global` - * Please see {@see VmwareEngineClient::locationName()} for help formatting this field. - * @param \Google\Cloud\VmwareEngine\V1\NetworkPeering $networkPeering Required. The initial description of the new network peering. - * @param string $networkPeeringId Required. The user-provided identifier of the new `NetworkPeering`. - * This identifier must be unique among `NetworkPeering` resources within the - * parent and becomes the final token in the name URI. - * The identifier must meet the following requirements: - * - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * @return \Google\Cloud\VmwareEngine\V1\CreateNetworkPeeringRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\VmwareEngine\V1\NetworkPeering $networkPeering, string $networkPeeringId): self - { - return (new self()) - ->setParent($parent) - ->setNetworkPeering($networkPeering) - ->setNetworkPeeringId($networkPeeringId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The resource name of the location to create the new network - * peering in. This value is always `global`, because `NetworkPeering` is a - * global resource. Resource names are schemeless URIs that follow the - * conventions in https://cloud.google.com/apis/design/resource_names. For - * example: `projects/my-project/locations/global` - * @type string $network_peering_id - * Required. The user-provided identifier of the new `NetworkPeering`. - * This identifier must be unique among `NetworkPeering` resources within the - * parent and becomes the final token in the name URI. - * The identifier must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * @type \Google\Cloud\VmwareEngine\V1\NetworkPeering $network_peering - * Required. The initial description of the new network peering. - * @type string $request_id - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the location to create the new network - * peering in. This value is always `global`, because `NetworkPeering` is a - * global resource. Resource names are schemeless URIs that follow the - * conventions in https://cloud.google.com/apis/design/resource_names. For - * example: `projects/my-project/locations/global` - * - * 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 to create the new network - * peering in. This value is always `global`, because `NetworkPeering` is a - * global resource. Resource names are schemeless URIs that follow the - * conventions in https://cloud.google.com/apis/design/resource_names. For - * example: `projects/my-project/locations/global` - * - * 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 user-provided identifier of the new `NetworkPeering`. - * This identifier must be unique among `NetworkPeering` resources within the - * parent and becomes the final token in the name URI. - * The identifier must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * Generated from protobuf field string network_peering_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getNetworkPeeringId() - { - return $this->network_peering_id; - } - - /** - * Required. The user-provided identifier of the new `NetworkPeering`. - * This identifier must be unique among `NetworkPeering` resources within the - * parent and becomes the final token in the name URI. - * The identifier must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * Generated from protobuf field string network_peering_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setNetworkPeeringId($var) - { - GPBUtil::checkString($var, True); - $this->network_peering_id = $var; - - return $this; - } - - /** - * Required. The initial description of the new network peering. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPeering network_peering = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\VmwareEngine\V1\NetworkPeering|null - */ - public function getNetworkPeering() - { - return $this->network_peering; - } - - public function hasNetworkPeering() - { - return isset($this->network_peering); - } - - public function clearNetworkPeering() - { - unset($this->network_peering); - } - - /** - * Required. The initial description of the new network peering. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPeering network_peering = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\VmwareEngine\V1\NetworkPeering $var - * @return $this - */ - public function setNetworkPeering($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\NetworkPeering::class); - $this->network_peering = $var; - - return $this; - } - - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateNetworkPolicyRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateNetworkPolicyRequest.php deleted file mode 100644 index e347120fa827..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateNetworkPolicyRequest.php +++ /dev/null @@ -1,318 +0,0 @@ -google.cloud.vmwareengine.v1.CreateNetworkPolicyRequest - */ -class CreateNetworkPolicyRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the location (region) - * to create the new network policy in. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The user-provided identifier of the network policy to be created. - * This identifier must be unique within parent - * `projects/{my-project}/locations/{us-central1}/networkPolicies` and becomes - * the final token in the name URI. - * The identifier must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * Generated from protobuf field string network_policy_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $network_policy_id = ''; - /** - * Required. The network policy configuration to use in the request. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPolicy network_policy = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $network_policy = null; - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 resource name of the location (region) - * to create the new network policy in. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1` - * Please see {@see VmwareEngineClient::locationName()} for help formatting this field. - * @param \Google\Cloud\VmwareEngine\V1\NetworkPolicy $networkPolicy Required. The network policy configuration to use in the request. - * @param string $networkPolicyId Required. The user-provided identifier of the network policy to be created. - * This identifier must be unique within parent - * `projects/{my-project}/locations/{us-central1}/networkPolicies` and becomes - * the final token in the name URI. - * The identifier must meet the following requirements: - * - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * @return \Google\Cloud\VmwareEngine\V1\CreateNetworkPolicyRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\VmwareEngine\V1\NetworkPolicy $networkPolicy, string $networkPolicyId): self - { - return (new self()) - ->setParent($parent) - ->setNetworkPolicy($networkPolicy) - ->setNetworkPolicyId($networkPolicyId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The resource name of the location (region) - * to create the new network policy in. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1` - * @type string $network_policy_id - * Required. The user-provided identifier of the network policy to be created. - * This identifier must be unique within parent - * `projects/{my-project}/locations/{us-central1}/networkPolicies` and becomes - * the final token in the name URI. - * The identifier must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * @type \Google\Cloud\VmwareEngine\V1\NetworkPolicy $network_policy - * Required. The network policy configuration to use in the request. - * @type string $request_id - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the location (region) - * to create the new network policy in. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1` - * - * 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 (region) - * to create the new network policy in. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1` - * - * 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 user-provided identifier of the network policy to be created. - * This identifier must be unique within parent - * `projects/{my-project}/locations/{us-central1}/networkPolicies` and becomes - * the final token in the name URI. - * The identifier must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * Generated from protobuf field string network_policy_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getNetworkPolicyId() - { - return $this->network_policy_id; - } - - /** - * Required. The user-provided identifier of the network policy to be created. - * This identifier must be unique within parent - * `projects/{my-project}/locations/{us-central1}/networkPolicies` and becomes - * the final token in the name URI. - * The identifier must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * Generated from protobuf field string network_policy_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setNetworkPolicyId($var) - { - GPBUtil::checkString($var, True); - $this->network_policy_id = $var; - - return $this; - } - - /** - * Required. The network policy configuration to use in the request. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPolicy network_policy = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\VmwareEngine\V1\NetworkPolicy|null - */ - public function getNetworkPolicy() - { - return $this->network_policy; - } - - public function hasNetworkPolicy() - { - return isset($this->network_policy); - } - - public function clearNetworkPolicy() - { - unset($this->network_policy); - } - - /** - * Required. The network policy configuration to use in the request. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPolicy network_policy = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\VmwareEngine\V1\NetworkPolicy $var - * @return $this - */ - public function setNetworkPolicy($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\NetworkPolicy::class); - $this->network_policy = $var; - - return $this; - } - - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreatePrivateCloudRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreatePrivateCloudRequest.php deleted file mode 100644 index b83a8b03ac8d..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreatePrivateCloudRequest.php +++ /dev/null @@ -1,306 +0,0 @@ -google.cloud.vmwareengine.v1.CreatePrivateCloudRequest - */ -class CreatePrivateCloudRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the location to create the new - * private cloud in. Resource names are schemeless URIs that follow the - * conventions in https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The user-provided identifier of the private cloud to be created. - * This identifier must be unique among each `PrivateCloud` within the parent - * and becomes the final token in the name URI. - * The identifier must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * Generated from protobuf field string private_cloud_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $private_cloud_id = ''; - /** - * Required. The initial description of the new private cloud. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateCloud private_cloud = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $private_cloud = null; - /** - * Optional. 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. True if you want the request to be validated and not executed; - * false otherwise. - * - * Generated from protobuf field bool validate_only = 5 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $validate_only = false; - - /** - * @param string $parent Required. The resource name of the location to create the new - * private cloud in. Resource names are schemeless URIs that follow the - * conventions in https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a` - * Please see {@see VmwareEngineClient::locationName()} for help formatting this field. - * @param \Google\Cloud\VmwareEngine\V1\PrivateCloud $privateCloud Required. The initial description of the new private cloud. - * @param string $privateCloudId Required. The user-provided identifier of the private cloud to be created. - * This identifier must be unique among each `PrivateCloud` within the parent - * and becomes the final token in the name URI. - * The identifier must meet the following requirements: - * - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * @return \Google\Cloud\VmwareEngine\V1\CreatePrivateCloudRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\VmwareEngine\V1\PrivateCloud $privateCloud, string $privateCloudId): self - { - return (new self()) - ->setParent($parent) - ->setPrivateCloud($privateCloud) - ->setPrivateCloudId($privateCloudId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The resource name of the location to create the new - * private cloud in. Resource names are schemeless URIs that follow the - * conventions in https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a` - * @type string $private_cloud_id - * Required. The user-provided identifier of the private cloud to be created. - * This identifier must be unique among each `PrivateCloud` within the parent - * and becomes the final token in the name URI. - * The identifier must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * @type \Google\Cloud\VmwareEngine\V1\PrivateCloud $private_cloud - * Required. The initial description of the new private cloud. - * @type string $request_id - * Optional. 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. True if you want the request to be validated and not executed; - * false otherwise. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the location to create the new - * private cloud in. Resource names are schemeless URIs that follow the - * conventions in https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a` - * - * 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 to create the new - * private cloud in. Resource names are schemeless URIs that follow the - * conventions in https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a` - * - * 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 user-provided identifier of the private cloud to be created. - * This identifier must be unique among each `PrivateCloud` within the parent - * and becomes the final token in the name URI. - * The identifier must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * Generated from protobuf field string private_cloud_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getPrivateCloudId() - { - return $this->private_cloud_id; - } - - /** - * Required. The user-provided identifier of the private cloud to be created. - * This identifier must be unique among each `PrivateCloud` within the parent - * and becomes the final token in the name URI. - * The identifier must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * Generated from protobuf field string private_cloud_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setPrivateCloudId($var) - { - GPBUtil::checkString($var, True); - $this->private_cloud_id = $var; - - return $this; - } - - /** - * Required. The initial description of the new private cloud. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateCloud private_cloud = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\VmwareEngine\V1\PrivateCloud|null - */ - public function getPrivateCloud() - { - return $this->private_cloud; - } - - public function hasPrivateCloud() - { - return isset($this->private_cloud); - } - - public function clearPrivateCloud() - { - unset($this->private_cloud); - } - - /** - * Required. The initial description of the new private cloud. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateCloud private_cloud = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\VmwareEngine\V1\PrivateCloud $var - * @return $this - */ - public function setPrivateCloud($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\PrivateCloud::class); - $this->private_cloud = $var; - - return $this; - } - - /** - * Optional. 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. 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. True if you want the request to be validated and not executed; - * false otherwise. - * - * Generated from protobuf field bool validate_only = 5 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getValidateOnly() - { - return $this->validate_only; - } - - /** - * Optional. True if you want the request to be validated and not executed; - * false otherwise. - * - * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreatePrivateConnectionRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreatePrivateConnectionRequest.php deleted file mode 100644 index 6210d15244f2..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreatePrivateConnectionRequest.php +++ /dev/null @@ -1,308 +0,0 @@ -google.cloud.vmwareengine.v1.CreatePrivateConnectionRequest - */ -class CreatePrivateConnectionRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the location to create the new private - * connection in. Private connection is a regional resource. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. For example: - * `projects/my-project/locations/us-central1` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The user-provided identifier of the new private connection. - * This identifier must be unique among private connection resources - * within the parent and becomes the final token in the name URI. The - * identifier must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * Generated from protobuf field string private_connection_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $private_connection_id = ''; - /** - * Required. The initial description of the new private connection. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateConnection private_connection = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $private_connection = null; - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 resource name of the location to create the new private - * connection in. Private connection is a regional resource. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. For example: - * `projects/my-project/locations/us-central1` - * Please see {@see VmwareEngineClient::locationName()} for help formatting this field. - * @param \Google\Cloud\VmwareEngine\V1\PrivateConnection $privateConnection Required. The initial description of the new private connection. - * @param string $privateConnectionId Required. The user-provided identifier of the new private connection. - * This identifier must be unique among private connection resources - * within the parent and becomes the final token in the name URI. The - * identifier must meet the following requirements: - * - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * @return \Google\Cloud\VmwareEngine\V1\CreatePrivateConnectionRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\VmwareEngine\V1\PrivateConnection $privateConnection, string $privateConnectionId): self - { - return (new self()) - ->setParent($parent) - ->setPrivateConnection($privateConnection) - ->setPrivateConnectionId($privateConnectionId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The resource name of the location to create the new private - * connection in. Private connection is a regional resource. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. For example: - * `projects/my-project/locations/us-central1` - * @type string $private_connection_id - * Required. The user-provided identifier of the new private connection. - * This identifier must be unique among private connection resources - * within the parent and becomes the final token in the name URI. The - * identifier must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * @type \Google\Cloud\VmwareEngine\V1\PrivateConnection $private_connection - * Required. The initial description of the new private connection. - * @type string $request_id - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the location to create the new private - * connection in. Private connection is a regional resource. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. For example: - * `projects/my-project/locations/us-central1` - * - * 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 to create the new private - * connection in. Private connection is a regional resource. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. For example: - * `projects/my-project/locations/us-central1` - * - * 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 user-provided identifier of the new private connection. - * This identifier must be unique among private connection resources - * within the parent and becomes the final token in the name URI. The - * identifier must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * Generated from protobuf field string private_connection_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getPrivateConnectionId() - { - return $this->private_connection_id; - } - - /** - * Required. The user-provided identifier of the new private connection. - * This identifier must be unique among private connection resources - * within the parent and becomes the final token in the name URI. The - * identifier must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * Generated from protobuf field string private_connection_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setPrivateConnectionId($var) - { - GPBUtil::checkString($var, True); - $this->private_connection_id = $var; - - return $this; - } - - /** - * Required. The initial description of the new private connection. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateConnection private_connection = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\VmwareEngine\V1\PrivateConnection|null - */ - public function getPrivateConnection() - { - return $this->private_connection; - } - - public function hasPrivateConnection() - { - return isset($this->private_connection); - } - - public function clearPrivateConnection() - { - unset($this->private_connection); - } - - /** - * Required. The initial description of the new private connection. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateConnection private_connection = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\VmwareEngine\V1\PrivateConnection $var - * @return $this - */ - public function setPrivateConnection($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\PrivateConnection::class); - $this->private_connection = $var; - - return $this; - } - - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateVmwareEngineNetworkRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateVmwareEngineNetworkRequest.php deleted file mode 100644 index 525b849b4e6b..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/CreateVmwareEngineNetworkRequest.php +++ /dev/null @@ -1,333 +0,0 @@ -google.cloud.vmwareengine.v1.CreateVmwareEngineNetworkRequest - */ -class CreateVmwareEngineNetworkRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the location to create the new VMware Engine - * network in. A VMware Engine network of type - * `LEGACY` is a regional resource, and a VMware - * Engine network of type `STANDARD` is a global resource. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. For example: - * `projects/my-project/locations/global` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * Required. The user-provided identifier of the new VMware Engine network. - * This identifier must be unique among VMware Engine network resources - * within the parent and becomes the final token in the name URI. The - * identifier must meet the following requirements: - * * For networks of type LEGACY, adheres to the format: - * `{region-id}-default`. Replace `{region-id}` with the region where you want - * to create the VMware Engine network. For example, "us-central1-default". - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * Generated from protobuf field string vmware_engine_network_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $vmware_engine_network_id = ''; - /** - * Required. The initial description of the new VMware Engine network. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.VmwareEngineNetwork vmware_engine_network = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $vmware_engine_network = null; - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 resource name of the location to create the new VMware Engine - * network in. A VMware Engine network of type - * `LEGACY` is a regional resource, and a VMware - * Engine network of type `STANDARD` is a global resource. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. For example: - * `projects/my-project/locations/global` - * Please see {@see VmwareEngineClient::locationName()} for help formatting this field. - * @param \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork $vmwareEngineNetwork Required. The initial description of the new VMware Engine network. - * @param string $vmwareEngineNetworkId Required. The user-provided identifier of the new VMware Engine network. - * This identifier must be unique among VMware Engine network resources - * within the parent and becomes the final token in the name URI. The - * identifier must meet the following requirements: - * - * * For networks of type LEGACY, adheres to the format: - * `{region-id}-default`. Replace `{region-id}` with the region where you want - * to create the VMware Engine network. For example, "us-central1-default". - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * @return \Google\Cloud\VmwareEngine\V1\CreateVmwareEngineNetworkRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork $vmwareEngineNetwork, string $vmwareEngineNetworkId): self - { - return (new self()) - ->setParent($parent) - ->setVmwareEngineNetwork($vmwareEngineNetwork) - ->setVmwareEngineNetworkId($vmwareEngineNetworkId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The resource name of the location to create the new VMware Engine - * network in. A VMware Engine network of type - * `LEGACY` is a regional resource, and a VMware - * Engine network of type `STANDARD` is a global resource. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. For example: - * `projects/my-project/locations/global` - * @type string $vmware_engine_network_id - * Required. The user-provided identifier of the new VMware Engine network. - * This identifier must be unique among VMware Engine network resources - * within the parent and becomes the final token in the name URI. The - * identifier must meet the following requirements: - * * For networks of type LEGACY, adheres to the format: - * `{region-id}-default`. Replace `{region-id}` with the region where you want - * to create the VMware Engine network. For example, "us-central1-default". - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * @type \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork $vmware_engine_network - * Required. The initial description of the new VMware Engine network. - * @type string $request_id - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the location to create the new VMware Engine - * network in. A VMware Engine network of type - * `LEGACY` is a regional resource, and a VMware - * Engine network of type `STANDARD` is a global resource. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. For example: - * `projects/my-project/locations/global` - * - * 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 to create the new VMware Engine - * network in. A VMware Engine network of type - * `LEGACY` is a regional resource, and a VMware - * Engine network of type `STANDARD` is a global resource. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. For example: - * `projects/my-project/locations/global` - * - * 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 user-provided identifier of the new VMware Engine network. - * This identifier must be unique among VMware Engine network resources - * within the parent and becomes the final token in the name URI. The - * identifier must meet the following requirements: - * * For networks of type LEGACY, adheres to the format: - * `{region-id}-default`. Replace `{region-id}` with the region where you want - * to create the VMware Engine network. For example, "us-central1-default". - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * Generated from protobuf field string vmware_engine_network_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getVmwareEngineNetworkId() - { - return $this->vmware_engine_network_id; - } - - /** - * Required. The user-provided identifier of the new VMware Engine network. - * This identifier must be unique among VMware Engine network resources - * within the parent and becomes the final token in the name URI. The - * identifier must meet the following requirements: - * * For networks of type LEGACY, adheres to the format: - * `{region-id}-default`. Replace `{region-id}` with the region where you want - * to create the VMware Engine network. For example, "us-central1-default". - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC 1034](https://datatracker.ietf.org/doc/html/rfc1034) - * (section 3.5) - * - * Generated from protobuf field string vmware_engine_network_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setVmwareEngineNetworkId($var) - { - GPBUtil::checkString($var, True); - $this->vmware_engine_network_id = $var; - - return $this; - } - - /** - * Required. The initial description of the new VMware Engine network. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.VmwareEngineNetwork vmware_engine_network = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork|null - */ - public function getVmwareEngineNetwork() - { - return $this->vmware_engine_network; - } - - public function hasVmwareEngineNetwork() - { - return isset($this->vmware_engine_network); - } - - public function clearVmwareEngineNetwork() - { - unset($this->vmware_engine_network); - } - - /** - * Required. The initial description of the new VMware Engine network. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.VmwareEngineNetwork vmware_engine_network = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork $var - * @return $this - */ - public function setVmwareEngineNetwork($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork::class); - $this->vmware_engine_network = $var; - - return $this; - } - - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Credentials.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Credentials.php deleted file mode 100644 index 330a9a4558f3..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Credentials.php +++ /dev/null @@ -1,101 +0,0 @@ -google.cloud.vmwareengine.v1.Credentials - */ -class Credentials extends \Google\Protobuf\Internal\Message -{ - /** - * Initial username. - * - * Generated from protobuf field string username = 1; - */ - protected $username = ''; - /** - * Initial password. - * - * Generated from protobuf field string password = 2; - */ - protected $password = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $username - * Initial username. - * @type string $password - * Initial password. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); - parent::__construct($data); - } - - /** - * Initial username. - * - * Generated from protobuf field string username = 1; - * @return string - */ - public function getUsername() - { - return $this->username; - } - - /** - * Initial username. - * - * Generated from protobuf field string username = 1; - * @param string $var - * @return $this - */ - public function setUsername($var) - { - GPBUtil::checkString($var, True); - $this->username = $var; - - return $this; - } - - /** - * Initial password. - * - * Generated from protobuf field string password = 2; - * @return string - */ - public function getPassword() - { - return $this->password; - } - - /** - * Initial password. - * - * Generated from protobuf field string password = 2; - * @param string $var - * @return $this - */ - public function setPassword($var) - { - GPBUtil::checkString($var, True); - $this->password = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteClusterRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteClusterRequest.php deleted file mode 100644 index 20cec6ac10fd..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteClusterRequest.php +++ /dev/null @@ -1,140 +0,0 @@ -google.cloud.vmwareengine.v1.DeleteClusterRequest - */ -class DeleteClusterRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the cluster to delete. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Optional. 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 = ''; - - /** - * @param string $name Required. The resource name of the cluster to delete. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster` - * Please see {@see VmwareEngineClient::clusterName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\DeleteClusterRequest - * - * @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 cluster to delete. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster` - * @type string $request_id - * Optional. 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\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the cluster to delete. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster` - * - * 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 cluster to delete. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster` - * - * 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 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. 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; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteExternalAccessRuleRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteExternalAccessRuleRequest.php deleted file mode 100644 index 454591e21d3f..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteExternalAccessRuleRequest.php +++ /dev/null @@ -1,180 +0,0 @@ -google.cloud.vmwareengine.v1.DeleteExternalAccessRuleRequest - */ -class DeleteExternalAccessRuleRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the external access firewall rule to delete. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/networkPolicies/my-policy/externalAccessRules/my-rule` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 the 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 = ''; - - /** - * @param string $name Required. The resource name of the external access firewall rule to delete. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/networkPolicies/my-policy/externalAccessRules/my-rule` - * Please see {@see VmwareEngineClient::externalAccessRuleName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\DeleteExternalAccessRuleRequest - * - * @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 external access firewall rule to delete. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/networkPolicies/my-policy/externalAccessRules/my-rule` - * @type string $request_id - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 the 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\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the external access firewall rule to delete. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/networkPolicies/my-policy/externalAccessRules/my-rule` - * - * 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 external access firewall rule to delete. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/networkPolicies/my-policy/externalAccessRules/my-rule` - * - * 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. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 the 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. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 the 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; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteExternalAddressRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteExternalAddressRequest.php deleted file mode 100644 index 1b2035b496db..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteExternalAddressRequest.php +++ /dev/null @@ -1,180 +0,0 @@ -google.cloud.vmwareengine.v1.DeleteExternalAddressRequest - */ -class DeleteExternalAddressRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the external IP address to delete. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/externalAddresses/my-ip` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 the 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 = ''; - - /** - * @param string $name Required. The resource name of the external IP address to delete. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/externalAddresses/my-ip` - * Please see {@see VmwareEngineClient::externalAddressName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\DeleteExternalAddressRequest - * - * @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 external IP address to delete. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/externalAddresses/my-ip` - * @type string $request_id - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 the 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\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the external IP address to delete. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/externalAddresses/my-ip` - * - * 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 external IP address to delete. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/externalAddresses/my-ip` - * - * 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. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 the 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. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 the 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; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteLoggingServerRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteLoggingServerRequest.php deleted file mode 100644 index e383258aeaf8..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteLoggingServerRequest.php +++ /dev/null @@ -1,180 +0,0 @@ -google.cloud.vmwareengine.v1.DeleteLoggingServerRequest - */ -class DeleteLoggingServerRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the logging server to delete. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/loggingServers/my-logging-server` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $request_id = ''; - - /** - * @param string $name Required. The resource name of the logging server to delete. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/loggingServers/my-logging-server` - * Please see {@see VmwareEngineClient::loggingServerName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\DeleteLoggingServerRequest - * - * @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 logging server to delete. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/loggingServers/my-logging-server` - * @type string $request_id - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the logging server to delete. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/loggingServers/my-logging-server` - * - * 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 logging server to delete. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/loggingServers/my-logging-server` - * - * 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. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 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; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteManagementDnsZoneBindingRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteManagementDnsZoneBindingRequest.php deleted file mode 100644 index a3d0fd65140e..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteManagementDnsZoneBindingRequest.php +++ /dev/null @@ -1,180 +0,0 @@ -google.cloud.vmwareengine.v1.DeleteManagementDnsZoneBindingRequest - */ -class DeleteManagementDnsZoneBindingRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the management DNS zone binding to delete. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/managementDnsZoneBindings/my-management-dns-zone-binding` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 the 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 = ''; - - /** - * @param string $name Required. The resource name of the management DNS zone binding to delete. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/managementDnsZoneBindings/my-management-dns-zone-binding` - * Please see {@see VmwareEngineClient::managementDnsZoneBindingName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\DeleteManagementDnsZoneBindingRequest - * - * @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 management DNS zone binding to delete. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/managementDnsZoneBindings/my-management-dns-zone-binding` - * @type string $request_id - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 the 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\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the management DNS zone binding to delete. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/managementDnsZoneBindings/my-management-dns-zone-binding` - * - * 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 management DNS zone binding to delete. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/managementDnsZoneBindings/my-management-dns-zone-binding` - * - * 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. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 the 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. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 the 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; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteNetworkPeeringRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteNetworkPeeringRequest.php deleted file mode 100644 index be442e7f5f22..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteNetworkPeeringRequest.php +++ /dev/null @@ -1,180 +0,0 @@ -google.cloud.vmwareengine.v1.DeleteNetworkPeeringRequest - */ -class DeleteNetworkPeeringRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the network peering to be deleted. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/global/networkPeerings/my-peering` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $request_id = ''; - - /** - * @param string $name Required. The resource name of the network peering to be deleted. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/global/networkPeerings/my-peering` - * Please see {@see VmwareEngineClient::networkPeeringName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\DeleteNetworkPeeringRequest - * - * @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 network peering to be deleted. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/global/networkPeerings/my-peering` - * @type string $request_id - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the network peering to be deleted. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/global/networkPeerings/my-peering` - * - * 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 network peering to be deleted. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/global/networkPeerings/my-peering` - * - * 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. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 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; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteNetworkPolicyRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteNetworkPolicyRequest.php deleted file mode 100644 index e0962e320717..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteNetworkPolicyRequest.php +++ /dev/null @@ -1,180 +0,0 @@ -google.cloud.vmwareengine.v1.DeleteNetworkPolicyRequest - */ -class DeleteNetworkPolicyRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the network policy to delete. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/networkPolicies/my-network-policy` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $request_id = ''; - - /** - * @param string $name Required. The resource name of the network policy to delete. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/networkPolicies/my-network-policy` - * Please see {@see VmwareEngineClient::networkPolicyName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\DeleteNetworkPolicyRequest - * - * @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 network policy to delete. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/networkPolicies/my-network-policy` - * @type string $request_id - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the network policy to delete. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/networkPolicies/my-network-policy` - * - * 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 network policy to delete. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/networkPolicies/my-network-policy` - * - * 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. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 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; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeletePrivateCloudRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeletePrivateCloudRequest.php deleted file mode 100644 index 6a0d40bcbdc3..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeletePrivateCloudRequest.php +++ /dev/null @@ -1,262 +0,0 @@ -google.cloud.vmwareengine.v1.DeletePrivateCloudRequest - */ -class DeletePrivateCloudRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the private cloud to delete. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Optional. 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 to true, cascade delete is enabled and all children of - * this private cloud resource are also deleted. When this flag is set to - * false, the private cloud will not be deleted if there are any children - * other than the management cluster. The management cluster is always - * deleted. - * - * Generated from protobuf field bool force = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $force = false; - /** - * Optional. Time delay of the deletion specified in hours. The default value - * is `3`. Specifying a non-zero value for this field changes the value of - * `PrivateCloud.state` to `DELETED` and sets `expire_time` to the planned - * deletion time. Deletion can be cancelled before `expire_time` elapses using - * [VmwareEngine.UndeletePrivateCloud][google.cloud.vmwareengine.v1.VmwareEngine.UndeletePrivateCloud]. - * Specifying a value of `0` for this field instead begins the deletion - * process and ceases billing immediately. During the final deletion process, - * the value of `PrivateCloud.state` becomes `PURGING`. - * - * Generated from protobuf field optional int32 delay_hours = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $delay_hours = null; - - /** - * @param string $name Required. The resource name of the private cloud to delete. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * Please see {@see VmwareEngineClient::privateCloudName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\DeletePrivateCloudRequest - * - * @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 private cloud to delete. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * @type string $request_id - * Optional. The request ID must be a valid UUID with the exception that zero - * UUID is not supported (00000000-0000-0000-0000-000000000000). - * @type bool $force - * Optional. If set to true, cascade delete is enabled and all children of - * this private cloud resource are also deleted. When this flag is set to - * false, the private cloud will not be deleted if there are any children - * other than the management cluster. The management cluster is always - * deleted. - * @type int $delay_hours - * Optional. Time delay of the deletion specified in hours. The default value - * is `3`. Specifying a non-zero value for this field changes the value of - * `PrivateCloud.state` to `DELETED` and sets `expire_time` to the planned - * deletion time. Deletion can be cancelled before `expire_time` elapses using - * [VmwareEngine.UndeletePrivateCloud][google.cloud.vmwareengine.v1.VmwareEngine.UndeletePrivateCloud]. - * Specifying a value of `0` for this field instead begins the deletion - * process and ceases billing immediately. During the final deletion process, - * the value of `PrivateCloud.state` becomes `PURGING`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the private cloud to delete. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * 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 private cloud to delete. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * 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 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. 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 to true, cascade delete is enabled and all children of - * this private cloud resource are also deleted. When this flag is set to - * false, the private cloud will not be deleted if there are any children - * other than the management cluster. The management cluster is always - * deleted. - * - * Generated from protobuf field bool force = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getForce() - { - return $this->force; - } - - /** - * Optional. If set to true, cascade delete is enabled and all children of - * this private cloud resource are also deleted. When this flag is set to - * false, the private cloud will not be deleted if there are any children - * other than the management cluster. The management cluster is always - * deleted. - * - * Generated from protobuf field bool force = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param bool $var - * @return $this - */ - public function setForce($var) - { - GPBUtil::checkBool($var); - $this->force = $var; - - return $this; - } - - /** - * Optional. Time delay of the deletion specified in hours. The default value - * is `3`. Specifying a non-zero value for this field changes the value of - * `PrivateCloud.state` to `DELETED` and sets `expire_time` to the planned - * deletion time. Deletion can be cancelled before `expire_time` elapses using - * [VmwareEngine.UndeletePrivateCloud][google.cloud.vmwareengine.v1.VmwareEngine.UndeletePrivateCloud]. - * Specifying a value of `0` for this field instead begins the deletion - * process and ceases billing immediately. During the final deletion process, - * the value of `PrivateCloud.state` becomes `PURGING`. - * - * Generated from protobuf field optional int32 delay_hours = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getDelayHours() - { - return isset($this->delay_hours) ? $this->delay_hours : 0; - } - - public function hasDelayHours() - { - return isset($this->delay_hours); - } - - public function clearDelayHours() - { - unset($this->delay_hours); - } - - /** - * Optional. Time delay of the deletion specified in hours. The default value - * is `3`. Specifying a non-zero value for this field changes the value of - * `PrivateCloud.state` to `DELETED` and sets `expire_time` to the planned - * deletion time. Deletion can be cancelled before `expire_time` elapses using - * [VmwareEngine.UndeletePrivateCloud][google.cloud.vmwareengine.v1.VmwareEngine.UndeletePrivateCloud]. - * Specifying a value of `0` for this field instead begins the deletion - * process and ceases billing immediately. During the final deletion process, - * the value of `PrivateCloud.state` becomes `PURGING`. - * - * Generated from protobuf field optional int32 delay_hours = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setDelayHours($var) - { - GPBUtil::checkInt32($var); - $this->delay_hours = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeletePrivateConnectionRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeletePrivateConnectionRequest.php deleted file mode 100644 index 98108687d10d..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeletePrivateConnectionRequest.php +++ /dev/null @@ -1,180 +0,0 @@ -google.cloud.vmwareengine.v1.DeletePrivateConnectionRequest - */ -class DeletePrivateConnectionRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the private connection to be deleted. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/privateConnections/my-connection` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $request_id = ''; - - /** - * @param string $name Required. The resource name of the private connection to be deleted. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/privateConnections/my-connection` - * Please see {@see VmwareEngineClient::privateConnectionName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\DeletePrivateConnectionRequest - * - * @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 private connection to be deleted. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/privateConnections/my-connection` - * @type string $request_id - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the private connection to be deleted. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/privateConnections/my-connection` - * - * 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 private connection to be deleted. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/privateConnections/my-connection` - * - * 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. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 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; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteVmwareEngineNetworkRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteVmwareEngineNetworkRequest.php deleted file mode 100644 index ff792e953240..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DeleteVmwareEngineNetworkRequest.php +++ /dev/null @@ -1,226 +0,0 @@ -google.cloud.vmwareengine.v1.DeleteVmwareEngineNetworkRequest - */ -class DeleteVmwareEngineNetworkRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the VMware Engine network to be deleted. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/global/vmwareEngineNetworks/my-network` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $request_id = ''; - /** - * Optional. Checksum used to ensure that the user-provided value is up to - * date before the server processes the request. The server compares provided - * checksum with the current checksum of the resource. If the user-provided - * value is out of date, this request returns an `ABORTED` error. - * - * Generated from protobuf field string etag = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $etag = ''; - - /** - * @param string $name Required. The resource name of the VMware Engine network to be deleted. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/global/vmwareEngineNetworks/my-network` - * Please see {@see VmwareEngineClient::vmwareEngineNetworkName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\DeleteVmwareEngineNetworkRequest - * - * @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 VMware Engine network to be deleted. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/global/vmwareEngineNetworks/my-network` - * @type string $request_id - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 string $etag - * Optional. Checksum used to ensure that the user-provided value is up to - * date before the server processes the request. The server compares provided - * checksum with the current checksum of the resource. If the user-provided - * value is out of date, this request returns an `ABORTED` error. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the VMware Engine network to be deleted. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/global/vmwareEngineNetworks/my-network` - * - * 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 VMware Engine network to be deleted. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/global/vmwareEngineNetworks/my-network` - * - * 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. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 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. Checksum used to ensure that the user-provided value is up to - * date before the server processes the request. The server compares provided - * checksum with the current checksum of the resource. If the user-provided - * value is out of date, this request returns an `ABORTED` error. - * - * Generated from protobuf field string etag = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getEtag() - { - return $this->etag; - } - - /** - * Optional. Checksum used to ensure that the user-provided value is up to - * date before the server processes the request. The server compares provided - * checksum with the current checksum of the resource. If the user-provided - * value is out of date, this request returns an `ABORTED` error. - * - * Generated from protobuf field string etag = 3 [(.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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DnsBindPermission.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DnsBindPermission.php deleted file mode 100644 index fd658e066f26..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DnsBindPermission.php +++ /dev/null @@ -1,130 +0,0 @@ -google.cloud.vmwareengine.v1.DnsBindPermission - */ -class DnsBindPermission extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Output only. The name of the resource which stores the - * users/service accounts having the permission to bind to the corresponding - * intranet VPC of the consumer project. DnsBindPermission is a global - * resource and location can only be global. Resource names are schemeless - * URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. For example: - * `projects/my-project/locations/global/dnsBindPermission` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * Output only. Users/Service accounts which have access for binding on the - * intranet VPC project corresponding to the consumer project. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.Principal principals = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - private $principals; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. Output only. The name of the resource which stores the - * users/service accounts having the permission to bind to the corresponding - * intranet VPC of the consumer project. DnsBindPermission is a global - * resource and location can only be global. Resource names are schemeless - * URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. For example: - * `projects/my-project/locations/global/dnsBindPermission` - * @type \Google\Cloud\VmwareEngine\V1\Principal[] $principals - * Output only. Users/Service accounts which have access for binding on the - * intranet VPC project corresponding to the consumer project. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); - parent::__construct($data); - } - - /** - * Required. Output only. The name of the resource which stores the - * users/service accounts having the permission to bind to the corresponding - * intranet VPC of the consumer project. DnsBindPermission is a global - * resource and location can only be global. Resource names are schemeless - * URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. For example: - * `projects/my-project/locations/global/dnsBindPermission` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Required. Output only. The name of the resource which stores the - * users/service accounts having the permission to bind to the corresponding - * intranet VPC of the consumer project. DnsBindPermission is a global - * resource and location can only be global. Resource names are schemeless - * URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. For example: - * `projects/my-project/locations/global/dnsBindPermission` - * - * 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. Users/Service accounts which have access for binding on the - * intranet VPC project corresponding to the consumer project. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.Principal principals = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\Principal> - */ - public function getPrincipals() - { - return $this->principals; - } - - /** - * Output only. Users/Service accounts which have access for binding on the - * intranet VPC project corresponding to the consumer project. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.Principal principals = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\VmwareEngine\V1\Principal[] $var - * @return $this - */ - public function setPrincipals($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\Principal::class); - $this->principals = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DnsForwarding.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DnsForwarding.php deleted file mode 100644 index 7163e44ee86c..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DnsForwarding.php +++ /dev/null @@ -1,207 +0,0 @@ -google.cloud.vmwareengine.v1.DnsForwarding - */ -class DnsForwarding extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The resource name of this DNS profile. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/dnsForwarding` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * Output only. Creation time of this resource. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. Last update time of this resource. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Required. List of domain mappings to configure - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.DnsForwarding.ForwardingRule forwarding_rules = 4 [(.google.api.field_behavior) = REQUIRED]; - */ - private $forwarding_rules; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. The resource name of this DNS profile. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/dnsForwarding` - * @type \Google\Protobuf\Timestamp $create_time - * Output only. Creation time of this resource. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. Last update time of this resource. - * @type \Google\Cloud\VmwareEngine\V1\DnsForwarding\ForwardingRule[] $forwarding_rules - * Required. List of domain mappings to configure - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The resource name of this DNS profile. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/dnsForwarding` - * - * 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 DNS profile. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/dnsForwarding` - * - * 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. Creation time of this resource. - * - * 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 time of this resource. - * - * 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 time of this resource. - * - * 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 time of this resource. - * - * 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; - } - - /** - * Required. List of domain mappings to configure - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.DnsForwarding.ForwardingRule forwarding_rules = 4 [(.google.api.field_behavior) = REQUIRED]; - * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\DnsForwarding\ForwardingRule> - */ - public function getForwardingRules() - { - return $this->forwarding_rules; - } - - /** - * Required. List of domain mappings to configure - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.DnsForwarding.ForwardingRule forwarding_rules = 4 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\VmwareEngine\V1\DnsForwarding\ForwardingRule[] $var - * @return $this - */ - public function setForwardingRules($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\DnsForwarding\ForwardingRule::class); - $this->forwarding_rules = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DnsForwarding/ForwardingRule.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DnsForwarding/ForwardingRule.php deleted file mode 100644 index 69ffc594750d..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/DnsForwarding/ForwardingRule.php +++ /dev/null @@ -1,104 +0,0 @@ -google.cloud.vmwareengine.v1.DnsForwarding.ForwardingRule - */ -class ForwardingRule extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Domain used to resolve a `name_servers` list. - * - * Generated from protobuf field string domain = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $domain = ''; - /** - * Required. List of DNS servers to use for domain resolution - * - * Generated from protobuf field repeated string name_servers = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - private $name_servers; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $domain - * Required. Domain used to resolve a `name_servers` list. - * @type string[] $name_servers - * Required. List of DNS servers to use for domain resolution - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); - parent::__construct($data); - } - - /** - * Required. Domain used to resolve a `name_servers` list. - * - * Generated from protobuf field string domain = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getDomain() - { - return $this->domain; - } - - /** - * Required. Domain used to resolve a `name_servers` list. - * - * Generated from protobuf field string domain = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setDomain($var) - { - GPBUtil::checkString($var, True); - $this->domain = $var; - - return $this; - } - - /** - * Required. List of DNS servers to use for domain resolution - * - * Generated from protobuf field repeated string name_servers = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return RepeatedField - */ - public function getNameServers() - { - return $this->name_servers; - } - - /** - * Required. List of DNS servers to use for domain resolution - * - * Generated from protobuf field repeated string name_servers = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string[] $var - * @return $this - */ - public function setNameServers($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->name_servers = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAccessRule.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAccessRule.php deleted file mode 100644 index 2b1a319b365b..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAccessRule.php +++ /dev/null @@ -1,620 +0,0 @@ -google.cloud.vmwareengine.v1.ExternalAccessRule - */ -class ExternalAccessRule extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The resource name of this external access rule. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/networkPolicies/my-policy/externalAccessRules/my-rule` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * Output only. Creation time of this resource. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. Last update time of this resource. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * User-provided description for this external access rule. - * - * Generated from protobuf field string description = 5; - */ - protected $description = ''; - /** - * External access rule priority, which determines the external access rule to - * use when multiple rules apply. If multiple rules have the same priority, - * their ordering is non-deterministic. If specific ordering is required, - * assign unique priorities to enforce such ordering. The external access rule - * priority is an integer from 100 to 4096, both inclusive. Lower integers - * indicate higher precedence. For example, a rule with priority `100` has - * higher precedence than a rule with priority `101`. - * - * Generated from protobuf field int32 priority = 6; - */ - protected $priority = 0; - /** - * The action that the external access rule performs. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.ExternalAccessRule.Action action = 7; - */ - protected $action = 0; - /** - * The IP protocol to which the external access rule applies. This value can - * be one of the following three protocol strings (not case-sensitive): - * `tcp`, `udp`, or `icmp`. - * - * Generated from protobuf field string ip_protocol = 8; - */ - protected $ip_protocol = ''; - /** - * If source ranges are specified, the external access rule applies only to - * traffic that has a source IP address in these ranges. These ranges can - * either be expressed in the CIDR format or as an IP address. As only inbound - * rules are supported, `ExternalAddress` resources cannot be the source IP - * addresses of an external access rule. To match all source addresses, - * specify `0.0.0.0/0`. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.ExternalAccessRule.IpRange source_ip_ranges = 9; - */ - private $source_ip_ranges; - /** - * A list of source ports to which the external access rule applies. This - * field is only applicable for the UDP or TCP protocol. - * Each entry must be either an integer or a range. For example: `["22"]`, - * `["80","443"]`, or `["12345-12349"]`. To match all source ports, specify - * `["0-65535"]`. - * - * Generated from protobuf field repeated string source_ports = 10; - */ - private $source_ports; - /** - * If destination ranges are specified, the external access rule applies only - * to the traffic that has a destination IP address in these ranges. The - * specified IP addresses must have reserved external IP addresses in the - * scope of the parent network policy. To match all external IP addresses in - * the scope of the parent network policy, specify `0.0.0.0/0`. To match a - * specific external IP address, specify it using the - * `IpRange.external_address` property. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.ExternalAccessRule.IpRange destination_ip_ranges = 11; - */ - private $destination_ip_ranges; - /** - * A list of destination ports to which the external access rule applies. This - * field is only applicable for the UDP or TCP protocol. - * Each entry must be either an integer or a range. For example: `["22"]`, - * `["80","443"]`, or `["12345-12349"]`. To match all destination ports, - * specify `["0-65535"]`. - * - * Generated from protobuf field repeated string destination_ports = 12; - */ - private $destination_ports; - /** - * Output only. The state of the resource. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.ExternalAccessRule.State state = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = 0; - /** - * Output only. System-generated unique identifier for the resource. - * - * Generated from protobuf field string uid = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $uid = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. The resource name of this external access rule. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/networkPolicies/my-policy/externalAccessRules/my-rule` - * @type \Google\Protobuf\Timestamp $create_time - * Output only. Creation time of this resource. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. Last update time of this resource. - * @type string $description - * User-provided description for this external access rule. - * @type int $priority - * External access rule priority, which determines the external access rule to - * use when multiple rules apply. If multiple rules have the same priority, - * their ordering is non-deterministic. If specific ordering is required, - * assign unique priorities to enforce such ordering. The external access rule - * priority is an integer from 100 to 4096, both inclusive. Lower integers - * indicate higher precedence. For example, a rule with priority `100` has - * higher precedence than a rule with priority `101`. - * @type int $action - * The action that the external access rule performs. - * @type string $ip_protocol - * The IP protocol to which the external access rule applies. This value can - * be one of the following three protocol strings (not case-sensitive): - * `tcp`, `udp`, or `icmp`. - * @type \Google\Cloud\VmwareEngine\V1\ExternalAccessRule\IpRange[] $source_ip_ranges - * If source ranges are specified, the external access rule applies only to - * traffic that has a source IP address in these ranges. These ranges can - * either be expressed in the CIDR format or as an IP address. As only inbound - * rules are supported, `ExternalAddress` resources cannot be the source IP - * addresses of an external access rule. To match all source addresses, - * specify `0.0.0.0/0`. - * @type string[] $source_ports - * A list of source ports to which the external access rule applies. This - * field is only applicable for the UDP or TCP protocol. - * Each entry must be either an integer or a range. For example: `["22"]`, - * `["80","443"]`, or `["12345-12349"]`. To match all source ports, specify - * `["0-65535"]`. - * @type \Google\Cloud\VmwareEngine\V1\ExternalAccessRule\IpRange[] $destination_ip_ranges - * If destination ranges are specified, the external access rule applies only - * to the traffic that has a destination IP address in these ranges. The - * specified IP addresses must have reserved external IP addresses in the - * scope of the parent network policy. To match all external IP addresses in - * the scope of the parent network policy, specify `0.0.0.0/0`. To match a - * specific external IP address, specify it using the - * `IpRange.external_address` property. - * @type string[] $destination_ports - * A list of destination ports to which the external access rule applies. This - * field is only applicable for the UDP or TCP protocol. - * Each entry must be either an integer or a range. For example: `["22"]`, - * `["80","443"]`, or `["12345-12349"]`. To match all destination ports, - * specify `["0-65535"]`. - * @type int $state - * Output only. The state of the resource. - * @type string $uid - * Output only. System-generated unique identifier for the resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The resource name of this external access rule. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/networkPolicies/my-policy/externalAccessRules/my-rule` - * - * 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 external access rule. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/networkPolicies/my-policy/externalAccessRules/my-rule` - * - * 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. Creation time of this resource. - * - * 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 time of this resource. - * - * 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 time of this resource. - * - * 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 time of this resource. - * - * 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; - } - - /** - * User-provided description for this external access rule. - * - * Generated from protobuf field string description = 5; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * User-provided description for this external access rule. - * - * 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; - } - - /** - * External access rule priority, which determines the external access rule to - * use when multiple rules apply. If multiple rules have the same priority, - * their ordering is non-deterministic. If specific ordering is required, - * assign unique priorities to enforce such ordering. The external access rule - * priority is an integer from 100 to 4096, both inclusive. Lower integers - * indicate higher precedence. For example, a rule with priority `100` has - * higher precedence than a rule with priority `101`. - * - * Generated from protobuf field int32 priority = 6; - * @return int - */ - public function getPriority() - { - return $this->priority; - } - - /** - * External access rule priority, which determines the external access rule to - * use when multiple rules apply. If multiple rules have the same priority, - * their ordering is non-deterministic. If specific ordering is required, - * assign unique priorities to enforce such ordering. The external access rule - * priority is an integer from 100 to 4096, both inclusive. Lower integers - * indicate higher precedence. For example, a rule with priority `100` has - * higher precedence than a rule with priority `101`. - * - * Generated from protobuf field int32 priority = 6; - * @param int $var - * @return $this - */ - public function setPriority($var) - { - GPBUtil::checkInt32($var); - $this->priority = $var; - - return $this; - } - - /** - * The action that the external access rule performs. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.ExternalAccessRule.Action action = 7; - * @return int - */ - public function getAction() - { - return $this->action; - } - - /** - * The action that the external access rule performs. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.ExternalAccessRule.Action action = 7; - * @param int $var - * @return $this - */ - public function setAction($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\ExternalAccessRule\Action::class); - $this->action = $var; - - return $this; - } - - /** - * The IP protocol to which the external access rule applies. This value can - * be one of the following three protocol strings (not case-sensitive): - * `tcp`, `udp`, or `icmp`. - * - * Generated from protobuf field string ip_protocol = 8; - * @return string - */ - public function getIpProtocol() - { - return $this->ip_protocol; - } - - /** - * The IP protocol to which the external access rule applies. This value can - * be one of the following three protocol strings (not case-sensitive): - * `tcp`, `udp`, or `icmp`. - * - * Generated from protobuf field string ip_protocol = 8; - * @param string $var - * @return $this - */ - public function setIpProtocol($var) - { - GPBUtil::checkString($var, True); - $this->ip_protocol = $var; - - return $this; - } - - /** - * If source ranges are specified, the external access rule applies only to - * traffic that has a source IP address in these ranges. These ranges can - * either be expressed in the CIDR format or as an IP address. As only inbound - * rules are supported, `ExternalAddress` resources cannot be the source IP - * addresses of an external access rule. To match all source addresses, - * specify `0.0.0.0/0`. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.ExternalAccessRule.IpRange source_ip_ranges = 9; - * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\ExternalAccessRule\IpRange> - */ - public function getSourceIpRanges() - { - return $this->source_ip_ranges; - } - - /** - * If source ranges are specified, the external access rule applies only to - * traffic that has a source IP address in these ranges. These ranges can - * either be expressed in the CIDR format or as an IP address. As only inbound - * rules are supported, `ExternalAddress` resources cannot be the source IP - * addresses of an external access rule. To match all source addresses, - * specify `0.0.0.0/0`. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.ExternalAccessRule.IpRange source_ip_ranges = 9; - * @param \Google\Cloud\VmwareEngine\V1\ExternalAccessRule\IpRange[] $var - * @return $this - */ - public function setSourceIpRanges($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\ExternalAccessRule\IpRange::class); - $this->source_ip_ranges = $arr; - - return $this; - } - - /** - * A list of source ports to which the external access rule applies. This - * field is only applicable for the UDP or TCP protocol. - * Each entry must be either an integer or a range. For example: `["22"]`, - * `["80","443"]`, or `["12345-12349"]`. To match all source ports, specify - * `["0-65535"]`. - * - * Generated from protobuf field repeated string source_ports = 10; - * @return RepeatedField - */ - public function getSourcePorts() - { - return $this->source_ports; - } - - /** - * A list of source ports to which the external access rule applies. This - * field is only applicable for the UDP or TCP protocol. - * Each entry must be either an integer or a range. For example: `["22"]`, - * `["80","443"]`, or `["12345-12349"]`. To match all source ports, specify - * `["0-65535"]`. - * - * Generated from protobuf field repeated string source_ports = 10; - * @param string[] $var - * @return $this - */ - public function setSourcePorts($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->source_ports = $arr; - - return $this; - } - - /** - * If destination ranges are specified, the external access rule applies only - * to the traffic that has a destination IP address in these ranges. The - * specified IP addresses must have reserved external IP addresses in the - * scope of the parent network policy. To match all external IP addresses in - * the scope of the parent network policy, specify `0.0.0.0/0`. To match a - * specific external IP address, specify it using the - * `IpRange.external_address` property. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.ExternalAccessRule.IpRange destination_ip_ranges = 11; - * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\ExternalAccessRule\IpRange> - */ - public function getDestinationIpRanges() - { - return $this->destination_ip_ranges; - } - - /** - * If destination ranges are specified, the external access rule applies only - * to the traffic that has a destination IP address in these ranges. The - * specified IP addresses must have reserved external IP addresses in the - * scope of the parent network policy. To match all external IP addresses in - * the scope of the parent network policy, specify `0.0.0.0/0`. To match a - * specific external IP address, specify it using the - * `IpRange.external_address` property. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.ExternalAccessRule.IpRange destination_ip_ranges = 11; - * @param \Google\Cloud\VmwareEngine\V1\ExternalAccessRule\IpRange[] $var - * @return $this - */ - public function setDestinationIpRanges($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\ExternalAccessRule\IpRange::class); - $this->destination_ip_ranges = $arr; - - return $this; - } - - /** - * A list of destination ports to which the external access rule applies. This - * field is only applicable for the UDP or TCP protocol. - * Each entry must be either an integer or a range. For example: `["22"]`, - * `["80","443"]`, or `["12345-12349"]`. To match all destination ports, - * specify `["0-65535"]`. - * - * Generated from protobuf field repeated string destination_ports = 12; - * @return RepeatedField - */ - public function getDestinationPorts() - { - return $this->destination_ports; - } - - /** - * A list of destination ports to which the external access rule applies. This - * field is only applicable for the UDP or TCP protocol. - * Each entry must be either an integer or a range. For example: `["22"]`, - * `["80","443"]`, or `["12345-12349"]`. To match all destination ports, - * specify `["0-65535"]`. - * - * Generated from protobuf field repeated string destination_ports = 12; - * @param string[] $var - * @return $this - */ - public function setDestinationPorts($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->destination_ports = $arr; - - return $this; - } - - /** - * Output only. The state of the resource. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.ExternalAccessRule.State state = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Output only. The state of the resource. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.ExternalAccessRule.State state = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\ExternalAccessRule\State::class); - $this->state = $var; - - return $this; - } - - /** - * Output only. System-generated unique identifier for the resource. - * - * Generated from protobuf field string uid = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getUid() - { - return $this->uid; - } - - /** - * Output only. System-generated unique identifier for the resource. - * - * Generated from protobuf field string uid = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setUid($var) - { - GPBUtil::checkString($var, True); - $this->uid = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAccessRule/Action.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAccessRule/Action.php deleted file mode 100644 index 5334d921d686..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAccessRule/Action.php +++ /dev/null @@ -1,62 +0,0 @@ -google.cloud.vmwareengine.v1.ExternalAccessRule.Action - */ -class Action -{ - /** - * Defaults to allow. - * - * Generated from protobuf enum ACTION_UNSPECIFIED = 0; - */ - const ACTION_UNSPECIFIED = 0; - /** - * Allows connections that match the other specified components. - * - * Generated from protobuf enum ALLOW = 1; - */ - const ALLOW = 1; - /** - * Blocks connections that match the other specified components. - * - * Generated from protobuf enum DENY = 2; - */ - const DENY = 2; - - private static $valueToName = [ - self::ACTION_UNSPECIFIED => 'ACTION_UNSPECIFIED', - self::ALLOW => 'ALLOW', - self::DENY => 'DENY', - ]; - - 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAccessRule/IpRange.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAccessRule/IpRange.php deleted file mode 100644 index 44ef1af0a579..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAccessRule/IpRange.php +++ /dev/null @@ -1,156 +0,0 @@ -google.cloud.vmwareengine.v1.ExternalAccessRule.IpRange - */ -class IpRange extends \Google\Protobuf\Internal\Message -{ - protected $ip_range; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $ip_address - * A single IP address. For example: `10.0.0.5`. - * @type string $ip_address_range - * An IP address range in the CIDR format. For example: `10.0.0.0/24`. - * @type string $external_address - * The name of an `ExternalAddress` resource. The external address must - * have been reserved in the scope of this external access rule's parent - * network policy. Provide the external address name in the form of - * `projects/{project}/locations/{location}/privateClouds/{private_cloud}/externalAddresses/{external_address}`. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/externalAddresses/my-address`. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); - parent::__construct($data); - } - - /** - * A single IP address. For example: `10.0.0.5`. - * - * Generated from protobuf field string ip_address = 1; - * @return string - */ - public function getIpAddress() - { - return $this->readOneof(1); - } - - public function hasIpAddress() - { - return $this->hasOneof(1); - } - - /** - * A single IP address. For example: `10.0.0.5`. - * - * Generated from protobuf field string ip_address = 1; - * @param string $var - * @return $this - */ - public function setIpAddress($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * An IP address range in the CIDR format. For example: `10.0.0.0/24`. - * - * Generated from protobuf field string ip_address_range = 2; - * @return string - */ - public function getIpAddressRange() - { - return $this->readOneof(2); - } - - public function hasIpAddressRange() - { - return $this->hasOneof(2); - } - - /** - * An IP address range in the CIDR format. For example: `10.0.0.0/24`. - * - * Generated from protobuf field string ip_address_range = 2; - * @param string $var - * @return $this - */ - public function setIpAddressRange($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * The name of an `ExternalAddress` resource. The external address must - * have been reserved in the scope of this external access rule's parent - * network policy. Provide the external address name in the form of - * `projects/{project}/locations/{location}/privateClouds/{private_cloud}/externalAddresses/{external_address}`. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/externalAddresses/my-address`. - * - * Generated from protobuf field string external_address = 3 [(.google.api.resource_reference) = { - * @return string - */ - public function getExternalAddress() - { - return $this->readOneof(3); - } - - public function hasExternalAddress() - { - return $this->hasOneof(3); - } - - /** - * The name of an `ExternalAddress` resource. The external address must - * have been reserved in the scope of this external access rule's parent - * network policy. Provide the external address name in the form of - * `projects/{project}/locations/{location}/privateClouds/{private_cloud}/externalAddresses/{external_address}`. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/externalAddresses/my-address`. - * - * Generated from protobuf field string external_address = 3 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setExternalAddress($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(3, $var); - - return $this; - } - - /** - * @return string - */ - public function getIpRange() - { - return $this->whichOneof("ip_range"); - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAccessRule/State.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAccessRule/State.php deleted file mode 100644 index 1b8614cc51df..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAccessRule/State.php +++ /dev/null @@ -1,75 +0,0 @@ -google.cloud.vmwareengine.v1.ExternalAccessRule.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 rule is ready. - * - * Generated from protobuf enum ACTIVE = 1; - */ - const ACTIVE = 1; - /** - * The rule is being created. - * - * Generated from protobuf enum CREATING = 2; - */ - const CREATING = 2; - /** - * The rule is being updated. - * - * Generated from protobuf enum UPDATING = 3; - */ - const UPDATING = 3; - /** - * The rule is being deleted. - * - * Generated from protobuf enum DELETING = 4; - */ - const DELETING = 4; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::ACTIVE => 'ACTIVE', - self::CREATING => 'CREATING', - self::UPDATING => 'UPDATING', - 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); - } -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAddress.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAddress.php deleted file mode 100644 index 2cc27215b61e..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAddress.php +++ /dev/null @@ -1,342 +0,0 @@ -google.cloud.vmwareengine.v1.ExternalAddress - */ -class ExternalAddress extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The resource name of this external IP address. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/externalAddresses/my-address` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * Output only. Creation time of this resource. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. Last update time of this resource. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * The internal IP address of a workload VM. - * - * Generated from protobuf field string internal_ip = 6; - */ - protected $internal_ip = ''; - /** - * Output only. The external IP address of a workload VM. - * - * Generated from protobuf field string external_ip = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $external_ip = ''; - /** - * Output only. The state of the resource. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.ExternalAddress.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = 0; - /** - * Output only. System-generated unique identifier for the resource. - * - * Generated from protobuf field string uid = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $uid = ''; - /** - * User-provided description for this resource. - * - * Generated from protobuf field string description = 11; - */ - protected $description = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. The resource name of this external IP address. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/externalAddresses/my-address` - * @type \Google\Protobuf\Timestamp $create_time - * Output only. Creation time of this resource. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. Last update time of this resource. - * @type string $internal_ip - * The internal IP address of a workload VM. - * @type string $external_ip - * Output only. The external IP address of a workload VM. - * @type int $state - * Output only. The state of the resource. - * @type string $uid - * Output only. System-generated unique identifier for the resource. - * @type string $description - * User-provided description for this resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The resource name of this external IP address. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/externalAddresses/my-address` - * - * 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 external IP address. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/externalAddresses/my-address` - * - * 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. Creation time of this resource. - * - * 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 time of this resource. - * - * 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 time of this resource. - * - * 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 time of this resource. - * - * 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 internal IP address of a workload VM. - * - * Generated from protobuf field string internal_ip = 6; - * @return string - */ - public function getInternalIp() - { - return $this->internal_ip; - } - - /** - * The internal IP address of a workload VM. - * - * Generated from protobuf field string internal_ip = 6; - * @param string $var - * @return $this - */ - public function setInternalIp($var) - { - GPBUtil::checkString($var, True); - $this->internal_ip = $var; - - return $this; - } - - /** - * Output only. The external IP address of a workload VM. - * - * Generated from protobuf field string external_ip = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getExternalIp() - { - return $this->external_ip; - } - - /** - * Output only. The external IP address of a workload VM. - * - * Generated from protobuf field string external_ip = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setExternalIp($var) - { - GPBUtil::checkString($var, True); - $this->external_ip = $var; - - return $this; - } - - /** - * Output only. The state of the resource. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.ExternalAddress.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Output only. The state of the resource. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.ExternalAddress.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\ExternalAddress\State::class); - $this->state = $var; - - return $this; - } - - /** - * Output only. System-generated unique identifier for the resource. - * - * Generated from protobuf field string uid = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getUid() - { - return $this->uid; - } - - /** - * Output only. System-generated unique identifier for the resource. - * - * Generated from protobuf field string uid = 9 [(.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-provided description for this resource. - * - * Generated from protobuf field string description = 11; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * User-provided description for this resource. - * - * Generated from protobuf field string description = 11; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAddress/State.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAddress/State.php deleted file mode 100644 index 808ba3a62c3e..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ExternalAddress/State.php +++ /dev/null @@ -1,75 +0,0 @@ -google.cloud.vmwareengine.v1.ExternalAddress.State - */ -class State -{ - /** - * The default value. This value should never be used. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * The address is ready. - * - * Generated from protobuf enum ACTIVE = 1; - */ - const ACTIVE = 1; - /** - * The address is being created. - * - * Generated from protobuf enum CREATING = 2; - */ - const CREATING = 2; - /** - * The address is being updated. - * - * Generated from protobuf enum UPDATING = 3; - */ - const UPDATING = 3; - /** - * The address is being deleted. - * - * Generated from protobuf enum DELETING = 4; - */ - const DELETING = 4; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::ACTIVE => 'ACTIVE', - self::CREATING => 'CREATING', - self::UPDATING => 'UPDATING', - 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); - } -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/FetchNetworkPolicyExternalAddressesRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/FetchNetworkPolicyExternalAddressesRequest.php deleted file mode 100644 index c8a6ce1fc904..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/FetchNetworkPolicyExternalAddressesRequest.php +++ /dev/null @@ -1,202 +0,0 @@ -google.cloud.vmwareengine.v1.FetchNetworkPolicyExternalAddressesRequest - */ -class FetchNetworkPolicyExternalAddressesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the network policy to query for assigned - * external IP addresses. Resource names are schemeless URIs that follow the - * conventions in https://cloud.google.com/apis/design/resource_names. For - * example: - * `projects/my-project/locations/us-central1/networkPolicies/my-policy` - * - * Generated from protobuf field string network_policy = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $network_policy = ''; - /** - * The maximum number of external IP addresses to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * A page token, received from a previous - * `FetchNetworkPolicyExternalAddresses` call. Provide this to retrieve the - * subsequent page. - * When paginating, all parameters provided to - * `FetchNetworkPolicyExternalAddresses`, except for `page_size` and - * `page_token`, must match the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - - /** - * @param string $networkPolicy Required. The resource name of the network policy to query for assigned - * external IP addresses. Resource names are schemeless URIs that follow the - * conventions in https://cloud.google.com/apis/design/resource_names. For - * example: - * `projects/my-project/locations/us-central1/networkPolicies/my-policy` - * Please see {@see VmwareEngineClient::networkPolicyName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\FetchNetworkPolicyExternalAddressesRequest - * - * @experimental - */ - public static function build(string $networkPolicy): self - { - return (new self()) - ->setNetworkPolicy($networkPolicy); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $network_policy - * Required. The resource name of the network policy to query for assigned - * external IP addresses. Resource names are schemeless URIs that follow the - * conventions in https://cloud.google.com/apis/design/resource_names. For - * example: - * `projects/my-project/locations/us-central1/networkPolicies/my-policy` - * @type int $page_size - * The maximum number of external IP addresses to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * @type string $page_token - * A page token, received from a previous - * `FetchNetworkPolicyExternalAddresses` call. Provide this to retrieve the - * subsequent page. - * When paginating, all parameters provided to - * `FetchNetworkPolicyExternalAddresses`, except for `page_size` and - * `page_token`, must match the call that provided the page token. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the network policy to query for assigned - * external IP addresses. Resource names are schemeless URIs that follow the - * conventions in https://cloud.google.com/apis/design/resource_names. For - * example: - * `projects/my-project/locations/us-central1/networkPolicies/my-policy` - * - * Generated from protobuf field string network_policy = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getNetworkPolicy() - { - return $this->network_policy; - } - - /** - * Required. The resource name of the network policy to query for assigned - * external IP addresses. Resource names are schemeless URIs that follow the - * conventions in https://cloud.google.com/apis/design/resource_names. For - * example: - * `projects/my-project/locations/us-central1/networkPolicies/my-policy` - * - * Generated from protobuf field string network_policy = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setNetworkPolicy($var) - { - GPBUtil::checkString($var, True); - $this->network_policy = $var; - - return $this; - } - - /** - * The maximum number of external IP addresses to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of external IP addresses to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * 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 - * `FetchNetworkPolicyExternalAddresses` call. Provide this to retrieve the - * subsequent page. - * When paginating, all parameters provided to - * `FetchNetworkPolicyExternalAddresses`, except for `page_size` and - * `page_token`, 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 - * `FetchNetworkPolicyExternalAddresses` call. Provide this to retrieve the - * subsequent page. - * When paginating, all parameters provided to - * `FetchNetworkPolicyExternalAddresses`, except for `page_size` and - * `page_token`, 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; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/FetchNetworkPolicyExternalAddressesResponse.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/FetchNetworkPolicyExternalAddressesResponse.php deleted file mode 100644 index 0ded235008ed..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/FetchNetworkPolicyExternalAddressesResponse.php +++ /dev/null @@ -1,110 +0,0 @@ -google.cloud.vmwareengine.v1.FetchNetworkPolicyExternalAddressesResponse - */ -class FetchNetworkPolicyExternalAddressesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * A list of external IP addresses assigned to VMware workload VMs within the - * scope of the given network policy. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.ExternalAddress external_addresses = 1; - */ - private $external_addresses; - /** - * 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 \Google\Cloud\VmwareEngine\V1\ExternalAddress[] $external_addresses - * A list of external IP addresses assigned to VMware workload VMs within the - * scope of the given network policy. - * @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\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * A list of external IP addresses assigned to VMware workload VMs within the - * scope of the given network policy. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.ExternalAddress external_addresses = 1; - * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\ExternalAddress> - */ - public function getExternalAddresses() - { - return $this->external_addresses; - } - - /** - * A list of external IP addresses assigned to VMware workload VMs within the - * scope of the given network policy. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.ExternalAddress external_addresses = 1; - * @param \Google\Cloud\VmwareEngine\V1\ExternalAddress[] $var - * @return $this - */ - public function setExternalAddresses($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\ExternalAddress::class); - $this->external_addresses = $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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetClusterRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetClusterRequest.php deleted file mode 100644 index 2215db732e3e..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetClusterRequest.php +++ /dev/null @@ -1,102 +0,0 @@ -google.cloud.vmwareengine.v1.GetClusterRequest - */ -class GetClusterRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The cluster resource name to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - - /** - * @param string $name Required. The cluster resource name to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster` - * Please see {@see VmwareEngineClient::clusterName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\GetClusterRequest - * - * @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 cluster resource name to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The cluster resource name to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster` - * - * 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 cluster resource name to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster` - * - * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetDnsBindPermissionRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetDnsBindPermissionRequest.php deleted file mode 100644 index de2977a08173..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetDnsBindPermissionRequest.php +++ /dev/null @@ -1,107 +0,0 @@ -google.cloud.vmwareengine.v1.GetDnsBindPermissionRequest - */ -class GetDnsBindPermissionRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the resource which stores the users/service accounts - * having the permission to bind to the corresponding intranet VPC of the - * consumer project. DnsBindPermission is a global resource. Resource names - * are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. For example: - * `projects/my-project/locations/global/dnsBindPermission` - * - * 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 resource which stores the users/service accounts - * having the permission to bind to the corresponding intranet VPC of the - * consumer project. DnsBindPermission is a global resource. Resource names - * are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. For example: - * `projects/my-project/locations/global/dnsBindPermission` - * Please see {@see VmwareEngineClient::dnsBindPermissionName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\GetDnsBindPermissionRequest - * - * @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 resource which stores the users/service accounts - * having the permission to bind to the corresponding intranet VPC of the - * consumer project. DnsBindPermission is a global resource. Resource names - * are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. For example: - * `projects/my-project/locations/global/dnsBindPermission` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the resource which stores the users/service accounts - * having the permission to bind to the corresponding intranet VPC of the - * consumer project. DnsBindPermission is a global resource. Resource names - * are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. For example: - * `projects/my-project/locations/global/dnsBindPermission` - * - * 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 resource which stores the users/service accounts - * having the permission to bind to the corresponding intranet VPC of the - * consumer project. DnsBindPermission is a global resource. Resource names - * are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. For example: - * `projects/my-project/locations/global/dnsBindPermission` - * - * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetDnsForwardingRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetDnsForwardingRequest.php deleted file mode 100644 index 8439208cddad..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetDnsForwardingRequest.php +++ /dev/null @@ -1,102 +0,0 @@ -google.cloud.vmwareengine.v1.GetDnsForwardingRequest - */ -class GetDnsForwardingRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of a `DnsForwarding` to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/dnsForwarding` - * - * 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 a `DnsForwarding` to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/dnsForwarding` - * Please see {@see VmwareEngineClient::dnsForwardingName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\GetDnsForwardingRequest - * - * @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 a `DnsForwarding` to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/dnsForwarding` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of a `DnsForwarding` to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/dnsForwarding` - * - * 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 a `DnsForwarding` to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/dnsForwarding` - * - * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetExternalAccessRuleRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetExternalAccessRuleRequest.php deleted file mode 100644 index 5df34dbd5f46..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetExternalAccessRuleRequest.php +++ /dev/null @@ -1,102 +0,0 @@ -google.cloud.vmwareengine.v1.GetExternalAccessRuleRequest - */ -class GetExternalAccessRuleRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the external access firewall rule to - * retrieve. Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/networkPolicies/my-policy/externalAccessRules/my-rule` - * - * 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 external access firewall rule to - * retrieve. Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/networkPolicies/my-policy/externalAccessRules/my-rule` - * Please see {@see VmwareEngineClient::externalAccessRuleName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\GetExternalAccessRuleRequest - * - * @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 external access firewall rule to - * retrieve. Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/networkPolicies/my-policy/externalAccessRules/my-rule` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the external access firewall rule to - * retrieve. Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/networkPolicies/my-policy/externalAccessRules/my-rule` - * - * 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 external access firewall rule to - * retrieve. Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/networkPolicies/my-policy/externalAccessRules/my-rule` - * - * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetExternalAddressRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetExternalAddressRequest.php deleted file mode 100644 index 0a03b77025bb..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetExternalAddressRequest.php +++ /dev/null @@ -1,102 +0,0 @@ -google.cloud.vmwareengine.v1.GetExternalAddressRequest - */ -class GetExternalAddressRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the external IP address to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/externalAddresses/my-ip` - * - * 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 external IP address to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/externalAddresses/my-ip` - * Please see {@see VmwareEngineClient::externalAddressName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\GetExternalAddressRequest - * - * @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 external IP address to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/externalAddresses/my-ip` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the external IP address to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/externalAddresses/my-ip` - * - * 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 external IP address to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/externalAddresses/my-ip` - * - * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetHcxActivationKeyRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetHcxActivationKeyRequest.php deleted file mode 100644 index 5ca1f84b8233..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetHcxActivationKeyRequest.php +++ /dev/null @@ -1,101 +0,0 @@ -google.cloud.vmwareengine.v1.GetHcxActivationKeyRequest - */ -class GetHcxActivationKeyRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the HCX activation key to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/privateClouds/my-cloud/hcxActivationKeys/my-key` - * - * 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 HCX activation key to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/privateClouds/my-cloud/hcxActivationKeys/my-key` - * Please see {@see VmwareEngineClient::hcxActivationKeyName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\GetHcxActivationKeyRequest - * - * @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 HCX activation key to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/privateClouds/my-cloud/hcxActivationKeys/my-key` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the HCX activation key to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/privateClouds/my-cloud/hcxActivationKeys/my-key` - * - * 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 HCX activation key to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/privateClouds/my-cloud/hcxActivationKeys/my-key` - * - * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetLoggingServerRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetLoggingServerRequest.php deleted file mode 100644 index 50f13b0de8a5..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetLoggingServerRequest.php +++ /dev/null @@ -1,102 +0,0 @@ -google.cloud.vmwareengine.v1.GetLoggingServerRequest - */ -class GetLoggingServerRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the Logging Server to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/loggingServers/my-logging-server` - * - * 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 Logging Server to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/loggingServers/my-logging-server` - * Please see {@see VmwareEngineClient::loggingServerName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\GetLoggingServerRequest - * - * @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 Logging Server to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/loggingServers/my-logging-server` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the Logging Server to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/loggingServers/my-logging-server` - * - * 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 Logging Server to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/loggingServers/my-logging-server` - * - * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetManagementDnsZoneBindingRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetManagementDnsZoneBindingRequest.php deleted file mode 100644 index c4be8a09029d..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetManagementDnsZoneBindingRequest.php +++ /dev/null @@ -1,102 +0,0 @@ -google.cloud.vmwareengine.v1.GetManagementDnsZoneBindingRequest - */ -class GetManagementDnsZoneBindingRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the management DNS zone binding to - * retrieve. Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/managementDnsZoneBindings/my-management-dns-zone-binding` - * - * 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 management DNS zone binding to - * retrieve. Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/managementDnsZoneBindings/my-management-dns-zone-binding` - * Please see {@see VmwareEngineClient::managementDnsZoneBindingName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\GetManagementDnsZoneBindingRequest - * - * @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 management DNS zone binding to - * retrieve. Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/managementDnsZoneBindings/my-management-dns-zone-binding` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the management DNS zone binding to - * retrieve. Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/managementDnsZoneBindings/my-management-dns-zone-binding` - * - * 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 management DNS zone binding to - * retrieve. Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/managementDnsZoneBindings/my-management-dns-zone-binding` - * - * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetNetworkPeeringRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetNetworkPeeringRequest.php deleted file mode 100644 index 0024412b3c9c..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetNetworkPeeringRequest.php +++ /dev/null @@ -1,102 +0,0 @@ -google.cloud.vmwareengine.v1.GetNetworkPeeringRequest - */ -class GetNetworkPeeringRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the network peering to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/global/networkPeerings/my-peering` - * - * 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 network peering to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/global/networkPeerings/my-peering` - * Please see {@see VmwareEngineClient::networkPeeringName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\GetNetworkPeeringRequest - * - * @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 network peering to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/global/networkPeerings/my-peering` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the network peering to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/global/networkPeerings/my-peering` - * - * 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 network peering to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/global/networkPeerings/my-peering` - * - * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetNetworkPolicyRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetNetworkPolicyRequest.php deleted file mode 100644 index 5d9ef4f3c147..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetNetworkPolicyRequest.php +++ /dev/null @@ -1,102 +0,0 @@ -google.cloud.vmwareengine.v1.GetNetworkPolicyRequest - */ -class GetNetworkPolicyRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the network policy to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/networkPolicies/my-network-policy` - * - * 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 network policy to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/networkPolicies/my-network-policy` - * Please see {@see VmwareEngineClient::networkPolicyName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\GetNetworkPolicyRequest - * - * @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 network policy to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/networkPolicies/my-network-policy` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the network policy to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/networkPolicies/my-network-policy` - * - * 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 network policy to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/networkPolicies/my-network-policy` - * - * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetNodeRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetNodeRequest.php deleted file mode 100644 index a44732cfde7c..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetNodeRequest.php +++ /dev/null @@ -1,92 +0,0 @@ -google.cloud.vmwareengine.v1.GetNodeRequest - */ -class GetNodeRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the node to retrieve. - * For example: - * `projects/{project}/locations/{location}/privateClouds/{private_cloud}/clusters/{cluster}/nodes/{node}` - * - * 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 node to retrieve. - * For example: - * `projects/{project}/locations/{location}/privateClouds/{private_cloud}/clusters/{cluster}/nodes/{node}` - * Please see {@see VmwareEngineClient::nodeName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\GetNodeRequest - * - * @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 node to retrieve. - * For example: - * `projects/{project}/locations/{location}/privateClouds/{private_cloud}/clusters/{cluster}/nodes/{node}` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the node to retrieve. - * For example: - * `projects/{project}/locations/{location}/privateClouds/{private_cloud}/clusters/{cluster}/nodes/{node}` - * - * 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 node to retrieve. - * For example: - * `projects/{project}/locations/{location}/privateClouds/{private_cloud}/clusters/{cluster}/nodes/{node}` - * - * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetNodeTypeRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetNodeTypeRequest.php deleted file mode 100644 index f50cf89a2e16..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetNodeTypeRequest.php +++ /dev/null @@ -1,102 +0,0 @@ -google.cloud.vmwareengine.v1.GetNodeTypeRequest - */ -class GetNodeTypeRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the node type to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-proj/locations/us-central1-a/nodeTypes/standard-72` - * - * 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 node type to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-proj/locations/us-central1-a/nodeTypes/standard-72` - * Please see {@see VmwareEngineClient::nodeTypeName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\GetNodeTypeRequest - * - * @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 node type to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-proj/locations/us-central1-a/nodeTypes/standard-72` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the node type to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-proj/locations/us-central1-a/nodeTypes/standard-72` - * - * 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 node type to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-proj/locations/us-central1-a/nodeTypes/standard-72` - * - * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetPrivateCloudRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetPrivateCloudRequest.php deleted file mode 100644 index dc71556ca70c..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetPrivateCloudRequest.php +++ /dev/null @@ -1,102 +0,0 @@ -google.cloud.vmwareengine.v1.GetPrivateCloudRequest - */ -class GetPrivateCloudRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the private cloud to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * 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 private cloud to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * Please see {@see VmwareEngineClient::privateCloudName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\GetPrivateCloudRequest - * - * @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 private cloud to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the private cloud to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * 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 private cloud to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetPrivateConnectionRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetPrivateConnectionRequest.php deleted file mode 100644 index 74cdaca7d052..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetPrivateConnectionRequest.php +++ /dev/null @@ -1,102 +0,0 @@ -google.cloud.vmwareengine.v1.GetPrivateConnectionRequest - */ -class GetPrivateConnectionRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the private connection to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/privateConnections/my-connection` - * - * 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 private connection to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/privateConnections/my-connection` - * Please see {@see VmwareEngineClient::privateConnectionName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\GetPrivateConnectionRequest - * - * @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 private connection to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/privateConnections/my-connection` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the private connection to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/privateConnections/my-connection` - * - * 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 private connection to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/privateConnections/my-connection` - * - * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetSubnetRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetSubnetRequest.php deleted file mode 100644 index 24616dbc5328..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetSubnetRequest.php +++ /dev/null @@ -1,102 +0,0 @@ -google.cloud.vmwareengine.v1.GetSubnetRequest - */ -class GetSubnetRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the subnet to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/subnets/my-subnet` - * - * 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 subnet to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/subnets/my-subnet` - * Please see {@see VmwareEngineClient::subnetName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\GetSubnetRequest - * - * @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 subnet to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/subnets/my-subnet` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the subnet to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/subnets/my-subnet` - * - * 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 subnet to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/subnets/my-subnet` - * - * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetVmwareEngineNetworkRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetVmwareEngineNetworkRequest.php deleted file mode 100644 index fe7249832e5e..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GetVmwareEngineNetworkRequest.php +++ /dev/null @@ -1,102 +0,0 @@ -google.cloud.vmwareengine.v1.GetVmwareEngineNetworkRequest - */ -class GetVmwareEngineNetworkRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the VMware Engine network to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/global/vmwareEngineNetworks/my-network` - * - * 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 VMware Engine network to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/global/vmwareEngineNetworks/my-network` - * Please see {@see VmwareEngineClient::vmwareEngineNetworkName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\GetVmwareEngineNetworkRequest - * - * @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 VMware Engine network to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/global/vmwareEngineNetworks/my-network` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the VMware Engine network to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/global/vmwareEngineNetworks/my-network` - * - * 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 VMware Engine network to retrieve. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/global/vmwareEngineNetworks/my-network` - * - * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GrantDnsBindPermissionRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GrantDnsBindPermissionRequest.php deleted file mode 100644 index 53afee6055af..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/GrantDnsBindPermissionRequest.php +++ /dev/null @@ -1,241 +0,0 @@ -google.cloud.vmwareengine.v1.GrantDnsBindPermissionRequest - */ -class GrantDnsBindPermissionRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the resource which stores the users/service accounts - * having the permission to bind to the corresponding intranet VPC of the - * consumer project. DnsBindPermission is a global resource. Resource names - * are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. For example: - * `projects/my-project/locations/global/dnsBindPermission` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Required. The consumer provided user/service account which needs to be - * granted permission to bind with the intranet VPC corresponding to the - * consumer project. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.Principal principal = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $principal = null; - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $request_id = ''; - - /** - * @param string $name Required. The name of the resource which stores the users/service accounts - * having the permission to bind to the corresponding intranet VPC of the - * consumer project. DnsBindPermission is a global resource. Resource names - * are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. For example: - * `projects/my-project/locations/global/dnsBindPermission` - * Please see {@see VmwareEngineClient::dnsBindPermissionName()} for help formatting this field. - * @param \Google\Cloud\VmwareEngine\V1\Principal $principal Required. The consumer provided user/service account which needs to be - * granted permission to bind with the intranet VPC corresponding to the - * consumer project. - * - * @return \Google\Cloud\VmwareEngine\V1\GrantDnsBindPermissionRequest - * - * @experimental - */ - public static function build(string $name, \Google\Cloud\VmwareEngine\V1\Principal $principal): self - { - return (new self()) - ->setName($name) - ->setPrincipal($principal); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the resource which stores the users/service accounts - * having the permission to bind to the corresponding intranet VPC of the - * consumer project. DnsBindPermission is a global resource. Resource names - * are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. For example: - * `projects/my-project/locations/global/dnsBindPermission` - * @type \Google\Cloud\VmwareEngine\V1\Principal $principal - * Required. The consumer provided user/service account which needs to be - * granted permission to bind with the intranet VPC corresponding to the - * consumer project. - * @type string $request_id - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the resource which stores the users/service accounts - * having the permission to bind to the corresponding intranet VPC of the - * consumer project. DnsBindPermission is a global resource. Resource names - * are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. For example: - * `projects/my-project/locations/global/dnsBindPermission` - * - * 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 resource which stores the users/service accounts - * having the permission to bind to the corresponding intranet VPC of the - * consumer project. DnsBindPermission is a global resource. Resource names - * are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. For example: - * `projects/my-project/locations/global/dnsBindPermission` - * - * 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 consumer provided user/service account which needs to be - * granted permission to bind with the intranet VPC corresponding to the - * consumer project. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.Principal principal = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\VmwareEngine\V1\Principal|null - */ - public function getPrincipal() - { - return $this->principal; - } - - public function hasPrincipal() - { - return isset($this->principal); - } - - public function clearPrincipal() - { - unset($this->principal); - } - - /** - * Required. The consumer provided user/service account which needs to be - * granted permission to bind with the intranet VPC corresponding to the - * consumer project. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.Principal principal = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\VmwareEngine\V1\Principal $var - * @return $this - */ - public function setPrincipal($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\Principal::class); - $this->principal = $var; - - return $this; - } - - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 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; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Hcx.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Hcx.php deleted file mode 100644 index 216f6bd75705..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Hcx.php +++ /dev/null @@ -1,169 +0,0 @@ -google.cloud.vmwareengine.v1.Hcx - */ -class Hcx extends \Google\Protobuf\Internal\Message -{ - /** - * Internal IP address of the appliance. - * - * Generated from protobuf field string internal_ip = 2; - */ - protected $internal_ip = ''; - /** - * Version of the appliance. - * - * Generated from protobuf field string version = 4; - */ - protected $version = ''; - /** - * Output only. The state of the appliance. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.Hcx.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = 0; - /** - * Fully qualified domain name of the appliance. - * - * Generated from protobuf field string fqdn = 6; - */ - protected $fqdn = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $internal_ip - * Internal IP address of the appliance. - * @type string $version - * Version of the appliance. - * @type int $state - * Output only. The state of the appliance. - * @type string $fqdn - * Fully qualified domain name of the appliance. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); - parent::__construct($data); - } - - /** - * Internal IP address of the appliance. - * - * Generated from protobuf field string internal_ip = 2; - * @return string - */ - public function getInternalIp() - { - return $this->internal_ip; - } - - /** - * Internal IP address of the appliance. - * - * Generated from protobuf field string internal_ip = 2; - * @param string $var - * @return $this - */ - public function setInternalIp($var) - { - GPBUtil::checkString($var, True); - $this->internal_ip = $var; - - return $this; - } - - /** - * Version of the appliance. - * - * Generated from protobuf field string version = 4; - * @return string - */ - public function getVersion() - { - return $this->version; - } - - /** - * Version of the appliance. - * - * Generated from protobuf field string version = 4; - * @param string $var - * @return $this - */ - public function setVersion($var) - { - GPBUtil::checkString($var, True); - $this->version = $var; - - return $this; - } - - /** - * Output only. The state of the appliance. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.Hcx.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Output only. The state of the appliance. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.Hcx.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\Hcx\State::class); - $this->state = $var; - - return $this; - } - - /** - * Fully qualified domain name of the appliance. - * - * Generated from protobuf field string fqdn = 6; - * @return string - */ - public function getFqdn() - { - return $this->fqdn; - } - - /** - * Fully qualified domain name of the appliance. - * - * Generated from protobuf field string fqdn = 6; - * @param string $var - * @return $this - */ - public function setFqdn($var) - { - GPBUtil::checkString($var, True); - $this->fqdn = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Hcx/State.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Hcx/State.php deleted file mode 100644 index 9d4ab1c43fcf..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Hcx/State.php +++ /dev/null @@ -1,68 +0,0 @@ -google.cloud.vmwareengine.v1.Hcx.State - */ -class State -{ - /** - * Unspecified appliance state. This is the default value. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * The appliance is operational and can be used. - * - * Generated from protobuf enum ACTIVE = 1; - */ - const ACTIVE = 1; - /** - * The appliance is being deployed. - * - * Generated from protobuf enum CREATING = 2; - */ - const CREATING = 2; - /** - * The appliance is being activated. - * - * Generated from protobuf enum ACTIVATING = 3; - */ - const ACTIVATING = 3; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::ACTIVE => 'ACTIVE', - self::CREATING => 'CREATING', - self::ACTIVATING => 'ACTIVATING', - ]; - - 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/HcxActivationKey.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/HcxActivationKey.php deleted file mode 100644 index 47e60f1b70d9..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/HcxActivationKey.php +++ /dev/null @@ -1,236 +0,0 @@ -google.cloud.vmwareengine.v1.HcxActivationKey - */ -class HcxActivationKey extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The resource name of this HcxActivationKey. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/privateClouds/my-cloud/hcxActivationKeys/my-key` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * Output only. Creation time of HCX activation key. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. State of HCX activation key. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.HcxActivationKey.State state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = 0; - /** - * Output only. HCX activation key. - * - * Generated from protobuf field string activation_key = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $activation_key = ''; - /** - * Output only. System-generated unique identifier for the resource. - * - * Generated from protobuf field string uid = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $uid = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. The resource name of this HcxActivationKey. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/privateClouds/my-cloud/hcxActivationKeys/my-key` - * @type \Google\Protobuf\Timestamp $create_time - * Output only. Creation time of HCX activation key. - * @type int $state - * Output only. State of HCX activation key. - * @type string $activation_key - * Output only. HCX activation key. - * @type string $uid - * Output only. System-generated unique identifier for the resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The resource name of this HcxActivationKey. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/privateClouds/my-cloud/hcxActivationKeys/my-key` - * - * 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 HcxActivationKey. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/privateClouds/my-cloud/hcxActivationKeys/my-key` - * - * 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. Creation time of HCX activation key. - * - * 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 time of HCX activation key. - * - * 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. State of HCX activation key. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.HcxActivationKey.State state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Output only. State of HCX activation key. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.HcxActivationKey.State state = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\HcxActivationKey\State::class); - $this->state = $var; - - return $this; - } - - /** - * Output only. HCX activation key. - * - * Generated from protobuf field string activation_key = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getActivationKey() - { - return $this->activation_key; - } - - /** - * Output only. HCX activation key. - * - * Generated from protobuf field string activation_key = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setActivationKey($var) - { - GPBUtil::checkString($var, True); - $this->activation_key = $var; - - return $this; - } - - /** - * Output only. System-generated unique identifier for the resource. - * - * Generated from protobuf field string uid = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getUid() - { - return $this->uid; - } - - /** - * Output only. System-generated unique identifier for the resource. - * - * 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; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/HcxActivationKey/State.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/HcxActivationKey/State.php deleted file mode 100644 index 78ed39482bb2..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/HcxActivationKey/State.php +++ /dev/null @@ -1,68 +0,0 @@ -google.cloud.vmwareengine.v1.HcxActivationKey.State - */ -class State -{ - /** - * Unspecified state. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * State of a newly generated activation key. - * - * Generated from protobuf enum AVAILABLE = 1; - */ - const AVAILABLE = 1; - /** - * State of key when it has been used to activate HCX appliance. - * - * Generated from protobuf enum CONSUMED = 2; - */ - const CONSUMED = 2; - /** - * State of key when it is being created. - * - * Generated from protobuf enum CREATING = 3; - */ - const CREATING = 3; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::AVAILABLE => 'AVAILABLE', - self::CONSUMED => 'CONSUMED', - self::CREATING => 'CREATING', - ]; - - 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListClustersRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListClustersRequest.php deleted file mode 100644 index 0436f6a8eefb..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListClustersRequest.php +++ /dev/null @@ -1,322 +0,0 @@ -google.cloud.vmwareengine.v1.ListClustersRequest - */ -class ListClustersRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the private cloud to query for clusters. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The maximum number of clusters to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * A page token, received from a previous `ListClusters` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListClusters` - * must match the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - /** - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "example-cluster") - * (nodeCount = "3") - * ``` - * By default, each expression is an `AND` expression. However, you can - * include `AND` and `OR` expressions explicitly. For example: - * ``` - * (name = "example-cluster-1") AND - * (createTime > "2021-04-12T08:15:10.40Z") OR - * (name = "example-cluster-2") - * ``` - * - * Generated from protobuf field string filter = 4; - */ - protected $filter = ''; - /** - * Sorts list results by a certain order. By default, returned results are - * ordered by `name` in ascending order. You can also sort results in - * descending order based on the `name` value using `orderBy="name desc"`. - * Currently, only ordering by `name` is supported. - * - * Generated from protobuf field string order_by = 5; - */ - protected $order_by = ''; - - /** - * @param string $parent Required. The resource name of the private cloud to query for clusters. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * Please see {@see VmwareEngineClient::privateCloudName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\ListClustersRequest - * - * @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 private cloud to query for clusters. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * @type int $page_size - * The maximum number of clusters to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * @type string $page_token - * A page token, received from a previous `ListClusters` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListClusters` - * must match the call that provided the page token. - * @type string $filter - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "example-cluster") - * (nodeCount = "3") - * ``` - * By default, each expression is an `AND` expression. However, you can - * include `AND` and `OR` expressions explicitly. For example: - * ``` - * (name = "example-cluster-1") AND - * (createTime > "2021-04-12T08:15:10.40Z") OR - * (name = "example-cluster-2") - * ``` - * @type string $order_by - * Sorts list results by a certain order. By default, returned results are - * ordered by `name` in ascending order. You can also sort results in - * descending order based on the `name` value using `orderBy="name desc"`. - * Currently, only ordering by `name` is supported. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the private cloud to query for clusters. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * 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 private cloud to query for clusters. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * 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 clusters to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of clusters to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * 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 `ListClusters` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListClusters` - * 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 `ListClusters` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListClusters` - * 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; - } - - /** - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "example-cluster") - * (nodeCount = "3") - * ``` - * By default, each expression is an `AND` expression. However, you can - * include `AND` and `OR` expressions explicitly. For example: - * ``` - * (name = "example-cluster-1") AND - * (createTime > "2021-04-12T08:15:10.40Z") OR - * (name = "example-cluster-2") - * ``` - * - * Generated from protobuf field string filter = 4; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "example-cluster") - * (nodeCount = "3") - * ``` - * By default, each expression is an `AND` expression. However, you can - * include `AND` and `OR` expressions explicitly. For example: - * ``` - * (name = "example-cluster-1") AND - * (createTime > "2021-04-12T08:15:10.40Z") OR - * (name = "example-cluster-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; - } - - /** - * Sorts list results by a certain order. By default, returned results are - * ordered by `name` in ascending order. You can also sort results in - * descending order based on the `name` value using `orderBy="name desc"`. - * Currently, only ordering by `name` is supported. - * - * Generated from protobuf field string order_by = 5; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * Sorts list results by a certain order. By default, returned results are - * ordered by `name` in ascending order. You can also sort results in - * descending order based on the `name` value using `orderBy="name desc"`. - * Currently, only ordering by `name` is supported. - * - * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListClustersResponse.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListClustersResponse.php deleted file mode 100644 index 89c4a4a3bf5c..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListClustersResponse.php +++ /dev/null @@ -1,144 +0,0 @@ -google.cloud.vmwareengine.v1.ListClustersResponse - */ -class ListClustersResponse extends \Google\Protobuf\Internal\Message -{ - /** - * A list of private cloud clusters. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.Cluster clusters = 1; - */ - private $clusters; - /** - * 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 = ''; - /** - * Locations that could not be reached when making an aggregated query using - * wildcards. - * - * Generated from protobuf field repeated string unreachable = 3; - */ - private $unreachable; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\VmwareEngine\V1\Cluster[] $clusters - * A list of private cloud clusters. - * @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. - * @type string[] $unreachable - * Locations that could not be reached when making an aggregated query using - * wildcards. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * A list of private cloud clusters. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.Cluster clusters = 1; - * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\Cluster> - */ - public function getClusters() - { - return $this->clusters; - } - - /** - * A list of private cloud clusters. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.Cluster clusters = 1; - * @param \Google\Cloud\VmwareEngine\V1\Cluster[] $var - * @return $this - */ - public function setClusters($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\Cluster::class); - $this->clusters = $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; - } - - /** - * Locations that could not be reached when making an aggregated query using - * wildcards. - * - * Generated from protobuf field repeated string unreachable = 3; - * @return RepeatedField - */ - public function getUnreachable() - { - return $this->unreachable; - } - - /** - * Locations that could not be reached when making an aggregated query using - * wildcards. - * - * Generated from protobuf field repeated string unreachable = 3; - * @param string[] $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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListExternalAccessRulesRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListExternalAccessRulesRequest.php deleted file mode 100644 index 8604d8f65081..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListExternalAccessRulesRequest.php +++ /dev/null @@ -1,366 +0,0 @@ -google.cloud.vmwareengine.v1.ListExternalAccessRulesRequest - */ -class ListExternalAccessRulesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the network policy to query for external - * access firewall rules. Resource names are schemeless URIs that follow the - * conventions in https://cloud.google.com/apis/design/resource_names. For - * example: - * `projects/my-project/locations/us-central1/networkPolicies/my-policy` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The maximum number of external access rules to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * A page token, received from a previous `ListExternalAccessRulesRequest` - * call. Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListExternalAccessRulesRequest` must match the call that provided the page - * token. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - /** - * A filter expression that matches resources returned in the response. - * The expression must specify the field name, a comparison - * operator, and the value that you want to use for filtering. The value - * must be a string, a number, or a boolean. The comparison operator - * must be `=`, `!=`, `>`, or `<`. - * For example, if you are filtering a list of external access rules, you can - * exclude the ones named `example-rule` by specifying - * `name != "example-rule"`. - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "example-rule") - * (createTime > "2021-04-12T08:15:10.40Z") - * ``` - * By default, each expression is an `AND` expression. However, you - * can include `AND` and `OR` expressions explicitly. - * For example: - * ``` - * (name = "example-rule-1") AND - * (createTime > "2021-04-12T08:15:10.40Z") OR - * (name = "example-rule-2") - * ``` - * - * Generated from protobuf field string filter = 4; - */ - protected $filter = ''; - /** - * Sorts list results by a certain order. By default, returned results - * are ordered by `name` in ascending order. - * You can also sort results in descending order based on the `name` value - * using `orderBy="name desc"`. - * Currently, only ordering by `name` is supported. - * - * Generated from protobuf field string order_by = 5; - */ - protected $order_by = ''; - - /** - * @param string $parent Required. The resource name of the network policy to query for external - * access firewall rules. Resource names are schemeless URIs that follow the - * conventions in https://cloud.google.com/apis/design/resource_names. For - * example: - * `projects/my-project/locations/us-central1/networkPolicies/my-policy` - * Please see {@see VmwareEngineClient::networkPolicyName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\ListExternalAccessRulesRequest - * - * @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 network policy to query for external - * access firewall rules. Resource names are schemeless URIs that follow the - * conventions in https://cloud.google.com/apis/design/resource_names. For - * example: - * `projects/my-project/locations/us-central1/networkPolicies/my-policy` - * @type int $page_size - * The maximum number of external access rules to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * @type string $page_token - * A page token, received from a previous `ListExternalAccessRulesRequest` - * call. Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListExternalAccessRulesRequest` must match the call that provided the page - * token. - * @type string $filter - * A filter expression that matches resources returned in the response. - * The expression must specify the field name, a comparison - * operator, and the value that you want to use for filtering. The value - * must be a string, a number, or a boolean. The comparison operator - * must be `=`, `!=`, `>`, or `<`. - * For example, if you are filtering a list of external access rules, you can - * exclude the ones named `example-rule` by specifying - * `name != "example-rule"`. - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "example-rule") - * (createTime > "2021-04-12T08:15:10.40Z") - * ``` - * By default, each expression is an `AND` expression. However, you - * can include `AND` and `OR` expressions explicitly. - * For example: - * ``` - * (name = "example-rule-1") AND - * (createTime > "2021-04-12T08:15:10.40Z") OR - * (name = "example-rule-2") - * ``` - * @type string $order_by - * Sorts list results by a certain order. By default, returned results - * are ordered by `name` in ascending order. - * You can also sort results in descending order based on the `name` value - * using `orderBy="name desc"`. - * Currently, only ordering by `name` is supported. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the network policy to query for external - * access firewall rules. Resource names are schemeless URIs that follow the - * conventions in https://cloud.google.com/apis/design/resource_names. For - * example: - * `projects/my-project/locations/us-central1/networkPolicies/my-policy` - * - * 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 network policy to query for external - * access firewall rules. Resource names are schemeless URIs that follow the - * conventions in https://cloud.google.com/apis/design/resource_names. For - * example: - * `projects/my-project/locations/us-central1/networkPolicies/my-policy` - * - * 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 external access rules to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of external access rules to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * 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 `ListExternalAccessRulesRequest` - * call. Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListExternalAccessRulesRequest` 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 `ListExternalAccessRulesRequest` - * call. Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListExternalAccessRulesRequest` 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; - } - - /** - * A filter expression that matches resources returned in the response. - * The expression must specify the field name, a comparison - * operator, and the value that you want to use for filtering. The value - * must be a string, a number, or a boolean. The comparison operator - * must be `=`, `!=`, `>`, or `<`. - * For example, if you are filtering a list of external access rules, you can - * exclude the ones named `example-rule` by specifying - * `name != "example-rule"`. - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "example-rule") - * (createTime > "2021-04-12T08:15:10.40Z") - * ``` - * By default, each expression is an `AND` expression. However, you - * can include `AND` and `OR` expressions explicitly. - * For example: - * ``` - * (name = "example-rule-1") AND - * (createTime > "2021-04-12T08:15:10.40Z") OR - * (name = "example-rule-2") - * ``` - * - * Generated from protobuf field string filter = 4; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * A filter expression that matches resources returned in the response. - * The expression must specify the field name, a comparison - * operator, and the value that you want to use for filtering. The value - * must be a string, a number, or a boolean. The comparison operator - * must be `=`, `!=`, `>`, or `<`. - * For example, if you are filtering a list of external access rules, you can - * exclude the ones named `example-rule` by specifying - * `name != "example-rule"`. - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "example-rule") - * (createTime > "2021-04-12T08:15:10.40Z") - * ``` - * By default, each expression is an `AND` expression. However, you - * can include `AND` and `OR` expressions explicitly. - * For example: - * ``` - * (name = "example-rule-1") AND - * (createTime > "2021-04-12T08:15:10.40Z") OR - * (name = "example-rule-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; - } - - /** - * Sorts list results by a certain order. By default, returned results - * are ordered by `name` in ascending order. - * You can also sort results in descending order based on the `name` value - * using `orderBy="name desc"`. - * Currently, only ordering by `name` is supported. - * - * Generated from protobuf field string order_by = 5; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * Sorts list results by a certain order. By default, returned results - * are ordered by `name` in ascending order. - * You can also sort results in descending order based on the `name` value - * using `orderBy="name desc"`. - * Currently, only ordering by `name` is supported. - * - * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListExternalAccessRulesResponse.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListExternalAccessRulesResponse.php deleted file mode 100644 index 453140127c84..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListExternalAccessRulesResponse.php +++ /dev/null @@ -1,144 +0,0 @@ -google.cloud.vmwareengine.v1.ListExternalAccessRulesResponse - */ -class ListExternalAccessRulesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * A list of external access firewall rules. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.ExternalAccessRule external_access_rules = 1; - */ - private $external_access_rules; - /** - * 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 = ''; - /** - * Locations that could not be reached when making an aggregated query using - * wildcards. - * - * Generated from protobuf field repeated string unreachable = 3; - */ - private $unreachable; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\VmwareEngine\V1\ExternalAccessRule[] $external_access_rules - * A list of external access firewall rules. - * @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. - * @type string[] $unreachable - * Locations that could not be reached when making an aggregated query using - * wildcards. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * A list of external access firewall rules. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.ExternalAccessRule external_access_rules = 1; - * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\ExternalAccessRule> - */ - public function getExternalAccessRules() - { - return $this->external_access_rules; - } - - /** - * A list of external access firewall rules. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.ExternalAccessRule external_access_rules = 1; - * @param \Google\Cloud\VmwareEngine\V1\ExternalAccessRule[] $var - * @return $this - */ - public function setExternalAccessRules($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\ExternalAccessRule::class); - $this->external_access_rules = $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; - } - - /** - * Locations that could not be reached when making an aggregated query using - * wildcards. - * - * Generated from protobuf field repeated string unreachable = 3; - * @return RepeatedField - */ - public function getUnreachable() - { - return $this->unreachable; - } - - /** - * Locations that could not be reached when making an aggregated query using - * wildcards. - * - * Generated from protobuf field repeated string unreachable = 3; - * @param string[] $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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListExternalAddressesRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListExternalAddressesRequest.php deleted file mode 100644 index 830b551193b8..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListExternalAddressesRequest.php +++ /dev/null @@ -1,367 +0,0 @@ -google.cloud.vmwareengine.v1.ListExternalAddressesRequest - */ -class ListExternalAddressesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the private cloud to be queried for - * external IP addresses. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The maximum number of external IP addresses to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * A page token, received from a previous `ListExternalAddresses` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListExternalAddresses` must match the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - /** - * A filter expression that matches resources returned in the response. - * The expression must specify the field name, a comparison - * operator, and the value that you want to use for filtering. The value - * must be a string, a number, or a boolean. The comparison operator - * must be `=`, `!=`, `>`, or `<`. - * For example, if you are filtering a list of IP addresses, you can - * exclude the ones named `example-ip` by specifying - * `name != "example-ip"`. - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "example-ip") - * (createTime > "2021-04-12T08:15:10.40Z") - * ``` - * By default, each expression is an `AND` expression. However, you - * can include `AND` and `OR` expressions explicitly. - * For example: - * ``` - * (name = "example-ip-1") AND - * (createTime > "2021-04-12T08:15:10.40Z") OR - * (name = "example-ip-2") - * ``` - * - * Generated from protobuf field string filter = 4; - */ - protected $filter = ''; - /** - * Sorts list results by a certain order. By default, returned results - * are ordered by `name` in ascending order. - * You can also sort results in descending order based on the `name` value - * using `orderBy="name desc"`. - * Currently, only ordering by `name` is supported. - * - * Generated from protobuf field string order_by = 5; - */ - protected $order_by = ''; - - /** - * @param string $parent Required. The resource name of the private cloud to be queried for - * external IP addresses. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * Please see {@see VmwareEngineClient::privateCloudName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\ListExternalAddressesRequest - * - * @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 private cloud to be queried for - * external IP addresses. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * @type int $page_size - * The maximum number of external IP addresses to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * @type string $page_token - * A page token, received from a previous `ListExternalAddresses` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListExternalAddresses` must match the call that provided the page token. - * @type string $filter - * A filter expression that matches resources returned in the response. - * The expression must specify the field name, a comparison - * operator, and the value that you want to use for filtering. The value - * must be a string, a number, or a boolean. The comparison operator - * must be `=`, `!=`, `>`, or `<`. - * For example, if you are filtering a list of IP addresses, you can - * exclude the ones named `example-ip` by specifying - * `name != "example-ip"`. - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "example-ip") - * (createTime > "2021-04-12T08:15:10.40Z") - * ``` - * By default, each expression is an `AND` expression. However, you - * can include `AND` and `OR` expressions explicitly. - * For example: - * ``` - * (name = "example-ip-1") AND - * (createTime > "2021-04-12T08:15:10.40Z") OR - * (name = "example-ip-2") - * ``` - * @type string $order_by - * Sorts list results by a certain order. By default, returned results - * are ordered by `name` in ascending order. - * You can also sort results in descending order based on the `name` value - * using `orderBy="name desc"`. - * Currently, only ordering by `name` is supported. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the private cloud to be queried for - * external IP addresses. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * 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 private cloud to be queried for - * external IP addresses. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * 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 external IP addresses to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of external IP addresses to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * 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 `ListExternalAddresses` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListExternalAddresses` 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 `ListExternalAddresses` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListExternalAddresses` 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; - } - - /** - * A filter expression that matches resources returned in the response. - * The expression must specify the field name, a comparison - * operator, and the value that you want to use for filtering. The value - * must be a string, a number, or a boolean. The comparison operator - * must be `=`, `!=`, `>`, or `<`. - * For example, if you are filtering a list of IP addresses, you can - * exclude the ones named `example-ip` by specifying - * `name != "example-ip"`. - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "example-ip") - * (createTime > "2021-04-12T08:15:10.40Z") - * ``` - * By default, each expression is an `AND` expression. However, you - * can include `AND` and `OR` expressions explicitly. - * For example: - * ``` - * (name = "example-ip-1") AND - * (createTime > "2021-04-12T08:15:10.40Z") OR - * (name = "example-ip-2") - * ``` - * - * Generated from protobuf field string filter = 4; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * A filter expression that matches resources returned in the response. - * The expression must specify the field name, a comparison - * operator, and the value that you want to use for filtering. The value - * must be a string, a number, or a boolean. The comparison operator - * must be `=`, `!=`, `>`, or `<`. - * For example, if you are filtering a list of IP addresses, you can - * exclude the ones named `example-ip` by specifying - * `name != "example-ip"`. - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "example-ip") - * (createTime > "2021-04-12T08:15:10.40Z") - * ``` - * By default, each expression is an `AND` expression. However, you - * can include `AND` and `OR` expressions explicitly. - * For example: - * ``` - * (name = "example-ip-1") AND - * (createTime > "2021-04-12T08:15:10.40Z") OR - * (name = "example-ip-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; - } - - /** - * Sorts list results by a certain order. By default, returned results - * are ordered by `name` in ascending order. - * You can also sort results in descending order based on the `name` value - * using `orderBy="name desc"`. - * Currently, only ordering by `name` is supported. - * - * Generated from protobuf field string order_by = 5; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * Sorts list results by a certain order. By default, returned results - * are ordered by `name` in ascending order. - * You can also sort results in descending order based on the `name` value - * using `orderBy="name desc"`. - * Currently, only ordering by `name` is supported. - * - * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListExternalAddressesResponse.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListExternalAddressesResponse.php deleted file mode 100644 index d6c7fe19077a..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListExternalAddressesResponse.php +++ /dev/null @@ -1,144 +0,0 @@ -google.cloud.vmwareengine.v1.ListExternalAddressesResponse - */ -class ListExternalAddressesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * A list of external IP addresses. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.ExternalAddress external_addresses = 1; - */ - private $external_addresses; - /** - * 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 = ''; - /** - * Locations that could not be reached when making an aggregated query using - * wildcards. - * - * Generated from protobuf field repeated string unreachable = 3; - */ - private $unreachable; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\VmwareEngine\V1\ExternalAddress[] $external_addresses - * A list of external IP addresses. - * @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. - * @type string[] $unreachable - * Locations that could not be reached when making an aggregated query using - * wildcards. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * A list of external IP addresses. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.ExternalAddress external_addresses = 1; - * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\ExternalAddress> - */ - public function getExternalAddresses() - { - return $this->external_addresses; - } - - /** - * A list of external IP addresses. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.ExternalAddress external_addresses = 1; - * @param \Google\Cloud\VmwareEngine\V1\ExternalAddress[] $var - * @return $this - */ - public function setExternalAddresses($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\ExternalAddress::class); - $this->external_addresses = $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; - } - - /** - * Locations that could not be reached when making an aggregated query using - * wildcards. - * - * Generated from protobuf field repeated string unreachable = 3; - * @return RepeatedField - */ - public function getUnreachable() - { - return $this->unreachable; - } - - /** - * Locations that could not be reached when making an aggregated query using - * wildcards. - * - * Generated from protobuf field repeated string unreachable = 3; - * @param string[] $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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListHcxActivationKeysRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListHcxActivationKeysRequest.php deleted file mode 100644 index ba3606cd0322..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListHcxActivationKeysRequest.php +++ /dev/null @@ -1,203 +0,0 @@ -google.cloud.vmwareengine.v1.ListHcxActivationKeysRequest - */ -class ListHcxActivationKeysRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the private cloud - * to be queried for HCX activation keys. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/privateClouds/my-cloud` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The maximum number of HCX activation keys to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * A page token, received from a previous `ListHcxActivationKeys` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListHcxActivationKeys` must match the call that provided the page - * token. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - - /** - * @param string $parent Required. The resource name of the private cloud - * to be queried for HCX activation keys. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/privateClouds/my-cloud` - * Please see {@see VmwareEngineClient::privateCloudName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\ListHcxActivationKeysRequest - * - * @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 private cloud - * to be queried for HCX activation keys. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/privateClouds/my-cloud` - * @type int $page_size - * The maximum number of HCX activation keys to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * @type string $page_token - * A page token, received from a previous `ListHcxActivationKeys` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListHcxActivationKeys` must match the call that provided the page - * token. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the private cloud - * to be queried for HCX activation keys. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/privateClouds/my-cloud` - * - * 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 private cloud - * to be queried for HCX activation keys. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/privateClouds/my-cloud` - * - * 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 HCX activation keys to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of HCX activation keys to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * 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 `ListHcxActivationKeys` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListHcxActivationKeys` 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 `ListHcxActivationKeys` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListHcxActivationKeys` 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; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListHcxActivationKeysResponse.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListHcxActivationKeysResponse.php deleted file mode 100644 index 7078df13358a..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListHcxActivationKeysResponse.php +++ /dev/null @@ -1,144 +0,0 @@ -google.cloud.vmwareengine.v1.ListHcxActivationKeysResponse - */ -class ListHcxActivationKeysResponse extends \Google\Protobuf\Internal\Message -{ - /** - * List of HCX activation keys. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.HcxActivationKey hcx_activation_keys = 1; - */ - private $hcx_activation_keys; - /** - * 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 = ''; - /** - * Locations that could not be reached when making an aggregated query using - * wildcards. - * - * Generated from protobuf field repeated string unreachable = 3; - */ - private $unreachable; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\VmwareEngine\V1\HcxActivationKey[] $hcx_activation_keys - * List of HCX activation keys. - * @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. - * @type string[] $unreachable - * Locations that could not be reached when making an aggregated query using - * wildcards. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * List of HCX activation keys. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.HcxActivationKey hcx_activation_keys = 1; - * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\HcxActivationKey> - */ - public function getHcxActivationKeys() - { - return $this->hcx_activation_keys; - } - - /** - * List of HCX activation keys. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.HcxActivationKey hcx_activation_keys = 1; - * @param \Google\Cloud\VmwareEngine\V1\HcxActivationKey[] $var - * @return $this - */ - public function setHcxActivationKeys($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\HcxActivationKey::class); - $this->hcx_activation_keys = $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; - } - - /** - * Locations that could not be reached when making an aggregated query using - * wildcards. - * - * Generated from protobuf field repeated string unreachable = 3; - * @return RepeatedField - */ - public function getUnreachable() - { - return $this->unreachable; - } - - /** - * Locations that could not be reached when making an aggregated query using - * wildcards. - * - * Generated from protobuf field repeated string unreachable = 3; - * @param string[] $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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListLoggingServersRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListLoggingServersRequest.php deleted file mode 100644 index bf5489610ed1..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListLoggingServersRequest.php +++ /dev/null @@ -1,371 +0,0 @@ -google.cloud.vmwareengine.v1.ListLoggingServersRequest - */ -class ListLoggingServersRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the private cloud to be queried for - * logging servers. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The maximum number of logging servers to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * A page token, received from a previous `ListLoggingServersRequest` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListLoggingServersRequest` must match the call that provided the page - * token. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - /** - * A filter expression that matches resources returned in the response. - * The expression must specify the field name, a comparison - * operator, and the value that you want to use for filtering. The value - * must be a string, a number, or a boolean. The comparison operator - * must be `=`, `!=`, `>`, or `<`. - * For example, if you are filtering a list of logging servers, you can - * exclude the ones named `example-server` by specifying - * `name != "example-server"`. - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "example-server") - * (createTime > "2021-04-12T08:15:10.40Z") - * ``` - * By default, each expression is an `AND` expression. However, you - * can include `AND` and `OR` expressions explicitly. - * For example: - * ``` - * (name = "example-server-1") AND - * (createTime > "2021-04-12T08:15:10.40Z") OR - * (name = "example-server-2") - * ``` - * - * Generated from protobuf field string filter = 4; - */ - protected $filter = ''; - /** - * Sorts list results by a certain order. By default, returned results - * are ordered by `name` in ascending order. - * You can also sort results in descending order based on the `name` value - * using `orderBy="name desc"`. - * Currently, only ordering by `name` is supported. - * - * Generated from protobuf field string order_by = 5; - */ - protected $order_by = ''; - - /** - * @param string $parent Required. The resource name of the private cloud to be queried for - * logging servers. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * Please see {@see VmwareEngineClient::privateCloudName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\ListLoggingServersRequest - * - * @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 private cloud to be queried for - * logging servers. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * @type int $page_size - * The maximum number of logging servers to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * @type string $page_token - * A page token, received from a previous `ListLoggingServersRequest` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListLoggingServersRequest` must match the call that provided the page - * token. - * @type string $filter - * A filter expression that matches resources returned in the response. - * The expression must specify the field name, a comparison - * operator, and the value that you want to use for filtering. The value - * must be a string, a number, or a boolean. The comparison operator - * must be `=`, `!=`, `>`, or `<`. - * For example, if you are filtering a list of logging servers, you can - * exclude the ones named `example-server` by specifying - * `name != "example-server"`. - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "example-server") - * (createTime > "2021-04-12T08:15:10.40Z") - * ``` - * By default, each expression is an `AND` expression. However, you - * can include `AND` and `OR` expressions explicitly. - * For example: - * ``` - * (name = "example-server-1") AND - * (createTime > "2021-04-12T08:15:10.40Z") OR - * (name = "example-server-2") - * ``` - * @type string $order_by - * Sorts list results by a certain order. By default, returned results - * are ordered by `name` in ascending order. - * You can also sort results in descending order based on the `name` value - * using `orderBy="name desc"`. - * Currently, only ordering by `name` is supported. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the private cloud to be queried for - * logging servers. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * 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 private cloud to be queried for - * logging servers. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * 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 logging servers to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of logging servers to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * 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 `ListLoggingServersRequest` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListLoggingServersRequest` 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 `ListLoggingServersRequest` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListLoggingServersRequest` 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; - } - - /** - * A filter expression that matches resources returned in the response. - * The expression must specify the field name, a comparison - * operator, and the value that you want to use for filtering. The value - * must be a string, a number, or a boolean. The comparison operator - * must be `=`, `!=`, `>`, or `<`. - * For example, if you are filtering a list of logging servers, you can - * exclude the ones named `example-server` by specifying - * `name != "example-server"`. - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "example-server") - * (createTime > "2021-04-12T08:15:10.40Z") - * ``` - * By default, each expression is an `AND` expression. However, you - * can include `AND` and `OR` expressions explicitly. - * For example: - * ``` - * (name = "example-server-1") AND - * (createTime > "2021-04-12T08:15:10.40Z") OR - * (name = "example-server-2") - * ``` - * - * Generated from protobuf field string filter = 4; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * A filter expression that matches resources returned in the response. - * The expression must specify the field name, a comparison - * operator, and the value that you want to use for filtering. The value - * must be a string, a number, or a boolean. The comparison operator - * must be `=`, `!=`, `>`, or `<`. - * For example, if you are filtering a list of logging servers, you can - * exclude the ones named `example-server` by specifying - * `name != "example-server"`. - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "example-server") - * (createTime > "2021-04-12T08:15:10.40Z") - * ``` - * By default, each expression is an `AND` expression. However, you - * can include `AND` and `OR` expressions explicitly. - * For example: - * ``` - * (name = "example-server-1") AND - * (createTime > "2021-04-12T08:15:10.40Z") OR - * (name = "example-server-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; - } - - /** - * Sorts list results by a certain order. By default, returned results - * are ordered by `name` in ascending order. - * You can also sort results in descending order based on the `name` value - * using `orderBy="name desc"`. - * Currently, only ordering by `name` is supported. - * - * Generated from protobuf field string order_by = 5; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * Sorts list results by a certain order. By default, returned results - * are ordered by `name` in ascending order. - * You can also sort results in descending order based on the `name` value - * using `orderBy="name desc"`. - * Currently, only ordering by `name` is supported. - * - * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListLoggingServersResponse.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListLoggingServersResponse.php deleted file mode 100644 index bf033aea7733..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListLoggingServersResponse.php +++ /dev/null @@ -1,144 +0,0 @@ -google.cloud.vmwareengine.v1.ListLoggingServersResponse - */ -class ListLoggingServersResponse extends \Google\Protobuf\Internal\Message -{ - /** - * A list of Logging Servers. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.LoggingServer logging_servers = 1; - */ - private $logging_servers; - /** - * A token, which can be send 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 = ''; - /** - * Locations that could not be reached when making an aggregated query using - * wildcards. - * - * Generated from protobuf field repeated string unreachable = 3; - */ - private $unreachable; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\VmwareEngine\V1\LoggingServer[] $logging_servers - * A list of Logging Servers. - * @type string $next_page_token - * A token, which can be send as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * @type string[] $unreachable - * Locations that could not be reached when making an aggregated query using - * wildcards. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * A list of Logging Servers. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.LoggingServer logging_servers = 1; - * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\LoggingServer> - */ - public function getLoggingServers() - { - return $this->logging_servers; - } - - /** - * A list of Logging Servers. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.LoggingServer logging_servers = 1; - * @param \Google\Cloud\VmwareEngine\V1\LoggingServer[] $var - * @return $this - */ - public function setLoggingServers($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\LoggingServer::class); - $this->logging_servers = $arr; - - return $this; - } - - /** - * A token, which can be send 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 send 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; - } - - /** - * Locations that could not be reached when making an aggregated query using - * wildcards. - * - * Generated from protobuf field repeated string unreachable = 3; - * @return RepeatedField - */ - public function getUnreachable() - { - return $this->unreachable; - } - - /** - * Locations that could not be reached when making an aggregated query using - * wildcards. - * - * Generated from protobuf field repeated string unreachable = 3; - * @param string[] $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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListManagementDnsZoneBindingsRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListManagementDnsZoneBindingsRequest.php deleted file mode 100644 index e92925440d51..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListManagementDnsZoneBindingsRequest.php +++ /dev/null @@ -1,371 +0,0 @@ -google.cloud.vmwareengine.v1.ListManagementDnsZoneBindingsRequest - */ -class ListManagementDnsZoneBindingsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the private cloud to be queried for - * management DNS zone bindings. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The maximum number of management DNS zone bindings to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * A page token, received from a previous `ListManagementDnsZoneBindings` - * call. Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListManagementDnsZoneBindings` must match the call that provided the page - * token. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - /** - * A filter expression that matches resources returned in the response. - * The expression must specify the field name, a comparison - * operator, and the value that you want to use for filtering. The value - * must be a string, a number, or a boolean. The comparison operator - * must be `=`, `!=`, `>`, or `<`. - * For example, if you are filtering a list of Management DNS Zone Bindings, - * you can exclude the ones named `example-management-dns-zone-binding` by - * specifying `name != "example-management-dns-zone-binding"`. - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "example-management-dns-zone-binding") - * (createTime > "2021-04-12T08:15:10.40Z") - * ``` - * By default, each expression is an `AND` expression. However, you - * can include `AND` and `OR` expressions explicitly. - * For example: - * ``` - * (name = "example-management-dns-zone-binding-1") AND - * (createTime > "2021-04-12T08:15:10.40Z") OR - * (name = "example-management-dns-zone-binding-2") - * ``` - * - * Generated from protobuf field string filter = 4; - */ - protected $filter = ''; - /** - * Sorts list results by a certain order. By default, returned results - * are ordered by `name` in ascending order. - * You can also sort results in descending order based on the `name` value - * using `orderBy="name desc"`. - * Currently, only ordering by `name` is supported. - * - * Generated from protobuf field string order_by = 5; - */ - protected $order_by = ''; - - /** - * @param string $parent Required. The resource name of the private cloud to be queried for - * management DNS zone bindings. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * Please see {@see VmwareEngineClient::privateCloudName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\ListManagementDnsZoneBindingsRequest - * - * @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 private cloud to be queried for - * management DNS zone bindings. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * @type int $page_size - * The maximum number of management DNS zone bindings to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * @type string $page_token - * A page token, received from a previous `ListManagementDnsZoneBindings` - * call. Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListManagementDnsZoneBindings` must match the call that provided the page - * token. - * @type string $filter - * A filter expression that matches resources returned in the response. - * The expression must specify the field name, a comparison - * operator, and the value that you want to use for filtering. The value - * must be a string, a number, or a boolean. The comparison operator - * must be `=`, `!=`, `>`, or `<`. - * For example, if you are filtering a list of Management DNS Zone Bindings, - * you can exclude the ones named `example-management-dns-zone-binding` by - * specifying `name != "example-management-dns-zone-binding"`. - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "example-management-dns-zone-binding") - * (createTime > "2021-04-12T08:15:10.40Z") - * ``` - * By default, each expression is an `AND` expression. However, you - * can include `AND` and `OR` expressions explicitly. - * For example: - * ``` - * (name = "example-management-dns-zone-binding-1") AND - * (createTime > "2021-04-12T08:15:10.40Z") OR - * (name = "example-management-dns-zone-binding-2") - * ``` - * @type string $order_by - * Sorts list results by a certain order. By default, returned results - * are ordered by `name` in ascending order. - * You can also sort results in descending order based on the `name` value - * using `orderBy="name desc"`. - * Currently, only ordering by `name` is supported. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the private cloud to be queried for - * management DNS zone bindings. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * 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 private cloud to be queried for - * management DNS zone bindings. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * 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 management DNS zone bindings to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of management DNS zone bindings to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * 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 `ListManagementDnsZoneBindings` - * call. Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListManagementDnsZoneBindings` 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 `ListManagementDnsZoneBindings` - * call. Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListManagementDnsZoneBindings` 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; - } - - /** - * A filter expression that matches resources returned in the response. - * The expression must specify the field name, a comparison - * operator, and the value that you want to use for filtering. The value - * must be a string, a number, or a boolean. The comparison operator - * must be `=`, `!=`, `>`, or `<`. - * For example, if you are filtering a list of Management DNS Zone Bindings, - * you can exclude the ones named `example-management-dns-zone-binding` by - * specifying `name != "example-management-dns-zone-binding"`. - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "example-management-dns-zone-binding") - * (createTime > "2021-04-12T08:15:10.40Z") - * ``` - * By default, each expression is an `AND` expression. However, you - * can include `AND` and `OR` expressions explicitly. - * For example: - * ``` - * (name = "example-management-dns-zone-binding-1") AND - * (createTime > "2021-04-12T08:15:10.40Z") OR - * (name = "example-management-dns-zone-binding-2") - * ``` - * - * Generated from protobuf field string filter = 4; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * A filter expression that matches resources returned in the response. - * The expression must specify the field name, a comparison - * operator, and the value that you want to use for filtering. The value - * must be a string, a number, or a boolean. The comparison operator - * must be `=`, `!=`, `>`, or `<`. - * For example, if you are filtering a list of Management DNS Zone Bindings, - * you can exclude the ones named `example-management-dns-zone-binding` by - * specifying `name != "example-management-dns-zone-binding"`. - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "example-management-dns-zone-binding") - * (createTime > "2021-04-12T08:15:10.40Z") - * ``` - * By default, each expression is an `AND` expression. However, you - * can include `AND` and `OR` expressions explicitly. - * For example: - * ``` - * (name = "example-management-dns-zone-binding-1") AND - * (createTime > "2021-04-12T08:15:10.40Z") OR - * (name = "example-management-dns-zone-binding-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; - } - - /** - * Sorts list results by a certain order. By default, returned results - * are ordered by `name` in ascending order. - * You can also sort results in descending order based on the `name` value - * using `orderBy="name desc"`. - * Currently, only ordering by `name` is supported. - * - * Generated from protobuf field string order_by = 5; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * Sorts list results by a certain order. By default, returned results - * are ordered by `name` in ascending order. - * You can also sort results in descending order based on the `name` value - * using `orderBy="name desc"`. - * Currently, only ordering by `name` is supported. - * - * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListManagementDnsZoneBindingsResponse.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListManagementDnsZoneBindingsResponse.php deleted file mode 100644 index 286b729b0c0a..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListManagementDnsZoneBindingsResponse.php +++ /dev/null @@ -1,144 +0,0 @@ -google.cloud.vmwareengine.v1.ListManagementDnsZoneBindingsResponse - */ -class ListManagementDnsZoneBindingsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * A list of management DNS zone bindings. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.ManagementDnsZoneBinding management_dns_zone_bindings = 1; - */ - private $management_dns_zone_bindings; - /** - * 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 = ''; - /** - * Locations that could not be reached when making an aggregated query using - * wildcards. - * - * Generated from protobuf field repeated string unreachable = 3; - */ - private $unreachable; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\VmwareEngine\V1\ManagementDnsZoneBinding[] $management_dns_zone_bindings - * A list of management DNS zone bindings. - * @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. - * @type string[] $unreachable - * Locations that could not be reached when making an aggregated query using - * wildcards. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * A list of management DNS zone bindings. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.ManagementDnsZoneBinding management_dns_zone_bindings = 1; - * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\ManagementDnsZoneBinding> - */ - public function getManagementDnsZoneBindings() - { - return $this->management_dns_zone_bindings; - } - - /** - * A list of management DNS zone bindings. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.ManagementDnsZoneBinding management_dns_zone_bindings = 1; - * @param \Google\Cloud\VmwareEngine\V1\ManagementDnsZoneBinding[] $var - * @return $this - */ - public function setManagementDnsZoneBindings($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\ManagementDnsZoneBinding::class); - $this->management_dns_zone_bindings = $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; - } - - /** - * Locations that could not be reached when making an aggregated query using - * wildcards. - * - * Generated from protobuf field repeated string unreachable = 3; - * @return RepeatedField - */ - public function getUnreachable() - { - return $this->unreachable; - } - - /** - * Locations that could not be reached when making an aggregated query using - * wildcards. - * - * Generated from protobuf field repeated string unreachable = 3; - * @param string[] $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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNetworkPeeringsRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNetworkPeeringsRequest.php deleted file mode 100644 index c032a2e8957f..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNetworkPeeringsRequest.php +++ /dev/null @@ -1,357 +0,0 @@ -google.cloud.vmwareengine.v1.ListNetworkPeeringsRequest - */ -class ListNetworkPeeringsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the location (global) to query for - * network peerings. Resource names are schemeless URIs that follow the - * conventions in https://cloud.google.com/apis/design/resource_names. For - * example: `projects/my-project/locations/global` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The maximum number of network peerings to return in one page. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * A page token, received from a previous `ListNetworkPeerings` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListNetworkPeerings` must match the call that provided the page - * token. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - /** - * A filter expression that matches resources returned in the response. - * The expression must specify the field name, a comparison - * operator, and the value that you want to use for filtering. The value - * must be a string, a number, or a boolean. The comparison operator - * must be `=`, `!=`, `>`, or `<`. - * For example, if you are filtering a list of network peerings, you can - * exclude the ones named `example-peering` by specifying - * `name != "example-peering"`. - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "example-peering") - * (createTime > "2021-04-12T08:15:10.40Z") - * ``` - * By default, each expression is an `AND` expression. However, you - * can include `AND` and `OR` expressions explicitly. - * For example: - * ``` - * (name = "example-peering-1") AND - * (createTime > "2021-04-12T08:15:10.40Z") OR - * (name = "example-peering-2") - * ``` - * - * Generated from protobuf field string filter = 4; - */ - protected $filter = ''; - /** - * Sorts list results by a certain order. By default, returned results - * are ordered by `name` in ascending order. - * You can also sort results in descending order based on the `name` value - * using `orderBy="name desc"`. - * Currently, only ordering by `name` is supported. - * - * Generated from protobuf field string order_by = 5; - */ - protected $order_by = ''; - - /** - * @param string $parent Required. The resource name of the location (global) to query for - * network peerings. Resource names are schemeless URIs that follow the - * conventions in https://cloud.google.com/apis/design/resource_names. For - * example: `projects/my-project/locations/global` - * Please see {@see VmwareEngineClient::locationName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\ListNetworkPeeringsRequest - * - * @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 location (global) to query for - * network peerings. Resource names are schemeless URIs that follow the - * conventions in https://cloud.google.com/apis/design/resource_names. For - * example: `projects/my-project/locations/global` - * @type int $page_size - * The maximum number of network peerings to return in one page. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * @type string $page_token - * A page token, received from a previous `ListNetworkPeerings` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListNetworkPeerings` must match the call that provided the page - * token. - * @type string $filter - * A filter expression that matches resources returned in the response. - * The expression must specify the field name, a comparison - * operator, and the value that you want to use for filtering. The value - * must be a string, a number, or a boolean. The comparison operator - * must be `=`, `!=`, `>`, or `<`. - * For example, if you are filtering a list of network peerings, you can - * exclude the ones named `example-peering` by specifying - * `name != "example-peering"`. - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "example-peering") - * (createTime > "2021-04-12T08:15:10.40Z") - * ``` - * By default, each expression is an `AND` expression. However, you - * can include `AND` and `OR` expressions explicitly. - * For example: - * ``` - * (name = "example-peering-1") AND - * (createTime > "2021-04-12T08:15:10.40Z") OR - * (name = "example-peering-2") - * ``` - * @type string $order_by - * Sorts list results by a certain order. By default, returned results - * are ordered by `name` in ascending order. - * You can also sort results in descending order based on the `name` value - * using `orderBy="name desc"`. - * Currently, only ordering by `name` is supported. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the location (global) to query for - * network peerings. Resource names are schemeless URIs that follow the - * conventions in https://cloud.google.com/apis/design/resource_names. For - * example: `projects/my-project/locations/global` - * - * 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 (global) to query for - * network peerings. Resource names are schemeless URIs that follow the - * conventions in https://cloud.google.com/apis/design/resource_names. For - * example: `projects/my-project/locations/global` - * - * 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 network peerings to return in one page. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of network peerings to return in one page. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * 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 `ListNetworkPeerings` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListNetworkPeerings` 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 `ListNetworkPeerings` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListNetworkPeerings` 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; - } - - /** - * A filter expression that matches resources returned in the response. - * The expression must specify the field name, a comparison - * operator, and the value that you want to use for filtering. The value - * must be a string, a number, or a boolean. The comparison operator - * must be `=`, `!=`, `>`, or `<`. - * For example, if you are filtering a list of network peerings, you can - * exclude the ones named `example-peering` by specifying - * `name != "example-peering"`. - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "example-peering") - * (createTime > "2021-04-12T08:15:10.40Z") - * ``` - * By default, each expression is an `AND` expression. However, you - * can include `AND` and `OR` expressions explicitly. - * For example: - * ``` - * (name = "example-peering-1") AND - * (createTime > "2021-04-12T08:15:10.40Z") OR - * (name = "example-peering-2") - * ``` - * - * Generated from protobuf field string filter = 4; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * A filter expression that matches resources returned in the response. - * The expression must specify the field name, a comparison - * operator, and the value that you want to use for filtering. The value - * must be a string, a number, or a boolean. The comparison operator - * must be `=`, `!=`, `>`, or `<`. - * For example, if you are filtering a list of network peerings, you can - * exclude the ones named `example-peering` by specifying - * `name != "example-peering"`. - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "example-peering") - * (createTime > "2021-04-12T08:15:10.40Z") - * ``` - * By default, each expression is an `AND` expression. However, you - * can include `AND` and `OR` expressions explicitly. - * For example: - * ``` - * (name = "example-peering-1") AND - * (createTime > "2021-04-12T08:15:10.40Z") OR - * (name = "example-peering-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; - } - - /** - * Sorts list results by a certain order. By default, returned results - * are ordered by `name` in ascending order. - * You can also sort results in descending order based on the `name` value - * using `orderBy="name desc"`. - * Currently, only ordering by `name` is supported. - * - * Generated from protobuf field string order_by = 5; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * Sorts list results by a certain order. By default, returned results - * are ordered by `name` in ascending order. - * You can also sort results in descending order based on the `name` value - * using `orderBy="name desc"`. - * Currently, only ordering by `name` is supported. - * - * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNetworkPeeringsResponse.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNetworkPeeringsResponse.php deleted file mode 100644 index 82cb3042c8e1..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNetworkPeeringsResponse.php +++ /dev/null @@ -1,140 +0,0 @@ -google.cloud.vmwareengine.v1.ListNetworkPeeringsResponse - */ -class ListNetworkPeeringsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * A list of network peerings. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.NetworkPeering network_peerings = 1; - */ - private $network_peerings; - /** - * 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 = ''; - /** - * Unreachable resources. - * - * Generated from protobuf field repeated string unreachable = 3; - */ - private $unreachable; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\VmwareEngine\V1\NetworkPeering[] $network_peerings - * A list of network peerings. - * @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. - * @type string[] $unreachable - * Unreachable resources. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * A list of network peerings. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.NetworkPeering network_peerings = 1; - * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\NetworkPeering> - */ - public function getNetworkPeerings() - { - return $this->network_peerings; - } - - /** - * A list of network peerings. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.NetworkPeering network_peerings = 1; - * @param \Google\Cloud\VmwareEngine\V1\NetworkPeering[] $var - * @return $this - */ - public function setNetworkPeerings($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\NetworkPeering::class); - $this->network_peerings = $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; - } - - /** - * Unreachable resources. - * - * Generated from protobuf field repeated string unreachable = 3; - * @return RepeatedField - */ - public function getUnreachable() - { - return $this->unreachable; - } - - /** - * Unreachable resources. - * - * Generated from protobuf field repeated string unreachable = 3; - * @param string[] $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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNetworkPoliciesRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNetworkPoliciesRequest.php deleted file mode 100644 index 45396e12ff7a..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNetworkPoliciesRequest.php +++ /dev/null @@ -1,361 +0,0 @@ -google.cloud.vmwareengine.v1.ListNetworkPoliciesRequest - */ -class ListNetworkPoliciesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the location (region) to query for - * network policies. Resource names are schemeless URIs that follow the - * conventions in https://cloud.google.com/apis/design/resource_names. For - * example: `projects/my-project/locations/us-central1` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The maximum number of network policies to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * A page token, received from a previous `ListNetworkPolicies` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListNetworkPolicies` must match the call that provided the page - * token. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - /** - * A filter expression that matches resources returned in the response. - * The expression must specify the field name, a comparison - * operator, and the value that you want to use for filtering. The value - * must be a string, a number, or a boolean. The comparison operator - * must be `=`, `!=`, `>`, or `<`. - * For example, if you are filtering a list of network policies, you can - * exclude the ones named `example-policy` by specifying - * `name != "example-policy"`. - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "example-policy") - * (createTime > "2021-04-12T08:15:10.40Z") - * ``` - * By default, each expression is an `AND` expression. However, you - * can include `AND` and `OR` expressions explicitly. - * For example: - * ``` - * (name = "example-policy-1") AND - * (createTime > "2021-04-12T08:15:10.40Z") OR - * (name = "example-policy-2") - * ``` - * - * Generated from protobuf field string filter = 4; - */ - protected $filter = ''; - /** - * Sorts list results by a certain order. By default, returned results - * are ordered by `name` in ascending order. - * You can also sort results in descending order based on the `name` value - * using `orderBy="name desc"`. - * Currently, only ordering by `name` is supported. - * - * Generated from protobuf field string order_by = 5; - */ - protected $order_by = ''; - - /** - * @param string $parent Required. The resource name of the location (region) to query for - * network policies. Resource names are schemeless URIs that follow the - * conventions in https://cloud.google.com/apis/design/resource_names. For - * example: `projects/my-project/locations/us-central1` - * Please see {@see VmwareEngineClient::locationName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\ListNetworkPoliciesRequest - * - * @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 location (region) to query for - * network policies. Resource names are schemeless URIs that follow the - * conventions in https://cloud.google.com/apis/design/resource_names. For - * example: `projects/my-project/locations/us-central1` - * @type int $page_size - * The maximum number of network policies to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * @type string $page_token - * A page token, received from a previous `ListNetworkPolicies` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListNetworkPolicies` must match the call that provided the page - * token. - * @type string $filter - * A filter expression that matches resources returned in the response. - * The expression must specify the field name, a comparison - * operator, and the value that you want to use for filtering. The value - * must be a string, a number, or a boolean. The comparison operator - * must be `=`, `!=`, `>`, or `<`. - * For example, if you are filtering a list of network policies, you can - * exclude the ones named `example-policy` by specifying - * `name != "example-policy"`. - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "example-policy") - * (createTime > "2021-04-12T08:15:10.40Z") - * ``` - * By default, each expression is an `AND` expression. However, you - * can include `AND` and `OR` expressions explicitly. - * For example: - * ``` - * (name = "example-policy-1") AND - * (createTime > "2021-04-12T08:15:10.40Z") OR - * (name = "example-policy-2") - * ``` - * @type string $order_by - * Sorts list results by a certain order. By default, returned results - * are ordered by `name` in ascending order. - * You can also sort results in descending order based on the `name` value - * using `orderBy="name desc"`. - * Currently, only ordering by `name` is supported. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the location (region) to query for - * network policies. Resource names are schemeless URIs that follow the - * conventions in https://cloud.google.com/apis/design/resource_names. For - * example: `projects/my-project/locations/us-central1` - * - * 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 (region) to query for - * network policies. Resource names are schemeless URIs that follow the - * conventions in https://cloud.google.com/apis/design/resource_names. For - * example: `projects/my-project/locations/us-central1` - * - * 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 network policies to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of network policies to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * 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 `ListNetworkPolicies` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListNetworkPolicies` 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 `ListNetworkPolicies` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListNetworkPolicies` 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; - } - - /** - * A filter expression that matches resources returned in the response. - * The expression must specify the field name, a comparison - * operator, and the value that you want to use for filtering. The value - * must be a string, a number, or a boolean. The comparison operator - * must be `=`, `!=`, `>`, or `<`. - * For example, if you are filtering a list of network policies, you can - * exclude the ones named `example-policy` by specifying - * `name != "example-policy"`. - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "example-policy") - * (createTime > "2021-04-12T08:15:10.40Z") - * ``` - * By default, each expression is an `AND` expression. However, you - * can include `AND` and `OR` expressions explicitly. - * For example: - * ``` - * (name = "example-policy-1") AND - * (createTime > "2021-04-12T08:15:10.40Z") OR - * (name = "example-policy-2") - * ``` - * - * Generated from protobuf field string filter = 4; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * A filter expression that matches resources returned in the response. - * The expression must specify the field name, a comparison - * operator, and the value that you want to use for filtering. The value - * must be a string, a number, or a boolean. The comparison operator - * must be `=`, `!=`, `>`, or `<`. - * For example, if you are filtering a list of network policies, you can - * exclude the ones named `example-policy` by specifying - * `name != "example-policy"`. - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "example-policy") - * (createTime > "2021-04-12T08:15:10.40Z") - * ``` - * By default, each expression is an `AND` expression. However, you - * can include `AND` and `OR` expressions explicitly. - * For example: - * ``` - * (name = "example-policy-1") AND - * (createTime > "2021-04-12T08:15:10.40Z") OR - * (name = "example-policy-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; - } - - /** - * Sorts list results by a certain order. By default, returned results - * are ordered by `name` in ascending order. - * You can also sort results in descending order based on the `name` value - * using `orderBy="name desc"`. - * Currently, only ordering by `name` is supported. - * - * Generated from protobuf field string order_by = 5; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * Sorts list results by a certain order. By default, returned results - * are ordered by `name` in ascending order. - * You can also sort results in descending order based on the `name` value - * using `orderBy="name desc"`. - * Currently, only ordering by `name` is supported. - * - * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNetworkPoliciesResponse.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNetworkPoliciesResponse.php deleted file mode 100644 index 26651ec97a12..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNetworkPoliciesResponse.php +++ /dev/null @@ -1,144 +0,0 @@ -google.cloud.vmwareengine.v1.ListNetworkPoliciesResponse - */ -class ListNetworkPoliciesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * A list of network policies. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.NetworkPolicy network_policies = 1; - */ - private $network_policies; - /** - * A token, which can be send 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 = ''; - /** - * Locations that could not be reached when making an aggregated query using - * wildcards. - * - * Generated from protobuf field repeated string unreachable = 3; - */ - private $unreachable; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\VmwareEngine\V1\NetworkPolicy[] $network_policies - * A list of network policies. - * @type string $next_page_token - * A token, which can be send as `page_token` to retrieve the next page. - * If this field is omitted, there are no subsequent pages. - * @type string[] $unreachable - * Locations that could not be reached when making an aggregated query using - * wildcards. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * A list of network policies. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.NetworkPolicy network_policies = 1; - * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\NetworkPolicy> - */ - public function getNetworkPolicies() - { - return $this->network_policies; - } - - /** - * A list of network policies. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.NetworkPolicy network_policies = 1; - * @param \Google\Cloud\VmwareEngine\V1\NetworkPolicy[] $var - * @return $this - */ - public function setNetworkPolicies($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\NetworkPolicy::class); - $this->network_policies = $arr; - - return $this; - } - - /** - * A token, which can be send 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 send 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; - } - - /** - * Locations that could not be reached when making an aggregated query using - * wildcards. - * - * Generated from protobuf field repeated string unreachable = 3; - * @return RepeatedField - */ - public function getUnreachable() - { - return $this->unreachable; - } - - /** - * Locations that could not be reached when making an aggregated query using - * wildcards. - * - * Generated from protobuf field repeated string unreachable = 3; - * @param string[] $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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNodeTypesRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNodeTypesRequest.php deleted file mode 100644 index 670c0e546789..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNodeTypesRequest.php +++ /dev/null @@ -1,312 +0,0 @@ -google.cloud.vmwareengine.v1.ListNodeTypesRequest - */ -class ListNodeTypesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the location to be queried for node types. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The maximum number of node types to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * A page token, received from a previous `ListNodeTypes` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListNodeTypes` must match the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - /** - * A filter expression that matches resources returned in the response. - * The expression must specify the field name, a comparison - * operator, and the value that you want to use for filtering. The value - * must be a string, a number, or a boolean. The comparison operator - * must be `=`, `!=`, `>`, or `<`. - * For example, if you are filtering a list of node types, you can - * exclude the ones named `standard-72` by specifying - * `name != "standard-72"`. - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "standard-72") - * (virtual_cpu_count > 2) - * ``` - * By default, each expression is an `AND` expression. However, you - * can include `AND` and `OR` expressions explicitly. - * For example: - * ``` - * (name = "standard-96") AND - * (virtual_cpu_count > 2) OR - * (name = "standard-72") - * ``` - * - * Generated from protobuf field string filter = 4; - */ - protected $filter = ''; - - /** - * @param string $parent Required. The resource name of the location to be queried for node types. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a` - * Please see {@see VmwareEngineClient::locationName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\ListNodeTypesRequest - * - * @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 location to be queried for node types. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a` - * @type int $page_size - * The maximum number of node types to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * @type string $page_token - * A page token, received from a previous `ListNodeTypes` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListNodeTypes` must match the call that provided the page token. - * @type string $filter - * A filter expression that matches resources returned in the response. - * The expression must specify the field name, a comparison - * operator, and the value that you want to use for filtering. The value - * must be a string, a number, or a boolean. The comparison operator - * must be `=`, `!=`, `>`, or `<`. - * For example, if you are filtering a list of node types, you can - * exclude the ones named `standard-72` by specifying - * `name != "standard-72"`. - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "standard-72") - * (virtual_cpu_count > 2) - * ``` - * By default, each expression is an `AND` expression. However, you - * can include `AND` and `OR` expressions explicitly. - * For example: - * ``` - * (name = "standard-96") AND - * (virtual_cpu_count > 2) OR - * (name = "standard-72") - * ``` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the location to be queried for node types. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a` - * - * 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 to be queried for node types. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a` - * - * 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 node types to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of node types to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * 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 `ListNodeTypes` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListNodeTypes` 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 `ListNodeTypes` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListNodeTypes` 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; - } - - /** - * A filter expression that matches resources returned in the response. - * The expression must specify the field name, a comparison - * operator, and the value that you want to use for filtering. The value - * must be a string, a number, or a boolean. The comparison operator - * must be `=`, `!=`, `>`, or `<`. - * For example, if you are filtering a list of node types, you can - * exclude the ones named `standard-72` by specifying - * `name != "standard-72"`. - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "standard-72") - * (virtual_cpu_count > 2) - * ``` - * By default, each expression is an `AND` expression. However, you - * can include `AND` and `OR` expressions explicitly. - * For example: - * ``` - * (name = "standard-96") AND - * (virtual_cpu_count > 2) OR - * (name = "standard-72") - * ``` - * - * Generated from protobuf field string filter = 4; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * A filter expression that matches resources returned in the response. - * The expression must specify the field name, a comparison - * operator, and the value that you want to use for filtering. The value - * must be a string, a number, or a boolean. The comparison operator - * must be `=`, `!=`, `>`, or `<`. - * For example, if you are filtering a list of node types, you can - * exclude the ones named `standard-72` by specifying - * `name != "standard-72"`. - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "standard-72") - * (virtual_cpu_count > 2) - * ``` - * By default, each expression is an `AND` expression. However, you - * can include `AND` and `OR` expressions explicitly. - * For example: - * ``` - * (name = "standard-96") AND - * (virtual_cpu_count > 2) OR - * (name = "standard-72") - * ``` - * - * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNodeTypesResponse.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNodeTypesResponse.php deleted file mode 100644 index bc4d8851e9c0..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNodeTypesResponse.php +++ /dev/null @@ -1,144 +0,0 @@ -google.cloud.vmwareengine.v1.ListNodeTypesResponse - */ -class ListNodeTypesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * A list of Node Types. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.NodeType node_types = 1; - */ - private $node_types; - /** - * 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 = ''; - /** - * Locations that could not be reached when making an aggregated query using - * wildcards. - * - * Generated from protobuf field repeated string unreachable = 3; - */ - private $unreachable; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\VmwareEngine\V1\NodeType[] $node_types - * A list of Node Types. - * @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. - * @type string[] $unreachable - * Locations that could not be reached when making an aggregated query using - * wildcards. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * A list of Node Types. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.NodeType node_types = 1; - * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\NodeType> - */ - public function getNodeTypes() - { - return $this->node_types; - } - - /** - * A list of Node Types. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.NodeType node_types = 1; - * @param \Google\Cloud\VmwareEngine\V1\NodeType[] $var - * @return $this - */ - public function setNodeTypes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\NodeType::class); - $this->node_types = $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; - } - - /** - * Locations that could not be reached when making an aggregated query using - * wildcards. - * - * Generated from protobuf field repeated string unreachable = 3; - * @return RepeatedField - */ - public function getUnreachable() - { - return $this->unreachable; - } - - /** - * Locations that could not be reached when making an aggregated query using - * wildcards. - * - * Generated from protobuf field repeated string unreachable = 3; - * @param string[] $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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNodesRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNodesRequest.php deleted file mode 100644 index aa9bc6b99586..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNodesRequest.php +++ /dev/null @@ -1,198 +0,0 @@ -google.cloud.vmwareengine.v1.ListNodesRequest - */ -class ListNodesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the cluster to be queried for nodes. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The maximum number of nodes to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * A page token, received from a previous `ListNodes` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListNodes` must match the call that provided the page - * token. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - - /** - * @param string $parent Required. The resource name of the cluster to be queried for nodes. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster` - * Please see {@see VmwareEngineClient::clusterName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\ListNodesRequest - * - * @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 cluster to be queried for nodes. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster` - * @type int $page_size - * The maximum number of nodes to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * @type string $page_token - * A page token, received from a previous `ListNodes` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListNodes` must match the call that provided the page - * token. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the cluster to be queried for nodes. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster` - * - * 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 cluster to be queried for nodes. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster` - * - * 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 nodes to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of nodes to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * 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 `ListNodes` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListNodes` 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 `ListNodes` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListNodes` 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; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNodesResponse.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNodesResponse.php deleted file mode 100644 index 1cd1fe3b8e7f..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListNodesResponse.php +++ /dev/null @@ -1,106 +0,0 @@ -google.cloud.vmwareengine.v1.ListNodesResponse - */ -class ListNodesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The nodes. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.Node nodes = 1; - */ - private $nodes; - /** - * 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 \Google\Cloud\VmwareEngine\V1\Node[] $nodes - * The nodes. - * @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\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * The nodes. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.Node nodes = 1; - * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\Node> - */ - public function getNodes() - { - return $this->nodes; - } - - /** - * The nodes. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.Node nodes = 1; - * @param \Google\Cloud\VmwareEngine\V1\Node[] $var - * @return $this - */ - public function setNodes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\Node::class); - $this->nodes = $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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPeeringRoutesRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPeeringRoutesRequest.php deleted file mode 100644 index 43d7c8486300..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPeeringRoutesRequest.php +++ /dev/null @@ -1,239 +0,0 @@ -google.cloud.vmwareengine.v1.ListPeeringRoutesRequest - */ -class ListPeeringRoutesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the network peering to retrieve peering - * routes from. Resource names are schemeless URIs that follow the conventions - * in https://cloud.google.com/apis/design/resource_names. For example: - * `projects/my-project/locations/global/networkPeerings/my-peering` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The maximum number of peering routes to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * A page token, received from a previous `ListPeeringRoutes` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListPeeringRoutes` must - * match the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - /** - * A filter expression that matches resources returned in the response. - * Currently, only filtering on the `direction` field is supported. To return - * routes imported from the peer network, provide "direction=INCOMING". To - * return routes exported from the VMware Engine network, provide - * "direction=OUTGOING". Other filter expressions return an error. - * - * Generated from protobuf field string filter = 6; - */ - protected $filter = ''; - - /** - * @param string $parent Required. The resource name of the network peering to retrieve peering - * routes from. Resource names are schemeless URIs that follow the conventions - * in https://cloud.google.com/apis/design/resource_names. For example: - * `projects/my-project/locations/global/networkPeerings/my-peering` - * Please see {@see VmwareEngineClient::networkPeeringName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\ListPeeringRoutesRequest - * - * @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 network peering to retrieve peering - * routes from. Resource names are schemeless URIs that follow the conventions - * in https://cloud.google.com/apis/design/resource_names. For example: - * `projects/my-project/locations/global/networkPeerings/my-peering` - * @type int $page_size - * The maximum number of peering routes to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * @type string $page_token - * A page token, received from a previous `ListPeeringRoutes` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListPeeringRoutes` must - * match the call that provided the page token. - * @type string $filter - * A filter expression that matches resources returned in the response. - * Currently, only filtering on the `direction` field is supported. To return - * routes imported from the peer network, provide "direction=INCOMING". To - * return routes exported from the VMware Engine network, provide - * "direction=OUTGOING". Other filter expressions return an error. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the network peering to retrieve peering - * routes from. Resource names are schemeless URIs that follow the conventions - * in https://cloud.google.com/apis/design/resource_names. For example: - * `projects/my-project/locations/global/networkPeerings/my-peering` - * - * 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 network peering to retrieve peering - * routes from. Resource names are schemeless URIs that follow the conventions - * in https://cloud.google.com/apis/design/resource_names. For example: - * `projects/my-project/locations/global/networkPeerings/my-peering` - * - * 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 peering routes to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of peering routes to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * 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 `ListPeeringRoutes` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListPeeringRoutes` 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 `ListPeeringRoutes` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListPeeringRoutes` 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; - } - - /** - * A filter expression that matches resources returned in the response. - * Currently, only filtering on the `direction` field is supported. To return - * routes imported from the peer network, provide "direction=INCOMING". To - * return routes exported from the VMware Engine network, provide - * "direction=OUTGOING". Other filter expressions return an error. - * - * Generated from protobuf field string filter = 6; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * A filter expression that matches resources returned in the response. - * Currently, only filtering on the `direction` field is supported. To return - * routes imported from the peer network, provide "direction=INCOMING". To - * return routes exported from the VMware Engine network, provide - * "direction=OUTGOING". Other filter expressions return an error. - * - * Generated from protobuf field string filter = 6; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPeeringRoutesResponse.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPeeringRoutesResponse.php deleted file mode 100644 index 93aecb6ae180..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPeeringRoutesResponse.php +++ /dev/null @@ -1,106 +0,0 @@ -google.cloud.vmwareengine.v1.ListPeeringRoutesResponse - */ -class ListPeeringRoutesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * A list of peering routes. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.PeeringRoute peering_routes = 1; - */ - private $peering_routes; - /** - * 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 \Google\Cloud\VmwareEngine\V1\PeeringRoute[] $peering_routes - * A list of peering routes. - * @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\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * A list of peering routes. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.PeeringRoute peering_routes = 1; - * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\PeeringRoute> - */ - public function getPeeringRoutes() - { - return $this->peering_routes; - } - - /** - * A list of peering routes. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.PeeringRoute peering_routes = 1; - * @param \Google\Cloud\VmwareEngine\V1\PeeringRoute[] $var - * @return $this - */ - public function setPeeringRoutes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\PeeringRoute::class); - $this->peering_routes = $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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateCloudsRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateCloudsRequest.php deleted file mode 100644 index 94a3f7bf545a..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateCloudsRequest.php +++ /dev/null @@ -1,362 +0,0 @@ -google.cloud.vmwareengine.v1.ListPrivateCloudsRequest - */ -class ListPrivateCloudsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the private cloud to be queried for - * clusters. Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The maximum number of private clouds to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * A page token, received from a previous `ListPrivateClouds` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListPrivateClouds` must - * match the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - /** - * A filter expression that matches resources returned in the response. - * The expression must specify the field name, a comparison operator, and the - * value that you want to use for filtering. The value must be a string, a - * number, or a boolean. The comparison operator must be `=`, `!=`, `>`, or - * `<`. - * For example, if you are filtering a list of private clouds, you can exclude - * the ones named `example-pc` by specifying `name != "example-pc"`. - * You can also filter nested fields. For example, you could specify - * `networkConfig.managementCidr = "192.168.0.0/24"` to include private clouds - * only if they have a matching address in their network configuration. - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "example-pc") - * (createTime > "2021-04-12T08:15:10.40Z") - * ``` - * By default, each expression is an `AND` expression. However, you can - * include `AND` and `OR` expressions explicitly. For example: - * ``` - * (name = "private-cloud-1") AND - * (createTime > "2021-04-12T08:15:10.40Z") OR - * (name = "private-cloud-2") - * ``` - * - * Generated from protobuf field string filter = 4; - */ - protected $filter = ''; - /** - * Sorts list results by a certain order. By default, returned results are - * ordered by `name` in ascending order. You can also sort results in - * descending order based on the `name` value using `orderBy="name desc"`. - * Currently, only ordering by `name` is supported. - * - * Generated from protobuf field string order_by = 5; - */ - protected $order_by = ''; - - /** - * @param string $parent Required. The resource name of the private cloud to be queried for - * clusters. Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a` - * Please see {@see VmwareEngineClient::locationName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\ListPrivateCloudsRequest - * - * @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 private cloud to be queried for - * clusters. Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a` - * @type int $page_size - * The maximum number of private clouds to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * @type string $page_token - * A page token, received from a previous `ListPrivateClouds` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListPrivateClouds` must - * match the call that provided the page token. - * @type string $filter - * A filter expression that matches resources returned in the response. - * The expression must specify the field name, a comparison operator, and the - * value that you want to use for filtering. The value must be a string, a - * number, or a boolean. The comparison operator must be `=`, `!=`, `>`, or - * `<`. - * For example, if you are filtering a list of private clouds, you can exclude - * the ones named `example-pc` by specifying `name != "example-pc"`. - * You can also filter nested fields. For example, you could specify - * `networkConfig.managementCidr = "192.168.0.0/24"` to include private clouds - * only if they have a matching address in their network configuration. - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "example-pc") - * (createTime > "2021-04-12T08:15:10.40Z") - * ``` - * By default, each expression is an `AND` expression. However, you can - * include `AND` and `OR` expressions explicitly. For example: - * ``` - * (name = "private-cloud-1") AND - * (createTime > "2021-04-12T08:15:10.40Z") OR - * (name = "private-cloud-2") - * ``` - * @type string $order_by - * Sorts list results by a certain order. By default, returned results are - * ordered by `name` in ascending order. You can also sort results in - * descending order based on the `name` value using `orderBy="name desc"`. - * Currently, only ordering by `name` is supported. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the private cloud to be queried for - * clusters. Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a` - * - * 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 private cloud to be queried for - * clusters. Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a` - * - * 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 private clouds to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of private clouds to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * 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 `ListPrivateClouds` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListPrivateClouds` 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 `ListPrivateClouds` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to `ListPrivateClouds` 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; - } - - /** - * A filter expression that matches resources returned in the response. - * The expression must specify the field name, a comparison operator, and the - * value that you want to use for filtering. The value must be a string, a - * number, or a boolean. The comparison operator must be `=`, `!=`, `>`, or - * `<`. - * For example, if you are filtering a list of private clouds, you can exclude - * the ones named `example-pc` by specifying `name != "example-pc"`. - * You can also filter nested fields. For example, you could specify - * `networkConfig.managementCidr = "192.168.0.0/24"` to include private clouds - * only if they have a matching address in their network configuration. - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "example-pc") - * (createTime > "2021-04-12T08:15:10.40Z") - * ``` - * By default, each expression is an `AND` expression. However, you can - * include `AND` and `OR` expressions explicitly. For example: - * ``` - * (name = "private-cloud-1") AND - * (createTime > "2021-04-12T08:15:10.40Z") OR - * (name = "private-cloud-2") - * ``` - * - * Generated from protobuf field string filter = 4; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * A filter expression that matches resources returned in the response. - * The expression must specify the field name, a comparison operator, and the - * value that you want to use for filtering. The value must be a string, a - * number, or a boolean. The comparison operator must be `=`, `!=`, `>`, or - * `<`. - * For example, if you are filtering a list of private clouds, you can exclude - * the ones named `example-pc` by specifying `name != "example-pc"`. - * You can also filter nested fields. For example, you could specify - * `networkConfig.managementCidr = "192.168.0.0/24"` to include private clouds - * only if they have a matching address in their network configuration. - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "example-pc") - * (createTime > "2021-04-12T08:15:10.40Z") - * ``` - * By default, each expression is an `AND` expression. However, you can - * include `AND` and `OR` expressions explicitly. For example: - * ``` - * (name = "private-cloud-1") AND - * (createTime > "2021-04-12T08:15:10.40Z") OR - * (name = "private-cloud-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; - } - - /** - * Sorts list results by a certain order. By default, returned results are - * ordered by `name` in ascending order. You can also sort results in - * descending order based on the `name` value using `orderBy="name desc"`. - * Currently, only ordering by `name` is supported. - * - * Generated from protobuf field string order_by = 5; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * Sorts list results by a certain order. By default, returned results are - * ordered by `name` in ascending order. You can also sort results in - * descending order based on the `name` value using `orderBy="name desc"`. - * Currently, only ordering by `name` is supported. - * - * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateCloudsResponse.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateCloudsResponse.php deleted file mode 100644 index d8c40de7920b..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateCloudsResponse.php +++ /dev/null @@ -1,144 +0,0 @@ -google.cloud.vmwareengine.v1.ListPrivateCloudsResponse - */ -class ListPrivateCloudsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * A list of private clouds. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.PrivateCloud private_clouds = 1; - */ - private $private_clouds; - /** - * 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 = ''; - /** - * Locations that could not be reached when making an aggregated query using - * wildcards. - * - * Generated from protobuf field repeated string unreachable = 3; - */ - private $unreachable; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\VmwareEngine\V1\PrivateCloud[] $private_clouds - * A list of private clouds. - * @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. - * @type string[] $unreachable - * Locations that could not be reached when making an aggregated query using - * wildcards. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * A list of private clouds. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.PrivateCloud private_clouds = 1; - * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\PrivateCloud> - */ - public function getPrivateClouds() - { - return $this->private_clouds; - } - - /** - * A list of private clouds. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.PrivateCloud private_clouds = 1; - * @param \Google\Cloud\VmwareEngine\V1\PrivateCloud[] $var - * @return $this - */ - public function setPrivateClouds($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\PrivateCloud::class); - $this->private_clouds = $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; - } - - /** - * Locations that could not be reached when making an aggregated query using - * wildcards. - * - * Generated from protobuf field repeated string unreachable = 3; - * @return RepeatedField - */ - public function getUnreachable() - { - return $this->unreachable; - } - - /** - * Locations that could not be reached when making an aggregated query using - * wildcards. - * - * Generated from protobuf field repeated string unreachable = 3; - * @param string[] $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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateConnectionPeeringRoutesRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateConnectionPeeringRoutesRequest.php deleted file mode 100644 index 6ad78b75cf5b..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateConnectionPeeringRoutesRequest.php +++ /dev/null @@ -1,189 +0,0 @@ -google.cloud.vmwareengine.v1.ListPrivateConnectionPeeringRoutesRequest - */ -class ListPrivateConnectionPeeringRoutesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the private connection to retrieve peering - * routes from. Resource names are schemeless URIs that follow the conventions - * in https://cloud.google.com/apis/design/resource_names. For example: - * `projects/my-project/locations/us-west1/privateConnections/my-connection` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The maximum number of peering routes to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * A page token, received from a previous `ListPrivateConnectionPeeringRoutes` - * call. Provide this to retrieve the subsequent page. When paginating, all - * other parameters provided to `ListPrivateConnectionPeeringRoutes` must - * match the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - - /** - * @param string $parent Required. The resource name of the private connection to retrieve peering - * routes from. Resource names are schemeless URIs that follow the conventions - * in https://cloud.google.com/apis/design/resource_names. For example: - * `projects/my-project/locations/us-west1/privateConnections/my-connection` - * Please see {@see VmwareEngineClient::privateConnectionName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\ListPrivateConnectionPeeringRoutesRequest - * - * @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 private connection to retrieve peering - * routes from. Resource names are schemeless URIs that follow the conventions - * in https://cloud.google.com/apis/design/resource_names. For example: - * `projects/my-project/locations/us-west1/privateConnections/my-connection` - * @type int $page_size - * The maximum number of peering routes to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * @type string $page_token - * A page token, received from a previous `ListPrivateConnectionPeeringRoutes` - * call. Provide this to retrieve the subsequent page. When paginating, all - * other parameters provided to `ListPrivateConnectionPeeringRoutes` must - * match the call that provided the page token. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the private connection to retrieve peering - * routes from. Resource names are schemeless URIs that follow the conventions - * in https://cloud.google.com/apis/design/resource_names. For example: - * `projects/my-project/locations/us-west1/privateConnections/my-connection` - * - * 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 private connection to retrieve peering - * routes from. Resource names are schemeless URIs that follow the conventions - * in https://cloud.google.com/apis/design/resource_names. For example: - * `projects/my-project/locations/us-west1/privateConnections/my-connection` - * - * 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 peering routes to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of peering routes to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * 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 `ListPrivateConnectionPeeringRoutes` - * call. Provide this to retrieve the subsequent page. When paginating, all - * other parameters provided to `ListPrivateConnectionPeeringRoutes` 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 `ListPrivateConnectionPeeringRoutes` - * call. Provide this to retrieve the subsequent page. When paginating, all - * other parameters provided to `ListPrivateConnectionPeeringRoutes` 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; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateConnectionPeeringRoutesResponse.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateConnectionPeeringRoutesResponse.php deleted file mode 100644 index 819633fd4674..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateConnectionPeeringRoutesResponse.php +++ /dev/null @@ -1,106 +0,0 @@ -google.cloud.vmwareengine.v1.ListPrivateConnectionPeeringRoutesResponse - */ -class ListPrivateConnectionPeeringRoutesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * A list of peering routes. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.PeeringRoute peering_routes = 1; - */ - private $peering_routes; - /** - * 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 \Google\Cloud\VmwareEngine\V1\PeeringRoute[] $peering_routes - * A list of peering routes. - * @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\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * A list of peering routes. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.PeeringRoute peering_routes = 1; - * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\PeeringRoute> - */ - public function getPeeringRoutes() - { - return $this->peering_routes; - } - - /** - * A list of peering routes. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.PeeringRoute peering_routes = 1; - * @param \Google\Cloud\VmwareEngine\V1\PeeringRoute[] $var - * @return $this - */ - public function setPeeringRoutes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\PeeringRoute::class); - $this->peering_routes = $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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateConnectionsRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateConnectionsRequest.php deleted file mode 100644 index 359db89ccd66..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateConnectionsRequest.php +++ /dev/null @@ -1,357 +0,0 @@ -google.cloud.vmwareengine.v1.ListPrivateConnectionsRequest - */ -class ListPrivateConnectionsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the location to query for - * private connections. Resource names are schemeless URIs that follow the - * conventions in https://cloud.google.com/apis/design/resource_names. For - * example: `projects/my-project/locations/us-central1` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The maximum number of private connections to return in one page. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * A page token, received from a previous `ListPrivateConnections` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListPrivateConnections` must match the call that provided the page - * token. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - /** - * A filter expression that matches resources returned in the response. - * The expression must specify the field name, a comparison - * operator, and the value that you want to use for filtering. The value - * must be a string, a number, or a boolean. The comparison operator - * must be `=`, `!=`, `>`, or `<`. - * For example, if you are filtering a list of private connections, you can - * exclude the ones named `example-connection` by specifying - * `name != "example-connection"`. - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "example-connection") - * (createTime > "2022-09-22T08:15:10.40Z") - * ``` - * By default, each expression is an `AND` expression. However, you - * can include `AND` and `OR` expressions explicitly. - * For example: - * ``` - * (name = "example-connection-1") AND - * (createTime > "2021-04-12T08:15:10.40Z") OR - * (name = "example-connection-2") - * ``` - * - * Generated from protobuf field string filter = 4; - */ - protected $filter = ''; - /** - * Sorts list results by a certain order. By default, returned results - * are ordered by `name` in ascending order. - * You can also sort results in descending order based on the `name` value - * using `orderBy="name desc"`. - * Currently, only ordering by `name` is supported. - * - * Generated from protobuf field string order_by = 5; - */ - protected $order_by = ''; - - /** - * @param string $parent Required. The resource name of the location to query for - * private connections. Resource names are schemeless URIs that follow the - * conventions in https://cloud.google.com/apis/design/resource_names. For - * example: `projects/my-project/locations/us-central1` - * Please see {@see VmwareEngineClient::locationName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\ListPrivateConnectionsRequest - * - * @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 location to query for - * private connections. Resource names are schemeless URIs that follow the - * conventions in https://cloud.google.com/apis/design/resource_names. For - * example: `projects/my-project/locations/us-central1` - * @type int $page_size - * The maximum number of private connections to return in one page. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * @type string $page_token - * A page token, received from a previous `ListPrivateConnections` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListPrivateConnections` must match the call that provided the page - * token. - * @type string $filter - * A filter expression that matches resources returned in the response. - * The expression must specify the field name, a comparison - * operator, and the value that you want to use for filtering. The value - * must be a string, a number, or a boolean. The comparison operator - * must be `=`, `!=`, `>`, or `<`. - * For example, if you are filtering a list of private connections, you can - * exclude the ones named `example-connection` by specifying - * `name != "example-connection"`. - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "example-connection") - * (createTime > "2022-09-22T08:15:10.40Z") - * ``` - * By default, each expression is an `AND` expression. However, you - * can include `AND` and `OR` expressions explicitly. - * For example: - * ``` - * (name = "example-connection-1") AND - * (createTime > "2021-04-12T08:15:10.40Z") OR - * (name = "example-connection-2") - * ``` - * @type string $order_by - * Sorts list results by a certain order. By default, returned results - * are ordered by `name` in ascending order. - * You can also sort results in descending order based on the `name` value - * using `orderBy="name desc"`. - * Currently, only ordering by `name` is supported. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the location to query for - * private connections. Resource names are schemeless URIs that follow the - * conventions in https://cloud.google.com/apis/design/resource_names. For - * example: `projects/my-project/locations/us-central1` - * - * 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 to query for - * private connections. Resource names are schemeless URIs that follow the - * conventions in https://cloud.google.com/apis/design/resource_names. For - * example: `projects/my-project/locations/us-central1` - * - * 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 private connections to return in one page. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of private connections to return in one page. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * 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 `ListPrivateConnections` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListPrivateConnections` 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 `ListPrivateConnections` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListPrivateConnections` 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; - } - - /** - * A filter expression that matches resources returned in the response. - * The expression must specify the field name, a comparison - * operator, and the value that you want to use for filtering. The value - * must be a string, a number, or a boolean. The comparison operator - * must be `=`, `!=`, `>`, or `<`. - * For example, if you are filtering a list of private connections, you can - * exclude the ones named `example-connection` by specifying - * `name != "example-connection"`. - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "example-connection") - * (createTime > "2022-09-22T08:15:10.40Z") - * ``` - * By default, each expression is an `AND` expression. However, you - * can include `AND` and `OR` expressions explicitly. - * For example: - * ``` - * (name = "example-connection-1") AND - * (createTime > "2021-04-12T08:15:10.40Z") OR - * (name = "example-connection-2") - * ``` - * - * Generated from protobuf field string filter = 4; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * A filter expression that matches resources returned in the response. - * The expression must specify the field name, a comparison - * operator, and the value that you want to use for filtering. The value - * must be a string, a number, or a boolean. The comparison operator - * must be `=`, `!=`, `>`, or `<`. - * For example, if you are filtering a list of private connections, you can - * exclude the ones named `example-connection` by specifying - * `name != "example-connection"`. - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "example-connection") - * (createTime > "2022-09-22T08:15:10.40Z") - * ``` - * By default, each expression is an `AND` expression. However, you - * can include `AND` and `OR` expressions explicitly. - * For example: - * ``` - * (name = "example-connection-1") AND - * (createTime > "2021-04-12T08:15:10.40Z") OR - * (name = "example-connection-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; - } - - /** - * Sorts list results by a certain order. By default, returned results - * are ordered by `name` in ascending order. - * You can also sort results in descending order based on the `name` value - * using `orderBy="name desc"`. - * Currently, only ordering by `name` is supported. - * - * Generated from protobuf field string order_by = 5; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * Sorts list results by a certain order. By default, returned results - * are ordered by `name` in ascending order. - * You can also sort results in descending order based on the `name` value - * using `orderBy="name desc"`. - * Currently, only ordering by `name` is supported. - * - * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateConnectionsResponse.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateConnectionsResponse.php deleted file mode 100644 index 896051d2d01f..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListPrivateConnectionsResponse.php +++ /dev/null @@ -1,140 +0,0 @@ -google.cloud.vmwareengine.v1.ListPrivateConnectionsResponse - */ -class ListPrivateConnectionsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * A list of private connections. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.PrivateConnection private_connections = 1; - */ - private $private_connections; - /** - * 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 = ''; - /** - * Unreachable resources. - * - * Generated from protobuf field repeated string unreachable = 3; - */ - private $unreachable; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\VmwareEngine\V1\PrivateConnection[] $private_connections - * A list of private connections. - * @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. - * @type string[] $unreachable - * Unreachable resources. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * A list of private connections. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.PrivateConnection private_connections = 1; - * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\PrivateConnection> - */ - public function getPrivateConnections() - { - return $this->private_connections; - } - - /** - * A list of private connections. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.PrivateConnection private_connections = 1; - * @param \Google\Cloud\VmwareEngine\V1\PrivateConnection[] $var - * @return $this - */ - public function setPrivateConnections($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\PrivateConnection::class); - $this->private_connections = $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; - } - - /** - * Unreachable resources. - * - * Generated from protobuf field repeated string unreachable = 3; - * @return RepeatedField - */ - public function getUnreachable() - { - return $this->unreachable; - } - - /** - * Unreachable resources. - * - * Generated from protobuf field repeated string unreachable = 3; - * @param string[] $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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListSubnetsRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListSubnetsRequest.php deleted file mode 100644 index bc4d382af8a1..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListSubnetsRequest.php +++ /dev/null @@ -1,199 +0,0 @@ -google.cloud.vmwareengine.v1.ListSubnetsRequest - */ -class ListSubnetsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the private cloud to be queried for - * subnets. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $parent = ''; - /** - * The maximum number of subnets to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * A page token, received from a previous `ListSubnetsRequest` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListSubnetsRequest` must match the call that provided the page token. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - - /** - * @param string $parent Required. The resource name of the private cloud to be queried for - * subnets. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * Please see {@see VmwareEngineClient::privateCloudName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\ListSubnetsRequest - * - * @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 private cloud to be queried for - * subnets. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * @type int $page_size - * The maximum number of subnets to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * @type string $page_token - * A page token, received from a previous `ListSubnetsRequest` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListSubnetsRequest` must match the call that provided the page token. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the private cloud to be queried for - * subnets. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * 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 private cloud to be queried for - * subnets. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * 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 subnets to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * Generated from protobuf field int32 page_size = 2; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * The maximum number of subnets to return in one page. - * The service may return fewer than this value. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * 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 `ListSubnetsRequest` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListSubnetsRequest` 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 `ListSubnetsRequest` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListSubnetsRequest` 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; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListSubnetsResponse.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListSubnetsResponse.php deleted file mode 100644 index b45bff4cb13f..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListSubnetsResponse.php +++ /dev/null @@ -1,144 +0,0 @@ -google.cloud.vmwareengine.v1.ListSubnetsResponse - */ -class ListSubnetsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * A list of subnets. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.Subnet subnets = 1; - */ - private $subnets; - /** - * 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 = ''; - /** - * Locations that could not be reached when making an aggregated query using - * wildcards. - * - * Generated from protobuf field repeated string unreachable = 3; - */ - private $unreachable; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\VmwareEngine\V1\Subnet[] $subnets - * A list of subnets. - * @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. - * @type string[] $unreachable - * Locations that could not be reached when making an aggregated query using - * wildcards. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * A list of subnets. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.Subnet subnets = 1; - * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\Subnet> - */ - public function getSubnets() - { - return $this->subnets; - } - - /** - * A list of subnets. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.Subnet subnets = 1; - * @param \Google\Cloud\VmwareEngine\V1\Subnet[] $var - * @return $this - */ - public function setSubnets($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\Subnet::class); - $this->subnets = $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; - } - - /** - * Locations that could not be reached when making an aggregated query using - * wildcards. - * - * Generated from protobuf field repeated string unreachable = 3; - * @return RepeatedField - */ - public function getUnreachable() - { - return $this->unreachable; - } - - /** - * Locations that could not be reached when making an aggregated query using - * wildcards. - * - * Generated from protobuf field repeated string unreachable = 3; - * @param string[] $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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListVmwareEngineNetworksRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListVmwareEngineNetworksRequest.php deleted file mode 100644 index 53e40b5677ae..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListVmwareEngineNetworksRequest.php +++ /dev/null @@ -1,357 +0,0 @@ -google.cloud.vmwareengine.v1.ListVmwareEngineNetworksRequest - */ -class ListVmwareEngineNetworksRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the location to query for - * VMware Engine networks. Resource names are schemeless URIs that follow the - * conventions in https://cloud.google.com/apis/design/resource_names. For - * example: `projects/my-project/locations/global` - * - * 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 one page. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * Generated from protobuf field int32 page_size = 2; - */ - protected $page_size = 0; - /** - * A page token, received from a previous `ListVmwareEngineNetworks` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListVmwareEngineNetworks` must match the call that provided the page - * token. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - /** - * A filter expression that matches resources returned in the response. - * The expression must specify the field name, a comparison - * operator, and the value that you want to use for filtering. The value - * must be a string, a number, or a boolean. The comparison operator - * must be `=`, `!=`, `>`, or `<`. - * For example, if you are filtering a list of network peerings, you can - * exclude the ones named `example-network` by specifying - * `name != "example-network"`. - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "example-network") - * (createTime > "2021-04-12T08:15:10.40Z") - * ``` - * By default, each expression is an `AND` expression. However, you - * can include `AND` and `OR` expressions explicitly. - * For example: - * ``` - * (name = "example-network-1") AND - * (createTime > "2021-04-12T08:15:10.40Z") OR - * (name = "example-network-2") - * ``` - * - * Generated from protobuf field string filter = 4; - */ - protected $filter = ''; - /** - * Sorts list results by a certain order. By default, returned results - * are ordered by `name` in ascending order. - * You can also sort results in descending order based on the `name` value - * using `orderBy="name desc"`. - * Currently, only ordering by `name` is supported. - * - * Generated from protobuf field string order_by = 5; - */ - protected $order_by = ''; - - /** - * @param string $parent Required. The resource name of the location to query for - * VMware Engine networks. Resource names are schemeless URIs that follow the - * conventions in https://cloud.google.com/apis/design/resource_names. For - * example: `projects/my-project/locations/global` - * Please see {@see VmwareEngineClient::locationName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\ListVmwareEngineNetworksRequest - * - * @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 location to query for - * VMware Engine networks. Resource names are schemeless URIs that follow the - * conventions in https://cloud.google.com/apis/design/resource_names. For - * example: `projects/my-project/locations/global` - * @type int $page_size - * The maximum number of results to return in one page. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * @type string $page_token - * A page token, received from a previous `ListVmwareEngineNetworks` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListVmwareEngineNetworks` must match the call that provided the page - * token. - * @type string $filter - * A filter expression that matches resources returned in the response. - * The expression must specify the field name, a comparison - * operator, and the value that you want to use for filtering. The value - * must be a string, a number, or a boolean. The comparison operator - * must be `=`, `!=`, `>`, or `<`. - * For example, if you are filtering a list of network peerings, you can - * exclude the ones named `example-network` by specifying - * `name != "example-network"`. - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "example-network") - * (createTime > "2021-04-12T08:15:10.40Z") - * ``` - * By default, each expression is an `AND` expression. However, you - * can include `AND` and `OR` expressions explicitly. - * For example: - * ``` - * (name = "example-network-1") AND - * (createTime > "2021-04-12T08:15:10.40Z") OR - * (name = "example-network-2") - * ``` - * @type string $order_by - * Sorts list results by a certain order. By default, returned results - * are ordered by `name` in ascending order. - * You can also sort results in descending order based on the `name` value - * using `orderBy="name desc"`. - * Currently, only ordering by `name` is supported. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the location to query for - * VMware Engine networks. Resource names are schemeless URIs that follow the - * conventions in https://cloud.google.com/apis/design/resource_names. For - * example: `projects/my-project/locations/global` - * - * 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 to query for - * VMware Engine networks. Resource names are schemeless URIs that follow the - * conventions in https://cloud.google.com/apis/design/resource_names. For - * example: `projects/my-project/locations/global` - * - * 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 one page. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * 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 one page. - * The maximum value is coerced to 1000. - * The default value of this field is 500. - * - * 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 `ListVmwareEngineNetworks` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListVmwareEngineNetworks` 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 `ListVmwareEngineNetworks` call. - * Provide this to retrieve the subsequent page. - * When paginating, all other parameters provided to - * `ListVmwareEngineNetworks` 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; - } - - /** - * A filter expression that matches resources returned in the response. - * The expression must specify the field name, a comparison - * operator, and the value that you want to use for filtering. The value - * must be a string, a number, or a boolean. The comparison operator - * must be `=`, `!=`, `>`, or `<`. - * For example, if you are filtering a list of network peerings, you can - * exclude the ones named `example-network` by specifying - * `name != "example-network"`. - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "example-network") - * (createTime > "2021-04-12T08:15:10.40Z") - * ``` - * By default, each expression is an `AND` expression. However, you - * can include `AND` and `OR` expressions explicitly. - * For example: - * ``` - * (name = "example-network-1") AND - * (createTime > "2021-04-12T08:15:10.40Z") OR - * (name = "example-network-2") - * ``` - * - * Generated from protobuf field string filter = 4; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * A filter expression that matches resources returned in the response. - * The expression must specify the field name, a comparison - * operator, and the value that you want to use for filtering. The value - * must be a string, a number, or a boolean. The comparison operator - * must be `=`, `!=`, `>`, or `<`. - * For example, if you are filtering a list of network peerings, you can - * exclude the ones named `example-network` by specifying - * `name != "example-network"`. - * To filter on multiple expressions, provide each separate expression within - * parentheses. For example: - * ``` - * (name = "example-network") - * (createTime > "2021-04-12T08:15:10.40Z") - * ``` - * By default, each expression is an `AND` expression. However, you - * can include `AND` and `OR` expressions explicitly. - * For example: - * ``` - * (name = "example-network-1") AND - * (createTime > "2021-04-12T08:15:10.40Z") OR - * (name = "example-network-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; - } - - /** - * Sorts list results by a certain order. By default, returned results - * are ordered by `name` in ascending order. - * You can also sort results in descending order based on the `name` value - * using `orderBy="name desc"`. - * Currently, only ordering by `name` is supported. - * - * Generated from protobuf field string order_by = 5; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * Sorts list results by a certain order. By default, returned results - * are ordered by `name` in ascending order. - * You can also sort results in descending order based on the `name` value - * using `orderBy="name desc"`. - * Currently, only ordering by `name` is supported. - * - * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListVmwareEngineNetworksResponse.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListVmwareEngineNetworksResponse.php deleted file mode 100644 index 545b85498aec..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ListVmwareEngineNetworksResponse.php +++ /dev/null @@ -1,140 +0,0 @@ -google.cloud.vmwareengine.v1.ListVmwareEngineNetworksResponse - */ -class ListVmwareEngineNetworksResponse extends \Google\Protobuf\Internal\Message -{ - /** - * A list of VMware Engine networks. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.VmwareEngineNetwork vmware_engine_networks = 1; - */ - private $vmware_engine_networks; - /** - * 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 = ''; - /** - * Unreachable resources. - * - * Generated from protobuf field repeated string unreachable = 3; - */ - private $unreachable; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork[] $vmware_engine_networks - * A list of VMware Engine networks. - * @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. - * @type string[] $unreachable - * Unreachable resources. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * A list of VMware Engine networks. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.VmwareEngineNetwork vmware_engine_networks = 1; - * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork> - */ - public function getVmwareEngineNetworks() - { - return $this->vmware_engine_networks; - } - - /** - * A list of VMware Engine networks. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.VmwareEngineNetwork vmware_engine_networks = 1; - * @param \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork[] $var - * @return $this - */ - public function setVmwareEngineNetworks($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork::class); - $this->vmware_engine_networks = $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; - } - - /** - * Unreachable resources. - * - * Generated from protobuf field repeated string unreachable = 3; - * @return RepeatedField - */ - public function getUnreachable() - { - return $this->unreachable; - } - - /** - * Unreachable resources. - * - * Generated from protobuf field repeated string unreachable = 3; - * @param string[] $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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/LocationMetadata.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/LocationMetadata.php deleted file mode 100644 index a7d4e18c47bd..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/LocationMetadata.php +++ /dev/null @@ -1,69 +0,0 @@ -google.cloud.vmwareengine.v1.LocationMetadata - */ -class LocationMetadata extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. Capabilities of this location. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.LocationMetadata.Capability capabilities = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - private $capabilities; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int[] $capabilities - * Output only. Capabilities of this location. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); - parent::__construct($data); - } - - /** - * Output only. Capabilities of this location. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.LocationMetadata.Capability capabilities = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return RepeatedField - */ - public function getCapabilities() - { - return $this->capabilities; - } - - /** - * Output only. Capabilities of this location. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.LocationMetadata.Capability capabilities = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int[] $var - * @return $this - */ - public function setCapabilities($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\VmwareEngine\V1\LocationMetadata\Capability::class); - $this->capabilities = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/LocationMetadata/Capability.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/LocationMetadata/Capability.php deleted file mode 100644 index 5281e51d1173..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/LocationMetadata/Capability.php +++ /dev/null @@ -1,55 +0,0 @@ -google.cloud.vmwareengine.v1.LocationMetadata.Capability - */ -class Capability -{ - /** - * The default value. This value is used if the capability is omitted or - * unknown. - * - * Generated from protobuf enum CAPABILITY_UNSPECIFIED = 0; - */ - const CAPABILITY_UNSPECIFIED = 0; - /** - * Stretch clusters are supported in this location. - * - * Generated from protobuf enum STRETCHED_CLUSTERS = 1; - */ - const STRETCHED_CLUSTERS = 1; - - private static $valueToName = [ - self::CAPABILITY_UNSPECIFIED => 'CAPABILITY_UNSPECIFIED', - self::STRETCHED_CLUSTERS => 'STRETCHED_CLUSTERS', - ]; - - 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/LoggingServer.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/LoggingServer.php deleted file mode 100644 index 0e8f6b86a56a..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/LoggingServer.php +++ /dev/null @@ -1,349 +0,0 @@ -google.cloud.vmwareengine.v1.LoggingServer - */ -class LoggingServer extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The resource name of this logging server. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/loggingServers/my-logging-server` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * Output only. Creation time of this resource. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. Last update time of this resource. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Required. Fully-qualified domain name (FQDN) or IP Address of the logging - * server. - * - * Generated from protobuf field string hostname = 5 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $hostname = ''; - /** - * Required. Port number at which the logging server receives logs. - * - * Generated from protobuf field int32 port = 7 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $port = 0; - /** - * Required. Protocol used by vCenter to send logs to a logging server. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.LoggingServer.Protocol protocol = 6 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $protocol = 0; - /** - * Required. The type of component that produces logs that will be forwarded - * to this logging server. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.LoggingServer.SourceType source_type = 10 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $source_type = 0; - /** - * Output only. System-generated unique identifier for the resource. - * - * Generated from protobuf field string uid = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $uid = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. The resource name of this logging server. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/loggingServers/my-logging-server` - * @type \Google\Protobuf\Timestamp $create_time - * Output only. Creation time of this resource. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. Last update time of this resource. - * @type string $hostname - * Required. Fully-qualified domain name (FQDN) or IP Address of the logging - * server. - * @type int $port - * Required. Port number at which the logging server receives logs. - * @type int $protocol - * Required. Protocol used by vCenter to send logs to a logging server. - * @type int $source_type - * Required. The type of component that produces logs that will be forwarded - * to this logging server. - * @type string $uid - * Output only. System-generated unique identifier for the resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The resource name of this logging server. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/loggingServers/my-logging-server` - * - * 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 logging server. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/loggingServers/my-logging-server` - * - * 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. Creation time of this resource. - * - * 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 time of this resource. - * - * 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 time of this resource. - * - * 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 time of this resource. - * - * 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; - } - - /** - * Required. Fully-qualified domain name (FQDN) or IP Address of the logging - * server. - * - * Generated from protobuf field string hostname = 5 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getHostname() - { - return $this->hostname; - } - - /** - * Required. Fully-qualified domain name (FQDN) or IP Address of the logging - * server. - * - * Generated from protobuf field string hostname = 5 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setHostname($var) - { - GPBUtil::checkString($var, True); - $this->hostname = $var; - - return $this; - } - - /** - * Required. Port number at which the logging server receives logs. - * - * Generated from protobuf field int32 port = 7 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getPort() - { - return $this->port; - } - - /** - * Required. Port number at which the logging server receives logs. - * - * Generated from protobuf field int32 port = 7 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setPort($var) - { - GPBUtil::checkInt32($var); - $this->port = $var; - - return $this; - } - - /** - * Required. Protocol used by vCenter to send logs to a logging server. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.LoggingServer.Protocol protocol = 6 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getProtocol() - { - return $this->protocol; - } - - /** - * Required. Protocol used by vCenter to send logs to a logging server. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.LoggingServer.Protocol protocol = 6 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setProtocol($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\LoggingServer\Protocol::class); - $this->protocol = $var; - - return $this; - } - - /** - * Required. The type of component that produces logs that will be forwarded - * to this logging server. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.LoggingServer.SourceType source_type = 10 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getSourceType() - { - return $this->source_type; - } - - /** - * Required. The type of component that produces logs that will be forwarded - * to this logging server. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.LoggingServer.SourceType source_type = 10 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setSourceType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\LoggingServer\SourceType::class); - $this->source_type = $var; - - return $this; - } - - /** - * Output only. System-generated unique identifier for the resource. - * - * Generated from protobuf field string uid = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getUid() - { - return $this->uid; - } - - /** - * Output only. System-generated unique identifier for the resource. - * - * Generated from protobuf field string uid = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setUid($var) - { - GPBUtil::checkString($var, True); - $this->uid = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/LoggingServer/Protocol.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/LoggingServer/Protocol.php deleted file mode 100644 index a60562691b80..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/LoggingServer/Protocol.php +++ /dev/null @@ -1,83 +0,0 @@ -google.cloud.vmwareengine.v1.LoggingServer.Protocol - */ -class Protocol -{ - /** - * Unspecified communications protocol. This is the default value. - * - * Generated from protobuf enum PROTOCOL_UNSPECIFIED = 0; - */ - const PROTOCOL_UNSPECIFIED = 0; - /** - * UDP - * - * Generated from protobuf enum UDP = 1; - */ - const UDP = 1; - /** - * TCP - * - * Generated from protobuf enum TCP = 2; - */ - const TCP = 2; - /** - * TLS - * - * Generated from protobuf enum TLS = 3; - */ - const TLS = 3; - /** - * SSL - * - * Generated from protobuf enum SSL = 4; - */ - const SSL = 4; - /** - * RELP - * - * Generated from protobuf enum RELP = 5; - */ - const RELP = 5; - - private static $valueToName = [ - self::PROTOCOL_UNSPECIFIED => 'PROTOCOL_UNSPECIFIED', - self::UDP => 'UDP', - self::TCP => 'TCP', - self::TLS => 'TLS', - self::SSL => 'SSL', - self::RELP => 'RELP', - ]; - - 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/LoggingServer/SourceType.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/LoggingServer/SourceType.php deleted file mode 100644 index 41cf7665c85a..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/LoggingServer/SourceType.php +++ /dev/null @@ -1,61 +0,0 @@ -google.cloud.vmwareengine.v1.LoggingServer.SourceType - */ -class SourceType -{ - /** - * The default value. This value should never be used. - * - * Generated from protobuf enum SOURCE_TYPE_UNSPECIFIED = 0; - */ - const SOURCE_TYPE_UNSPECIFIED = 0; - /** - * Logs produced by ESXI hosts - * - * Generated from protobuf enum ESXI = 1; - */ - const ESXI = 1; - /** - * Logs produced by vCenter server - * - * Generated from protobuf enum VCSA = 2; - */ - const VCSA = 2; - - private static $valueToName = [ - self::SOURCE_TYPE_UNSPECIFIED => 'SOURCE_TYPE_UNSPECIFIED', - self::ESXI => 'ESXI', - self::VCSA => 'VCSA', - ]; - - 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ManagementDnsZoneBinding.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ManagementDnsZoneBinding.php deleted file mode 100644 index 4a48628993fa..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ManagementDnsZoneBinding.php +++ /dev/null @@ -1,370 +0,0 @@ -google.cloud.vmwareengine.v1.ManagementDnsZoneBinding - */ -class ManagementDnsZoneBinding extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The resource name of this binding. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/managementDnsZoneBindings/my-management-dns-zone-binding` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * Output only. Creation time of this resource. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. Last update time of this resource. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Output only. The state of the resource. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.ManagementDnsZoneBinding.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = 0; - /** - * User-provided description for this resource. - * - * Generated from protobuf field string description = 13; - */ - protected $description = ''; - /** - * Output only. System-generated unique identifier for the resource. - * - * Generated from protobuf field string uid = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $uid = ''; - protected $bind_network; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. The resource name of this binding. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/managementDnsZoneBindings/my-management-dns-zone-binding` - * @type \Google\Protobuf\Timestamp $create_time - * Output only. Creation time of this resource. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. Last update time of this resource. - * @type int $state - * Output only. The state of the resource. - * @type string $description - * User-provided description for this resource. - * @type string $vpc_network - * Network to bind is a standard consumer VPC. - * Specify the name in the following form for consumer - * VPC network: `projects/{project}/global/networks/{network_id}`. - * `{project}` can either be a project number or a project ID. - * @type string $vmware_engine_network - * Network to bind is a VMware Engine network. - * Specify the name in the following form for VMware engine network: - * `projects/{project}/locations/global/vmwareEngineNetworks/{vmware_engine_network_id}`. - * `{project}` can either be a project number or a project ID. - * @type string $uid - * Output only. System-generated unique identifier for the resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The resource name of this binding. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/managementDnsZoneBindings/my-management-dns-zone-binding` - * - * 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 binding. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/managementDnsZoneBindings/my-management-dns-zone-binding` - * - * 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. Creation time of this resource. - * - * 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 time of this resource. - * - * 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 time of this resource. - * - * 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 time of this resource. - * - * 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 state of the resource. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.ManagementDnsZoneBinding.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Output only. The state of the resource. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.ManagementDnsZoneBinding.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\ManagementDnsZoneBinding\State::class); - $this->state = $var; - - return $this; - } - - /** - * User-provided description for this resource. - * - * Generated from protobuf field string description = 13; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * User-provided description for this resource. - * - * Generated from protobuf field string description = 13; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * Network to bind is a standard consumer VPC. - * Specify the name in the following form for consumer - * VPC network: `projects/{project}/global/networks/{network_id}`. - * `{project}` can either be a project number or a project ID. - * - * Generated from protobuf field string vpc_network = 14 [(.google.api.resource_reference) = { - * @return string - */ - public function getVpcNetwork() - { - return $this->readOneof(14); - } - - public function hasVpcNetwork() - { - return $this->hasOneof(14); - } - - /** - * Network to bind is a standard consumer VPC. - * Specify the name in the following form for consumer - * VPC network: `projects/{project}/global/networks/{network_id}`. - * `{project}` can either be a project number or a project ID. - * - * Generated from protobuf field string vpc_network = 14 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setVpcNetwork($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(14, $var); - - return $this; - } - - /** - * Network to bind is a VMware Engine network. - * Specify the name in the following form for VMware engine network: - * `projects/{project}/locations/global/vmwareEngineNetworks/{vmware_engine_network_id}`. - * `{project}` can either be a project number or a project ID. - * - * Generated from protobuf field string vmware_engine_network = 15 [(.google.api.resource_reference) = { - * @return string - */ - public function getVmwareEngineNetwork() - { - return $this->readOneof(15); - } - - public function hasVmwareEngineNetwork() - { - return $this->hasOneof(15); - } - - /** - * Network to bind is a VMware Engine network. - * Specify the name in the following form for VMware engine network: - * `projects/{project}/locations/global/vmwareEngineNetworks/{vmware_engine_network_id}`. - * `{project}` can either be a project number or a project ID. - * - * Generated from protobuf field string vmware_engine_network = 15 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setVmwareEngineNetwork($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(15, $var); - - return $this; - } - - /** - * Output only. System-generated unique identifier for the resource. - * - * Generated from protobuf field string uid = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getUid() - { - return $this->uid; - } - - /** - * Output only. System-generated unique identifier for the resource. - * - * Generated from protobuf field string uid = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setUid($var) - { - GPBUtil::checkString($var, True); - $this->uid = $var; - - return $this; - } - - /** - * @return string - */ - public function getBindNetwork() - { - return $this->whichOneof("bind_network"); - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ManagementDnsZoneBinding/State.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ManagementDnsZoneBinding/State.php deleted file mode 100644 index 266e357e393b..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ManagementDnsZoneBinding/State.php +++ /dev/null @@ -1,83 +0,0 @@ -google.cloud.vmwareengine.v1.ManagementDnsZoneBinding.State - */ -class State -{ - /** - * The default value. This value should never be used. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * The binding is ready. - * - * Generated from protobuf enum ACTIVE = 1; - */ - const ACTIVE = 1; - /** - * The binding is being created. - * - * Generated from protobuf enum CREATING = 2; - */ - const CREATING = 2; - /** - * The binding is being updated. - * - * Generated from protobuf enum UPDATING = 3; - */ - const UPDATING = 3; - /** - * The binding is being deleted. - * - * Generated from protobuf enum DELETING = 4; - */ - const DELETING = 4; - /** - * The binding has failed. - * - * Generated from protobuf enum FAILED = 5; - */ - const FAILED = 5; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::ACTIVE => 'ACTIVE', - self::CREATING => 'CREATING', - 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); - } -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkConfig.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkConfig.php deleted file mode 100644 index da1e9832d563..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkConfig.php +++ /dev/null @@ -1,260 +0,0 @@ -google.cloud.vmwareengine.v1.NetworkConfig - */ -class NetworkConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Management CIDR used by VMware management appliances. - * - * Generated from protobuf field string management_cidr = 4 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $management_cidr = ''; - /** - * Optional. The relative resource name of the VMware Engine network attached - * to the private cloud. Specify the name in the following form: - * `projects/{project}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` - * where `{project}` can either be a project number or a project ID. - * - * Generated from protobuf field string vmware_engine_network = 5 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { - */ - protected $vmware_engine_network = ''; - /** - * Output only. The canonical name of the VMware Engine network in the form: - * `projects/{project_number}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` - * - * Generated from protobuf field string vmware_engine_network_canonical = 6 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { - */ - protected $vmware_engine_network_canonical = ''; - /** - * Output only. The IP address layout version of the management IP address - * range. Possible versions include: - * * `managementIpAddressLayoutVersion=1`: Indicates the legacy IP address - * layout used by some existing private clouds. This is no longer supported - * for new private clouds as it does not support all features. - * * `managementIpAddressLayoutVersion=2`: Indicates the latest IP address - * layout used by all newly created private clouds. This version supports all - * current features. - * - * Generated from protobuf field int32 management_ip_address_layout_version = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $management_ip_address_layout_version = 0; - /** - * Output only. DNS Server IP of the Private Cloud. - * All DNS queries can be forwarded to this address for name resolution of - * Private Cloud's management entities like vCenter, NSX-T Manager and - * ESXi hosts. - * - * Generated from protobuf field string dns_server_ip = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $dns_server_ip = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $management_cidr - * Required. Management CIDR used by VMware management appliances. - * @type string $vmware_engine_network - * Optional. The relative resource name of the VMware Engine network attached - * to the private cloud. Specify the name in the following form: - * `projects/{project}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` - * where `{project}` can either be a project number or a project ID. - * @type string $vmware_engine_network_canonical - * Output only. The canonical name of the VMware Engine network in the form: - * `projects/{project_number}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` - * @type int $management_ip_address_layout_version - * Output only. The IP address layout version of the management IP address - * range. Possible versions include: - * * `managementIpAddressLayoutVersion=1`: Indicates the legacy IP address - * layout used by some existing private clouds. This is no longer supported - * for new private clouds as it does not support all features. - * * `managementIpAddressLayoutVersion=2`: Indicates the latest IP address - * layout used by all newly created private clouds. This version supports all - * current features. - * @type string $dns_server_ip - * Output only. DNS Server IP of the Private Cloud. - * All DNS queries can be forwarded to this address for name resolution of - * Private Cloud's management entities like vCenter, NSX-T Manager and - * ESXi hosts. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); - parent::__construct($data); - } - - /** - * Required. Management CIDR used by VMware management appliances. - * - * Generated from protobuf field string management_cidr = 4 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getManagementCidr() - { - return $this->management_cidr; - } - - /** - * Required. Management CIDR used by VMware management appliances. - * - * Generated from protobuf field string management_cidr = 4 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setManagementCidr($var) - { - GPBUtil::checkString($var, True); - $this->management_cidr = $var; - - return $this; - } - - /** - * Optional. The relative resource name of the VMware Engine network attached - * to the private cloud. Specify the name in the following form: - * `projects/{project}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` - * where `{project}` can either be a project number or a project ID. - * - * Generated from protobuf field string vmware_engine_network = 5 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { - * @return string - */ - public function getVmwareEngineNetwork() - { - return $this->vmware_engine_network; - } - - /** - * Optional. The relative resource name of the VMware Engine network attached - * to the private cloud. Specify the name in the following form: - * `projects/{project}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` - * where `{project}` can either be a project number or a project ID. - * - * Generated from protobuf field string vmware_engine_network = 5 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setVmwareEngineNetwork($var) - { - GPBUtil::checkString($var, True); - $this->vmware_engine_network = $var; - - return $this; - } - - /** - * Output only. The canonical name of the VMware Engine network in the form: - * `projects/{project_number}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` - * - * Generated from protobuf field string vmware_engine_network_canonical = 6 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { - * @return string - */ - public function getVmwareEngineNetworkCanonical() - { - return $this->vmware_engine_network_canonical; - } - - /** - * Output only. The canonical name of the VMware Engine network in the form: - * `projects/{project_number}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` - * - * Generated from protobuf field string vmware_engine_network_canonical = 6 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setVmwareEngineNetworkCanonical($var) - { - GPBUtil::checkString($var, True); - $this->vmware_engine_network_canonical = $var; - - return $this; - } - - /** - * Output only. The IP address layout version of the management IP address - * range. Possible versions include: - * * `managementIpAddressLayoutVersion=1`: Indicates the legacy IP address - * layout used by some existing private clouds. This is no longer supported - * for new private clouds as it does not support all features. - * * `managementIpAddressLayoutVersion=2`: Indicates the latest IP address - * layout used by all newly created private clouds. This version supports all - * current features. - * - * Generated from protobuf field int32 management_ip_address_layout_version = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getManagementIpAddressLayoutVersion() - { - return $this->management_ip_address_layout_version; - } - - /** - * Output only. The IP address layout version of the management IP address - * range. Possible versions include: - * * `managementIpAddressLayoutVersion=1`: Indicates the legacy IP address - * layout used by some existing private clouds. This is no longer supported - * for new private clouds as it does not support all features. - * * `managementIpAddressLayoutVersion=2`: Indicates the latest IP address - * layout used by all newly created private clouds. This version supports all - * current features. - * - * Generated from protobuf field int32 management_ip_address_layout_version = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setManagementIpAddressLayoutVersion($var) - { - GPBUtil::checkInt32($var); - $this->management_ip_address_layout_version = $var; - - return $this; - } - - /** - * Output only. DNS Server IP of the Private Cloud. - * All DNS queries can be forwarded to this address for name resolution of - * Private Cloud's management entities like vCenter, NSX-T Manager and - * ESXi hosts. - * - * Generated from protobuf field string dns_server_ip = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getDnsServerIp() - { - return $this->dns_server_ip; - } - - /** - * Output only. DNS Server IP of the Private Cloud. - * All DNS queries can be forwarded to this address for name resolution of - * Private Cloud's management entities like vCenter, NSX-T Manager and - * ESXi hosts. - * - * Generated from protobuf field string dns_server_ip = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setDnsServerIp($var) - { - GPBUtil::checkString($var, True); - $this->dns_server_ip = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPeering.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPeering.php deleted file mode 100644 index 2f041ffc4656..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPeering.php +++ /dev/null @@ -1,775 +0,0 @@ -google.cloud.vmwareengine.v1.NetworkPeering - */ -class NetworkPeering extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The resource name of the network peering. NetworkPeering is a - * global resource and location can only be global. Resource names are - * scheme-less URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/global/networkPeerings/my-peering` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * Output only. Creation time of this resource. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. Last update time of this resource. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Required. The relative resource name of the network to peer with - * a standard VMware Engine network. The provided network can be a - * consumer VPC network or another standard VMware Engine network. If the - * `peer_network_type` is VMWARE_ENGINE_NETWORK, specify the name in the form: - * `projects/{project}/locations/global/vmwareEngineNetworks/{vmware_engine_network_id}`. - * Otherwise specify the name in the form: - * `projects/{project}/global/networks/{network_id}`, where - * `{project}` can either be a project number or a project ID. - * - * Generated from protobuf field string peer_network = 5 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $peer_network = ''; - /** - * Optional. True if custom routes are exported to the peered network; - * false otherwise. The default value is true. - * - * Generated from protobuf field optional bool export_custom_routes = 8 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $export_custom_routes = null; - /** - * Optional. True if custom routes are imported from the peered network; - * false otherwise. The default value is true. - * - * Generated from protobuf field optional bool import_custom_routes = 9 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $import_custom_routes = null; - /** - * Optional. True if full mesh connectivity is created and managed - * automatically between peered networks; false otherwise. Currently this - * field is always true because Google Compute Engine automatically creates - * and manages subnetwork routes between two VPC networks when peering state - * is 'ACTIVE'. - * - * Generated from protobuf field optional bool exchange_subnet_routes = 10 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $exchange_subnet_routes = null; - /** - * Optional. True if all subnet routes with a public IP address range are - * exported; false otherwise. The default value is true. IPv4 special-use - * ranges (https://en.wikipedia.org/wiki/IPv4#Special_addresses) are always - * exported to peers and are not controlled by this field. - * - * Generated from protobuf field optional bool export_custom_routes_with_public_ip = 11 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $export_custom_routes_with_public_ip = null; - /** - * Optional. True if all subnet routes with public IP address range are - * imported; false otherwise. The default value is true. IPv4 special-use - * ranges (https://en.wikipedia.org/wiki/IPv4#Special_addresses) are always - * imported to peers and are not controlled by this field. - * - * Generated from protobuf field optional bool import_custom_routes_with_public_ip = 12 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $import_custom_routes_with_public_ip = null; - /** - * Output only. State of the network peering. This field - * has a value of 'ACTIVE' when there's a matching configuration in the peer - * network. New values may be added to this enum when appropriate. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPeering.State state = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = 0; - /** - * Output only. Output Only. Details about the current state of the network - * peering. - * - * Generated from protobuf field string state_details = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state_details = ''; - /** - * Optional. Maximum transmission unit (MTU) in bytes. - * The default value is `1500`. If a value of `0` is provided for this field, - * VMware Engine uses the default value instead. - * - * Generated from protobuf field int32 peer_mtu = 14 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $peer_mtu = 0; - /** - * Required. The type of the network to peer with the VMware Engine network. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPeering.PeerNetworkType peer_network_type = 16 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $peer_network_type = 0; - /** - * Output only. System-generated unique identifier for the resource. - * - * Generated from protobuf field string uid = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $uid = ''; - /** - * Required. The relative resource name of the VMware Engine network. - * Specify the name in the following form: - * `projects/{project}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` - * where `{project}` can either be a project number or a project ID. - * - * Generated from protobuf field string vmware_engine_network = 20 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $vmware_engine_network = ''; - /** - * Optional. User-provided description for this network peering. - * - * Generated from protobuf field string description = 21 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $description = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. The resource name of the network peering. NetworkPeering is a - * global resource and location can only be global. Resource names are - * scheme-less URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/global/networkPeerings/my-peering` - * @type \Google\Protobuf\Timestamp $create_time - * Output only. Creation time of this resource. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. Last update time of this resource. - * @type string $peer_network - * Required. The relative resource name of the network to peer with - * a standard VMware Engine network. The provided network can be a - * consumer VPC network or another standard VMware Engine network. If the - * `peer_network_type` is VMWARE_ENGINE_NETWORK, specify the name in the form: - * `projects/{project}/locations/global/vmwareEngineNetworks/{vmware_engine_network_id}`. - * Otherwise specify the name in the form: - * `projects/{project}/global/networks/{network_id}`, where - * `{project}` can either be a project number or a project ID. - * @type bool $export_custom_routes - * Optional. True if custom routes are exported to the peered network; - * false otherwise. The default value is true. - * @type bool $import_custom_routes - * Optional. True if custom routes are imported from the peered network; - * false otherwise. The default value is true. - * @type bool $exchange_subnet_routes - * Optional. True if full mesh connectivity is created and managed - * automatically between peered networks; false otherwise. Currently this - * field is always true because Google Compute Engine automatically creates - * and manages subnetwork routes between two VPC networks when peering state - * is 'ACTIVE'. - * @type bool $export_custom_routes_with_public_ip - * Optional. True if all subnet routes with a public IP address range are - * exported; false otherwise. The default value is true. IPv4 special-use - * ranges (https://en.wikipedia.org/wiki/IPv4#Special_addresses) are always - * exported to peers and are not controlled by this field. - * @type bool $import_custom_routes_with_public_ip - * Optional. True if all subnet routes with public IP address range are - * imported; false otherwise. The default value is true. IPv4 special-use - * ranges (https://en.wikipedia.org/wiki/IPv4#Special_addresses) are always - * imported to peers and are not controlled by this field. - * @type int $state - * Output only. State of the network peering. This field - * has a value of 'ACTIVE' when there's a matching configuration in the peer - * network. New values may be added to this enum when appropriate. - * @type string $state_details - * Output only. Output Only. Details about the current state of the network - * peering. - * @type int $peer_mtu - * Optional. Maximum transmission unit (MTU) in bytes. - * The default value is `1500`. If a value of `0` is provided for this field, - * VMware Engine uses the default value instead. - * @type int $peer_network_type - * Required. The type of the network to peer with the VMware Engine network. - * @type string $uid - * Output only. System-generated unique identifier for the resource. - * @type string $vmware_engine_network - * Required. The relative resource name of the VMware Engine network. - * Specify the name in the following form: - * `projects/{project}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` - * where `{project}` can either be a project number or a project ID. - * @type string $description - * Optional. User-provided description for this network peering. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The resource name of the network peering. NetworkPeering is a - * global resource and location can only be global. Resource names are - * scheme-less URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/global/networkPeerings/my-peering` - * - * 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 network peering. NetworkPeering is a - * global resource and location can only be global. Resource names are - * scheme-less URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/global/networkPeerings/my-peering` - * - * 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. Creation time of this resource. - * - * 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 time of this resource. - * - * 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 time of this resource. - * - * 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 time of this resource. - * - * 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; - } - - /** - * Required. The relative resource name of the network to peer with - * a standard VMware Engine network. The provided network can be a - * consumer VPC network or another standard VMware Engine network. If the - * `peer_network_type` is VMWARE_ENGINE_NETWORK, specify the name in the form: - * `projects/{project}/locations/global/vmwareEngineNetworks/{vmware_engine_network_id}`. - * Otherwise specify the name in the form: - * `projects/{project}/global/networks/{network_id}`, where - * `{project}` can either be a project number or a project ID. - * - * Generated from protobuf field string peer_network = 5 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getPeerNetwork() - { - return $this->peer_network; - } - - /** - * Required. The relative resource name of the network to peer with - * a standard VMware Engine network. The provided network can be a - * consumer VPC network or another standard VMware Engine network. If the - * `peer_network_type` is VMWARE_ENGINE_NETWORK, specify the name in the form: - * `projects/{project}/locations/global/vmwareEngineNetworks/{vmware_engine_network_id}`. - * Otherwise specify the name in the form: - * `projects/{project}/global/networks/{network_id}`, where - * `{project}` can either be a project number or a project ID. - * - * Generated from protobuf field string peer_network = 5 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setPeerNetwork($var) - { - GPBUtil::checkString($var, True); - $this->peer_network = $var; - - return $this; - } - - /** - * Optional. True if custom routes are exported to the peered network; - * false otherwise. The default value is true. - * - * Generated from protobuf field optional bool export_custom_routes = 8 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getExportCustomRoutes() - { - return isset($this->export_custom_routes) ? $this->export_custom_routes : false; - } - - public function hasExportCustomRoutes() - { - return isset($this->export_custom_routes); - } - - public function clearExportCustomRoutes() - { - unset($this->export_custom_routes); - } - - /** - * Optional. True if custom routes are exported to the peered network; - * false otherwise. The default value is true. - * - * Generated from protobuf field optional bool export_custom_routes = 8 [(.google.api.field_behavior) = OPTIONAL]; - * @param bool $var - * @return $this - */ - public function setExportCustomRoutes($var) - { - GPBUtil::checkBool($var); - $this->export_custom_routes = $var; - - return $this; - } - - /** - * Optional. True if custom routes are imported from the peered network; - * false otherwise. The default value is true. - * - * Generated from protobuf field optional bool import_custom_routes = 9 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getImportCustomRoutes() - { - return isset($this->import_custom_routes) ? $this->import_custom_routes : false; - } - - public function hasImportCustomRoutes() - { - return isset($this->import_custom_routes); - } - - public function clearImportCustomRoutes() - { - unset($this->import_custom_routes); - } - - /** - * Optional. True if custom routes are imported from the peered network; - * false otherwise. The default value is true. - * - * Generated from protobuf field optional bool import_custom_routes = 9 [(.google.api.field_behavior) = OPTIONAL]; - * @param bool $var - * @return $this - */ - public function setImportCustomRoutes($var) - { - GPBUtil::checkBool($var); - $this->import_custom_routes = $var; - - return $this; - } - - /** - * Optional. True if full mesh connectivity is created and managed - * automatically between peered networks; false otherwise. Currently this - * field is always true because Google Compute Engine automatically creates - * and manages subnetwork routes between two VPC networks when peering state - * is 'ACTIVE'. - * - * Generated from protobuf field optional bool exchange_subnet_routes = 10 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getExchangeSubnetRoutes() - { - return isset($this->exchange_subnet_routes) ? $this->exchange_subnet_routes : false; - } - - public function hasExchangeSubnetRoutes() - { - return isset($this->exchange_subnet_routes); - } - - public function clearExchangeSubnetRoutes() - { - unset($this->exchange_subnet_routes); - } - - /** - * Optional. True if full mesh connectivity is created and managed - * automatically between peered networks; false otherwise. Currently this - * field is always true because Google Compute Engine automatically creates - * and manages subnetwork routes between two VPC networks when peering state - * is 'ACTIVE'. - * - * Generated from protobuf field optional bool exchange_subnet_routes = 10 [(.google.api.field_behavior) = OPTIONAL]; - * @param bool $var - * @return $this - */ - public function setExchangeSubnetRoutes($var) - { - GPBUtil::checkBool($var); - $this->exchange_subnet_routes = $var; - - return $this; - } - - /** - * Optional. True if all subnet routes with a public IP address range are - * exported; false otherwise. The default value is true. IPv4 special-use - * ranges (https://en.wikipedia.org/wiki/IPv4#Special_addresses) are always - * exported to peers and are not controlled by this field. - * - * Generated from protobuf field optional bool export_custom_routes_with_public_ip = 11 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getExportCustomRoutesWithPublicIp() - { - return isset($this->export_custom_routes_with_public_ip) ? $this->export_custom_routes_with_public_ip : false; - } - - public function hasExportCustomRoutesWithPublicIp() - { - return isset($this->export_custom_routes_with_public_ip); - } - - public function clearExportCustomRoutesWithPublicIp() - { - unset($this->export_custom_routes_with_public_ip); - } - - /** - * Optional. True if all subnet routes with a public IP address range are - * exported; false otherwise. The default value is true. IPv4 special-use - * ranges (https://en.wikipedia.org/wiki/IPv4#Special_addresses) are always - * exported to peers and are not controlled by this field. - * - * Generated from protobuf field optional bool export_custom_routes_with_public_ip = 11 [(.google.api.field_behavior) = OPTIONAL]; - * @param bool $var - * @return $this - */ - public function setExportCustomRoutesWithPublicIp($var) - { - GPBUtil::checkBool($var); - $this->export_custom_routes_with_public_ip = $var; - - return $this; - } - - /** - * Optional. True if all subnet routes with public IP address range are - * imported; false otherwise. The default value is true. IPv4 special-use - * ranges (https://en.wikipedia.org/wiki/IPv4#Special_addresses) are always - * imported to peers and are not controlled by this field. - * - * Generated from protobuf field optional bool import_custom_routes_with_public_ip = 12 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getImportCustomRoutesWithPublicIp() - { - return isset($this->import_custom_routes_with_public_ip) ? $this->import_custom_routes_with_public_ip : false; - } - - public function hasImportCustomRoutesWithPublicIp() - { - return isset($this->import_custom_routes_with_public_ip); - } - - public function clearImportCustomRoutesWithPublicIp() - { - unset($this->import_custom_routes_with_public_ip); - } - - /** - * Optional. True if all subnet routes with public IP address range are - * imported; false otherwise. The default value is true. IPv4 special-use - * ranges (https://en.wikipedia.org/wiki/IPv4#Special_addresses) are always - * imported to peers and are not controlled by this field. - * - * Generated from protobuf field optional bool import_custom_routes_with_public_ip = 12 [(.google.api.field_behavior) = OPTIONAL]; - * @param bool $var - * @return $this - */ - public function setImportCustomRoutesWithPublicIp($var) - { - GPBUtil::checkBool($var); - $this->import_custom_routes_with_public_ip = $var; - - return $this; - } - - /** - * Output only. State of the network peering. This field - * has a value of 'ACTIVE' when there's a matching configuration in the peer - * network. New values may be added to this enum when appropriate. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPeering.State state = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Output only. State of the network peering. This field - * has a value of 'ACTIVE' when there's a matching configuration in the peer - * network. New values may be added to this enum when appropriate. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPeering.State state = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\NetworkPeering\State::class); - $this->state = $var; - - return $this; - } - - /** - * Output only. Output Only. Details about the current state of the network - * peering. - * - * Generated from protobuf field string state_details = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getStateDetails() - { - return $this->state_details; - } - - /** - * Output only. Output Only. Details about the current state of the network - * peering. - * - * Generated from protobuf field string state_details = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setStateDetails($var) - { - GPBUtil::checkString($var, True); - $this->state_details = $var; - - return $this; - } - - /** - * Optional. Maximum transmission unit (MTU) in bytes. - * The default value is `1500`. If a value of `0` is provided for this field, - * VMware Engine uses the default value instead. - * - * Generated from protobuf field int32 peer_mtu = 14 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getPeerMtu() - { - return $this->peer_mtu; - } - - /** - * Optional. Maximum transmission unit (MTU) in bytes. - * The default value is `1500`. If a value of `0` is provided for this field, - * VMware Engine uses the default value instead. - * - * Generated from protobuf field int32 peer_mtu = 14 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setPeerMtu($var) - { - GPBUtil::checkInt32($var); - $this->peer_mtu = $var; - - return $this; - } - - /** - * Required. The type of the network to peer with the VMware Engine network. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPeering.PeerNetworkType peer_network_type = 16 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getPeerNetworkType() - { - return $this->peer_network_type; - } - - /** - * Required. The type of the network to peer with the VMware Engine network. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPeering.PeerNetworkType peer_network_type = 16 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setPeerNetworkType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\NetworkPeering\PeerNetworkType::class); - $this->peer_network_type = $var; - - return $this; - } - - /** - * Output only. System-generated unique identifier for the resource. - * - * Generated from protobuf field string uid = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getUid() - { - return $this->uid; - } - - /** - * Output only. System-generated unique identifier for the resource. - * - * Generated from protobuf field string uid = 17 [(.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 relative resource name of the VMware Engine network. - * Specify the name in the following form: - * `projects/{project}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` - * where `{project}` can either be a project number or a project ID. - * - * Generated from protobuf field string vmware_engine_network = 20 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getVmwareEngineNetwork() - { - return $this->vmware_engine_network; - } - - /** - * Required. The relative resource name of the VMware Engine network. - * Specify the name in the following form: - * `projects/{project}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` - * where `{project}` can either be a project number or a project ID. - * - * Generated from protobuf field string vmware_engine_network = 20 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setVmwareEngineNetwork($var) - { - GPBUtil::checkString($var, True); - $this->vmware_engine_network = $var; - - return $this; - } - - /** - * Optional. User-provided description for this network peering. - * - * Generated from protobuf field string description = 21 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * Optional. User-provided description for this network peering. - * - * Generated from protobuf field string description = 21 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPeering/PeerNetworkType.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPeering/PeerNetworkType.php deleted file mode 100644 index d3019ab08ef8..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPeering/PeerNetworkType.php +++ /dev/null @@ -1,101 +0,0 @@ -google.cloud.vmwareengine.v1.NetworkPeering.PeerNetworkType - */ -class PeerNetworkType -{ - /** - * Unspecified - * - * Generated from protobuf enum PEER_NETWORK_TYPE_UNSPECIFIED = 0; - */ - const PEER_NETWORK_TYPE_UNSPECIFIED = 0; - /** - * Peering connection used for connecting to another VPC network established - * by the same user. For example, a peering connection to another VPC - * network in the same project or to an on-premises network. - * - * Generated from protobuf enum STANDARD = 1; - */ - const STANDARD = 1; - /** - * Peering connection used for connecting to another VMware Engine network. - * - * Generated from protobuf enum VMWARE_ENGINE_NETWORK = 2; - */ - const VMWARE_ENGINE_NETWORK = 2; - /** - * Peering connection used for establishing [private services - * access](https://cloud.google.com/vpc/docs/private-services-access). - * - * Generated from protobuf enum PRIVATE_SERVICES_ACCESS = 3; - */ - const PRIVATE_SERVICES_ACCESS = 3; - /** - * Peering connection used for connecting to NetApp Cloud Volumes. - * - * Generated from protobuf enum NETAPP_CLOUD_VOLUMES = 4; - */ - const NETAPP_CLOUD_VOLUMES = 4; - /** - * Peering connection used for connecting to third-party services. Most - * third-party services require manual setup of reverse peering on the VPC - * network associated with the third-party service. - * - * Generated from protobuf enum THIRD_PARTY_SERVICE = 5; - */ - const THIRD_PARTY_SERVICE = 5; - /** - * Peering connection used for connecting to Dell PowerScale Filers - * - * Generated from protobuf enum DELL_POWERSCALE = 6; - */ - const DELL_POWERSCALE = 6; - /** - * Peering connection used for connecting to Google Cloud NetApp Volumes. - * - * Generated from protobuf enum GOOGLE_CLOUD_NETAPP_VOLUMES = 7; - */ - const GOOGLE_CLOUD_NETAPP_VOLUMES = 7; - - private static $valueToName = [ - self::PEER_NETWORK_TYPE_UNSPECIFIED => 'PEER_NETWORK_TYPE_UNSPECIFIED', - self::STANDARD => 'STANDARD', - self::VMWARE_ENGINE_NETWORK => 'VMWARE_ENGINE_NETWORK', - self::PRIVATE_SERVICES_ACCESS => 'PRIVATE_SERVICES_ACCESS', - self::NETAPP_CLOUD_VOLUMES => 'NETAPP_CLOUD_VOLUMES', - self::THIRD_PARTY_SERVICE => 'THIRD_PARTY_SERVICE', - self::DELL_POWERSCALE => 'DELL_POWERSCALE', - self::GOOGLE_CLOUD_NETAPP_VOLUMES => 'GOOGLE_CLOUD_NETAPP_VOLUMES', - ]; - - 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPeering/State.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPeering/State.php deleted file mode 100644 index da07bce71cde..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPeering/State.php +++ /dev/null @@ -1,75 +0,0 @@ -google.cloud.vmwareengine.v1.NetworkPeering.State - */ -class State -{ - /** - * Unspecified network peering state. This is the default value. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * The peering is not active. - * - * Generated from protobuf enum INACTIVE = 1; - */ - const INACTIVE = 1; - /** - * The peering is active. - * - * Generated from protobuf enum ACTIVE = 2; - */ - const ACTIVE = 2; - /** - * The peering is being created. - * - * Generated from protobuf enum CREATING = 3; - */ - const CREATING = 3; - /** - * The peering is being deleted. - * - * Generated from protobuf enum DELETING = 4; - */ - const DELETING = 4; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::INACTIVE => 'INACTIVE', - self::ACTIVE => 'ACTIVE', - self::CREATING => 'CREATING', - 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); - } -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPolicy.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPolicy.php deleted file mode 100644 index d9d552c009e8..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPolicy.php +++ /dev/null @@ -1,470 +0,0 @@ -google.cloud.vmwareengine.v1.NetworkPolicy - */ -class NetworkPolicy extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The resource name of this network policy. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/networkPolicies/my-network-policy` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * Output only. Creation time of this resource. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. Last update time of this resource. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Network service that allows VMware workloads to access the internet. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPolicy.NetworkService internet_access = 6; - */ - protected $internet_access = null; - /** - * Network service that allows External IP addresses to be assigned to VMware - * workloads. This service can only be enabled when `internet_access` is also - * enabled. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPolicy.NetworkService external_ip = 7; - */ - protected $external_ip = null; - /** - * Required. IP address range in CIDR notation used to create internet access - * and external IP access. An RFC 1918 CIDR block, with a "/26" prefix, is - * required. The range cannot overlap with any prefixes either in the consumer - * VPC network or in use by the private clouds attached to that VPC network. - * - * Generated from protobuf field string edge_services_cidr = 9 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $edge_services_cidr = ''; - /** - * Output only. System-generated unique identifier for the resource. - * - * Generated from protobuf field string uid = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $uid = ''; - /** - * Optional. The relative resource name of the VMware Engine network. - * Specify the name in the following form: - * `projects/{project}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` - * where `{project}` can either be a project number or a project ID. - * - * Generated from protobuf field string vmware_engine_network = 12 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { - */ - protected $vmware_engine_network = ''; - /** - * Optional. User-provided description for this network policy. - * - * Generated from protobuf field string description = 13 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $description = ''; - /** - * Output only. The canonical name of the VMware Engine network in the form: - * `projects/{project_number}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` - * - * Generated from protobuf field string vmware_engine_network_canonical = 14 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { - */ - protected $vmware_engine_network_canonical = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. The resource name of this network policy. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/networkPolicies/my-network-policy` - * @type \Google\Protobuf\Timestamp $create_time - * Output only. Creation time of this resource. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. Last update time of this resource. - * @type \Google\Cloud\VmwareEngine\V1\NetworkPolicy\NetworkService $internet_access - * Network service that allows VMware workloads to access the internet. - * @type \Google\Cloud\VmwareEngine\V1\NetworkPolicy\NetworkService $external_ip - * Network service that allows External IP addresses to be assigned to VMware - * workloads. This service can only be enabled when `internet_access` is also - * enabled. - * @type string $edge_services_cidr - * Required. IP address range in CIDR notation used to create internet access - * and external IP access. An RFC 1918 CIDR block, with a "/26" prefix, is - * required. The range cannot overlap with any prefixes either in the consumer - * VPC network or in use by the private clouds attached to that VPC network. - * @type string $uid - * Output only. System-generated unique identifier for the resource. - * @type string $vmware_engine_network - * Optional. The relative resource name of the VMware Engine network. - * Specify the name in the following form: - * `projects/{project}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` - * where `{project}` can either be a project number or a project ID. - * @type string $description - * Optional. User-provided description for this network policy. - * @type string $vmware_engine_network_canonical - * Output only. The canonical name of the VMware Engine network in the form: - * `projects/{project_number}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The resource name of this network policy. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/networkPolicies/my-network-policy` - * - * 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 network policy. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/networkPolicies/my-network-policy` - * - * 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. Creation time of this resource. - * - * 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 time of this resource. - * - * 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 time of this resource. - * - * 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 time of this resource. - * - * 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; - } - - /** - * Network service that allows VMware workloads to access the internet. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPolicy.NetworkService internet_access = 6; - * @return \Google\Cloud\VmwareEngine\V1\NetworkPolicy\NetworkService|null - */ - public function getInternetAccess() - { - return $this->internet_access; - } - - public function hasInternetAccess() - { - return isset($this->internet_access); - } - - public function clearInternetAccess() - { - unset($this->internet_access); - } - - /** - * Network service that allows VMware workloads to access the internet. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPolicy.NetworkService internet_access = 6; - * @param \Google\Cloud\VmwareEngine\V1\NetworkPolicy\NetworkService $var - * @return $this - */ - public function setInternetAccess($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\NetworkPolicy\NetworkService::class); - $this->internet_access = $var; - - return $this; - } - - /** - * Network service that allows External IP addresses to be assigned to VMware - * workloads. This service can only be enabled when `internet_access` is also - * enabled. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPolicy.NetworkService external_ip = 7; - * @return \Google\Cloud\VmwareEngine\V1\NetworkPolicy\NetworkService|null - */ - public function getExternalIp() - { - return $this->external_ip; - } - - public function hasExternalIp() - { - return isset($this->external_ip); - } - - public function clearExternalIp() - { - unset($this->external_ip); - } - - /** - * Network service that allows External IP addresses to be assigned to VMware - * workloads. This service can only be enabled when `internet_access` is also - * enabled. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPolicy.NetworkService external_ip = 7; - * @param \Google\Cloud\VmwareEngine\V1\NetworkPolicy\NetworkService $var - * @return $this - */ - public function setExternalIp($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\NetworkPolicy\NetworkService::class); - $this->external_ip = $var; - - return $this; - } - - /** - * Required. IP address range in CIDR notation used to create internet access - * and external IP access. An RFC 1918 CIDR block, with a "/26" prefix, is - * required. The range cannot overlap with any prefixes either in the consumer - * VPC network or in use by the private clouds attached to that VPC network. - * - * Generated from protobuf field string edge_services_cidr = 9 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getEdgeServicesCidr() - { - return $this->edge_services_cidr; - } - - /** - * Required. IP address range in CIDR notation used to create internet access - * and external IP access. An RFC 1918 CIDR block, with a "/26" prefix, is - * required. The range cannot overlap with any prefixes either in the consumer - * VPC network or in use by the private clouds attached to that VPC network. - * - * Generated from protobuf field string edge_services_cidr = 9 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setEdgeServicesCidr($var) - { - GPBUtil::checkString($var, True); - $this->edge_services_cidr = $var; - - return $this; - } - - /** - * Output only. System-generated unique identifier for the resource. - * - * Generated from protobuf field string uid = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getUid() - { - return $this->uid; - } - - /** - * Output only. System-generated unique identifier for the resource. - * - * Generated from protobuf field string uid = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setUid($var) - { - GPBUtil::checkString($var, True); - $this->uid = $var; - - return $this; - } - - /** - * Optional. The relative resource name of the VMware Engine network. - * Specify the name in the following form: - * `projects/{project}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` - * where `{project}` can either be a project number or a project ID. - * - * Generated from protobuf field string vmware_engine_network = 12 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { - * @return string - */ - public function getVmwareEngineNetwork() - { - return $this->vmware_engine_network; - } - - /** - * Optional. The relative resource name of the VMware Engine network. - * Specify the name in the following form: - * `projects/{project}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` - * where `{project}` can either be a project number or a project ID. - * - * Generated from protobuf field string vmware_engine_network = 12 [(.google.api.field_behavior) = OPTIONAL, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setVmwareEngineNetwork($var) - { - GPBUtil::checkString($var, True); - $this->vmware_engine_network = $var; - - return $this; - } - - /** - * Optional. User-provided description for this network policy. - * - * Generated from protobuf field string description = 13 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * Optional. User-provided description for this network policy. - * - * Generated from protobuf field string description = 13 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * Output only. The canonical name of the VMware Engine network in the form: - * `projects/{project_number}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` - * - * Generated from protobuf field string vmware_engine_network_canonical = 14 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { - * @return string - */ - public function getVmwareEngineNetworkCanonical() - { - return $this->vmware_engine_network_canonical; - } - - /** - * Output only. The canonical name of the VMware Engine network in the form: - * `projects/{project_number}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` - * - * Generated from protobuf field string vmware_engine_network_canonical = 14 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setVmwareEngineNetworkCanonical($var) - { - GPBUtil::checkString($var, True); - $this->vmware_engine_network_canonical = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPolicy/NetworkService.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPolicy/NetworkService.php deleted file mode 100644 index 7c346b1c96a1..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPolicy/NetworkService.php +++ /dev/null @@ -1,109 +0,0 @@ -google.cloud.vmwareengine.v1.NetworkPolicy.NetworkService - */ -class NetworkService extends \Google\Protobuf\Internal\Message -{ - /** - * True if the service is enabled; false otherwise. - * - * Generated from protobuf field bool enabled = 1; - */ - protected $enabled = false; - /** - * Output only. State of the service. New values may be added to this enum - * when appropriate. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPolicy.NetworkService.State state = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type bool $enabled - * True if the service is enabled; false otherwise. - * @type int $state - * Output only. State of the service. New values may be added to this enum - * when appropriate. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); - parent::__construct($data); - } - - /** - * True if the service is enabled; false otherwise. - * - * Generated from protobuf field bool enabled = 1; - * @return bool - */ - public function getEnabled() - { - return $this->enabled; - } - - /** - * True if the service is enabled; false otherwise. - * - * Generated from protobuf field bool enabled = 1; - * @param bool $var - * @return $this - */ - public function setEnabled($var) - { - GPBUtil::checkBool($var); - $this->enabled = $var; - - return $this; - } - - /** - * Output only. State of the service. New values may be added to this enum - * when appropriate. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPolicy.NetworkService.State state = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Output only. State of the service. New values may be added to this enum - * when appropriate. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPolicy.NetworkService.State state = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\NetworkPolicy\NetworkService\State::class); - $this->state = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPolicy/NetworkService/State.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPolicy/NetworkService/State.php deleted file mode 100644 index d6de8dc94e59..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NetworkPolicy/NetworkService/State.php +++ /dev/null @@ -1,69 +0,0 @@ -google.cloud.vmwareengine.v1.NetworkPolicy.NetworkService.State - */ -class State -{ - /** - * Unspecified service state. This is the default value. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * Service is not provisioned. - * - * Generated from protobuf enum UNPROVISIONED = 1; - */ - const UNPROVISIONED = 1; - /** - * Service is in the process of being provisioned/deprovisioned. - * - * Generated from protobuf enum RECONCILING = 2; - */ - const RECONCILING = 2; - /** - * Service is active. - * - * Generated from protobuf enum ACTIVE = 3; - */ - const ACTIVE = 3; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::UNPROVISIONED => 'UNPROVISIONED', - self::RECONCILING => 'RECONCILING', - 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); - } -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Node.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Node.php deleted file mode 100644 index ccd3d2b2e735..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Node.php +++ /dev/null @@ -1,299 +0,0 @@ -google.cloud.vmwareengine.v1.Node - */ -class Node extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The resource name of this node. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster/nodes/my-node - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * Output only. Fully qualified domain name of the node. - * - * Generated from protobuf field string fqdn = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $fqdn = ''; - /** - * Output only. Internal IP address of the node. - * - * Generated from protobuf field string internal_ip = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $internal_ip = ''; - /** - * Output only. The canonical identifier of the node type (corresponds to the - * `NodeType`). - * For example: standard-72. - * - * Generated from protobuf field string node_type_id = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $node_type_id = ''; - /** - * Output only. The version number of the VMware ESXi - * management component in this cluster. - * - * Generated from protobuf field string version = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $version = ''; - /** - * Output only. Customized number of cores - * - * Generated from protobuf field int64 custom_core_count = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $custom_core_count = 0; - /** - * Output only. The state of the appliance. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.Node.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. The resource name of this node. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster/nodes/my-node - * @type string $fqdn - * Output only. Fully qualified domain name of the node. - * @type string $internal_ip - * Output only. Internal IP address of the node. - * @type string $node_type_id - * Output only. The canonical identifier of the node type (corresponds to the - * `NodeType`). - * For example: standard-72. - * @type string $version - * Output only. The version number of the VMware ESXi - * management component in this cluster. - * @type int|string $custom_core_count - * Output only. Customized number of cores - * @type int $state - * Output only. The state of the appliance. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The resource name of this node. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster/nodes/my-node - * - * 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 node. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * projects/my-project/locations/us-central1-a/privateClouds/my-cloud/clusters/my-cluster/nodes/my-node - * - * 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. Fully qualified domain name of the node. - * - * Generated from protobuf field string fqdn = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getFqdn() - { - return $this->fqdn; - } - - /** - * Output only. Fully qualified domain name of the node. - * - * Generated from protobuf field string fqdn = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setFqdn($var) - { - GPBUtil::checkString($var, True); - $this->fqdn = $var; - - return $this; - } - - /** - * Output only. Internal IP address of the node. - * - * Generated from protobuf field string internal_ip = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getInternalIp() - { - return $this->internal_ip; - } - - /** - * Output only. Internal IP address of the node. - * - * Generated from protobuf field string internal_ip = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setInternalIp($var) - { - GPBUtil::checkString($var, True); - $this->internal_ip = $var; - - return $this; - } - - /** - * Output only. The canonical identifier of the node type (corresponds to the - * `NodeType`). - * For example: standard-72. - * - * Generated from protobuf field string node_type_id = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getNodeTypeId() - { - return $this->node_type_id; - } - - /** - * Output only. The canonical identifier of the node type (corresponds to the - * `NodeType`). - * For example: standard-72. - * - * Generated from protobuf field string node_type_id = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setNodeTypeId($var) - { - GPBUtil::checkString($var, True); - $this->node_type_id = $var; - - return $this; - } - - /** - * Output only. The version number of the VMware ESXi - * management component in this cluster. - * - * Generated from protobuf field string version = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getVersion() - { - return $this->version; - } - - /** - * Output only. The version number of the VMware ESXi - * management component in this cluster. - * - * Generated from protobuf field string version = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setVersion($var) - { - GPBUtil::checkString($var, True); - $this->version = $var; - - return $this; - } - - /** - * Output only. Customized number of cores - * - * Generated from protobuf field int64 custom_core_count = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int|string - */ - public function getCustomCoreCount() - { - return $this->custom_core_count; - } - - /** - * Output only. Customized number of cores - * - * Generated from protobuf field int64 custom_core_count = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int|string $var - * @return $this - */ - public function setCustomCoreCount($var) - { - GPBUtil::checkInt64($var); - $this->custom_core_count = $var; - - return $this; - } - - /** - * Output only. The state of the appliance. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.Node.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Output only. The state of the appliance. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.Node.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\Node\State::class); - $this->state = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Node/State.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Node/State.php deleted file mode 100644 index 67a6d5115860..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Node/State.php +++ /dev/null @@ -1,75 +0,0 @@ -google.cloud.vmwareengine.v1.Node.State - */ -class State -{ - /** - * The default value. This value should never be used. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * Node is operational and can be used by the user. - * - * Generated from protobuf enum ACTIVE = 1; - */ - const ACTIVE = 1; - /** - * Node is being provisioned. - * - * Generated from protobuf enum CREATING = 2; - */ - const CREATING = 2; - /** - * Node is in a failed state. - * - * Generated from protobuf enum FAILED = 3; - */ - const FAILED = 3; - /** - * Node is undergoing maintenance, e.g.: during private cloud upgrade. - * - * Generated from protobuf enum UPGRADING = 4; - */ - const UPGRADING = 4; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::ACTIVE => 'ACTIVE', - self::CREATING => 'CREATING', - self::FAILED => 'FAILED', - self::UPGRADING => 'UPGRADING', - ]; - - 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NodeType.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NodeType.php deleted file mode 100644 index 665cf3177190..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NodeType.php +++ /dev/null @@ -1,439 +0,0 @@ -google.cloud.vmwareengine.v1.NodeType - */ -class NodeType extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The resource name of this node type. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-proj/locations/us-central1-a/nodeTypes/standard-72` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * Output only. The canonical identifier of the node type - * (corresponds to the `NodeType`). For example: standard-72. - * - * Generated from protobuf field string node_type_id = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $node_type_id = ''; - /** - * Output only. The friendly name for this node type. - * For example: ve1-standard-72 - * - * Generated from protobuf field string display_name = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $display_name = ''; - /** - * Output only. The total number of virtual CPUs in a single node. - * - * Generated from protobuf field int32 virtual_cpu_count = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $virtual_cpu_count = 0; - /** - * Output only. The total number of CPU cores in a single node. - * - * Generated from protobuf field int32 total_core_count = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $total_core_count = 0; - /** - * Output only. The amount of physical memory available, defined in GB. - * - * Generated from protobuf field int32 memory_gb = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $memory_gb = 0; - /** - * Output only. The amount of storage available, defined in GB. - * - * Generated from protobuf field int32 disk_size_gb = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $disk_size_gb = 0; - /** - * Output only. List of possible values of custom core count. - * - * Generated from protobuf field repeated int32 available_custom_core_counts = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - private $available_custom_core_counts; - /** - * Output only. The type of the resource. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.NodeType.Kind kind = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $kind = 0; - /** - * Output only. Families of the node type. - * For node types to be in the same cluster - * they must share at least one element in the `families`. - * - * Generated from protobuf field repeated string families = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - private $families; - /** - * Output only. Capabilities of this node type. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.NodeType.Capability capabilities = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - private $capabilities; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. The resource name of this node type. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-proj/locations/us-central1-a/nodeTypes/standard-72` - * @type string $node_type_id - * Output only. The canonical identifier of the node type - * (corresponds to the `NodeType`). For example: standard-72. - * @type string $display_name - * Output only. The friendly name for this node type. - * For example: ve1-standard-72 - * @type int $virtual_cpu_count - * Output only. The total number of virtual CPUs in a single node. - * @type int $total_core_count - * Output only. The total number of CPU cores in a single node. - * @type int $memory_gb - * Output only. The amount of physical memory available, defined in GB. - * @type int $disk_size_gb - * Output only. The amount of storage available, defined in GB. - * @type int[] $available_custom_core_counts - * Output only. List of possible values of custom core count. - * @type int $kind - * Output only. The type of the resource. - * @type string[] $families - * Output only. Families of the node type. - * For node types to be in the same cluster - * they must share at least one element in the `families`. - * @type int[] $capabilities - * Output only. Capabilities of this node type. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The resource name of this node type. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-proj/locations/us-central1-a/nodeTypes/standard-72` - * - * 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 node type. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-proj/locations/us-central1-a/nodeTypes/standard-72` - * - * 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 canonical identifier of the node type - * (corresponds to the `NodeType`). For example: standard-72. - * - * Generated from protobuf field string node_type_id = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getNodeTypeId() - { - return $this->node_type_id; - } - - /** - * Output only. The canonical identifier of the node type - * (corresponds to the `NodeType`). For example: standard-72. - * - * Generated from protobuf field string node_type_id = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setNodeTypeId($var) - { - GPBUtil::checkString($var, True); - $this->node_type_id = $var; - - return $this; - } - - /** - * Output only. The friendly name for this node type. - * For example: ve1-standard-72 - * - * Generated from protobuf field string display_name = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * Output only. The friendly name for this node type. - * For example: ve1-standard-72 - * - * Generated from protobuf field string display_name = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->display_name = $var; - - return $this; - } - - /** - * Output only. The total number of virtual CPUs in a single node. - * - * Generated from protobuf field int32 virtual_cpu_count = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getVirtualCpuCount() - { - return $this->virtual_cpu_count; - } - - /** - * Output only. The total number of virtual CPUs in a single node. - * - * Generated from protobuf field int32 virtual_cpu_count = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setVirtualCpuCount($var) - { - GPBUtil::checkInt32($var); - $this->virtual_cpu_count = $var; - - return $this; - } - - /** - * Output only. The total number of CPU cores in a single node. - * - * Generated from protobuf field int32 total_core_count = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getTotalCoreCount() - { - return $this->total_core_count; - } - - /** - * Output only. The total number of CPU cores in a single node. - * - * Generated from protobuf field int32 total_core_count = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setTotalCoreCount($var) - { - GPBUtil::checkInt32($var); - $this->total_core_count = $var; - - return $this; - } - - /** - * Output only. The amount of physical memory available, defined in GB. - * - * Generated from protobuf field int32 memory_gb = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getMemoryGb() - { - return $this->memory_gb; - } - - /** - * Output only. The amount of physical memory available, defined in GB. - * - * Generated from protobuf field int32 memory_gb = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setMemoryGb($var) - { - GPBUtil::checkInt32($var); - $this->memory_gb = $var; - - return $this; - } - - /** - * Output only. The amount of storage available, defined in GB. - * - * Generated from protobuf field int32 disk_size_gb = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getDiskSizeGb() - { - return $this->disk_size_gb; - } - - /** - * Output only. The amount of storage available, defined in GB. - * - * Generated from protobuf field int32 disk_size_gb = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setDiskSizeGb($var) - { - GPBUtil::checkInt32($var); - $this->disk_size_gb = $var; - - return $this; - } - - /** - * Output only. List of possible values of custom core count. - * - * Generated from protobuf field repeated int32 available_custom_core_counts = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return RepeatedField - */ - public function getAvailableCustomCoreCounts() - { - return $this->available_custom_core_counts; - } - - /** - * Output only. List of possible values of custom core count. - * - * Generated from protobuf field repeated int32 available_custom_core_counts = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int[] $var - * @return $this - */ - public function setAvailableCustomCoreCounts($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::INT32); - $this->available_custom_core_counts = $arr; - - return $this; - } - - /** - * Output only. The type of the resource. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.NodeType.Kind kind = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getKind() - { - return $this->kind; - } - - /** - * Output only. The type of the resource. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.NodeType.Kind kind = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setKind($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\NodeType\Kind::class); - $this->kind = $var; - - return $this; - } - - /** - * Output only. Families of the node type. - * For node types to be in the same cluster - * they must share at least one element in the `families`. - * - * Generated from protobuf field repeated string families = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return RepeatedField - */ - public function getFamilies() - { - return $this->families; - } - - /** - * Output only. Families of the node type. - * For node types to be in the same cluster - * they must share at least one element in the `families`. - * - * Generated from protobuf field repeated string families = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string[] $var - * @return $this - */ - public function setFamilies($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->families = $arr; - - return $this; - } - - /** - * Output only. Capabilities of this node type. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.NodeType.Capability capabilities = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return RepeatedField - */ - public function getCapabilities() - { - return $this->capabilities; - } - - /** - * Output only. Capabilities of this node type. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.NodeType.Capability capabilities = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int[] $var - * @return $this - */ - public function setCapabilities($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::ENUM, \Google\Cloud\VmwareEngine\V1\NodeType\Capability::class); - $this->capabilities = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NodeType/Capability.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NodeType/Capability.php deleted file mode 100644 index f01cf73118ce..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NodeType/Capability.php +++ /dev/null @@ -1,55 +0,0 @@ -google.cloud.vmwareengine.v1.NodeType.Capability - */ -class Capability -{ - /** - * The default value. This value is used if the capability is omitted or - * unknown. - * - * Generated from protobuf enum CAPABILITY_UNSPECIFIED = 0; - */ - const CAPABILITY_UNSPECIFIED = 0; - /** - * This node type supports stretch clusters. - * - * Generated from protobuf enum STRETCHED_CLUSTERS = 1; - */ - const STRETCHED_CLUSTERS = 1; - - private static $valueToName = [ - self::CAPABILITY_UNSPECIFIED => 'CAPABILITY_UNSPECIFIED', - self::STRETCHED_CLUSTERS => 'STRETCHED_CLUSTERS', - ]; - - 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NodeType/Kind.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NodeType/Kind.php deleted file mode 100644 index 8dc3c2a8c852..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NodeType/Kind.php +++ /dev/null @@ -1,61 +0,0 @@ -google.cloud.vmwareengine.v1.NodeType.Kind - */ -class Kind -{ - /** - * The default value. This value should never be used. - * - * Generated from protobuf enum KIND_UNSPECIFIED = 0; - */ - const KIND_UNSPECIFIED = 0; - /** - * Standard HCI node. - * - * Generated from protobuf enum STANDARD = 1; - */ - const STANDARD = 1; - /** - * Storage only Node. - * - * Generated from protobuf enum STORAGE_ONLY = 2; - */ - const STORAGE_ONLY = 2; - - private static $valueToName = [ - self::KIND_UNSPECIFIED => 'KIND_UNSPECIFIED', - self::STANDARD => 'STANDARD', - self::STORAGE_ONLY => 'STORAGE_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); - } -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NodeTypeConfig.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NodeTypeConfig.php deleted file mode 100644 index e69b0585e5b7..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/NodeTypeConfig.php +++ /dev/null @@ -1,113 +0,0 @@ -google.cloud.vmwareengine.v1.NodeTypeConfig - */ -class NodeTypeConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The number of nodes of this type in the cluster - * - * Generated from protobuf field int32 node_count = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $node_count = 0; - /** - * Optional. Customized number of cores available to each node of the type. - * This number must always be one of `nodeType.availableCustomCoreCounts`. - * If zero is provided max value from `nodeType.availableCustomCoreCounts` - * will be used. - * - * Generated from protobuf field int32 custom_core_count = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $custom_core_count = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $node_count - * Required. The number of nodes of this type in the cluster - * @type int $custom_core_count - * Optional. Customized number of cores available to each node of the type. - * This number must always be one of `nodeType.availableCustomCoreCounts`. - * If zero is provided max value from `nodeType.availableCustomCoreCounts` - * will be used. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); - parent::__construct($data); - } - - /** - * Required. The number of nodes of this type in the cluster - * - * Generated from protobuf field int32 node_count = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getNodeCount() - { - return $this->node_count; - } - - /** - * Required. The number of nodes of this type in the cluster - * - * Generated from protobuf field int32 node_count = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setNodeCount($var) - { - GPBUtil::checkInt32($var); - $this->node_count = $var; - - return $this; - } - - /** - * Optional. Customized number of cores available to each node of the type. - * This number must always be one of `nodeType.availableCustomCoreCounts`. - * If zero is provided max value from `nodeType.availableCustomCoreCounts` - * will be used. - * - * Generated from protobuf field int32 custom_core_count = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getCustomCoreCount() - { - return $this->custom_core_count; - } - - /** - * Optional. Customized number of cores available to each node of the type. - * This number must always be one of `nodeType.availableCustomCoreCounts`. - * If zero is provided max value from `nodeType.availableCustomCoreCounts` - * will be used. - * - * Generated from protobuf field int32 custom_core_count = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setCustomCoreCount($var) - { - GPBUtil::checkInt32($var); - $this->custom_core_count = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Nsx.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Nsx.php deleted file mode 100644 index 8527b1083f52..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Nsx.php +++ /dev/null @@ -1,169 +0,0 @@ -google.cloud.vmwareengine.v1.Nsx - */ -class Nsx extends \Google\Protobuf\Internal\Message -{ - /** - * Internal IP address of the appliance. - * - * Generated from protobuf field string internal_ip = 2; - */ - protected $internal_ip = ''; - /** - * Version of the appliance. - * - * Generated from protobuf field string version = 4; - */ - protected $version = ''; - /** - * Output only. The state of the appliance. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.Nsx.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = 0; - /** - * Fully qualified domain name of the appliance. - * - * Generated from protobuf field string fqdn = 6; - */ - protected $fqdn = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $internal_ip - * Internal IP address of the appliance. - * @type string $version - * Version of the appliance. - * @type int $state - * Output only. The state of the appliance. - * @type string $fqdn - * Fully qualified domain name of the appliance. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); - parent::__construct($data); - } - - /** - * Internal IP address of the appliance. - * - * Generated from protobuf field string internal_ip = 2; - * @return string - */ - public function getInternalIp() - { - return $this->internal_ip; - } - - /** - * Internal IP address of the appliance. - * - * Generated from protobuf field string internal_ip = 2; - * @param string $var - * @return $this - */ - public function setInternalIp($var) - { - GPBUtil::checkString($var, True); - $this->internal_ip = $var; - - return $this; - } - - /** - * Version of the appliance. - * - * Generated from protobuf field string version = 4; - * @return string - */ - public function getVersion() - { - return $this->version; - } - - /** - * Version of the appliance. - * - * Generated from protobuf field string version = 4; - * @param string $var - * @return $this - */ - public function setVersion($var) - { - GPBUtil::checkString($var, True); - $this->version = $var; - - return $this; - } - - /** - * Output only. The state of the appliance. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.Nsx.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Output only. The state of the appliance. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.Nsx.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\Nsx\State::class); - $this->state = $var; - - return $this; - } - - /** - * Fully qualified domain name of the appliance. - * - * Generated from protobuf field string fqdn = 6; - * @return string - */ - public function getFqdn() - { - return $this->fqdn; - } - - /** - * Fully qualified domain name of the appliance. - * - * Generated from protobuf field string fqdn = 6; - * @param string $var - * @return $this - */ - public function setFqdn($var) - { - GPBUtil::checkString($var, True); - $this->fqdn = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Nsx/State.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Nsx/State.php deleted file mode 100644 index 9993128a8f71..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Nsx/State.php +++ /dev/null @@ -1,61 +0,0 @@ -google.cloud.vmwareengine.v1.Nsx.State - */ -class State -{ - /** - * Unspecified appliance state. This is the default value. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * The appliance is operational and can be used. - * - * Generated from protobuf enum ACTIVE = 1; - */ - const ACTIVE = 1; - /** - * The appliance is being deployed. - * - * Generated from protobuf enum CREATING = 2; - */ - const CREATING = 2; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::ACTIVE => 'ACTIVE', - self::CREATING => 'CREATING', - ]; - - 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/OperationMetadata.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/OperationMetadata.php deleted file mode 100644 index 3cf2dca10ff5..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/OperationMetadata.php +++ /dev/null @@ -1,311 +0,0 @@ -google.cloud.vmwareengine.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. True if the user has requested cancellation - * of the operation; false otherwise. - * 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. True if the user has requested cancellation - * of the operation; false otherwise. - * 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\Vmwareengine\V1\Vmwareengine::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. True if the user has requested cancellation - * of the operation; false otherwise. - * 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. True if the user has requested cancellation - * of the operation; false otherwise. - * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PeeringRoute.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PeeringRoute.php deleted file mode 100644 index b3b461952293..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PeeringRoute.php +++ /dev/null @@ -1,273 +0,0 @@ -google.cloud.vmwareengine.v1.PeeringRoute - */ -class PeeringRoute extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. Destination range of the peering route in CIDR notation. - * - * Generated from protobuf field string dest_range = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $dest_range = ''; - /** - * Output only. Type of the route in the peer VPC network. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.PeeringRoute.Type type = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $type = 0; - /** - * Output only. Region containing the next hop of the peering route. This - * field only applies to dynamic routes in the peer VPC network. - * - * Generated from protobuf field string next_hop_region = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $next_hop_region = ''; - /** - * Output only. The priority of the peering route. - * - * Generated from protobuf field int64 priority = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $priority = 0; - /** - * Output only. True if the peering route has been imported from a peered - * VPC network; false otherwise. The import happens if the field - * `NetworkPeering.importCustomRoutes` is true for this network, - * `NetworkPeering.exportCustomRoutes` is true for the peer VPC network, and - * the import does not result in a route conflict. - * - * Generated from protobuf field bool imported = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $imported = false; - /** - * Output only. Direction of the routes exchanged with the peer network, from - * the VMware Engine network perspective: - * * Routes of direction `INCOMING` are imported from the peer network. - * * Routes of direction `OUTGOING` are exported from the intranet VPC network - * of the VMware Engine network. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.PeeringRoute.Direction direction = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $direction = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $dest_range - * Output only. Destination range of the peering route in CIDR notation. - * @type int $type - * Output only. Type of the route in the peer VPC network. - * @type string $next_hop_region - * Output only. Region containing the next hop of the peering route. This - * field only applies to dynamic routes in the peer VPC network. - * @type int|string $priority - * Output only. The priority of the peering route. - * @type bool $imported - * Output only. True if the peering route has been imported from a peered - * VPC network; false otherwise. The import happens if the field - * `NetworkPeering.importCustomRoutes` is true for this network, - * `NetworkPeering.exportCustomRoutes` is true for the peer VPC network, and - * the import does not result in a route conflict. - * @type int $direction - * Output only. Direction of the routes exchanged with the peer network, from - * the VMware Engine network perspective: - * * Routes of direction `INCOMING` are imported from the peer network. - * * Routes of direction `OUTGOING` are exported from the intranet VPC network - * of the VMware Engine network. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); - parent::__construct($data); - } - - /** - * Output only. Destination range of the peering route in CIDR notation. - * - * Generated from protobuf field string dest_range = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getDestRange() - { - return $this->dest_range; - } - - /** - * Output only. Destination range of the peering route in CIDR notation. - * - * Generated from protobuf field string dest_range = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setDestRange($var) - { - GPBUtil::checkString($var, True); - $this->dest_range = $var; - - return $this; - } - - /** - * Output only. Type of the route in the peer VPC network. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.PeeringRoute.Type type = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getType() - { - return $this->type; - } - - /** - * Output only. Type of the route in the peer VPC network. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.PeeringRoute.Type type = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\PeeringRoute\Type::class); - $this->type = $var; - - return $this; - } - - /** - * Output only. Region containing the next hop of the peering route. This - * field only applies to dynamic routes in the peer VPC network. - * - * Generated from protobuf field string next_hop_region = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getNextHopRegion() - { - return $this->next_hop_region; - } - - /** - * Output only. Region containing the next hop of the peering route. This - * field only applies to dynamic routes in the peer VPC network. - * - * Generated from protobuf field string next_hop_region = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setNextHopRegion($var) - { - GPBUtil::checkString($var, True); - $this->next_hop_region = $var; - - return $this; - } - - /** - * Output only. The priority of the peering route. - * - * Generated from protobuf field int64 priority = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int|string - */ - public function getPriority() - { - return $this->priority; - } - - /** - * Output only. The priority of the peering route. - * - * Generated from protobuf field int64 priority = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int|string $var - * @return $this - */ - public function setPriority($var) - { - GPBUtil::checkInt64($var); - $this->priority = $var; - - return $this; - } - - /** - * Output only. True if the peering route has been imported from a peered - * VPC network; false otherwise. The import happens if the field - * `NetworkPeering.importCustomRoutes` is true for this network, - * `NetworkPeering.exportCustomRoutes` is true for the peer VPC network, and - * the import does not result in a route conflict. - * - * Generated from protobuf field bool imported = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return bool - */ - public function getImported() - { - return $this->imported; - } - - /** - * Output only. True if the peering route has been imported from a peered - * VPC network; false otherwise. The import happens if the field - * `NetworkPeering.importCustomRoutes` is true for this network, - * `NetworkPeering.exportCustomRoutes` is true for the peer VPC network, and - * the import does not result in a route conflict. - * - * Generated from protobuf field bool imported = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param bool $var - * @return $this - */ - public function setImported($var) - { - GPBUtil::checkBool($var); - $this->imported = $var; - - return $this; - } - - /** - * Output only. Direction of the routes exchanged with the peer network, from - * the VMware Engine network perspective: - * * Routes of direction `INCOMING` are imported from the peer network. - * * Routes of direction `OUTGOING` are exported from the intranet VPC network - * of the VMware Engine network. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.PeeringRoute.Direction direction = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getDirection() - { - return $this->direction; - } - - /** - * Output only. Direction of the routes exchanged with the peer network, from - * the VMware Engine network perspective: - * * Routes of direction `INCOMING` are imported from the peer network. - * * Routes of direction `OUTGOING` are exported from the intranet VPC network - * of the VMware Engine network. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.PeeringRoute.Direction direction = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setDirection($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\PeeringRoute\Direction::class); - $this->direction = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PeeringRoute/Direction.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PeeringRoute/Direction.php deleted file mode 100644 index 23cd5efbf13c..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PeeringRoute/Direction.php +++ /dev/null @@ -1,61 +0,0 @@ -google.cloud.vmwareengine.v1.PeeringRoute.Direction - */ -class Direction -{ - /** - * Unspecified exchanged routes direction. This is default. - * - * Generated from protobuf enum DIRECTION_UNSPECIFIED = 0; - */ - const DIRECTION_UNSPECIFIED = 0; - /** - * Routes imported from the peer network. - * - * Generated from protobuf enum INCOMING = 1; - */ - const INCOMING = 1; - /** - * Routes exported to the peer network. - * - * Generated from protobuf enum OUTGOING = 2; - */ - const OUTGOING = 2; - - private static $valueToName = [ - self::DIRECTION_UNSPECIFIED => 'DIRECTION_UNSPECIFIED', - self::INCOMING => 'INCOMING', - self::OUTGOING => 'OUTGOING', - ]; - - 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PeeringRoute/Type.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PeeringRoute/Type.php deleted file mode 100644 index 60e15b1025ff..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PeeringRoute/Type.php +++ /dev/null @@ -1,69 +0,0 @@ -google.cloud.vmwareengine.v1.PeeringRoute.Type - */ -class Type -{ - /** - * Unspecified peering route type. This is the default value. - * - * Generated from protobuf enum TYPE_UNSPECIFIED = 0; - */ - const TYPE_UNSPECIFIED = 0; - /** - * Dynamic routes in the peer network. - * - * Generated from protobuf enum DYNAMIC_PEERING_ROUTE = 1; - */ - const DYNAMIC_PEERING_ROUTE = 1; - /** - * Static routes in the peer network. - * - * Generated from protobuf enum STATIC_PEERING_ROUTE = 2; - */ - const STATIC_PEERING_ROUTE = 2; - /** - * Created, updated, and removed automatically by Google Cloud when subnets - * are created, modified, or deleted in the peer network. - * - * Generated from protobuf enum SUBNET_PEERING_ROUTE = 3; - */ - const SUBNET_PEERING_ROUTE = 3; - - private static $valueToName = [ - self::TYPE_UNSPECIFIED => 'TYPE_UNSPECIFIED', - self::DYNAMIC_PEERING_ROUTE => 'DYNAMIC_PEERING_ROUTE', - self::STATIC_PEERING_ROUTE => 'STATIC_PEERING_ROUTE', - self::SUBNET_PEERING_ROUTE => 'SUBNET_PEERING_ROUTE', - ]; - - 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Principal.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Principal.php deleted file mode 100644 index 7eb8388e7217..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Principal.php +++ /dev/null @@ -1,109 +0,0 @@ -google.cloud.vmwareengine.v1.Principal - */ -class Principal extends \Google\Protobuf\Internal\Message -{ - protected $principal; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $user - * The user who needs to be granted permission. - * @type string $service_account - * The service account which needs to be granted the permission. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); - parent::__construct($data); - } - - /** - * The user who needs to be granted permission. - * - * Generated from protobuf field string user = 1; - * @return string - */ - public function getUser() - { - return $this->readOneof(1); - } - - public function hasUser() - { - return $this->hasOneof(1); - } - - /** - * The user who needs to be granted permission. - * - * Generated from protobuf field string user = 1; - * @param string $var - * @return $this - */ - public function setUser($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * The service account which needs to be granted the permission. - * - * Generated from protobuf field string service_account = 2; - * @return string - */ - public function getServiceAccount() - { - return $this->readOneof(2); - } - - public function hasServiceAccount() - { - return $this->hasOneof(2); - } - - /** - * The service account which needs to be granted the permission. - * - * Generated from protobuf field string service_account = 2; - * @param string $var - * @return $this - */ - public function setServiceAccount($var) - { - GPBUtil::checkString($var, True); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * @return string - */ - public function getPrincipal() - { - return $this->whichOneof("principal"); - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateCloud.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateCloud.php deleted file mode 100644 index 978f9d15a52a..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateCloud.php +++ /dev/null @@ -1,637 +0,0 @@ -google.cloud.vmwareengine.v1.PrivateCloud - */ -class PrivateCloud extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The resource name of this private cloud. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * Output only. Creation time of this resource. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. Last update time of this resource. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Output only. Time when the resource was scheduled for deletion. - * - * Generated from protobuf field .google.protobuf.Timestamp delete_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $delete_time = null; - /** - * Output only. Time when the resource will be irreversibly deleted. - * - * Generated from protobuf field .google.protobuf.Timestamp expire_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $expire_time = null; - /** - * Output only. State of the resource. New values may be added to this enum - * when appropriate. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateCloud.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = 0; - /** - * Required. Network configuration of the private cloud. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkConfig network_config = 9 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $network_config = null; - /** - * Required. Input only. The management cluster for this private cloud. - * This field is required during creation of the private cloud to provide - * details for the default cluster. - * The following fields can't be changed after private cloud creation: - * `ManagementCluster.clusterId`, `ManagementCluster.nodeTypeId`. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateCloud.ManagementCluster management_cluster = 10 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = REQUIRED]; - */ - protected $management_cluster = null; - /** - * User-provided description for this private cloud. - * - * Generated from protobuf field string description = 11; - */ - protected $description = ''; - /** - * Output only. HCX appliance. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.Hcx hcx = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $hcx = null; - /** - * Output only. NSX appliance. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.Nsx nsx = 18 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $nsx = null; - /** - * Output only. Vcenter appliance. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.Vcenter vcenter = 19 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $vcenter = null; - /** - * Output only. System-generated unique identifier for the resource. - * - * Generated from protobuf field string uid = 20 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $uid = ''; - /** - * Optional. Type of the private cloud. Defaults to STANDARD. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateCloud.Type type = 22 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $type = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. The resource name of this private cloud. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * @type \Google\Protobuf\Timestamp $create_time - * Output only. Creation time of this resource. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. Last update time of this resource. - * @type \Google\Protobuf\Timestamp $delete_time - * Output only. Time when the resource was scheduled for deletion. - * @type \Google\Protobuf\Timestamp $expire_time - * Output only. Time when the resource will be irreversibly deleted. - * @type int $state - * Output only. State of the resource. New values may be added to this enum - * when appropriate. - * @type \Google\Cloud\VmwareEngine\V1\NetworkConfig $network_config - * Required. Network configuration of the private cloud. - * @type \Google\Cloud\VmwareEngine\V1\PrivateCloud\ManagementCluster $management_cluster - * Required. Input only. The management cluster for this private cloud. - * This field is required during creation of the private cloud to provide - * details for the default cluster. - * The following fields can't be changed after private cloud creation: - * `ManagementCluster.clusterId`, `ManagementCluster.nodeTypeId`. - * @type string $description - * User-provided description for this private cloud. - * @type \Google\Cloud\VmwareEngine\V1\Hcx $hcx - * Output only. HCX appliance. - * @type \Google\Cloud\VmwareEngine\V1\Nsx $nsx - * Output only. NSX appliance. - * @type \Google\Cloud\VmwareEngine\V1\Vcenter $vcenter - * Output only. Vcenter appliance. - * @type string $uid - * Output only. System-generated unique identifier for the resource. - * @type int $type - * Optional. Type of the private cloud. Defaults to STANDARD. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The resource name of this private cloud. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * 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 private cloud. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * 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. Creation time of this resource. - * - * 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 time of this resource. - * - * 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 time of this resource. - * - * 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 time of this resource. - * - * 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. Time when the resource was scheduled for deletion. - * - * Generated from protobuf field .google.protobuf.Timestamp delete_time = 4 [(.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 when the resource was scheduled for deletion. - * - * Generated from protobuf field .google.protobuf.Timestamp delete_time = 4 [(.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. Time when the resource will be irreversibly deleted. - * - * Generated from protobuf field .google.protobuf.Timestamp expire_time = 5 [(.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. Time when the resource will be irreversibly deleted. - * - * Generated from protobuf field .google.protobuf.Timestamp expire_time = 5 [(.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. State of the resource. New values may be added to this enum - * when appropriate. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateCloud.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Output only. State of the resource. New values may be added to this enum - * when appropriate. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateCloud.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\PrivateCloud\State::class); - $this->state = $var; - - return $this; - } - - /** - * Required. Network configuration of the private cloud. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkConfig network_config = 9 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\VmwareEngine\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); - } - - /** - * Required. Network configuration of the private cloud. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkConfig network_config = 9 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\VmwareEngine\V1\NetworkConfig $var - * @return $this - */ - public function setNetworkConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\NetworkConfig::class); - $this->network_config = $var; - - return $this; - } - - /** - * Required. Input only. The management cluster for this private cloud. - * This field is required during creation of the private cloud to provide - * details for the default cluster. - * The following fields can't be changed after private cloud creation: - * `ManagementCluster.clusterId`, `ManagementCluster.nodeTypeId`. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateCloud.ManagementCluster management_cluster = 10 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\VmwareEngine\V1\PrivateCloud\ManagementCluster|null - */ - public function getManagementCluster() - { - return $this->management_cluster; - } - - public function hasManagementCluster() - { - return isset($this->management_cluster); - } - - public function clearManagementCluster() - { - unset($this->management_cluster); - } - - /** - * Required. Input only. The management cluster for this private cloud. - * This field is required during creation of the private cloud to provide - * details for the default cluster. - * The following fields can't be changed after private cloud creation: - * `ManagementCluster.clusterId`, `ManagementCluster.nodeTypeId`. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateCloud.ManagementCluster management_cluster = 10 [(.google.api.field_behavior) = INPUT_ONLY, (.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\VmwareEngine\V1\PrivateCloud\ManagementCluster $var - * @return $this - */ - public function setManagementCluster($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\PrivateCloud\ManagementCluster::class); - $this->management_cluster = $var; - - return $this; - } - - /** - * User-provided description for this private cloud. - * - * Generated from protobuf field string description = 11; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * User-provided description for this private cloud. - * - * Generated from protobuf field string description = 11; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * Output only. HCX appliance. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.Hcx hcx = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Cloud\VmwareEngine\V1\Hcx|null - */ - public function getHcx() - { - return $this->hcx; - } - - public function hasHcx() - { - return isset($this->hcx); - } - - public function clearHcx() - { - unset($this->hcx); - } - - /** - * Output only. HCX appliance. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.Hcx hcx = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\VmwareEngine\V1\Hcx $var - * @return $this - */ - public function setHcx($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\Hcx::class); - $this->hcx = $var; - - return $this; - } - - /** - * Output only. NSX appliance. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.Nsx nsx = 18 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Cloud\VmwareEngine\V1\Nsx|null - */ - public function getNsx() - { - return $this->nsx; - } - - public function hasNsx() - { - return isset($this->nsx); - } - - public function clearNsx() - { - unset($this->nsx); - } - - /** - * Output only. NSX appliance. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.Nsx nsx = 18 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\VmwareEngine\V1\Nsx $var - * @return $this - */ - public function setNsx($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\Nsx::class); - $this->nsx = $var; - - return $this; - } - - /** - * Output only. Vcenter appliance. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.Vcenter vcenter = 19 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Cloud\VmwareEngine\V1\Vcenter|null - */ - public function getVcenter() - { - return $this->vcenter; - } - - public function hasVcenter() - { - return isset($this->vcenter); - } - - public function clearVcenter() - { - unset($this->vcenter); - } - - /** - * Output only. Vcenter appliance. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.Vcenter vcenter = 19 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\VmwareEngine\V1\Vcenter $var - * @return $this - */ - public function setVcenter($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\Vcenter::class); - $this->vcenter = $var; - - return $this; - } - - /** - * Output only. System-generated unique identifier for the resource. - * - * Generated from protobuf field string uid = 20 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getUid() - { - return $this->uid; - } - - /** - * Output only. System-generated unique identifier for the resource. - * - * Generated from protobuf field string uid = 20 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setUid($var) - { - GPBUtil::checkString($var, True); - $this->uid = $var; - - return $this; - } - - /** - * Optional. Type of the private cloud. Defaults to STANDARD. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateCloud.Type type = 22 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getType() - { - return $this->type; - } - - /** - * Optional. Type of the private cloud. Defaults to STANDARD. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateCloud.Type type = 22 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\PrivateCloud\Type::class); - $this->type = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateCloud/ManagementCluster.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateCloud/ManagementCluster.php deleted file mode 100644 index 04ac33651a47..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateCloud/ManagementCluster.php +++ /dev/null @@ -1,181 +0,0 @@ -google.cloud.vmwareengine.v1.PrivateCloud.ManagementCluster - */ -class ManagementCluster extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The user-provided identifier of the new `Cluster`. - * The identifier must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC - * 1034](https://datatracker.ietf.org/doc/html/rfc1034) (section 3.5) - * - * Generated from protobuf field string cluster_id = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $cluster_id = ''; - /** - * Required. The map of cluster node types in this cluster, where the key is - * canonical identifier of the node type (corresponds to the `NodeType`). - * - * Generated from protobuf field map node_type_configs = 7 [(.google.api.field_behavior) = REQUIRED]; - */ - private $node_type_configs; - /** - * Optional. Configuration of a stretched cluster. Required for STRETCHED - * private clouds. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.StretchedClusterConfig stretched_cluster_config = 8 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $stretched_cluster_config = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $cluster_id - * Required. The user-provided identifier of the new `Cluster`. - * The identifier must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC - * 1034](https://datatracker.ietf.org/doc/html/rfc1034) (section 3.5) - * @type array|\Google\Protobuf\Internal\MapField $node_type_configs - * Required. The map of cluster node types in this cluster, where the key is - * canonical identifier of the node type (corresponds to the `NodeType`). - * @type \Google\Cloud\VmwareEngine\V1\StretchedClusterConfig $stretched_cluster_config - * Optional. Configuration of a stretched cluster. Required for STRETCHED - * private clouds. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); - parent::__construct($data); - } - - /** - * Required. The user-provided identifier of the new `Cluster`. - * The identifier must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC - * 1034](https://datatracker.ietf.org/doc/html/rfc1034) (section 3.5) - * - * Generated from protobuf field string cluster_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getClusterId() - { - return $this->cluster_id; - } - - /** - * Required. The user-provided identifier of the new `Cluster`. - * The identifier must meet the following requirements: - * * Only contains 1-63 alphanumeric characters and hyphens - * * Begins with an alphabetical character - * * Ends with a non-hyphen character - * * Not formatted as a UUID - * * Complies with [RFC - * 1034](https://datatracker.ietf.org/doc/html/rfc1034) (section 3.5) - * - * Generated from protobuf field string cluster_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setClusterId($var) - { - GPBUtil::checkString($var, True); - $this->cluster_id = $var; - - return $this; - } - - /** - * Required. The map of cluster node types in this cluster, where the key is - * canonical identifier of the node type (corresponds to the `NodeType`). - * - * Generated from protobuf field map node_type_configs = 7 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Protobuf\Internal\MapField - */ - public function getNodeTypeConfigs() - { - return $this->node_type_configs; - } - - /** - * Required. The map of cluster node types in this cluster, where the key is - * canonical identifier of the node type (corresponds to the `NodeType`). - * - * Generated from protobuf field map node_type_configs = 7 [(.google.api.field_behavior) = REQUIRED]; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setNodeTypeConfigs($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\NodeTypeConfig::class); - $this->node_type_configs = $arr; - - return $this; - } - - /** - * Optional. Configuration of a stretched cluster. Required for STRETCHED - * private clouds. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.StretchedClusterConfig stretched_cluster_config = 8 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\VmwareEngine\V1\StretchedClusterConfig|null - */ - public function getStretchedClusterConfig() - { - return $this->stretched_cluster_config; - } - - public function hasStretchedClusterConfig() - { - return isset($this->stretched_cluster_config); - } - - public function clearStretchedClusterConfig() - { - unset($this->stretched_cluster_config); - } - - /** - * Optional. Configuration of a stretched cluster. Required for STRETCHED - * private clouds. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.StretchedClusterConfig stretched_cluster_config = 8 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\VmwareEngine\V1\StretchedClusterConfig $var - * @return $this - */ - public function setStretchedClusterConfig($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\StretchedClusterConfig::class); - $this->stretched_cluster_config = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateCloud/State.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateCloud/State.php deleted file mode 100644 index 4d9eedfbdb73..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateCloud/State.php +++ /dev/null @@ -1,91 +0,0 @@ -google.cloud.vmwareengine.v1.PrivateCloud.State - */ -class State -{ - /** - * The default value. This value should never be used. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * The private cloud is ready. - * - * Generated from protobuf enum ACTIVE = 1; - */ - const ACTIVE = 1; - /** - * The private cloud is being created. - * - * Generated from protobuf enum CREATING = 2; - */ - const CREATING = 2; - /** - * The private cloud is being updated. - * - * Generated from protobuf enum UPDATING = 3; - */ - const UPDATING = 3; - /** - * The private cloud is in failed state. - * - * Generated from protobuf enum FAILED = 5; - */ - const FAILED = 5; - /** - * The private cloud is scheduled for deletion. The deletion process can be - * cancelled by using the corresponding undelete method. - * - * Generated from protobuf enum DELETED = 6; - */ - const DELETED = 6; - /** - * The private cloud is irreversibly deleted and is being removed from the - * system. - * - * Generated from protobuf enum PURGING = 7; - */ - const PURGING = 7; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::ACTIVE => 'ACTIVE', - self::CREATING => 'CREATING', - self::UPDATING => 'UPDATING', - self::FAILED => 'FAILED', - self::DELETED => 'DELETED', - self::PURGING => 'PURGING', - ]; - - 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateCloud/Type.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateCloud/Type.php deleted file mode 100644 index 12765c323a8e..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateCloud/Type.php +++ /dev/null @@ -1,65 +0,0 @@ -google.cloud.vmwareengine.v1.PrivateCloud.Type - */ -class Type -{ - /** - * Standard private is a zonal resource, with 3+ nodes. Default type. - * - * Generated from protobuf enum STANDARD = 0; - */ - const STANDARD = 0; - /** - * Time limited private cloud is a zonal resource, can have only 1 node and - * has limited life span. Will be deleted after defined period of time, - * can be converted into standard private cloud by expanding it up to 3 - * or more nodes. - * - * Generated from protobuf enum TIME_LIMITED = 1; - */ - const TIME_LIMITED = 1; - /** - * Stretched private cloud is a regional resource with redundancy, - * with a minimum of 6 nodes, nodes count has to be even. - * - * Generated from protobuf enum STRETCHED = 2; - */ - const STRETCHED = 2; - - private static $valueToName = [ - self::STANDARD => 'STANDARD', - self::TIME_LIMITED => 'TIME_LIMITED', - self::STRETCHED => 'STRETCHED', - ]; - - 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateConnection.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateConnection.php deleted file mode 100644 index 5ee125dfa695..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateConnection.php +++ /dev/null @@ -1,604 +0,0 @@ -google.cloud.vmwareengine.v1.PrivateConnection - */ -class PrivateConnection extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The resource name of the private connection. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/privateConnections/my-connection` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * Output only. Creation time of this resource. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. Last update time of this resource. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Optional. User-provided description for this private connection. - * - * Generated from protobuf field string description = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $description = ''; - /** - * Output only. State of the private connection. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateConnection.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = 0; - /** - * Required. The relative resource name of Legacy VMware Engine network. - * Specify the name in the following form: - * `projects/{project}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` - * where `{project}`, `{location}` will be same as specified in private - * connection resource name and `{vmware_engine_network_id}` will be in the - * form of `{location}`-default e.g. - * projects/project/locations/us-central1/vmwareEngineNetworks/us-central1-default. - * - * Generated from protobuf field string vmware_engine_network = 8 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $vmware_engine_network = ''; - /** - * Output only. The canonical name of the VMware Engine network in the form: - * `projects/{project_number}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` - * - * Generated from protobuf field string vmware_engine_network_canonical = 9 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { - */ - protected $vmware_engine_network_canonical = ''; - /** - * Required. Private connection type. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateConnection.Type type = 10 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $type = 0; - /** - * Output only. VPC network peering id between given network VPC and - * VMwareEngineNetwork. - * - * Generated from protobuf field string peering_id = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $peering_id = ''; - /** - * Optional. Routing Mode. - * Default value is set to GLOBAL. - * For type = PRIVATE_SERVICE_ACCESS, this field can be set to GLOBAL or - * REGIONAL, for other types only GLOBAL is supported. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateConnection.RoutingMode routing_mode = 13 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $routing_mode = 0; - /** - * Output only. System-generated unique identifier for the resource. - * - * Generated from protobuf field string uid = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $uid = ''; - /** - * Required. Service network to create private connection. - * Specify the name in the following form: - * `projects/{project}/global/networks/{network_id}` - * For type = PRIVATE_SERVICE_ACCESS, this field represents servicenetworking - * VPC, e.g. projects/project-tp/global/networks/servicenetworking. - * For type = NETAPP_CLOUD_VOLUME, this field represents NetApp service VPC, - * e.g. projects/project-tp/global/networks/netapp-tenant-vpc. - * For type = DELL_POWERSCALE, this field represent Dell service VPC, e.g. - * projects/project-tp/global/networks/dell-tenant-vpc. - * For type= THIRD_PARTY_SERVICE, this field could represent a consumer VPC or - * any other producer VPC to which the VMware Engine Network needs to be - * connected, e.g. projects/project/global/networks/vpc. - * - * Generated from protobuf field string service_network = 16 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $service_network = ''; - /** - * Output only. Peering state between service network and VMware Engine - * network. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateConnection.PeeringState peering_state = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $peering_state = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. The resource name of the private connection. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/privateConnections/my-connection` - * @type \Google\Protobuf\Timestamp $create_time - * Output only. Creation time of this resource. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. Last update time of this resource. - * @type string $description - * Optional. User-provided description for this private connection. - * @type int $state - * Output only. State of the private connection. - * @type string $vmware_engine_network - * Required. The relative resource name of Legacy VMware Engine network. - * Specify the name in the following form: - * `projects/{project}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` - * where `{project}`, `{location}` will be same as specified in private - * connection resource name and `{vmware_engine_network_id}` will be in the - * form of `{location}`-default e.g. - * projects/project/locations/us-central1/vmwareEngineNetworks/us-central1-default. - * @type string $vmware_engine_network_canonical - * Output only. The canonical name of the VMware Engine network in the form: - * `projects/{project_number}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` - * @type int $type - * Required. Private connection type. - * @type string $peering_id - * Output only. VPC network peering id between given network VPC and - * VMwareEngineNetwork. - * @type int $routing_mode - * Optional. Routing Mode. - * Default value is set to GLOBAL. - * For type = PRIVATE_SERVICE_ACCESS, this field can be set to GLOBAL or - * REGIONAL, for other types only GLOBAL is supported. - * @type string $uid - * Output only. System-generated unique identifier for the resource. - * @type string $service_network - * Required. Service network to create private connection. - * Specify the name in the following form: - * `projects/{project}/global/networks/{network_id}` - * For type = PRIVATE_SERVICE_ACCESS, this field represents servicenetworking - * VPC, e.g. projects/project-tp/global/networks/servicenetworking. - * For type = NETAPP_CLOUD_VOLUME, this field represents NetApp service VPC, - * e.g. projects/project-tp/global/networks/netapp-tenant-vpc. - * For type = DELL_POWERSCALE, this field represent Dell service VPC, e.g. - * projects/project-tp/global/networks/dell-tenant-vpc. - * For type= THIRD_PARTY_SERVICE, this field could represent a consumer VPC or - * any other producer VPC to which the VMware Engine Network needs to be - * connected, e.g. projects/project/global/networks/vpc. - * @type int $peering_state - * Output only. Peering state between service network and VMware Engine - * network. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The resource name of the private connection. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/privateConnections/my-connection` - * - * 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 private connection. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1/privateConnections/my-connection` - * - * 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. Creation time of this resource. - * - * 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 time of this resource. - * - * 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 time of this resource. - * - * 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 time of this resource. - * - * 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 description for this private connection. - * - * Generated from protobuf field string description = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * Optional. User-provided description for this private connection. - * - * Generated from protobuf field string description = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * Output only. State of the private connection. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateConnection.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Output only. State of the private connection. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateConnection.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\PrivateConnection\State::class); - $this->state = $var; - - return $this; - } - - /** - * Required. The relative resource name of Legacy VMware Engine network. - * Specify the name in the following form: - * `projects/{project}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` - * where `{project}`, `{location}` will be same as specified in private - * connection resource name and `{vmware_engine_network_id}` will be in the - * form of `{location}`-default e.g. - * projects/project/locations/us-central1/vmwareEngineNetworks/us-central1-default. - * - * Generated from protobuf field string vmware_engine_network = 8 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getVmwareEngineNetwork() - { - return $this->vmware_engine_network; - } - - /** - * Required. The relative resource name of Legacy VMware Engine network. - * Specify the name in the following form: - * `projects/{project}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` - * where `{project}`, `{location}` will be same as specified in private - * connection resource name and `{vmware_engine_network_id}` will be in the - * form of `{location}`-default e.g. - * projects/project/locations/us-central1/vmwareEngineNetworks/us-central1-default. - * - * Generated from protobuf field string vmware_engine_network = 8 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setVmwareEngineNetwork($var) - { - GPBUtil::checkString($var, True); - $this->vmware_engine_network = $var; - - return $this; - } - - /** - * Output only. The canonical name of the VMware Engine network in the form: - * `projects/{project_number}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` - * - * Generated from protobuf field string vmware_engine_network_canonical = 9 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { - * @return string - */ - public function getVmwareEngineNetworkCanonical() - { - return $this->vmware_engine_network_canonical; - } - - /** - * Output only. The canonical name of the VMware Engine network in the form: - * `projects/{project_number}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network_id}` - * - * Generated from protobuf field string vmware_engine_network_canonical = 9 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setVmwareEngineNetworkCanonical($var) - { - GPBUtil::checkString($var, True); - $this->vmware_engine_network_canonical = $var; - - return $this; - } - - /** - * Required. Private connection type. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateConnection.Type type = 10 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getType() - { - return $this->type; - } - - /** - * Required. Private connection type. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateConnection.Type type = 10 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\PrivateConnection\Type::class); - $this->type = $var; - - return $this; - } - - /** - * Output only. VPC network peering id between given network VPC and - * VMwareEngineNetwork. - * - * Generated from protobuf field string peering_id = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getPeeringId() - { - return $this->peering_id; - } - - /** - * Output only. VPC network peering id between given network VPC and - * VMwareEngineNetwork. - * - * Generated from protobuf field string peering_id = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setPeeringId($var) - { - GPBUtil::checkString($var, True); - $this->peering_id = $var; - - return $this; - } - - /** - * Optional. Routing Mode. - * Default value is set to GLOBAL. - * For type = PRIVATE_SERVICE_ACCESS, this field can be set to GLOBAL or - * REGIONAL, for other types only GLOBAL is supported. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateConnection.RoutingMode routing_mode = 13 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getRoutingMode() - { - return $this->routing_mode; - } - - /** - * Optional. Routing Mode. - * Default value is set to GLOBAL. - * For type = PRIVATE_SERVICE_ACCESS, this field can be set to GLOBAL or - * REGIONAL, for other types only GLOBAL is supported. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateConnection.RoutingMode routing_mode = 13 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setRoutingMode($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\PrivateConnection\RoutingMode::class); - $this->routing_mode = $var; - - return $this; - } - - /** - * Output only. System-generated unique identifier for the resource. - * - * Generated from protobuf field string uid = 14 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getUid() - { - return $this->uid; - } - - /** - * Output only. System-generated unique identifier for the resource. - * - * Generated from protobuf field string uid = 14 [(.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. Service network to create private connection. - * Specify the name in the following form: - * `projects/{project}/global/networks/{network_id}` - * For type = PRIVATE_SERVICE_ACCESS, this field represents servicenetworking - * VPC, e.g. projects/project-tp/global/networks/servicenetworking. - * For type = NETAPP_CLOUD_VOLUME, this field represents NetApp service VPC, - * e.g. projects/project-tp/global/networks/netapp-tenant-vpc. - * For type = DELL_POWERSCALE, this field represent Dell service VPC, e.g. - * projects/project-tp/global/networks/dell-tenant-vpc. - * For type= THIRD_PARTY_SERVICE, this field could represent a consumer VPC or - * any other producer VPC to which the VMware Engine Network needs to be - * connected, e.g. projects/project/global/networks/vpc. - * - * Generated from protobuf field string service_network = 16 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getServiceNetwork() - { - return $this->service_network; - } - - /** - * Required. Service network to create private connection. - * Specify the name in the following form: - * `projects/{project}/global/networks/{network_id}` - * For type = PRIVATE_SERVICE_ACCESS, this field represents servicenetworking - * VPC, e.g. projects/project-tp/global/networks/servicenetworking. - * For type = NETAPP_CLOUD_VOLUME, this field represents NetApp service VPC, - * e.g. projects/project-tp/global/networks/netapp-tenant-vpc. - * For type = DELL_POWERSCALE, this field represent Dell service VPC, e.g. - * projects/project-tp/global/networks/dell-tenant-vpc. - * For type= THIRD_PARTY_SERVICE, this field could represent a consumer VPC or - * any other producer VPC to which the VMware Engine Network needs to be - * connected, e.g. projects/project/global/networks/vpc. - * - * Generated from protobuf field string service_network = 16 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setServiceNetwork($var) - { - GPBUtil::checkString($var, True); - $this->service_network = $var; - - return $this; - } - - /** - * Output only. Peering state between service network and VMware Engine - * network. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateConnection.PeeringState peering_state = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getPeeringState() - { - return $this->peering_state; - } - - /** - * Output only. Peering state between service network and VMware Engine - * network. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateConnection.PeeringState peering_state = 17 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setPeeringState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\PrivateConnection\PeeringState::class); - $this->peering_state = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateConnection/PeeringState.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateConnection/PeeringState.php deleted file mode 100644 index 611bf6fa8853..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateConnection/PeeringState.php +++ /dev/null @@ -1,63 +0,0 @@ -google.cloud.vmwareengine.v1.PrivateConnection.PeeringState - */ -class PeeringState -{ - /** - * The default value. This value is used if the peering state is omitted or - * unknown. - * - * Generated from protobuf enum PEERING_STATE_UNSPECIFIED = 0; - */ - const PEERING_STATE_UNSPECIFIED = 0; - /** - * The peering is in active state. - * - * Generated from protobuf enum PEERING_ACTIVE = 1; - */ - const PEERING_ACTIVE = 1; - /** - * The peering is in inactive state. - * - * Generated from protobuf enum PEERING_INACTIVE = 2; - */ - const PEERING_INACTIVE = 2; - - private static $valueToName = [ - self::PEERING_STATE_UNSPECIFIED => 'PEERING_STATE_UNSPECIFIED', - self::PEERING_ACTIVE => 'PEERING_ACTIVE', - self::PEERING_INACTIVE => 'PEERING_INACTIVE', - ]; - - 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateConnection/RoutingMode.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateConnection/RoutingMode.php deleted file mode 100644 index da082ba9590f..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateConnection/RoutingMode.php +++ /dev/null @@ -1,65 +0,0 @@ -google.cloud.vmwareengine.v1.PrivateConnection.RoutingMode - */ -class RoutingMode -{ - /** - * The default value. This value should never be used. - * - * Generated from protobuf enum ROUTING_MODE_UNSPECIFIED = 0; - */ - const ROUTING_MODE_UNSPECIFIED = 0; - /** - * Global Routing Mode - * - * Generated from protobuf enum GLOBAL = 1; - */ - const PBGLOBAL = 1; - /** - * Regional Routing Mode - * - * Generated from protobuf enum REGIONAL = 2; - */ - const REGIONAL = 2; - - private static $valueToName = [ - self::ROUTING_MODE_UNSPECIFIED => 'ROUTING_MODE_UNSPECIFIED', - self::PBGLOBAL => 'GLOBAL', - self::REGIONAL => 'REGIONAL', - ]; - - 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); - } -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateConnection/State.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateConnection/State.php deleted file mode 100644 index 8a495a9ed4ee..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateConnection/State.php +++ /dev/null @@ -1,90 +0,0 @@ -google.cloud.vmwareengine.v1.PrivateConnection.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 private connection is being created. - * - * Generated from protobuf enum CREATING = 1; - */ - const CREATING = 1; - /** - * The private connection is ready. - * - * Generated from protobuf enum ACTIVE = 2; - */ - const ACTIVE = 2; - /** - * The private connection is being updated. - * - * Generated from protobuf enum UPDATING = 3; - */ - const UPDATING = 3; - /** - * The private connection is being deleted. - * - * Generated from protobuf enum DELETING = 4; - */ - const DELETING = 4; - /** - * The private connection is not provisioned, since no private cloud is - * present for which this private connection is needed. - * - * Generated from protobuf enum UNPROVISIONED = 5; - */ - const UNPROVISIONED = 5; - /** - * The private connection is in failed state. - * - * Generated from protobuf enum FAILED = 6; - */ - const FAILED = 6; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::CREATING => 'CREATING', - self::ACTIVE => 'ACTIVE', - self::UPDATING => 'UPDATING', - self::DELETING => 'DELETING', - self::UNPROVISIONED => 'UNPROVISIONED', - 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); - } -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateConnection/Type.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateConnection/Type.php deleted file mode 100644 index f69dcc844e7a..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/PrivateConnection/Type.php +++ /dev/null @@ -1,76 +0,0 @@ -google.cloud.vmwareengine.v1.PrivateConnection.Type - */ -class Type -{ - /** - * The default value. This value should never be used. - * - * Generated from protobuf enum TYPE_UNSPECIFIED = 0; - */ - const TYPE_UNSPECIFIED = 0; - /** - * Connection used for establishing [private services - * access](https://cloud.google.com/vpc/docs/private-services-access). - * - * Generated from protobuf enum PRIVATE_SERVICE_ACCESS = 1; - */ - const PRIVATE_SERVICE_ACCESS = 1; - /** - * Connection used for connecting to NetApp Cloud Volumes. - * - * Generated from protobuf enum NETAPP_CLOUD_VOLUMES = 2; - */ - const NETAPP_CLOUD_VOLUMES = 2; - /** - * Connection used for connecting to Dell PowerScale. - * - * Generated from protobuf enum DELL_POWERSCALE = 3; - */ - const DELL_POWERSCALE = 3; - /** - * Connection used for connecting to third-party services. - * - * Generated from protobuf enum THIRD_PARTY_SERVICE = 4; - */ - const THIRD_PARTY_SERVICE = 4; - - private static $valueToName = [ - self::TYPE_UNSPECIFIED => 'TYPE_UNSPECIFIED', - self::PRIVATE_SERVICE_ACCESS => 'PRIVATE_SERVICE_ACCESS', - self::NETAPP_CLOUD_VOLUMES => 'NETAPP_CLOUD_VOLUMES', - self::DELL_POWERSCALE => 'DELL_POWERSCALE', - self::THIRD_PARTY_SERVICE => 'THIRD_PARTY_SERVICE', - ]; - - 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/RepairManagementDnsZoneBindingRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/RepairManagementDnsZoneBindingRequest.php deleted file mode 100644 index 2ffb1f84dae5..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/RepairManagementDnsZoneBindingRequest.php +++ /dev/null @@ -1,179 +0,0 @@ -google.cloud.vmwareengine.v1.RepairManagementDnsZoneBindingRequest - */ -class RepairManagementDnsZoneBindingRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the management DNS zone binding to repair. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/managementDnsZoneBindings/my-management-dns-zone-binding` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 the 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 = ''; - - /** - * @param string $name Required. The resource name of the management DNS zone binding to repair. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/managementDnsZoneBindings/my-management-dns-zone-binding` - * Please see {@see VmwareEngineClient::managementDnsZoneBindingName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\RepairManagementDnsZoneBindingRequest - * - * @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 management DNS zone binding to repair. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/managementDnsZoneBindings/my-management-dns-zone-binding` - * @type string $request_id - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 the 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\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the management DNS zone binding to repair. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/managementDnsZoneBindings/my-management-dns-zone-binding` - * - * 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 management DNS zone binding to repair. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/managementDnsZoneBindings/my-management-dns-zone-binding` - * - * 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. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 the 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. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 the 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; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ResetNsxCredentialsRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ResetNsxCredentialsRequest.php deleted file mode 100644 index 9b7312ac0f3b..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ResetNsxCredentialsRequest.php +++ /dev/null @@ -1,185 +0,0 @@ -google.cloud.vmwareengine.v1.ResetNsxCredentialsRequest - */ -class ResetNsxCredentialsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the private cloud - * to reset credentials for. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * Generated from protobuf field string private_cloud = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $private_cloud = ''; - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $request_id = ''; - - /** - * @param string $privateCloud Required. The resource name of the private cloud - * to reset credentials for. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * Please see {@see VmwareEngineClient::privateCloudName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\ResetNsxCredentialsRequest - * - * @experimental - */ - public static function build(string $privateCloud): self - { - return (new self()) - ->setPrivateCloud($privateCloud); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $private_cloud - * Required. The resource name of the private cloud - * to reset credentials for. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * @type string $request_id - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the private cloud - * to reset credentials for. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * Generated from protobuf field string private_cloud = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getPrivateCloud() - { - return $this->private_cloud; - } - - /** - * Required. The resource name of the private cloud - * to reset credentials for. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * Generated from protobuf field string private_cloud = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setPrivateCloud($var) - { - GPBUtil::checkString($var, True); - $this->private_cloud = $var; - - return $this; - } - - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 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; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ResetVcenterCredentialsRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ResetVcenterCredentialsRequest.php deleted file mode 100644 index 6d297c139b99..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ResetVcenterCredentialsRequest.php +++ /dev/null @@ -1,251 +0,0 @@ -google.cloud.vmwareengine.v1.ResetVcenterCredentialsRequest - */ -class ResetVcenterCredentialsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the private cloud - * to reset credentials for. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * Generated from protobuf field string private_cloud = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $private_cloud = ''; - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $request_id = ''; - /** - * Optional. The username of the user to be to reset the credentials. - * The default value of this field is CloudOwner\@gve.local. - * The provided value should be one of the following: - * solution-user-01\@gve.local, - * solution-user-02\@gve.local, - * solution-user-03\@gve.local, - * solution-user-04\@gve.local, - * solution-user-05\@gve.local, - * zertoadmin\@gve.local. - * - * Generated from protobuf field string username = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $username = ''; - - /** - * @param string $privateCloud Required. The resource name of the private cloud - * to reset credentials for. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * Please see {@see VmwareEngineClient::privateCloudName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\ResetVcenterCredentialsRequest - * - * @experimental - */ - public static function build(string $privateCloud): self - { - return (new self()) - ->setPrivateCloud($privateCloud); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $private_cloud - * Required. The resource name of the private cloud - * to reset credentials for. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * @type string $request_id - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 string $username - * Optional. The username of the user to be to reset the credentials. - * The default value of this field is CloudOwner\@gve.local. - * The provided value should be one of the following: - * solution-user-01\@gve.local, - * solution-user-02\@gve.local, - * solution-user-03\@gve.local, - * solution-user-04\@gve.local, - * solution-user-05\@gve.local, - * zertoadmin\@gve.local. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the private cloud - * to reset credentials for. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * Generated from protobuf field string private_cloud = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getPrivateCloud() - { - return $this->private_cloud; - } - - /** - * Required. The resource name of the private cloud - * to reset credentials for. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * Generated from protobuf field string private_cloud = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setPrivateCloud($var) - { - GPBUtil::checkString($var, True); - $this->private_cloud = $var; - - return $this; - } - - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 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. The username of the user to be to reset the credentials. - * The default value of this field is CloudOwner\@gve.local. - * The provided value should be one of the following: - * solution-user-01\@gve.local, - * solution-user-02\@gve.local, - * solution-user-03\@gve.local, - * solution-user-04\@gve.local, - * solution-user-05\@gve.local, - * zertoadmin\@gve.local. - * - * Generated from protobuf field string username = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getUsername() - { - return $this->username; - } - - /** - * Optional. The username of the user to be to reset the credentials. - * The default value of this field is CloudOwner\@gve.local. - * The provided value should be one of the following: - * solution-user-01\@gve.local, - * solution-user-02\@gve.local, - * solution-user-03\@gve.local, - * solution-user-04\@gve.local, - * solution-user-05\@gve.local, - * zertoadmin\@gve.local. - * - * Generated from protobuf field string username = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setUsername($var) - { - GPBUtil::checkString($var, True); - $this->username = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/RevokeDnsBindPermissionRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/RevokeDnsBindPermissionRequest.php deleted file mode 100644 index 17821053a5d5..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/RevokeDnsBindPermissionRequest.php +++ /dev/null @@ -1,241 +0,0 @@ -google.cloud.vmwareengine.v1.RevokeDnsBindPermissionRequest - */ -class RevokeDnsBindPermissionRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The name of the resource which stores the users/service accounts - * having the permission to bind to the corresponding intranet VPC of the - * consumer project. DnsBindPermission is a global resource. Resource names - * are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. For example: - * `projects/my-project/locations/global/dnsBindPermission` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Required. The consumer provided user/service account which needs to be - * granted permission to bind with the intranet VPC corresponding to the - * consumer project. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.Principal principal = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $principal = null; - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $request_id = ''; - - /** - * @param string $name Required. The name of the resource which stores the users/service accounts - * having the permission to bind to the corresponding intranet VPC of the - * consumer project. DnsBindPermission is a global resource. Resource names - * are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. For example: - * `projects/my-project/locations/global/dnsBindPermission` - * Please see {@see VmwareEngineClient::dnsBindPermissionName()} for help formatting this field. - * @param \Google\Cloud\VmwareEngine\V1\Principal $principal Required. The consumer provided user/service account which needs to be - * granted permission to bind with the intranet VPC corresponding to the - * consumer project. - * - * @return \Google\Cloud\VmwareEngine\V1\RevokeDnsBindPermissionRequest - * - * @experimental - */ - public static function build(string $name, \Google\Cloud\VmwareEngine\V1\Principal $principal): self - { - return (new self()) - ->setName($name) - ->setPrincipal($principal); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The name of the resource which stores the users/service accounts - * having the permission to bind to the corresponding intranet VPC of the - * consumer project. DnsBindPermission is a global resource. Resource names - * are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. For example: - * `projects/my-project/locations/global/dnsBindPermission` - * @type \Google\Cloud\VmwareEngine\V1\Principal $principal - * Required. The consumer provided user/service account which needs to be - * granted permission to bind with the intranet VPC corresponding to the - * consumer project. - * @type string $request_id - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The name of the resource which stores the users/service accounts - * having the permission to bind to the corresponding intranet VPC of the - * consumer project. DnsBindPermission is a global resource. Resource names - * are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. For example: - * `projects/my-project/locations/global/dnsBindPermission` - * - * 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 resource which stores the users/service accounts - * having the permission to bind to the corresponding intranet VPC of the - * consumer project. DnsBindPermission is a global resource. Resource names - * are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. For example: - * `projects/my-project/locations/global/dnsBindPermission` - * - * 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 consumer provided user/service account which needs to be - * granted permission to bind with the intranet VPC corresponding to the - * consumer project. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.Principal principal = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\VmwareEngine\V1\Principal|null - */ - public function getPrincipal() - { - return $this->principal; - } - - public function hasPrincipal() - { - return isset($this->principal); - } - - public function clearPrincipal() - { - unset($this->principal); - } - - /** - * Required. The consumer provided user/service account which needs to be - * granted permission to bind with the intranet VPC corresponding to the - * consumer project. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.Principal principal = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\VmwareEngine\V1\Principal $var - * @return $this - */ - public function setPrincipal($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\Principal::class); - $this->principal = $var; - - return $this; - } - - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 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; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ShowNsxCredentialsRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ShowNsxCredentialsRequest.php deleted file mode 100644 index 9b21d7406f66..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ShowNsxCredentialsRequest.php +++ /dev/null @@ -1,107 +0,0 @@ -google.cloud.vmwareengine.v1.ShowNsxCredentialsRequest - */ -class ShowNsxCredentialsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the private cloud - * to be queried for credentials. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * Generated from protobuf field string private_cloud = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $private_cloud = ''; - - /** - * @param string $privateCloud Required. The resource name of the private cloud - * to be queried for credentials. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * Please see {@see VmwareEngineClient::privateCloudName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\ShowNsxCredentialsRequest - * - * @experimental - */ - public static function build(string $privateCloud): self - { - return (new self()) - ->setPrivateCloud($privateCloud); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $private_cloud - * Required. The resource name of the private cloud - * to be queried for credentials. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the private cloud - * to be queried for credentials. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * Generated from protobuf field string private_cloud = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getPrivateCloud() - { - return $this->private_cloud; - } - - /** - * Required. The resource name of the private cloud - * to be queried for credentials. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * Generated from protobuf field string private_cloud = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setPrivateCloud($var) - { - GPBUtil::checkString($var, True); - $this->private_cloud = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ShowVcenterCredentialsRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ShowVcenterCredentialsRequest.php deleted file mode 100644 index 2ad8e46ca47c..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/ShowVcenterCredentialsRequest.php +++ /dev/null @@ -1,177 +0,0 @@ -google.cloud.vmwareengine.v1.ShowVcenterCredentialsRequest - */ -class ShowVcenterCredentialsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the private cloud - * to be queried for credentials. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * Generated from protobuf field string private_cloud = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $private_cloud = ''; - /** - * Optional. The username of the user to be queried for credentials. - * The default value of this field is CloudOwner\@gve.local. - * The provided value must be one of the following: - * CloudOwner\@gve.local, - * solution-user-01\@gve.local, - * solution-user-02\@gve.local, - * solution-user-03\@gve.local, - * solution-user-04\@gve.local, - * solution-user-05\@gve.local, - * zertoadmin\@gve.local. - * - * Generated from protobuf field string username = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $username = ''; - - /** - * @param string $privateCloud Required. The resource name of the private cloud - * to be queried for credentials. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * Please see {@see VmwareEngineClient::privateCloudName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\ShowVcenterCredentialsRequest - * - * @experimental - */ - public static function build(string $privateCloud): self - { - return (new self()) - ->setPrivateCloud($privateCloud); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $private_cloud - * Required. The resource name of the private cloud - * to be queried for credentials. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * @type string $username - * Optional. The username of the user to be queried for credentials. - * The default value of this field is CloudOwner\@gve.local. - * The provided value must be one of the following: - * CloudOwner\@gve.local, - * solution-user-01\@gve.local, - * solution-user-02\@gve.local, - * solution-user-03\@gve.local, - * solution-user-04\@gve.local, - * solution-user-05\@gve.local, - * zertoadmin\@gve.local. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the private cloud - * to be queried for credentials. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * Generated from protobuf field string private_cloud = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getPrivateCloud() - { - return $this->private_cloud; - } - - /** - * Required. The resource name of the private cloud - * to be queried for credentials. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * Generated from protobuf field string private_cloud = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setPrivateCloud($var) - { - GPBUtil::checkString($var, True); - $this->private_cloud = $var; - - return $this; - } - - /** - * Optional. The username of the user to be queried for credentials. - * The default value of this field is CloudOwner\@gve.local. - * The provided value must be one of the following: - * CloudOwner\@gve.local, - * solution-user-01\@gve.local, - * solution-user-02\@gve.local, - * solution-user-03\@gve.local, - * solution-user-04\@gve.local, - * solution-user-05\@gve.local, - * zertoadmin\@gve.local. - * - * Generated from protobuf field string username = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getUsername() - { - return $this->username; - } - - /** - * Optional. The username of the user to be queried for credentials. - * The default value of this field is CloudOwner\@gve.local. - * The provided value must be one of the following: - * CloudOwner\@gve.local, - * solution-user-01\@gve.local, - * solution-user-02\@gve.local, - * solution-user-03\@gve.local, - * solution-user-04\@gve.local, - * solution-user-05\@gve.local, - * zertoadmin\@gve.local. - * - * Generated from protobuf field string username = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setUsername($var) - { - GPBUtil::checkString($var, True); - $this->username = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/StretchedClusterConfig.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/StretchedClusterConfig.php deleted file mode 100644 index 088a2fdc96c8..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/StretchedClusterConfig.php +++ /dev/null @@ -1,133 +0,0 @@ -google.cloud.vmwareengine.v1.StretchedClusterConfig - */ -class StretchedClusterConfig extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Zone that will remain operational when connection between the two - * zones is lost. Specify the resource name of a zone that belongs to the - * region of the private cloud. For example: - * `projects/{project}/locations/europe-west3-a` where `{project}` can either - * be a project number or a project ID. - * - * Generated from protobuf field string preferred_location = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $preferred_location = ''; - /** - * Required. Additional zone for a higher level of availability and load - * balancing. Specify the resource name of a zone that belongs to the region - * of the private cloud. For example: - * `projects/{project}/locations/europe-west3-b` where `{project}` can either - * be a project number or a project ID. - * - * Generated from protobuf field string secondary_location = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $secondary_location = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $preferred_location - * Required. Zone that will remain operational when connection between the two - * zones is lost. Specify the resource name of a zone that belongs to the - * region of the private cloud. For example: - * `projects/{project}/locations/europe-west3-a` where `{project}` can either - * be a project number or a project ID. - * @type string $secondary_location - * Required. Additional zone for a higher level of availability and load - * balancing. Specify the resource name of a zone that belongs to the region - * of the private cloud. For example: - * `projects/{project}/locations/europe-west3-b` where `{project}` can either - * be a project number or a project ID. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); - parent::__construct($data); - } - - /** - * Required. Zone that will remain operational when connection between the two - * zones is lost. Specify the resource name of a zone that belongs to the - * region of the private cloud. For example: - * `projects/{project}/locations/europe-west3-a` where `{project}` can either - * be a project number or a project ID. - * - * Generated from protobuf field string preferred_location = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getPreferredLocation() - { - return $this->preferred_location; - } - - /** - * Required. Zone that will remain operational when connection between the two - * zones is lost. Specify the resource name of a zone that belongs to the - * region of the private cloud. For example: - * `projects/{project}/locations/europe-west3-a` where `{project}` can either - * be a project number or a project ID. - * - * Generated from protobuf field string preferred_location = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setPreferredLocation($var) - { - GPBUtil::checkString($var, True); - $this->preferred_location = $var; - - return $this; - } - - /** - * Required. Additional zone for a higher level of availability and load - * balancing. Specify the resource name of a zone that belongs to the region - * of the private cloud. For example: - * `projects/{project}/locations/europe-west3-b` where `{project}` can either - * be a project number or a project ID. - * - * Generated from protobuf field string secondary_location = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @return string - */ - public function getSecondaryLocation() - { - return $this->secondary_location; - } - - /** - * Required. Additional zone for a higher level of availability and load - * balancing. Specify the resource name of a zone that belongs to the region - * of the private cloud. For example: - * `projects/{project}/locations/europe-west3-b` where `{project}` can either - * be a project number or a project ID. - * - * Generated from protobuf field string secondary_location = 2 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setSecondaryLocation($var) - { - GPBUtil::checkString($var, True); - $this->secondary_location = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Subnet.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Subnet.php deleted file mode 100644 index 3a48feaa3a0f..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Subnet.php +++ /dev/null @@ -1,262 +0,0 @@ -google.cloud.vmwareengine.v1.Subnet - */ -class Subnet extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The resource name of this subnet. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/subnets/my-subnet` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * The IP address range of the subnet in CIDR format '10.0.0.0/24'. - * - * Generated from protobuf field string ip_cidr_range = 7; - */ - protected $ip_cidr_range = ''; - /** - * The IP address of the gateway of this subnet. - * Must fall within the IP prefix defined above. - * - * Generated from protobuf field string gateway_ip = 8; - */ - protected $gateway_ip = ''; - /** - * Output only. The type of the subnet. For example "management" or - * "userDefined". - * - * Generated from protobuf field string type = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $type = ''; - /** - * Output only. The state of the resource. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.Subnet.State state = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = 0; - /** - * Output only. VLAN ID of the VLAN on which the subnet is configured - * - * Generated from protobuf field int32 vlan_id = 16 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $vlan_id = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. The resource name of this subnet. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/subnets/my-subnet` - * @type string $ip_cidr_range - * The IP address range of the subnet in CIDR format '10.0.0.0/24'. - * @type string $gateway_ip - * The IP address of the gateway of this subnet. - * Must fall within the IP prefix defined above. - * @type string $type - * Output only. The type of the subnet. For example "management" or - * "userDefined". - * @type int $state - * Output only. The state of the resource. - * @type int $vlan_id - * Output only. VLAN ID of the VLAN on which the subnet is configured - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The resource name of this subnet. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/subnets/my-subnet` - * - * 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 subnet. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud/subnets/my-subnet` - * - * 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; - } - - /** - * The IP address range of the subnet in CIDR format '10.0.0.0/24'. - * - * Generated from protobuf field string ip_cidr_range = 7; - * @return string - */ - public function getIpCidrRange() - { - return $this->ip_cidr_range; - } - - /** - * The IP address range of the subnet in CIDR format '10.0.0.0/24'. - * - * Generated from protobuf field string ip_cidr_range = 7; - * @param string $var - * @return $this - */ - public function setIpCidrRange($var) - { - GPBUtil::checkString($var, True); - $this->ip_cidr_range = $var; - - return $this; - } - - /** - * The IP address of the gateway of this subnet. - * Must fall within the IP prefix defined above. - * - * Generated from protobuf field string gateway_ip = 8; - * @return string - */ - public function getGatewayIp() - { - return $this->gateway_ip; - } - - /** - * The IP address of the gateway of this subnet. - * Must fall within the IP prefix defined above. - * - * Generated from protobuf field string gateway_ip = 8; - * @param string $var - * @return $this - */ - public function setGatewayIp($var) - { - GPBUtil::checkString($var, True); - $this->gateway_ip = $var; - - return $this; - } - - /** - * Output only. The type of the subnet. For example "management" or - * "userDefined". - * - * Generated from protobuf field string type = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getType() - { - return $this->type; - } - - /** - * Output only. The type of the subnet. For example "management" or - * "userDefined". - * - * Generated from protobuf field string type = 11 [(.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. The state of the resource. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.Subnet.State state = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Output only. The state of the resource. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.Subnet.State state = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\Subnet\State::class); - $this->state = $var; - - return $this; - } - - /** - * Output only. VLAN ID of the VLAN on which the subnet is configured - * - * Generated from protobuf field int32 vlan_id = 16 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getVlanId() - { - return $this->vlan_id; - } - - /** - * Output only. VLAN ID of the VLAN on which the subnet is configured - * - * Generated from protobuf field int32 vlan_id = 16 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setVlanId($var) - { - GPBUtil::checkInt32($var); - $this->vlan_id = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Subnet/State.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Subnet/State.php deleted file mode 100644 index 92cf3e454561..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Subnet/State.php +++ /dev/null @@ -1,90 +0,0 @@ -google.cloud.vmwareengine.v1.Subnet.State - */ -class State -{ - /** - * The default value. This value should never be used. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * The subnet is ready. - * - * Generated from protobuf enum ACTIVE = 1; - */ - const ACTIVE = 1; - /** - * The subnet is being created. - * - * Generated from protobuf enum CREATING = 2; - */ - const CREATING = 2; - /** - * The subnet is being updated. - * - * Generated from protobuf enum UPDATING = 3; - */ - const UPDATING = 3; - /** - * The subnet is being deleted. - * - * Generated from protobuf enum DELETING = 4; - */ - const DELETING = 4; - /** - * Changes requested in the last operation are being propagated. - * - * Generated from protobuf enum RECONCILING = 5; - */ - const RECONCILING = 5; - /** - * Last operation on the subnet did not succeed. Subnet's payload is - * reverted back to its most recent working state. - * - * Generated from protobuf enum FAILED = 6; - */ - const FAILED = 6; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::ACTIVE => 'ACTIVE', - self::CREATING => 'CREATING', - self::UPDATING => 'UPDATING', - self::DELETING => 'DELETING', - self::RECONCILING => 'RECONCILING', - 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); - } -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UndeletePrivateCloudRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UndeletePrivateCloudRequest.php deleted file mode 100644 index f4704b080b50..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UndeletePrivateCloudRequest.php +++ /dev/null @@ -1,140 +0,0 @@ -google.cloud.vmwareengine.v1.UndeletePrivateCloudRequest - */ -class UndeletePrivateCloudRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the private cloud scheduled for deletion. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Optional. 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 = ''; - - /** - * @param string $name Required. The resource name of the private cloud scheduled for deletion. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * Please see {@see VmwareEngineClient::privateCloudName()} for help formatting this field. - * - * @return \Google\Cloud\VmwareEngine\V1\UndeletePrivateCloudRequest - * - * @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 private cloud scheduled for deletion. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * @type string $request_id - * Optional. 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\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the private cloud scheduled for deletion. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * 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 private cloud scheduled for deletion. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/us-central1-a/privateClouds/my-cloud` - * - * 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 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. 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; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateClusterRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateClusterRequest.php deleted file mode 100644 index b11ad2d64297..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateClusterRequest.php +++ /dev/null @@ -1,233 +0,0 @@ -google.cloud.vmwareengine.v1.UpdateClusterRequest - */ -class UpdateClusterRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Field mask is used to specify the fields to be overwritten in the - * `Cluster` resource by the update. The fields specified in the `updateMask` - * 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. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $update_mask = null; - /** - * Required. The description of the cluster. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.Cluster cluster = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $cluster = null; - /** - * Optional. 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. True if you want the request to be validated and not executed; - * false otherwise. - * - * Generated from protobuf field bool validate_only = 4 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $validate_only = false; - - /** - * @param \Google\Cloud\VmwareEngine\V1\Cluster $cluster Required. The description of the cluster. - * @param \Google\Protobuf\FieldMask $updateMask Required. Field mask is used to specify the fields to be overwritten in the - * `Cluster` resource by the update. The fields specified in the `updateMask` - * 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. - * - * @return \Google\Cloud\VmwareEngine\V1\UpdateClusterRequest - * - * @experimental - */ - public static function build(\Google\Cloud\VmwareEngine\V1\Cluster $cluster, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setCluster($cluster) - ->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 - * `Cluster` resource by the update. The fields specified in the `updateMask` - * 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. - * @type \Google\Cloud\VmwareEngine\V1\Cluster $cluster - * Required. The description of the cluster. - * @type string $request_id - * Optional. 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. True if you want the request to be validated and not executed; - * false otherwise. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. Field mask is used to specify the fields to be overwritten in the - * `Cluster` resource by the update. The fields specified in the `updateMask` - * 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. - * - * 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 - * `Cluster` resource by the update. The fields specified in the `updateMask` - * 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. - * - * 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 description of the cluster. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.Cluster cluster = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\VmwareEngine\V1\Cluster|null - */ - public function getCluster() - { - return $this->cluster; - } - - public function hasCluster() - { - return isset($this->cluster); - } - - public function clearCluster() - { - unset($this->cluster); - } - - /** - * Required. The description of the cluster. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.Cluster cluster = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\VmwareEngine\V1\Cluster $var - * @return $this - */ - public function setCluster($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\Cluster::class); - $this->cluster = $var; - - return $this; - } - - /** - * Optional. 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. 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. True if you want the request to be validated and not executed; - * false otherwise. - * - * Generated from protobuf field bool validate_only = 4 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getValidateOnly() - { - return $this->validate_only; - } - - /** - * Optional. True if you want the request to be validated and not executed; - * false otherwise. - * - * 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateDnsForwardingRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateDnsForwardingRequest.php deleted file mode 100644 index 1087a4cf67d4..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateDnsForwardingRequest.php +++ /dev/null @@ -1,235 +0,0 @@ -google.cloud.vmwareengine.v1.UpdateDnsForwardingRequest - */ -class UpdateDnsForwardingRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. DnsForwarding config details. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.DnsForwarding dns_forwarding = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $dns_forwarding = null; - /** - * Required. Field mask is used to specify the fields to be overwritten in the - * `DnsForwarding` 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. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $update_mask = null; - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $request_id = ''; - - /** - * @param \Google\Cloud\VmwareEngine\V1\DnsForwarding $dnsForwarding Required. DnsForwarding config details. - * @param \Google\Protobuf\FieldMask $updateMask Required. Field mask is used to specify the fields to be overwritten in the - * `DnsForwarding` 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. - * - * @return \Google\Cloud\VmwareEngine\V1\UpdateDnsForwardingRequest - * - * @experimental - */ - public static function build(\Google\Cloud\VmwareEngine\V1\DnsForwarding $dnsForwarding, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setDnsForwarding($dnsForwarding) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\VmwareEngine\V1\DnsForwarding $dns_forwarding - * Required. DnsForwarding config details. - * @type \Google\Protobuf\FieldMask $update_mask - * Required. Field mask is used to specify the fields to be overwritten in the - * `DnsForwarding` 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. - * @type string $request_id - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. DnsForwarding config details. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.DnsForwarding dns_forwarding = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\VmwareEngine\V1\DnsForwarding|null - */ - public function getDnsForwarding() - { - return $this->dns_forwarding; - } - - public function hasDnsForwarding() - { - return isset($this->dns_forwarding); - } - - public function clearDnsForwarding() - { - unset($this->dns_forwarding); - } - - /** - * Required. DnsForwarding config details. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.DnsForwarding dns_forwarding = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\VmwareEngine\V1\DnsForwarding $var - * @return $this - */ - public function setDnsForwarding($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\DnsForwarding::class); - $this->dns_forwarding = $var; - - return $this; - } - - /** - * Required. Field mask is used to specify the fields to be overwritten in the - * `DnsForwarding` 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. - * - * 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. Field mask is used to specify the fields to be overwritten in the - * `DnsForwarding` 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. - * - * 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; - } - - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 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; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateExternalAccessRuleRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateExternalAccessRuleRequest.php deleted file mode 100644 index 15daf8db744c..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateExternalAccessRuleRequest.php +++ /dev/null @@ -1,235 +0,0 @@ -google.cloud.vmwareengine.v1.UpdateExternalAccessRuleRequest - */ -class UpdateExternalAccessRuleRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Field mask is used to specify the fields to be overwritten in the - * `ExternalAccessRule` 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. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $update_mask = null; - /** - * Required. Description of the external access rule. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.ExternalAccessRule external_access_rule = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $external_access_rule = null; - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 the 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 = ''; - - /** - * @param \Google\Cloud\VmwareEngine\V1\ExternalAccessRule $externalAccessRule Required. Description of the external access rule. - * @param \Google\Protobuf\FieldMask $updateMask Required. Field mask is used to specify the fields to be overwritten in the - * `ExternalAccessRule` 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. - * - * @return \Google\Cloud\VmwareEngine\V1\UpdateExternalAccessRuleRequest - * - * @experimental - */ - public static function build(\Google\Cloud\VmwareEngine\V1\ExternalAccessRule $externalAccessRule, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setExternalAccessRule($externalAccessRule) - ->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 - * `ExternalAccessRule` 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. - * @type \Google\Cloud\VmwareEngine\V1\ExternalAccessRule $external_access_rule - * Required. Description of the external access rule. - * @type string $request_id - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 the 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\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. Field mask is used to specify the fields to be overwritten in the - * `ExternalAccessRule` 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. - * - * 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 - * `ExternalAccessRule` 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. - * - * 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. Description of the external access rule. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.ExternalAccessRule external_access_rule = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\VmwareEngine\V1\ExternalAccessRule|null - */ - public function getExternalAccessRule() - { - return $this->external_access_rule; - } - - public function hasExternalAccessRule() - { - return isset($this->external_access_rule); - } - - public function clearExternalAccessRule() - { - unset($this->external_access_rule); - } - - /** - * Required. Description of the external access rule. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.ExternalAccessRule external_access_rule = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\VmwareEngine\V1\ExternalAccessRule $var - * @return $this - */ - public function setExternalAccessRule($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\ExternalAccessRule::class); - $this->external_access_rule = $var; - - return $this; - } - - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 the 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. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 the 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; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateExternalAddressRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateExternalAddressRequest.php deleted file mode 100644 index 3d42ce8e05b7..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateExternalAddressRequest.php +++ /dev/null @@ -1,235 +0,0 @@ -google.cloud.vmwareengine.v1.UpdateExternalAddressRequest - */ -class UpdateExternalAddressRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Field mask is used to specify the fields to be overwritten in the - * `ExternalAddress` 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. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $update_mask = null; - /** - * Required. External IP address description. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.ExternalAddress external_address = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $external_address = null; - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 the 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 = ''; - - /** - * @param \Google\Cloud\VmwareEngine\V1\ExternalAddress $externalAddress Required. External IP address description. - * @param \Google\Protobuf\FieldMask $updateMask Required. Field mask is used to specify the fields to be overwritten in the - * `ExternalAddress` 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. - * - * @return \Google\Cloud\VmwareEngine\V1\UpdateExternalAddressRequest - * - * @experimental - */ - public static function build(\Google\Cloud\VmwareEngine\V1\ExternalAddress $externalAddress, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setExternalAddress($externalAddress) - ->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 - * `ExternalAddress` 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. - * @type \Google\Cloud\VmwareEngine\V1\ExternalAddress $external_address - * Required. External IP address description. - * @type string $request_id - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 the 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\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. Field mask is used to specify the fields to be overwritten in the - * `ExternalAddress` 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. - * - * 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 - * `ExternalAddress` 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. - * - * 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. External IP address description. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.ExternalAddress external_address = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\VmwareEngine\V1\ExternalAddress|null - */ - public function getExternalAddress() - { - return $this->external_address; - } - - public function hasExternalAddress() - { - return isset($this->external_address); - } - - public function clearExternalAddress() - { - unset($this->external_address); - } - - /** - * Required. External IP address description. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.ExternalAddress external_address = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\VmwareEngine\V1\ExternalAddress $var - * @return $this - */ - public function setExternalAddress($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\ExternalAddress::class); - $this->external_address = $var; - - return $this; - } - - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 the 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. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 the 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; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateLoggingServerRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateLoggingServerRequest.php deleted file mode 100644 index 4e9feaa73fbd..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateLoggingServerRequest.php +++ /dev/null @@ -1,235 +0,0 @@ -google.cloud.vmwareengine.v1.UpdateLoggingServerRequest - */ -class UpdateLoggingServerRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Field mask is used to specify the fields to be overwritten in the - * `LoggingServer` 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. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $update_mask = null; - /** - * Required. Logging server description. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.LoggingServer logging_server = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $logging_server = null; - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $request_id = ''; - - /** - * @param \Google\Cloud\VmwareEngine\V1\LoggingServer $loggingServer Required. Logging server description. - * @param \Google\Protobuf\FieldMask $updateMask Required. Field mask is used to specify the fields to be overwritten in the - * `LoggingServer` 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. - * - * @return \Google\Cloud\VmwareEngine\V1\UpdateLoggingServerRequest - * - * @experimental - */ - public static function build(\Google\Cloud\VmwareEngine\V1\LoggingServer $loggingServer, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setLoggingServer($loggingServer) - ->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 - * `LoggingServer` 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. - * @type \Google\Cloud\VmwareEngine\V1\LoggingServer $logging_server - * Required. Logging server description. - * @type string $request_id - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. Field mask is used to specify the fields to be overwritten in the - * `LoggingServer` 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. - * - * 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 - * `LoggingServer` 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. - * - * 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. Logging server description. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.LoggingServer logging_server = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\VmwareEngine\V1\LoggingServer|null - */ - public function getLoggingServer() - { - return $this->logging_server; - } - - public function hasLoggingServer() - { - return isset($this->logging_server); - } - - public function clearLoggingServer() - { - unset($this->logging_server); - } - - /** - * Required. Logging server description. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.LoggingServer logging_server = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\VmwareEngine\V1\LoggingServer $var - * @return $this - */ - public function setLoggingServer($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\LoggingServer::class); - $this->logging_server = $var; - - return $this; - } - - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 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; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateManagementDnsZoneBindingRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateManagementDnsZoneBindingRequest.php deleted file mode 100644 index d2b66cf147ea..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateManagementDnsZoneBindingRequest.php +++ /dev/null @@ -1,235 +0,0 @@ -google.cloud.vmwareengine.v1.UpdateManagementDnsZoneBindingRequest - */ -class UpdateManagementDnsZoneBindingRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Field mask is used to specify the fields to be overwritten in the - * `ManagementDnsZoneBinding` 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. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $update_mask = null; - /** - * Required. New values to update the management DNS zone binding with. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.ManagementDnsZoneBinding management_dns_zone_binding = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $management_dns_zone_binding = null; - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 the 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 = ''; - - /** - * @param \Google\Cloud\VmwareEngine\V1\ManagementDnsZoneBinding $managementDnsZoneBinding Required. New values to update the management DNS zone binding with. - * @param \Google\Protobuf\FieldMask $updateMask Required. Field mask is used to specify the fields to be overwritten in the - * `ManagementDnsZoneBinding` 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. - * - * @return \Google\Cloud\VmwareEngine\V1\UpdateManagementDnsZoneBindingRequest - * - * @experimental - */ - public static function build(\Google\Cloud\VmwareEngine\V1\ManagementDnsZoneBinding $managementDnsZoneBinding, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setManagementDnsZoneBinding($managementDnsZoneBinding) - ->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 - * `ManagementDnsZoneBinding` 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. - * @type \Google\Cloud\VmwareEngine\V1\ManagementDnsZoneBinding $management_dns_zone_binding - * Required. New values to update the management DNS zone binding with. - * @type string $request_id - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 the 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\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. Field mask is used to specify the fields to be overwritten in the - * `ManagementDnsZoneBinding` 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. - * - * 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 - * `ManagementDnsZoneBinding` 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. - * - * 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. New values to update the management DNS zone binding with. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.ManagementDnsZoneBinding management_dns_zone_binding = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\VmwareEngine\V1\ManagementDnsZoneBinding|null - */ - public function getManagementDnsZoneBinding() - { - return $this->management_dns_zone_binding; - } - - public function hasManagementDnsZoneBinding() - { - return isset($this->management_dns_zone_binding); - } - - public function clearManagementDnsZoneBinding() - { - unset($this->management_dns_zone_binding); - } - - /** - * Required. New values to update the management DNS zone binding with. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.ManagementDnsZoneBinding management_dns_zone_binding = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\VmwareEngine\V1\ManagementDnsZoneBinding $var - * @return $this - */ - public function setManagementDnsZoneBinding($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\ManagementDnsZoneBinding::class); - $this->management_dns_zone_binding = $var; - - return $this; - } - - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 the 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. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 the 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; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateNetworkPeeringRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateNetworkPeeringRequest.php deleted file mode 100644 index 642bed6a5167..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateNetworkPeeringRequest.php +++ /dev/null @@ -1,235 +0,0 @@ -google.cloud.vmwareengine.v1.UpdateNetworkPeeringRequest - */ -class UpdateNetworkPeeringRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Network peering description. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPeering network_peering = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $network_peering = null; - /** - * Required. Field mask is used to specify the fields to be overwritten in the - * `NetworkPeering` 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. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $update_mask = null; - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $request_id = ''; - - /** - * @param \Google\Cloud\VmwareEngine\V1\NetworkPeering $networkPeering Required. Network peering description. - * @param \Google\Protobuf\FieldMask $updateMask Required. Field mask is used to specify the fields to be overwritten in the - * `NetworkPeering` 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. - * - * @return \Google\Cloud\VmwareEngine\V1\UpdateNetworkPeeringRequest - * - * @experimental - */ - public static function build(\Google\Cloud\VmwareEngine\V1\NetworkPeering $networkPeering, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setNetworkPeering($networkPeering) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\VmwareEngine\V1\NetworkPeering $network_peering - * Required. Network peering description. - * @type \Google\Protobuf\FieldMask $update_mask - * Required. Field mask is used to specify the fields to be overwritten in the - * `NetworkPeering` 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. - * @type string $request_id - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. Network peering description. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPeering network_peering = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\VmwareEngine\V1\NetworkPeering|null - */ - public function getNetworkPeering() - { - return $this->network_peering; - } - - public function hasNetworkPeering() - { - return isset($this->network_peering); - } - - public function clearNetworkPeering() - { - unset($this->network_peering); - } - - /** - * Required. Network peering description. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPeering network_peering = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\VmwareEngine\V1\NetworkPeering $var - * @return $this - */ - public function setNetworkPeering($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\NetworkPeering::class); - $this->network_peering = $var; - - return $this; - } - - /** - * Required. Field mask is used to specify the fields to be overwritten in the - * `NetworkPeering` 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. - * - * 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. Field mask is used to specify the fields to be overwritten in the - * `NetworkPeering` 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. - * - * 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; - } - - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 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; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateNetworkPolicyRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateNetworkPolicyRequest.php deleted file mode 100644 index 2ec762dc531e..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateNetworkPolicyRequest.php +++ /dev/null @@ -1,235 +0,0 @@ -google.cloud.vmwareengine.v1.UpdateNetworkPolicyRequest - */ -class UpdateNetworkPolicyRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Network policy description. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPolicy network_policy = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $network_policy = null; - /** - * Required. Field mask is used to specify the fields to be overwritten in the - * `NetworkPolicy` 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. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $update_mask = null; - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $request_id = ''; - - /** - * @param \Google\Cloud\VmwareEngine\V1\NetworkPolicy $networkPolicy Required. Network policy description. - * @param \Google\Protobuf\FieldMask $updateMask Required. Field mask is used to specify the fields to be overwritten in the - * `NetworkPolicy` 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. - * - * @return \Google\Cloud\VmwareEngine\V1\UpdateNetworkPolicyRequest - * - * @experimental - */ - public static function build(\Google\Cloud\VmwareEngine\V1\NetworkPolicy $networkPolicy, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setNetworkPolicy($networkPolicy) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\VmwareEngine\V1\NetworkPolicy $network_policy - * Required. Network policy description. - * @type \Google\Protobuf\FieldMask $update_mask - * Required. Field mask is used to specify the fields to be overwritten in the - * `NetworkPolicy` 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. - * @type string $request_id - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. Network policy description. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPolicy network_policy = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\VmwareEngine\V1\NetworkPolicy|null - */ - public function getNetworkPolicy() - { - return $this->network_policy; - } - - public function hasNetworkPolicy() - { - return isset($this->network_policy); - } - - public function clearNetworkPolicy() - { - unset($this->network_policy); - } - - /** - * Required. Network policy description. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.NetworkPolicy network_policy = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\VmwareEngine\V1\NetworkPolicy $var - * @return $this - */ - public function setNetworkPolicy($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\NetworkPolicy::class); - $this->network_policy = $var; - - return $this; - } - - /** - * Required. Field mask is used to specify the fields to be overwritten in the - * `NetworkPolicy` 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. - * - * 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. Field mask is used to specify the fields to be overwritten in the - * `NetworkPolicy` 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. - * - * 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; - } - - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 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; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdatePrivateCloudRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdatePrivateCloudRequest.php deleted file mode 100644 index 0304fc6978ce..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdatePrivateCloudRequest.php +++ /dev/null @@ -1,195 +0,0 @@ -google.cloud.vmwareengine.v1.UpdatePrivateCloudRequest - */ -class UpdatePrivateCloudRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Private cloud description. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateCloud private_cloud = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $private_cloud = null; - /** - * Required. Field mask is used to specify the fields to be overwritten in the - * `PrivateCloud` resource by the update. The fields specified in `updateMask` - * 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. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $update_mask = null; - /** - * Optional. 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 = ''; - - /** - * @param \Google\Cloud\VmwareEngine\V1\PrivateCloud $privateCloud Required. Private cloud description. - * @param \Google\Protobuf\FieldMask $updateMask Required. Field mask is used to specify the fields to be overwritten in the - * `PrivateCloud` resource by the update. The fields specified in `updateMask` - * 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. - * - * @return \Google\Cloud\VmwareEngine\V1\UpdatePrivateCloudRequest - * - * @experimental - */ - public static function build(\Google\Cloud\VmwareEngine\V1\PrivateCloud $privateCloud, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setPrivateCloud($privateCloud) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\VmwareEngine\V1\PrivateCloud $private_cloud - * Required. Private cloud description. - * @type \Google\Protobuf\FieldMask $update_mask - * Required. Field mask is used to specify the fields to be overwritten in the - * `PrivateCloud` resource by the update. The fields specified in `updateMask` - * 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. - * @type string $request_id - * Optional. 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\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. Private cloud description. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateCloud private_cloud = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\VmwareEngine\V1\PrivateCloud|null - */ - public function getPrivateCloud() - { - return $this->private_cloud; - } - - public function hasPrivateCloud() - { - return isset($this->private_cloud); - } - - public function clearPrivateCloud() - { - unset($this->private_cloud); - } - - /** - * Required. Private cloud description. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateCloud private_cloud = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\VmwareEngine\V1\PrivateCloud $var - * @return $this - */ - public function setPrivateCloud($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\PrivateCloud::class); - $this->private_cloud = $var; - - return $this; - } - - /** - * Required. Field mask is used to specify the fields to be overwritten in the - * `PrivateCloud` resource by the update. The fields specified in `updateMask` - * 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. - * - * 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. Field mask is used to specify the fields to be overwritten in the - * `PrivateCloud` resource by the update. The fields specified in `updateMask` - * 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. - * - * 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; - } - - /** - * Optional. 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. 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; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdatePrivateConnectionRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdatePrivateConnectionRequest.php deleted file mode 100644 index 46ee4128d3f1..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdatePrivateConnectionRequest.php +++ /dev/null @@ -1,235 +0,0 @@ -google.cloud.vmwareengine.v1.UpdatePrivateConnectionRequest - */ -class UpdatePrivateConnectionRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Private connection description. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateConnection private_connection = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $private_connection = null; - /** - * Required. Field mask is used to specify the fields to be overwritten in the - * `PrivateConnection` 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. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $update_mask = null; - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $request_id = ''; - - /** - * @param \Google\Cloud\VmwareEngine\V1\PrivateConnection $privateConnection Required. Private connection description. - * @param \Google\Protobuf\FieldMask $updateMask Required. Field mask is used to specify the fields to be overwritten in the - * `PrivateConnection` 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. - * - * @return \Google\Cloud\VmwareEngine\V1\UpdatePrivateConnectionRequest - * - * @experimental - */ - public static function build(\Google\Cloud\VmwareEngine\V1\PrivateConnection $privateConnection, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setPrivateConnection($privateConnection) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\VmwareEngine\V1\PrivateConnection $private_connection - * Required. Private connection description. - * @type \Google\Protobuf\FieldMask $update_mask - * Required. Field mask is used to specify the fields to be overwritten in the - * `PrivateConnection` 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. - * @type string $request_id - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. Private connection description. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateConnection private_connection = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\VmwareEngine\V1\PrivateConnection|null - */ - public function getPrivateConnection() - { - return $this->private_connection; - } - - public function hasPrivateConnection() - { - return isset($this->private_connection); - } - - public function clearPrivateConnection() - { - unset($this->private_connection); - } - - /** - * Required. Private connection description. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.PrivateConnection private_connection = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\VmwareEngine\V1\PrivateConnection $var - * @return $this - */ - public function setPrivateConnection($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\PrivateConnection::class); - $this->private_connection = $var; - - return $this; - } - - /** - * Required. Field mask is used to specify the fields to be overwritten in the - * `PrivateConnection` 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. - * - * 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. Field mask is used to specify the fields to be overwritten in the - * `PrivateConnection` 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. - * - * 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; - } - - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 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; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateSubnetRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateSubnetRequest.php deleted file mode 100644 index b37a82ae16b4..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateSubnetRequest.php +++ /dev/null @@ -1,157 +0,0 @@ -google.cloud.vmwareengine.v1.UpdateSubnetRequest - */ -class UpdateSubnetRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Field mask is used to specify the fields to be overwritten in the - * `Subnet` 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. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $update_mask = null; - /** - * Required. Subnet description. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.Subnet subnet = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $subnet = null; - - /** - * @param \Google\Cloud\VmwareEngine\V1\Subnet $subnet Required. Subnet description. - * @param \Google\Protobuf\FieldMask $updateMask Required. Field mask is used to specify the fields to be overwritten in the - * `Subnet` 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. - * - * @return \Google\Cloud\VmwareEngine\V1\UpdateSubnetRequest - * - * @experimental - */ - public static function build(\Google\Cloud\VmwareEngine\V1\Subnet $subnet, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setSubnet($subnet) - ->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 - * `Subnet` 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. - * @type \Google\Cloud\VmwareEngine\V1\Subnet $subnet - * Required. Subnet description. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. Field mask is used to specify the fields to be overwritten in the - * `Subnet` 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. - * - * 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 - * `Subnet` 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. - * - * 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. Subnet description. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.Subnet subnet = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\VmwareEngine\V1\Subnet|null - */ - public function getSubnet() - { - return $this->subnet; - } - - public function hasSubnet() - { - return isset($this->subnet); - } - - public function clearSubnet() - { - unset($this->subnet); - } - - /** - * Required. Subnet description. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.Subnet subnet = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\VmwareEngine\V1\Subnet $var - * @return $this - */ - public function setSubnet($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\Subnet::class); - $this->subnet = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateVmwareEngineNetworkRequest.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateVmwareEngineNetworkRequest.php deleted file mode 100644 index 2994f4021cc2..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/UpdateVmwareEngineNetworkRequest.php +++ /dev/null @@ -1,240 +0,0 @@ -google.cloud.vmwareengine.v1.UpdateVmwareEngineNetworkRequest - */ -class UpdateVmwareEngineNetworkRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. VMware Engine network description. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.VmwareEngineNetwork vmware_engine_network = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $vmware_engine_network = null; - /** - * Required. Field mask is used to specify the fields to be overwritten in the - * VMware Engine network 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. Only the - * following fields can be updated: `description`. - * - * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $update_mask = null; - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $request_id = ''; - - /** - * @param \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork $vmwareEngineNetwork Required. VMware Engine network description. - * @param \Google\Protobuf\FieldMask $updateMask Required. Field mask is used to specify the fields to be overwritten in the - * VMware Engine network 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. Only the - * following fields can be updated: `description`. - * - * @return \Google\Cloud\VmwareEngine\V1\UpdateVmwareEngineNetworkRequest - * - * @experimental - */ - public static function build(\Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork $vmwareEngineNetwork, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setVmwareEngineNetwork($vmwareEngineNetwork) - ->setUpdateMask($updateMask); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork $vmware_engine_network - * Required. VMware Engine network description. - * @type \Google\Protobuf\FieldMask $update_mask - * Required. Field mask is used to specify the fields to be overwritten in the - * VMware Engine network 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. Only the - * following fields can be updated: `description`. - * @type string $request_id - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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\Vmwareengine\V1\Vmwareengine::initOnce(); - parent::__construct($data); - } - - /** - * Required. VMware Engine network description. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.VmwareEngineNetwork vmware_engine_network = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork|null - */ - public function getVmwareEngineNetwork() - { - return $this->vmware_engine_network; - } - - public function hasVmwareEngineNetwork() - { - return isset($this->vmware_engine_network); - } - - public function clearVmwareEngineNetwork() - { - unset($this->vmware_engine_network); - } - - /** - * Required. VMware Engine network description. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.VmwareEngineNetwork vmware_engine_network = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork $var - * @return $this - */ - public function setVmwareEngineNetwork($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork::class); - $this->vmware_engine_network = $var; - - return $this; - } - - /** - * Required. Field mask is used to specify the fields to be overwritten in the - * VMware Engine network 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. Only the - * following fields can be updated: `description`. - * - * 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. Field mask is used to specify the fields to be overwritten in the - * VMware Engine network 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. Only the - * following fields can be updated: `description`. - * - * 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; - } - - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getRequestId() - { - return $this->request_id; - } - - /** - * Optional. A 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 guarantees that a - * request doesn't result in creation of duplicate commitments for at least 60 - * minutes. - * 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 = 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; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Vcenter.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Vcenter.php deleted file mode 100644 index b9d9c5b0aac2..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Vcenter.php +++ /dev/null @@ -1,169 +0,0 @@ -google.cloud.vmwareengine.v1.Vcenter - */ -class Vcenter extends \Google\Protobuf\Internal\Message -{ - /** - * Internal IP address of the appliance. - * - * Generated from protobuf field string internal_ip = 2; - */ - protected $internal_ip = ''; - /** - * Version of the appliance. - * - * Generated from protobuf field string version = 4; - */ - protected $version = ''; - /** - * Output only. The state of the appliance. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.Vcenter.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = 0; - /** - * Fully qualified domain name of the appliance. - * - * Generated from protobuf field string fqdn = 6; - */ - protected $fqdn = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $internal_ip - * Internal IP address of the appliance. - * @type string $version - * Version of the appliance. - * @type int $state - * Output only. The state of the appliance. - * @type string $fqdn - * Fully qualified domain name of the appliance. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); - parent::__construct($data); - } - - /** - * Internal IP address of the appliance. - * - * Generated from protobuf field string internal_ip = 2; - * @return string - */ - public function getInternalIp() - { - return $this->internal_ip; - } - - /** - * Internal IP address of the appliance. - * - * Generated from protobuf field string internal_ip = 2; - * @param string $var - * @return $this - */ - public function setInternalIp($var) - { - GPBUtil::checkString($var, True); - $this->internal_ip = $var; - - return $this; - } - - /** - * Version of the appliance. - * - * Generated from protobuf field string version = 4; - * @return string - */ - public function getVersion() - { - return $this->version; - } - - /** - * Version of the appliance. - * - * Generated from protobuf field string version = 4; - * @param string $var - * @return $this - */ - public function setVersion($var) - { - GPBUtil::checkString($var, True); - $this->version = $var; - - return $this; - } - - /** - * Output only. The state of the appliance. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.Vcenter.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Output only. The state of the appliance. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.Vcenter.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\Vcenter\State::class); - $this->state = $var; - - return $this; - } - - /** - * Fully qualified domain name of the appliance. - * - * Generated from protobuf field string fqdn = 6; - * @return string - */ - public function getFqdn() - { - return $this->fqdn; - } - - /** - * Fully qualified domain name of the appliance. - * - * Generated from protobuf field string fqdn = 6; - * @param string $var - * @return $this - */ - public function setFqdn($var) - { - GPBUtil::checkString($var, True); - $this->fqdn = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Vcenter/State.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Vcenter/State.php deleted file mode 100644 index eb444491b18d..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/Vcenter/State.php +++ /dev/null @@ -1,61 +0,0 @@ -google.cloud.vmwareengine.v1.Vcenter.State - */ -class State -{ - /** - * Unspecified appliance state. This is the default value. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * The appliance is operational and can be used. - * - * Generated from protobuf enum ACTIVE = 1; - */ - const ACTIVE = 1; - /** - * The appliance is being deployed. - * - * Generated from protobuf enum CREATING = 2; - */ - const CREATING = 2; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::ACTIVE => 'ACTIVE', - self::CREATING => 'CREATING', - ]; - - 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/VmwareEngineNetwork.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/VmwareEngineNetwork.php deleted file mode 100644 index 300e0b940f7e..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/VmwareEngineNetwork.php +++ /dev/null @@ -1,396 +0,0 @@ -google.cloud.vmwareengine.v1.VmwareEngineNetwork - */ -class VmwareEngineNetwork extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. The resource name of the VMware Engine network. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/global/vmwareEngineNetworks/my-network` - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $name = ''; - /** - * Output only. Creation time of this resource. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $create_time = null; - /** - * Output only. Last update time of this resource. - * - * Generated from protobuf field .google.protobuf.Timestamp update_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * User-provided description for this VMware Engine network. - * - * Generated from protobuf field string description = 5; - */ - protected $description = ''; - /** - * Output only. VMware Engine service VPC networks that provide connectivity - * from a private cloud to customer projects, the internet, and other Google - * Cloud services. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.VmwareEngineNetwork.VpcNetwork vpc_networks = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - private $vpc_networks; - /** - * Output only. State of the VMware Engine network. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.VmwareEngineNetwork.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = 0; - /** - * Required. VMware Engine network type. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.VmwareEngineNetwork.Type type = 8 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $type = 0; - /** - * Output only. System-generated unique identifier for the resource. - * - * Generated from protobuf field string uid = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $uid = ''; - /** - * Checksum that may be sent on update and delete requests to ensure that the - * user-provided value is up to date before the server processes a request. - * The server computes checksums based on the value of other fields in the - * request. - * - * Generated from protobuf field string etag = 10; - */ - protected $etag = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Output only. The resource name of the VMware Engine network. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/global/vmwareEngineNetworks/my-network` - * @type \Google\Protobuf\Timestamp $create_time - * Output only. Creation time of this resource. - * @type \Google\Protobuf\Timestamp $update_time - * Output only. Last update time of this resource. - * @type string $description - * User-provided description for this VMware Engine network. - * @type \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork\VpcNetwork[] $vpc_networks - * Output only. VMware Engine service VPC networks that provide connectivity - * from a private cloud to customer projects, the internet, and other Google - * Cloud services. - * @type int $state - * Output only. State of the VMware Engine network. - * @type int $type - * Required. VMware Engine network type. - * @type string $uid - * Output only. System-generated unique identifier for the resource. - * @type string $etag - * Checksum that may be sent on update and delete requests to ensure that the - * user-provided value is up to date before the server processes a request. - * The server computes checksums based on the value of other fields in the - * request. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); - parent::__construct($data); - } - - /** - * Output only. The resource name of the VMware Engine network. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/global/vmwareEngineNetworks/my-network` - * - * 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 VMware Engine network. - * Resource names are schemeless URIs that follow the conventions in - * https://cloud.google.com/apis/design/resource_names. - * For example: - * `projects/my-project/locations/global/vmwareEngineNetworks/my-network` - * - * 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. Creation time of this resource. - * - * 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 time of this resource. - * - * 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 time of this resource. - * - * 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 time of this resource. - * - * 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; - } - - /** - * User-provided description for this VMware Engine network. - * - * Generated from protobuf field string description = 5; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * User-provided description for this VMware Engine network. - * - * 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. VMware Engine service VPC networks that provide connectivity - * from a private cloud to customer projects, the internet, and other Google - * Cloud services. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.VmwareEngineNetwork.VpcNetwork vpc_networks = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return RepeatedField<\Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork\VpcNetwork> - */ - public function getVpcNetworks() - { - return $this->vpc_networks; - } - - /** - * Output only. VMware Engine service VPC networks that provide connectivity - * from a private cloud to customer projects, the internet, and other Google - * Cloud services. - * - * Generated from protobuf field repeated .google.cloud.vmwareengine.v1.VmwareEngineNetwork.VpcNetwork vpc_networks = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork\VpcNetwork[] $var - * @return $this - */ - public function setVpcNetworks($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork\VpcNetwork::class); - $this->vpc_networks = $arr; - - return $this; - } - - /** - * Output only. State of the VMware Engine network. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.VmwareEngineNetwork.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Output only. State of the VMware Engine network. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.VmwareEngineNetwork.State state = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork\State::class); - $this->state = $var; - - return $this; - } - - /** - * Required. VMware Engine network type. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.VmwareEngineNetwork.Type type = 8 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getType() - { - return $this->type; - } - - /** - * Required. VMware Engine network type. - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.VmwareEngineNetwork.Type type = 8 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork\Type::class); - $this->type = $var; - - return $this; - } - - /** - * Output only. System-generated unique identifier for the resource. - * - * Generated from protobuf field string uid = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getUid() - { - return $this->uid; - } - - /** - * Output only. System-generated unique identifier for the resource. - * - * Generated from protobuf field string uid = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setUid($var) - { - GPBUtil::checkString($var, True); - $this->uid = $var; - - return $this; - } - - /** - * Checksum that may be sent on update and delete requests to ensure that the - * user-provided value is up to date before the server processes a request. - * The server computes checksums based on the value of other fields in the - * request. - * - * Generated from protobuf field string etag = 10; - * @return string - */ - public function getEtag() - { - return $this->etag; - } - - /** - * Checksum that may be sent on update and delete requests to ensure that the - * user-provided value is up to date before the server processes a request. - * The server computes checksums based on the value of other fields in the - * request. - * - * Generated from protobuf field string etag = 10; - * @param string $var - * @return $this - */ - public function setEtag($var) - { - GPBUtil::checkString($var, True); - $this->etag = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/VmwareEngineNetwork/State.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/VmwareEngineNetwork/State.php deleted file mode 100644 index a20e89ebef11..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/VmwareEngineNetwork/State.php +++ /dev/null @@ -1,75 +0,0 @@ -google.cloud.vmwareengine.v1.VmwareEngineNetwork.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 VMware Engine network is being created. - * - * Generated from protobuf enum CREATING = 1; - */ - const CREATING = 1; - /** - * The VMware Engine network is ready. - * - * Generated from protobuf enum ACTIVE = 2; - */ - const ACTIVE = 2; - /** - * The VMware Engine network is being updated. - * - * Generated from protobuf enum UPDATING = 3; - */ - const UPDATING = 3; - /** - * The VMware Engine network is being deleted. - * - * Generated from protobuf enum DELETING = 4; - */ - const DELETING = 4; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::CREATING => 'CREATING', - self::ACTIVE => 'ACTIVE', - self::UPDATING => 'UPDATING', - 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); - } -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/VmwareEngineNetwork/Type.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/VmwareEngineNetwork/Type.php deleted file mode 100644 index 02b2e4490642..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/VmwareEngineNetwork/Type.php +++ /dev/null @@ -1,63 +0,0 @@ -google.cloud.vmwareengine.v1.VmwareEngineNetwork.Type - */ -class Type -{ - /** - * The default value. This value should never be used. - * - * Generated from protobuf enum TYPE_UNSPECIFIED = 0; - */ - const TYPE_UNSPECIFIED = 0; - /** - * Network type used by private clouds created in projects without a network - * of type `STANDARD`. This network type is no longer used for new VMware - * Engine private cloud deployments. - * - * Generated from protobuf enum LEGACY = 1; - */ - const LEGACY = 1; - /** - * Standard network type used for private cloud connectivity. - * - * Generated from protobuf enum STANDARD = 2; - */ - const STANDARD = 2; - - private static $valueToName = [ - self::TYPE_UNSPECIFIED => 'TYPE_UNSPECIFIED', - self::LEGACY => 'LEGACY', - self::STANDARD => 'STANDARD', - ]; - - 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/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/VmwareEngineNetwork/VpcNetwork.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/VmwareEngineNetwork/VpcNetwork.php deleted file mode 100644 index e223d6a569ec..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/VmwareEngineNetwork/VpcNetwork.php +++ /dev/null @@ -1,114 +0,0 @@ -google.cloud.vmwareengine.v1.VmwareEngineNetwork.VpcNetwork - */ -class VpcNetwork extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. Type of VPC network (INTRANET, INTERNET, or - * GOOGLE_CLOUD) - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.VmwareEngineNetwork.VpcNetwork.Type type = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $type = 0; - /** - * Output only. The relative resource name of the service VPC network this - * VMware Engine network is attached to. For example: - * `projects/123123/global/networks/my-network` - * - * Generated from protobuf field string network = 2 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { - */ - protected $network = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $type - * Output only. Type of VPC network (INTRANET, INTERNET, or - * GOOGLE_CLOUD) - * @type string $network - * Output only. The relative resource name of the service VPC network this - * VMware Engine network is attached to. For example: - * `projects/123123/global/networks/my-network` - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Vmwareengine\V1\VmwareengineResources::initOnce(); - parent::__construct($data); - } - - /** - * Output only. Type of VPC network (INTRANET, INTERNET, or - * GOOGLE_CLOUD) - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.VmwareEngineNetwork.VpcNetwork.Type type = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getType() - { - return $this->type; - } - - /** - * Output only. Type of VPC network (INTRANET, INTERNET, or - * GOOGLE_CLOUD) - * - * Generated from protobuf field .google.cloud.vmwareengine.v1.VmwareEngineNetwork.VpcNetwork.Type type = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork\VpcNetwork\Type::class); - $this->type = $var; - - return $this; - } - - /** - * Output only. The relative resource name of the service VPC network this - * VMware Engine network is attached to. For example: - * `projects/123123/global/networks/my-network` - * - * Generated from protobuf field string network = 2 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { - * @return string - */ - public function getNetwork() - { - return $this->network; - } - - /** - * Output only. The relative resource name of the service VPC network this - * VMware Engine network is attached to. For example: - * `projects/123123/global/networks/my-network` - * - * Generated from protobuf field string network = 2 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setNetwork($var) - { - GPBUtil::checkString($var, True); - $this->network = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/VmwareEngineNetwork/VpcNetwork/Type.php b/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/VmwareEngineNetwork/VpcNetwork/Type.php deleted file mode 100644 index 8ac68c237aa8..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/proto/src/Google/Cloud/VmwareEngine/V1/VmwareEngineNetwork/VpcNetwork/Type.php +++ /dev/null @@ -1,73 +0,0 @@ -google.cloud.vmwareengine.v1.VmwareEngineNetwork.VpcNetwork.Type - */ -class Type -{ - /** - * The default value. This value should never be used. - * - * Generated from protobuf enum TYPE_UNSPECIFIED = 0; - */ - const TYPE_UNSPECIFIED = 0; - /** - * VPC network that will be peered with a consumer VPC network or the - * intranet VPC of another VMware Engine network. Access a private cloud - * through Compute Engine VMs on a peered VPC network or an on-premises - * resource connected to a peered consumer VPC network. - * - * Generated from protobuf enum INTRANET = 1; - */ - const INTRANET = 1; - /** - * VPC network used for internet access to and from a private cloud. - * - * Generated from protobuf enum INTERNET = 2; - */ - const INTERNET = 2; - /** - * VPC network used for access to Google Cloud services like - * Cloud Storage. - * - * Generated from protobuf enum GOOGLE_CLOUD = 3; - */ - const GOOGLE_CLOUD = 3; - - private static $valueToName = [ - self::TYPE_UNSPECIFIED => 'TYPE_UNSPECIFIED', - self::INTRANET => 'INTRANET', - self::INTERNET => 'INTERNET', - self::GOOGLE_CLOUD => 'GOOGLE_CLOUD', - ]; - - 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/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_cluster.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_cluster.php deleted file mode 100644 index 3c5c13790d00..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_cluster.php +++ /dev/null @@ -1,111 +0,0 @@ -setNodeTypeConfigs($clusterNodeTypeConfigs); - $request = (new CreateClusterRequest()) - ->setParent($formattedParent) - ->setClusterId($clusterId) - ->setCluster($cluster); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vmwareEngineClient->createCluster($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var Cluster $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 = VmwareEngineClient::privateCloudName( - '[PROJECT]', - '[LOCATION]', - '[PRIVATE_CLOUD]' - ); - $clusterId = '[CLUSTER_ID]'; - - create_cluster_sample($formattedParent, $clusterId); -} -// [END vmwareengine_v1_generated_VmwareEngine_CreateCluster_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_external_access_rule.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_external_access_rule.php deleted file mode 100644 index 8a18f02c5f94..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_external_access_rule.php +++ /dev/null @@ -1,109 +0,0 @@ -setParent($formattedParent) - ->setExternalAccessRule($externalAccessRule) - ->setExternalAccessRuleId($externalAccessRuleId); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vmwareEngineClient->createExternalAccessRule($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var ExternalAccessRule $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 = VmwareEngineClient::networkPolicyName( - '[PROJECT]', - '[LOCATION]', - '[NETWORK_POLICY]' - ); - $externalAccessRuleId = '[EXTERNAL_ACCESS_RULE_ID]'; - - create_external_access_rule_sample($formattedParent, $externalAccessRuleId); -} -// [END vmwareengine_v1_generated_VmwareEngine_CreateExternalAccessRule_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_external_address.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_external_address.php deleted file mode 100644 index 847381723e90..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_external_address.php +++ /dev/null @@ -1,109 +0,0 @@ -setParent($formattedParent) - ->setExternalAddress($externalAddress) - ->setExternalAddressId($externalAddressId); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vmwareEngineClient->createExternalAddress($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var ExternalAddress $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 = VmwareEngineClient::privateCloudName( - '[PROJECT]', - '[LOCATION]', - '[PRIVATE_CLOUD]' - ); - $externalAddressId = '[EXTERNAL_ADDRESS_ID]'; - - create_external_address_sample($formattedParent, $externalAddressId); -} -// [END vmwareengine_v1_generated_VmwareEngine_CreateExternalAddress_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_hcx_activation_key.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_hcx_activation_key.php deleted file mode 100644 index b1719637eb0b..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_hcx_activation_key.php +++ /dev/null @@ -1,108 +0,0 @@ -setParent($formattedParent) - ->setHcxActivationKey($hcxActivationKey) - ->setHcxActivationKeyId($hcxActivationKeyId); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vmwareEngineClient->createHcxActivationKey($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var HcxActivationKey $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 = VmwareEngineClient::privateCloudName( - '[PROJECT]', - '[LOCATION]', - '[PRIVATE_CLOUD]' - ); - $hcxActivationKeyId = '[HCX_ACTIVATION_KEY_ID]'; - - create_hcx_activation_key_sample($formattedParent, $hcxActivationKeyId); -} -// [END vmwareengine_v1_generated_VmwareEngine_CreateHcxActivationKey_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_logging_server.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_logging_server.php deleted file mode 100644 index 51f2f18d9288..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_logging_server.php +++ /dev/null @@ -1,136 +0,0 @@ -setHostname($loggingServerHostname) - ->setPort($loggingServerPort) - ->setProtocol($loggingServerProtocol) - ->setSourceType($loggingServerSourceType); - $request = (new CreateLoggingServerRequest()) - ->setParent($formattedParent) - ->setLoggingServer($loggingServer) - ->setLoggingServerId($loggingServerId); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vmwareEngineClient->createLoggingServer($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var LoggingServer $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 = VmwareEngineClient::privateCloudName( - '[PROJECT]', - '[LOCATION]', - '[PRIVATE_CLOUD]' - ); - $loggingServerHostname = '[HOSTNAME]'; - $loggingServerPort = 0; - $loggingServerProtocol = Protocol::PROTOCOL_UNSPECIFIED; - $loggingServerSourceType = SourceType::SOURCE_TYPE_UNSPECIFIED; - $loggingServerId = '[LOGGING_SERVER_ID]'; - - create_logging_server_sample( - $formattedParent, - $loggingServerHostname, - $loggingServerPort, - $loggingServerProtocol, - $loggingServerSourceType, - $loggingServerId - ); -} -// [END vmwareengine_v1_generated_VmwareEngine_CreateLoggingServer_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_management_dns_zone_binding.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_management_dns_zone_binding.php deleted file mode 100644 index 3a988bbd9eff..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_management_dns_zone_binding.php +++ /dev/null @@ -1,116 +0,0 @@ -setParent($formattedParent) - ->setManagementDnsZoneBinding($managementDnsZoneBinding) - ->setManagementDnsZoneBindingId($managementDnsZoneBindingId); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vmwareEngineClient->createManagementDnsZoneBinding($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var ManagementDnsZoneBinding $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 = VmwareEngineClient::privateCloudName( - '[PROJECT]', - '[LOCATION]', - '[PRIVATE_CLOUD]' - ); - $managementDnsZoneBindingId = '[MANAGEMENT_DNS_ZONE_BINDING_ID]'; - - create_management_dns_zone_binding_sample($formattedParent, $managementDnsZoneBindingId); -} -// [END vmwareengine_v1_generated_VmwareEngine_CreateManagementDnsZoneBinding_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_network_peering.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_network_peering.php deleted file mode 100644 index 6b4cd697429f..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_network_peering.php +++ /dev/null @@ -1,140 +0,0 @@ -setPeerNetwork($networkPeeringPeerNetwork) - ->setPeerNetworkType($networkPeeringPeerNetworkType) - ->setVmwareEngineNetwork($formattedNetworkPeeringVmwareEngineNetwork); - $request = (new CreateNetworkPeeringRequest()) - ->setParent($formattedParent) - ->setNetworkPeeringId($networkPeeringId) - ->setNetworkPeering($networkPeering); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vmwareEngineClient->createNetworkPeering($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var NetworkPeering $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 = VmwareEngineClient::locationName('[PROJECT]', '[LOCATION]'); - $networkPeeringId = '[NETWORK_PEERING_ID]'; - $networkPeeringPeerNetwork = '[PEER_NETWORK]'; - $networkPeeringPeerNetworkType = PeerNetworkType::PEER_NETWORK_TYPE_UNSPECIFIED; - $formattedNetworkPeeringVmwareEngineNetwork = VmwareEngineClient::vmwareEngineNetworkName( - '[PROJECT]', - '[LOCATION]', - '[VMWARE_ENGINE_NETWORK]' - ); - - create_network_peering_sample( - $formattedParent, - $networkPeeringId, - $networkPeeringPeerNetwork, - $networkPeeringPeerNetworkType, - $formattedNetworkPeeringVmwareEngineNetwork - ); -} -// [END vmwareengine_v1_generated_VmwareEngine_CreateNetworkPeering_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_network_policy.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_network_policy.php deleted file mode 100644 index f15be3f399c7..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_network_policy.php +++ /dev/null @@ -1,115 +0,0 @@ -setEdgeServicesCidr($networkPolicyEdgeServicesCidr); - $request = (new CreateNetworkPolicyRequest()) - ->setParent($formattedParent) - ->setNetworkPolicyId($networkPolicyId) - ->setNetworkPolicy($networkPolicy); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vmwareEngineClient->createNetworkPolicy($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var NetworkPolicy $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 = VmwareEngineClient::locationName('[PROJECT]', '[LOCATION]'); - $networkPolicyId = '[NETWORK_POLICY_ID]'; - $networkPolicyEdgeServicesCidr = '[EDGE_SERVICES_CIDR]'; - - create_network_policy_sample($formattedParent, $networkPolicyId, $networkPolicyEdgeServicesCidr); -} -// [END vmwareengine_v1_generated_VmwareEngine_CreateNetworkPolicy_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_private_cloud.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_private_cloud.php deleted file mode 100644 index 82e975c3daf0..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_private_cloud.php +++ /dev/null @@ -1,139 +0,0 @@ -setManagementCidr($privateCloudNetworkConfigManagementCidr); - $privateCloudManagementClusterNodeTypeConfigs = []; - $privateCloudManagementCluster = (new ManagementCluster()) - ->setClusterId($privateCloudManagementClusterClusterId) - ->setNodeTypeConfigs($privateCloudManagementClusterNodeTypeConfigs); - $privateCloud = (new PrivateCloud()) - ->setNetworkConfig($privateCloudNetworkConfig) - ->setManagementCluster($privateCloudManagementCluster); - $request = (new CreatePrivateCloudRequest()) - ->setParent($formattedParent) - ->setPrivateCloudId($privateCloudId) - ->setPrivateCloud($privateCloud); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vmwareEngineClient->createPrivateCloud($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var PrivateCloud $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 = VmwareEngineClient::locationName('[PROJECT]', '[LOCATION]'); - $privateCloudId = '[PRIVATE_CLOUD_ID]'; - $privateCloudNetworkConfigManagementCidr = '[MANAGEMENT_CIDR]'; - $privateCloudManagementClusterClusterId = '[CLUSTER_ID]'; - - create_private_cloud_sample( - $formattedParent, - $privateCloudId, - $privateCloudNetworkConfigManagementCidr, - $privateCloudManagementClusterClusterId - ); -} -// [END vmwareengine_v1_generated_VmwareEngine_CreatePrivateCloud_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_private_connection.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_private_connection.php deleted file mode 100644 index 07886cb7aba0..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_private_connection.php +++ /dev/null @@ -1,150 +0,0 @@ -setVmwareEngineNetwork($formattedPrivateConnectionVmwareEngineNetwork) - ->setType($privateConnectionType) - ->setServiceNetwork($formattedPrivateConnectionServiceNetwork); - $request = (new CreatePrivateConnectionRequest()) - ->setParent($formattedParent) - ->setPrivateConnectionId($privateConnectionId) - ->setPrivateConnection($privateConnection); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vmwareEngineClient->createPrivateConnection($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var PrivateConnection $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 = VmwareEngineClient::locationName('[PROJECT]', '[LOCATION]'); - $privateConnectionId = '[PRIVATE_CONNECTION_ID]'; - $formattedPrivateConnectionVmwareEngineNetwork = VmwareEngineClient::vmwareEngineNetworkName( - '[PROJECT]', - '[LOCATION]', - '[VMWARE_ENGINE_NETWORK]' - ); - $privateConnectionType = Type::TYPE_UNSPECIFIED; - $formattedPrivateConnectionServiceNetwork = VmwareEngineClient::networkName( - '[PROJECT]', - '[NETWORK]' - ); - - create_private_connection_sample( - $formattedParent, - $privateConnectionId, - $formattedPrivateConnectionVmwareEngineNetwork, - $privateConnectionType, - $formattedPrivateConnectionServiceNetwork - ); -} -// [END vmwareengine_v1_generated_VmwareEngine_CreatePrivateConnection_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_vmware_engine_network.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_vmware_engine_network.php deleted file mode 100644 index a6341f8c1c21..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/create_vmware_engine_network.php +++ /dev/null @@ -1,118 +0,0 @@ -setType($vmwareEngineNetworkType); - $request = (new CreateVmwareEngineNetworkRequest()) - ->setParent($formattedParent) - ->setVmwareEngineNetworkId($vmwareEngineNetworkId) - ->setVmwareEngineNetwork($vmwareEngineNetwork); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vmwareEngineClient->createVmwareEngineNetwork($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var VmwareEngineNetwork $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 = VmwareEngineClient::locationName('[PROJECT]', '[LOCATION]'); - $vmwareEngineNetworkId = '[VMWARE_ENGINE_NETWORK_ID]'; - $vmwareEngineNetworkType = Type::TYPE_UNSPECIFIED; - - create_vmware_engine_network_sample( - $formattedParent, - $vmwareEngineNetworkId, - $vmwareEngineNetworkType - ); -} -// [END vmwareengine_v1_generated_VmwareEngine_CreateVmwareEngineNetwork_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_cluster.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_cluster.php deleted file mode 100644 index 8b52ee95d96c..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_cluster.php +++ /dev/null @@ -1,92 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vmwareEngineClient->deleteCluster($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 = VmwareEngineClient::clusterName( - '[PROJECT]', - '[LOCATION]', - '[PRIVATE_CLOUD]', - '[CLUSTER]' - ); - - delete_cluster_sample($formattedName); -} -// [END vmwareengine_v1_generated_VmwareEngine_DeleteCluster_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_external_access_rule.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_external_access_rule.php deleted file mode 100644 index 698ef6e0513e..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_external_access_rule.php +++ /dev/null @@ -1,89 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vmwareEngineClient->deleteExternalAccessRule($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 = VmwareEngineClient::externalAccessRuleName( - '[PROJECT]', - '[LOCATION]', - '[NETWORK_POLICY]', - '[EXTERNAL_ACCESS_RULE]' - ); - - delete_external_access_rule_sample($formattedName); -} -// [END vmwareengine_v1_generated_VmwareEngine_DeleteExternalAccessRule_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_external_address.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_external_address.php deleted file mode 100644 index 05a16494102e..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_external_address.php +++ /dev/null @@ -1,91 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vmwareEngineClient->deleteExternalAddress($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 = VmwareEngineClient::externalAddressName( - '[PROJECT]', - '[LOCATION]', - '[PRIVATE_CLOUD]', - '[EXTERNAL_ADDRESS]' - ); - - delete_external_address_sample($formattedName); -} -// [END vmwareengine_v1_generated_VmwareEngine_DeleteExternalAddress_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_logging_server.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_logging_server.php deleted file mode 100644 index f0925c4a3122..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_logging_server.php +++ /dev/null @@ -1,89 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vmwareEngineClient->deleteLoggingServer($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 = VmwareEngineClient::loggingServerName( - '[PROJECT]', - '[LOCATION]', - '[PRIVATE_CLOUD]', - '[LOGGING_SERVER]' - ); - - delete_logging_server_sample($formattedName); -} -// [END vmwareengine_v1_generated_VmwareEngine_DeleteLoggingServer_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_management_dns_zone_binding.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_management_dns_zone_binding.php deleted file mode 100644 index f468098c83a1..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_management_dns_zone_binding.php +++ /dev/null @@ -1,91 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vmwareEngineClient->deleteManagementDnsZoneBinding($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 = VmwareEngineClient::managementDnsZoneBindingName( - '[PROJECT]', - '[LOCATION]', - '[PRIVATE_CLOUD]', - '[MANAGEMENT_DNS_ZONE_BINDING]' - ); - - delete_management_dns_zone_binding_sample($formattedName); -} -// [END vmwareengine_v1_generated_VmwareEngine_DeleteManagementDnsZoneBinding_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_network_peering.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_network_peering.php deleted file mode 100644 index f7d05f9ea5b9..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_network_peering.php +++ /dev/null @@ -1,91 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vmwareEngineClient->deleteNetworkPeering($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 = VmwareEngineClient::networkPeeringName( - '[PROJECT]', - '[LOCATION]', - '[NETWORK_PEERING]' - ); - - delete_network_peering_sample($formattedName); -} -// [END vmwareengine_v1_generated_VmwareEngine_DeleteNetworkPeering_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_network_policy.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_network_policy.php deleted file mode 100644 index 91ff032245c4..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_network_policy.php +++ /dev/null @@ -1,90 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vmwareEngineClient->deleteNetworkPolicy($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 = VmwareEngineClient::networkPolicyName( - '[PROJECT]', - '[LOCATION]', - '[NETWORK_POLICY]' - ); - - delete_network_policy_sample($formattedName); -} -// [END vmwareengine_v1_generated_VmwareEngine_DeleteNetworkPolicy_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_private_cloud.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_private_cloud.php deleted file mode 100644 index 617474ba14b2..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_private_cloud.php +++ /dev/null @@ -1,101 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vmwareEngineClient->deletePrivateCloud($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var PrivateCloud $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 = VmwareEngineClient::privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); - - delete_private_cloud_sample($formattedName); -} -// [END vmwareengine_v1_generated_VmwareEngine_DeletePrivateCloud_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_private_connection.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_private_connection.php deleted file mode 100644 index d2bf7afb7b8a..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_private_connection.php +++ /dev/null @@ -1,90 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vmwareEngineClient->deletePrivateConnection($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 = VmwareEngineClient::privateConnectionName( - '[PROJECT]', - '[LOCATION]', - '[PRIVATE_CONNECTION]' - ); - - delete_private_connection_sample($formattedName); -} -// [END vmwareengine_v1_generated_VmwareEngine_DeletePrivateConnection_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_vmware_engine_network.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_vmware_engine_network.php deleted file mode 100644 index bf2516710177..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/delete_vmware_engine_network.php +++ /dev/null @@ -1,91 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vmwareEngineClient->deleteVmwareEngineNetwork($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 = VmwareEngineClient::vmwareEngineNetworkName( - '[PROJECT]', - '[LOCATION]', - '[VMWARE_ENGINE_NETWORK]' - ); - - delete_vmware_engine_network_sample($formattedName); -} -// [END vmwareengine_v1_generated_VmwareEngine_DeleteVmwareEngineNetwork_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/fetch_network_policy_external_addresses.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/fetch_network_policy_external_addresses.php deleted file mode 100644 index 7b3012a15ab6..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/fetch_network_policy_external_addresses.php +++ /dev/null @@ -1,85 +0,0 @@ -setNetworkPolicy($formattedNetworkPolicy); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $vmwareEngineClient->fetchNetworkPolicyExternalAddresses($request); - - /** @var ExternalAddress $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 -{ - $formattedNetworkPolicy = VmwareEngineClient::networkPolicyName( - '[PROJECT]', - '[LOCATION]', - '[NETWORK_POLICY]' - ); - - fetch_network_policy_external_addresses_sample($formattedNetworkPolicy); -} -// [END vmwareengine_v1_generated_VmwareEngine_FetchNetworkPolicyExternalAddresses_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_cluster.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_cluster.php deleted file mode 100644 index dbfceec11a84..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_cluster.php +++ /dev/null @@ -1,80 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var Cluster $response */ - $response = $vmwareEngineClient->getCluster($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 = VmwareEngineClient::clusterName( - '[PROJECT]', - '[LOCATION]', - '[PRIVATE_CLOUD]', - '[CLUSTER]' - ); - - get_cluster_sample($formattedName); -} -// [END vmwareengine_v1_generated_VmwareEngine_GetCluster_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_dns_bind_permission.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_dns_bind_permission.php deleted file mode 100644 index b8bd0cfe9f5e..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_dns_bind_permission.php +++ /dev/null @@ -1,78 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var DnsBindPermission $response */ - $response = $vmwareEngineClient->getDnsBindPermission($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 = VmwareEngineClient::dnsBindPermissionName('[PROJECT]', '[LOCATION]'); - - get_dns_bind_permission_sample($formattedName); -} -// [END vmwareengine_v1_generated_VmwareEngine_GetDnsBindPermission_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_dns_forwarding.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_dns_forwarding.php deleted file mode 100644 index c296fa15e107..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_dns_forwarding.php +++ /dev/null @@ -1,79 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var DnsForwarding $response */ - $response = $vmwareEngineClient->getDnsForwarding($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 = VmwareEngineClient::dnsForwardingName( - '[PROJECT]', - '[LOCATION]', - '[PRIVATE_CLOUD]' - ); - - get_dns_forwarding_sample($formattedName); -} -// [END vmwareengine_v1_generated_VmwareEngine_GetDnsForwarding_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_external_access_rule.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_external_access_rule.php deleted file mode 100644 index 4956f4f39764..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_external_access_rule.php +++ /dev/null @@ -1,80 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var ExternalAccessRule $response */ - $response = $vmwareEngineClient->getExternalAccessRule($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 = VmwareEngineClient::externalAccessRuleName( - '[PROJECT]', - '[LOCATION]', - '[NETWORK_POLICY]', - '[EXTERNAL_ACCESS_RULE]' - ); - - get_external_access_rule_sample($formattedName); -} -// [END vmwareengine_v1_generated_VmwareEngine_GetExternalAccessRule_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_external_address.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_external_address.php deleted file mode 100644 index e03eaeeec78c..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_external_address.php +++ /dev/null @@ -1,80 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var ExternalAddress $response */ - $response = $vmwareEngineClient->getExternalAddress($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 = VmwareEngineClient::externalAddressName( - '[PROJECT]', - '[LOCATION]', - '[PRIVATE_CLOUD]', - '[EXTERNAL_ADDRESS]' - ); - - get_external_address_sample($formattedName); -} -// [END vmwareengine_v1_generated_VmwareEngine_GetExternalAddress_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_hcx_activation_key.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_hcx_activation_key.php deleted file mode 100644 index 977eb9e46998..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_hcx_activation_key.php +++ /dev/null @@ -1,80 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var HcxActivationKey $response */ - $response = $vmwareEngineClient->getHcxActivationKey($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 = VmwareEngineClient::hcxActivationKeyName( - '[PROJECT]', - '[LOCATION]', - '[PRIVATE_CLOUD]', - '[HCX_ACTIVATION_KEY]' - ); - - get_hcx_activation_key_sample($formattedName); -} -// [END vmwareengine_v1_generated_VmwareEngine_GetHcxActivationKey_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_iam_policy.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_iam_policy.php deleted file mode 100644 index 218de3f0f81a..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/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 = $vmwareEngineClient->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 vmwareengine_v1_generated_VmwareEngine_GetIamPolicy_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_location.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_location.php deleted file mode 100644 index ac8afb52a829..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/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 vmwareengine_v1_generated_VmwareEngine_GetLocation_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_logging_server.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_logging_server.php deleted file mode 100644 index d1ad1d3d5670..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_logging_server.php +++ /dev/null @@ -1,80 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var LoggingServer $response */ - $response = $vmwareEngineClient->getLoggingServer($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 = VmwareEngineClient::loggingServerName( - '[PROJECT]', - '[LOCATION]', - '[PRIVATE_CLOUD]', - '[LOGGING_SERVER]' - ); - - get_logging_server_sample($formattedName); -} -// [END vmwareengine_v1_generated_VmwareEngine_GetLoggingServer_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_management_dns_zone_binding.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_management_dns_zone_binding.php deleted file mode 100644 index 141b5705d3d5..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_management_dns_zone_binding.php +++ /dev/null @@ -1,80 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var ManagementDnsZoneBinding $response */ - $response = $vmwareEngineClient->getManagementDnsZoneBinding($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 = VmwareEngineClient::managementDnsZoneBindingName( - '[PROJECT]', - '[LOCATION]', - '[PRIVATE_CLOUD]', - '[MANAGEMENT_DNS_ZONE_BINDING]' - ); - - get_management_dns_zone_binding_sample($formattedName); -} -// [END vmwareengine_v1_generated_VmwareEngine_GetManagementDnsZoneBinding_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_network_peering.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_network_peering.php deleted file mode 100644 index 9f67d8a9023d..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_network_peering.php +++ /dev/null @@ -1,82 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var NetworkPeering $response */ - $response = $vmwareEngineClient->getNetworkPeering($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 = VmwareEngineClient::networkPeeringName( - '[PROJECT]', - '[LOCATION]', - '[NETWORK_PEERING]' - ); - - get_network_peering_sample($formattedName); -} -// [END vmwareengine_v1_generated_VmwareEngine_GetNetworkPeering_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_network_policy.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_network_policy.php deleted file mode 100644 index 1858a6bb51b4..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_network_policy.php +++ /dev/null @@ -1,79 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var NetworkPolicy $response */ - $response = $vmwareEngineClient->getNetworkPolicy($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 = VmwareEngineClient::networkPolicyName( - '[PROJECT]', - '[LOCATION]', - '[NETWORK_POLICY]' - ); - - get_network_policy_sample($formattedName); -} -// [END vmwareengine_v1_generated_VmwareEngine_GetNetworkPolicy_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_node.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_node.php deleted file mode 100644 index 606068f1bd00..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_node.php +++ /dev/null @@ -1,79 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var Node $response */ - $response = $vmwareEngineClient->getNode($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 = VmwareEngineClient::nodeName( - '[PROJECT]', - '[LOCATION]', - '[PRIVATE_CLOUD]', - '[CLUSTER]', - '[NODE]' - ); - - get_node_sample($formattedName); -} -// [END vmwareengine_v1_generated_VmwareEngine_GetNode_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_node_type.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_node_type.php deleted file mode 100644 index bf314f1c3ca7..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_node_type.php +++ /dev/null @@ -1,75 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var NodeType $response */ - $response = $vmwareEngineClient->getNodeType($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 = VmwareEngineClient::nodeTypeName('[PROJECT]', '[LOCATION]', '[NODE_TYPE]'); - - get_node_type_sample($formattedName); -} -// [END vmwareengine_v1_generated_VmwareEngine_GetNodeType_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_private_cloud.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_private_cloud.php deleted file mode 100644 index aea564280e7b..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_private_cloud.php +++ /dev/null @@ -1,75 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var PrivateCloud $response */ - $response = $vmwareEngineClient->getPrivateCloud($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 = VmwareEngineClient::privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); - - get_private_cloud_sample($formattedName); -} -// [END vmwareengine_v1_generated_VmwareEngine_GetPrivateCloud_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_private_connection.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_private_connection.php deleted file mode 100644 index 5e93253c5144..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_private_connection.php +++ /dev/null @@ -1,81 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var PrivateConnection $response */ - $response = $vmwareEngineClient->getPrivateConnection($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 = VmwareEngineClient::privateConnectionName( - '[PROJECT]', - '[LOCATION]', - '[PRIVATE_CONNECTION]' - ); - - get_private_connection_sample($formattedName); -} -// [END vmwareengine_v1_generated_VmwareEngine_GetPrivateConnection_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_subnet.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_subnet.php deleted file mode 100644 index 3400ca7377a3..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_subnet.php +++ /dev/null @@ -1,80 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var Subnet $response */ - $response = $vmwareEngineClient->getSubnet($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 = VmwareEngineClient::subnetName( - '[PROJECT]', - '[LOCATION]', - '[PRIVATE_CLOUD]', - '[SUBNET]' - ); - - get_subnet_sample($formattedName); -} -// [END vmwareengine_v1_generated_VmwareEngine_GetSubnet_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_vmware_engine_network.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_vmware_engine_network.php deleted file mode 100644 index 0000f359e144..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/get_vmware_engine_network.php +++ /dev/null @@ -1,82 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var VmwareEngineNetwork $response */ - $response = $vmwareEngineClient->getVmwareEngineNetwork($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 = VmwareEngineClient::vmwareEngineNetworkName( - '[PROJECT]', - '[LOCATION]', - '[VMWARE_ENGINE_NETWORK]' - ); - - get_vmware_engine_network_sample($formattedName); -} -// [END vmwareengine_v1_generated_VmwareEngine_GetVmwareEngineNetwork_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/grant_dns_bind_permission.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/grant_dns_bind_permission.php deleted file mode 100644 index 9f2f39f426fb..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/grant_dns_bind_permission.php +++ /dev/null @@ -1,94 +0,0 @@ -setName($formattedName) - ->setPrincipal($principal); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vmwareEngineClient->grantDnsBindPermission($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var DnsBindPermission $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 = VmwareEngineClient::dnsBindPermissionName('[PROJECT]', '[LOCATION]'); - - grant_dns_bind_permission_sample($formattedName); -} -// [END vmwareengine_v1_generated_VmwareEngine_GrantDnsBindPermission_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_clusters.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_clusters.php deleted file mode 100644 index 189100b2a36d..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_clusters.php +++ /dev/null @@ -1,84 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $vmwareEngineClient->listClusters($request); - - /** @var Cluster $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 = VmwareEngineClient::privateCloudName( - '[PROJECT]', - '[LOCATION]', - '[PRIVATE_CLOUD]' - ); - - list_clusters_sample($formattedParent); -} -// [END vmwareengine_v1_generated_VmwareEngine_ListClusters_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_external_access_rules.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_external_access_rules.php deleted file mode 100644 index 7baf8030d44c..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_external_access_rules.php +++ /dev/null @@ -1,84 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $vmwareEngineClient->listExternalAccessRules($request); - - /** @var ExternalAccessRule $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 = VmwareEngineClient::networkPolicyName( - '[PROJECT]', - '[LOCATION]', - '[NETWORK_POLICY]' - ); - - list_external_access_rules_sample($formattedParent); -} -// [END vmwareengine_v1_generated_VmwareEngine_ListExternalAccessRules_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_external_addresses.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_external_addresses.php deleted file mode 100644 index ff1e309f4c08..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_external_addresses.php +++ /dev/null @@ -1,86 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $vmwareEngineClient->listExternalAddresses($request); - - /** @var ExternalAddress $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 = VmwareEngineClient::privateCloudName( - '[PROJECT]', - '[LOCATION]', - '[PRIVATE_CLOUD]' - ); - - list_external_addresses_sample($formattedParent); -} -// [END vmwareengine_v1_generated_VmwareEngine_ListExternalAddresses_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_hcx_activation_keys.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_hcx_activation_keys.php deleted file mode 100644 index 590b1edf06bb..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_hcx_activation_keys.php +++ /dev/null @@ -1,85 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $vmwareEngineClient->listHcxActivationKeys($request); - - /** @var HcxActivationKey $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 = VmwareEngineClient::privateCloudName( - '[PROJECT]', - '[LOCATION]', - '[PRIVATE_CLOUD]' - ); - - list_hcx_activation_keys_sample($formattedParent); -} -// [END vmwareengine_v1_generated_VmwareEngine_ListHcxActivationKeys_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_locations.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_locations.php deleted file mode 100644 index 07ea876ceb92..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/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 vmwareengine_v1_generated_VmwareEngine_ListLocations_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_logging_servers.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_logging_servers.php deleted file mode 100644 index 84f00b97e71c..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_logging_servers.php +++ /dev/null @@ -1,86 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $vmwareEngineClient->listLoggingServers($request); - - /** @var LoggingServer $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 = VmwareEngineClient::privateCloudName( - '[PROJECT]', - '[LOCATION]', - '[PRIVATE_CLOUD]' - ); - - list_logging_servers_sample($formattedParent); -} -// [END vmwareengine_v1_generated_VmwareEngine_ListLoggingServers_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_management_dns_zone_bindings.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_management_dns_zone_bindings.php deleted file mode 100644 index 9f9c978459a8..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_management_dns_zone_bindings.php +++ /dev/null @@ -1,85 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $vmwareEngineClient->listManagementDnsZoneBindings($request); - - /** @var ManagementDnsZoneBinding $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 = VmwareEngineClient::privateCloudName( - '[PROJECT]', - '[LOCATION]', - '[PRIVATE_CLOUD]' - ); - - list_management_dns_zone_bindings_sample($formattedParent); -} -// [END vmwareengine_v1_generated_VmwareEngine_ListManagementDnsZoneBindings_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_network_peerings.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_network_peerings.php deleted file mode 100644 index 9935aac17f4c..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_network_peerings.php +++ /dev/null @@ -1,80 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $vmwareEngineClient->listNetworkPeerings($request); - - /** @var NetworkPeering $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 = VmwareEngineClient::locationName('[PROJECT]', '[LOCATION]'); - - list_network_peerings_sample($formattedParent); -} -// [END vmwareengine_v1_generated_VmwareEngine_ListNetworkPeerings_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_network_policies.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_network_policies.php deleted file mode 100644 index 4db6647a7f66..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_network_policies.php +++ /dev/null @@ -1,79 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $vmwareEngineClient->listNetworkPolicies($request); - - /** @var NetworkPolicy $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 = VmwareEngineClient::locationName('[PROJECT]', '[LOCATION]'); - - list_network_policies_sample($formattedParent); -} -// [END vmwareengine_v1_generated_VmwareEngine_ListNetworkPolicies_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_node_types.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_node_types.php deleted file mode 100644 index 210d752a2c2e..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_node_types.php +++ /dev/null @@ -1,80 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $vmwareEngineClient->listNodeTypes($request); - - /** @var NodeType $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 = VmwareEngineClient::locationName('[PROJECT]', '[LOCATION]'); - - list_node_types_sample($formattedParent); -} -// [END vmwareengine_v1_generated_VmwareEngine_ListNodeTypes_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_nodes.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_nodes.php deleted file mode 100644 index 1993040a46cd..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_nodes.php +++ /dev/null @@ -1,85 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $vmwareEngineClient->listNodes($request); - - /** @var Node $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 = VmwareEngineClient::clusterName( - '[PROJECT]', - '[LOCATION]', - '[PRIVATE_CLOUD]', - '[CLUSTER]' - ); - - list_nodes_sample($formattedParent); -} -// [END vmwareengine_v1_generated_VmwareEngine_ListNodes_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_peering_routes.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_peering_routes.php deleted file mode 100644 index 930f29bc3bbd..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_peering_routes.php +++ /dev/null @@ -1,84 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $vmwareEngineClient->listPeeringRoutes($request); - - /** @var PeeringRoute $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 = VmwareEngineClient::networkPeeringName( - '[PROJECT]', - '[LOCATION]', - '[NETWORK_PEERING]' - ); - - list_peering_routes_sample($formattedParent); -} -// [END vmwareengine_v1_generated_VmwareEngine_ListPeeringRoutes_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_private_clouds.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_private_clouds.php deleted file mode 100644 index fdf995492516..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_private_clouds.php +++ /dev/null @@ -1,80 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $vmwareEngineClient->listPrivateClouds($request); - - /** @var PrivateCloud $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 = VmwareEngineClient::locationName('[PROJECT]', '[LOCATION]'); - - list_private_clouds_sample($formattedParent); -} -// [END vmwareengine_v1_generated_VmwareEngine_ListPrivateClouds_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_private_connection_peering_routes.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_private_connection_peering_routes.php deleted file mode 100644 index 323d453f543f..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_private_connection_peering_routes.php +++ /dev/null @@ -1,83 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $vmwareEngineClient->listPrivateConnectionPeeringRoutes($request); - - /** @var PeeringRoute $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 = VmwareEngineClient::privateConnectionName( - '[PROJECT]', - '[LOCATION]', - '[PRIVATE_CONNECTION]' - ); - - list_private_connection_peering_routes_sample($formattedParent); -} -// [END vmwareengine_v1_generated_VmwareEngine_ListPrivateConnectionPeeringRoutes_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_private_connections.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_private_connections.php deleted file mode 100644 index 48da41e3ed40..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_private_connections.php +++ /dev/null @@ -1,79 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $vmwareEngineClient->listPrivateConnections($request); - - /** @var PrivateConnection $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 = VmwareEngineClient::locationName('[PROJECT]', '[LOCATION]'); - - list_private_connections_sample($formattedParent); -} -// [END vmwareengine_v1_generated_VmwareEngine_ListPrivateConnections_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_subnets.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_subnets.php deleted file mode 100644 index 92c76d17c3eb..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_subnets.php +++ /dev/null @@ -1,85 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $vmwareEngineClient->listSubnets($request); - - /** @var Subnet $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 = VmwareEngineClient::privateCloudName( - '[PROJECT]', - '[LOCATION]', - '[PRIVATE_CLOUD]' - ); - - list_subnets_sample($formattedParent); -} -// [END vmwareengine_v1_generated_VmwareEngine_ListSubnets_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_vmware_engine_networks.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_vmware_engine_networks.php deleted file mode 100644 index 6d9b5d6c6211..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/list_vmware_engine_networks.php +++ /dev/null @@ -1,79 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $vmwareEngineClient->listVmwareEngineNetworks($request); - - /** @var VmwareEngineNetwork $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 = VmwareEngineClient::locationName('[PROJECT]', '[LOCATION]'); - - list_vmware_engine_networks_sample($formattedParent); -} -// [END vmwareengine_v1_generated_VmwareEngine_ListVmwareEngineNetworks_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/repair_management_dns_zone_binding.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/repair_management_dns_zone_binding.php deleted file mode 100644 index c28b6ea8229c..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/repair_management_dns_zone_binding.php +++ /dev/null @@ -1,93 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vmwareEngineClient->repairManagementDnsZoneBinding($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var ManagementDnsZoneBinding $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 = VmwareEngineClient::managementDnsZoneBindingName( - '[PROJECT]', - '[LOCATION]', - '[PRIVATE_CLOUD]', - '[MANAGEMENT_DNS_ZONE_BINDING]' - ); - - repair_management_dns_zone_binding_sample($formattedName); -} -// [END vmwareengine_v1_generated_VmwareEngine_RepairManagementDnsZoneBinding_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/reset_nsx_credentials.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/reset_nsx_credentials.php deleted file mode 100644 index 0f53ba78c338..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/reset_nsx_credentials.php +++ /dev/null @@ -1,92 +0,0 @@ -setPrivateCloud($formattedPrivateCloud); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vmwareEngineClient->resetNsxCredentials($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var PrivateCloud $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 -{ - $formattedPrivateCloud = VmwareEngineClient::privateCloudName( - '[PROJECT]', - '[LOCATION]', - '[PRIVATE_CLOUD]' - ); - - reset_nsx_credentials_sample($formattedPrivateCloud); -} -// [END vmwareengine_v1_generated_VmwareEngine_ResetNsxCredentials_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/reset_vcenter_credentials.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/reset_vcenter_credentials.php deleted file mode 100644 index b65e64903ea9..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/reset_vcenter_credentials.php +++ /dev/null @@ -1,92 +0,0 @@ -setPrivateCloud($formattedPrivateCloud); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vmwareEngineClient->resetVcenterCredentials($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var PrivateCloud $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 -{ - $formattedPrivateCloud = VmwareEngineClient::privateCloudName( - '[PROJECT]', - '[LOCATION]', - '[PRIVATE_CLOUD]' - ); - - reset_vcenter_credentials_sample($formattedPrivateCloud); -} -// [END vmwareengine_v1_generated_VmwareEngine_ResetVcenterCredentials_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/revoke_dns_bind_permission.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/revoke_dns_bind_permission.php deleted file mode 100644 index a42c8d26fa98..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/revoke_dns_bind_permission.php +++ /dev/null @@ -1,93 +0,0 @@ -setName($formattedName) - ->setPrincipal($principal); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vmwareEngineClient->revokeDnsBindPermission($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var DnsBindPermission $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 = VmwareEngineClient::dnsBindPermissionName('[PROJECT]', '[LOCATION]'); - - revoke_dns_bind_permission_sample($formattedName); -} -// [END vmwareengine_v1_generated_VmwareEngine_RevokeDnsBindPermission_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/set_iam_policy.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/set_iam_policy.php deleted file mode 100644 index 013961cc1ad4..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/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 = $vmwareEngineClient->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 vmwareengine_v1_generated_VmwareEngine_SetIamPolicy_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/show_nsx_credentials.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/show_nsx_credentials.php deleted file mode 100644 index 000aa3d51ecb..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/show_nsx_credentials.php +++ /dev/null @@ -1,80 +0,0 @@ -setPrivateCloud($formattedPrivateCloud); - - // Call the API and handle any network failures. - try { - /** @var Credentials $response */ - $response = $vmwareEngineClient->showNsxCredentials($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 -{ - $formattedPrivateCloud = VmwareEngineClient::privateCloudName( - '[PROJECT]', - '[LOCATION]', - '[PRIVATE_CLOUD]' - ); - - show_nsx_credentials_sample($formattedPrivateCloud); -} -// [END vmwareengine_v1_generated_VmwareEngine_ShowNsxCredentials_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/show_vcenter_credentials.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/show_vcenter_credentials.php deleted file mode 100644 index c050051193c2..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/show_vcenter_credentials.php +++ /dev/null @@ -1,80 +0,0 @@ -setPrivateCloud($formattedPrivateCloud); - - // Call the API and handle any network failures. - try { - /** @var Credentials $response */ - $response = $vmwareEngineClient->showVcenterCredentials($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 -{ - $formattedPrivateCloud = VmwareEngineClient::privateCloudName( - '[PROJECT]', - '[LOCATION]', - '[PRIVATE_CLOUD]' - ); - - show_vcenter_credentials_sample($formattedPrivateCloud); -} -// [END vmwareengine_v1_generated_VmwareEngine_ShowVcenterCredentials_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/test_iam_permissions.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/test_iam_permissions.php deleted file mode 100644 index afe66a91da5c..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/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 = $vmwareEngineClient->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 vmwareengine_v1_generated_VmwareEngine_TestIamPermissions_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/undelete_private_cloud.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/undelete_private_cloud.php deleted file mode 100644 index 3163b084b6e3..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/undelete_private_cloud.php +++ /dev/null @@ -1,90 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vmwareEngineClient->undeletePrivateCloud($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var PrivateCloud $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 = VmwareEngineClient::privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); - - undelete_private_cloud_sample($formattedName); -} -// [END vmwareengine_v1_generated_VmwareEngine_UndeletePrivateCloud_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_cluster.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_cluster.php deleted file mode 100644 index 8c772d60d635..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_cluster.php +++ /dev/null @@ -1,82 +0,0 @@ -setNodeTypeConfigs($clusterNodeTypeConfigs); - $request = (new UpdateClusterRequest()) - ->setUpdateMask($updateMask) - ->setCluster($cluster); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vmwareEngineClient->updateCluster($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var Cluster $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 vmwareengine_v1_generated_VmwareEngine_UpdateCluster_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_dns_forwarding.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_dns_forwarding.php deleted file mode 100644 index ec1f793a6d48..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_dns_forwarding.php +++ /dev/null @@ -1,101 +0,0 @@ -setDomain($dnsForwardingForwardingRulesDomain) - ->setNameServers($dnsForwardingForwardingRulesNameServers); - $dnsForwardingForwardingRules = [$forwardingRule,]; - $dnsForwarding = (new DnsForwarding()) - ->setForwardingRules($dnsForwardingForwardingRules); - $updateMask = new FieldMask(); - $request = (new UpdateDnsForwardingRequest()) - ->setDnsForwarding($dnsForwarding) - ->setUpdateMask($updateMask); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vmwareEngineClient->updateDnsForwarding($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var DnsForwarding $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 -{ - $dnsForwardingForwardingRulesDomain = '[DOMAIN]'; - $dnsForwardingForwardingRulesNameServersElement = '[NAME_SERVERS]'; - - update_dns_forwarding_sample( - $dnsForwardingForwardingRulesDomain, - $dnsForwardingForwardingRulesNameServersElement - ); -} -// [END vmwareengine_v1_generated_VmwareEngine_UpdateDnsForwarding_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_external_access_rule.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_external_access_rule.php deleted file mode 100644 index e396f90fc681..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_external_access_rule.php +++ /dev/null @@ -1,75 +0,0 @@ -setUpdateMask($updateMask) - ->setExternalAccessRule($externalAccessRule); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vmwareEngineClient->updateExternalAccessRule($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var ExternalAccessRule $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 vmwareengine_v1_generated_VmwareEngine_UpdateExternalAccessRule_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_external_address.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_external_address.php deleted file mode 100644 index 248968f2a981..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_external_address.php +++ /dev/null @@ -1,80 +0,0 @@ -setUpdateMask($updateMask) - ->setExternalAddress($externalAddress); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vmwareEngineClient->updateExternalAddress($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var ExternalAddress $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 vmwareengine_v1_generated_VmwareEngine_UpdateExternalAddress_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_logging_server.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_logging_server.php deleted file mode 100644 index 165fcdd8f615..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_logging_server.php +++ /dev/null @@ -1,110 +0,0 @@ -setHostname($loggingServerHostname) - ->setPort($loggingServerPort) - ->setProtocol($loggingServerProtocol) - ->setSourceType($loggingServerSourceType); - $request = (new UpdateLoggingServerRequest()) - ->setUpdateMask($updateMask) - ->setLoggingServer($loggingServer); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vmwareEngineClient->updateLoggingServer($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var LoggingServer $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 -{ - $loggingServerHostname = '[HOSTNAME]'; - $loggingServerPort = 0; - $loggingServerProtocol = Protocol::PROTOCOL_UNSPECIFIED; - $loggingServerSourceType = SourceType::SOURCE_TYPE_UNSPECIFIED; - - update_logging_server_sample( - $loggingServerHostname, - $loggingServerPort, - $loggingServerProtocol, - $loggingServerSourceType - ); -} -// [END vmwareengine_v1_generated_VmwareEngine_UpdateLoggingServer_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_management_dns_zone_binding.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_management_dns_zone_binding.php deleted file mode 100644 index 66d0f4ec9867..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_management_dns_zone_binding.php +++ /dev/null @@ -1,75 +0,0 @@ -setUpdateMask($updateMask) - ->setManagementDnsZoneBinding($managementDnsZoneBinding); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vmwareEngineClient->updateManagementDnsZoneBinding($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var ManagementDnsZoneBinding $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 vmwareengine_v1_generated_VmwareEngine_UpdateManagementDnsZoneBinding_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_network_peering.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_network_peering.php deleted file mode 100644 index 2777034651b3..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_network_peering.php +++ /dev/null @@ -1,118 +0,0 @@ -setPeerNetwork($networkPeeringPeerNetwork) - ->setPeerNetworkType($networkPeeringPeerNetworkType) - ->setVmwareEngineNetwork($formattedNetworkPeeringVmwareEngineNetwork); - $updateMask = new FieldMask(); - $request = (new UpdateNetworkPeeringRequest()) - ->setNetworkPeering($networkPeering) - ->setUpdateMask($updateMask); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vmwareEngineClient->updateNetworkPeering($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var NetworkPeering $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 -{ - $networkPeeringPeerNetwork = '[PEER_NETWORK]'; - $networkPeeringPeerNetworkType = PeerNetworkType::PEER_NETWORK_TYPE_UNSPECIFIED; - $formattedNetworkPeeringVmwareEngineNetwork = VmwareEngineClient::vmwareEngineNetworkName( - '[PROJECT]', - '[LOCATION]', - '[VMWARE_ENGINE_NETWORK]' - ); - - update_network_peering_sample( - $networkPeeringPeerNetwork, - $networkPeeringPeerNetworkType, - $formattedNetworkPeeringVmwareEngineNetwork - ); -} -// [END vmwareengine_v1_generated_VmwareEngine_UpdateNetworkPeering_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_network_policy.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_network_policy.php deleted file mode 100644 index e9f9c71536b2..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_network_policy.php +++ /dev/null @@ -1,101 +0,0 @@ -setEdgeServicesCidr($networkPolicyEdgeServicesCidr); - $updateMask = new FieldMask(); - $request = (new UpdateNetworkPolicyRequest()) - ->setNetworkPolicy($networkPolicy) - ->setUpdateMask($updateMask); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vmwareEngineClient->updateNetworkPolicy($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var NetworkPolicy $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 -{ - $networkPolicyEdgeServicesCidr = '[EDGE_SERVICES_CIDR]'; - - update_network_policy_sample($networkPolicyEdgeServicesCidr); -} -// [END vmwareengine_v1_generated_VmwareEngine_UpdateNetworkPolicy_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_private_cloud.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_private_cloud.php deleted file mode 100644 index aec482998832..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_private_cloud.php +++ /dev/null @@ -1,118 +0,0 @@ -setManagementCidr($privateCloudNetworkConfigManagementCidr); - $privateCloudManagementClusterNodeTypeConfigs = []; - $privateCloudManagementCluster = (new ManagementCluster()) - ->setClusterId($privateCloudManagementClusterClusterId) - ->setNodeTypeConfigs($privateCloudManagementClusterNodeTypeConfigs); - $privateCloud = (new PrivateCloud()) - ->setNetworkConfig($privateCloudNetworkConfig) - ->setManagementCluster($privateCloudManagementCluster); - $updateMask = new FieldMask(); - $request = (new UpdatePrivateCloudRequest()) - ->setPrivateCloud($privateCloud) - ->setUpdateMask($updateMask); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vmwareEngineClient->updatePrivateCloud($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var PrivateCloud $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 -{ - $privateCloudNetworkConfigManagementCidr = '[MANAGEMENT_CIDR]'; - $privateCloudManagementClusterClusterId = '[CLUSTER_ID]'; - - update_private_cloud_sample( - $privateCloudNetworkConfigManagementCidr, - $privateCloudManagementClusterClusterId - ); -} -// [END vmwareengine_v1_generated_VmwareEngine_UpdatePrivateCloud_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_private_connection.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_private_connection.php deleted file mode 100644 index e8b68cb69618..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_private_connection.php +++ /dev/null @@ -1,129 +0,0 @@ -setVmwareEngineNetwork($formattedPrivateConnectionVmwareEngineNetwork) - ->setType($privateConnectionType) - ->setServiceNetwork($formattedPrivateConnectionServiceNetwork); - $updateMask = new FieldMask(); - $request = (new UpdatePrivateConnectionRequest()) - ->setPrivateConnection($privateConnection) - ->setUpdateMask($updateMask); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vmwareEngineClient->updatePrivateConnection($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var PrivateConnection $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 -{ - $formattedPrivateConnectionVmwareEngineNetwork = VmwareEngineClient::vmwareEngineNetworkName( - '[PROJECT]', - '[LOCATION]', - '[VMWARE_ENGINE_NETWORK]' - ); - $privateConnectionType = Type::TYPE_UNSPECIFIED; - $formattedPrivateConnectionServiceNetwork = VmwareEngineClient::networkName( - '[PROJECT]', - '[NETWORK]' - ); - - update_private_connection_sample( - $formattedPrivateConnectionVmwareEngineNetwork, - $privateConnectionType, - $formattedPrivateConnectionServiceNetwork - ); -} -// [END vmwareengine_v1_generated_VmwareEngine_UpdatePrivateConnection_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_subnet.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_subnet.php deleted file mode 100644 index 36369c95e426..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_subnet.php +++ /dev/null @@ -1,79 +0,0 @@ -setUpdateMask($updateMask) - ->setSubnet($subnet); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vmwareEngineClient->updateSubnet($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var Subnet $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 vmwareengine_v1_generated_VmwareEngine_UpdateSubnet_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_vmware_engine_network.php b/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_vmware_engine_network.php deleted file mode 100644 index c2fac6587ec0..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/samples/V1/VmwareEngineClient/update_vmware_engine_network.php +++ /dev/null @@ -1,90 +0,0 @@ -setType($vmwareEngineNetworkType); - $updateMask = new FieldMask(); - $request = (new UpdateVmwareEngineNetworkRequest()) - ->setVmwareEngineNetwork($vmwareEngineNetwork) - ->setUpdateMask($updateMask); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $vmwareEngineClient->updateVmwareEngineNetwork($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var VmwareEngineNetwork $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 -{ - $vmwareEngineNetworkType = Type::TYPE_UNSPECIFIED; - - update_vmware_engine_network_sample($vmwareEngineNetworkType); -} -// [END vmwareengine_v1_generated_VmwareEngine_UpdateVmwareEngineNetwork_sync] diff --git a/owl-bot-staging/VmwareEngine/v1/src/V1/Client/VmwareEngineClient.php b/owl-bot-staging/VmwareEngine/v1/src/V1/Client/VmwareEngineClient.php deleted file mode 100644 index a3ce75d15f20..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/src/V1/Client/VmwareEngineClient.php +++ /dev/null @@ -1,3013 +0,0 @@ - createClusterAsync(CreateClusterRequest $request, array $optionalArgs = []) - * @method PromiseInterface createExternalAccessRuleAsync(CreateExternalAccessRuleRequest $request, array $optionalArgs = []) - * @method PromiseInterface createExternalAddressAsync(CreateExternalAddressRequest $request, array $optionalArgs = []) - * @method PromiseInterface createHcxActivationKeyAsync(CreateHcxActivationKeyRequest $request, array $optionalArgs = []) - * @method PromiseInterface createLoggingServerAsync(CreateLoggingServerRequest $request, array $optionalArgs = []) - * @method PromiseInterface createManagementDnsZoneBindingAsync(CreateManagementDnsZoneBindingRequest $request, array $optionalArgs = []) - * @method PromiseInterface createNetworkPeeringAsync(CreateNetworkPeeringRequest $request, array $optionalArgs = []) - * @method PromiseInterface createNetworkPolicyAsync(CreateNetworkPolicyRequest $request, array $optionalArgs = []) - * @method PromiseInterface createPrivateCloudAsync(CreatePrivateCloudRequest $request, array $optionalArgs = []) - * @method PromiseInterface createPrivateConnectionAsync(CreatePrivateConnectionRequest $request, array $optionalArgs = []) - * @method PromiseInterface createVmwareEngineNetworkAsync(CreateVmwareEngineNetworkRequest $request, array $optionalArgs = []) - * @method PromiseInterface deleteClusterAsync(DeleteClusterRequest $request, array $optionalArgs = []) - * @method PromiseInterface deleteExternalAccessRuleAsync(DeleteExternalAccessRuleRequest $request, array $optionalArgs = []) - * @method PromiseInterface deleteExternalAddressAsync(DeleteExternalAddressRequest $request, array $optionalArgs = []) - * @method PromiseInterface deleteLoggingServerAsync(DeleteLoggingServerRequest $request, array $optionalArgs = []) - * @method PromiseInterface deleteManagementDnsZoneBindingAsync(DeleteManagementDnsZoneBindingRequest $request, array $optionalArgs = []) - * @method PromiseInterface deleteNetworkPeeringAsync(DeleteNetworkPeeringRequest $request, array $optionalArgs = []) - * @method PromiseInterface deleteNetworkPolicyAsync(DeleteNetworkPolicyRequest $request, array $optionalArgs = []) - * @method PromiseInterface deletePrivateCloudAsync(DeletePrivateCloudRequest $request, array $optionalArgs = []) - * @method PromiseInterface deletePrivateConnectionAsync(DeletePrivateConnectionRequest $request, array $optionalArgs = []) - * @method PromiseInterface deleteVmwareEngineNetworkAsync(DeleteVmwareEngineNetworkRequest $request, array $optionalArgs = []) - * @method PromiseInterface fetchNetworkPolicyExternalAddressesAsync(FetchNetworkPolicyExternalAddressesRequest $request, array $optionalArgs = []) - * @method PromiseInterface getClusterAsync(GetClusterRequest $request, array $optionalArgs = []) - * @method PromiseInterface getDnsBindPermissionAsync(GetDnsBindPermissionRequest $request, array $optionalArgs = []) - * @method PromiseInterface getDnsForwardingAsync(GetDnsForwardingRequest $request, array $optionalArgs = []) - * @method PromiseInterface getExternalAccessRuleAsync(GetExternalAccessRuleRequest $request, array $optionalArgs = []) - * @method PromiseInterface getExternalAddressAsync(GetExternalAddressRequest $request, array $optionalArgs = []) - * @method PromiseInterface getHcxActivationKeyAsync(GetHcxActivationKeyRequest $request, array $optionalArgs = []) - * @method PromiseInterface getLoggingServerAsync(GetLoggingServerRequest $request, array $optionalArgs = []) - * @method PromiseInterface getManagementDnsZoneBindingAsync(GetManagementDnsZoneBindingRequest $request, array $optionalArgs = []) - * @method PromiseInterface getNetworkPeeringAsync(GetNetworkPeeringRequest $request, array $optionalArgs = []) - * @method PromiseInterface getNetworkPolicyAsync(GetNetworkPolicyRequest $request, array $optionalArgs = []) - * @method PromiseInterface getNodeAsync(GetNodeRequest $request, array $optionalArgs = []) - * @method PromiseInterface getNodeTypeAsync(GetNodeTypeRequest $request, array $optionalArgs = []) - * @method PromiseInterface getPrivateCloudAsync(GetPrivateCloudRequest $request, array $optionalArgs = []) - * @method PromiseInterface getPrivateConnectionAsync(GetPrivateConnectionRequest $request, array $optionalArgs = []) - * @method PromiseInterface getSubnetAsync(GetSubnetRequest $request, array $optionalArgs = []) - * @method PromiseInterface getVmwareEngineNetworkAsync(GetVmwareEngineNetworkRequest $request, array $optionalArgs = []) - * @method PromiseInterface grantDnsBindPermissionAsync(GrantDnsBindPermissionRequest $request, array $optionalArgs = []) - * @method PromiseInterface listClustersAsync(ListClustersRequest $request, array $optionalArgs = []) - * @method PromiseInterface listExternalAccessRulesAsync(ListExternalAccessRulesRequest $request, array $optionalArgs = []) - * @method PromiseInterface listExternalAddressesAsync(ListExternalAddressesRequest $request, array $optionalArgs = []) - * @method PromiseInterface listHcxActivationKeysAsync(ListHcxActivationKeysRequest $request, array $optionalArgs = []) - * @method PromiseInterface listLoggingServersAsync(ListLoggingServersRequest $request, array $optionalArgs = []) - * @method PromiseInterface listManagementDnsZoneBindingsAsync(ListManagementDnsZoneBindingsRequest $request, array $optionalArgs = []) - * @method PromiseInterface listNetworkPeeringsAsync(ListNetworkPeeringsRequest $request, array $optionalArgs = []) - * @method PromiseInterface listNetworkPoliciesAsync(ListNetworkPoliciesRequest $request, array $optionalArgs = []) - * @method PromiseInterface listNodeTypesAsync(ListNodeTypesRequest $request, array $optionalArgs = []) - * @method PromiseInterface listNodesAsync(ListNodesRequest $request, array $optionalArgs = []) - * @method PromiseInterface listPeeringRoutesAsync(ListPeeringRoutesRequest $request, array $optionalArgs = []) - * @method PromiseInterface listPrivateCloudsAsync(ListPrivateCloudsRequest $request, array $optionalArgs = []) - * @method PromiseInterface listPrivateConnectionPeeringRoutesAsync(ListPrivateConnectionPeeringRoutesRequest $request, array $optionalArgs = []) - * @method PromiseInterface listPrivateConnectionsAsync(ListPrivateConnectionsRequest $request, array $optionalArgs = []) - * @method PromiseInterface listSubnetsAsync(ListSubnetsRequest $request, array $optionalArgs = []) - * @method PromiseInterface listVmwareEngineNetworksAsync(ListVmwareEngineNetworksRequest $request, array $optionalArgs = []) - * @method PromiseInterface repairManagementDnsZoneBindingAsync(RepairManagementDnsZoneBindingRequest $request, array $optionalArgs = []) - * @method PromiseInterface resetNsxCredentialsAsync(ResetNsxCredentialsRequest $request, array $optionalArgs = []) - * @method PromiseInterface resetVcenterCredentialsAsync(ResetVcenterCredentialsRequest $request, array $optionalArgs = []) - * @method PromiseInterface revokeDnsBindPermissionAsync(RevokeDnsBindPermissionRequest $request, array $optionalArgs = []) - * @method PromiseInterface showNsxCredentialsAsync(ShowNsxCredentialsRequest $request, array $optionalArgs = []) - * @method PromiseInterface showVcenterCredentialsAsync(ShowVcenterCredentialsRequest $request, array $optionalArgs = []) - * @method PromiseInterface undeletePrivateCloudAsync(UndeletePrivateCloudRequest $request, array $optionalArgs = []) - * @method PromiseInterface updateClusterAsync(UpdateClusterRequest $request, array $optionalArgs = []) - * @method PromiseInterface updateDnsForwardingAsync(UpdateDnsForwardingRequest $request, array $optionalArgs = []) - * @method PromiseInterface updateExternalAccessRuleAsync(UpdateExternalAccessRuleRequest $request, array $optionalArgs = []) - * @method PromiseInterface updateExternalAddressAsync(UpdateExternalAddressRequest $request, array $optionalArgs = []) - * @method PromiseInterface updateLoggingServerAsync(UpdateLoggingServerRequest $request, array $optionalArgs = []) - * @method PromiseInterface updateManagementDnsZoneBindingAsync(UpdateManagementDnsZoneBindingRequest $request, array $optionalArgs = []) - * @method PromiseInterface updateNetworkPeeringAsync(UpdateNetworkPeeringRequest $request, array $optionalArgs = []) - * @method PromiseInterface updateNetworkPolicyAsync(UpdateNetworkPolicyRequest $request, array $optionalArgs = []) - * @method PromiseInterface updatePrivateCloudAsync(UpdatePrivateCloudRequest $request, array $optionalArgs = []) - * @method PromiseInterface updatePrivateConnectionAsync(UpdatePrivateConnectionRequest $request, array $optionalArgs = []) - * @method PromiseInterface updateSubnetAsync(UpdateSubnetRequest $request, array $optionalArgs = []) - * @method PromiseInterface updateVmwareEngineNetworkAsync(UpdateVmwareEngineNetworkRequest $request, array $optionalArgs = []) - * @method PromiseInterface getLocationAsync(GetLocationRequest $request, array $optionalArgs = []) - * @method PromiseInterface listLocationsAsync(ListLocationsRequest $request, array $optionalArgs = []) - * @method PromiseInterface getIamPolicyAsync(GetIamPolicyRequest $request, array $optionalArgs = []) - * @method PromiseInterface setIamPolicyAsync(SetIamPolicyRequest $request, array $optionalArgs = []) - * @method PromiseInterface testIamPermissionsAsync(TestIamPermissionsRequest $request, array $optionalArgs = []) - */ -final class VmwareEngineClient -{ - use GapicClientTrait; - use ResourceHelperTrait; - - /** The name of the service. */ - private const SERVICE_NAME = 'google.cloud.vmwareengine.v1.VmwareEngine'; - - /** - * The default address of the service. - * - * @deprecated SERVICE_ADDRESS_TEMPLATE should be used instead. - */ - private const SERVICE_ADDRESS = 'vmwareengine.googleapis.com'; - - /** The address template of the service. */ - private const SERVICE_ADDRESS_TEMPLATE = 'vmwareengine.UNIVERSE_DOMAIN'; - - /** The default port of the service. */ - private const DEFAULT_SERVICE_PORT = 443; - - /** The name of the code generator, to be included in the agent header. */ - private const CODEGEN_NAME = 'gapic'; - - /** The default scopes required by the service. */ - public static $serviceScopes = [ - 'https://www.googleapis.com/auth/cloud-platform', - ]; - - private $operationsClient; - - private static function getClientDefaults() - { - return [ - 'serviceName' => self::SERVICE_NAME, - 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, - 'clientConfig' => __DIR__ . '/../resources/vmware_engine_client_config.json', - 'descriptorsConfigPath' => __DIR__ . '/../resources/vmware_engine_descriptor_config.php', - 'gcpApiConfigPath' => __DIR__ . '/../resources/vmware_engine_grpc_config.json', - 'credentialsConfig' => [ - 'defaultScopes' => self::$serviceScopes, - ], - 'transportConfig' => [ - 'rest' => [ - 'restClientConfigPath' => __DIR__ . '/../resources/vmware_engine_rest_client_config.php', - ], - ], - ]; - } - - /** - * 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 = $this->descriptors[$methodName]['longRunning'] ?? []; - $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); - $operation->reload(); - return $operation; - } - - /** - * Create the default operation client for the service. - * - * @param array $options ClientOptions for the client. - * - * @return OperationsClient - */ - private function createOperationsClient(array $options) - { - // Unset client-specific configuration options - unset($options['serviceName'], $options['clientConfig'], $options['descriptorsConfigPath']); - - if (isset($options['operationsClient'])) { - return $options['operationsClient']; - } - - return new OperationsClient($options); - } - - /** - * Formats a string containing the fully-qualified path to represent a cluster - * resource. - * - * @param string $project - * @param string $location - * @param string $privateCloud - * @param string $cluster - * - * @return string The formatted cluster resource. - */ - public static function clusterName(string $project, string $location, string $privateCloud, string $cluster): string - { - return self::getPathTemplate('cluster')->render([ - 'project' => $project, - 'location' => $location, - 'private_cloud' => $privateCloud, - 'cluster' => $cluster, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * dns_bind_permission resource. - * - * @param string $project - * @param string $location - * - * @return string The formatted dns_bind_permission resource. - */ - public static function dnsBindPermissionName(string $project, string $location): string - { - return self::getPathTemplate('dnsBindPermission')->render([ - 'project' => $project, - 'location' => $location, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * dns_forwarding resource. - * - * @param string $project - * @param string $location - * @param string $privateCloud - * - * @return string The formatted dns_forwarding resource. - */ - public static function dnsForwardingName(string $project, string $location, string $privateCloud): string - { - return self::getPathTemplate('dnsForwarding')->render([ - 'project' => $project, - 'location' => $location, - 'private_cloud' => $privateCloud, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * external_access_rule resource. - * - * @param string $project - * @param string $location - * @param string $networkPolicy - * @param string $externalAccessRule - * - * @return string The formatted external_access_rule resource. - */ - public static function externalAccessRuleName(string $project, string $location, string $networkPolicy, string $externalAccessRule): string - { - return self::getPathTemplate('externalAccessRule')->render([ - 'project' => $project, - 'location' => $location, - 'network_policy' => $networkPolicy, - 'external_access_rule' => $externalAccessRule, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * external_address resource. - * - * @param string $project - * @param string $location - * @param string $privateCloud - * @param string $externalAddress - * - * @return string The formatted external_address resource. - */ - public static function externalAddressName(string $project, string $location, string $privateCloud, string $externalAddress): string - { - return self::getPathTemplate('externalAddress')->render([ - 'project' => $project, - 'location' => $location, - 'private_cloud' => $privateCloud, - 'external_address' => $externalAddress, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * hcx_activation_key resource. - * - * @param string $project - * @param string $location - * @param string $privateCloud - * @param string $hcxActivationKey - * - * @return string The formatted hcx_activation_key resource. - */ - public static function hcxActivationKeyName(string $project, string $location, string $privateCloud, string $hcxActivationKey): string - { - return self::getPathTemplate('hcxActivationKey')->render([ - 'project' => $project, - 'location' => $location, - 'private_cloud' => $privateCloud, - 'hcx_activation_key' => $hcxActivationKey, - ]); - } - - /** - * 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(string $project, string $location): string - { - return self::getPathTemplate('location')->render([ - 'project' => $project, - 'location' => $location, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * logging_server resource. - * - * @param string $project - * @param string $location - * @param string $privateCloud - * @param string $loggingServer - * - * @return string The formatted logging_server resource. - */ - public static function loggingServerName(string $project, string $location, string $privateCloud, string $loggingServer): string - { - return self::getPathTemplate('loggingServer')->render([ - 'project' => $project, - 'location' => $location, - 'private_cloud' => $privateCloud, - 'logging_server' => $loggingServer, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * management_dns_zone_binding resource. - * - * @param string $project - * @param string $location - * @param string $privateCloud - * @param string $managementDnsZoneBinding - * - * @return string The formatted management_dns_zone_binding resource. - */ - public static function managementDnsZoneBindingName(string $project, string $location, string $privateCloud, string $managementDnsZoneBinding): string - { - return self::getPathTemplate('managementDnsZoneBinding')->render([ - 'project' => $project, - 'location' => $location, - 'private_cloud' => $privateCloud, - 'management_dns_zone_binding' => $managementDnsZoneBinding, - ]); - } - - /** - * 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(string $project, string $network): string - { - return self::getPathTemplate('network')->render([ - 'project' => $project, - 'network' => $network, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * network_peering resource. - * - * @param string $project - * @param string $location - * @param string $networkPeering - * - * @return string The formatted network_peering resource. - */ - public static function networkPeeringName(string $project, string $location, string $networkPeering): string - { - return self::getPathTemplate('networkPeering')->render([ - 'project' => $project, - 'location' => $location, - 'network_peering' => $networkPeering, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * network_policy resource. - * - * @param string $project - * @param string $location - * @param string $networkPolicy - * - * @return string The formatted network_policy resource. - */ - public static function networkPolicyName(string $project, string $location, string $networkPolicy): string - { - return self::getPathTemplate('networkPolicy')->render([ - 'project' => $project, - 'location' => $location, - 'network_policy' => $networkPolicy, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a node - * resource. - * - * @param string $project - * @param string $location - * @param string $privateCloud - * @param string $cluster - * @param string $node - * - * @return string The formatted node resource. - */ - public static function nodeName(string $project, string $location, string $privateCloud, string $cluster, string $node): string - { - return self::getPathTemplate('node')->render([ - 'project' => $project, - 'location' => $location, - 'private_cloud' => $privateCloud, - 'cluster' => $cluster, - 'node' => $node, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a node_type - * resource. - * - * @param string $project - * @param string $location - * @param string $nodeType - * - * @return string The formatted node_type resource. - */ - public static function nodeTypeName(string $project, string $location, string $nodeType): string - { - return self::getPathTemplate('nodeType')->render([ - 'project' => $project, - 'location' => $location, - 'node_type' => $nodeType, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * private_cloud resource. - * - * @param string $project - * @param string $location - * @param string $privateCloud - * - * @return string The formatted private_cloud resource. - */ - public static function privateCloudName(string $project, string $location, string $privateCloud): string - { - return self::getPathTemplate('privateCloud')->render([ - 'project' => $project, - 'location' => $location, - 'private_cloud' => $privateCloud, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * private_connection resource. - * - * @param string $project - * @param string $location - * @param string $privateConnection - * - * @return string The formatted private_connection resource. - */ - public static function privateConnectionName(string $project, string $location, string $privateConnection): string - { - return self::getPathTemplate('privateConnection')->render([ - 'project' => $project, - 'location' => $location, - 'private_connection' => $privateConnection, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a subnet - * resource. - * - * @param string $project - * @param string $location - * @param string $privateCloud - * @param string $subnet - * - * @return string The formatted subnet resource. - */ - public static function subnetName(string $project, string $location, string $privateCloud, string $subnet): string - { - return self::getPathTemplate('subnet')->render([ - 'project' => $project, - 'location' => $location, - 'private_cloud' => $privateCloud, - 'subnet' => $subnet, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a - * vmware_engine_network resource. - * - * @param string $project - * @param string $location - * @param string $vmwareEngineNetwork - * - * @return string The formatted vmware_engine_network resource. - */ - public static function vmwareEngineNetworkName(string $project, string $location, string $vmwareEngineNetwork): string - { - return self::getPathTemplate('vmwareEngineNetwork')->render([ - 'project' => $project, - 'location' => $location, - 'vmware_engine_network' => $vmwareEngineNetwork, - ]); - } - - /** - * Parses a formatted name string and returns an associative array of the components in the name. - * The following name formats are supported: - * Template: Pattern - * - cluster: projects/{project}/locations/{location}/privateClouds/{private_cloud}/clusters/{cluster} - * - dnsBindPermission: projects/{project}/locations/{location}/dnsBindPermission - * - dnsForwarding: projects/{project}/locations/{location}/privateClouds/{private_cloud}/dnsForwarding - * - externalAccessRule: projects/{project}/locations/{location}/networkPolicies/{network_policy}/externalAccessRules/{external_access_rule} - * - externalAddress: projects/{project}/locations/{location}/privateClouds/{private_cloud}/externalAddresses/{external_address} - * - hcxActivationKey: projects/{project}/locations/{location}/privateClouds/{private_cloud}/hcxActivationKeys/{hcx_activation_key} - * - location: projects/{project}/locations/{location} - * - loggingServer: projects/{project}/locations/{location}/privateClouds/{private_cloud}/loggingServers/{logging_server} - * - managementDnsZoneBinding: projects/{project}/locations/{location}/privateClouds/{private_cloud}/managementDnsZoneBindings/{management_dns_zone_binding} - * - network: projects/{project}/global/networks/{network} - * - networkPeering: projects/{project}/locations/{location}/networkPeerings/{network_peering} - * - networkPolicy: projects/{project}/locations/{location}/networkPolicies/{network_policy} - * - node: projects/{project}/locations/{location}/privateClouds/{private_cloud}/clusters/{cluster}/nodes/{node} - * - nodeType: projects/{project}/locations/{location}/nodeTypes/{node_type} - * - privateCloud: projects/{project}/locations/{location}/privateClouds/{private_cloud} - * - privateConnection: projects/{project}/locations/{location}/privateConnections/{private_connection} - * - subnet: projects/{project}/locations/{location}/privateClouds/{private_cloud}/subnets/{subnet} - * - vmwareEngineNetwork: projects/{project}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network} - * - * 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(string $formattedName, ?string $template = null): array - { - return self::parseFormattedName($formattedName, $template); - } - - /** - * Constructor. - * - * @param array|ClientOptions $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 'vmwareengine.googleapis.com:443'. - * @type FetchAuthTokenInterface|CredentialsWrapper $credentials - * This option should only be used with a pre-constructed - * {@see FetchAuthTokenInterface} or {@see CredentialsWrapper} object. Note that - * when one of these objects are provided, any settings in $credentialsConfig will - * be ignored. - * **Important**: If you are providing a path to a credentials file, or a decoded - * credentials file as a PHP array, this usage is now DEPRECATED. Providing an - * unvalidated credential configuration to Google APIs can compromise the security - * of your systems and data. It is recommended to create the credentials explicitly - * ``` - * use Google\Auth\Credentials\ServiceAccountCredentials; - * use Google\Cloud\VmwareEngine\V1\VmwareEngineClient; - * $creds = new ServiceAccountCredentials($scopes, $json); - * $options = new VmwareEngineClient(['credentials' => $creds]); - * ``` - * {@see - * https://cloud.google.com/docs/authentication/external/externally-sourced-credentials} - * @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. - * @type false|LoggerInterface $logger - * A PSR-3 compliant logger. If set to false, logging is disabled, ignoring the - * 'GOOGLE_SDK_PHP_LOGGING' environment flag - * @type string $universeDomain - * The service domain for the client. Defaults to 'googleapis.com'. - * } - * - * @throws ValidationException - */ - public function __construct(array|ClientOptions $options = []) - { - $clientOptions = $this->buildClientOptions($options); - $this->setClientOptions($clientOptions); - $this->operationsClient = $this->createOperationsClient($clientOptions); - } - - /** Handles execution of the async variants for each documented method. */ - public function __call($method, $args) - { - if (substr($method, -5) !== 'Async') { - trigger_error('Call to undefined method ' . __CLASS__ . "::$method()", E_USER_ERROR); - } - - array_unshift($args, substr($method, 0, -5)); - return call_user_func_array([$this, 'startAsyncCall'], $args); - } - - /** - * Creates a new cluster in a given private cloud. - * Creating a new cluster provides additional nodes for - * use in the parent private cloud and requires sufficient [node - * quota](https://cloud.google.com/vmware-engine/quotas). - * - * The async variant is {@see VmwareEngineClient::createClusterAsync()} . - * - * @example samples/V1/VmwareEngineClient/create_cluster.php - * - * @param CreateClusterRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function createCluster(CreateClusterRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('CreateCluster', $request, $callOptions)->wait(); - } - - /** - * Creates a new external access rule in a given network policy. - * - * The async variant is {@see VmwareEngineClient::createExternalAccessRuleAsync()} - * . - * - * @example samples/V1/VmwareEngineClient/create_external_access_rule.php - * - * @param CreateExternalAccessRuleRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function createExternalAccessRule(CreateExternalAccessRuleRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('CreateExternalAccessRule', $request, $callOptions)->wait(); - } - - /** - * Creates a new `ExternalAddress` resource in a given private cloud. The - * network policy that corresponds to the private cloud must have the external - * IP address network service enabled (`NetworkPolicy.external_ip`). - * - * The async variant is {@see VmwareEngineClient::createExternalAddressAsync()} . - * - * @example samples/V1/VmwareEngineClient/create_external_address.php - * - * @param CreateExternalAddressRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function createExternalAddress(CreateExternalAddressRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('CreateExternalAddress', $request, $callOptions)->wait(); - } - - /** - * Creates a new HCX activation key in a given private cloud. - * - * The async variant is {@see VmwareEngineClient::createHcxActivationKeyAsync()} . - * - * @example samples/V1/VmwareEngineClient/create_hcx_activation_key.php - * - * @param CreateHcxActivationKeyRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function createHcxActivationKey(CreateHcxActivationKeyRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('CreateHcxActivationKey', $request, $callOptions)->wait(); - } - - /** - * Create a new logging server for a given private cloud. - * - * The async variant is {@see VmwareEngineClient::createLoggingServerAsync()} . - * - * @example samples/V1/VmwareEngineClient/create_logging_server.php - * - * @param CreateLoggingServerRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function createLoggingServer(CreateLoggingServerRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('CreateLoggingServer', $request, $callOptions)->wait(); - } - - /** - * Creates a new `ManagementDnsZoneBinding` resource in a private cloud. - * This RPC creates the DNS binding and the resource that represents the - * DNS binding of the consumer VPC network to the management DNS zone. A - * management DNS zone is the Cloud DNS cross-project binding zone that - * VMware Engine creates for each private cloud. It contains FQDNs and - * corresponding IP addresses for the private cloud's ESXi hosts and - * management VM appliances like vCenter and NSX Manager. - * - * The async variant is - * {@see VmwareEngineClient::createManagementDnsZoneBindingAsync()} . - * - * @example samples/V1/VmwareEngineClient/create_management_dns_zone_binding.php - * - * @param CreateManagementDnsZoneBindingRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function createManagementDnsZoneBinding(CreateManagementDnsZoneBindingRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('CreateManagementDnsZoneBinding', $request, $callOptions)->wait(); - } - - /** - * Creates a new network peering between the peer network and VMware Engine - * network provided in a `NetworkPeering` resource. NetworkPeering is a - * global resource and location can only be global. - * - * The async variant is {@see VmwareEngineClient::createNetworkPeeringAsync()} . - * - * @example samples/V1/VmwareEngineClient/create_network_peering.php - * - * @param CreateNetworkPeeringRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function createNetworkPeering(CreateNetworkPeeringRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('CreateNetworkPeering', $request, $callOptions)->wait(); - } - - /** - * Creates a new network policy in a given VMware Engine network of a - * project and location (region). A new network policy cannot be created if - * another network policy already exists in the same scope. - * - * The async variant is {@see VmwareEngineClient::createNetworkPolicyAsync()} . - * - * @example samples/V1/VmwareEngineClient/create_network_policy.php - * - * @param CreateNetworkPolicyRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function createNetworkPolicy(CreateNetworkPolicyRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('CreateNetworkPolicy', $request, $callOptions)->wait(); - } - - /** - * Creates a new `PrivateCloud` resource in a given project and location. - * Private clouds of type `STANDARD` and - * `TIME_LIMITED` are zonal resources, `STRETCHED` private clouds are - * regional. - * Creating a private cloud also creates a [management - * cluster](https://cloud.google.com/vmware-engine/docs/concepts-vmware-components) - * for that private cloud. - * - * The async variant is {@see VmwareEngineClient::createPrivateCloudAsync()} . - * - * @example samples/V1/VmwareEngineClient/create_private_cloud.php - * - * @param CreatePrivateCloudRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function createPrivateCloud(CreatePrivateCloudRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('CreatePrivateCloud', $request, $callOptions)->wait(); - } - - /** - * Creates a new private connection that can be used for accessing private - * Clouds. - * - * The async variant is {@see VmwareEngineClient::createPrivateConnectionAsync()} . - * - * @example samples/V1/VmwareEngineClient/create_private_connection.php - * - * @param CreatePrivateConnectionRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function createPrivateConnection(CreatePrivateConnectionRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('CreatePrivateConnection', $request, $callOptions)->wait(); - } - - /** - * Creates a new VMware Engine network that can be used by a private cloud. - * - * The async variant is {@see VmwareEngineClient::createVmwareEngineNetworkAsync()} - * . - * - * @example samples/V1/VmwareEngineClient/create_vmware_engine_network.php - * - * @param CreateVmwareEngineNetworkRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function createVmwareEngineNetwork(CreateVmwareEngineNetworkRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('CreateVmwareEngineNetwork', $request, $callOptions)->wait(); - } - - /** - * Deletes a `Cluster` resource. To avoid unintended data loss, migrate or - * gracefully shut down any workloads running on the cluster before deletion. - * You cannot delete the management cluster of a private cloud using this - * method. - * - * The async variant is {@see VmwareEngineClient::deleteClusterAsync()} . - * - * @example samples/V1/VmwareEngineClient/delete_cluster.php - * - * @param DeleteClusterRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function deleteCluster(DeleteClusterRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('DeleteCluster', $request, $callOptions)->wait(); - } - - /** - * Deletes a single external access rule. - * - * The async variant is {@see VmwareEngineClient::deleteExternalAccessRuleAsync()} - * . - * - * @example samples/V1/VmwareEngineClient/delete_external_access_rule.php - * - * @param DeleteExternalAccessRuleRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function deleteExternalAccessRule(DeleteExternalAccessRuleRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('DeleteExternalAccessRule', $request, $callOptions)->wait(); - } - - /** - * Deletes a single external IP address. When you delete an external IP - * address, connectivity between the external IP address and the corresponding - * internal IP address is lost. - * - * The async variant is {@see VmwareEngineClient::deleteExternalAddressAsync()} . - * - * @example samples/V1/VmwareEngineClient/delete_external_address.php - * - * @param DeleteExternalAddressRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function deleteExternalAddress(DeleteExternalAddressRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('DeleteExternalAddress', $request, $callOptions)->wait(); - } - - /** - * Deletes a single logging server. - * - * The async variant is {@see VmwareEngineClient::deleteLoggingServerAsync()} . - * - * @example samples/V1/VmwareEngineClient/delete_logging_server.php - * - * @param DeleteLoggingServerRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function deleteLoggingServer(DeleteLoggingServerRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('DeleteLoggingServer', $request, $callOptions)->wait(); - } - - /** - * Deletes a `ManagementDnsZoneBinding` resource. When a management DNS zone - * binding is deleted, the corresponding consumer VPC network is no longer - * bound to the management DNS zone. - * - * The async variant is - * {@see VmwareEngineClient::deleteManagementDnsZoneBindingAsync()} . - * - * @example samples/V1/VmwareEngineClient/delete_management_dns_zone_binding.php - * - * @param DeleteManagementDnsZoneBindingRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function deleteManagementDnsZoneBinding(DeleteManagementDnsZoneBindingRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('DeleteManagementDnsZoneBinding', $request, $callOptions)->wait(); - } - - /** - * Deletes a `NetworkPeering` resource. When a network peering is deleted for - * a VMware Engine network, the peer network becomes inaccessible to that - * VMware Engine network. NetworkPeering is a global resource and location can - * only be global. - * - * The async variant is {@see VmwareEngineClient::deleteNetworkPeeringAsync()} . - * - * @example samples/V1/VmwareEngineClient/delete_network_peering.php - * - * @param DeleteNetworkPeeringRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function deleteNetworkPeering(DeleteNetworkPeeringRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('DeleteNetworkPeering', $request, $callOptions)->wait(); - } - - /** - * Deletes a `NetworkPolicy` resource. A network policy cannot be deleted - * when `NetworkService.state` is set to `RECONCILING` for either its external - * IP or internet access service. - * - * The async variant is {@see VmwareEngineClient::deleteNetworkPolicyAsync()} . - * - * @example samples/V1/VmwareEngineClient/delete_network_policy.php - * - * @param DeleteNetworkPolicyRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function deleteNetworkPolicy(DeleteNetworkPolicyRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('DeleteNetworkPolicy', $request, $callOptions)->wait(); - } - - /** - * Schedules a `PrivateCloud` resource for deletion. - * - * A `PrivateCloud` resource scheduled for deletion has `PrivateCloud.state` - * set to `DELETED` and `expireTime` set to the time when deletion is final - * and can no longer be reversed. The delete operation is marked as done - * as soon as the `PrivateCloud` is successfully scheduled for deletion - * (this also applies when `delayHours` is set to zero), and the operation is - * not kept in pending state until `PrivateCloud` is purged. - * `PrivateCloud` can be restored using `UndeletePrivateCloud` method before - * the `expireTime` elapses. When `expireTime` is reached, deletion is final - * and all private cloud resources are irreversibly removed and billing stops. - * During the final removal process, `PrivateCloud.state` is set to `PURGING`. - * `PrivateCloud` can be polled using standard `GET` method for the whole - * period of deletion and purging. It will not be returned only - * when it is completely purged. - * - * The async variant is {@see VmwareEngineClient::deletePrivateCloudAsync()} . - * - * @example samples/V1/VmwareEngineClient/delete_private_cloud.php - * - * @param DeletePrivateCloudRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function deletePrivateCloud(DeletePrivateCloudRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('DeletePrivateCloud', $request, $callOptions)->wait(); - } - - /** - * Deletes a `PrivateConnection` resource. When a private connection is - * deleted for a VMware Engine network, the connected network becomes - * inaccessible to that VMware Engine network. - * - * The async variant is {@see VmwareEngineClient::deletePrivateConnectionAsync()} . - * - * @example samples/V1/VmwareEngineClient/delete_private_connection.php - * - * @param DeletePrivateConnectionRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function deletePrivateConnection(DeletePrivateConnectionRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('DeletePrivateConnection', $request, $callOptions)->wait(); - } - - /** - * Deletes a `VmwareEngineNetwork` resource. You can only delete a VMware - * Engine network after all resources that refer to it are deleted. For - * example, a private cloud, a network peering, and a network policy can all - * refer to the same VMware Engine network. - * - * The async variant is {@see VmwareEngineClient::deleteVmwareEngineNetworkAsync()} - * . - * - * @example samples/V1/VmwareEngineClient/delete_vmware_engine_network.php - * - * @param DeleteVmwareEngineNetworkRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function deleteVmwareEngineNetwork(DeleteVmwareEngineNetworkRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('DeleteVmwareEngineNetwork', $request, $callOptions)->wait(); - } - - /** - * Lists external IP addresses assigned to VMware workload VMs within the - * scope of the given network policy. - * - * The async variant is - * {@see VmwareEngineClient::fetchNetworkPolicyExternalAddressesAsync()} . - * - * @example samples/V1/VmwareEngineClient/fetch_network_policy_external_addresses.php - * - * @param FetchNetworkPolicyExternalAddressesRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function fetchNetworkPolicyExternalAddresses(FetchNetworkPolicyExternalAddressesRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('FetchNetworkPolicyExternalAddresses', $request, $callOptions); - } - - /** - * Retrieves a `Cluster` resource by its resource name. - * - * The async variant is {@see VmwareEngineClient::getClusterAsync()} . - * - * @example samples/V1/VmwareEngineClient/get_cluster.php - * - * @param GetClusterRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Cluster - * - * @throws ApiException Thrown if the API call fails. - */ - public function getCluster(GetClusterRequest $request, array $callOptions = []): Cluster - { - return $this->startApiCall('GetCluster', $request, $callOptions)->wait(); - } - - /** - * Gets all the principals having bind permission on the intranet VPC - * associated with the consumer project granted by the Grant API. - * DnsBindPermission is a global resource and location can only be global. - * - * The async variant is {@see VmwareEngineClient::getDnsBindPermissionAsync()} . - * - * @example samples/V1/VmwareEngineClient/get_dns_bind_permission.php - * - * @param GetDnsBindPermissionRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 DnsBindPermission - * - * @throws ApiException Thrown if the API call fails. - */ - public function getDnsBindPermission(GetDnsBindPermissionRequest $request, array $callOptions = []): DnsBindPermission - { - return $this->startApiCall('GetDnsBindPermission', $request, $callOptions)->wait(); - } - - /** - * Gets details of the `DnsForwarding` config. - * - * The async variant is {@see VmwareEngineClient::getDnsForwardingAsync()} . - * - * @example samples/V1/VmwareEngineClient/get_dns_forwarding.php - * - * @param GetDnsForwardingRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 DnsForwarding - * - * @throws ApiException Thrown if the API call fails. - */ - public function getDnsForwarding(GetDnsForwardingRequest $request, array $callOptions = []): DnsForwarding - { - return $this->startApiCall('GetDnsForwarding', $request, $callOptions)->wait(); - } - - /** - * Gets details of a single external access rule. - * - * The async variant is {@see VmwareEngineClient::getExternalAccessRuleAsync()} . - * - * @example samples/V1/VmwareEngineClient/get_external_access_rule.php - * - * @param GetExternalAccessRuleRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 ExternalAccessRule - * - * @throws ApiException Thrown if the API call fails. - */ - public function getExternalAccessRule(GetExternalAccessRuleRequest $request, array $callOptions = []): ExternalAccessRule - { - return $this->startApiCall('GetExternalAccessRule', $request, $callOptions)->wait(); - } - - /** - * Gets details of a single external IP address. - * - * The async variant is {@see VmwareEngineClient::getExternalAddressAsync()} . - * - * @example samples/V1/VmwareEngineClient/get_external_address.php - * - * @param GetExternalAddressRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 ExternalAddress - * - * @throws ApiException Thrown if the API call fails. - */ - public function getExternalAddress(GetExternalAddressRequest $request, array $callOptions = []): ExternalAddress - { - return $this->startApiCall('GetExternalAddress', $request, $callOptions)->wait(); - } - - /** - * Retrieves a `HcxActivationKey` resource by its resource name. - * - * The async variant is {@see VmwareEngineClient::getHcxActivationKeyAsync()} . - * - * @example samples/V1/VmwareEngineClient/get_hcx_activation_key.php - * - * @param GetHcxActivationKeyRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 HcxActivationKey - * - * @throws ApiException Thrown if the API call fails. - */ - public function getHcxActivationKey(GetHcxActivationKeyRequest $request, array $callOptions = []): HcxActivationKey - { - return $this->startApiCall('GetHcxActivationKey', $request, $callOptions)->wait(); - } - - /** - * Gets details of a logging server. - * - * The async variant is {@see VmwareEngineClient::getLoggingServerAsync()} . - * - * @example samples/V1/VmwareEngineClient/get_logging_server.php - * - * @param GetLoggingServerRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 LoggingServer - * - * @throws ApiException Thrown if the API call fails. - */ - public function getLoggingServer(GetLoggingServerRequest $request, array $callOptions = []): LoggingServer - { - return $this->startApiCall('GetLoggingServer', $request, $callOptions)->wait(); - } - - /** - * Retrieves a 'ManagementDnsZoneBinding' resource by its resource name. - * - * The async variant is - * {@see VmwareEngineClient::getManagementDnsZoneBindingAsync()} . - * - * @example samples/V1/VmwareEngineClient/get_management_dns_zone_binding.php - * - * @param GetManagementDnsZoneBindingRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 ManagementDnsZoneBinding - * - * @throws ApiException Thrown if the API call fails. - */ - public function getManagementDnsZoneBinding(GetManagementDnsZoneBindingRequest $request, array $callOptions = []): ManagementDnsZoneBinding - { - return $this->startApiCall('GetManagementDnsZoneBinding', $request, $callOptions)->wait(); - } - - /** - * Retrieves a `NetworkPeering` resource by its resource name. The resource - * contains details of the network peering, such as peered - * networks, import and export custom route configurations, and peering state. - * NetworkPeering is a global resource and location can only be global. - * - * The async variant is {@see VmwareEngineClient::getNetworkPeeringAsync()} . - * - * @example samples/V1/VmwareEngineClient/get_network_peering.php - * - * @param GetNetworkPeeringRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 NetworkPeering - * - * @throws ApiException Thrown if the API call fails. - */ - public function getNetworkPeering(GetNetworkPeeringRequest $request, array $callOptions = []): NetworkPeering - { - return $this->startApiCall('GetNetworkPeering', $request, $callOptions)->wait(); - } - - /** - * Retrieves a `NetworkPolicy` resource by its resource name. - * - * The async variant is {@see VmwareEngineClient::getNetworkPolicyAsync()} . - * - * @example samples/V1/VmwareEngineClient/get_network_policy.php - * - * @param GetNetworkPolicyRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 NetworkPolicy - * - * @throws ApiException Thrown if the API call fails. - */ - public function getNetworkPolicy(GetNetworkPolicyRequest $request, array $callOptions = []): NetworkPolicy - { - return $this->startApiCall('GetNetworkPolicy', $request, $callOptions)->wait(); - } - - /** - * Gets details of a single node. - * - * The async variant is {@see VmwareEngineClient::getNodeAsync()} . - * - * @example samples/V1/VmwareEngineClient/get_node.php - * - * @param GetNodeRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Node - * - * @throws ApiException Thrown if the API call fails. - */ - public function getNode(GetNodeRequest $request, array $callOptions = []): Node - { - return $this->startApiCall('GetNode', $request, $callOptions)->wait(); - } - - /** - * Gets details of a single `NodeType`. - * - * The async variant is {@see VmwareEngineClient::getNodeTypeAsync()} . - * - * @example samples/V1/VmwareEngineClient/get_node_type.php - * - * @param GetNodeTypeRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 NodeType - * - * @throws ApiException Thrown if the API call fails. - */ - public function getNodeType(GetNodeTypeRequest $request, array $callOptions = []): NodeType - { - return $this->startApiCall('GetNodeType', $request, $callOptions)->wait(); - } - - /** - * Retrieves a `PrivateCloud` resource by its resource name. - * - * The async variant is {@see VmwareEngineClient::getPrivateCloudAsync()} . - * - * @example samples/V1/VmwareEngineClient/get_private_cloud.php - * - * @param GetPrivateCloudRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PrivateCloud - * - * @throws ApiException Thrown if the API call fails. - */ - public function getPrivateCloud(GetPrivateCloudRequest $request, array $callOptions = []): PrivateCloud - { - return $this->startApiCall('GetPrivateCloud', $request, $callOptions)->wait(); - } - - /** - * Retrieves a `PrivateConnection` resource by its resource name. The resource - * contains details of the private connection, such as connected - * network, routing mode and state. - * - * The async variant is {@see VmwareEngineClient::getPrivateConnectionAsync()} . - * - * @example samples/V1/VmwareEngineClient/get_private_connection.php - * - * @param GetPrivateConnectionRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PrivateConnection - * - * @throws ApiException Thrown if the API call fails. - */ - public function getPrivateConnection(GetPrivateConnectionRequest $request, array $callOptions = []): PrivateConnection - { - return $this->startApiCall('GetPrivateConnection', $request, $callOptions)->wait(); - } - - /** - * Gets details of a single subnet. - * - * The async variant is {@see VmwareEngineClient::getSubnetAsync()} . - * - * @example samples/V1/VmwareEngineClient/get_subnet.php - * - * @param GetSubnetRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Subnet - * - * @throws ApiException Thrown if the API call fails. - */ - public function getSubnet(GetSubnetRequest $request, array $callOptions = []): Subnet - { - return $this->startApiCall('GetSubnet', $request, $callOptions)->wait(); - } - - /** - * Retrieves a `VmwareEngineNetwork` resource by its resource name. The - * resource contains details of the VMware Engine network, such as its VMware - * Engine network type, peered networks in a service project, and state - * (for example, `CREATING`, `ACTIVE`, `DELETING`). - * - * The async variant is {@see VmwareEngineClient::getVmwareEngineNetworkAsync()} . - * - * @example samples/V1/VmwareEngineClient/get_vmware_engine_network.php - * - * @param GetVmwareEngineNetworkRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 VmwareEngineNetwork - * - * @throws ApiException Thrown if the API call fails. - */ - public function getVmwareEngineNetwork(GetVmwareEngineNetworkRequest $request, array $callOptions = []): VmwareEngineNetwork - { - return $this->startApiCall('GetVmwareEngineNetwork', $request, $callOptions)->wait(); - } - - /** - * Grants the bind permission to the customer provided principal(user / - * service account) to bind their DNS zone with the intranet VPC associated - * with the project. DnsBindPermission is a global resource and location can - * only be global. - * - * The async variant is {@see VmwareEngineClient::grantDnsBindPermissionAsync()} . - * - * @example samples/V1/VmwareEngineClient/grant_dns_bind_permission.php - * - * @param GrantDnsBindPermissionRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function grantDnsBindPermission(GrantDnsBindPermissionRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('GrantDnsBindPermission', $request, $callOptions)->wait(); - } - - /** - * Lists `Cluster` resources in a given private cloud. - * - * The async variant is {@see VmwareEngineClient::listClustersAsync()} . - * - * @example samples/V1/VmwareEngineClient/list_clusters.php - * - * @param ListClustersRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listClusters(ListClustersRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListClusters', $request, $callOptions); - } - - /** - * Lists `ExternalAccessRule` resources in the specified network policy. - * - * The async variant is {@see VmwareEngineClient::listExternalAccessRulesAsync()} . - * - * @example samples/V1/VmwareEngineClient/list_external_access_rules.php - * - * @param ListExternalAccessRulesRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listExternalAccessRules(ListExternalAccessRulesRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListExternalAccessRules', $request, $callOptions); - } - - /** - * Lists external IP addresses assigned to VMware workload VMs in a given - * private cloud. - * - * The async variant is {@see VmwareEngineClient::listExternalAddressesAsync()} . - * - * @example samples/V1/VmwareEngineClient/list_external_addresses.php - * - * @param ListExternalAddressesRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listExternalAddresses(ListExternalAddressesRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListExternalAddresses', $request, $callOptions); - } - - /** - * Lists `HcxActivationKey` resources in a given private cloud. - * - * The async variant is {@see VmwareEngineClient::listHcxActivationKeysAsync()} . - * - * @example samples/V1/VmwareEngineClient/list_hcx_activation_keys.php - * - * @param ListHcxActivationKeysRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listHcxActivationKeys(ListHcxActivationKeysRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListHcxActivationKeys', $request, $callOptions); - } - - /** - * Lists logging servers configured for a given private - * cloud. - * - * The async variant is {@see VmwareEngineClient::listLoggingServersAsync()} . - * - * @example samples/V1/VmwareEngineClient/list_logging_servers.php - * - * @param ListLoggingServersRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listLoggingServers(ListLoggingServersRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListLoggingServers', $request, $callOptions); - } - - /** - * Lists Consumer VPCs bound to Management DNS Zone of a given private cloud. - * - * The async variant is - * {@see VmwareEngineClient::listManagementDnsZoneBindingsAsync()} . - * - * @example samples/V1/VmwareEngineClient/list_management_dns_zone_bindings.php - * - * @param ListManagementDnsZoneBindingsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listManagementDnsZoneBindings(ListManagementDnsZoneBindingsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListManagementDnsZoneBindings', $request, $callOptions); - } - - /** - * Lists `NetworkPeering` resources in a given project. NetworkPeering is a - * global resource and location can only be global. - * - * The async variant is {@see VmwareEngineClient::listNetworkPeeringsAsync()} . - * - * @example samples/V1/VmwareEngineClient/list_network_peerings.php - * - * @param ListNetworkPeeringsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listNetworkPeerings(ListNetworkPeeringsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListNetworkPeerings', $request, $callOptions); - } - - /** - * Lists `NetworkPolicy` resources in a specified project and location. - * - * The async variant is {@see VmwareEngineClient::listNetworkPoliciesAsync()} . - * - * @example samples/V1/VmwareEngineClient/list_network_policies.php - * - * @param ListNetworkPoliciesRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listNetworkPolicies(ListNetworkPoliciesRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListNetworkPolicies', $request, $callOptions); - } - - /** - * Lists node types - * - * The async variant is {@see VmwareEngineClient::listNodeTypesAsync()} . - * - * @example samples/V1/VmwareEngineClient/list_node_types.php - * - * @param ListNodeTypesRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listNodeTypes(ListNodeTypesRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListNodeTypes', $request, $callOptions); - } - - /** - * Lists nodes in a given cluster. - * - * The async variant is {@see VmwareEngineClient::listNodesAsync()} . - * - * @example samples/V1/VmwareEngineClient/list_nodes.php - * - * @param ListNodesRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listNodes(ListNodesRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListNodes', $request, $callOptions); - } - - /** - * Lists the network peering routes exchanged over a peering connection. - * NetworkPeering is a global resource and location can only be global. - * - * The async variant is {@see VmwareEngineClient::listPeeringRoutesAsync()} . - * - * @example samples/V1/VmwareEngineClient/list_peering_routes.php - * - * @param ListPeeringRoutesRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listPeeringRoutes(ListPeeringRoutesRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListPeeringRoutes', $request, $callOptions); - } - - /** - * Lists `PrivateCloud` resources in a given project and location. - * - * The async variant is {@see VmwareEngineClient::listPrivateCloudsAsync()} . - * - * @example samples/V1/VmwareEngineClient/list_private_clouds.php - * - * @param ListPrivateCloudsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listPrivateClouds(ListPrivateCloudsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListPrivateClouds', $request, $callOptions); - } - - /** - * Lists the private connection routes exchanged over a peering connection. - * - * The async variant is - * {@see VmwareEngineClient::listPrivateConnectionPeeringRoutesAsync()} . - * - * @example samples/V1/VmwareEngineClient/list_private_connection_peering_routes.php - * - * @param ListPrivateConnectionPeeringRoutesRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listPrivateConnectionPeeringRoutes(ListPrivateConnectionPeeringRoutesRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListPrivateConnectionPeeringRoutes', $request, $callOptions); - } - - /** - * Lists `PrivateConnection` resources in a given project and location. - * - * The async variant is {@see VmwareEngineClient::listPrivateConnectionsAsync()} . - * - * @example samples/V1/VmwareEngineClient/list_private_connections.php - * - * @param ListPrivateConnectionsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listPrivateConnections(ListPrivateConnectionsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListPrivateConnections', $request, $callOptions); - } - - /** - * Lists subnets in a given private cloud. - * - * The async variant is {@see VmwareEngineClient::listSubnetsAsync()} . - * - * @example samples/V1/VmwareEngineClient/list_subnets.php - * - * @param ListSubnetsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listSubnets(ListSubnetsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListSubnets', $request, $callOptions); - } - - /** - * Lists `VmwareEngineNetwork` resources in a given project and location. - * - * The async variant is {@see VmwareEngineClient::listVmwareEngineNetworksAsync()} - * . - * - * @example samples/V1/VmwareEngineClient/list_vmware_engine_networks.php - * - * @param ListVmwareEngineNetworksRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listVmwareEngineNetworks(ListVmwareEngineNetworksRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListVmwareEngineNetworks', $request, $callOptions); - } - - /** - * Retries to create a `ManagementDnsZoneBinding` resource that is - * in failed state. - * - * The async variant is - * {@see VmwareEngineClient::repairManagementDnsZoneBindingAsync()} . - * - * @example samples/V1/VmwareEngineClient/repair_management_dns_zone_binding.php - * - * @param RepairManagementDnsZoneBindingRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function repairManagementDnsZoneBinding(RepairManagementDnsZoneBindingRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('RepairManagementDnsZoneBinding', $request, $callOptions)->wait(); - } - - /** - * Resets credentials of the NSX appliance. - * - * The async variant is {@see VmwareEngineClient::resetNsxCredentialsAsync()} . - * - * @example samples/V1/VmwareEngineClient/reset_nsx_credentials.php - * - * @param ResetNsxCredentialsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function resetNsxCredentials(ResetNsxCredentialsRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('ResetNsxCredentials', $request, $callOptions)->wait(); - } - - /** - * Resets credentials of the Vcenter appliance. - * - * The async variant is {@see VmwareEngineClient::resetVcenterCredentialsAsync()} . - * - * @example samples/V1/VmwareEngineClient/reset_vcenter_credentials.php - * - * @param ResetVcenterCredentialsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function resetVcenterCredentials(ResetVcenterCredentialsRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('ResetVcenterCredentials', $request, $callOptions)->wait(); - } - - /** - * Revokes the bind permission from the customer provided principal(user / - * service account) on the intranet VPC associated with the consumer project. - * DnsBindPermission is a global resource and location can only be global. - * - * The async variant is {@see VmwareEngineClient::revokeDnsBindPermissionAsync()} . - * - * @example samples/V1/VmwareEngineClient/revoke_dns_bind_permission.php - * - * @param RevokeDnsBindPermissionRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function revokeDnsBindPermission(RevokeDnsBindPermissionRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('RevokeDnsBindPermission', $request, $callOptions)->wait(); - } - - /** - * Gets details of credentials for NSX appliance. - * - * The async variant is {@see VmwareEngineClient::showNsxCredentialsAsync()} . - * - * @example samples/V1/VmwareEngineClient/show_nsx_credentials.php - * - * @param ShowNsxCredentialsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Credentials - * - * @throws ApiException Thrown if the API call fails. - */ - public function showNsxCredentials(ShowNsxCredentialsRequest $request, array $callOptions = []): Credentials - { - return $this->startApiCall('ShowNsxCredentials', $request, $callOptions)->wait(); - } - - /** - * Gets details of credentials for Vcenter appliance. - * - * The async variant is {@see VmwareEngineClient::showVcenterCredentialsAsync()} . - * - * @example samples/V1/VmwareEngineClient/show_vcenter_credentials.php - * - * @param ShowVcenterCredentialsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Credentials - * - * @throws ApiException Thrown if the API call fails. - */ - public function showVcenterCredentials(ShowVcenterCredentialsRequest $request, array $callOptions = []): Credentials - { - return $this->startApiCall('ShowVcenterCredentials', $request, $callOptions)->wait(); - } - - /** - * Restores a private cloud that was previously scheduled for deletion by - * `DeletePrivateCloud`. A `PrivateCloud` resource scheduled for deletion has - * `PrivateCloud.state` set to `DELETED` and `PrivateCloud.expireTime` set to - * the time when deletion can no longer be reversed. - * - * The async variant is {@see VmwareEngineClient::undeletePrivateCloudAsync()} . - * - * @example samples/V1/VmwareEngineClient/undelete_private_cloud.php - * - * @param UndeletePrivateCloudRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function undeletePrivateCloud(UndeletePrivateCloudRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('UndeletePrivateCloud', $request, $callOptions)->wait(); - } - - /** - * Modifies a `Cluster` resource. Only fields specified in `updateMask` are - * applied. - * - * During operation processing, the resource is temporarily in the `ACTIVE` - * state before the operation fully completes. For that period of time, you - * can't update the resource. Use the operation status to determine when the - * processing fully completes. - * - * The async variant is {@see VmwareEngineClient::updateClusterAsync()} . - * - * @example samples/V1/VmwareEngineClient/update_cluster.php - * - * @param UpdateClusterRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateCluster(UpdateClusterRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('UpdateCluster', $request, $callOptions)->wait(); - } - - /** - * Updates the parameters of the `DnsForwarding` config, like associated - * domains. Only fields specified in `update_mask` are applied. - * - * The async variant is {@see VmwareEngineClient::updateDnsForwardingAsync()} . - * - * @example samples/V1/VmwareEngineClient/update_dns_forwarding.php - * - * @param UpdateDnsForwardingRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateDnsForwarding(UpdateDnsForwardingRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('UpdateDnsForwarding', $request, $callOptions)->wait(); - } - - /** - * Updates the parameters of a single external access rule. - * Only fields specified in `update_mask` are applied. - * - * The async variant is {@see VmwareEngineClient::updateExternalAccessRuleAsync()} - * . - * - * @example samples/V1/VmwareEngineClient/update_external_access_rule.php - * - * @param UpdateExternalAccessRuleRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateExternalAccessRule(UpdateExternalAccessRuleRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('UpdateExternalAccessRule', $request, $callOptions)->wait(); - } - - /** - * Updates the parameters of a single external IP address. - * Only fields specified in `update_mask` are applied. - * - * During operation processing, the resource is temporarily in the `ACTIVE` - * state before the operation fully completes. For that period of time, you - * can't update the resource. Use the operation status to determine when the - * processing fully completes. - * - * The async variant is {@see VmwareEngineClient::updateExternalAddressAsync()} . - * - * @example samples/V1/VmwareEngineClient/update_external_address.php - * - * @param UpdateExternalAddressRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateExternalAddress(UpdateExternalAddressRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('UpdateExternalAddress', $request, $callOptions)->wait(); - } - - /** - * Updates the parameters of a single logging server. - * Only fields specified in `update_mask` are applied. - * - * The async variant is {@see VmwareEngineClient::updateLoggingServerAsync()} . - * - * @example samples/V1/VmwareEngineClient/update_logging_server.php - * - * @param UpdateLoggingServerRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateLoggingServer(UpdateLoggingServerRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('UpdateLoggingServer', $request, $callOptions)->wait(); - } - - /** - * Updates a `ManagementDnsZoneBinding` resource. - * Only fields specified in `update_mask` are applied. - * - * The async variant is - * {@see VmwareEngineClient::updateManagementDnsZoneBindingAsync()} . - * - * @example samples/V1/VmwareEngineClient/update_management_dns_zone_binding.php - * - * @param UpdateManagementDnsZoneBindingRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateManagementDnsZoneBinding(UpdateManagementDnsZoneBindingRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('UpdateManagementDnsZoneBinding', $request, $callOptions)->wait(); - } - - /** - * Modifies a `NetworkPeering` resource. Only the `description` field can be - * updated. Only fields specified in `updateMask` are applied. NetworkPeering - * is a global resource and location can only be global. - * - * The async variant is {@see VmwareEngineClient::updateNetworkPeeringAsync()} . - * - * @example samples/V1/VmwareEngineClient/update_network_peering.php - * - * @param UpdateNetworkPeeringRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateNetworkPeering(UpdateNetworkPeeringRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('UpdateNetworkPeering', $request, $callOptions)->wait(); - } - - /** - * Modifies a `NetworkPolicy` resource. Only the following fields can be - * updated: `internet_access`, `external_ip`, `edge_services_cidr`. - * Only fields specified in `updateMask` are applied. When updating a network - * policy, the external IP network service can only be disabled if there are - * no external IP addresses present in the scope of the policy. Also, a - * `NetworkService` cannot be updated when `NetworkService.state` is set - * to `RECONCILING`. - * - * During operation processing, the resource is temporarily in the `ACTIVE` - * state before the operation fully completes. For that period of time, you - * can't update the resource. Use the operation status to determine when the - * processing fully completes. - * - * The async variant is {@see VmwareEngineClient::updateNetworkPolicyAsync()} . - * - * @example samples/V1/VmwareEngineClient/update_network_policy.php - * - * @param UpdateNetworkPolicyRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateNetworkPolicy(UpdateNetworkPolicyRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('UpdateNetworkPolicy', $request, $callOptions)->wait(); - } - - /** - * Modifies a `PrivateCloud` resource. Only the following fields can be - * updated: `description`. - * Only fields specified in `updateMask` are applied. - * - * During operation processing, the resource is temporarily in the `ACTIVE` - * state before the operation fully completes. For that period of time, you - * can't update the resource. Use the operation status to determine when the - * processing fully completes. - * - * The async variant is {@see VmwareEngineClient::updatePrivateCloudAsync()} . - * - * @example samples/V1/VmwareEngineClient/update_private_cloud.php - * - * @param UpdatePrivateCloudRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function updatePrivateCloud(UpdatePrivateCloudRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('UpdatePrivateCloud', $request, $callOptions)->wait(); - } - - /** - * Modifies a `PrivateConnection` resource. Only `description` and - * `routing_mode` fields can be updated. Only fields specified in `updateMask` - * are applied. - * - * The async variant is {@see VmwareEngineClient::updatePrivateConnectionAsync()} . - * - * @example samples/V1/VmwareEngineClient/update_private_connection.php - * - * @param UpdatePrivateConnectionRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function updatePrivateConnection(UpdatePrivateConnectionRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('UpdatePrivateConnection', $request, $callOptions)->wait(); - } - - /** - * Updates the parameters of a single subnet. Only fields specified in - * `update_mask` are applied. - * - * *Note*: This API is synchronous and always returns a successful - * `google.longrunning.Operation` (LRO). The returned LRO will only have - * `done` and `response` fields. - * - * The async variant is {@see VmwareEngineClient::updateSubnetAsync()} . - * - * @example samples/V1/VmwareEngineClient/update_subnet.php - * - * @param UpdateSubnetRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateSubnet(UpdateSubnetRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('UpdateSubnet', $request, $callOptions)->wait(); - } - - /** - * Modifies a VMware Engine network resource. Only the following fields can be - * updated: `description`. Only fields specified in `updateMask` are - * applied. - * - * The async variant is {@see VmwareEngineClient::updateVmwareEngineNetworkAsync()} - * . - * - * @example samples/V1/VmwareEngineClient/update_vmware_engine_network.php - * - * @param UpdateVmwareEngineNetworkRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateVmwareEngineNetwork(UpdateVmwareEngineNetworkRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('UpdateVmwareEngineNetwork', $request, $callOptions)->wait(); - } - - /** - * Gets information about a location. - * - * The async variant is {@see VmwareEngineClient::getLocationAsync()} . - * - * @example samples/V1/VmwareEngineClient/get_location.php - * - * @param GetLocationRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Location - * - * @throws ApiException Thrown if the API call fails. - */ - public function getLocation(GetLocationRequest $request, array $callOptions = []): Location - { - return $this->startApiCall('GetLocation', $request, $callOptions)->wait(); - } - - /** - * Lists information about the supported locations for this service. - * - * The async variant is {@see VmwareEngineClient::listLocationsAsync()} . - * - * @example samples/V1/VmwareEngineClient/list_locations.php - * - * @param ListLocationsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listLocations(ListLocationsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListLocations', $request, $callOptions); - } - - /** - * Gets the access control policy for a resource. Returns an empty policy - * if the resource exists and does not have a policy set. - * - * The async variant is {@see VmwareEngineClient::getIamPolicyAsync()} . - * - * @example samples/V1/VmwareEngineClient/get_iam_policy.php - * - * @param GetIamPolicyRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Policy - * - * @throws ApiException Thrown if the API call fails. - */ - public function getIamPolicy(GetIamPolicyRequest $request, array $callOptions = []): Policy - { - return $this->startApiCall('GetIamPolicy', $request, $callOptions)->wait(); - } - - /** - * Sets the access control policy on the specified resource. Replaces - * any existing policy. - * - * Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` - * errors. - * - * The async variant is {@see VmwareEngineClient::setIamPolicyAsync()} . - * - * @example samples/V1/VmwareEngineClient/set_iam_policy.php - * - * @param SetIamPolicyRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Policy - * - * @throws ApiException Thrown if the API call fails. - */ - public function setIamPolicy(SetIamPolicyRequest $request, array $callOptions = []): Policy - { - return $this->startApiCall('SetIamPolicy', $request, $callOptions)->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. - * - * The async variant is {@see VmwareEngineClient::testIamPermissionsAsync()} . - * - * @example samples/V1/VmwareEngineClient/test_iam_permissions.php - * - * @param TestIamPermissionsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 TestIamPermissionsResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function testIamPermissions(TestIamPermissionsRequest $request, array $callOptions = []): TestIamPermissionsResponse - { - return $this->startApiCall('TestIamPermissions', $request, $callOptions)->wait(); - } -} diff --git a/owl-bot-staging/VmwareEngine/v1/src/V1/gapic_metadata.json b/owl-bot-staging/VmwareEngine/v1/src/V1/gapic_metadata.json deleted file mode 100644 index f3559962a01c..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/src/V1/gapic_metadata.json +++ /dev/null @@ -1,413 +0,0 @@ -{ - "schema": "1.0", - "comment": "This file maps proto services\/RPCs to the corresponding library clients\/methods", - "language": "php", - "protoPackage": "google.cloud.vmwareengine.v1", - "libraryPackage": "Google\\Cloud\\VmwareEngine\\V1", - "services": { - "VmwareEngine": { - "clients": { - "grpc": { - "libraryClient": "VmwareEngineGapicClient", - "rpcs": { - "CreateCluster": { - "methods": [ - "createCluster" - ] - }, - "CreateExternalAccessRule": { - "methods": [ - "createExternalAccessRule" - ] - }, - "CreateExternalAddress": { - "methods": [ - "createExternalAddress" - ] - }, - "CreateHcxActivationKey": { - "methods": [ - "createHcxActivationKey" - ] - }, - "CreateLoggingServer": { - "methods": [ - "createLoggingServer" - ] - }, - "CreateManagementDnsZoneBinding": { - "methods": [ - "createManagementDnsZoneBinding" - ] - }, - "CreateNetworkPeering": { - "methods": [ - "createNetworkPeering" - ] - }, - "CreateNetworkPolicy": { - "methods": [ - "createNetworkPolicy" - ] - }, - "CreatePrivateCloud": { - "methods": [ - "createPrivateCloud" - ] - }, - "CreatePrivateConnection": { - "methods": [ - "createPrivateConnection" - ] - }, - "CreateVmwareEngineNetwork": { - "methods": [ - "createVmwareEngineNetwork" - ] - }, - "DeleteCluster": { - "methods": [ - "deleteCluster" - ] - }, - "DeleteExternalAccessRule": { - "methods": [ - "deleteExternalAccessRule" - ] - }, - "DeleteExternalAddress": { - "methods": [ - "deleteExternalAddress" - ] - }, - "DeleteLoggingServer": { - "methods": [ - "deleteLoggingServer" - ] - }, - "DeleteManagementDnsZoneBinding": { - "methods": [ - "deleteManagementDnsZoneBinding" - ] - }, - "DeleteNetworkPeering": { - "methods": [ - "deleteNetworkPeering" - ] - }, - "DeleteNetworkPolicy": { - "methods": [ - "deleteNetworkPolicy" - ] - }, - "DeletePrivateCloud": { - "methods": [ - "deletePrivateCloud" - ] - }, - "DeletePrivateConnection": { - "methods": [ - "deletePrivateConnection" - ] - }, - "DeleteVmwareEngineNetwork": { - "methods": [ - "deleteVmwareEngineNetwork" - ] - }, - "FetchNetworkPolicyExternalAddresses": { - "methods": [ - "fetchNetworkPolicyExternalAddresses" - ] - }, - "GetCluster": { - "methods": [ - "getCluster" - ] - }, - "GetDnsBindPermission": { - "methods": [ - "getDnsBindPermission" - ] - }, - "GetDnsForwarding": { - "methods": [ - "getDnsForwarding" - ] - }, - "GetExternalAccessRule": { - "methods": [ - "getExternalAccessRule" - ] - }, - "GetExternalAddress": { - "methods": [ - "getExternalAddress" - ] - }, - "GetHcxActivationKey": { - "methods": [ - "getHcxActivationKey" - ] - }, - "GetLoggingServer": { - "methods": [ - "getLoggingServer" - ] - }, - "GetManagementDnsZoneBinding": { - "methods": [ - "getManagementDnsZoneBinding" - ] - }, - "GetNetworkPeering": { - "methods": [ - "getNetworkPeering" - ] - }, - "GetNetworkPolicy": { - "methods": [ - "getNetworkPolicy" - ] - }, - "GetNode": { - "methods": [ - "getNode" - ] - }, - "GetNodeType": { - "methods": [ - "getNodeType" - ] - }, - "GetPrivateCloud": { - "methods": [ - "getPrivateCloud" - ] - }, - "GetPrivateConnection": { - "methods": [ - "getPrivateConnection" - ] - }, - "GetSubnet": { - "methods": [ - "getSubnet" - ] - }, - "GetVmwareEngineNetwork": { - "methods": [ - "getVmwareEngineNetwork" - ] - }, - "GrantDnsBindPermission": { - "methods": [ - "grantDnsBindPermission" - ] - }, - "ListClusters": { - "methods": [ - "listClusters" - ] - }, - "ListExternalAccessRules": { - "methods": [ - "listExternalAccessRules" - ] - }, - "ListExternalAddresses": { - "methods": [ - "listExternalAddresses" - ] - }, - "ListHcxActivationKeys": { - "methods": [ - "listHcxActivationKeys" - ] - }, - "ListLoggingServers": { - "methods": [ - "listLoggingServers" - ] - }, - "ListManagementDnsZoneBindings": { - "methods": [ - "listManagementDnsZoneBindings" - ] - }, - "ListNetworkPeerings": { - "methods": [ - "listNetworkPeerings" - ] - }, - "ListNetworkPolicies": { - "methods": [ - "listNetworkPolicies" - ] - }, - "ListNodeTypes": { - "methods": [ - "listNodeTypes" - ] - }, - "ListNodes": { - "methods": [ - "listNodes" - ] - }, - "ListPeeringRoutes": { - "methods": [ - "listPeeringRoutes" - ] - }, - "ListPrivateClouds": { - "methods": [ - "listPrivateClouds" - ] - }, - "ListPrivateConnectionPeeringRoutes": { - "methods": [ - "listPrivateConnectionPeeringRoutes" - ] - }, - "ListPrivateConnections": { - "methods": [ - "listPrivateConnections" - ] - }, - "ListSubnets": { - "methods": [ - "listSubnets" - ] - }, - "ListVmwareEngineNetworks": { - "methods": [ - "listVmwareEngineNetworks" - ] - }, - "RepairManagementDnsZoneBinding": { - "methods": [ - "repairManagementDnsZoneBinding" - ] - }, - "ResetNsxCredentials": { - "methods": [ - "resetNsxCredentials" - ] - }, - "ResetVcenterCredentials": { - "methods": [ - "resetVcenterCredentials" - ] - }, - "RevokeDnsBindPermission": { - "methods": [ - "revokeDnsBindPermission" - ] - }, - "ShowNsxCredentials": { - "methods": [ - "showNsxCredentials" - ] - }, - "ShowVcenterCredentials": { - "methods": [ - "showVcenterCredentials" - ] - }, - "UndeletePrivateCloud": { - "methods": [ - "undeletePrivateCloud" - ] - }, - "UpdateCluster": { - "methods": [ - "updateCluster" - ] - }, - "UpdateDnsForwarding": { - "methods": [ - "updateDnsForwarding" - ] - }, - "UpdateExternalAccessRule": { - "methods": [ - "updateExternalAccessRule" - ] - }, - "UpdateExternalAddress": { - "methods": [ - "updateExternalAddress" - ] - }, - "UpdateLoggingServer": { - "methods": [ - "updateLoggingServer" - ] - }, - "UpdateManagementDnsZoneBinding": { - "methods": [ - "updateManagementDnsZoneBinding" - ] - }, - "UpdateNetworkPeering": { - "methods": [ - "updateNetworkPeering" - ] - }, - "UpdateNetworkPolicy": { - "methods": [ - "updateNetworkPolicy" - ] - }, - "UpdatePrivateCloud": { - "methods": [ - "updatePrivateCloud" - ] - }, - "UpdatePrivateConnection": { - "methods": [ - "updatePrivateConnection" - ] - }, - "UpdateSubnet": { - "methods": [ - "updateSubnet" - ] - }, - "UpdateVmwareEngineNetwork": { - "methods": [ - "updateVmwareEngineNetwork" - ] - }, - "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/VmwareEngine/v1/src/V1/resources/vmware_engine_client_config.json b/owl-bot-staging/VmwareEngine/v1/src/V1/resources/vmware_engine_client_config.json deleted file mode 100644 index b669825592a5..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/src/V1/resources/vmware_engine_client_config.json +++ /dev/null @@ -1,449 +0,0 @@ -{ - "interfaces": { - "google.cloud.vmwareengine.v1.VmwareEngine": { - "retry_codes": { - "no_retry_codes": [], - "retry_policy_1_codes": [ - "UNAVAILABLE" - ], - "no_retry_1_codes": [], - "no_retry_2_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": 120000, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 120000, - "total_timeout_millis": 120000 - }, - "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 - }, - "no_retry_2_params": { - "initial_retry_delay_millis": 0, - "retry_delay_multiplier": 0.0, - "max_retry_delay_millis": 0, - "initial_rpc_timeout_millis": 120000, - "rpc_timeout_multiplier": 1.0, - "max_rpc_timeout_millis": 120000, - "total_timeout_millis": 120000 - } - }, - "methods": { - "CreateCluster": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "CreateExternalAccessRule": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "CreateExternalAddress": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "CreateHcxActivationKey": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "CreateLoggingServer": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "CreateManagementDnsZoneBinding": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "CreateNetworkPeering": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "CreateNetworkPolicy": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "CreatePrivateCloud": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "CreatePrivateConnection": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "CreateVmwareEngineNetwork": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "DeleteCluster": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "DeleteExternalAccessRule": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "DeleteExternalAddress": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "DeleteLoggingServer": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "DeleteManagementDnsZoneBinding": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "DeleteNetworkPeering": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "DeleteNetworkPolicy": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "DeletePrivateCloud": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "DeletePrivateConnection": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "DeleteVmwareEngineNetwork": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "FetchNetworkPolicyExternalAddresses": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "GetCluster": { - "timeout_millis": 120000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetDnsBindPermission": { - "timeout_millis": 120000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetDnsForwarding": { - "timeout_millis": 120000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetExternalAccessRule": { - "timeout_millis": 120000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetExternalAddress": { - "timeout_millis": 120000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetHcxActivationKey": { - "timeout_millis": 120000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetLoggingServer": { - "timeout_millis": 120000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetManagementDnsZoneBinding": { - "timeout_millis": 120000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetNetworkPeering": { - "timeout_millis": 120000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetNetworkPolicy": { - "timeout_millis": 120000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetNode": { - "timeout_millis": 120000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetNodeType": { - "timeout_millis": 120000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetPrivateCloud": { - "timeout_millis": 120000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetPrivateConnection": { - "timeout_millis": 120000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetSubnet": { - "timeout_millis": 120000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetVmwareEngineNetwork": { - "timeout_millis": 120000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GrantDnsBindPermission": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "ListClusters": { - "timeout_millis": 120000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListExternalAccessRules": { - "timeout_millis": 120000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListExternalAddresses": { - "timeout_millis": 120000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListHcxActivationKeys": { - "timeout_millis": 120000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListLoggingServers": { - "timeout_millis": 120000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListManagementDnsZoneBindings": { - "timeout_millis": 120000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListNetworkPeerings": { - "timeout_millis": 120000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListNetworkPolicies": { - "timeout_millis": 120000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListNodeTypes": { - "timeout_millis": 120000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListNodes": { - "timeout_millis": 120000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListPeeringRoutes": { - "timeout_millis": 120000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListPrivateClouds": { - "timeout_millis": 120000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListPrivateConnectionPeeringRoutes": { - "timeout_millis": 120000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListPrivateConnections": { - "timeout_millis": 120000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListSubnets": { - "timeout_millis": 120000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListVmwareEngineNetworks": { - "timeout_millis": 120000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "RepairManagementDnsZoneBinding": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "ResetNsxCredentials": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "ResetVcenterCredentials": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "RevokeDnsBindPermission": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "ShowNsxCredentials": { - "timeout_millis": 120000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ShowVcenterCredentials": { - "timeout_millis": 120000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "UndeletePrivateCloud": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "UpdateCluster": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "UpdateDnsForwarding": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "UpdateExternalAccessRule": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "UpdateExternalAddress": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "UpdateLoggingServer": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "UpdateManagementDnsZoneBinding": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "UpdateNetworkPeering": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "UpdateNetworkPolicy": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "UpdatePrivateCloud": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "UpdatePrivateConnection": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "UpdateSubnet": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "UpdateVmwareEngineNetwork": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "GetLocation": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "ListLocations": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "GetIamPolicy": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "SetIamPolicy": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - }, - "TestIamPermissions": { - "timeout_millis": 120000, - "retry_codes_name": "no_retry_2_codes", - "retry_params_name": "no_retry_2_params" - } - } - } - } -} diff --git a/owl-bot-staging/VmwareEngine/v1/src/V1/resources/vmware_engine_descriptor_config.php b/owl-bot-staging/VmwareEngine/v1/src/V1/resources/vmware_engine_descriptor_config.php deleted file mode 100644 index 6ca28d70250a..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/src/V1/resources/vmware_engine_descriptor_config.php +++ /dev/null @@ -1,1430 +0,0 @@ - [ - 'google.cloud.vmwareengine.v1.VmwareEngine' => [ - 'CreateCluster' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\Cluster', - 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateExternalAccessRule' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\ExternalAccessRule', - 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateExternalAddress' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\ExternalAddress', - 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateHcxActivationKey' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\HcxActivationKey', - 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateLoggingServer' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\LoggingServer', - 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateManagementDnsZoneBinding' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\ManagementDnsZoneBinding', - 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateNetworkPeering' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\NetworkPeering', - 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateNetworkPolicy' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\NetworkPolicy', - 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreatePrivateCloud' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\PrivateCloud', - 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreatePrivateConnection' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\PrivateConnection', - 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'CreateVmwareEngineNetwork' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork', - 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'DeleteCluster' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'DeleteExternalAccessRule' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'DeleteExternalAddress' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'DeleteLoggingServer' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'DeleteManagementDnsZoneBinding' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'DeleteNetworkPeering' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'DeleteNetworkPolicy' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'DeletePrivateCloud' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\PrivateCloud', - 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'DeletePrivateConnection' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'DeleteVmwareEngineNetwork' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GrantDnsBindPermission' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\DnsBindPermission', - 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'RepairManagementDnsZoneBinding' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\ManagementDnsZoneBinding', - 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'ResetNsxCredentials' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\PrivateCloud', - 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'private_cloud', - 'fieldAccessors' => [ - 'getPrivateCloud', - ], - ], - ], - ], - 'ResetVcenterCredentials' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\PrivateCloud', - 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'private_cloud', - 'fieldAccessors' => [ - 'getPrivateCloud', - ], - ], - ], - ], - 'RevokeDnsBindPermission' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\DnsBindPermission', - 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'UndeletePrivateCloud' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\PrivateCloud', - 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'UpdateCluster' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\Cluster', - 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'cluster.name', - 'fieldAccessors' => [ - 'getCluster', - 'getName', - ], - ], - ], - ], - 'UpdateDnsForwarding' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\DnsForwarding', - 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'dns_forwarding.name', - 'fieldAccessors' => [ - 'getDnsForwarding', - 'getName', - ], - ], - ], - ], - 'UpdateExternalAccessRule' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\ExternalAccessRule', - 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'external_access_rule.name', - 'fieldAccessors' => [ - 'getExternalAccessRule', - 'getName', - ], - ], - ], - ], - 'UpdateExternalAddress' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\ExternalAddress', - 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'external_address.name', - 'fieldAccessors' => [ - 'getExternalAddress', - 'getName', - ], - ], - ], - ], - 'UpdateLoggingServer' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\LoggingServer', - 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'logging_server.name', - 'fieldAccessors' => [ - 'getLoggingServer', - 'getName', - ], - ], - ], - ], - 'UpdateManagementDnsZoneBinding' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\ManagementDnsZoneBinding', - 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'management_dns_zone_binding.name', - 'fieldAccessors' => [ - 'getManagementDnsZoneBinding', - 'getName', - ], - ], - ], - ], - 'UpdateNetworkPeering' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\NetworkPeering', - 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'network_peering.name', - 'fieldAccessors' => [ - 'getNetworkPeering', - 'getName', - ], - ], - ], - ], - 'UpdateNetworkPolicy' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\NetworkPolicy', - 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'network_policy.name', - 'fieldAccessors' => [ - 'getNetworkPolicy', - 'getName', - ], - ], - ], - ], - 'UpdatePrivateCloud' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\PrivateCloud', - 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'private_cloud.name', - 'fieldAccessors' => [ - 'getPrivateCloud', - 'getName', - ], - ], - ], - ], - 'UpdatePrivateConnection' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\PrivateConnection', - 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'private_connection.name', - 'fieldAccessors' => [ - 'getPrivateConnection', - 'getName', - ], - ], - ], - ], - 'UpdateSubnet' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\Subnet', - 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'subnet.name', - 'fieldAccessors' => [ - 'getSubnet', - 'getName', - ], - ], - ], - ], - 'UpdateVmwareEngineNetwork' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork', - 'metadataReturnType' => '\Google\Cloud\VmwareEngine\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'vmware_engine_network.name', - 'fieldAccessors' => [ - 'getVmwareEngineNetwork', - 'getName', - ], - ], - ], - ], - 'FetchNetworkPolicyExternalAddresses' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getExternalAddresses', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\VmwareEngine\V1\FetchNetworkPolicyExternalAddressesResponse', - 'headerParams' => [ - [ - 'keyName' => 'network_policy', - 'fieldAccessors' => [ - 'getNetworkPolicy', - ], - ], - ], - ], - 'GetCluster' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\VmwareEngine\V1\Cluster', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetDnsBindPermission' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\VmwareEngine\V1\DnsBindPermission', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetDnsForwarding' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\VmwareEngine\V1\DnsForwarding', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetExternalAccessRule' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\VmwareEngine\V1\ExternalAccessRule', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetExternalAddress' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\VmwareEngine\V1\ExternalAddress', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetHcxActivationKey' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\VmwareEngine\V1\HcxActivationKey', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetLoggingServer' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\VmwareEngine\V1\LoggingServer', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetManagementDnsZoneBinding' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\VmwareEngine\V1\ManagementDnsZoneBinding', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetNetworkPeering' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\VmwareEngine\V1\NetworkPeering', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetNetworkPolicy' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\VmwareEngine\V1\NetworkPolicy', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetNode' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\VmwareEngine\V1\Node', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetNodeType' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\VmwareEngine\V1\NodeType', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetPrivateCloud' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\VmwareEngine\V1\PrivateCloud', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetPrivateConnection' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\VmwareEngine\V1\PrivateConnection', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetSubnet' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\VmwareEngine\V1\Subnet', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetVmwareEngineNetwork' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'ListClusters' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getClusters', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\VmwareEngine\V1\ListClustersResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListExternalAccessRules' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getExternalAccessRules', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\VmwareEngine\V1\ListExternalAccessRulesResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListExternalAddresses' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getExternalAddresses', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\VmwareEngine\V1\ListExternalAddressesResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListHcxActivationKeys' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getHcxActivationKeys', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\VmwareEngine\V1\ListHcxActivationKeysResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListLoggingServers' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getLoggingServers', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\VmwareEngine\V1\ListLoggingServersResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListManagementDnsZoneBindings' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getManagementDnsZoneBindings', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\VmwareEngine\V1\ListManagementDnsZoneBindingsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListNetworkPeerings' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getNetworkPeerings', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\VmwareEngine\V1\ListNetworkPeeringsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListNetworkPolicies' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getNetworkPolicies', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\VmwareEngine\V1\ListNetworkPoliciesResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListNodeTypes' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getNodeTypes', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\VmwareEngine\V1\ListNodeTypesResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListNodes' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getNodes', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\VmwareEngine\V1\ListNodesResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListPeeringRoutes' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getPeeringRoutes', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\VmwareEngine\V1\ListPeeringRoutesResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListPrivateClouds' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getPrivateClouds', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\VmwareEngine\V1\ListPrivateCloudsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListPrivateConnectionPeeringRoutes' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getPeeringRoutes', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\VmwareEngine\V1\ListPrivateConnectionPeeringRoutesResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListPrivateConnections' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getPrivateConnections', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\VmwareEngine\V1\ListPrivateConnectionsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListSubnets' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getSubnets', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\VmwareEngine\V1\ListSubnetsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListVmwareEngineNetworks' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getVmwareEngineNetworks', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\VmwareEngine\V1\ListVmwareEngineNetworksResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ShowNsxCredentials' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\VmwareEngine\V1\Credentials', - 'headerParams' => [ - [ - 'keyName' => 'private_cloud', - 'fieldAccessors' => [ - 'getPrivateCloud', - ], - ], - ], - ], - 'ShowVcenterCredentials' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\VmwareEngine\V1\Credentials', - 'headerParams' => [ - [ - 'keyName' => 'private_cloud', - 'fieldAccessors' => [ - 'getPrivateCloud', - ], - ], - ], - ], - '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' => [ - 'cluster' => 'projects/{project}/locations/{location}/privateClouds/{private_cloud}/clusters/{cluster}', - 'dnsBindPermission' => 'projects/{project}/locations/{location}/dnsBindPermission', - 'dnsForwarding' => 'projects/{project}/locations/{location}/privateClouds/{private_cloud}/dnsForwarding', - 'externalAccessRule' => 'projects/{project}/locations/{location}/networkPolicies/{network_policy}/externalAccessRules/{external_access_rule}', - 'externalAddress' => 'projects/{project}/locations/{location}/privateClouds/{private_cloud}/externalAddresses/{external_address}', - 'hcxActivationKey' => 'projects/{project}/locations/{location}/privateClouds/{private_cloud}/hcxActivationKeys/{hcx_activation_key}', - 'location' => 'projects/{project}/locations/{location}', - 'loggingServer' => 'projects/{project}/locations/{location}/privateClouds/{private_cloud}/loggingServers/{logging_server}', - 'managementDnsZoneBinding' => 'projects/{project}/locations/{location}/privateClouds/{private_cloud}/managementDnsZoneBindings/{management_dns_zone_binding}', - 'network' => 'projects/{project}/global/networks/{network}', - 'networkPeering' => 'projects/{project}/locations/{location}/networkPeerings/{network_peering}', - 'networkPolicy' => 'projects/{project}/locations/{location}/networkPolicies/{network_policy}', - 'node' => 'projects/{project}/locations/{location}/privateClouds/{private_cloud}/clusters/{cluster}/nodes/{node}', - 'nodeType' => 'projects/{project}/locations/{location}/nodeTypes/{node_type}', - 'privateCloud' => 'projects/{project}/locations/{location}/privateClouds/{private_cloud}', - 'privateConnection' => 'projects/{project}/locations/{location}/privateConnections/{private_connection}', - 'subnet' => 'projects/{project}/locations/{location}/privateClouds/{private_cloud}/subnets/{subnet}', - 'vmwareEngineNetwork' => 'projects/{project}/locations/{location}/vmwareEngineNetworks/{vmware_engine_network}', - ], - ], - ], -]; diff --git a/owl-bot-staging/VmwareEngine/v1/src/V1/resources/vmware_engine_rest_client_config.php b/owl-bot-staging/VmwareEngine/v1/src/V1/resources/vmware_engine_rest_client_config.php deleted file mode 100644 index c5a81f84f850..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/src/V1/resources/vmware_engine_rest_client_config.php +++ /dev/null @@ -1,1083 +0,0 @@ - [ - '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.cloud.vmwareengine.v1.VmwareEngine' => [ - 'CreateCluster' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/privateClouds/*}/clusters', - 'body' => 'cluster', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'cluster_id', - ], - ], - 'CreateExternalAccessRule' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/networkPolicies/*}/externalAccessRules', - 'body' => 'external_access_rule', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'external_access_rule_id', - ], - ], - 'CreateExternalAddress' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/privateClouds/*}/externalAddresses', - 'body' => 'external_address', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'external_address_id', - ], - ], - 'CreateHcxActivationKey' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/privateClouds/*}/hcxActivationKeys', - 'body' => 'hcx_activation_key', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'hcx_activation_key_id', - ], - ], - 'CreateLoggingServer' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/privateClouds/*}/loggingServers', - 'body' => 'logging_server', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'logging_server_id', - ], - ], - 'CreateManagementDnsZoneBinding' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/privateClouds/*}/managementDnsZoneBindings', - 'body' => 'management_dns_zone_binding', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'management_dns_zone_binding_id', - ], - ], - 'CreateNetworkPeering' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/networkPeerings', - 'body' => 'network_peering', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'network_peering_id', - ], - ], - 'CreateNetworkPolicy' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/networkPolicies', - 'body' => 'network_policy', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'network_policy_id', - ], - ], - 'CreatePrivateCloud' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/privateClouds', - 'body' => 'private_cloud', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'private_cloud_id', - ], - ], - 'CreatePrivateConnection' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/privateConnections', - 'body' => 'private_connection', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'private_connection_id', - ], - ], - 'CreateVmwareEngineNetwork' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/vmwareEngineNetworks', - 'body' => 'vmware_engine_network', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'vmware_engine_network_id', - ], - ], - 'DeleteCluster' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/privateClouds/*/clusters/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteExternalAccessRule' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/networkPolicies/*/externalAccessRules/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteExternalAddress' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/privateClouds/*/externalAddresses/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteLoggingServer' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/privateClouds/*/loggingServers/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteManagementDnsZoneBinding' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/privateClouds/*/managementDnsZoneBindings/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteNetworkPeering' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/networkPeerings/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteNetworkPolicy' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/networkPolicies/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeletePrivateCloud' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/privateClouds/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeletePrivateConnection' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/privateConnections/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteVmwareEngineNetwork' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/vmwareEngineNetworks/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'FetchNetworkPolicyExternalAddresses' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{network_policy=projects/*/locations/*/networkPolicies/*}:fetchExternalAddresses', - 'placeholders' => [ - 'network_policy' => [ - 'getters' => [ - 'getNetworkPolicy', - ], - ], - ], - ], - 'GetCluster' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/privateClouds/*/clusters/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetDnsBindPermission' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/dnsBindPermission}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetDnsForwarding' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/privateClouds/*/dnsForwarding}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetExternalAccessRule' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/networkPolicies/*/externalAccessRules/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetExternalAddress' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/privateClouds/*/externalAddresses/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetHcxActivationKey' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/privateClouds/*/hcxActivationKeys/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetLoggingServer' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/privateClouds/*/loggingServers/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetManagementDnsZoneBinding' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/privateClouds/*/managementDnsZoneBindings/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetNetworkPeering' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/networkPeerings/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetNetworkPolicy' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/networkPolicies/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetNode' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/privateClouds/*/clusters/*/nodes/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetNodeType' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/nodeTypes/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetPrivateCloud' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/privateClouds/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetPrivateConnection' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/privateConnections/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetSubnet' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/privateClouds/*/subnets/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetVmwareEngineNetwork' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/vmwareEngineNetworks/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GrantDnsBindPermission' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/dnsBindPermission}:grant', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListClusters' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/privateClouds/*}/clusters', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListExternalAccessRules' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/networkPolicies/*}/externalAccessRules', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListExternalAddresses' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/privateClouds/*}/externalAddresses', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListHcxActivationKeys' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/privateClouds/*}/hcxActivationKeys', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListLoggingServers' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/privateClouds/*}/loggingServers', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListManagementDnsZoneBindings' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/privateClouds/*}/managementDnsZoneBindings', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListNetworkPeerings' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/networkPeerings', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListNetworkPolicies' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/networkPolicies', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListNodeTypes' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/nodeTypes', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListNodes' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/privateClouds/*/clusters/*}/nodes', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListPeeringRoutes' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/networkPeerings/*}/peeringRoutes', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListPrivateClouds' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/privateClouds', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListPrivateConnectionPeeringRoutes' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/privateConnections/*}/peeringRoutes', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListPrivateConnections' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/privateConnections', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListSubnets' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/privateClouds/*}/subnets', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListVmwareEngineNetworks' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/vmwareEngineNetworks', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'RepairManagementDnsZoneBinding' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/privateClouds/*/managementDnsZoneBindings/*}:repair', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ResetNsxCredentials' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{private_cloud=projects/*/locations/*/privateClouds/*}:resetNsxCredentials', - 'body' => '*', - 'placeholders' => [ - 'private_cloud' => [ - 'getters' => [ - 'getPrivateCloud', - ], - ], - ], - ], - 'ResetVcenterCredentials' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{private_cloud=projects/*/locations/*/privateClouds/*}:resetVcenterCredentials', - 'body' => '*', - 'placeholders' => [ - 'private_cloud' => [ - 'getters' => [ - 'getPrivateCloud', - ], - ], - ], - ], - 'RevokeDnsBindPermission' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/dnsBindPermission}:revoke', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ShowNsxCredentials' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{private_cloud=projects/*/locations/*/privateClouds/*}:showNsxCredentials', - 'placeholders' => [ - 'private_cloud' => [ - 'getters' => [ - 'getPrivateCloud', - ], - ], - ], - ], - 'ShowVcenterCredentials' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{private_cloud=projects/*/locations/*/privateClouds/*}:showVcenterCredentials', - 'placeholders' => [ - 'private_cloud' => [ - 'getters' => [ - 'getPrivateCloud', - ], - ], - ], - ], - 'UndeletePrivateCloud' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/privateClouds/*}:undelete', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'UpdateCluster' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{cluster.name=projects/*/locations/*/privateClouds/*/clusters/*}', - 'body' => 'cluster', - 'placeholders' => [ - 'cluster.name' => [ - 'getters' => [ - 'getCluster', - 'getName', - ], - ], - ], - 'queryParams' => [ - 'update_mask', - ], - ], - 'UpdateDnsForwarding' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{dns_forwarding.name=projects/*/locations/*/privateClouds/*/dnsForwarding}', - 'body' => 'dns_forwarding', - 'placeholders' => [ - 'dns_forwarding.name' => [ - 'getters' => [ - 'getDnsForwarding', - 'getName', - ], - ], - ], - 'queryParams' => [ - 'update_mask', - ], - ], - 'UpdateExternalAccessRule' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{external_access_rule.name=projects/*/locations/*/networkPolicies/*/externalAccessRules/*}', - 'body' => 'external_access_rule', - 'placeholders' => [ - 'external_access_rule.name' => [ - 'getters' => [ - 'getExternalAccessRule', - 'getName', - ], - ], - ], - 'queryParams' => [ - 'update_mask', - ], - ], - 'UpdateExternalAddress' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{external_address.name=projects/*/locations/*/privateClouds/*/externalAddresses/*}', - 'body' => 'external_address', - 'placeholders' => [ - 'external_address.name' => [ - 'getters' => [ - 'getExternalAddress', - 'getName', - ], - ], - ], - 'queryParams' => [ - 'update_mask', - ], - ], - 'UpdateLoggingServer' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{logging_server.name=projects/*/locations/*/privateClouds/*/loggingServers/*}', - 'body' => 'logging_server', - 'placeholders' => [ - 'logging_server.name' => [ - 'getters' => [ - 'getLoggingServer', - 'getName', - ], - ], - ], - 'queryParams' => [ - 'update_mask', - ], - ], - 'UpdateManagementDnsZoneBinding' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{management_dns_zone_binding.name=projects/*/locations/*/privateClouds/*/managementDnsZoneBindings/*}', - 'body' => 'management_dns_zone_binding', - 'placeholders' => [ - 'management_dns_zone_binding.name' => [ - 'getters' => [ - 'getManagementDnsZoneBinding', - 'getName', - ], - ], - ], - 'queryParams' => [ - 'update_mask', - ], - ], - 'UpdateNetworkPeering' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{network_peering.name=projects/*/locations/*/networkPeerings/*}', - 'body' => 'network_peering', - 'placeholders' => [ - 'network_peering.name' => [ - 'getters' => [ - 'getNetworkPeering', - 'getName', - ], - ], - ], - 'queryParams' => [ - 'update_mask', - ], - ], - 'UpdateNetworkPolicy' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{network_policy.name=projects/*/locations/*/networkPolicies/*}', - 'body' => 'network_policy', - 'placeholders' => [ - 'network_policy.name' => [ - 'getters' => [ - 'getNetworkPolicy', - 'getName', - ], - ], - ], - 'queryParams' => [ - 'update_mask', - ], - ], - 'UpdatePrivateCloud' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{private_cloud.name=projects/*/locations/*/privateClouds/*}', - 'body' => 'private_cloud', - 'placeholders' => [ - 'private_cloud.name' => [ - 'getters' => [ - 'getPrivateCloud', - 'getName', - ], - ], - ], - 'queryParams' => [ - 'update_mask', - ], - ], - 'UpdatePrivateConnection' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{private_connection.name=projects/*/locations/*/privateConnections/*}', - 'body' => 'private_connection', - 'placeholders' => [ - 'private_connection.name' => [ - 'getters' => [ - 'getPrivateConnection', - 'getName', - ], - ], - ], - 'queryParams' => [ - 'update_mask', - ], - ], - 'UpdateSubnet' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{subnet.name=projects/*/locations/*/privateClouds/*/subnets/*}', - 'body' => 'subnet', - 'placeholders' => [ - 'subnet.name' => [ - 'getters' => [ - 'getSubnet', - 'getName', - ], - ], - ], - 'queryParams' => [ - 'update_mask', - ], - ], - 'UpdateVmwareEngineNetwork' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{vmware_engine_network.name=projects/*/locations/*/vmwareEngineNetworks/*}', - 'body' => 'vmware_engine_network', - 'placeholders' => [ - 'vmware_engine_network.name' => [ - 'getters' => [ - 'getVmwareEngineNetwork', - 'getName', - ], - ], - ], - 'queryParams' => [ - 'update_mask', - ], - ], - ], - 'google.iam.v1.IAMPolicy' => [ - 'GetIamPolicy' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/privateClouds/*}:getIamPolicy', - 'additionalBindings' => [ - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/privateClouds/*/clusters/*}:getIamPolicy', - ], - [ - 'method' => 'get', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/privateClouds/*/hcxActivationKeys/*}:getIamPolicy', - ], - ], - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'SetIamPolicy' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/privateClouds/*}:setIamPolicy', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/privateClouds/*/clusters/*}:setIamPolicy', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/privateClouds/*/hcxActivationKeys/*}:setIamPolicy', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - 'TestIamPermissions' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/privateClouds/*}:testIamPermissions', - 'body' => '*', - 'additionalBindings' => [ - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/privateClouds/*/clusters/*}:testIamPermissions', - 'body' => '*', - ], - [ - 'method' => 'post', - 'uriTemplate' => '/v1/{resource=projects/*/locations/*/privateClouds/*/hcxActivationKeys/*}:testIamPermissions', - 'body' => '*', - ], - ], - 'placeholders' => [ - 'resource' => [ - 'getters' => [ - 'getResource', - ], - ], - ], - ], - ], - 'google.longrunning.Operations' => [ - '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/VmwareEngine/v1/tests/Unit/V1/Client/VmwareEngineClientTest.php b/owl-bot-staging/VmwareEngine/v1/tests/Unit/V1/Client/VmwareEngineClientTest.php deleted file mode 100644 index 5152911fa8be..000000000000 --- a/owl-bot-staging/VmwareEngine/v1/tests/Unit/V1/Client/VmwareEngineClientTest.php +++ /dev/null @@ -1,8496 +0,0 @@ -getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); - } - - /** @return VmwareEngineClient */ - private function createClient(array $options = []) - { - $options += [ - 'credentials' => $this->createCredentials(), - ]; - return new VmwareEngineClient($options); - } - - /** @test */ - public function createClusterTest() - { - $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/createClusterTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $management = false; - $uid = 'uid115792'; - $expectedResponse = new Cluster(); - $expectedResponse->setName($name); - $expectedResponse->setManagement($management); - $expectedResponse->setUid($uid); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createClusterTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); - $clusterId = 'clusterId240280960'; - $cluster = new Cluster(); - $nodeTypeConfigsValue = new NodeTypeConfig(); - $valueNodeCount = 1174748740; - $nodeTypeConfigsValue->setNodeCount($valueNodeCount); - $clusterNodeTypeConfigs = [ - 'nodeTypeConfigsKey' => $nodeTypeConfigsValue, - ]; - $cluster->setNodeTypeConfigs($clusterNodeTypeConfigs); - $request = (new CreateClusterRequest()) - ->setParent($formattedParent) - ->setClusterId($clusterId) - ->setCluster($cluster); - $response = $gapicClient->createCluster($request); - $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.vmwareengine.v1.VmwareEngine/CreateCluster', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getClusterId(); - $this->assertProtobufEquals($clusterId, $actualValue); - $actualValue = $actualApiRequestObject->getCluster(); - $this->assertProtobufEquals($cluster, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createClusterTest'); - $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 createClusterExceptionTest() - { - $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/createClusterTest'); - $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->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); - $clusterId = 'clusterId240280960'; - $cluster = new Cluster(); - $nodeTypeConfigsValue = new NodeTypeConfig(); - $valueNodeCount = 1174748740; - $nodeTypeConfigsValue->setNodeCount($valueNodeCount); - $clusterNodeTypeConfigs = [ - 'nodeTypeConfigsKey' => $nodeTypeConfigsValue, - ]; - $cluster->setNodeTypeConfigs($clusterNodeTypeConfigs); - $request = (new CreateClusterRequest()) - ->setParent($formattedParent) - ->setClusterId($clusterId) - ->setCluster($cluster); - $response = $gapicClient->createCluster($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createClusterTest'); - 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 createExternalAccessRuleTest() - { - $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/createExternalAccessRuleTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $description = 'description-1724546052'; - $priority = 1165461084; - $ipProtocol = 'ipProtocol-1134653776'; - $uid = 'uid115792'; - $expectedResponse = new ExternalAccessRule(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $expectedResponse->setPriority($priority); - $expectedResponse->setIpProtocol($ipProtocol); - $expectedResponse->setUid($uid); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createExternalAccessRuleTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->networkPolicyName('[PROJECT]', '[LOCATION]', '[NETWORK_POLICY]'); - $externalAccessRule = new ExternalAccessRule(); - $externalAccessRuleId = 'externalAccessRuleId1434975319'; - $request = (new CreateExternalAccessRuleRequest()) - ->setParent($formattedParent) - ->setExternalAccessRule($externalAccessRule) - ->setExternalAccessRuleId($externalAccessRuleId); - $response = $gapicClient->createExternalAccessRule($request); - $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.vmwareengine.v1.VmwareEngine/CreateExternalAccessRule', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getExternalAccessRule(); - $this->assertProtobufEquals($externalAccessRule, $actualValue); - $actualValue = $actualApiRequestObject->getExternalAccessRuleId(); - $this->assertProtobufEquals($externalAccessRuleId, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createExternalAccessRuleTest'); - $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 createExternalAccessRuleExceptionTest() - { - $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/createExternalAccessRuleTest'); - $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->networkPolicyName('[PROJECT]', '[LOCATION]', '[NETWORK_POLICY]'); - $externalAccessRule = new ExternalAccessRule(); - $externalAccessRuleId = 'externalAccessRuleId1434975319'; - $request = (new CreateExternalAccessRuleRequest()) - ->setParent($formattedParent) - ->setExternalAccessRule($externalAccessRule) - ->setExternalAccessRuleId($externalAccessRuleId); - $response = $gapicClient->createExternalAccessRule($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createExternalAccessRuleTest'); - 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 createExternalAddressTest() - { - $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/createExternalAddressTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $internalIp = 'internalIp-2080778775'; - $externalIp = 'externalIp-1153075685'; - $uid = 'uid115792'; - $description = 'description-1724546052'; - $expectedResponse = new ExternalAddress(); - $expectedResponse->setName($name); - $expectedResponse->setInternalIp($internalIp); - $expectedResponse->setExternalIp($externalIp); - $expectedResponse->setUid($uid); - $expectedResponse->setDescription($description); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createExternalAddressTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); - $externalAddress = new ExternalAddress(); - $externalAddressId = 'externalAddressId344331834'; - $request = (new CreateExternalAddressRequest()) - ->setParent($formattedParent) - ->setExternalAddress($externalAddress) - ->setExternalAddressId($externalAddressId); - $response = $gapicClient->createExternalAddress($request); - $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.vmwareengine.v1.VmwareEngine/CreateExternalAddress', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getExternalAddress(); - $this->assertProtobufEquals($externalAddress, $actualValue); - $actualValue = $actualApiRequestObject->getExternalAddressId(); - $this->assertProtobufEquals($externalAddressId, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createExternalAddressTest'); - $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 createExternalAddressExceptionTest() - { - $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/createExternalAddressTest'); - $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->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); - $externalAddress = new ExternalAddress(); - $externalAddressId = 'externalAddressId344331834'; - $request = (new CreateExternalAddressRequest()) - ->setParent($formattedParent) - ->setExternalAddress($externalAddress) - ->setExternalAddressId($externalAddressId); - $response = $gapicClient->createExternalAddress($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createExternalAddressTest'); - 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 createHcxActivationKeyTest() - { - $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/createHcxActivationKeyTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $activationKey = 'activationKey-1343958090'; - $uid = 'uid115792'; - $expectedResponse = new HcxActivationKey(); - $expectedResponse->setName($name); - $expectedResponse->setActivationKey($activationKey); - $expectedResponse->setUid($uid); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createHcxActivationKeyTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); - $hcxActivationKey = new HcxActivationKey(); - $hcxActivationKeyId = 'hcxActivationKeyId26532194'; - $request = (new CreateHcxActivationKeyRequest()) - ->setParent($formattedParent) - ->setHcxActivationKey($hcxActivationKey) - ->setHcxActivationKeyId($hcxActivationKeyId); - $response = $gapicClient->createHcxActivationKey($request); - $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.vmwareengine.v1.VmwareEngine/CreateHcxActivationKey', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getHcxActivationKey(); - $this->assertProtobufEquals($hcxActivationKey, $actualValue); - $actualValue = $actualApiRequestObject->getHcxActivationKeyId(); - $this->assertProtobufEquals($hcxActivationKeyId, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createHcxActivationKeyTest'); - $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 createHcxActivationKeyExceptionTest() - { - $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/createHcxActivationKeyTest'); - $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->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); - $hcxActivationKey = new HcxActivationKey(); - $hcxActivationKeyId = 'hcxActivationKeyId26532194'; - $request = (new CreateHcxActivationKeyRequest()) - ->setParent($formattedParent) - ->setHcxActivationKey($hcxActivationKey) - ->setHcxActivationKeyId($hcxActivationKeyId); - $response = $gapicClient->createHcxActivationKey($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createHcxActivationKeyTest'); - 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 createLoggingServerTest() - { - $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/createLoggingServerTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $hostname = 'hostname-299803597'; - $port = 3446913; - $uid = 'uid115792'; - $expectedResponse = new LoggingServer(); - $expectedResponse->setName($name); - $expectedResponse->setHostname($hostname); - $expectedResponse->setPort($port); - $expectedResponse->setUid($uid); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createLoggingServerTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); - $loggingServer = new LoggingServer(); - $loggingServerHostname = 'loggingServerHostname2082652629'; - $loggingServer->setHostname($loggingServerHostname); - $loggingServerPort = 243392733; - $loggingServer->setPort($loggingServerPort); - $loggingServerProtocol = Protocol::PROTOCOL_UNSPECIFIED; - $loggingServer->setProtocol($loggingServerProtocol); - $loggingServerSourceType = SourceType::SOURCE_TYPE_UNSPECIFIED; - $loggingServer->setSourceType($loggingServerSourceType); - $loggingServerId = 'loggingServerId-2097171785'; - $request = (new CreateLoggingServerRequest()) - ->setParent($formattedParent) - ->setLoggingServer($loggingServer) - ->setLoggingServerId($loggingServerId); - $response = $gapicClient->createLoggingServer($request); - $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.vmwareengine.v1.VmwareEngine/CreateLoggingServer', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getLoggingServer(); - $this->assertProtobufEquals($loggingServer, $actualValue); - $actualValue = $actualApiRequestObject->getLoggingServerId(); - $this->assertProtobufEquals($loggingServerId, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createLoggingServerTest'); - $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 createLoggingServerExceptionTest() - { - $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/createLoggingServerTest'); - $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->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); - $loggingServer = new LoggingServer(); - $loggingServerHostname = 'loggingServerHostname2082652629'; - $loggingServer->setHostname($loggingServerHostname); - $loggingServerPort = 243392733; - $loggingServer->setPort($loggingServerPort); - $loggingServerProtocol = Protocol::PROTOCOL_UNSPECIFIED; - $loggingServer->setProtocol($loggingServerProtocol); - $loggingServerSourceType = SourceType::SOURCE_TYPE_UNSPECIFIED; - $loggingServer->setSourceType($loggingServerSourceType); - $loggingServerId = 'loggingServerId-2097171785'; - $request = (new CreateLoggingServerRequest()) - ->setParent($formattedParent) - ->setLoggingServer($loggingServer) - ->setLoggingServerId($loggingServerId); - $response = $gapicClient->createLoggingServer($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createLoggingServerTest'); - 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 createManagementDnsZoneBindingTest() - { - $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/createManagementDnsZoneBindingTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $description = 'description-1724546052'; - $vpcNetwork = 'vpcNetwork-764161832'; - $uid = 'uid115792'; - $expectedResponse = new ManagementDnsZoneBinding(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $expectedResponse->setVpcNetwork($vpcNetwork); - $expectedResponse->setUid($uid); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createManagementDnsZoneBindingTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); - $managementDnsZoneBinding = new ManagementDnsZoneBinding(); - $managementDnsZoneBindingId = 'managementDnsZoneBindingId-1294625162'; - $request = (new CreateManagementDnsZoneBindingRequest()) - ->setParent($formattedParent) - ->setManagementDnsZoneBinding($managementDnsZoneBinding) - ->setManagementDnsZoneBindingId($managementDnsZoneBindingId); - $response = $gapicClient->createManagementDnsZoneBinding($request); - $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.vmwareengine.v1.VmwareEngine/CreateManagementDnsZoneBinding', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getManagementDnsZoneBinding(); - $this->assertProtobufEquals($managementDnsZoneBinding, $actualValue); - $actualValue = $actualApiRequestObject->getManagementDnsZoneBindingId(); - $this->assertProtobufEquals($managementDnsZoneBindingId, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createManagementDnsZoneBindingTest'); - $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 createManagementDnsZoneBindingExceptionTest() - { - $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/createManagementDnsZoneBindingTest'); - $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->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); - $managementDnsZoneBinding = new ManagementDnsZoneBinding(); - $managementDnsZoneBindingId = 'managementDnsZoneBindingId-1294625162'; - $request = (new CreateManagementDnsZoneBindingRequest()) - ->setParent($formattedParent) - ->setManagementDnsZoneBinding($managementDnsZoneBinding) - ->setManagementDnsZoneBindingId($managementDnsZoneBindingId); - $response = $gapicClient->createManagementDnsZoneBinding($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createManagementDnsZoneBindingTest'); - 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 createNetworkPeeringTest() - { - $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/createNetworkPeeringTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $peerNetwork = 'peerNetwork2111238225'; - $exportCustomRoutes = false; - $importCustomRoutes = true; - $exchangeSubnetRoutes = true; - $exportCustomRoutesWithPublicIp = true; - $importCustomRoutesWithPublicIp = false; - $stateDetails = 'stateDetails632437908'; - $peerMtu = 69584721; - $uid = 'uid115792'; - $vmwareEngineNetwork = 'vmwareEngineNetwork-90899684'; - $description = 'description-1724546052'; - $expectedResponse = new NetworkPeering(); - $expectedResponse->setName($name); - $expectedResponse->setPeerNetwork($peerNetwork); - $expectedResponse->setExportCustomRoutes($exportCustomRoutes); - $expectedResponse->setImportCustomRoutes($importCustomRoutes); - $expectedResponse->setExchangeSubnetRoutes($exchangeSubnetRoutes); - $expectedResponse->setExportCustomRoutesWithPublicIp($exportCustomRoutesWithPublicIp); - $expectedResponse->setImportCustomRoutesWithPublicIp($importCustomRoutesWithPublicIp); - $expectedResponse->setStateDetails($stateDetails); - $expectedResponse->setPeerMtu($peerMtu); - $expectedResponse->setUid($uid); - $expectedResponse->setVmwareEngineNetwork($vmwareEngineNetwork); - $expectedResponse->setDescription($description); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createNetworkPeeringTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $networkPeeringId = 'networkPeeringId-2057959125'; - $networkPeering = new NetworkPeering(); - $networkPeeringPeerNetwork = 'networkPeeringPeerNetwork-385302054'; - $networkPeering->setPeerNetwork($networkPeeringPeerNetwork); - $networkPeeringPeerNetworkType = PeerNetworkType::PEER_NETWORK_TYPE_UNSPECIFIED; - $networkPeering->setPeerNetworkType($networkPeeringPeerNetworkType); - $networkPeeringVmwareEngineNetwork = $gapicClient->vmwareEngineNetworkName('[PROJECT]', '[LOCATION]', '[VMWARE_ENGINE_NETWORK]'); - $networkPeering->setVmwareEngineNetwork($networkPeeringVmwareEngineNetwork); - $request = (new CreateNetworkPeeringRequest()) - ->setParent($formattedParent) - ->setNetworkPeeringId($networkPeeringId) - ->setNetworkPeering($networkPeering); - $response = $gapicClient->createNetworkPeering($request); - $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.vmwareengine.v1.VmwareEngine/CreateNetworkPeering', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getNetworkPeeringId(); - $this->assertProtobufEquals($networkPeeringId, $actualValue); - $actualValue = $actualApiRequestObject->getNetworkPeering(); - $this->assertProtobufEquals($networkPeering, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createNetworkPeeringTest'); - $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 createNetworkPeeringExceptionTest() - { - $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/createNetworkPeeringTest'); - $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]'); - $networkPeeringId = 'networkPeeringId-2057959125'; - $networkPeering = new NetworkPeering(); - $networkPeeringPeerNetwork = 'networkPeeringPeerNetwork-385302054'; - $networkPeering->setPeerNetwork($networkPeeringPeerNetwork); - $networkPeeringPeerNetworkType = PeerNetworkType::PEER_NETWORK_TYPE_UNSPECIFIED; - $networkPeering->setPeerNetworkType($networkPeeringPeerNetworkType); - $networkPeeringVmwareEngineNetwork = $gapicClient->vmwareEngineNetworkName('[PROJECT]', '[LOCATION]', '[VMWARE_ENGINE_NETWORK]'); - $networkPeering->setVmwareEngineNetwork($networkPeeringVmwareEngineNetwork); - $request = (new CreateNetworkPeeringRequest()) - ->setParent($formattedParent) - ->setNetworkPeeringId($networkPeeringId) - ->setNetworkPeering($networkPeering); - $response = $gapicClient->createNetworkPeering($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createNetworkPeeringTest'); - 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 createNetworkPolicyTest() - { - $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/createNetworkPolicyTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $edgeServicesCidr = 'edgeServicesCidr-792872013'; - $uid = 'uid115792'; - $vmwareEngineNetwork = 'vmwareEngineNetwork-90899684'; - $description = 'description-1724546052'; - $vmwareEngineNetworkCanonical = 'vmwareEngineNetworkCanonical779839377'; - $expectedResponse = new NetworkPolicy(); - $expectedResponse->setName($name); - $expectedResponse->setEdgeServicesCidr($edgeServicesCidr); - $expectedResponse->setUid($uid); - $expectedResponse->setVmwareEngineNetwork($vmwareEngineNetwork); - $expectedResponse->setDescription($description); - $expectedResponse->setVmwareEngineNetworkCanonical($vmwareEngineNetworkCanonical); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createNetworkPolicyTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $networkPolicyId = 'networkPolicyId173955703'; - $networkPolicy = new NetworkPolicy(); - $networkPolicyEdgeServicesCidr = 'networkPolicyEdgeServicesCidr-602005393'; - $networkPolicy->setEdgeServicesCidr($networkPolicyEdgeServicesCidr); - $request = (new CreateNetworkPolicyRequest()) - ->setParent($formattedParent) - ->setNetworkPolicyId($networkPolicyId) - ->setNetworkPolicy($networkPolicy); - $response = $gapicClient->createNetworkPolicy($request); - $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.vmwareengine.v1.VmwareEngine/CreateNetworkPolicy', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getNetworkPolicyId(); - $this->assertProtobufEquals($networkPolicyId, $actualValue); - $actualValue = $actualApiRequestObject->getNetworkPolicy(); - $this->assertProtobufEquals($networkPolicy, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createNetworkPolicyTest'); - $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 createNetworkPolicyExceptionTest() - { - $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/createNetworkPolicyTest'); - $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]'); - $networkPolicyId = 'networkPolicyId173955703'; - $networkPolicy = new NetworkPolicy(); - $networkPolicyEdgeServicesCidr = 'networkPolicyEdgeServicesCidr-602005393'; - $networkPolicy->setEdgeServicesCidr($networkPolicyEdgeServicesCidr); - $request = (new CreateNetworkPolicyRequest()) - ->setParent($formattedParent) - ->setNetworkPolicyId($networkPolicyId) - ->setNetworkPolicy($networkPolicy); - $response = $gapicClient->createNetworkPolicy($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createNetworkPolicyTest'); - 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 createPrivateCloudTest() - { - $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/createPrivateCloudTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $description = 'description-1724546052'; - $uid = 'uid115792'; - $expectedResponse = new PrivateCloud(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $expectedResponse->setUid($uid); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createPrivateCloudTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $privateCloudId = 'privateCloudId1366391457'; - $privateCloud = new PrivateCloud(); - $privateCloudNetworkConfig = new NetworkConfig(); - $networkConfigManagementCidr = 'networkConfigManagementCidr2092091783'; - $privateCloudNetworkConfig->setManagementCidr($networkConfigManagementCidr); - $privateCloud->setNetworkConfig($privateCloudNetworkConfig); - $privateCloudManagementCluster = new ManagementCluster(); - $managementClusterClusterId = 'managementClusterClusterId311493182'; - $privateCloudManagementCluster->setClusterId($managementClusterClusterId); - $nodeTypeConfigsValue = new NodeTypeConfig(); - $valueNodeCount = 1174748740; - $nodeTypeConfigsValue->setNodeCount($valueNodeCount); - $managementClusterNodeTypeConfigs = [ - 'nodeTypeConfigsKey' => $nodeTypeConfigsValue, - ]; - $privateCloudManagementCluster->setNodeTypeConfigs($managementClusterNodeTypeConfigs); - $privateCloud->setManagementCluster($privateCloudManagementCluster); - $request = (new CreatePrivateCloudRequest()) - ->setParent($formattedParent) - ->setPrivateCloudId($privateCloudId) - ->setPrivateCloud($privateCloud); - $response = $gapicClient->createPrivateCloud($request); - $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.vmwareengine.v1.VmwareEngine/CreatePrivateCloud', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getPrivateCloudId(); - $this->assertProtobufEquals($privateCloudId, $actualValue); - $actualValue = $actualApiRequestObject->getPrivateCloud(); - $this->assertProtobufEquals($privateCloud, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createPrivateCloudTest'); - $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 createPrivateCloudExceptionTest() - { - $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/createPrivateCloudTest'); - $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]'); - $privateCloudId = 'privateCloudId1366391457'; - $privateCloud = new PrivateCloud(); - $privateCloudNetworkConfig = new NetworkConfig(); - $networkConfigManagementCidr = 'networkConfigManagementCidr2092091783'; - $privateCloudNetworkConfig->setManagementCidr($networkConfigManagementCidr); - $privateCloud->setNetworkConfig($privateCloudNetworkConfig); - $privateCloudManagementCluster = new ManagementCluster(); - $managementClusterClusterId = 'managementClusterClusterId311493182'; - $privateCloudManagementCluster->setClusterId($managementClusterClusterId); - $nodeTypeConfigsValue = new NodeTypeConfig(); - $valueNodeCount = 1174748740; - $nodeTypeConfigsValue->setNodeCount($valueNodeCount); - $managementClusterNodeTypeConfigs = [ - 'nodeTypeConfigsKey' => $nodeTypeConfigsValue, - ]; - $privateCloudManagementCluster->setNodeTypeConfigs($managementClusterNodeTypeConfigs); - $privateCloud->setManagementCluster($privateCloudManagementCluster); - $request = (new CreatePrivateCloudRequest()) - ->setParent($formattedParent) - ->setPrivateCloudId($privateCloudId) - ->setPrivateCloud($privateCloud); - $response = $gapicClient->createPrivateCloud($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createPrivateCloudTest'); - 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 createPrivateConnectionTest() - { - $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/createPrivateConnectionTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $description = 'description-1724546052'; - $vmwareEngineNetwork = 'vmwareEngineNetwork-90899684'; - $vmwareEngineNetworkCanonical = 'vmwareEngineNetworkCanonical779839377'; - $peeringId = 'peeringId-1561749894'; - $uid = 'uid115792'; - $serviceNetwork = 'serviceNetwork1072775844'; - $expectedResponse = new PrivateConnection(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $expectedResponse->setVmwareEngineNetwork($vmwareEngineNetwork); - $expectedResponse->setVmwareEngineNetworkCanonical($vmwareEngineNetworkCanonical); - $expectedResponse->setPeeringId($peeringId); - $expectedResponse->setUid($uid); - $expectedResponse->setServiceNetwork($serviceNetwork); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createPrivateConnectionTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $privateConnectionId = 'privateConnectionId-1948601248'; - $privateConnection = new PrivateConnection(); - $privateConnectionVmwareEngineNetwork = $gapicClient->vmwareEngineNetworkName('[PROJECT]', '[LOCATION]', '[VMWARE_ENGINE_NETWORK]'); - $privateConnection->setVmwareEngineNetwork($privateConnectionVmwareEngineNetwork); - $privateConnectionType = Type::TYPE_UNSPECIFIED; - $privateConnection->setType($privateConnectionType); - $privateConnectionServiceNetwork = $gapicClient->networkName('[PROJECT]', '[NETWORK]'); - $privateConnection->setServiceNetwork($privateConnectionServiceNetwork); - $request = (new CreatePrivateConnectionRequest()) - ->setParent($formattedParent) - ->setPrivateConnectionId($privateConnectionId) - ->setPrivateConnection($privateConnection); - $response = $gapicClient->createPrivateConnection($request); - $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.vmwareengine.v1.VmwareEngine/CreatePrivateConnection', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getPrivateConnectionId(); - $this->assertProtobufEquals($privateConnectionId, $actualValue); - $actualValue = $actualApiRequestObject->getPrivateConnection(); - $this->assertProtobufEquals($privateConnection, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createPrivateConnectionTest'); - $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 createPrivateConnectionExceptionTest() - { - $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/createPrivateConnectionTest'); - $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]'); - $privateConnectionId = 'privateConnectionId-1948601248'; - $privateConnection = new PrivateConnection(); - $privateConnectionVmwareEngineNetwork = $gapicClient->vmwareEngineNetworkName('[PROJECT]', '[LOCATION]', '[VMWARE_ENGINE_NETWORK]'); - $privateConnection->setVmwareEngineNetwork($privateConnectionVmwareEngineNetwork); - $privateConnectionType = Type::TYPE_UNSPECIFIED; - $privateConnection->setType($privateConnectionType); - $privateConnectionServiceNetwork = $gapicClient->networkName('[PROJECT]', '[NETWORK]'); - $privateConnection->setServiceNetwork($privateConnectionServiceNetwork); - $request = (new CreatePrivateConnectionRequest()) - ->setParent($formattedParent) - ->setPrivateConnectionId($privateConnectionId) - ->setPrivateConnection($privateConnection); - $response = $gapicClient->createPrivateConnection($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createPrivateConnectionTest'); - 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 createVmwareEngineNetworkTest() - { - $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/createVmwareEngineNetworkTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $description = 'description-1724546052'; - $uid = 'uid115792'; - $etag = 'etag3123477'; - $expectedResponse = new VmwareEngineNetwork(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $expectedResponse->setUid($uid); - $expectedResponse->setEtag($etag); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createVmwareEngineNetworkTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $vmwareEngineNetworkId = 'vmwareEngineNetworkId2131972382'; - $vmwareEngineNetwork = new VmwareEngineNetwork(); - $vmwareEngineNetworkType = \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork\Type::TYPE_UNSPECIFIED; - $vmwareEngineNetwork->setType($vmwareEngineNetworkType); - $request = (new CreateVmwareEngineNetworkRequest()) - ->setParent($formattedParent) - ->setVmwareEngineNetworkId($vmwareEngineNetworkId) - ->setVmwareEngineNetwork($vmwareEngineNetwork); - $response = $gapicClient->createVmwareEngineNetwork($request); - $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.vmwareengine.v1.VmwareEngine/CreateVmwareEngineNetwork', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getVmwareEngineNetworkId(); - $this->assertProtobufEquals($vmwareEngineNetworkId, $actualValue); - $actualValue = $actualApiRequestObject->getVmwareEngineNetwork(); - $this->assertProtobufEquals($vmwareEngineNetwork, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createVmwareEngineNetworkTest'); - $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 createVmwareEngineNetworkExceptionTest() - { - $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/createVmwareEngineNetworkTest'); - $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]'); - $vmwareEngineNetworkId = 'vmwareEngineNetworkId2131972382'; - $vmwareEngineNetwork = new VmwareEngineNetwork(); - $vmwareEngineNetworkType = \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork\Type::TYPE_UNSPECIFIED; - $vmwareEngineNetwork->setType($vmwareEngineNetworkType); - $request = (new CreateVmwareEngineNetworkRequest()) - ->setParent($formattedParent) - ->setVmwareEngineNetworkId($vmwareEngineNetworkId) - ->setVmwareEngineNetwork($vmwareEngineNetwork); - $response = $gapicClient->createVmwareEngineNetwork($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createVmwareEngineNetworkTest'); - 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 deleteClusterTest() - { - $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/deleteClusterTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteClusterTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->clusterName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[CLUSTER]'); - $request = (new DeleteClusterRequest()) - ->setName($formattedName); - $response = $gapicClient->deleteCluster($request); - $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.vmwareengine.v1.VmwareEngine/DeleteCluster', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteClusterTest'); - $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 deleteClusterExceptionTest() - { - $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/deleteClusterTest'); - $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->clusterName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[CLUSTER]'); - $request = (new DeleteClusterRequest()) - ->setName($formattedName); - $response = $gapicClient->deleteCluster($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteClusterTest'); - 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 deleteExternalAccessRuleTest() - { - $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/deleteExternalAccessRuleTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteExternalAccessRuleTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->externalAccessRuleName('[PROJECT]', '[LOCATION]', '[NETWORK_POLICY]', '[EXTERNAL_ACCESS_RULE]'); - $request = (new DeleteExternalAccessRuleRequest()) - ->setName($formattedName); - $response = $gapicClient->deleteExternalAccessRule($request); - $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.vmwareengine.v1.VmwareEngine/DeleteExternalAccessRule', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteExternalAccessRuleTest'); - $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 deleteExternalAccessRuleExceptionTest() - { - $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/deleteExternalAccessRuleTest'); - $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->externalAccessRuleName('[PROJECT]', '[LOCATION]', '[NETWORK_POLICY]', '[EXTERNAL_ACCESS_RULE]'); - $request = (new DeleteExternalAccessRuleRequest()) - ->setName($formattedName); - $response = $gapicClient->deleteExternalAccessRule($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteExternalAccessRuleTest'); - 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 deleteExternalAddressTest() - { - $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/deleteExternalAddressTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteExternalAddressTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->externalAddressName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[EXTERNAL_ADDRESS]'); - $request = (new DeleteExternalAddressRequest()) - ->setName($formattedName); - $response = $gapicClient->deleteExternalAddress($request); - $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.vmwareengine.v1.VmwareEngine/DeleteExternalAddress', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteExternalAddressTest'); - $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 deleteExternalAddressExceptionTest() - { - $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/deleteExternalAddressTest'); - $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->externalAddressName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[EXTERNAL_ADDRESS]'); - $request = (new DeleteExternalAddressRequest()) - ->setName($formattedName); - $response = $gapicClient->deleteExternalAddress($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteExternalAddressTest'); - 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 deleteLoggingServerTest() - { - $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/deleteLoggingServerTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteLoggingServerTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->loggingServerName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[LOGGING_SERVER]'); - $request = (new DeleteLoggingServerRequest()) - ->setName($formattedName); - $response = $gapicClient->deleteLoggingServer($request); - $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.vmwareengine.v1.VmwareEngine/DeleteLoggingServer', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteLoggingServerTest'); - $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 deleteLoggingServerExceptionTest() - { - $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/deleteLoggingServerTest'); - $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->loggingServerName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[LOGGING_SERVER]'); - $request = (new DeleteLoggingServerRequest()) - ->setName($formattedName); - $response = $gapicClient->deleteLoggingServer($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteLoggingServerTest'); - 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 deleteManagementDnsZoneBindingTest() - { - $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/deleteManagementDnsZoneBindingTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteManagementDnsZoneBindingTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->managementDnsZoneBindingName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[MANAGEMENT_DNS_ZONE_BINDING]'); - $request = (new DeleteManagementDnsZoneBindingRequest()) - ->setName($formattedName); - $response = $gapicClient->deleteManagementDnsZoneBinding($request); - $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.vmwareengine.v1.VmwareEngine/DeleteManagementDnsZoneBinding', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteManagementDnsZoneBindingTest'); - $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 deleteManagementDnsZoneBindingExceptionTest() - { - $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/deleteManagementDnsZoneBindingTest'); - $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->managementDnsZoneBindingName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[MANAGEMENT_DNS_ZONE_BINDING]'); - $request = (new DeleteManagementDnsZoneBindingRequest()) - ->setName($formattedName); - $response = $gapicClient->deleteManagementDnsZoneBinding($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteManagementDnsZoneBindingTest'); - 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 deleteNetworkPeeringTest() - { - $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/deleteNetworkPeeringTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteNetworkPeeringTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->networkPeeringName('[PROJECT]', '[LOCATION]', '[NETWORK_PEERING]'); - $request = (new DeleteNetworkPeeringRequest()) - ->setName($formattedName); - $response = $gapicClient->deleteNetworkPeering($request); - $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.vmwareengine.v1.VmwareEngine/DeleteNetworkPeering', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteNetworkPeeringTest'); - $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 deleteNetworkPeeringExceptionTest() - { - $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/deleteNetworkPeeringTest'); - $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->networkPeeringName('[PROJECT]', '[LOCATION]', '[NETWORK_PEERING]'); - $request = (new DeleteNetworkPeeringRequest()) - ->setName($formattedName); - $response = $gapicClient->deleteNetworkPeering($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteNetworkPeeringTest'); - 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 deleteNetworkPolicyTest() - { - $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/deleteNetworkPolicyTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteNetworkPolicyTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->networkPolicyName('[PROJECT]', '[LOCATION]', '[NETWORK_POLICY]'); - $request = (new DeleteNetworkPolicyRequest()) - ->setName($formattedName); - $response = $gapicClient->deleteNetworkPolicy($request); - $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.vmwareengine.v1.VmwareEngine/DeleteNetworkPolicy', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteNetworkPolicyTest'); - $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 deleteNetworkPolicyExceptionTest() - { - $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/deleteNetworkPolicyTest'); - $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->networkPolicyName('[PROJECT]', '[LOCATION]', '[NETWORK_POLICY]'); - $request = (new DeleteNetworkPolicyRequest()) - ->setName($formattedName); - $response = $gapicClient->deleteNetworkPolicy($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteNetworkPolicyTest'); - 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 deletePrivateCloudTest() - { - $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/deletePrivateCloudTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name2 = 'name2-1052831874'; - $description = 'description-1724546052'; - $uid = 'uid115792'; - $expectedResponse = new PrivateCloud(); - $expectedResponse->setName($name2); - $expectedResponse->setDescription($description); - $expectedResponse->setUid($uid); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deletePrivateCloudTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); - $request = (new DeletePrivateCloudRequest()) - ->setName($formattedName); - $response = $gapicClient->deletePrivateCloud($request); - $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.vmwareengine.v1.VmwareEngine/DeletePrivateCloud', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deletePrivateCloudTest'); - $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 deletePrivateCloudExceptionTest() - { - $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/deletePrivateCloudTest'); - $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->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); - $request = (new DeletePrivateCloudRequest()) - ->setName($formattedName); - $response = $gapicClient->deletePrivateCloud($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deletePrivateCloudTest'); - 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 deletePrivateConnectionTest() - { - $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/deletePrivateConnectionTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deletePrivateConnectionTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->privateConnectionName('[PROJECT]', '[LOCATION]', '[PRIVATE_CONNECTION]'); - $request = (new DeletePrivateConnectionRequest()) - ->setName($formattedName); - $response = $gapicClient->deletePrivateConnection($request); - $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.vmwareengine.v1.VmwareEngine/DeletePrivateConnection', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deletePrivateConnectionTest'); - $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 deletePrivateConnectionExceptionTest() - { - $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/deletePrivateConnectionTest'); - $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->privateConnectionName('[PROJECT]', '[LOCATION]', '[PRIVATE_CONNECTION]'); - $request = (new DeletePrivateConnectionRequest()) - ->setName($formattedName); - $response = $gapicClient->deletePrivateConnection($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deletePrivateConnectionTest'); - 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 deleteVmwareEngineNetworkTest() - { - $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/deleteVmwareEngineNetworkTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteVmwareEngineNetworkTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->vmwareEngineNetworkName('[PROJECT]', '[LOCATION]', '[VMWARE_ENGINE_NETWORK]'); - $request = (new DeleteVmwareEngineNetworkRequest()) - ->setName($formattedName); - $response = $gapicClient->deleteVmwareEngineNetwork($request); - $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.vmwareengine.v1.VmwareEngine/DeleteVmwareEngineNetwork', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteVmwareEngineNetworkTest'); - $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 deleteVmwareEngineNetworkExceptionTest() - { - $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/deleteVmwareEngineNetworkTest'); - $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->vmwareEngineNetworkName('[PROJECT]', '[LOCATION]', '[VMWARE_ENGINE_NETWORK]'); - $request = (new DeleteVmwareEngineNetworkRequest()) - ->setName($formattedName); - $response = $gapicClient->deleteVmwareEngineNetwork($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteVmwareEngineNetworkTest'); - 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 fetchNetworkPolicyExternalAddressesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $externalAddressesElement = new ExternalAddress(); - $externalAddresses = [ - $externalAddressesElement, - ]; - $expectedResponse = new FetchNetworkPolicyExternalAddressesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setExternalAddresses($externalAddresses); - $transport->addResponse($expectedResponse); - // Mock request - $formattedNetworkPolicy = $gapicClient->networkPolicyName('[PROJECT]', '[LOCATION]', '[NETWORK_POLICY]'); - $request = (new FetchNetworkPolicyExternalAddressesRequest()) - ->setNetworkPolicy($formattedNetworkPolicy); - $response = $gapicClient->fetchNetworkPolicyExternalAddresses($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getExternalAddresses()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/FetchNetworkPolicyExternalAddresses', $actualFuncCall); - $actualValue = $actualRequestObject->getNetworkPolicy(); - $this->assertProtobufEquals($formattedNetworkPolicy, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function fetchNetworkPolicyExternalAddressesExceptionTest() - { - $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 - $formattedNetworkPolicy = $gapicClient->networkPolicyName('[PROJECT]', '[LOCATION]', '[NETWORK_POLICY]'); - $request = (new FetchNetworkPolicyExternalAddressesRequest()) - ->setNetworkPolicy($formattedNetworkPolicy); - try { - $gapicClient->fetchNetworkPolicyExternalAddresses($request); - // 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 getClusterTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $management = false; - $uid = 'uid115792'; - $expectedResponse = new Cluster(); - $expectedResponse->setName($name2); - $expectedResponse->setManagement($management); - $expectedResponse->setUid($uid); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->clusterName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[CLUSTER]'); - $request = (new GetClusterRequest()) - ->setName($formattedName); - $response = $gapicClient->getCluster($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/GetCluster', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getClusterExceptionTest() - { - $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->clusterName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[CLUSTER]'); - $request = (new GetClusterRequest()) - ->setName($formattedName); - try { - $gapicClient->getCluster($request); - // 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 getDnsBindPermissionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $expectedResponse = new DnsBindPermission(); - $expectedResponse->setName($name2); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->dnsBindPermissionName('[PROJECT]', '[LOCATION]'); - $request = (new GetDnsBindPermissionRequest()) - ->setName($formattedName); - $response = $gapicClient->getDnsBindPermission($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/GetDnsBindPermission', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getDnsBindPermissionExceptionTest() - { - $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->dnsBindPermissionName('[PROJECT]', '[LOCATION]'); - $request = (new GetDnsBindPermissionRequest()) - ->setName($formattedName); - try { - $gapicClient->getDnsBindPermission($request); - // 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 getDnsForwardingTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $expectedResponse = new DnsForwarding(); - $expectedResponse->setName($name2); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->dnsForwardingName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); - $request = (new GetDnsForwardingRequest()) - ->setName($formattedName); - $response = $gapicClient->getDnsForwarding($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/GetDnsForwarding', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getDnsForwardingExceptionTest() - { - $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->dnsForwardingName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); - $request = (new GetDnsForwardingRequest()) - ->setName($formattedName); - try { - $gapicClient->getDnsForwarding($request); - // 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 getExternalAccessRuleTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $description = 'description-1724546052'; - $priority = 1165461084; - $ipProtocol = 'ipProtocol-1134653776'; - $uid = 'uid115792'; - $expectedResponse = new ExternalAccessRule(); - $expectedResponse->setName($name2); - $expectedResponse->setDescription($description); - $expectedResponse->setPriority($priority); - $expectedResponse->setIpProtocol($ipProtocol); - $expectedResponse->setUid($uid); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->externalAccessRuleName('[PROJECT]', '[LOCATION]', '[NETWORK_POLICY]', '[EXTERNAL_ACCESS_RULE]'); - $request = (new GetExternalAccessRuleRequest()) - ->setName($formattedName); - $response = $gapicClient->getExternalAccessRule($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/GetExternalAccessRule', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getExternalAccessRuleExceptionTest() - { - $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->externalAccessRuleName('[PROJECT]', '[LOCATION]', '[NETWORK_POLICY]', '[EXTERNAL_ACCESS_RULE]'); - $request = (new GetExternalAccessRuleRequest()) - ->setName($formattedName); - try { - $gapicClient->getExternalAccessRule($request); - // 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 getExternalAddressTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $internalIp = 'internalIp-2080778775'; - $externalIp = 'externalIp-1153075685'; - $uid = 'uid115792'; - $description = 'description-1724546052'; - $expectedResponse = new ExternalAddress(); - $expectedResponse->setName($name2); - $expectedResponse->setInternalIp($internalIp); - $expectedResponse->setExternalIp($externalIp); - $expectedResponse->setUid($uid); - $expectedResponse->setDescription($description); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->externalAddressName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[EXTERNAL_ADDRESS]'); - $request = (new GetExternalAddressRequest()) - ->setName($formattedName); - $response = $gapicClient->getExternalAddress($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/GetExternalAddress', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getExternalAddressExceptionTest() - { - $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->externalAddressName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[EXTERNAL_ADDRESS]'); - $request = (new GetExternalAddressRequest()) - ->setName($formattedName); - try { - $gapicClient->getExternalAddress($request); - // 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 getHcxActivationKeyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $activationKey = 'activationKey-1343958090'; - $uid = 'uid115792'; - $expectedResponse = new HcxActivationKey(); - $expectedResponse->setName($name2); - $expectedResponse->setActivationKey($activationKey); - $expectedResponse->setUid($uid); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->hcxActivationKeyName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[HCX_ACTIVATION_KEY]'); - $request = (new GetHcxActivationKeyRequest()) - ->setName($formattedName); - $response = $gapicClient->getHcxActivationKey($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/GetHcxActivationKey', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getHcxActivationKeyExceptionTest() - { - $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->hcxActivationKeyName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[HCX_ACTIVATION_KEY]'); - $request = (new GetHcxActivationKeyRequest()) - ->setName($formattedName); - try { - $gapicClient->getHcxActivationKey($request); - // 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 getLoggingServerTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $hostname = 'hostname-299803597'; - $port = 3446913; - $uid = 'uid115792'; - $expectedResponse = new LoggingServer(); - $expectedResponse->setName($name2); - $expectedResponse->setHostname($hostname); - $expectedResponse->setPort($port); - $expectedResponse->setUid($uid); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->loggingServerName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[LOGGING_SERVER]'); - $request = (new GetLoggingServerRequest()) - ->setName($formattedName); - $response = $gapicClient->getLoggingServer($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/GetLoggingServer', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getLoggingServerExceptionTest() - { - $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->loggingServerName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[LOGGING_SERVER]'); - $request = (new GetLoggingServerRequest()) - ->setName($formattedName); - try { - $gapicClient->getLoggingServer($request); - // 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 getManagementDnsZoneBindingTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $description = 'description-1724546052'; - $vpcNetwork = 'vpcNetwork-764161832'; - $uid = 'uid115792'; - $expectedResponse = new ManagementDnsZoneBinding(); - $expectedResponse->setName($name2); - $expectedResponse->setDescription($description); - $expectedResponse->setVpcNetwork($vpcNetwork); - $expectedResponse->setUid($uid); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->managementDnsZoneBindingName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[MANAGEMENT_DNS_ZONE_BINDING]'); - $request = (new GetManagementDnsZoneBindingRequest()) - ->setName($formattedName); - $response = $gapicClient->getManagementDnsZoneBinding($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/GetManagementDnsZoneBinding', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getManagementDnsZoneBindingExceptionTest() - { - $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->managementDnsZoneBindingName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[MANAGEMENT_DNS_ZONE_BINDING]'); - $request = (new GetManagementDnsZoneBindingRequest()) - ->setName($formattedName); - try { - $gapicClient->getManagementDnsZoneBinding($request); - // 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 getNetworkPeeringTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $peerNetwork = 'peerNetwork2111238225'; - $exportCustomRoutes = false; - $importCustomRoutes = true; - $exchangeSubnetRoutes = true; - $exportCustomRoutesWithPublicIp = true; - $importCustomRoutesWithPublicIp = false; - $stateDetails = 'stateDetails632437908'; - $peerMtu = 69584721; - $uid = 'uid115792'; - $vmwareEngineNetwork = 'vmwareEngineNetwork-90899684'; - $description = 'description-1724546052'; - $expectedResponse = new NetworkPeering(); - $expectedResponse->setName($name2); - $expectedResponse->setPeerNetwork($peerNetwork); - $expectedResponse->setExportCustomRoutes($exportCustomRoutes); - $expectedResponse->setImportCustomRoutes($importCustomRoutes); - $expectedResponse->setExchangeSubnetRoutes($exchangeSubnetRoutes); - $expectedResponse->setExportCustomRoutesWithPublicIp($exportCustomRoutesWithPublicIp); - $expectedResponse->setImportCustomRoutesWithPublicIp($importCustomRoutesWithPublicIp); - $expectedResponse->setStateDetails($stateDetails); - $expectedResponse->setPeerMtu($peerMtu); - $expectedResponse->setUid($uid); - $expectedResponse->setVmwareEngineNetwork($vmwareEngineNetwork); - $expectedResponse->setDescription($description); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->networkPeeringName('[PROJECT]', '[LOCATION]', '[NETWORK_PEERING]'); - $request = (new GetNetworkPeeringRequest()) - ->setName($formattedName); - $response = $gapicClient->getNetworkPeering($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/GetNetworkPeering', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getNetworkPeeringExceptionTest() - { - $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->networkPeeringName('[PROJECT]', '[LOCATION]', '[NETWORK_PEERING]'); - $request = (new GetNetworkPeeringRequest()) - ->setName($formattedName); - try { - $gapicClient->getNetworkPeering($request); - // 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 getNetworkPolicyTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $edgeServicesCidr = 'edgeServicesCidr-792872013'; - $uid = 'uid115792'; - $vmwareEngineNetwork = 'vmwareEngineNetwork-90899684'; - $description = 'description-1724546052'; - $vmwareEngineNetworkCanonical = 'vmwareEngineNetworkCanonical779839377'; - $expectedResponse = new NetworkPolicy(); - $expectedResponse->setName($name2); - $expectedResponse->setEdgeServicesCidr($edgeServicesCidr); - $expectedResponse->setUid($uid); - $expectedResponse->setVmwareEngineNetwork($vmwareEngineNetwork); - $expectedResponse->setDescription($description); - $expectedResponse->setVmwareEngineNetworkCanonical($vmwareEngineNetworkCanonical); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->networkPolicyName('[PROJECT]', '[LOCATION]', '[NETWORK_POLICY]'); - $request = (new GetNetworkPolicyRequest()) - ->setName($formattedName); - $response = $gapicClient->getNetworkPolicy($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/GetNetworkPolicy', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getNetworkPolicyExceptionTest() - { - $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->networkPolicyName('[PROJECT]', '[LOCATION]', '[NETWORK_POLICY]'); - $request = (new GetNetworkPolicyRequest()) - ->setName($formattedName); - try { - $gapicClient->getNetworkPolicy($request); - // 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 getNodeTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $fqdn = 'fqdn3150485'; - $internalIp = 'internalIp-2080778775'; - $nodeTypeId = 'nodeTypeId585437955'; - $version = 'version351608024'; - $customCoreCount = 2091833853; - $expectedResponse = new Node(); - $expectedResponse->setName($name2); - $expectedResponse->setFqdn($fqdn); - $expectedResponse->setInternalIp($internalIp); - $expectedResponse->setNodeTypeId($nodeTypeId); - $expectedResponse->setVersion($version); - $expectedResponse->setCustomCoreCount($customCoreCount); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->nodeName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[CLUSTER]', '[NODE]'); - $request = (new GetNodeRequest()) - ->setName($formattedName); - $response = $gapicClient->getNode($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/GetNode', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getNodeExceptionTest() - { - $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->nodeName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[CLUSTER]', '[NODE]'); - $request = (new GetNodeRequest()) - ->setName($formattedName); - try { - $gapicClient->getNode($request); - // 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 getNodeTypeTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $nodeTypeId = 'nodeTypeId585437955'; - $displayName = 'displayName1615086568'; - $virtualCpuCount = 289038212; - $totalCoreCount = 282953654; - $memoryGb = 1726613721; - $diskSizeGb = 757478089; - $expectedResponse = new NodeType(); - $expectedResponse->setName($name2); - $expectedResponse->setNodeTypeId($nodeTypeId); - $expectedResponse->setDisplayName($displayName); - $expectedResponse->setVirtualCpuCount($virtualCpuCount); - $expectedResponse->setTotalCoreCount($totalCoreCount); - $expectedResponse->setMemoryGb($memoryGb); - $expectedResponse->setDiskSizeGb($diskSizeGb); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->nodeTypeName('[PROJECT]', '[LOCATION]', '[NODE_TYPE]'); - $request = (new GetNodeTypeRequest()) - ->setName($formattedName); - $response = $gapicClient->getNodeType($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/GetNodeType', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getNodeTypeExceptionTest() - { - $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->nodeTypeName('[PROJECT]', '[LOCATION]', '[NODE_TYPE]'); - $request = (new GetNodeTypeRequest()) - ->setName($formattedName); - try { - $gapicClient->getNodeType($request); - // 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 getPrivateCloudTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $description = 'description-1724546052'; - $uid = 'uid115792'; - $expectedResponse = new PrivateCloud(); - $expectedResponse->setName($name2); - $expectedResponse->setDescription($description); - $expectedResponse->setUid($uid); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); - $request = (new GetPrivateCloudRequest()) - ->setName($formattedName); - $response = $gapicClient->getPrivateCloud($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/GetPrivateCloud', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getPrivateCloudExceptionTest() - { - $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->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); - $request = (new GetPrivateCloudRequest()) - ->setName($formattedName); - try { - $gapicClient->getPrivateCloud($request); - // 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 getPrivateConnectionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $description = 'description-1724546052'; - $vmwareEngineNetwork = 'vmwareEngineNetwork-90899684'; - $vmwareEngineNetworkCanonical = 'vmwareEngineNetworkCanonical779839377'; - $peeringId = 'peeringId-1561749894'; - $uid = 'uid115792'; - $serviceNetwork = 'serviceNetwork1072775844'; - $expectedResponse = new PrivateConnection(); - $expectedResponse->setName($name2); - $expectedResponse->setDescription($description); - $expectedResponse->setVmwareEngineNetwork($vmwareEngineNetwork); - $expectedResponse->setVmwareEngineNetworkCanonical($vmwareEngineNetworkCanonical); - $expectedResponse->setPeeringId($peeringId); - $expectedResponse->setUid($uid); - $expectedResponse->setServiceNetwork($serviceNetwork); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->privateConnectionName('[PROJECT]', '[LOCATION]', '[PRIVATE_CONNECTION]'); - $request = (new GetPrivateConnectionRequest()) - ->setName($formattedName); - $response = $gapicClient->getPrivateConnection($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/GetPrivateConnection', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getPrivateConnectionExceptionTest() - { - $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->privateConnectionName('[PROJECT]', '[LOCATION]', '[PRIVATE_CONNECTION]'); - $request = (new GetPrivateConnectionRequest()) - ->setName($formattedName); - try { - $gapicClient->getPrivateConnection($request); - // 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 getSubnetTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $ipCidrRange = 'ipCidrRange-2049366326'; - $gatewayIp = 'gatewayIp955798786'; - $type = 'type3575610'; - $vlanId = 536153463; - $expectedResponse = new Subnet(); - $expectedResponse->setName($name2); - $expectedResponse->setIpCidrRange($ipCidrRange); - $expectedResponse->setGatewayIp($gatewayIp); - $expectedResponse->setType($type); - $expectedResponse->setVlanId($vlanId); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->subnetName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[SUBNET]'); - $request = (new GetSubnetRequest()) - ->setName($formattedName); - $response = $gapicClient->getSubnet($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/GetSubnet', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getSubnetExceptionTest() - { - $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->subnetName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[SUBNET]'); - $request = (new GetSubnetRequest()) - ->setName($formattedName); - try { - $gapicClient->getSubnet($request); - // 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 getVmwareEngineNetworkTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $description = 'description-1724546052'; - $uid = 'uid115792'; - $etag = 'etag3123477'; - $expectedResponse = new VmwareEngineNetwork(); - $expectedResponse->setName($name2); - $expectedResponse->setDescription($description); - $expectedResponse->setUid($uid); - $expectedResponse->setEtag($etag); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->vmwareEngineNetworkName('[PROJECT]', '[LOCATION]', '[VMWARE_ENGINE_NETWORK]'); - $request = (new GetVmwareEngineNetworkRequest()) - ->setName($formattedName); - $response = $gapicClient->getVmwareEngineNetwork($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/GetVmwareEngineNetwork', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getVmwareEngineNetworkExceptionTest() - { - $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->vmwareEngineNetworkName('[PROJECT]', '[LOCATION]', '[VMWARE_ENGINE_NETWORK]'); - $request = (new GetVmwareEngineNetworkRequest()) - ->setName($formattedName); - try { - $gapicClient->getVmwareEngineNetwork($request); - // 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 grantDnsBindPermissionTest() - { - $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/grantDnsBindPermissionTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name2 = 'name2-1052831874'; - $expectedResponse = new DnsBindPermission(); - $expectedResponse->setName($name2); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/grantDnsBindPermissionTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->dnsBindPermissionName('[PROJECT]', '[LOCATION]'); - $principal = new Principal(); - $request = (new GrantDnsBindPermissionRequest()) - ->setName($formattedName) - ->setPrincipal($principal); - $response = $gapicClient->grantDnsBindPermission($request); - $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.vmwareengine.v1.VmwareEngine/GrantDnsBindPermission', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $actualValue = $actualApiRequestObject->getPrincipal(); - $this->assertProtobufEquals($principal, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/grantDnsBindPermissionTest'); - $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 grantDnsBindPermissionExceptionTest() - { - $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/grantDnsBindPermissionTest'); - $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->dnsBindPermissionName('[PROJECT]', '[LOCATION]'); - $principal = new Principal(); - $request = (new GrantDnsBindPermissionRequest()) - ->setName($formattedName) - ->setPrincipal($principal); - $response = $gapicClient->grantDnsBindPermission($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/grantDnsBindPermissionTest'); - 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 listClustersTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $clustersElement = new Cluster(); - $clusters = [ - $clustersElement, - ]; - $expectedResponse = new ListClustersResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setClusters($clusters); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); - $request = (new ListClustersRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listClusters($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getClusters()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/ListClusters', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listClustersExceptionTest() - { - $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->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); - $request = (new ListClustersRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listClusters($request); - // 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 listExternalAccessRulesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $externalAccessRulesElement = new ExternalAccessRule(); - $externalAccessRules = [ - $externalAccessRulesElement, - ]; - $expectedResponse = new ListExternalAccessRulesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setExternalAccessRules($externalAccessRules); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->networkPolicyName('[PROJECT]', '[LOCATION]', '[NETWORK_POLICY]'); - $request = (new ListExternalAccessRulesRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listExternalAccessRules($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getExternalAccessRules()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/ListExternalAccessRules', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listExternalAccessRulesExceptionTest() - { - $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->networkPolicyName('[PROJECT]', '[LOCATION]', '[NETWORK_POLICY]'); - $request = (new ListExternalAccessRulesRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listExternalAccessRules($request); - // 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 listExternalAddressesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $externalAddressesElement = new ExternalAddress(); - $externalAddresses = [ - $externalAddressesElement, - ]; - $expectedResponse = new ListExternalAddressesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setExternalAddresses($externalAddresses); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); - $request = (new ListExternalAddressesRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listExternalAddresses($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getExternalAddresses()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/ListExternalAddresses', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listExternalAddressesExceptionTest() - { - $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->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); - $request = (new ListExternalAddressesRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listExternalAddresses($request); - // 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 listHcxActivationKeysTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $hcxActivationKeysElement = new HcxActivationKey(); - $hcxActivationKeys = [ - $hcxActivationKeysElement, - ]; - $expectedResponse = new ListHcxActivationKeysResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setHcxActivationKeys($hcxActivationKeys); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); - $request = (new ListHcxActivationKeysRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listHcxActivationKeys($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getHcxActivationKeys()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/ListHcxActivationKeys', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listHcxActivationKeysExceptionTest() - { - $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->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); - $request = (new ListHcxActivationKeysRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listHcxActivationKeys($request); - // 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 listLoggingServersTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $loggingServersElement = new LoggingServer(); - $loggingServers = [ - $loggingServersElement, - ]; - $expectedResponse = new ListLoggingServersResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setLoggingServers($loggingServers); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); - $request = (new ListLoggingServersRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listLoggingServers($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getLoggingServers()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/ListLoggingServers', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listLoggingServersExceptionTest() - { - $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->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); - $request = (new ListLoggingServersRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listLoggingServers($request); - // 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 listManagementDnsZoneBindingsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $managementDnsZoneBindingsElement = new ManagementDnsZoneBinding(); - $managementDnsZoneBindings = [ - $managementDnsZoneBindingsElement, - ]; - $expectedResponse = new ListManagementDnsZoneBindingsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setManagementDnsZoneBindings($managementDnsZoneBindings); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); - $request = (new ListManagementDnsZoneBindingsRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listManagementDnsZoneBindings($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getManagementDnsZoneBindings()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/ListManagementDnsZoneBindings', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listManagementDnsZoneBindingsExceptionTest() - { - $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->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); - $request = (new ListManagementDnsZoneBindingsRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listManagementDnsZoneBindings($request); - // 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 listNetworkPeeringsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $networkPeeringsElement = new NetworkPeering(); - $networkPeerings = [ - $networkPeeringsElement, - ]; - $expectedResponse = new ListNetworkPeeringsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setNetworkPeerings($networkPeerings); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $request = (new ListNetworkPeeringsRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listNetworkPeerings($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getNetworkPeerings()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/ListNetworkPeerings', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listNetworkPeeringsExceptionTest() - { - $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]'); - $request = (new ListNetworkPeeringsRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listNetworkPeerings($request); - // 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 listNetworkPoliciesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $networkPoliciesElement = new NetworkPolicy(); - $networkPolicies = [ - $networkPoliciesElement, - ]; - $expectedResponse = new ListNetworkPoliciesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setNetworkPolicies($networkPolicies); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $request = (new ListNetworkPoliciesRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listNetworkPolicies($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getNetworkPolicies()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/ListNetworkPolicies', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listNetworkPoliciesExceptionTest() - { - $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]'); - $request = (new ListNetworkPoliciesRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listNetworkPolicies($request); - // 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 listNodeTypesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $nodeTypesElement = new NodeType(); - $nodeTypes = [ - $nodeTypesElement, - ]; - $expectedResponse = new ListNodeTypesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setNodeTypes($nodeTypes); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $request = (new ListNodeTypesRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listNodeTypes($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getNodeTypes()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/ListNodeTypes', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listNodeTypesExceptionTest() - { - $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]'); - $request = (new ListNodeTypesRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listNodeTypes($request); - // 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 listNodesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $nodesElement = new Node(); - $nodes = [ - $nodesElement, - ]; - $expectedResponse = new ListNodesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setNodes($nodes); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->clusterName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[CLUSTER]'); - $request = (new ListNodesRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listNodes($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getNodes()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/ListNodes', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listNodesExceptionTest() - { - $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->clusterName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[CLUSTER]'); - $request = (new ListNodesRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listNodes($request); - // 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 listPeeringRoutesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $peeringRoutesElement = new PeeringRoute(); - $peeringRoutes = [ - $peeringRoutesElement, - ]; - $expectedResponse = new ListPeeringRoutesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setPeeringRoutes($peeringRoutes); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->networkPeeringName('[PROJECT]', '[LOCATION]', '[NETWORK_PEERING]'); - $request = (new ListPeeringRoutesRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listPeeringRoutes($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getPeeringRoutes()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/ListPeeringRoutes', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listPeeringRoutesExceptionTest() - { - $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->networkPeeringName('[PROJECT]', '[LOCATION]', '[NETWORK_PEERING]'); - $request = (new ListPeeringRoutesRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listPeeringRoutes($request); - // 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 listPrivateCloudsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $privateCloudsElement = new PrivateCloud(); - $privateClouds = [ - $privateCloudsElement, - ]; - $expectedResponse = new ListPrivateCloudsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setPrivateClouds($privateClouds); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $request = (new ListPrivateCloudsRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listPrivateClouds($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getPrivateClouds()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/ListPrivateClouds', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listPrivateCloudsExceptionTest() - { - $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]'); - $request = (new ListPrivateCloudsRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listPrivateClouds($request); - // 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 listPrivateConnectionPeeringRoutesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $peeringRoutesElement = new PeeringRoute(); - $peeringRoutes = [ - $peeringRoutesElement, - ]; - $expectedResponse = new ListPrivateConnectionPeeringRoutesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setPeeringRoutes($peeringRoutes); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->privateConnectionName('[PROJECT]', '[LOCATION]', '[PRIVATE_CONNECTION]'); - $request = (new ListPrivateConnectionPeeringRoutesRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listPrivateConnectionPeeringRoutes($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getPeeringRoutes()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/ListPrivateConnectionPeeringRoutes', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listPrivateConnectionPeeringRoutesExceptionTest() - { - $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->privateConnectionName('[PROJECT]', '[LOCATION]', '[PRIVATE_CONNECTION]'); - $request = (new ListPrivateConnectionPeeringRoutesRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listPrivateConnectionPeeringRoutes($request); - // 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 listPrivateConnectionsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $privateConnectionsElement = new PrivateConnection(); - $privateConnections = [ - $privateConnectionsElement, - ]; - $expectedResponse = new ListPrivateConnectionsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setPrivateConnections($privateConnections); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $request = (new ListPrivateConnectionsRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listPrivateConnections($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getPrivateConnections()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/ListPrivateConnections', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listPrivateConnectionsExceptionTest() - { - $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]'); - $request = (new ListPrivateConnectionsRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listPrivateConnections($request); - // 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 listSubnetsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $subnetsElement = new Subnet(); - $subnets = [ - $subnetsElement, - ]; - $expectedResponse = new ListSubnetsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setSubnets($subnets); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); - $request = (new ListSubnetsRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listSubnets($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getSubnets()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/ListSubnets', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listSubnetsExceptionTest() - { - $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->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); - $request = (new ListSubnetsRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listSubnets($request); - // 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 listVmwareEngineNetworksTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $vmwareEngineNetworksElement = new VmwareEngineNetwork(); - $vmwareEngineNetworks = [ - $vmwareEngineNetworksElement, - ]; - $expectedResponse = new ListVmwareEngineNetworksResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setVmwareEngineNetworks($vmwareEngineNetworks); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $request = (new ListVmwareEngineNetworksRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listVmwareEngineNetworks($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getVmwareEngineNetworks()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/ListVmwareEngineNetworks', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listVmwareEngineNetworksExceptionTest() - { - $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]'); - $request = (new ListVmwareEngineNetworksRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listVmwareEngineNetworks($request); - // 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 repairManagementDnsZoneBindingTest() - { - $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/repairManagementDnsZoneBindingTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name2 = 'name2-1052831874'; - $description = 'description-1724546052'; - $vpcNetwork = 'vpcNetwork-764161832'; - $uid = 'uid115792'; - $expectedResponse = new ManagementDnsZoneBinding(); - $expectedResponse->setName($name2); - $expectedResponse->setDescription($description); - $expectedResponse->setVpcNetwork($vpcNetwork); - $expectedResponse->setUid($uid); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/repairManagementDnsZoneBindingTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->managementDnsZoneBindingName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[MANAGEMENT_DNS_ZONE_BINDING]'); - $request = (new RepairManagementDnsZoneBindingRequest()) - ->setName($formattedName); - $response = $gapicClient->repairManagementDnsZoneBinding($request); - $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.vmwareengine.v1.VmwareEngine/RepairManagementDnsZoneBinding', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/repairManagementDnsZoneBindingTest'); - $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 repairManagementDnsZoneBindingExceptionTest() - { - $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/repairManagementDnsZoneBindingTest'); - $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->managementDnsZoneBindingName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]', '[MANAGEMENT_DNS_ZONE_BINDING]'); - $request = (new RepairManagementDnsZoneBindingRequest()) - ->setName($formattedName); - $response = $gapicClient->repairManagementDnsZoneBinding($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/repairManagementDnsZoneBindingTest'); - 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 resetNsxCredentialsTest() - { - $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/resetNsxCredentialsTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $description = 'description-1724546052'; - $uid = 'uid115792'; - $expectedResponse = new PrivateCloud(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $expectedResponse->setUid($uid); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/resetNsxCredentialsTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedPrivateCloud = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); - $request = (new ResetNsxCredentialsRequest()) - ->setPrivateCloud($formattedPrivateCloud); - $response = $gapicClient->resetNsxCredentials($request); - $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.vmwareengine.v1.VmwareEngine/ResetNsxCredentials', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getPrivateCloud(); - $this->assertProtobufEquals($formattedPrivateCloud, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/resetNsxCredentialsTest'); - $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 resetNsxCredentialsExceptionTest() - { - $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/resetNsxCredentialsTest'); - $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 - $formattedPrivateCloud = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); - $request = (new ResetNsxCredentialsRequest()) - ->setPrivateCloud($formattedPrivateCloud); - $response = $gapicClient->resetNsxCredentials($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/resetNsxCredentialsTest'); - 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 resetVcenterCredentialsTest() - { - $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/resetVcenterCredentialsTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $description = 'description-1724546052'; - $uid = 'uid115792'; - $expectedResponse = new PrivateCloud(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $expectedResponse->setUid($uid); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/resetVcenterCredentialsTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedPrivateCloud = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); - $request = (new ResetVcenterCredentialsRequest()) - ->setPrivateCloud($formattedPrivateCloud); - $response = $gapicClient->resetVcenterCredentials($request); - $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.vmwareengine.v1.VmwareEngine/ResetVcenterCredentials', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getPrivateCloud(); - $this->assertProtobufEquals($formattedPrivateCloud, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/resetVcenterCredentialsTest'); - $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 resetVcenterCredentialsExceptionTest() - { - $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/resetVcenterCredentialsTest'); - $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 - $formattedPrivateCloud = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); - $request = (new ResetVcenterCredentialsRequest()) - ->setPrivateCloud($formattedPrivateCloud); - $response = $gapicClient->resetVcenterCredentials($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/resetVcenterCredentialsTest'); - 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 revokeDnsBindPermissionTest() - { - $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/revokeDnsBindPermissionTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name2 = 'name2-1052831874'; - $expectedResponse = new DnsBindPermission(); - $expectedResponse->setName($name2); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/revokeDnsBindPermissionTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->dnsBindPermissionName('[PROJECT]', '[LOCATION]'); - $principal = new Principal(); - $request = (new RevokeDnsBindPermissionRequest()) - ->setName($formattedName) - ->setPrincipal($principal); - $response = $gapicClient->revokeDnsBindPermission($request); - $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.vmwareengine.v1.VmwareEngine/RevokeDnsBindPermission', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $actualValue = $actualApiRequestObject->getPrincipal(); - $this->assertProtobufEquals($principal, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/revokeDnsBindPermissionTest'); - $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 revokeDnsBindPermissionExceptionTest() - { - $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/revokeDnsBindPermissionTest'); - $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->dnsBindPermissionName('[PROJECT]', '[LOCATION]'); - $principal = new Principal(); - $request = (new RevokeDnsBindPermissionRequest()) - ->setName($formattedName) - ->setPrincipal($principal); - $response = $gapicClient->revokeDnsBindPermission($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/revokeDnsBindPermissionTest'); - 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 showNsxCredentialsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $username = 'username-265713450'; - $password = 'password1216985755'; - $expectedResponse = new Credentials(); - $expectedResponse->setUsername($username); - $expectedResponse->setPassword($password); - $transport->addResponse($expectedResponse); - // Mock request - $formattedPrivateCloud = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); - $request = (new ShowNsxCredentialsRequest()) - ->setPrivateCloud($formattedPrivateCloud); - $response = $gapicClient->showNsxCredentials($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/ShowNsxCredentials', $actualFuncCall); - $actualValue = $actualRequestObject->getPrivateCloud(); - $this->assertProtobufEquals($formattedPrivateCloud, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function showNsxCredentialsExceptionTest() - { - $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 - $formattedPrivateCloud = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); - $request = (new ShowNsxCredentialsRequest()) - ->setPrivateCloud($formattedPrivateCloud); - try { - $gapicClient->showNsxCredentials($request); - // 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 showVcenterCredentialsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $username2 = 'username2-1947551991'; - $password = 'password1216985755'; - $expectedResponse = new Credentials(); - $expectedResponse->setUsername($username2); - $expectedResponse->setPassword($password); - $transport->addResponse($expectedResponse); - // Mock request - $formattedPrivateCloud = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); - $request = (new ShowVcenterCredentialsRequest()) - ->setPrivateCloud($formattedPrivateCloud); - $response = $gapicClient->showVcenterCredentials($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.vmwareengine.v1.VmwareEngine/ShowVcenterCredentials', $actualFuncCall); - $actualValue = $actualRequestObject->getPrivateCloud(); - $this->assertProtobufEquals($formattedPrivateCloud, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function showVcenterCredentialsExceptionTest() - { - $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 - $formattedPrivateCloud = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); - $request = (new ShowVcenterCredentialsRequest()) - ->setPrivateCloud($formattedPrivateCloud); - try { - $gapicClient->showVcenterCredentials($request); - // 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 undeletePrivateCloudTest() - { - $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/undeletePrivateCloudTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name2 = 'name2-1052831874'; - $description = 'description-1724546052'; - $uid = 'uid115792'; - $expectedResponse = new PrivateCloud(); - $expectedResponse->setName($name2); - $expectedResponse->setDescription($description); - $expectedResponse->setUid($uid); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/undeletePrivateCloudTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); - $request = (new UndeletePrivateCloudRequest()) - ->setName($formattedName); - $response = $gapicClient->undeletePrivateCloud($request); - $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.vmwareengine.v1.VmwareEngine/UndeletePrivateCloud', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/undeletePrivateCloudTest'); - $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 undeletePrivateCloudExceptionTest() - { - $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/undeletePrivateCloudTest'); - $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->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); - $request = (new UndeletePrivateCloudRequest()) - ->setName($formattedName); - $response = $gapicClient->undeletePrivateCloud($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/undeletePrivateCloudTest'); - 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 updateClusterTest() - { - $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/updateClusterTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $management = false; - $uid = 'uid115792'; - $expectedResponse = new Cluster(); - $expectedResponse->setName($name); - $expectedResponse->setManagement($management); - $expectedResponse->setUid($uid); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateClusterTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $updateMask = new FieldMask(); - $cluster = new Cluster(); - $nodeTypeConfigsValue = new NodeTypeConfig(); - $valueNodeCount = 1174748740; - $nodeTypeConfigsValue->setNodeCount($valueNodeCount); - $clusterNodeTypeConfigs = [ - 'nodeTypeConfigsKey' => $nodeTypeConfigsValue, - ]; - $cluster->setNodeTypeConfigs($clusterNodeTypeConfigs); - $request = (new UpdateClusterRequest()) - ->setUpdateMask($updateMask) - ->setCluster($cluster); - $response = $gapicClient->updateCluster($request); - $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.vmwareengine.v1.VmwareEngine/UpdateCluster', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getUpdateMask(); - $this->assertProtobufEquals($updateMask, $actualValue); - $actualValue = $actualApiRequestObject->getCluster(); - $this->assertProtobufEquals($cluster, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateClusterTest'); - $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 updateClusterExceptionTest() - { - $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/updateClusterTest'); - $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(); - $cluster = new Cluster(); - $nodeTypeConfigsValue = new NodeTypeConfig(); - $valueNodeCount = 1174748740; - $nodeTypeConfigsValue->setNodeCount($valueNodeCount); - $clusterNodeTypeConfigs = [ - 'nodeTypeConfigsKey' => $nodeTypeConfigsValue, - ]; - $cluster->setNodeTypeConfigs($clusterNodeTypeConfigs); - $request = (new UpdateClusterRequest()) - ->setUpdateMask($updateMask) - ->setCluster($cluster); - $response = $gapicClient->updateCluster($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateClusterTest'); - 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 updateDnsForwardingTest() - { - $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/updateDnsForwardingTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $expectedResponse = new DnsForwarding(); - $expectedResponse->setName($name); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateDnsForwardingTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $dnsForwarding = new DnsForwarding(); - $dnsForwardingForwardingRules = []; - $dnsForwarding->setForwardingRules($dnsForwardingForwardingRules); - $updateMask = new FieldMask(); - $request = (new UpdateDnsForwardingRequest()) - ->setDnsForwarding($dnsForwarding) - ->setUpdateMask($updateMask); - $response = $gapicClient->updateDnsForwarding($request); - $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.vmwareengine.v1.VmwareEngine/UpdateDnsForwarding', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getDnsForwarding(); - $this->assertProtobufEquals($dnsForwarding, $actualValue); - $actualValue = $actualApiRequestObject->getUpdateMask(); - $this->assertProtobufEquals($updateMask, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateDnsForwardingTest'); - $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 updateDnsForwardingExceptionTest() - { - $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/updateDnsForwardingTest'); - $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 - $dnsForwarding = new DnsForwarding(); - $dnsForwardingForwardingRules = []; - $dnsForwarding->setForwardingRules($dnsForwardingForwardingRules); - $updateMask = new FieldMask(); - $request = (new UpdateDnsForwardingRequest()) - ->setDnsForwarding($dnsForwarding) - ->setUpdateMask($updateMask); - $response = $gapicClient->updateDnsForwarding($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateDnsForwardingTest'); - 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 updateExternalAccessRuleTest() - { - $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/updateExternalAccessRuleTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $description = 'description-1724546052'; - $priority = 1165461084; - $ipProtocol = 'ipProtocol-1134653776'; - $uid = 'uid115792'; - $expectedResponse = new ExternalAccessRule(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $expectedResponse->setPriority($priority); - $expectedResponse->setIpProtocol($ipProtocol); - $expectedResponse->setUid($uid); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateExternalAccessRuleTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $updateMask = new FieldMask(); - $externalAccessRule = new ExternalAccessRule(); - $request = (new UpdateExternalAccessRuleRequest()) - ->setUpdateMask($updateMask) - ->setExternalAccessRule($externalAccessRule); - $response = $gapicClient->updateExternalAccessRule($request); - $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.vmwareengine.v1.VmwareEngine/UpdateExternalAccessRule', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getUpdateMask(); - $this->assertProtobufEquals($updateMask, $actualValue); - $actualValue = $actualApiRequestObject->getExternalAccessRule(); - $this->assertProtobufEquals($externalAccessRule, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateExternalAccessRuleTest'); - $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 updateExternalAccessRuleExceptionTest() - { - $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/updateExternalAccessRuleTest'); - $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(); - $externalAccessRule = new ExternalAccessRule(); - $request = (new UpdateExternalAccessRuleRequest()) - ->setUpdateMask($updateMask) - ->setExternalAccessRule($externalAccessRule); - $response = $gapicClient->updateExternalAccessRule($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateExternalAccessRuleTest'); - 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 updateExternalAddressTest() - { - $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/updateExternalAddressTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $internalIp = 'internalIp-2080778775'; - $externalIp = 'externalIp-1153075685'; - $uid = 'uid115792'; - $description = 'description-1724546052'; - $expectedResponse = new ExternalAddress(); - $expectedResponse->setName($name); - $expectedResponse->setInternalIp($internalIp); - $expectedResponse->setExternalIp($externalIp); - $expectedResponse->setUid($uid); - $expectedResponse->setDescription($description); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateExternalAddressTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $updateMask = new FieldMask(); - $externalAddress = new ExternalAddress(); - $request = (new UpdateExternalAddressRequest()) - ->setUpdateMask($updateMask) - ->setExternalAddress($externalAddress); - $response = $gapicClient->updateExternalAddress($request); - $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.vmwareengine.v1.VmwareEngine/UpdateExternalAddress', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getUpdateMask(); - $this->assertProtobufEquals($updateMask, $actualValue); - $actualValue = $actualApiRequestObject->getExternalAddress(); - $this->assertProtobufEquals($externalAddress, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateExternalAddressTest'); - $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 updateExternalAddressExceptionTest() - { - $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/updateExternalAddressTest'); - $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(); - $externalAddress = new ExternalAddress(); - $request = (new UpdateExternalAddressRequest()) - ->setUpdateMask($updateMask) - ->setExternalAddress($externalAddress); - $response = $gapicClient->updateExternalAddress($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateExternalAddressTest'); - 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 updateLoggingServerTest() - { - $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/updateLoggingServerTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $hostname = 'hostname-299803597'; - $port = 3446913; - $uid = 'uid115792'; - $expectedResponse = new LoggingServer(); - $expectedResponse->setName($name); - $expectedResponse->setHostname($hostname); - $expectedResponse->setPort($port); - $expectedResponse->setUid($uid); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateLoggingServerTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $updateMask = new FieldMask(); - $loggingServer = new LoggingServer(); - $loggingServerHostname = 'loggingServerHostname2082652629'; - $loggingServer->setHostname($loggingServerHostname); - $loggingServerPort = 243392733; - $loggingServer->setPort($loggingServerPort); - $loggingServerProtocol = Protocol::PROTOCOL_UNSPECIFIED; - $loggingServer->setProtocol($loggingServerProtocol); - $loggingServerSourceType = SourceType::SOURCE_TYPE_UNSPECIFIED; - $loggingServer->setSourceType($loggingServerSourceType); - $request = (new UpdateLoggingServerRequest()) - ->setUpdateMask($updateMask) - ->setLoggingServer($loggingServer); - $response = $gapicClient->updateLoggingServer($request); - $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.vmwareengine.v1.VmwareEngine/UpdateLoggingServer', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getUpdateMask(); - $this->assertProtobufEquals($updateMask, $actualValue); - $actualValue = $actualApiRequestObject->getLoggingServer(); - $this->assertProtobufEquals($loggingServer, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateLoggingServerTest'); - $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 updateLoggingServerExceptionTest() - { - $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/updateLoggingServerTest'); - $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(); - $loggingServer = new LoggingServer(); - $loggingServerHostname = 'loggingServerHostname2082652629'; - $loggingServer->setHostname($loggingServerHostname); - $loggingServerPort = 243392733; - $loggingServer->setPort($loggingServerPort); - $loggingServerProtocol = Protocol::PROTOCOL_UNSPECIFIED; - $loggingServer->setProtocol($loggingServerProtocol); - $loggingServerSourceType = SourceType::SOURCE_TYPE_UNSPECIFIED; - $loggingServer->setSourceType($loggingServerSourceType); - $request = (new UpdateLoggingServerRequest()) - ->setUpdateMask($updateMask) - ->setLoggingServer($loggingServer); - $response = $gapicClient->updateLoggingServer($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateLoggingServerTest'); - 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 updateManagementDnsZoneBindingTest() - { - $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/updateManagementDnsZoneBindingTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $description = 'description-1724546052'; - $vpcNetwork = 'vpcNetwork-764161832'; - $uid = 'uid115792'; - $expectedResponse = new ManagementDnsZoneBinding(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $expectedResponse->setVpcNetwork($vpcNetwork); - $expectedResponse->setUid($uid); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateManagementDnsZoneBindingTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $updateMask = new FieldMask(); - $managementDnsZoneBinding = new ManagementDnsZoneBinding(); - $request = (new UpdateManagementDnsZoneBindingRequest()) - ->setUpdateMask($updateMask) - ->setManagementDnsZoneBinding($managementDnsZoneBinding); - $response = $gapicClient->updateManagementDnsZoneBinding($request); - $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.vmwareengine.v1.VmwareEngine/UpdateManagementDnsZoneBinding', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getUpdateMask(); - $this->assertProtobufEquals($updateMask, $actualValue); - $actualValue = $actualApiRequestObject->getManagementDnsZoneBinding(); - $this->assertProtobufEquals($managementDnsZoneBinding, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateManagementDnsZoneBindingTest'); - $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 updateManagementDnsZoneBindingExceptionTest() - { - $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/updateManagementDnsZoneBindingTest'); - $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(); - $managementDnsZoneBinding = new ManagementDnsZoneBinding(); - $request = (new UpdateManagementDnsZoneBindingRequest()) - ->setUpdateMask($updateMask) - ->setManagementDnsZoneBinding($managementDnsZoneBinding); - $response = $gapicClient->updateManagementDnsZoneBinding($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateManagementDnsZoneBindingTest'); - 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 updateNetworkPeeringTest() - { - $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/updateNetworkPeeringTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $peerNetwork = 'peerNetwork2111238225'; - $exportCustomRoutes = false; - $importCustomRoutes = true; - $exchangeSubnetRoutes = true; - $exportCustomRoutesWithPublicIp = true; - $importCustomRoutesWithPublicIp = false; - $stateDetails = 'stateDetails632437908'; - $peerMtu = 69584721; - $uid = 'uid115792'; - $vmwareEngineNetwork = 'vmwareEngineNetwork-90899684'; - $description = 'description-1724546052'; - $expectedResponse = new NetworkPeering(); - $expectedResponse->setName($name); - $expectedResponse->setPeerNetwork($peerNetwork); - $expectedResponse->setExportCustomRoutes($exportCustomRoutes); - $expectedResponse->setImportCustomRoutes($importCustomRoutes); - $expectedResponse->setExchangeSubnetRoutes($exchangeSubnetRoutes); - $expectedResponse->setExportCustomRoutesWithPublicIp($exportCustomRoutesWithPublicIp); - $expectedResponse->setImportCustomRoutesWithPublicIp($importCustomRoutesWithPublicIp); - $expectedResponse->setStateDetails($stateDetails); - $expectedResponse->setPeerMtu($peerMtu); - $expectedResponse->setUid($uid); - $expectedResponse->setVmwareEngineNetwork($vmwareEngineNetwork); - $expectedResponse->setDescription($description); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateNetworkPeeringTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $networkPeering = new NetworkPeering(); - $networkPeeringPeerNetwork = 'networkPeeringPeerNetwork-385302054'; - $networkPeering->setPeerNetwork($networkPeeringPeerNetwork); - $networkPeeringPeerNetworkType = PeerNetworkType::PEER_NETWORK_TYPE_UNSPECIFIED; - $networkPeering->setPeerNetworkType($networkPeeringPeerNetworkType); - $networkPeeringVmwareEngineNetwork = $gapicClient->vmwareEngineNetworkName('[PROJECT]', '[LOCATION]', '[VMWARE_ENGINE_NETWORK]'); - $networkPeering->setVmwareEngineNetwork($networkPeeringVmwareEngineNetwork); - $updateMask = new FieldMask(); - $request = (new UpdateNetworkPeeringRequest()) - ->setNetworkPeering($networkPeering) - ->setUpdateMask($updateMask); - $response = $gapicClient->updateNetworkPeering($request); - $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.vmwareengine.v1.VmwareEngine/UpdateNetworkPeering', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getNetworkPeering(); - $this->assertProtobufEquals($networkPeering, $actualValue); - $actualValue = $actualApiRequestObject->getUpdateMask(); - $this->assertProtobufEquals($updateMask, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateNetworkPeeringTest'); - $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 updateNetworkPeeringExceptionTest() - { - $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/updateNetworkPeeringTest'); - $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 - $networkPeering = new NetworkPeering(); - $networkPeeringPeerNetwork = 'networkPeeringPeerNetwork-385302054'; - $networkPeering->setPeerNetwork($networkPeeringPeerNetwork); - $networkPeeringPeerNetworkType = PeerNetworkType::PEER_NETWORK_TYPE_UNSPECIFIED; - $networkPeering->setPeerNetworkType($networkPeeringPeerNetworkType); - $networkPeeringVmwareEngineNetwork = $gapicClient->vmwareEngineNetworkName('[PROJECT]', '[LOCATION]', '[VMWARE_ENGINE_NETWORK]'); - $networkPeering->setVmwareEngineNetwork($networkPeeringVmwareEngineNetwork); - $updateMask = new FieldMask(); - $request = (new UpdateNetworkPeeringRequest()) - ->setNetworkPeering($networkPeering) - ->setUpdateMask($updateMask); - $response = $gapicClient->updateNetworkPeering($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateNetworkPeeringTest'); - 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 updateNetworkPolicyTest() - { - $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/updateNetworkPolicyTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $edgeServicesCidr = 'edgeServicesCidr-792872013'; - $uid = 'uid115792'; - $vmwareEngineNetwork = 'vmwareEngineNetwork-90899684'; - $description = 'description-1724546052'; - $vmwareEngineNetworkCanonical = 'vmwareEngineNetworkCanonical779839377'; - $expectedResponse = new NetworkPolicy(); - $expectedResponse->setName($name); - $expectedResponse->setEdgeServicesCidr($edgeServicesCidr); - $expectedResponse->setUid($uid); - $expectedResponse->setVmwareEngineNetwork($vmwareEngineNetwork); - $expectedResponse->setDescription($description); - $expectedResponse->setVmwareEngineNetworkCanonical($vmwareEngineNetworkCanonical); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateNetworkPolicyTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $networkPolicy = new NetworkPolicy(); - $networkPolicyEdgeServicesCidr = 'networkPolicyEdgeServicesCidr-602005393'; - $networkPolicy->setEdgeServicesCidr($networkPolicyEdgeServicesCidr); - $updateMask = new FieldMask(); - $request = (new UpdateNetworkPolicyRequest()) - ->setNetworkPolicy($networkPolicy) - ->setUpdateMask($updateMask); - $response = $gapicClient->updateNetworkPolicy($request); - $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.vmwareengine.v1.VmwareEngine/UpdateNetworkPolicy', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getNetworkPolicy(); - $this->assertProtobufEquals($networkPolicy, $actualValue); - $actualValue = $actualApiRequestObject->getUpdateMask(); - $this->assertProtobufEquals($updateMask, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateNetworkPolicyTest'); - $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 updateNetworkPolicyExceptionTest() - { - $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/updateNetworkPolicyTest'); - $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 - $networkPolicy = new NetworkPolicy(); - $networkPolicyEdgeServicesCidr = 'networkPolicyEdgeServicesCidr-602005393'; - $networkPolicy->setEdgeServicesCidr($networkPolicyEdgeServicesCidr); - $updateMask = new FieldMask(); - $request = (new UpdateNetworkPolicyRequest()) - ->setNetworkPolicy($networkPolicy) - ->setUpdateMask($updateMask); - $response = $gapicClient->updateNetworkPolicy($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateNetworkPolicyTest'); - 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 updatePrivateCloudTest() - { - $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/updatePrivateCloudTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $description = 'description-1724546052'; - $uid = 'uid115792'; - $expectedResponse = new PrivateCloud(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $expectedResponse->setUid($uid); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updatePrivateCloudTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $privateCloud = new PrivateCloud(); - $privateCloudNetworkConfig = new NetworkConfig(); - $networkConfigManagementCidr = 'networkConfigManagementCidr2092091783'; - $privateCloudNetworkConfig->setManagementCidr($networkConfigManagementCidr); - $privateCloud->setNetworkConfig($privateCloudNetworkConfig); - $privateCloudManagementCluster = new ManagementCluster(); - $managementClusterClusterId = 'managementClusterClusterId311493182'; - $privateCloudManagementCluster->setClusterId($managementClusterClusterId); - $nodeTypeConfigsValue = new NodeTypeConfig(); - $valueNodeCount = 1174748740; - $nodeTypeConfigsValue->setNodeCount($valueNodeCount); - $managementClusterNodeTypeConfigs = [ - 'nodeTypeConfigsKey' => $nodeTypeConfigsValue, - ]; - $privateCloudManagementCluster->setNodeTypeConfigs($managementClusterNodeTypeConfigs); - $privateCloud->setManagementCluster($privateCloudManagementCluster); - $updateMask = new FieldMask(); - $request = (new UpdatePrivateCloudRequest()) - ->setPrivateCloud($privateCloud) - ->setUpdateMask($updateMask); - $response = $gapicClient->updatePrivateCloud($request); - $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.vmwareengine.v1.VmwareEngine/UpdatePrivateCloud', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getPrivateCloud(); - $this->assertProtobufEquals($privateCloud, $actualValue); - $actualValue = $actualApiRequestObject->getUpdateMask(); - $this->assertProtobufEquals($updateMask, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updatePrivateCloudTest'); - $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 updatePrivateCloudExceptionTest() - { - $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/updatePrivateCloudTest'); - $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 - $privateCloud = new PrivateCloud(); - $privateCloudNetworkConfig = new NetworkConfig(); - $networkConfigManagementCidr = 'networkConfigManagementCidr2092091783'; - $privateCloudNetworkConfig->setManagementCidr($networkConfigManagementCidr); - $privateCloud->setNetworkConfig($privateCloudNetworkConfig); - $privateCloudManagementCluster = new ManagementCluster(); - $managementClusterClusterId = 'managementClusterClusterId311493182'; - $privateCloudManagementCluster->setClusterId($managementClusterClusterId); - $nodeTypeConfigsValue = new NodeTypeConfig(); - $valueNodeCount = 1174748740; - $nodeTypeConfigsValue->setNodeCount($valueNodeCount); - $managementClusterNodeTypeConfigs = [ - 'nodeTypeConfigsKey' => $nodeTypeConfigsValue, - ]; - $privateCloudManagementCluster->setNodeTypeConfigs($managementClusterNodeTypeConfigs); - $privateCloud->setManagementCluster($privateCloudManagementCluster); - $updateMask = new FieldMask(); - $request = (new UpdatePrivateCloudRequest()) - ->setPrivateCloud($privateCloud) - ->setUpdateMask($updateMask); - $response = $gapicClient->updatePrivateCloud($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updatePrivateCloudTest'); - 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 updatePrivateConnectionTest() - { - $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/updatePrivateConnectionTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $description = 'description-1724546052'; - $vmwareEngineNetwork = 'vmwareEngineNetwork-90899684'; - $vmwareEngineNetworkCanonical = 'vmwareEngineNetworkCanonical779839377'; - $peeringId = 'peeringId-1561749894'; - $uid = 'uid115792'; - $serviceNetwork = 'serviceNetwork1072775844'; - $expectedResponse = new PrivateConnection(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $expectedResponse->setVmwareEngineNetwork($vmwareEngineNetwork); - $expectedResponse->setVmwareEngineNetworkCanonical($vmwareEngineNetworkCanonical); - $expectedResponse->setPeeringId($peeringId); - $expectedResponse->setUid($uid); - $expectedResponse->setServiceNetwork($serviceNetwork); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updatePrivateConnectionTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $privateConnection = new PrivateConnection(); - $privateConnectionVmwareEngineNetwork = $gapicClient->vmwareEngineNetworkName('[PROJECT]', '[LOCATION]', '[VMWARE_ENGINE_NETWORK]'); - $privateConnection->setVmwareEngineNetwork($privateConnectionVmwareEngineNetwork); - $privateConnectionType = Type::TYPE_UNSPECIFIED; - $privateConnection->setType($privateConnectionType); - $privateConnectionServiceNetwork = $gapicClient->networkName('[PROJECT]', '[NETWORK]'); - $privateConnection->setServiceNetwork($privateConnectionServiceNetwork); - $updateMask = new FieldMask(); - $request = (new UpdatePrivateConnectionRequest()) - ->setPrivateConnection($privateConnection) - ->setUpdateMask($updateMask); - $response = $gapicClient->updatePrivateConnection($request); - $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.vmwareengine.v1.VmwareEngine/UpdatePrivateConnection', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getPrivateConnection(); - $this->assertProtobufEquals($privateConnection, $actualValue); - $actualValue = $actualApiRequestObject->getUpdateMask(); - $this->assertProtobufEquals($updateMask, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updatePrivateConnectionTest'); - $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 updatePrivateConnectionExceptionTest() - { - $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/updatePrivateConnectionTest'); - $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 - $privateConnection = new PrivateConnection(); - $privateConnectionVmwareEngineNetwork = $gapicClient->vmwareEngineNetworkName('[PROJECT]', '[LOCATION]', '[VMWARE_ENGINE_NETWORK]'); - $privateConnection->setVmwareEngineNetwork($privateConnectionVmwareEngineNetwork); - $privateConnectionType = Type::TYPE_UNSPECIFIED; - $privateConnection->setType($privateConnectionType); - $privateConnectionServiceNetwork = $gapicClient->networkName('[PROJECT]', '[NETWORK]'); - $privateConnection->setServiceNetwork($privateConnectionServiceNetwork); - $updateMask = new FieldMask(); - $request = (new UpdatePrivateConnectionRequest()) - ->setPrivateConnection($privateConnection) - ->setUpdateMask($updateMask); - $response = $gapicClient->updatePrivateConnection($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updatePrivateConnectionTest'); - 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 updateSubnetTest() - { - $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/updateSubnetTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $ipCidrRange = 'ipCidrRange-2049366326'; - $gatewayIp = 'gatewayIp955798786'; - $type = 'type3575610'; - $vlanId = 536153463; - $expectedResponse = new Subnet(); - $expectedResponse->setName($name); - $expectedResponse->setIpCidrRange($ipCidrRange); - $expectedResponse->setGatewayIp($gatewayIp); - $expectedResponse->setType($type); - $expectedResponse->setVlanId($vlanId); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateSubnetTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $updateMask = new FieldMask(); - $subnet = new Subnet(); - $request = (new UpdateSubnetRequest()) - ->setUpdateMask($updateMask) - ->setSubnet($subnet); - $response = $gapicClient->updateSubnet($request); - $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.vmwareengine.v1.VmwareEngine/UpdateSubnet', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getUpdateMask(); - $this->assertProtobufEquals($updateMask, $actualValue); - $actualValue = $actualApiRequestObject->getSubnet(); - $this->assertProtobufEquals($subnet, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateSubnetTest'); - $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 updateSubnetExceptionTest() - { - $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/updateSubnetTest'); - $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(); - $subnet = new Subnet(); - $request = (new UpdateSubnetRequest()) - ->setUpdateMask($updateMask) - ->setSubnet($subnet); - $response = $gapicClient->updateSubnet($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateSubnetTest'); - 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 updateVmwareEngineNetworkTest() - { - $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/updateVmwareEngineNetworkTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $description = 'description-1724546052'; - $uid = 'uid115792'; - $etag = 'etag3123477'; - $expectedResponse = new VmwareEngineNetwork(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $expectedResponse->setUid($uid); - $expectedResponse->setEtag($etag); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateVmwareEngineNetworkTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $vmwareEngineNetwork = new VmwareEngineNetwork(); - $vmwareEngineNetworkType = \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork\Type::TYPE_UNSPECIFIED; - $vmwareEngineNetwork->setType($vmwareEngineNetworkType); - $updateMask = new FieldMask(); - $request = (new UpdateVmwareEngineNetworkRequest()) - ->setVmwareEngineNetwork($vmwareEngineNetwork) - ->setUpdateMask($updateMask); - $response = $gapicClient->updateVmwareEngineNetwork($request); - $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.vmwareengine.v1.VmwareEngine/UpdateVmwareEngineNetwork', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getVmwareEngineNetwork(); - $this->assertProtobufEquals($vmwareEngineNetwork, $actualValue); - $actualValue = $actualApiRequestObject->getUpdateMask(); - $this->assertProtobufEquals($updateMask, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateVmwareEngineNetworkTest'); - $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 updateVmwareEngineNetworkExceptionTest() - { - $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/updateVmwareEngineNetworkTest'); - $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 - $vmwareEngineNetwork = new VmwareEngineNetwork(); - $vmwareEngineNetworkType = \Google\Cloud\VmwareEngine\V1\VmwareEngineNetwork\Type::TYPE_UNSPECIFIED; - $vmwareEngineNetwork->setType($vmwareEngineNetworkType); - $updateMask = new FieldMask(); - $request = (new UpdateVmwareEngineNetworkRequest()) - ->setVmwareEngineNetwork($vmwareEngineNetwork) - ->setUpdateMask($updateMask); - $response = $gapicClient->updateVmwareEngineNetwork($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateVmwareEngineNetworkTest'); - 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); - $request = new GetLocationRequest(); - $response = $gapicClient->getLocation($request); - $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); - $request = new GetLocationRequest(); - try { - $gapicClient->getLocation($request); - // 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); - $request = new ListLocationsRequest(); - $response = $gapicClient->listLocations($request); - $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); - $request = new ListLocationsRequest(); - try { - $gapicClient->listLocations($request); - // 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'; - $request = (new GetIamPolicyRequest()) - ->setResource($resource); - $response = $gapicClient->getIamPolicy($request); - $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'; - $request = (new GetIamPolicyRequest()) - ->setResource($resource); - try { - $gapicClient->getIamPolicy($request); - // 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(); - $request = (new SetIamPolicyRequest()) - ->setResource($resource) - ->setPolicy($policy); - $response = $gapicClient->setIamPolicy($request); - $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(); - $request = (new SetIamPolicyRequest()) - ->setResource($resource) - ->setPolicy($policy); - try { - $gapicClient->setIamPolicy($request); - // 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 = []; - $request = (new TestIamPermissionsRequest()) - ->setResource($resource) - ->setPermissions($permissions); - $response = $gapicClient->testIamPermissions($request); - $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 = []; - $request = (new TestIamPermissionsRequest()) - ->setResource($resource) - ->setPermissions($permissions); - try { - $gapicClient->testIamPermissions($request); - // 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 createClusterAsyncTest() - { - $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/createClusterTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $management = false; - $uid = 'uid115792'; - $expectedResponse = new Cluster(); - $expectedResponse->setName($name); - $expectedResponse->setManagement($management); - $expectedResponse->setUid($uid); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createClusterTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->privateCloudName('[PROJECT]', '[LOCATION]', '[PRIVATE_CLOUD]'); - $clusterId = 'clusterId240280960'; - $cluster = new Cluster(); - $nodeTypeConfigsValue = new NodeTypeConfig(); - $valueNodeCount = 1174748740; - $nodeTypeConfigsValue->setNodeCount($valueNodeCount); - $clusterNodeTypeConfigs = [ - 'nodeTypeConfigsKey' => $nodeTypeConfigsValue, - ]; - $cluster->setNodeTypeConfigs($clusterNodeTypeConfigs); - $request = (new CreateClusterRequest()) - ->setParent($formattedParent) - ->setClusterId($clusterId) - ->setCluster($cluster); - $response = $gapicClient->createClusterAsync($request)->wait(); - $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.vmwareengine.v1.VmwareEngine/CreateCluster', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getClusterId(); - $this->assertProtobufEquals($clusterId, $actualValue); - $actualValue = $actualApiRequestObject->getCluster(); - $this->assertProtobufEquals($cluster, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createClusterTest'); - $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()); - } -} diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/GPBMetadata/Google/Cloud/Workloadmanager/V1/Service.php b/owl-bot-staging/WorkloadManager/v1/proto/src/GPBMetadata/Google/Cloud/Workloadmanager/V1/Service.php deleted file mode 100644 index d48b9b6684bd..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/GPBMetadata/Google/Cloud/Workloadmanager/V1/Service.php +++ /dev/null @@ -1,32 +0,0 @@ -internalAddGeneratedFile( - "\x0A\x9CZ\x0A-google/cloud/workloadmanager/v1/service.proto\x12\x1Fgoogle.cloud.workloadmanager.v1\x1A\x17google/api/client.proto\x1A\x1Fgoogle/api/field_behavior.proto\x1A\x19google/api/resource.proto\x1A#google/longrunning/operations.proto\x1A\x1Bgoogle/protobuf/empty.proto\x1A google/protobuf/field_mask.proto\x1A\x1Fgoogle/protobuf/timestamp.proto\"\xD0\x07\x0A\x0AEvaluation\x12\x0C\x0A\x04name\x18\x01 \x01(\x09\x12\x13\x0A\x0Bdescription\x18\x02 \x01(\x09\x12H\x0A\x0Fresource_filter\x18\x03 \x01(\x0B2/.google.cloud.workloadmanager.v1.ResourceFilter\x12\x12\x0A\x0Arule_names\x18\x04 \x03(\x09\x12M\x0A\x0Fresource_status\x18\x06 \x01(\x0B2/.google.cloud.workloadmanager.v1.ResourceStatusB\x03\xE0A\x03\x124\x0A\x0Bcreate_time\x18\x07 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bupdate_time\x18\x08 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12G\x0A\x06labels\x18\x09 \x03(\x0B27.google.cloud.workloadmanager.v1.Evaluation.LabelsEntry\x12\x15\x0A\x08schedule\x18\x0A \x01(\x09H\x00\x88\x01\x01\x12\x1B\x0A\x13custom_rules_bucket\x18\x0B \x01(\x09\x12S\x0A\x0Fevaluation_type\x18\x0C \x01(\x0E2:.google.cloud.workloadmanager.v1.Evaluation.EvaluationType\x12X\x0A\x15big_query_destination\x18\x0D \x01(\x0B24.google.cloud.workloadmanager.v1.BigQueryDestinationB\x03\xE0A\x01\x12:\x0A\x07kms_key\x18\x0F \x01(\x09B)\xE0A\x05\xFAA#\x0A!cloudkms.googleapis.com/CryptoKey\x1A-\x0A\x0BLabelsEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12\x0D\x0A\x05value\x18\x02 \x01(\x09:\x028\x01\"U\x0A\x0EEvaluationType\x12\x1F\x0A\x1BEVALUATION_TYPE_UNSPECIFIED\x10\x00\x12\x07\x0A\x03SAP\x10\x01\x12\x0E\x0A\x0ASQL_SERVER\x10\x02\x12\x09\x0A\x05OTHER\x10\x03:\x8A\x01\xEAA\x86\x01\x0A)workloadmanager.googleapis.com/Evaluation\x12@projects/{project}/locations/{location}/evaluations/{evaluation}*\x0Bevaluations2\x0AevaluationB\x0B\x0A\x09_schedule\"\xA7\x02\x0A\x0EResourceFilter\x12\x0E\x0A\x06scopes\x18\x01 \x03(\x09\x12\x1C\x0A\x14resource_id_patterns\x18\x02 \x03(\x09\x12^\x0A\x10inclusion_labels\x18\x03 \x03(\x0B2D.google.cloud.workloadmanager.v1.ResourceFilter.InclusionLabelsEntry\x12O\x0A\x13gce_instance_filter\x18\x04 \x01(\x0B22.google.cloud.workloadmanager.v1.GceInstanceFilter\x1A6\x0A\x14InclusionLabelsEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12\x0D\x0A\x05value\x18\x02 \x01(\x09:\x028\x01\"-\x0A\x11GceInstanceFilter\x12\x18\x0A\x10service_accounts\x18\x04 \x03(\x09\"\x9E\x01\x0A\x0EResourceStatus\x12D\x0A\x05state\x18\x02 \x01(\x0E25.google.cloud.workloadmanager.v1.ResourceStatus.State\"F\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x0C\x0A\x08CREATING\x10\x01\x12\x0A\x0A\x06ACTIVE\x10\x02\x12\x0C\x0A\x08DELETING\x10\x03\"^\x0A\x13BigQueryDestination\x12 \x0A\x13destination_dataset\x18\x01 \x01(\x09B\x03\xE0A\x01\x12%\x0A\x18create_new_results_table\x18\x02 \x01(\x08B\x03\xE0A\x01\"\xA4\x01\x0A\x16ListEvaluationsRequest\x12A\x0A\x06parent\x18\x01 \x01(\x09B1\xE0A\x02\xFAA+\x12)workloadmanager.googleapis.com/Evaluation\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\x12\x0E\x0A\x06filter\x18\x04 \x01(\x09\x12\x10\x0A\x08order_by\x18\x05 \x01(\x09\"\x89\x01\x0A\x17ListEvaluationsResponse\x12@\x0A\x0Bevaluations\x18\x01 \x03(\x0B2+.google.cloud.workloadmanager.v1.Evaluation\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\x12\x13\x0A\x0Bunreachable\x18\x03 \x03(\x09\"W\x0A\x14GetEvaluationRequest\x12?\x0A\x04name\x18\x01 \x01(\x09B1\xE0A\x02\xFAA+\x0A)workloadmanager.googleapis.com/Evaluation\"\xD7\x01\x0A\x17CreateEvaluationRequest\x12A\x0A\x06parent\x18\x01 \x01(\x09B1\xE0A\x02\xFAA+\x12)workloadmanager.googleapis.com/Evaluation\x12\x1A\x0A\x0Devaluation_id\x18\x02 \x01(\x09B\x03\xE0A\x02\x12D\x0A\x0Aevaluation\x18\x03 \x01(\x0B2+.google.cloud.workloadmanager.v1.EvaluationB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x04 \x01(\x09B\x03\xE0A\x01\"\xAE\x01\x0A\x17UpdateEvaluationRequest\x124\x0A\x0Bupdate_mask\x18\x01 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x02\x12D\x0A\x0Aevaluation\x18\x02 \x01(\x0B2+.google.cloud.workloadmanager.v1.EvaluationB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x03 \x01(\x09B\x03\xE0A\x01\"\x87\x01\x0A\x17DeleteEvaluationRequest\x12?\x0A\x04name\x18\x01 \x01(\x09B1\xE0A\x02\xFAA+\x0A)workloadmanager.googleapis.com/Evaluation\x12\x17\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x03\xE0A\x01\x12\x12\x0A\x05force\x18\x03 \x01(\x08B\x03\xE0A\x01\"\xA5\x0C\x0A\x09Execution\x12\x0C\x0A\x04name\x18\x01 \x01(\x09\x123\x0A\x0Astart_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x121\x0A\x08end_time\x18\x03 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x127\x0A\x0Einventory_time\x18\x04 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12D\x0A\x05state\x18\x05 \x01(\x0E20.google.cloud.workloadmanager.v1.Execution.StateB\x03\xE0A\x03\x12\x1A\x0A\x0Devaluation_id\x18\x06 \x01(\x09B\x03\xE0A\x03\x12F\x0A\x06labels\x18\x07 \x03(\x0B26.google.cloud.workloadmanager.v1.Execution.LabelsEntry\x12A\x0A\x08run_type\x18\x08 \x01(\x0E2/.google.cloud.workloadmanager.v1.Execution.Type\x12O\x0A\x0Crule_results\x18\x09 \x03(\x0B24.google.cloud.workloadmanager.v1.RuleExecutionResultB\x03\xE0A\x03\x12b\x0A\x15external_data_sources\x18\x0A \x03(\x0B2>.google.cloud.workloadmanager.v1.Execution.ExternalDataSourcesB\x03\xE0A\x01\x12G\x0A\x07notices\x18\x0B \x03(\x0B21.google.cloud.workloadmanager.v1.Execution.NoticeB\x03\xE0A\x03\x12F\x0A\x06engine\x18\x0C \x01(\x0E21.google.cloud.workloadmanager.v1.Execution.EngineB\x03\xE0A\x01\x12O\x0A\x0Eresult_summary\x18\x0D \x01(\x0B22.google.cloud.workloadmanager.v1.Execution.SummaryB\x03\xE0A\x03\x1A\xDE\x01\x0A\x13ExternalDataSources\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x01\x12\x10\x0A\x03uri\x18\x02 \x01(\x09B\x03\xE0A\x02\x12V\x0A\x04type\x18\x03 \x01(\x0E2C.google.cloud.workloadmanager.v1.Execution.ExternalDataSources.TypeB\x03\xE0A\x02\x12\x17\x0A\x0Aasset_type\x18\x04 \x01(\x09B\x03\xE0A\x02\"1\x0A\x04Type\x12\x14\x0A\x10TYPE_UNSPECIFIED\x10\x00\x12\x13\x0A\x0FBIG_QUERY_TABLE\x10\x01\x1A\x1E\x0A\x06Notice\x12\x14\x0A\x07message\x18\x01 \x01(\x09B\x03\xE0A\x03\x1AS\x0A\x07Summary\x12\x15\x0A\x08failures\x18\x01 \x01(\x03B\x03\xE0A\x03\x12\x19\x0A\x0Cnew_failures\x18\x02 \x01(\x03B\x03\xE0A\x03\x12\x16\x0A\x09new_fixes\x18\x03 \x01(\x03B\x03\xE0A\x03\x1A-\x0A\x0BLabelsEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12\x0D\x0A\x05value\x18\x02 \x01(\x09:\x028\x01\"F\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x0B\x0A\x07RUNNING\x10\x01\x12\x0D\x0A\x09SUCCEEDED\x10\x02\x12\x0A\x0A\x06FAILED\x10\x03\"9\x0A\x04Type\x12\x14\x0A\x10TYPE_UNSPECIFIED\x10\x00\x12\x0C\x0A\x08ONE_TIME\x10\x01\x12\x0D\x0A\x09SCHEDULED\x10\x02\"<\x0A\x06Engine\x12\x16\x0A\x12ENGINE_UNSPECIFIED\x10\x00\x12\x12\x0A\x0EENGINE_SCANNER\x10\x01\x12\x06\x0A\x02V2\x10\x02:\x9E\x01\xEAA\x9A\x01\x0A(workloadmanager.googleapis.com/Execution\x12Wprojects/{project}/locations/{location}/evaluations/{evaluation}/executions/{execution}*\x0Aexecutions2\x09execution\"\x93\x02\x0A\x13RuleExecutionResult\x12\x0C\x0A\x04rule\x18\x01 \x01(\x09\x12N\x0A\x05state\x18\x02 \x01(\x0E2:.google.cloud.workloadmanager.v1.RuleExecutionResult.StateB\x03\xE0A\x03\x12\x0F\x0A\x07message\x18\x03 \x01(\x09\x12\x14\x0A\x0Cresult_count\x18\x04 \x01(\x03\x12\x1E\x0A\x16scanned_resource_count\x18\x05 \x01(\x03\"W\x0A\x05State\x12\x15\x0A\x11STATE_UNSPECIFIED\x10\x00\x12\x11\x0A\x0DSTATE_SUCCESS\x10\x01\x12\x11\x0A\x0DSTATE_FAILURE\x10\x02\x12\x11\x0A\x0DSTATE_SKIPPED\x10\x03\"\xA2\x01\x0A\x15ListExecutionsRequest\x12@\x0A\x06parent\x18\x01 \x01(\x09B0\xE0A\x02\xFAA*\x12(workloadmanager.googleapis.com/Execution\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\x12\x0E\x0A\x06filter\x18\x04 \x01(\x09\x12\x10\x0A\x08order_by\x18\x05 \x01(\x09\"\x86\x01\x0A\x16ListExecutionsResponse\x12>\x0A\x0Aexecutions\x18\x01 \x03(\x0B2*.google.cloud.workloadmanager.v1.Execution\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\x12\x13\x0A\x0Bunreachable\x18\x03 \x03(\x09\"U\x0A\x13GetExecutionRequest\x12>\x0A\x04name\x18\x01 \x01(\x09B0\xE0A\x02\xFAA*\x0A(workloadmanager.googleapis.com/Execution\"\xCF\x01\x0A\x14RunEvaluationRequest\x12?\x0A\x04name\x18\x01 \x01(\x09B1\xE0A\x02\xFAA+\x0A)workloadmanager.googleapis.com/Evaluation\x12\x19\x0A\x0Cexecution_id\x18\x02 \x01(\x09B\x03\xE0A\x02\x12B\x0A\x09execution\x18\x03 \x01(\x0B2*.google.cloud.workloadmanager.v1.ExecutionB\x03\xE0A\x02\x12\x17\x0A\x0Arequest_id\x18\x04 \x01(\x09B\x03\xE0A\x01\"q\x0A\x16DeleteExecutionRequest\x12>\x0A\x04name\x18\x01 \x01(\x09B0\xE0A\x02\xFAA*\x0A(workloadmanager.googleapis.com/Execution\x12\x17\x0A\x0Arequest_id\x18\x02 \x01(\x09B\x03\xE0A\x01\"i\x0A\x1BListExecutionResultsRequest\x12\x13\x0A\x06parent\x18\x01 \x01(\x09B\x03\xE0A\x02\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\x12\x0E\x0A\x06filter\x18\x04 \x01(\x09\"\x84\x01\x0A\x1CListExecutionResultsResponse\x12K\x0A\x11execution_results\x18\x01 \x03(\x0B20.google.cloud.workloadmanager.v1.ExecutionResult\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\"\xDF\x03\x0A\x0FExecutionResult\x12\x19\x0A\x11violation_message\x18\x01 \x01(\x09\x12\x10\x0A\x08severity\x18\x02 \x01(\x09\x126\x0A\x04rule\x18\x03 \x01(\x09B(\xFAA%\x0A#workloadmanager.googleapis.com/Rule\x12\x19\x0A\x11documentation_url\x18\x04 \x01(\x09\x12;\x0A\x08resource\x18\x05 \x01(\x0B2).google.cloud.workloadmanager.v1.Resource\x12L\x0A\x11violation_details\x18\x06 \x01(\x0B21.google.cloud.workloadmanager.v1.ViolationDetails\x12:\x0A\x08commands\x18\x07 \x03(\x0B2(.google.cloud.workloadmanager.v1.Command\x12C\x0A\x04type\x18\x08 \x01(\x0E25.google.cloud.workloadmanager.v1.ExecutionResult.Type\"@\x0A\x04Type\x12\x14\x0A\x10TYPE_UNSPECIFIED\x10\x00\x12\x0F\x0A\x0BTYPE_PASSED\x10\x01\x12\x11\x0A\x0DTYPE_VIOLATED\x10\x02\"\xA9\x01\x0A\x07Command\x12F\x0A\x0Dagent_command\x18\x01 \x01(\x0B2-.google.cloud.workloadmanager.v1.AgentCommandH\x00\x12F\x0A\x0Dshell_command\x18\x02 \x01(\x0B2-.google.cloud.workloadmanager.v1.ShellCommandH\x00B\x0E\x0A\x0Ccommand_type\"\xA5\x01\x0A\x0CAgentCommand\x12\x0F\x0A\x07command\x18\x01 \x01(\x09\x12Q\x0A\x0Aparameters\x18\x02 \x03(\x0B2=.google.cloud.workloadmanager.v1.AgentCommand.ParametersEntry\x1A1\x0A\x0FParametersEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12\x0D\x0A\x05value\x18\x02 \x01(\x09:\x028\x01\"F\x0A\x0CShellCommand\x12\x0F\x0A\x07command\x18\x01 \x01(\x09\x12\x0C\x0A\x04args\x18\x02 \x01(\x09\x12\x17\x0A\x0Ftimeout_seconds\x18\x03 \x01(\x05\"\xA2\x01\x0A\x0ARuleOutput\x12N\x0A\x07details\x18\x01 \x03(\x0B28.google.cloud.workloadmanager.v1.RuleOutput.DetailsEntryB\x03\xE0A\x03\x12\x14\x0A\x07message\x18\x02 \x01(\x09B\x03\xE0A\x03\x1A.\x0A\x0CDetailsEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12\x0D\x0A\x05value\x18\x02 \x01(\x09:\x028\x01\"\x85\x02\x0A\x10ViolationDetails\x12\x0D\x0A\x05asset\x18\x01 \x01(\x09\x12\x17\x0A\x0Fservice_account\x18\x02 \x01(\x09\x12Q\x0A\x08observed\x18\x03 \x03(\x0B2?.google.cloud.workloadmanager.v1.ViolationDetails.ObservedEntry\x12E\x0A\x0Brule_output\x18\x04 \x03(\x0B2+.google.cloud.workloadmanager.v1.RuleOutputB\x03\xE0A\x03\x1A/\x0A\x0DObservedEntry\x12\x0B\x0A\x03key\x18\x01 \x01(\x09\x12\x0D\x0A\x05value\x18\x02 \x01(\x09:\x028\x01\"?\x0A\x08Resource\x12\x0C\x0A\x04type\x18\x01 \x01(\x09\x12\x0C\x0A\x04name\x18\x02 \x01(\x09\x12\x17\x0A\x0Fservice_account\x18\x03 \x01(\x09\"\x80\x02\x0A\x11OperationMetadata\x124\x0A\x0Bcreate_time\x18\x01 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x121\x0A\x08end_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12\x13\x0A\x06target\x18\x03 \x01(\x09B\x03\xE0A\x03\x12\x11\x0A\x04verb\x18\x04 \x01(\x09B\x03\xE0A\x03\x12\x1B\x0A\x0Estatus_message\x18\x05 \x01(\x09B\x03\xE0A\x03\x12#\x0A\x16requested_cancellation\x18\x06 \x01(\x08B\x03\xE0A\x03\x12\x18\x0A\x0Bapi_version\x18\x07 \x01(\x09B\x03\xE0A\x03\"\xED\x03\x0A\x04Rule\x12\x0C\x0A\x04name\x18\x01 \x01(\x09\x12\x18\x0A\x0Brevision_id\x18\x02 \x01(\x09B\x03\xE0A\x03\x12\x14\x0A\x0Cdisplay_name\x18\x03 \x01(\x09\x12\x13\x0A\x0Bdescription\x18\x04 \x01(\x09\x12\x10\x0A\x08severity\x18\x05 \x01(\x09\x12\x18\x0A\x10primary_category\x18\x06 \x01(\x09\x12\x1A\x0A\x12secondary_category\x18\x07 \x01(\x09\x12\x15\x0A\x0Derror_message\x18\x08 \x01(\x09\x12\x0B\x0A\x03uri\x18\x09 \x01(\x09\x12\x13\x0A\x0Bremediation\x18\x0A \x01(\x09\x12\x0C\x0A\x04tags\x18\x0B \x03(\x09\x12A\x0A\x09rule_type\x18\x0C \x01(\x0E2..google.cloud.workloadmanager.v1.Rule.RuleType\x12\x12\x0A\x0Aasset_type\x18\x0D \x01(\x09\"?\x0A\x08RuleType\x12\x19\x0A\x15RULE_TYPE_UNSPECIFIED\x10\x00\x12\x0C\x0A\x08BASELINE\x10\x01\x12\x0A\x0A\x06CUSTOM\x10\x02:k\xEAAh\x0A#workloadmanager.googleapis.com/Rule\x124projects/{project}/locations/{location}/rules/{rule}*\x05rules2\x04rule\"\xFD\x01\x0A\x10ListRulesRequest\x12;\x0A\x06parent\x18\x01 \x01(\x09B+\xE0A\x02\xFAA%\x12#workloadmanager.googleapis.com/Rule\x12\x11\x0A\x09page_size\x18\x02 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x03 \x01(\x09\x12\x0E\x0A\x06filter\x18\x04 \x01(\x09\x12\x1B\x0A\x13custom_rules_bucket\x18\x05 \x01(\x09\x12X\x0A\x0Fevaluation_type\x18\x06 \x01(\x0E2:.google.cloud.workloadmanager.v1.Evaluation.EvaluationTypeB\x03\xE0A\x01\"I\x0A\x11ListRulesResponse\x124\x0A\x05rules\x18\x01 \x03(\x0B2%.google.cloud.workloadmanager.v1.Rule\"\x89\x01\x0A\x1BListScannedResourcesRequest\x12\x13\x0A\x06parent\x18\x01 \x01(\x09B\x03\xE0A\x02\x12\x0C\x0A\x04rule\x18\x02 \x01(\x09\x12\x11\x0A\x09page_size\x18\x03 \x01(\x05\x12\x12\x0A\x0Apage_token\x18\x04 \x01(\x09\x12\x0E\x0A\x06filter\x18\x05 \x01(\x09\x12\x10\x0A\x08order_by\x18\x06 \x01(\x09\"\x84\x01\x0A\x1CListScannedResourcesResponse\x12K\x0A\x11scanned_resources\x18\x01 \x03(\x0B20.google.cloud.workloadmanager.v1.ScannedResource\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\"1\x0A\x0FScannedResource\x12\x10\x0A\x08resource\x18\x01 \x01(\x09\x12\x0C\x0A\x04type\x18\x02 \x01(\x092\xB5\x15\x0A\x0FWorkloadManager\x12\xC6\x01\x0A\x0FListEvaluations\x127.google.cloud.workloadmanager.v1.ListEvaluationsRequest\x1A8.google.cloud.workloadmanager.v1.ListEvaluationsResponse\"@\xDAA\x06parent\x82\xD3\xE4\x93\x021\x12//v1/{parent=projects/*/locations/*}/evaluations\x12\xB3\x01\x0A\x0DGetEvaluation\x125.google.cloud.workloadmanager.v1.GetEvaluationRequest\x1A+.google.cloud.workloadmanager.v1.Evaluation\">\xDAA\x04name\x82\xD3\xE4\x93\x021\x12//v1/{name=projects/*/locations/*/evaluations/*}\x12\xF5\x01\x0A\x10CreateEvaluation\x128.google.cloud.workloadmanager.v1.CreateEvaluationRequest\x1A\x1D.google.longrunning.Operation\"\x87\x01\xCAA\x1F\x0A\x0AEvaluation\x12\x11OperationMetadata\xDAA\x1Fparent,evaluation,evaluation_id\x82\xD3\xE4\x93\x02=\"//v1/{parent=projects/*/locations/*}/evaluations:\x0Aevaluation\x12\xF7\x01\x0A\x10UpdateEvaluation\x128.google.cloud.workloadmanager.v1.UpdateEvaluationRequest\x1A\x1D.google.longrunning.Operation\"\x89\x01\xCAA\x1F\x0A\x0AEvaluation\x12\x11OperationMetadata\xDAA\x16evaluation,update_mask\x82\xD3\xE4\x93\x02H2:/v1/{evaluation.name=projects/*/locations/*/evaluations/*}:\x0Aevaluation\x12\xD8\x01\x0A\x10DeleteEvaluation\x128.google.cloud.workloadmanager.v1.DeleteEvaluationRequest\x1A\x1D.google.longrunning.Operation\"k\xCAA*\x0A\x15google.protobuf.Empty\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x021*//v1/{name=projects/*/locations/*/evaluations/*}\x12\xD0\x01\x0A\x0EListExecutions\x126.google.cloud.workloadmanager.v1.ListExecutionsRequest\x1A7.google.cloud.workloadmanager.v1.ListExecutionsResponse\"M\xDAA\x06parent\x82\xD3\xE4\x93\x02>\x12\x12/v1/{name=projects/*/locations/*/evaluations/*}/executions:run:\x01*\x12\xE3\x01\x0A\x0FDeleteExecution\x127.google.cloud.workloadmanager.v1.DeleteExecutionRequest\x1A\x1D.google.longrunning.Operation\"x\xCAA*\x0A\x15google.protobuf.Empty\x12\x11OperationMetadata\xDAA\x04name\x82\xD3\xE4\x93\x02>*google.cloud.workloadmanager.v1.AgentCommand - */ -class AgentCommand extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the agent one-time executable that will be invoked. - * - * Generated from protobuf field string command = 1; - */ - protected $command = ''; - /** - * A map of key/value pairs that can be used to specify - * additional one-time executable settings. - * - * Generated from protobuf field map parameters = 2; - */ - private $parameters; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $command - * The name of the agent one-time executable that will be invoked. - * @type array|\Google\Protobuf\Internal\MapField $parameters - * A map of key/value pairs that can be used to specify - * additional one-time executable settings. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * The name of the agent one-time executable that will be invoked. - * - * Generated from protobuf field string command = 1; - * @return string - */ - public function getCommand() - { - return $this->command; - } - - /** - * The name of the agent one-time executable that will be invoked. - * - * Generated from protobuf field string command = 1; - * @param string $var - * @return $this - */ - public function setCommand($var) - { - GPBUtil::checkString($var, True); - $this->command = $var; - - return $this; - } - - /** - * A map of key/value pairs that can be used to specify - * additional one-time executable settings. - * - * Generated from protobuf field map parameters = 2; - * @return \Google\Protobuf\Internal\MapField - */ - public function getParameters() - { - return $this->parameters; - } - - /** - * A map of key/value pairs that can be used to specify - * additional one-time executable settings. - * - * Generated from protobuf field map parameters = 2; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setParameters($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->parameters = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/BigQueryDestination.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/BigQueryDestination.php deleted file mode 100644 index 0fb323100ffb..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/BigQueryDestination.php +++ /dev/null @@ -1,105 +0,0 @@ -google.cloud.workloadmanager.v1.BigQueryDestination - */ -class BigQueryDestination extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. Destination dataset to save evaluation results. - * - * Generated from protobuf field string destination_dataset = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $destination_dataset = ''; - /** - * Optional. Determines if a new results table will be created when an - * Execution is created. - * - * Generated from protobuf field bool create_new_results_table = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $create_new_results_table = false; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $destination_dataset - * Optional. Destination dataset to save evaluation results. - * @type bool $create_new_results_table - * Optional. Determines if a new results table will be created when an - * Execution is created. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Optional. Destination dataset to save evaluation results. - * - * Generated from protobuf field string destination_dataset = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getDestinationDataset() - { - return $this->destination_dataset; - } - - /** - * Optional. Destination dataset to save evaluation results. - * - * Generated from protobuf field string destination_dataset = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @param string $var - * @return $this - */ - public function setDestinationDataset($var) - { - GPBUtil::checkString($var, True); - $this->destination_dataset = $var; - - return $this; - } - - /** - * Optional. Determines if a new results table will be created when an - * Execution is created. - * - * Generated from protobuf field bool create_new_results_table = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getCreateNewResultsTable() - { - return $this->create_new_results_table; - } - - /** - * Optional. Determines if a new results table will be created when an - * Execution is created. - * - * Generated from protobuf field bool create_new_results_table = 2 [(.google.api.field_behavior) = OPTIONAL]; - * @param bool $var - * @return $this - */ - public function setCreateNewResultsTable($var) - { - GPBUtil::checkBool($var); - $this->create_new_results_table = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Command.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Command.php deleted file mode 100644 index a50557e163fb..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Command.php +++ /dev/null @@ -1,111 +0,0 @@ -google.cloud.workloadmanager.v1.Command - */ -class Command extends \Google\Protobuf\Internal\Message -{ - protected $command_type; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\WorkloadManager\V1\AgentCommand $agent_command - * AgentCommand specifies a one-time executable program for the agent to - * run. - * @type \Google\Cloud\WorkloadManager\V1\ShellCommand $shell_command - * ShellCommand is invoked via the agent's command line executor. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * AgentCommand specifies a one-time executable program for the agent to - * run. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.AgentCommand agent_command = 1; - * @return \Google\Cloud\WorkloadManager\V1\AgentCommand|null - */ - public function getAgentCommand() - { - return $this->readOneof(1); - } - - public function hasAgentCommand() - { - return $this->hasOneof(1); - } - - /** - * AgentCommand specifies a one-time executable program for the agent to - * run. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.AgentCommand agent_command = 1; - * @param \Google\Cloud\WorkloadManager\V1\AgentCommand $var - * @return $this - */ - public function setAgentCommand($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\WorkloadManager\V1\AgentCommand::class); - $this->writeOneof(1, $var); - - return $this; - } - - /** - * ShellCommand is invoked via the agent's command line executor. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.ShellCommand shell_command = 2; - * @return \Google\Cloud\WorkloadManager\V1\ShellCommand|null - */ - public function getShellCommand() - { - return $this->readOneof(2); - } - - public function hasShellCommand() - { - return $this->hasOneof(2); - } - - /** - * ShellCommand is invoked via the agent's command line executor. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.ShellCommand shell_command = 2; - * @param \Google\Cloud\WorkloadManager\V1\ShellCommand $var - * @return $this - */ - public function setShellCommand($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\WorkloadManager\V1\ShellCommand::class); - $this->writeOneof(2, $var); - - return $this; - } - - /** - * @return string - */ - public function getCommandType() - { - return $this->whichOneof("command_type"); - } - -} - diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/CreateEvaluationRequest.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/CreateEvaluationRequest.php deleted file mode 100644 index 885e93c8e5b0..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/CreateEvaluationRequest.php +++ /dev/null @@ -1,242 +0,0 @@ -google.cloud.workloadmanager.v1.CreateEvaluationRequest - */ -class CreateEvaluationRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource prefix of the evaluation 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. Id of the requesting object. - * - * Generated from protobuf field string evaluation_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $evaluation_id = ''; - /** - * Required. The resource being created. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.Evaluation evaluation = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $evaluation = 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 resource prefix of the evaluation location using the form: - * `projects/{project_id}/locations/{location_id}`. Please see - * {@see WorkloadManagerClient::locationName()} for help formatting this field. - * @param \Google\Cloud\WorkloadManager\V1\Evaluation $evaluation Required. The resource being created. - * @param string $evaluationId Required. Id of the requesting object. - * - * @return \Google\Cloud\WorkloadManager\V1\CreateEvaluationRequest - * - * @experimental - */ - public static function build(string $parent, \Google\Cloud\WorkloadManager\V1\Evaluation $evaluation, string $evaluationId): self - { - return (new self()) - ->setParent($parent) - ->setEvaluation($evaluation) - ->setEvaluationId($evaluationId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $parent - * Required. The resource prefix of the evaluation location using the form: - * `projects/{project_id}/locations/{location_id}`. - * @type string $evaluation_id - * Required. Id of the requesting object. - * @type \Google\Cloud\WorkloadManager\V1\Evaluation $evaluation - * 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 - * 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\Workloadmanager\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource prefix of the evaluation 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 prefix of the evaluation 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. Id of the requesting object. - * - * Generated from protobuf field string evaluation_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getEvaluationId() - { - return $this->evaluation_id; - } - - /** - * Required. Id of the requesting object. - * - * Generated from protobuf field string evaluation_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setEvaluationId($var) - { - GPBUtil::checkString($var, True); - $this->evaluation_id = $var; - - return $this; - } - - /** - * Required. The resource being created. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.Evaluation evaluation = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\WorkloadManager\V1\Evaluation|null - */ - public function getEvaluation() - { - return $this->evaluation; - } - - public function hasEvaluation() - { - return isset($this->evaluation); - } - - public function clearEvaluation() - { - unset($this->evaluation); - } - - /** - * Required. The resource being created. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.Evaluation evaluation = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\WorkloadManager\V1\Evaluation $var - * @return $this - */ - public function setEvaluation($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\WorkloadManager\V1\Evaluation::class); - $this->evaluation = $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/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/DeleteEvaluationRequest.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/DeleteEvaluationRequest.php deleted file mode 100644 index 682f6569f1c4..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/DeleteEvaluationRequest.php +++ /dev/null @@ -1,193 +0,0 @@ -google.cloud.workloadmanager.v1.DeleteEvaluationRequest - */ -class DeleteEvaluationRequest 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 - * 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 = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $request_id = ''; - /** - * Optional. Followed the best practice from - * https://aip.dev/135#cascading-delete. - * - * Generated from protobuf field bool force = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $force = false; - - /** - * @param string $name Required. Name of the resource. Please see - * {@see WorkloadManagerClient::evaluationName()} for help formatting this field. - * - * @return \Google\Cloud\WorkloadManager\V1\DeleteEvaluationRequest - * - * @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 - * 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 bool $force - * Optional. Followed the best practice from - * https://aip.dev/135#cascading-delete. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::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 - * 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 = 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 - * 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 = 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. Followed the best practice from - * https://aip.dev/135#cascading-delete. - * - * Generated from protobuf field bool force = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @return bool - */ - public function getForce() - { - return $this->force; - } - - /** - * Optional. Followed the best practice from - * https://aip.dev/135#cascading-delete. - * - * Generated from protobuf field bool force = 3 [(.google.api.field_behavior) = OPTIONAL]; - * @param bool $var - * @return $this - */ - public function setForce($var) - { - GPBUtil::checkBool($var); - $this->force = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/DeleteExecutionRequest.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/DeleteExecutionRequest.php deleted file mode 100644 index 3f317ed1d3f6..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/DeleteExecutionRequest.php +++ /dev/null @@ -1,155 +0,0 @@ -google.cloud.workloadmanager.v1.DeleteExecutionRequest - */ -class DeleteExecutionRequest 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 - * 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 = 2 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $request_id = ''; - - /** - * @param string $name Required. Name of the resource. Please see - * {@see WorkloadManagerClient::executionName()} for help formatting this field. - * - * @return \Google\Cloud\WorkloadManager\V1\DeleteExecutionRequest - * - * @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 - * 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\Workloadmanager\V1\Service::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 - * 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 = 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 - * 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 = 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; - } - -} - diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Evaluation.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Evaluation.php deleted file mode 100644 index aa4cd8a7ef2e..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Evaluation.php +++ /dev/null @@ -1,597 +0,0 @@ -google.cloud.workloadmanager.v1.Evaluation - */ -class Evaluation extends \Google\Protobuf\Internal\Message -{ - /** - * Name of resource that has the form - * `projects/{project_id}/locations/{location_id}/evaluations/{evaluation_id}`. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Description of the Evaluation. - * - * Generated from protobuf field string description = 2; - */ - protected $description = ''; - /** - * Resource filter for an evaluation defining the scope of resources to be - * evaluated. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.ResourceFilter resource_filter = 3; - */ - protected $resource_filter = null; - /** - * The names of the rules used for this evaluation. - * - * Generated from protobuf field repeated string rule_names = 4; - */ - private $rule_names; - /** - * Output only. [Output only] The current lifecycle state of the evaluation - * resource. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.ResourceStatus resource_status = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $resource_status = null; - /** - * Output only. [Output only] Create time stamp. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 7 [(.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 = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $update_time = null; - /** - * Labels as key value pairs. - * - * Generated from protobuf field map labels = 9; - */ - private $labels; - /** - * Crontab format schedule for scheduled evaluation, currently only supports - * the following fixed schedules: - * * `0 {@*}1 * * *` # Hourly - * * `0 {@*}6 * * *` # Every 6 hours - * * `0 {@*}12 * * *` # Every 12 hours - * * `0 0 {@*}1 * *` # Daily - * * `0 0 {@*}7 * *` # Weekly - * * `0 0 {@*}14 * *` # Every 14 days - * * `0 0 1 {@*}1 *` # Monthly - * - * Generated from protobuf field optional string schedule = 10; - */ - protected $schedule = null; - /** - * The Cloud Storage bucket name for custom rules. - * - * Generated from protobuf field string custom_rules_bucket = 11; - */ - protected $custom_rules_bucket = ''; - /** - * Evaluation type. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.Evaluation.EvaluationType evaluation_type = 12; - */ - protected $evaluation_type = 0; - /** - * Optional. The BigQuery destination for detailed evaluation results. - * If this field is specified, the results of each evaluation execution are - * exported to BigQuery. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.BigQueryDestination big_query_destination = 13 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $big_query_destination = null; - /** - * Optional. Immutable. Customer-managed encryption key name, in the format - * projects/{@*}locations/{@*}keyRings/{@*}cryptoKeys/*. - * The key will be used for CMEK encryption of the evaluation resource. - * - * Generated from protobuf field string kms_key = 15 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { - */ - protected $kms_key = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Name of resource that has the form - * `projects/{project_id}/locations/{location_id}/evaluations/{evaluation_id}`. - * @type string $description - * Description of the Evaluation. - * @type \Google\Cloud\WorkloadManager\V1\ResourceFilter $resource_filter - * Resource filter for an evaluation defining the scope of resources to be - * evaluated. - * @type string[] $rule_names - * The names of the rules used for this evaluation. - * @type \Google\Cloud\WorkloadManager\V1\ResourceStatus $resource_status - * Output only. [Output only] The current lifecycle state of the evaluation - * resource. - * @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 array|\Google\Protobuf\Internal\MapField $labels - * Labels as key value pairs. - * @type string $schedule - * Crontab format schedule for scheduled evaluation, currently only supports - * the following fixed schedules: - * * `0 {@*}1 * * *` # Hourly - * * `0 {@*}6 * * *` # Every 6 hours - * * `0 {@*}12 * * *` # Every 12 hours - * * `0 0 {@*}1 * *` # Daily - * * `0 0 {@*}7 * *` # Weekly - * * `0 0 {@*}14 * *` # Every 14 days - * * `0 0 1 {@*}1 *` # Monthly - * @type string $custom_rules_bucket - * The Cloud Storage bucket name for custom rules. - * @type int $evaluation_type - * Evaluation type. - * @type \Google\Cloud\WorkloadManager\V1\BigQueryDestination $big_query_destination - * Optional. The BigQuery destination for detailed evaluation results. - * If this field is specified, the results of each evaluation execution are - * exported to BigQuery. - * @type string $kms_key - * Optional. Immutable. Customer-managed encryption key name, in the format - * projects/{@*}locations/{@*}keyRings/{@*}cryptoKeys/*. - * The key will be used for CMEK encryption of the evaluation resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Name of resource that has the form - * `projects/{project_id}/locations/{location_id}/evaluations/{evaluation_id}`. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Name of resource that has the form - * `projects/{project_id}/locations/{location_id}/evaluations/{evaluation_id}`. - * - * 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; - } - - /** - * Description of the Evaluation. - * - * Generated from protobuf field string description = 2; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * Description of the Evaluation. - * - * 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; - } - - /** - * Resource filter for an evaluation defining the scope of resources to be - * evaluated. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.ResourceFilter resource_filter = 3; - * @return \Google\Cloud\WorkloadManager\V1\ResourceFilter|null - */ - public function getResourceFilter() - { - return $this->resource_filter; - } - - public function hasResourceFilter() - { - return isset($this->resource_filter); - } - - public function clearResourceFilter() - { - unset($this->resource_filter); - } - - /** - * Resource filter for an evaluation defining the scope of resources to be - * evaluated. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.ResourceFilter resource_filter = 3; - * @param \Google\Cloud\WorkloadManager\V1\ResourceFilter $var - * @return $this - */ - public function setResourceFilter($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\WorkloadManager\V1\ResourceFilter::class); - $this->resource_filter = $var; - - return $this; - } - - /** - * The names of the rules used for this evaluation. - * - * Generated from protobuf field repeated string rule_names = 4; - * @return RepeatedField - */ - public function getRuleNames() - { - return $this->rule_names; - } - - /** - * The names of the rules used for this evaluation. - * - * Generated from protobuf field repeated string rule_names = 4; - * @param string[] $var - * @return $this - */ - public function setRuleNames($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->rule_names = $arr; - - return $this; - } - - /** - * Output only. [Output only] The current lifecycle state of the evaluation - * resource. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.ResourceStatus resource_status = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Cloud\WorkloadManager\V1\ResourceStatus|null - */ - public function getResourceStatus() - { - return $this->resource_status; - } - - public function hasResourceStatus() - { - return isset($this->resource_status); - } - - public function clearResourceStatus() - { - unset($this->resource_status); - } - - /** - * Output only. [Output only] The current lifecycle state of the evaluation - * resource. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.ResourceStatus resource_status = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\WorkloadManager\V1\ResourceStatus $var - * @return $this - */ - public function setResourceStatus($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\WorkloadManager\V1\ResourceStatus::class); - $this->resource_status = $var; - - return $this; - } - - /** - * Output only. [Output only] Create time stamp. - * - * Generated from protobuf field .google.protobuf.Timestamp create_time = 7 [(.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 = 7 [(.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 = 8 [(.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 = 8 [(.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; - } - - /** - * Labels as key value pairs. - * - * Generated from protobuf field map labels = 9; - * @return \Google\Protobuf\Internal\MapField - */ - public function getLabels() - { - return $this->labels; - } - - /** - * Labels as key value pairs. - * - * 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; - } - - /** - * Crontab format schedule for scheduled evaluation, currently only supports - * the following fixed schedules: - * * `0 {@*}1 * * *` # Hourly - * * `0 {@*}6 * * *` # Every 6 hours - * * `0 {@*}12 * * *` # Every 12 hours - * * `0 0 {@*}1 * *` # Daily - * * `0 0 {@*}7 * *` # Weekly - * * `0 0 {@*}14 * *` # Every 14 days - * * `0 0 1 {@*}1 *` # Monthly - * - * Generated from protobuf field optional string schedule = 10; - * @return string - */ - public function getSchedule() - { - return isset($this->schedule) ? $this->schedule : ''; - } - - public function hasSchedule() - { - return isset($this->schedule); - } - - public function clearSchedule() - { - unset($this->schedule); - } - - /** - * Crontab format schedule for scheduled evaluation, currently only supports - * the following fixed schedules: - * * `0 {@*}1 * * *` # Hourly - * * `0 {@*}6 * * *` # Every 6 hours - * * `0 {@*}12 * * *` # Every 12 hours - * * `0 0 {@*}1 * *` # Daily - * * `0 0 {@*}7 * *` # Weekly - * * `0 0 {@*}14 * *` # Every 14 days - * * `0 0 1 {@*}1 *` # Monthly - * - * Generated from protobuf field optional string schedule = 10; - * @param string $var - * @return $this - */ - public function setSchedule($var) - { - GPBUtil::checkString($var, True); - $this->schedule = $var; - - return $this; - } - - /** - * The Cloud Storage bucket name for custom rules. - * - * Generated from protobuf field string custom_rules_bucket = 11; - * @return string - */ - public function getCustomRulesBucket() - { - return $this->custom_rules_bucket; - } - - /** - * The Cloud Storage bucket name for custom rules. - * - * Generated from protobuf field string custom_rules_bucket = 11; - * @param string $var - * @return $this - */ - public function setCustomRulesBucket($var) - { - GPBUtil::checkString($var, True); - $this->custom_rules_bucket = $var; - - return $this; - } - - /** - * Evaluation type. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.Evaluation.EvaluationType evaluation_type = 12; - * @return int - */ - public function getEvaluationType() - { - return $this->evaluation_type; - } - - /** - * Evaluation type. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.Evaluation.EvaluationType evaluation_type = 12; - * @param int $var - * @return $this - */ - public function setEvaluationType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\WorkloadManager\V1\Evaluation\EvaluationType::class); - $this->evaluation_type = $var; - - return $this; - } - - /** - * Optional. The BigQuery destination for detailed evaluation results. - * If this field is specified, the results of each evaluation execution are - * exported to BigQuery. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.BigQueryDestination big_query_destination = 13 [(.google.api.field_behavior) = OPTIONAL]; - * @return \Google\Cloud\WorkloadManager\V1\BigQueryDestination|null - */ - public function getBigQueryDestination() - { - return $this->big_query_destination; - } - - public function hasBigQueryDestination() - { - return isset($this->big_query_destination); - } - - public function clearBigQueryDestination() - { - unset($this->big_query_destination); - } - - /** - * Optional. The BigQuery destination for detailed evaluation results. - * If this field is specified, the results of each evaluation execution are - * exported to BigQuery. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.BigQueryDestination big_query_destination = 13 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\WorkloadManager\V1\BigQueryDestination $var - * @return $this - */ - public function setBigQueryDestination($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\WorkloadManager\V1\BigQueryDestination::class); - $this->big_query_destination = $var; - - return $this; - } - - /** - * Optional. Immutable. Customer-managed encryption key name, in the format - * projects/{@*}locations/{@*}keyRings/{@*}cryptoKeys/*. - * The key will be used for CMEK encryption of the evaluation resource. - * - * Generated from protobuf field string kms_key = 15 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { - * @return string - */ - public function getKmsKey() - { - return $this->kms_key; - } - - /** - * Optional. Immutable. Customer-managed encryption key name, in the format - * projects/{@*}locations/{@*}keyRings/{@*}cryptoKeys/*. - * The key will be used for CMEK encryption of the evaluation resource. - * - * Generated from protobuf field string kms_key = 15 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setKmsKey($var) - { - GPBUtil::checkString($var, True); - $this->kms_key = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Evaluation/EvaluationType.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Evaluation/EvaluationType.php deleted file mode 100644 index ca76914d92d8..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Evaluation/EvaluationType.php +++ /dev/null @@ -1,68 +0,0 @@ -google.cloud.workloadmanager.v1.Evaluation.EvaluationType - */ -class EvaluationType -{ - /** - * Not specified. - * - * Generated from protobuf enum EVALUATION_TYPE_UNSPECIFIED = 0; - */ - const EVALUATION_TYPE_UNSPECIFIED = 0; - /** - * SAP best practices. - * - * Generated from protobuf enum SAP = 1; - */ - const SAP = 1; - /** - * SQL best practices. - * - * Generated from protobuf enum SQL_SERVER = 2; - */ - const SQL_SERVER = 2; - /** - * Customized best practices. - * - * Generated from protobuf enum OTHER = 3; - */ - const OTHER = 3; - - private static $valueToName = [ - self::EVALUATION_TYPE_UNSPECIFIED => 'EVALUATION_TYPE_UNSPECIFIED', - self::SAP => 'SAP', - self::SQL_SERVER => 'SQL_SERVER', - self::OTHER => 'OTHER', - ]; - - 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/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution.php deleted file mode 100644 index c2467cee43d2..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution.php +++ /dev/null @@ -1,523 +0,0 @@ -google.cloud.workloadmanager.v1.Execution - */ -class Execution extends \Google\Protobuf\Internal\Message -{ - /** - * The name of execution resource. The format is - * projects/{project}/locations/{location}/evaluations/{evaluation}/executions/{execution}. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Output only. [Output only] Start time stamp. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $start_time = null; - /** - * Output only. [Output only] End time stamp. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $end_time = null; - /** - * Output only. [Output only] Inventory time stamp. - * - * Generated from protobuf field .google.protobuf.Timestamp inventory_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $inventory_time = null; - /** - * Output only. [Output only] State. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.Execution.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = 0; - /** - * Output only. [Output only] Evaluation ID. - * - * Generated from protobuf field string evaluation_id = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $evaluation_id = ''; - /** - * Labels as key value pairs. - * - * Generated from protobuf field map labels = 7; - */ - private $labels; - /** - * Type which represents whether the execution executed directly by user or - * scheduled according to the `Evaluation.schedule` field. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.Execution.Type run_type = 8; - */ - protected $run_type = 0; - /** - * Output only. Execution result summary per rule. - * - * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.RuleExecutionResult rule_results = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - private $rule_results; - /** - * Optional. External data sources. - * - * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.Execution.ExternalDataSources external_data_sources = 10 [(.google.api.field_behavior) = OPTIONAL]; - */ - private $external_data_sources; - /** - * Output only. Additional information generated by the execution. - * - * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.Execution.Notice notices = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - private $notices; - /** - * Optional. Engine. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.Execution.Engine engine = 12 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $engine = 0; - /** - * Output only. [Output only] Result summary for the execution. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.Execution.Summary result_summary = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $result_summary = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * The name of execution resource. The format is - * projects/{project}/locations/{location}/evaluations/{evaluation}/executions/{execution}. - * @type \Google\Protobuf\Timestamp $start_time - * Output only. [Output only] Start time stamp. - * @type \Google\Protobuf\Timestamp $end_time - * Output only. [Output only] End time stamp. - * @type \Google\Protobuf\Timestamp $inventory_time - * Output only. [Output only] Inventory time stamp. - * @type int $state - * Output only. [Output only] State. - * @type string $evaluation_id - * Output only. [Output only] Evaluation ID. - * @type array|\Google\Protobuf\Internal\MapField $labels - * Labels as key value pairs. - * @type int $run_type - * Type which represents whether the execution executed directly by user or - * scheduled according to the `Evaluation.schedule` field. - * @type \Google\Cloud\WorkloadManager\V1\RuleExecutionResult[] $rule_results - * Output only. Execution result summary per rule. - * @type \Google\Cloud\WorkloadManager\V1\Execution\ExternalDataSources[] $external_data_sources - * Optional. External data sources. - * @type \Google\Cloud\WorkloadManager\V1\Execution\Notice[] $notices - * Output only. Additional information generated by the execution. - * @type int $engine - * Optional. Engine. - * @type \Google\Cloud\WorkloadManager\V1\Execution\Summary $result_summary - * Output only. [Output only] Result summary for the execution. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * The name of execution resource. The format is - * projects/{project}/locations/{location}/evaluations/{evaluation}/executions/{execution}. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The name of execution resource. The format is - * projects/{project}/locations/{location}/evaluations/{evaluation}/executions/{execution}. - * - * 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. [Output only] Start time stamp. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 2 [(.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. [Output only] Start time stamp. - * - * Generated from protobuf field .google.protobuf.Timestamp start_time = 2 [(.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. [Output only] End time stamp. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 3 [(.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. [Output only] End time stamp. - * - * Generated from protobuf field .google.protobuf.Timestamp end_time = 3 [(.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. [Output only] Inventory time stamp. - * - * Generated from protobuf field .google.protobuf.Timestamp inventory_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Timestamp|null - */ - public function getInventoryTime() - { - return $this->inventory_time; - } - - public function hasInventoryTime() - { - return isset($this->inventory_time); - } - - public function clearInventoryTime() - { - unset($this->inventory_time); - } - - /** - * Output only. [Output only] Inventory time stamp. - * - * Generated from protobuf field .google.protobuf.Timestamp inventory_time = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Protobuf\Timestamp $var - * @return $this - */ - public function setInventoryTime($var) - { - GPBUtil::checkMessage($var, \Google\Protobuf\Timestamp::class); - $this->inventory_time = $var; - - return $this; - } - - /** - * Output only. [Output only] State. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.Execution.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Output only. [Output only] State. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.Execution.State state = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\WorkloadManager\V1\Execution\State::class); - $this->state = $var; - - return $this; - } - - /** - * Output only. [Output only] Evaluation ID. - * - * Generated from protobuf field string evaluation_id = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getEvaluationId() - { - return $this->evaluation_id; - } - - /** - * Output only. [Output only] Evaluation ID. - * - * Generated from protobuf field string evaluation_id = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setEvaluationId($var) - { - GPBUtil::checkString($var, True); - $this->evaluation_id = $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; - } - - /** - * Type which represents whether the execution executed directly by user or - * scheduled according to the `Evaluation.schedule` field. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.Execution.Type run_type = 8; - * @return int - */ - public function getRunType() - { - return $this->run_type; - } - - /** - * Type which represents whether the execution executed directly by user or - * scheduled according to the `Evaluation.schedule` field. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.Execution.Type run_type = 8; - * @param int $var - * @return $this - */ - public function setRunType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\WorkloadManager\V1\Execution\Type::class); - $this->run_type = $var; - - return $this; - } - - /** - * Output only. Execution result summary per rule. - * - * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.RuleExecutionResult rule_results = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return RepeatedField<\Google\Cloud\WorkloadManager\V1\RuleExecutionResult> - */ - public function getRuleResults() - { - return $this->rule_results; - } - - /** - * Output only. Execution result summary per rule. - * - * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.RuleExecutionResult rule_results = 9 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\WorkloadManager\V1\RuleExecutionResult[] $var - * @return $this - */ - public function setRuleResults($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\WorkloadManager\V1\RuleExecutionResult::class); - $this->rule_results = $arr; - - return $this; - } - - /** - * Optional. External data sources. - * - * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.Execution.ExternalDataSources external_data_sources = 10 [(.google.api.field_behavior) = OPTIONAL]; - * @return RepeatedField<\Google\Cloud\WorkloadManager\V1\Execution\ExternalDataSources> - */ - public function getExternalDataSources() - { - return $this->external_data_sources; - } - - /** - * Optional. External data sources. - * - * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.Execution.ExternalDataSources external_data_sources = 10 [(.google.api.field_behavior) = OPTIONAL]; - * @param \Google\Cloud\WorkloadManager\V1\Execution\ExternalDataSources[] $var - * @return $this - */ - public function setExternalDataSources($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\WorkloadManager\V1\Execution\ExternalDataSources::class); - $this->external_data_sources = $arr; - - return $this; - } - - /** - * Output only. Additional information generated by the execution. - * - * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.Execution.Notice notices = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return RepeatedField<\Google\Cloud\WorkloadManager\V1\Execution\Notice> - */ - public function getNotices() - { - return $this->notices; - } - - /** - * Output only. Additional information generated by the execution. - * - * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.Execution.Notice notices = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\WorkloadManager\V1\Execution\Notice[] $var - * @return $this - */ - public function setNotices($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\WorkloadManager\V1\Execution\Notice::class); - $this->notices = $arr; - - return $this; - } - - /** - * Optional. Engine. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.Execution.Engine engine = 12 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getEngine() - { - return $this->engine; - } - - /** - * Optional. Engine. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.Execution.Engine engine = 12 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setEngine($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\WorkloadManager\V1\Execution\Engine::class); - $this->engine = $var; - - return $this; - } - - /** - * Output only. [Output only] Result summary for the execution. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.Execution.Summary result_summary = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Cloud\WorkloadManager\V1\Execution\Summary|null - */ - public function getResultSummary() - { - return $this->result_summary; - } - - public function hasResultSummary() - { - return isset($this->result_summary); - } - - public function clearResultSummary() - { - unset($this->result_summary); - } - - /** - * Output only. [Output only] Result summary for the execution. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.Execution.Summary result_summary = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\WorkloadManager\V1\Execution\Summary $var - * @return $this - */ - public function setResultSummary($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\WorkloadManager\V1\Execution\Summary::class); - $this->result_summary = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/Engine.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/Engine.php deleted file mode 100644 index 2eab2de77522..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/Engine.php +++ /dev/null @@ -1,61 +0,0 @@ -google.cloud.workloadmanager.v1.Execution.Engine - */ -class Engine -{ - /** - * The original CG. - * - * Generated from protobuf enum ENGINE_UNSPECIFIED = 0; - */ - const ENGINE_UNSPECIFIED = 0; - /** - * SlimCG / Scanner. - * - * Generated from protobuf enum ENGINE_SCANNER = 1; - */ - const ENGINE_SCANNER = 1; - /** - * Evaluation Engine V2. - * - * Generated from protobuf enum V2 = 2; - */ - const V2 = 2; - - private static $valueToName = [ - self::ENGINE_UNSPECIFIED => 'ENGINE_UNSPECIFIED', - self::ENGINE_SCANNER => 'ENGINE_SCANNER', - self::V2 => 'V2', - ]; - - 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/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/ExternalDataSources.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/ExternalDataSources.php deleted file mode 100644 index 2b3a52e447d9..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/ExternalDataSources.php +++ /dev/null @@ -1,193 +0,0 @@ -google.cloud.workloadmanager.v1.Execution.ExternalDataSources - */ -class ExternalDataSources extends \Google\Protobuf\Internal\Message -{ - /** - * Optional. Name of external data source. The name will be used inside the - * rego/sql to refer the external data. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $name = ''; - /** - * Required. URI of external data source. example of bq table - * {project_ID}.{dataset_ID}.{table_ID}. - * - * Generated from protobuf field string uri = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $uri = ''; - /** - * Required. Type of external data source. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.Execution.ExternalDataSources.Type type = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $type = 0; - /** - * Required. The asset type of the external data source. - * This can be a supported Cloud Asset Inventory asset type - * (see https://cloud.google.com/asset-inventory/docs/supported-asset-types) - * to override the default asset type, or it can be a custom type defined by - * the user. - * - * Generated from protobuf field string asset_type = 4 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $asset_type = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Optional. Name of external data source. The name will be used inside the - * rego/sql to refer the external data. - * @type string $uri - * Required. URI of external data source. example of bq table - * {project_ID}.{dataset_ID}.{table_ID}. - * @type int $type - * Required. Type of external data source. - * @type string $asset_type - * Required. The asset type of the external data source. - * This can be a supported Cloud Asset Inventory asset type - * (see https://cloud.google.com/asset-inventory/docs/supported-asset-types) - * to override the default asset type, or it can be a custom type defined by - * the user. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Optional. Name of external data source. The name will be used inside the - * rego/sql to refer the external data. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OPTIONAL]; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Optional. Name of external data source. The name will be used inside the - * rego/sql to refer the external data. - * - * 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; - } - - /** - * Required. URI of external data source. example of bq table - * {project_ID}.{dataset_ID}.{table_ID}. - * - * Generated from protobuf field string uri = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getUri() - { - return $this->uri; - } - - /** - * Required. URI of external data source. example of bq table - * {project_ID}.{dataset_ID}.{table_ID}. - * - * Generated from protobuf field string uri = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setUri($var) - { - GPBUtil::checkString($var, True); - $this->uri = $var; - - return $this; - } - - /** - * Required. Type of external data source. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.Execution.ExternalDataSources.Type type = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return int - */ - public function getType() - { - return $this->type; - } - - /** - * Required. Type of external data source. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.Execution.ExternalDataSources.Type type = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param int $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\WorkloadManager\V1\Execution\ExternalDataSources\Type::class); - $this->type = $var; - - return $this; - } - - /** - * Required. The asset type of the external data source. - * This can be a supported Cloud Asset Inventory asset type - * (see https://cloud.google.com/asset-inventory/docs/supported-asset-types) - * to override the default asset type, or it can be a custom type defined by - * the user. - * - * Generated from protobuf field string asset_type = 4 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getAssetType() - { - return $this->asset_type; - } - - /** - * Required. The asset type of the external data source. - * This can be a supported Cloud Asset Inventory asset type - * (see https://cloud.google.com/asset-inventory/docs/supported-asset-types) - * to override the default asset type, or it can be a custom type defined by - * the user. - * - * Generated from protobuf field string asset_type = 4 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setAssetType($var) - { - GPBUtil::checkString($var, True); - $this->asset_type = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/ExternalDataSources/Type.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/ExternalDataSources/Type.php deleted file mode 100644 index ace783f4dc23..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/ExternalDataSources/Type.php +++ /dev/null @@ -1,54 +0,0 @@ -google.cloud.workloadmanager.v1.Execution.ExternalDataSources.Type - */ -class Type -{ - /** - * Unknown type. - * - * Generated from protobuf enum TYPE_UNSPECIFIED = 0; - */ - const TYPE_UNSPECIFIED = 0; - /** - * BigQuery table. - * - * Generated from protobuf enum BIG_QUERY_TABLE = 1; - */ - const BIG_QUERY_TABLE = 1; - - private static $valueToName = [ - self::TYPE_UNSPECIFIED => 'TYPE_UNSPECIFIED', - self::BIG_QUERY_TABLE => 'BIG_QUERY_TABLE', - ]; - - 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/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/Notice.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/Notice.php deleted file mode 100644 index 5714c4d9904d..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/Notice.php +++ /dev/null @@ -1,67 +0,0 @@ -google.cloud.workloadmanager.v1.Execution.Notice - */ -class Notice extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. Message of the notice. - * - * Generated from protobuf field string message = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $message = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $message - * Output only. Message of the notice. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Output only. Message of the notice. - * - * Generated from protobuf field string message = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getMessage() - { - return $this->message; - } - - /** - * Output only. Message of the notice. - * - * Generated from protobuf field string message = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param string $var - * @return $this - */ - public function setMessage($var) - { - GPBUtil::checkString($var, True); - $this->message = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/State.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/State.php deleted file mode 100644 index dee6c46c0034..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/State.php +++ /dev/null @@ -1,68 +0,0 @@ -google.cloud.workloadmanager.v1.Execution.State - */ -class State -{ - /** - * State of execution is unspecified. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * The execution is running in backend service. - * - * Generated from protobuf enum RUNNING = 1; - */ - const RUNNING = 1; - /** - * The execution run succeeded. - * - * Generated from protobuf enum SUCCEEDED = 2; - */ - const SUCCEEDED = 2; - /** - * The execution run failed. - * - * Generated from protobuf enum FAILED = 3; - */ - const FAILED = 3; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - 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); - } -} - diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/Summary.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/Summary.php deleted file mode 100644 index 213268e904d6..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/Summary.php +++ /dev/null @@ -1,135 +0,0 @@ -google.cloud.workloadmanager.v1.Execution.Summary - */ -class Summary extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. Number of failures. - * - * Generated from protobuf field int64 failures = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $failures = 0; - /** - * Output only. Number of new failures compared to the previous execution. - * - * Generated from protobuf field int64 new_failures = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $new_failures = 0; - /** - * Output only. Number of new fixes compared to the previous execution. - * - * Generated from protobuf field int64 new_fixes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $new_fixes = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int|string $failures - * Output only. Number of failures. - * @type int|string $new_failures - * Output only. Number of new failures compared to the previous execution. - * @type int|string $new_fixes - * Output only. Number of new fixes compared to the previous execution. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Output only. Number of failures. - * - * Generated from protobuf field int64 failures = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int|string - */ - public function getFailures() - { - return $this->failures; - } - - /** - * Output only. Number of failures. - * - * Generated from protobuf field int64 failures = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int|string $var - * @return $this - */ - public function setFailures($var) - { - GPBUtil::checkInt64($var); - $this->failures = $var; - - return $this; - } - - /** - * Output only. Number of new failures compared to the previous execution. - * - * Generated from protobuf field int64 new_failures = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int|string - */ - public function getNewFailures() - { - return $this->new_failures; - } - - /** - * Output only. Number of new failures compared to the previous execution. - * - * Generated from protobuf field int64 new_failures = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int|string $var - * @return $this - */ - public function setNewFailures($var) - { - GPBUtil::checkInt64($var); - $this->new_failures = $var; - - return $this; - } - - /** - * Output only. Number of new fixes compared to the previous execution. - * - * Generated from protobuf field int64 new_fixes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int|string - */ - public function getNewFixes() - { - return $this->new_fixes; - } - - /** - * Output only. Number of new fixes compared to the previous execution. - * - * Generated from protobuf field int64 new_fixes = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int|string $var - * @return $this - */ - public function setNewFixes($var) - { - GPBUtil::checkInt64($var); - $this->new_fixes = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/Type.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/Type.php deleted file mode 100644 index 441034593b4a..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Execution/Type.php +++ /dev/null @@ -1,61 +0,0 @@ -google.cloud.workloadmanager.v1.Execution.Type - */ -class Type -{ - /** - * Type of execution is unspecified. - * - * Generated from protobuf enum TYPE_UNSPECIFIED = 0; - */ - const TYPE_UNSPECIFIED = 0; - /** - * Type of execution is one time. - * - * Generated from protobuf enum ONE_TIME = 1; - */ - const ONE_TIME = 1; - /** - * Type of execution is scheduled. - * - * Generated from protobuf enum SCHEDULED = 2; - */ - const SCHEDULED = 2; - - private static $valueToName = [ - self::TYPE_UNSPECIFIED => 'TYPE_UNSPECIFIED', - self::ONE_TIME => 'ONE_TIME', - self::SCHEDULED => 'SCHEDULED', - ]; - - 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/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ExecutionResult.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ExecutionResult.php deleted file mode 100644 index 324b3ebd2a4f..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ExecutionResult.php +++ /dev/null @@ -1,325 +0,0 @@ -google.cloud.workloadmanager.v1.ExecutionResult - */ -class ExecutionResult extends \Google\Protobuf\Internal\Message -{ - /** - * The violation message of an execution. - * - * Generated from protobuf field string violation_message = 1; - */ - protected $violation_message = ''; - /** - * The severity of violation. - * - * Generated from protobuf field string severity = 2; - */ - protected $severity = ''; - /** - * The rule that is violated in an evaluation. - * - * Generated from protobuf field string rule = 3 [(.google.api.resource_reference) = { - */ - protected $rule = ''; - /** - * The URL for the documentation of the rule. - * - * Generated from protobuf field string documentation_url = 4; - */ - protected $documentation_url = ''; - /** - * The resource that violates the rule. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.Resource resource = 5; - */ - protected $resource = null; - /** - * The details of violation in an evaluation result. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.ViolationDetails violation_details = 6; - */ - protected $violation_details = null; - /** - * The commands to remediate the violation. - * - * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.Command commands = 7; - */ - private $commands; - /** - * Execution result type of the scanned resource. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.ExecutionResult.Type type = 8; - */ - protected $type = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $violation_message - * The violation message of an execution. - * @type string $severity - * The severity of violation. - * @type string $rule - * The rule that is violated in an evaluation. - * @type string $documentation_url - * The URL for the documentation of the rule. - * @type \Google\Cloud\WorkloadManager\V1\Resource $resource - * The resource that violates the rule. - * @type \Google\Cloud\WorkloadManager\V1\ViolationDetails $violation_details - * The details of violation in an evaluation result. - * @type \Google\Cloud\WorkloadManager\V1\Command[] $commands - * The commands to remediate the violation. - * @type int $type - * Execution result type of the scanned resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * The violation message of an execution. - * - * Generated from protobuf field string violation_message = 1; - * @return string - */ - public function getViolationMessage() - { - return $this->violation_message; - } - - /** - * The violation message of an execution. - * - * Generated from protobuf field string violation_message = 1; - * @param string $var - * @return $this - */ - public function setViolationMessage($var) - { - GPBUtil::checkString($var, True); - $this->violation_message = $var; - - return $this; - } - - /** - * The severity of violation. - * - * Generated from protobuf field string severity = 2; - * @return string - */ - public function getSeverity() - { - return $this->severity; - } - - /** - * The severity of violation. - * - * Generated from protobuf field string severity = 2; - * @param string $var - * @return $this - */ - public function setSeverity($var) - { - GPBUtil::checkString($var, True); - $this->severity = $var; - - return $this; - } - - /** - * The rule that is violated in an evaluation. - * - * Generated from protobuf field string rule = 3 [(.google.api.resource_reference) = { - * @return string - */ - public function getRule() - { - return $this->rule; - } - - /** - * The rule that is violated in an evaluation. - * - * Generated from protobuf field string rule = 3 [(.google.api.resource_reference) = { - * @param string $var - * @return $this - */ - public function setRule($var) - { - GPBUtil::checkString($var, True); - $this->rule = $var; - - return $this; - } - - /** - * The URL for the documentation of the rule. - * - * Generated from protobuf field string documentation_url = 4; - * @return string - */ - public function getDocumentationUrl() - { - return $this->documentation_url; - } - - /** - * The URL for the documentation of the rule. - * - * Generated from protobuf field string documentation_url = 4; - * @param string $var - * @return $this - */ - public function setDocumentationUrl($var) - { - GPBUtil::checkString($var, True); - $this->documentation_url = $var; - - return $this; - } - - /** - * The resource that violates the rule. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.Resource resource = 5; - * @return \Google\Cloud\WorkloadManager\V1\Resource|null - */ - public function getResource() - { - return $this->resource; - } - - public function hasResource() - { - return isset($this->resource); - } - - public function clearResource() - { - unset($this->resource); - } - - /** - * The resource that violates the rule. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.Resource resource = 5; - * @param \Google\Cloud\WorkloadManager\V1\Resource $var - * @return $this - */ - public function setResource($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\WorkloadManager\V1\Resource::class); - $this->resource = $var; - - return $this; - } - - /** - * The details of violation in an evaluation result. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.ViolationDetails violation_details = 6; - * @return \Google\Cloud\WorkloadManager\V1\ViolationDetails|null - */ - public function getViolationDetails() - { - return $this->violation_details; - } - - public function hasViolationDetails() - { - return isset($this->violation_details); - } - - public function clearViolationDetails() - { - unset($this->violation_details); - } - - /** - * The details of violation in an evaluation result. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.ViolationDetails violation_details = 6; - * @param \Google\Cloud\WorkloadManager\V1\ViolationDetails $var - * @return $this - */ - public function setViolationDetails($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\WorkloadManager\V1\ViolationDetails::class); - $this->violation_details = $var; - - return $this; - } - - /** - * The commands to remediate the violation. - * - * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.Command commands = 7; - * @return RepeatedField<\Google\Cloud\WorkloadManager\V1\Command> - */ - public function getCommands() - { - return $this->commands; - } - - /** - * The commands to remediate the violation. - * - * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.Command commands = 7; - * @param \Google\Cloud\WorkloadManager\V1\Command[] $var - * @return $this - */ - public function setCommands($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\WorkloadManager\V1\Command::class); - $this->commands = $arr; - - return $this; - } - - /** - * Execution result type of the scanned resource. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.ExecutionResult.Type type = 8; - * @return int - */ - public function getType() - { - return $this->type; - } - - /** - * Execution result type of the scanned resource. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.ExecutionResult.Type type = 8; - * @param int $var - * @return $this - */ - public function setType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\WorkloadManager\V1\ExecutionResult\Type::class); - $this->type = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ExecutionResult/Type.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ExecutionResult/Type.php deleted file mode 100644 index 4b283dbbaa32..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ExecutionResult/Type.php +++ /dev/null @@ -1,61 +0,0 @@ -google.cloud.workloadmanager.v1.ExecutionResult.Type - */ -class Type -{ - /** - * Unknown state. - * - * Generated from protobuf enum TYPE_UNSPECIFIED = 0; - */ - const TYPE_UNSPECIFIED = 0; - /** - * Resource successfully passed the rule. - * - * Generated from protobuf enum TYPE_PASSED = 1; - */ - const TYPE_PASSED = 1; - /** - * Resource violated the rule. - * - * Generated from protobuf enum TYPE_VIOLATED = 2; - */ - const TYPE_VIOLATED = 2; - - private static $valueToName = [ - self::TYPE_UNSPECIFIED => 'TYPE_UNSPECIFIED', - self::TYPE_PASSED => 'TYPE_PASSED', - self::TYPE_VIOLATED => 'TYPE_VIOLATED', - ]; - - 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/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/GceInstanceFilter.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/GceInstanceFilter.php deleted file mode 100644 index 9b64151a16a0..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/GceInstanceFilter.php +++ /dev/null @@ -1,71 +0,0 @@ -google.cloud.workloadmanager.v1.GceInstanceFilter - */ -class GceInstanceFilter extends \Google\Protobuf\Internal\Message -{ - /** - * If non-empty, only Compute Engine instances associated with at least one of - * the provided service accounts will be included in the evaluation. - * - * Generated from protobuf field repeated string service_accounts = 4; - */ - private $service_accounts; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string[] $service_accounts - * If non-empty, only Compute Engine instances associated with at least one of - * the provided service accounts will be included in the evaluation. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * If non-empty, only Compute Engine instances associated with at least one of - * the provided service accounts will be included in the evaluation. - * - * Generated from protobuf field repeated string service_accounts = 4; - * @return RepeatedField - */ - public function getServiceAccounts() - { - return $this->service_accounts; - } - - /** - * If non-empty, only Compute Engine instances associated with at least one of - * the provided service accounts will be included in the evaluation. - * - * Generated from protobuf field repeated string service_accounts = 4; - * @param string[] $var - * @return $this - */ - public function setServiceAccounts($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->service_accounts = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/GetEvaluationRequest.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/GetEvaluationRequest.php deleted file mode 100644 index b75aba40adb4..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/GetEvaluationRequest.php +++ /dev/null @@ -1,81 +0,0 @@ -google.cloud.workloadmanager.v1.GetEvaluationRequest - */ -class GetEvaluationRequest 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 WorkloadManagerClient::evaluationName()} for help formatting this field. - * - * @return \Google\Cloud\WorkloadManager\V1\GetEvaluationRequest - * - * @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\Workloadmanager\V1\Service::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/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/GetExecutionRequest.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/GetExecutionRequest.php deleted file mode 100644 index 6226a78e28bd..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/GetExecutionRequest.php +++ /dev/null @@ -1,81 +0,0 @@ -google.cloud.workloadmanager.v1.GetExecutionRequest - */ -class GetExecutionRequest 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 WorkloadManagerClient::executionName()} for help formatting this field. - * - * @return \Google\Cloud\WorkloadManager\V1\GetExecutionRequest - * - * @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\Workloadmanager\V1\Service::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/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListEvaluationsRequest.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListEvaluationsRequest.php deleted file mode 100644 index 6c84965635f1..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListEvaluationsRequest.php +++ /dev/null @@ -1,221 +0,0 @@ -google.cloud.workloadmanager.v1.ListEvaluationsRequest - */ -class ListEvaluationsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Parent value for ListEvaluationsRequest. - * - * 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, 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 the server should return. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - /** - * Filter to be applied when listing the evaluation results. - * - * Generated from protobuf field string filter = 4; - */ - protected $filter = ''; - /** - * Hint for how to order the results. - * - * Generated from protobuf field string order_by = 5; - */ - protected $order_by = ''; - - /** - * @param string $parent Required. Parent value for ListEvaluationsRequest. Please see - * {@see WorkloadManagerClient::locationName()} for help formatting this field. - * - * @return \Google\Cloud\WorkloadManager\V1\ListEvaluationsRequest - * - * @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 ListEvaluationsRequest. - * @type int $page_size - * Requested page size. Server may return fewer items than requested. - * If unspecified, server will pick an appropriate default. - * @type string $page_token - * A token identifying a page of results the server should return. - * @type string $filter - * Filter to be applied when listing the evaluation results. - * @type string $order_by - * Hint for how to order the results. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Required. Parent value for ListEvaluationsRequest. - * - * 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 ListEvaluationsRequest. - * - * 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, 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, 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 the server should return. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * A token identifying a page of results the server should return. - * - * 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 to be applied when listing the evaluation results. - * - * Generated from protobuf field string filter = 4; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Filter to be applied when listing the evaluation results. - * - * 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; - } - - /** - * Hint for how to order the results. - * - * Generated from protobuf field string order_by = 5; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * Hint for how to order the results. - * - * 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/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListEvaluationsResponse.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListEvaluationsResponse.php deleted file mode 100644 index 9c6d566611ec..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListEvaluationsResponse.php +++ /dev/null @@ -1,135 +0,0 @@ -google.cloud.workloadmanager.v1.ListEvaluationsResponse - */ -class ListEvaluationsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The list of evaluations. - * - * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.Evaluation evaluations = 1; - */ - private $evaluations; - /** - * 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 \Google\Cloud\WorkloadManager\V1\Evaluation[] $evaluations - * The list of evaluations. - * @type string $next_page_token - * A token identifying a page of results the server should return. - * @type string[] $unreachable - * Locations that could not be reached. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * The list of evaluations. - * - * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.Evaluation evaluations = 1; - * @return RepeatedField<\Google\Cloud\WorkloadManager\V1\Evaluation> - */ - public function getEvaluations() - { - return $this->evaluations; - } - - /** - * The list of evaluations. - * - * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.Evaluation evaluations = 1; - * @param \Google\Cloud\WorkloadManager\V1\Evaluation[] $var - * @return $this - */ - public function setEvaluations($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\WorkloadManager\V1\Evaluation::class); - $this->evaluations = $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 RepeatedField - */ - public function getUnreachable() - { - return $this->unreachable; - } - - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @param string[] $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/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListExecutionResultsRequest.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListExecutionResultsRequest.php deleted file mode 100644 index 79ae90c7eea2..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListExecutionResultsRequest.php +++ /dev/null @@ -1,191 +0,0 @@ -google.cloud.workloadmanager.v1.ListExecutionResultsRequest - */ -class ListExecutionResultsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The execution results. - * Format: {parent}/evaluations/{@*}executions/{@*}results. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $parent = ''; - /** - * 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; - */ - protected $page_size = 0; - /** - * A token identifying a page of results the server should return. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - /** - * Filtering results. - * - * Generated from protobuf field string filter = 4; - */ - protected $filter = ''; - - /** - * @param string $parent Required. The execution results. - * Format: {parent}/evaluations/*/executions/*/results. - * - * @return \Google\Cloud\WorkloadManager\V1\ListExecutionResultsRequest - * - * @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 execution results. - * Format: {parent}/evaluations/{@*}executions/{@*}results. - * @type int $page_size - * Requested page size. Server may return fewer items than requested. - * If unspecified, server will pick an appropriate default. - * @type string $page_token - * A token identifying a page of results the server should return. - * @type string $filter - * Filtering results. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Required. The execution results. - * Format: {parent}/evaluations/{@*}executions/{@*}results. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. The execution results. - * Format: {parent}/evaluations/{@*}executions/{@*}results. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED]; - * @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, 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, 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 the server should return. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * A token identifying a page of results the server should return. - * - * 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; - } - - /** - * Filtering results. - * - * Generated from protobuf field string filter = 4; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Filtering results. - * - * 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/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListExecutionResultsResponse.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListExecutionResultsResponse.php deleted file mode 100644 index 6b22e73de5f7..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListExecutionResultsResponse.php +++ /dev/null @@ -1,105 +0,0 @@ -google.cloud.workloadmanager.v1.ListExecutionResultsResponse - */ -class ListExecutionResultsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The versions from the specified publisher. - * - * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.ExecutionResult execution_results = 1; - */ - private $execution_results; - /** - * 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 \Google\Cloud\WorkloadManager\V1\ExecutionResult[] $execution_results - * 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\Workloadmanager\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * The versions from the specified publisher. - * - * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.ExecutionResult execution_results = 1; - * @return RepeatedField<\Google\Cloud\WorkloadManager\V1\ExecutionResult> - */ - public function getExecutionResults() - { - return $this->execution_results; - } - - /** - * The versions from the specified publisher. - * - * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.ExecutionResult execution_results = 1; - * @param \Google\Cloud\WorkloadManager\V1\ExecutionResult[] $var - * @return $this - */ - public function setExecutionResults($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\WorkloadManager\V1\ExecutionResult::class); - $this->execution_results = $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/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListExecutionsRequest.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListExecutionsRequest.php deleted file mode 100644 index d23e4813582c..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListExecutionsRequest.php +++ /dev/null @@ -1,226 +0,0 @@ -google.cloud.workloadmanager.v1.ListExecutionsRequest - */ -class ListExecutionsRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource prefix of the Execution using the form: - * `projects/{project}/locations/{location}/evaluations/{evaluation}`. - * - * 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, 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 the server should return. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - /** - * Filtering results. - * - * Generated from protobuf field string filter = 4; - */ - protected $filter = ''; - /** - * Field to sort by. See https://google.aip.dev/132#ordering for more details. - * - * Generated from protobuf field string order_by = 5; - */ - protected $order_by = ''; - - /** - * @param string $parent Required. The resource prefix of the Execution using the form: - * `projects/{project}/locations/{location}/evaluations/{evaluation}`. Please see - * {@see WorkloadManagerClient::evaluationName()} for help formatting this field. - * - * @return \Google\Cloud\WorkloadManager\V1\ListExecutionsRequest - * - * @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 prefix of the Execution using the form: - * `projects/{project}/locations/{location}/evaluations/{evaluation}`. - * @type int $page_size - * Requested page size. Server may return fewer items than requested. - * If unspecified, server will pick an appropriate default. - * @type string $page_token - * A token identifying a page of results the server should return. - * @type string $filter - * Filtering results. - * @type string $order_by - * Field to sort by. See https://google.aip.dev/132#ordering for more details. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource prefix of the Execution using the form: - * `projects/{project}/locations/{location}/evaluations/{evaluation}`. - * - * 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 prefix of the Execution using the form: - * `projects/{project}/locations/{location}/evaluations/{evaluation}`. - * - * 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, 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, 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 the server should return. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * A token identifying a page of results the server should return. - * - * 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; - } - - /** - * Filtering results. - * - * Generated from protobuf field string filter = 4; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Filtering results. - * - * 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; - } - - /** - * Field to sort by. See https://google.aip.dev/132#ordering for more details. - * - * Generated from protobuf field string order_by = 5; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * Field to sort by. See https://google.aip.dev/132#ordering for more details. - * - * 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/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListExecutionsResponse.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListExecutionsResponse.php deleted file mode 100644 index 6d130e8d3886..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListExecutionsResponse.php +++ /dev/null @@ -1,135 +0,0 @@ -google.cloud.workloadmanager.v1.ListExecutionsResponse - */ -class ListExecutionsResponse extends \Google\Protobuf\Internal\Message -{ - /** - * The list of Execution. - * - * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.Execution executions = 1; - */ - private $executions; - /** - * 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 \Google\Cloud\WorkloadManager\V1\Execution[] $executions - * The list of Execution. - * @type string $next_page_token - * A token identifying a page of results the server should return. - * @type string[] $unreachable - * Locations that could not be reached. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * The list of Execution. - * - * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.Execution executions = 1; - * @return RepeatedField<\Google\Cloud\WorkloadManager\V1\Execution> - */ - public function getExecutions() - { - return $this->executions; - } - - /** - * The list of Execution. - * - * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.Execution executions = 1; - * @param \Google\Cloud\WorkloadManager\V1\Execution[] $var - * @return $this - */ - public function setExecutions($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\WorkloadManager\V1\Execution::class); - $this->executions = $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 RepeatedField - */ - public function getUnreachable() - { - return $this->unreachable; - } - - /** - * Locations that could not be reached. - * - * Generated from protobuf field repeated string unreachable = 3; - * @param string[] $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/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListRulesRequest.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListRulesRequest.php deleted file mode 100644 index eec3d72aa14b..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListRulesRequest.php +++ /dev/null @@ -1,274 +0,0 @@ -google.cloud.workloadmanager.v1.ListRulesRequest - */ -class ListRulesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The [project] on which to execute the request. The format is: - * projects/{project_id}/locations/{location} - * Currently, the pre-defined rules are global available to all projects and - * all regions. - * - * 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, 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 the server should return. - * - * Generated from protobuf field string page_token = 3; - */ - protected $page_token = ''; - /** - * Filter based on primary_category, secondary_category. - * - * Generated from protobuf field string filter = 4; - */ - protected $filter = ''; - /** - * The Cloud Storage bucket name for custom rules. - * - * Generated from protobuf field string custom_rules_bucket = 5; - */ - protected $custom_rules_bucket = ''; - /** - * Optional. The evaluation type of the rules will be applied to. - * The Cloud Storage bucket name for custom rules. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.Evaluation.EvaluationType evaluation_type = 6 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $evaluation_type = 0; - - /** - * @param string $parent Required. The [project] on which to execute the request. The format is: - * projects/{project_id}/locations/{location} - * Currently, the pre-defined rules are global available to all projects and - * all regions. Please see - * {@see WorkloadManagerClient::locationName()} for help formatting this field. - * - * @return \Google\Cloud\WorkloadManager\V1\ListRulesRequest - * - * @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] on which to execute the request. The format is: - * projects/{project_id}/locations/{location} - * Currently, the pre-defined rules are global available to all projects and - * all regions. - * @type int $page_size - * Requested page size. Server may return fewer items than requested. - * If unspecified, server will pick an appropriate default. - * @type string $page_token - * A token identifying a page of results the server should return. - * @type string $filter - * Filter based on primary_category, secondary_category. - * @type string $custom_rules_bucket - * The Cloud Storage bucket name for custom rules. - * @type int $evaluation_type - * Optional. The evaluation type of the rules will be applied to. - * The Cloud Storage bucket name for custom rules. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Required. The [project] on which to execute the request. The format is: - * projects/{project_id}/locations/{location} - * Currently, the pre-defined rules are global available to all projects and - * all regions. - * - * 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] on which to execute the request. The format is: - * projects/{project_id}/locations/{location} - * Currently, the pre-defined rules are global available to all projects and - * all regions. - * - * 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, 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, 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 the server should return. - * - * Generated from protobuf field string page_token = 3; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * A token identifying a page of results the server should return. - * - * 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 based on primary_category, secondary_category. - * - * Generated from protobuf field string filter = 4; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Filter based on primary_category, secondary_category. - * - * 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; - } - - /** - * The Cloud Storage bucket name for custom rules. - * - * Generated from protobuf field string custom_rules_bucket = 5; - * @return string - */ - public function getCustomRulesBucket() - { - return $this->custom_rules_bucket; - } - - /** - * The Cloud Storage bucket name for custom rules. - * - * Generated from protobuf field string custom_rules_bucket = 5; - * @param string $var - * @return $this - */ - public function setCustomRulesBucket($var) - { - GPBUtil::checkString($var, True); - $this->custom_rules_bucket = $var; - - return $this; - } - - /** - * Optional. The evaluation type of the rules will be applied to. - * The Cloud Storage bucket name for custom rules. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.Evaluation.EvaluationType evaluation_type = 6 [(.google.api.field_behavior) = OPTIONAL]; - * @return int - */ - public function getEvaluationType() - { - return $this->evaluation_type; - } - - /** - * Optional. The evaluation type of the rules will be applied to. - * The Cloud Storage bucket name for custom rules. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.Evaluation.EvaluationType evaluation_type = 6 [(.google.api.field_behavior) = OPTIONAL]; - * @param int $var - * @return $this - */ - public function setEvaluationType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\WorkloadManager\V1\Evaluation\EvaluationType::class); - $this->evaluation_type = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListRulesResponse.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListRulesResponse.php deleted file mode 100644 index 02e22504f3d4..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListRulesResponse.php +++ /dev/null @@ -1,67 +0,0 @@ -google.cloud.workloadmanager.v1.ListRulesResponse - */ -class ListRulesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * All rules in response. - * - * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.Rule rules = 1; - */ - private $rules; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type \Google\Cloud\WorkloadManager\V1\Rule[] $rules - * All rules in response. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * All rules in response. - * - * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.Rule rules = 1; - * @return RepeatedField<\Google\Cloud\WorkloadManager\V1\Rule> - */ - public function getRules() - { - return $this->rules; - } - - /** - * All rules in response. - * - * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.Rule rules = 1; - * @param \Google\Cloud\WorkloadManager\V1\Rule[] $var - * @return $this - */ - public function setRules($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\WorkloadManager\V1\Rule::class); - $this->rules = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListScannedResourcesRequest.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListScannedResourcesRequest.php deleted file mode 100644 index 411c1cb6923a..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListScannedResourcesRequest.php +++ /dev/null @@ -1,254 +0,0 @@ -google.cloud.workloadmanager.v1.ListScannedResourcesRequest - */ -class ListScannedResourcesRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Parent for ListScannedResourcesRequest. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $parent = ''; - /** - * Rule name. - * - * Generated from protobuf field string rule = 2; - */ - protected $rule = ''; - /** - * 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 = 3; - */ - protected $page_size = 0; - /** - * A token identifying a page of results the server should return. - * - * Generated from protobuf field string page_token = 4; - */ - protected $page_token = ''; - /** - * Filtering results. - * - * Generated from protobuf field string filter = 5; - */ - protected $filter = ''; - /** - * Field to sort by. See https://google.aip.dev/132#ordering for more details. - * - * Generated from protobuf field string order_by = 6; - */ - protected $order_by = ''; - - /** - * @param string $parent Required. Parent for ListScannedResourcesRequest. - * - * @return \Google\Cloud\WorkloadManager\V1\ListScannedResourcesRequest - * - * @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 for ListScannedResourcesRequest. - * @type string $rule - * Rule name. - * @type int $page_size - * Requested page size. Server may return fewer items than requested. - * If unspecified, server will pick an appropriate default. - * @type string $page_token - * A token identifying a page of results the server should return. - * @type string $filter - * Filtering results. - * @type string $order_by - * Field to sort by. See https://google.aip.dev/132#ordering for more details. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Required. Parent for ListScannedResourcesRequest. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getParent() - { - return $this->parent; - } - - /** - * Required. Parent for ListScannedResourcesRequest. - * - * Generated from protobuf field string parent = 1 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setParent($var) - { - GPBUtil::checkString($var, True); - $this->parent = $var; - - return $this; - } - - /** - * Rule name. - * - * Generated from protobuf field string rule = 2; - * @return string - */ - public function getRule() - { - return $this->rule; - } - - /** - * Rule name. - * - * Generated from protobuf field string rule = 2; - * @param string $var - * @return $this - */ - public function setRule($var) - { - GPBUtil::checkString($var, True); - $this->rule = $var; - - return $this; - } - - /** - * 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 = 3; - * @return int - */ - public function getPageSize() - { - return $this->page_size; - } - - /** - * 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 = 3; - * @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 the server should return. - * - * Generated from protobuf field string page_token = 4; - * @return string - */ - public function getPageToken() - { - return $this->page_token; - } - - /** - * A token identifying a page of results the server should return. - * - * 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; - } - - /** - * Filtering results. - * - * Generated from protobuf field string filter = 5; - * @return string - */ - public function getFilter() - { - return $this->filter; - } - - /** - * Filtering results. - * - * Generated from protobuf field string filter = 5; - * @param string $var - * @return $this - */ - public function setFilter($var) - { - GPBUtil::checkString($var, True); - $this->filter = $var; - - return $this; - } - - /** - * Field to sort by. See https://google.aip.dev/132#ordering for more details. - * - * Generated from protobuf field string order_by = 6; - * @return string - */ - public function getOrderBy() - { - return $this->order_by; - } - - /** - * Field to sort by. See https://google.aip.dev/132#ordering for more details. - * - * Generated from protobuf field string order_by = 6; - * @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/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListScannedResourcesResponse.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListScannedResourcesResponse.php deleted file mode 100644 index 5af4157fe8bd..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ListScannedResourcesResponse.php +++ /dev/null @@ -1,105 +0,0 @@ -google.cloud.workloadmanager.v1.ListScannedResourcesResponse - */ -class ListScannedResourcesResponse extends \Google\Protobuf\Internal\Message -{ - /** - * All scanned resources in response. - * - * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.ScannedResource scanned_resources = 1; - */ - private $scanned_resources; - /** - * 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 \Google\Cloud\WorkloadManager\V1\ScannedResource[] $scanned_resources - * All scanned resources in response. - * @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\Workloadmanager\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * All scanned resources in response. - * - * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.ScannedResource scanned_resources = 1; - * @return RepeatedField<\Google\Cloud\WorkloadManager\V1\ScannedResource> - */ - public function getScannedResources() - { - return $this->scanned_resources; - } - - /** - * All scanned resources in response. - * - * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.ScannedResource scanned_resources = 1; - * @param \Google\Cloud\WorkloadManager\V1\ScannedResource[] $var - * @return $this - */ - public function setScannedResources($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\WorkloadManager\V1\ScannedResource::class); - $this->scanned_resources = $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/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/OperationMetadata.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/OperationMetadata.php deleted file mode 100644 index 67adbada707b..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/OperationMetadata.php +++ /dev/null @@ -1,307 +0,0 @@ -google.cloud.workloadmanager.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 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\Workloadmanager\V1\Service::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/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Resource.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Resource.php deleted file mode 100644 index 76f883092db6..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Resource.php +++ /dev/null @@ -1,135 +0,0 @@ -google.cloud.workloadmanager.v1.Resource - */ -class Resource extends \Google\Protobuf\Internal\Message -{ - /** - * The type of resource. - * - * Generated from protobuf field string type = 1; - */ - protected $type = ''; - /** - * The name of the resource. - * - * Generated from protobuf field string name = 2; - */ - protected $name = ''; - /** - * The service account associated with the resource. - * - * Generated from protobuf field string service_account = 3; - */ - protected $service_account = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $type - * The type of resource. - * @type string $name - * The name of the resource. - * @type string $service_account - * The service account associated with the resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * The type of resource. - * - * Generated from protobuf field string type = 1; - * @return string - */ - public function getType() - { - return $this->type; - } - - /** - * The type of resource. - * - * 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 name of the resource. - * - * Generated from protobuf field string name = 2; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * The name of the resource. - * - * 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 service account associated with the resource. - * - * Generated from protobuf field string service_account = 3; - * @return string - */ - public function getServiceAccount() - { - return $this->service_account; - } - - /** - * The service account associated with the resource. - * - * Generated from protobuf field string service_account = 3; - * @param string $var - * @return $this - */ - public function setServiceAccount($var) - { - GPBUtil::checkString($var, True); - $this->service_account = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ResourceFilter.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ResourceFilter.php deleted file mode 100644 index da38a03e068e..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ResourceFilter.php +++ /dev/null @@ -1,216 +0,0 @@ -google.cloud.workloadmanager.v1.ResourceFilter - */ -class ResourceFilter extends \Google\Protobuf\Internal\Message -{ - /** - * The scopes of evaluation resource. - * Format: - * * `projects/{project_id}` - * * `folders/{folder_id}` - * * `organizations/{organization_id}` - * - * Generated from protobuf field repeated string scopes = 1; - */ - private $scopes; - /** - * The pattern to filter resources by their id - * For example, a pattern of ".*prod-cluster.*" will match all resources that - * contain "prod-cluster" in their ID. - * - * Generated from protobuf field repeated string resource_id_patterns = 2; - */ - private $resource_id_patterns; - /** - * Labels to filter resources by. Each key-value pair in the map must exist - * on the resource for it to be included (e.g. VM instance labels). - * For example, specifying `{ "env": "prod", "database": "nosql" }` will only - * include resources that have labels `env=prod` and `database=nosql`. - * - * Generated from protobuf field map inclusion_labels = 3; - */ - private $inclusion_labels; - /** - * Filter compute engine resources. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.GceInstanceFilter gce_instance_filter = 4; - */ - protected $gce_instance_filter = null; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string[] $scopes - * The scopes of evaluation resource. - * Format: - * * `projects/{project_id}` - * * `folders/{folder_id}` - * * `organizations/{organization_id}` - * @type string[] $resource_id_patterns - * The pattern to filter resources by their id - * For example, a pattern of ".*prod-cluster.*" will match all resources that - * contain "prod-cluster" in their ID. - * @type array|\Google\Protobuf\Internal\MapField $inclusion_labels - * Labels to filter resources by. Each key-value pair in the map must exist - * on the resource for it to be included (e.g. VM instance labels). - * For example, specifying `{ "env": "prod", "database": "nosql" }` will only - * include resources that have labels `env=prod` and `database=nosql`. - * @type \Google\Cloud\WorkloadManager\V1\GceInstanceFilter $gce_instance_filter - * Filter compute engine resources. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * The scopes of evaluation resource. - * Format: - * * `projects/{project_id}` - * * `folders/{folder_id}` - * * `organizations/{organization_id}` - * - * Generated from protobuf field repeated string scopes = 1; - * @return RepeatedField - */ - public function getScopes() - { - return $this->scopes; - } - - /** - * The scopes of evaluation resource. - * Format: - * * `projects/{project_id}` - * * `folders/{folder_id}` - * * `organizations/{organization_id}` - * - * Generated from protobuf field repeated string scopes = 1; - * @param string[] $var - * @return $this - */ - public function setScopes($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->scopes = $arr; - - return $this; - } - - /** - * The pattern to filter resources by their id - * For example, a pattern of ".*prod-cluster.*" will match all resources that - * contain "prod-cluster" in their ID. - * - * Generated from protobuf field repeated string resource_id_patterns = 2; - * @return RepeatedField - */ - public function getResourceIdPatterns() - { - return $this->resource_id_patterns; - } - - /** - * The pattern to filter resources by their id - * For example, a pattern of ".*prod-cluster.*" will match all resources that - * contain "prod-cluster" in their ID. - * - * Generated from protobuf field repeated string resource_id_patterns = 2; - * @param string[] $var - * @return $this - */ - public function setResourceIdPatterns($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->resource_id_patterns = $arr; - - return $this; - } - - /** - * Labels to filter resources by. Each key-value pair in the map must exist - * on the resource for it to be included (e.g. VM instance labels). - * For example, specifying `{ "env": "prod", "database": "nosql" }` will only - * include resources that have labels `env=prod` and `database=nosql`. - * - * Generated from protobuf field map inclusion_labels = 3; - * @return \Google\Protobuf\Internal\MapField - */ - public function getInclusionLabels() - { - return $this->inclusion_labels; - } - - /** - * Labels to filter resources by. Each key-value pair in the map must exist - * on the resource for it to be included (e.g. VM instance labels). - * For example, specifying `{ "env": "prod", "database": "nosql" }` will only - * include resources that have labels `env=prod` and `database=nosql`. - * - * Generated from protobuf field map inclusion_labels = 3; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setInclusionLabels($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->inclusion_labels = $arr; - - return $this; - } - - /** - * Filter compute engine resources. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.GceInstanceFilter gce_instance_filter = 4; - * @return \Google\Cloud\WorkloadManager\V1\GceInstanceFilter|null - */ - public function getGceInstanceFilter() - { - return $this->gce_instance_filter; - } - - public function hasGceInstanceFilter() - { - return isset($this->gce_instance_filter); - } - - public function clearGceInstanceFilter() - { - unset($this->gce_instance_filter); - } - - /** - * Filter compute engine resources. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.GceInstanceFilter gce_instance_filter = 4; - * @param \Google\Cloud\WorkloadManager\V1\GceInstanceFilter $var - * @return $this - */ - public function setGceInstanceFilter($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\WorkloadManager\V1\GceInstanceFilter::class); - $this->gce_instance_filter = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ResourceStatus.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ResourceStatus.php deleted file mode 100644 index a0129371e9c3..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ResourceStatus.php +++ /dev/null @@ -1,67 +0,0 @@ -google.cloud.workloadmanager.v1.ResourceStatus - */ -class ResourceStatus extends \Google\Protobuf\Internal\Message -{ - /** - * State of the Evaluation resource. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.ResourceStatus.State state = 2; - */ - protected $state = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type int $state - * State of the Evaluation resource. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * State of the Evaluation resource. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.ResourceStatus.State state = 2; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * State of the Evaluation resource. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.ResourceStatus.State state = 2; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\WorkloadManager\V1\ResourceStatus\State::class); - $this->state = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ResourceStatus/State.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ResourceStatus/State.php deleted file mode 100644 index 2eb24634e00e..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ResourceStatus/State.php +++ /dev/null @@ -1,69 +0,0 @@ -google.cloud.workloadmanager.v1.ResourceStatus.State - */ -class State -{ - /** - * The state has not been populated in this message. - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * Resource has an active Create operation. - * - * Generated from protobuf enum CREATING = 1; - */ - const CREATING = 1; - /** - * Resource has no outstanding operations on it or has active Update - * operations. - * - * Generated from protobuf enum ACTIVE = 2; - */ - const ACTIVE = 2; - /** - * Resource has an active Delete operation. - * - * Generated from protobuf enum DELETING = 3; - */ - const DELETING = 3; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::CREATING => 'CREATING', - self::ACTIVE => 'ACTIVE', - 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); - } -} - diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Rule.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Rule.php deleted file mode 100644 index 103e66e66cb1..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Rule.php +++ /dev/null @@ -1,479 +0,0 @@ -google.cloud.workloadmanager.v1.Rule - */ -class Rule extends \Google\Protobuf\Internal\Message -{ - /** - * Rule name. - * - * Generated from protobuf field string name = 1; - */ - protected $name = ''; - /** - * Output only. The version of the rule. - * - * Generated from protobuf field string revision_id = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $revision_id = ''; - /** - * The name display in UI. - * - * Generated from protobuf field string display_name = 3; - */ - protected $display_name = ''; - /** - * Describe rule in plain language. - * - * Generated from protobuf field string description = 4; - */ - protected $description = ''; - /** - * The severity of the rule. - * - * Generated from protobuf field string severity = 5; - */ - protected $severity = ''; - /** - * The primary category. - * - * Generated from protobuf field string primary_category = 6; - */ - protected $primary_category = ''; - /** - * The secondary category. - * - * Generated from protobuf field string secondary_category = 7; - */ - protected $secondary_category = ''; - /** - * The message template for rule. - * - * Generated from protobuf field string error_message = 8; - */ - protected $error_message = ''; - /** - * The document url for the rule. - * - * Generated from protobuf field string uri = 9; - */ - protected $uri = ''; - /** - * The remediation for the rule. - * - * Generated from protobuf field string remediation = 10; - */ - protected $remediation = ''; - /** - * List of user-defined tags. - * - * Generated from protobuf field repeated string tags = 11; - */ - private $tags; - /** - * The type of the rule. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.Rule.RuleType rule_type = 12; - */ - protected $rule_type = 0; - /** - * The CAI asset type of the rule is evaluating, for joined asset types, it - * will be the corresponding primary asset types. - * - * Generated from protobuf field string asset_type = 13; - */ - protected $asset_type = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Rule name. - * @type string $revision_id - * Output only. The version of the rule. - * @type string $display_name - * The name display in UI. - * @type string $description - * Describe rule in plain language. - * @type string $severity - * The severity of the rule. - * @type string $primary_category - * The primary category. - * @type string $secondary_category - * The secondary category. - * @type string $error_message - * The message template for rule. - * @type string $uri - * The document url for the rule. - * @type string $remediation - * The remediation for the rule. - * @type string[] $tags - * List of user-defined tags. - * @type int $rule_type - * The type of the rule. - * @type string $asset_type - * The CAI asset type of the rule is evaluating, for joined asset types, it - * will be the corresponding primary asset types. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Rule name. - * - * Generated from protobuf field string name = 1; - * @return string - */ - public function getName() - { - return $this->name; - } - - /** - * Rule 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. The version of the rule. - * - * Generated from protobuf field string revision_id = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getRevisionId() - { - return $this->revision_id; - } - - /** - * Output only. The version of the rule. - * - * Generated from protobuf field string revision_id = 2 [(.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; - } - - /** - * The name display in UI. - * - * Generated from protobuf field string display_name = 3; - * @return string - */ - public function getDisplayName() - { - return $this->display_name; - } - - /** - * The name display in UI. - * - * Generated from protobuf field string display_name = 3; - * @param string $var - * @return $this - */ - public function setDisplayName($var) - { - GPBUtil::checkString($var, True); - $this->display_name = $var; - - return $this; - } - - /** - * Describe rule in plain language. - * - * Generated from protobuf field string description = 4; - * @return string - */ - public function getDescription() - { - return $this->description; - } - - /** - * Describe rule in plain language. - * - * Generated from protobuf field string description = 4; - * @param string $var - * @return $this - */ - public function setDescription($var) - { - GPBUtil::checkString($var, True); - $this->description = $var; - - return $this; - } - - /** - * The severity of the rule. - * - * Generated from protobuf field string severity = 5; - * @return string - */ - public function getSeverity() - { - return $this->severity; - } - - /** - * The severity of the rule. - * - * Generated from protobuf field string severity = 5; - * @param string $var - * @return $this - */ - public function setSeverity($var) - { - GPBUtil::checkString($var, True); - $this->severity = $var; - - return $this; - } - - /** - * The primary category. - * - * Generated from protobuf field string primary_category = 6; - * @return string - */ - public function getPrimaryCategory() - { - return $this->primary_category; - } - - /** - * The primary category. - * - * Generated from protobuf field string primary_category = 6; - * @param string $var - * @return $this - */ - public function setPrimaryCategory($var) - { - GPBUtil::checkString($var, True); - $this->primary_category = $var; - - return $this; - } - - /** - * The secondary category. - * - * Generated from protobuf field string secondary_category = 7; - * @return string - */ - public function getSecondaryCategory() - { - return $this->secondary_category; - } - - /** - * The secondary category. - * - * Generated from protobuf field string secondary_category = 7; - * @param string $var - * @return $this - */ - public function setSecondaryCategory($var) - { - GPBUtil::checkString($var, True); - $this->secondary_category = $var; - - return $this; - } - - /** - * The message template for rule. - * - * Generated from protobuf field string error_message = 8; - * @return string - */ - public function getErrorMessage() - { - return $this->error_message; - } - - /** - * The message template for rule. - * - * Generated from protobuf field string error_message = 8; - * @param string $var - * @return $this - */ - public function setErrorMessage($var) - { - GPBUtil::checkString($var, True); - $this->error_message = $var; - - return $this; - } - - /** - * The document url for the rule. - * - * Generated from protobuf field string uri = 9; - * @return string - */ - public function getUri() - { - return $this->uri; - } - - /** - * The document url for the rule. - * - * Generated from protobuf field string uri = 9; - * @param string $var - * @return $this - */ - public function setUri($var) - { - GPBUtil::checkString($var, True); - $this->uri = $var; - - return $this; - } - - /** - * The remediation for the rule. - * - * Generated from protobuf field string remediation = 10; - * @return string - */ - public function getRemediation() - { - return $this->remediation; - } - - /** - * The remediation for the rule. - * - * Generated from protobuf field string remediation = 10; - * @param string $var - * @return $this - */ - public function setRemediation($var) - { - GPBUtil::checkString($var, True); - $this->remediation = $var; - - return $this; - } - - /** - * List of user-defined tags. - * - * Generated from protobuf field repeated string tags = 11; - * @return RepeatedField - */ - public function getTags() - { - return $this->tags; - } - - /** - * List of user-defined tags. - * - * Generated from protobuf field repeated string tags = 11; - * @param string[] $var - * @return $this - */ - public function setTags($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::STRING); - $this->tags = $arr; - - return $this; - } - - /** - * The type of the rule. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.Rule.RuleType rule_type = 12; - * @return int - */ - public function getRuleType() - { - return $this->rule_type; - } - - /** - * The type of the rule. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.Rule.RuleType rule_type = 12; - * @param int $var - * @return $this - */ - public function setRuleType($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\WorkloadManager\V1\Rule\RuleType::class); - $this->rule_type = $var; - - return $this; - } - - /** - * The CAI asset type of the rule is evaluating, for joined asset types, it - * will be the corresponding primary asset types. - * - * Generated from protobuf field string asset_type = 13; - * @return string - */ - public function getAssetType() - { - return $this->asset_type; - } - - /** - * The CAI asset type of the rule is evaluating, for joined asset types, it - * will be the corresponding primary asset types. - * - * Generated from protobuf field string asset_type = 13; - * @param string $var - * @return $this - */ - public function setAssetType($var) - { - GPBUtil::checkString($var, True); - $this->asset_type = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Rule/RuleType.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Rule/RuleType.php deleted file mode 100644 index 41da1acddf5c..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/Rule/RuleType.php +++ /dev/null @@ -1,61 +0,0 @@ -google.cloud.workloadmanager.v1.Rule.RuleType - */ -class RuleType -{ - /** - * Not specified. - * - * Generated from protobuf enum RULE_TYPE_UNSPECIFIED = 0; - */ - const RULE_TYPE_UNSPECIFIED = 0; - /** - * Baseline rules. - * - * Generated from protobuf enum BASELINE = 1; - */ - const BASELINE = 1; - /** - * Custom rules. - * - * Generated from protobuf enum CUSTOM = 2; - */ - const CUSTOM = 2; - - private static $valueToName = [ - self::RULE_TYPE_UNSPECIFIED => 'RULE_TYPE_UNSPECIFIED', - self::BASELINE => 'BASELINE', - self::CUSTOM => 'CUSTOM', - ]; - - 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/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/RuleExecutionResult.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/RuleExecutionResult.php deleted file mode 100644 index 92f0d8f39dc8..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/RuleExecutionResult.php +++ /dev/null @@ -1,203 +0,0 @@ -google.cloud.workloadmanager.v1.RuleExecutionResult - */ -class RuleExecutionResult extends \Google\Protobuf\Internal\Message -{ - /** - * Rule name as plain text like `sap-hana-configured`. - * - * Generated from protobuf field string rule = 1; - */ - protected $rule = ''; - /** - * Output only. The execution status. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.RuleExecutionResult.State state = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $state = 0; - /** - * Execution message, if any. - * - * Generated from protobuf field string message = 3; - */ - protected $message = ''; - /** - * Number of violations. - * - * Generated from protobuf field int64 result_count = 4; - */ - protected $result_count = 0; - /** - * Number of total scanned resources. - * - * Generated from protobuf field int64 scanned_resource_count = 5; - */ - protected $scanned_resource_count = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $rule - * Rule name as plain text like `sap-hana-configured`. - * @type int $state - * Output only. The execution status. - * @type string $message - * Execution message, if any. - * @type int|string $result_count - * Number of violations. - * @type int|string $scanned_resource_count - * Number of total scanned resources. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Rule name as plain text like `sap-hana-configured`. - * - * Generated from protobuf field string rule = 1; - * @return string - */ - public function getRule() - { - return $this->rule; - } - - /** - * Rule name as plain text like `sap-hana-configured`. - * - * Generated from protobuf field string rule = 1; - * @param string $var - * @return $this - */ - public function setRule($var) - { - GPBUtil::checkString($var, True); - $this->rule = $var; - - return $this; - } - - /** - * Output only. The execution status. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.RuleExecutionResult.State state = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return int - */ - public function getState() - { - return $this->state; - } - - /** - * Output only. The execution status. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.RuleExecutionResult.State state = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param int $var - * @return $this - */ - public function setState($var) - { - GPBUtil::checkEnum($var, \Google\Cloud\WorkloadManager\V1\RuleExecutionResult\State::class); - $this->state = $var; - - return $this; - } - - /** - * Execution message, if any. - * - * Generated from protobuf field string message = 3; - * @return string - */ - public function getMessage() - { - return $this->message; - } - - /** - * Execution message, if any. - * - * Generated from protobuf field string message = 3; - * @param string $var - * @return $this - */ - public function setMessage($var) - { - GPBUtil::checkString($var, True); - $this->message = $var; - - return $this; - } - - /** - * Number of violations. - * - * Generated from protobuf field int64 result_count = 4; - * @return int|string - */ - public function getResultCount() - { - return $this->result_count; - } - - /** - * Number of violations. - * - * Generated from protobuf field int64 result_count = 4; - * @param int|string $var - * @return $this - */ - public function setResultCount($var) - { - GPBUtil::checkInt64($var); - $this->result_count = $var; - - return $this; - } - - /** - * Number of total scanned resources. - * - * Generated from protobuf field int64 scanned_resource_count = 5; - * @return int|string - */ - public function getScannedResourceCount() - { - return $this->scanned_resource_count; - } - - /** - * Number of total scanned resources. - * - * Generated from protobuf field int64 scanned_resource_count = 5; - * @param int|string $var - * @return $this - */ - public function setScannedResourceCount($var) - { - GPBUtil::checkInt64($var); - $this->scanned_resource_count = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/RuleExecutionResult/State.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/RuleExecutionResult/State.php deleted file mode 100644 index 1adc3db3ba48..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/RuleExecutionResult/State.php +++ /dev/null @@ -1,68 +0,0 @@ -google.cloud.workloadmanager.v1.RuleExecutionResult.State - */ -class State -{ - /** - * Unknown state - * - * Generated from protobuf enum STATE_UNSPECIFIED = 0; - */ - const STATE_UNSPECIFIED = 0; - /** - * Execution completed successfully - * - * Generated from protobuf enum STATE_SUCCESS = 1; - */ - const STATE_SUCCESS = 1; - /** - * Execution completed with failures - * - * Generated from protobuf enum STATE_FAILURE = 2; - */ - const STATE_FAILURE = 2; - /** - * Execution was not executed - * - * Generated from protobuf enum STATE_SKIPPED = 3; - */ - const STATE_SKIPPED = 3; - - private static $valueToName = [ - self::STATE_UNSPECIFIED => 'STATE_UNSPECIFIED', - self::STATE_SUCCESS => 'STATE_SUCCESS', - self::STATE_FAILURE => 'STATE_FAILURE', - self::STATE_SKIPPED => 'STATE_SKIPPED', - ]; - - 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/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/RuleOutput.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/RuleOutput.php deleted file mode 100644 index 28f1ea969edf..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/RuleOutput.php +++ /dev/null @@ -1,101 +0,0 @@ -google.cloud.workloadmanager.v1.RuleOutput - */ -class RuleOutput extends \Google\Protobuf\Internal\Message -{ - /** - * Output only. Violation details generated by rule. - * - * Generated from protobuf field map details = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - private $details; - /** - * Output only. The message generated by rule. - * - * Generated from protobuf field string message = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - protected $message = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type array|\Google\Protobuf\Internal\MapField $details - * Output only. Violation details generated by rule. - * @type string $message - * Output only. The message generated by rule. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Output only. Violation details generated by rule. - * - * Generated from protobuf field map details = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return \Google\Protobuf\Internal\MapField - */ - public function getDetails() - { - return $this->details; - } - - /** - * Output only. Violation details generated by rule. - * - * Generated from protobuf field map details = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setDetails($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->details = $arr; - - return $this; - } - - /** - * Output only. The message generated by rule. - * - * Generated from protobuf field string message = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return string - */ - public function getMessage() - { - return $this->message; - } - - /** - * Output only. The message generated by rule. - * - * 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; - } - -} - diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/RunEvaluationRequest.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/RunEvaluationRequest.php deleted file mode 100644 index e5ba45787979..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/RunEvaluationRequest.php +++ /dev/null @@ -1,242 +0,0 @@ -google.cloud.workloadmanager.v1.RunEvaluationRequest - */ -class RunEvaluationRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. The resource name of the Evaluation using the form: - * `projects/{project}/locations/{location}/evaluations/{evaluation}`. - * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { - */ - protected $name = ''; - /** - * Required. ID of the execution which will be created. - * - * Generated from protobuf field string execution_id = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $execution_id = ''; - /** - * Required. The resource being created. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.Execution execution = 3 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $execution = 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 $name Required. The resource name of the Evaluation using the form: - * `projects/{project}/locations/{location}/evaluations/{evaluation}`. Please see - * {@see WorkloadManagerClient::evaluationName()} for help formatting this field. - * @param \Google\Cloud\WorkloadManager\V1\Execution $execution Required. The resource being created. - * @param string $executionId Required. ID of the execution which will be created. - * - * @return \Google\Cloud\WorkloadManager\V1\RunEvaluationRequest - * - * @experimental - */ - public static function build(string $name, \Google\Cloud\WorkloadManager\V1\Execution $execution, string $executionId): self - { - return (new self()) - ->setName($name) - ->setExecution($execution) - ->setExecutionId($executionId); - } - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $name - * Required. The resource name of the Evaluation using the form: - * `projects/{project}/locations/{location}/evaluations/{evaluation}`. - * @type string $execution_id - * Required. ID of the execution which will be created. - * @type \Google\Cloud\WorkloadManager\V1\Execution $execution - * 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 - * 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\Workloadmanager\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Required. The resource name of the Evaluation using the form: - * `projects/{project}/locations/{location}/evaluations/{evaluation}`. - * - * 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 Evaluation using the form: - * `projects/{project}/locations/{location}/evaluations/{evaluation}`. - * - * 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. ID of the execution which will be created. - * - * Generated from protobuf field string execution_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return string - */ - public function getExecutionId() - { - return $this->execution_id; - } - - /** - * Required. ID of the execution which will be created. - * - * Generated from protobuf field string execution_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param string $var - * @return $this - */ - public function setExecutionId($var) - { - GPBUtil::checkString($var, True); - $this->execution_id = $var; - - return $this; - } - - /** - * Required. The resource being created. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.Execution execution = 3 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\WorkloadManager\V1\Execution|null - */ - public function getExecution() - { - return $this->execution; - } - - public function hasExecution() - { - return isset($this->execution); - } - - public function clearExecution() - { - unset($this->execution); - } - - /** - * Required. The resource being created. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.Execution execution = 3 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\WorkloadManager\V1\Execution $var - * @return $this - */ - public function setExecution($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\WorkloadManager\V1\Execution::class); - $this->execution = $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/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ScannedResource.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ScannedResource.php deleted file mode 100644 index 3d841554e1ac..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ScannedResource.php +++ /dev/null @@ -1,101 +0,0 @@ -google.cloud.workloadmanager.v1.ScannedResource - */ -class ScannedResource extends \Google\Protobuf\Internal\Message -{ - /** - * Resource name. - * - * Generated from protobuf field string resource = 1; - */ - protected $resource = ''; - /** - * Resource type. - * - * Generated from protobuf field string type = 2; - */ - protected $type = ''; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $resource - * Resource name. - * @type string $type - * Resource type. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Resource name. - * - * Generated from protobuf field string resource = 1; - * @return string - */ - public function getResource() - { - return $this->resource; - } - - /** - * Resource name. - * - * Generated from protobuf field string resource = 1; - * @param string $var - * @return $this - */ - public function setResource($var) - { - GPBUtil::checkString($var, True); - $this->resource = $var; - - return $this; - } - - /** - * Resource type. - * - * Generated from protobuf field string type = 2; - * @return string - */ - public function getType() - { - return $this->type; - } - - /** - * Resource type. - * - * 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; - } - -} - diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ShellCommand.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ShellCommand.php deleted file mode 100644 index d862e692f53a..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ShellCommand.php +++ /dev/null @@ -1,135 +0,0 @@ -google.cloud.workloadmanager.v1.ShellCommand - */ -class ShellCommand extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the command to be executed. - * - * Generated from protobuf field string command = 1; - */ - protected $command = ''; - /** - * Arguments to be passed to the command. - * - * Generated from protobuf field string args = 2; - */ - protected $args = ''; - /** - * Optional. If not specified, the default timeout is 60 seconds. - * - * Generated from protobuf field int32 timeout_seconds = 3; - */ - protected $timeout_seconds = 0; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $command - * The name of the command to be executed. - * @type string $args - * Arguments to be passed to the command. - * @type int $timeout_seconds - * Optional. If not specified, the default timeout is 60 seconds. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * The name of the command to be executed. - * - * Generated from protobuf field string command = 1; - * @return string - */ - public function getCommand() - { - return $this->command; - } - - /** - * The name of the command to be executed. - * - * Generated from protobuf field string command = 1; - * @param string $var - * @return $this - */ - public function setCommand($var) - { - GPBUtil::checkString($var, True); - $this->command = $var; - - return $this; - } - - /** - * Arguments to be passed to the command. - * - * Generated from protobuf field string args = 2; - * @return string - */ - public function getArgs() - { - return $this->args; - } - - /** - * Arguments to be passed to the command. - * - * Generated from protobuf field string args = 2; - * @param string $var - * @return $this - */ - public function setArgs($var) - { - GPBUtil::checkString($var, True); - $this->args = $var; - - return $this; - } - - /** - * Optional. If not specified, the default timeout is 60 seconds. - * - * Generated from protobuf field int32 timeout_seconds = 3; - * @return int - */ - public function getTimeoutSeconds() - { - return $this->timeout_seconds; - } - - /** - * Optional. If not specified, the default timeout is 60 seconds. - * - * Generated from protobuf field int32 timeout_seconds = 3; - * @param int $var - * @return $this - */ - public function setTimeoutSeconds($var) - { - GPBUtil::checkInt32($var); - $this->timeout_seconds = $var; - - return $this; - } - -} - diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/UpdateEvaluationRequest.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/UpdateEvaluationRequest.php deleted file mode 100644 index 39206bd970f6..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/UpdateEvaluationRequest.php +++ /dev/null @@ -1,225 +0,0 @@ -google.cloud.workloadmanager.v1.UpdateEvaluationRequest - */ -class UpdateEvaluationRequest extends \Google\Protobuf\Internal\Message -{ - /** - * Required. Field mask is used to specify the fields to be overwritten in the - * Evaluation 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. - * - * 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.workloadmanager.v1.Evaluation evaluation = 2 [(.google.api.field_behavior) = REQUIRED]; - */ - protected $evaluation = 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 = 3 [(.google.api.field_behavior) = OPTIONAL]; - */ - protected $request_id = ''; - - /** - * @param \Google\Cloud\WorkloadManager\V1\Evaluation $evaluation Required. The resource being updated. - * @param \Google\Protobuf\FieldMask $updateMask Required. Field mask is used to specify the fields to be overwritten in the - * Evaluation 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. - * - * @return \Google\Cloud\WorkloadManager\V1\UpdateEvaluationRequest - * - * @experimental - */ - public static function build(\Google\Cloud\WorkloadManager\V1\Evaluation $evaluation, \Google\Protobuf\FieldMask $updateMask): self - { - return (new self()) - ->setEvaluation($evaluation) - ->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 - * Evaluation 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. - * @type \Google\Cloud\WorkloadManager\V1\Evaluation $evaluation - * 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 - * 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\Workloadmanager\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * Required. Field mask is used to specify the fields to be overwritten in the - * Evaluation 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. - * - * 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 - * Evaluation 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. - * - * 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.workloadmanager.v1.Evaluation evaluation = 2 [(.google.api.field_behavior) = REQUIRED]; - * @return \Google\Cloud\WorkloadManager\V1\Evaluation|null - */ - public function getEvaluation() - { - return $this->evaluation; - } - - public function hasEvaluation() - { - return isset($this->evaluation); - } - - public function clearEvaluation() - { - unset($this->evaluation); - } - - /** - * Required. The resource being updated. - * - * Generated from protobuf field .google.cloud.workloadmanager.v1.Evaluation evaluation = 2 [(.google.api.field_behavior) = REQUIRED]; - * @param \Google\Cloud\WorkloadManager\V1\Evaluation $var - * @return $this - */ - public function setEvaluation($var) - { - GPBUtil::checkMessage($var, \Google\Cloud\WorkloadManager\V1\Evaluation::class); - $this->evaluation = $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 = 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 - * 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 = 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; - } - -} - diff --git a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ViolationDetails.php b/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ViolationDetails.php deleted file mode 100644 index fd2bd3f72e67..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/proto/src/Google/Cloud/WorkloadManager/V1/ViolationDetails.php +++ /dev/null @@ -1,169 +0,0 @@ -google.cloud.workloadmanager.v1.ViolationDetails - */ -class ViolationDetails extends \Google\Protobuf\Internal\Message -{ - /** - * The name of the asset. - * - * Generated from protobuf field string asset = 1; - */ - protected $asset = ''; - /** - * The service account associated with the resource. - * - * Generated from protobuf field string service_account = 2; - */ - protected $service_account = ''; - /** - * Details of the violation. - * - * Generated from protobuf field map observed = 3; - */ - private $observed; - /** - * Output only. The rule output of the violation. - * - * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.RuleOutput rule_output = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - */ - private $rule_output; - - /** - * Constructor. - * - * @param array $data { - * Optional. Data for populating the Message object. - * - * @type string $asset - * The name of the asset. - * @type string $service_account - * The service account associated with the resource. - * @type array|\Google\Protobuf\Internal\MapField $observed - * Details of the violation. - * @type \Google\Cloud\WorkloadManager\V1\RuleOutput[] $rule_output - * Output only. The rule output of the violation. - * } - */ - public function __construct($data = NULL) { - \GPBMetadata\Google\Cloud\Workloadmanager\V1\Service::initOnce(); - parent::__construct($data); - } - - /** - * The name of the asset. - * - * Generated from protobuf field string asset = 1; - * @return string - */ - public function getAsset() - { - return $this->asset; - } - - /** - * The name of the asset. - * - * Generated from protobuf field string asset = 1; - * @param string $var - * @return $this - */ - public function setAsset($var) - { - GPBUtil::checkString($var, True); - $this->asset = $var; - - return $this; - } - - /** - * The service account associated with the resource. - * - * Generated from protobuf field string service_account = 2; - * @return string - */ - public function getServiceAccount() - { - return $this->service_account; - } - - /** - * The service account associated with the resource. - * - * Generated from protobuf field string service_account = 2; - * @param string $var - * @return $this - */ - public function setServiceAccount($var) - { - GPBUtil::checkString($var, True); - $this->service_account = $var; - - return $this; - } - - /** - * Details of the violation. - * - * Generated from protobuf field map observed = 3; - * @return \Google\Protobuf\Internal\MapField - */ - public function getObserved() - { - return $this->observed; - } - - /** - * Details of the violation. - * - * Generated from protobuf field map observed = 3; - * @param array|\Google\Protobuf\Internal\MapField $var - * @return $this - */ - public function setObserved($var) - { - $arr = GPBUtil::checkMapField($var, \Google\Protobuf\Internal\GPBType::STRING, \Google\Protobuf\Internal\GPBType::STRING); - $this->observed = $arr; - - return $this; - } - - /** - * Output only. The rule output of the violation. - * - * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.RuleOutput rule_output = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @return RepeatedField<\Google\Cloud\WorkloadManager\V1\RuleOutput> - */ - public function getRuleOutput() - { - return $this->rule_output; - } - - /** - * Output only. The rule output of the violation. - * - * Generated from protobuf field repeated .google.cloud.workloadmanager.v1.RuleOutput rule_output = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * @param \Google\Cloud\WorkloadManager\V1\RuleOutput[] $var - * @return $this - */ - public function setRuleOutput($var) - { - $arr = GPBUtil::checkRepeatedField($var, \Google\Protobuf\Internal\GPBType::MESSAGE, \Google\Cloud\WorkloadManager\V1\RuleOutput::class); - $this->rule_output = $arr; - - return $this; - } - -} - diff --git a/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/create_evaluation.php b/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/create_evaluation.php deleted file mode 100644 index 946ff96e3de8..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/create_evaluation.php +++ /dev/null @@ -1,89 +0,0 @@ -setParent($formattedParent) - ->setEvaluationId($evaluationId) - ->setEvaluation($evaluation); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $workloadManagerClient->createEvaluation($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var Evaluation $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 = WorkloadManagerClient::locationName('[PROJECT]', '[LOCATION]'); - $evaluationId = '[EVALUATION_ID]'; - - create_evaluation_sample($formattedParent, $evaluationId); -} -// [END workloadmanager_v1_generated_WorkloadManager_CreateEvaluation_sync] diff --git a/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/delete_evaluation.php b/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/delete_evaluation.php deleted file mode 100644 index cf7e883c5513..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/delete_evaluation.php +++ /dev/null @@ -1,80 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $workloadManagerClient->deleteEvaluation($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 = WorkloadManagerClient::evaluationName('[PROJECT]', '[LOCATION]', '[EVALUATION]'); - - delete_evaluation_sample($formattedName); -} -// [END workloadmanager_v1_generated_WorkloadManager_DeleteEvaluation_sync] diff --git a/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/delete_execution.php b/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/delete_execution.php deleted file mode 100644 index 1b42923f0bc6..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/delete_execution.php +++ /dev/null @@ -1,85 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $workloadManagerClient->deleteExecution($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 = WorkloadManagerClient::executionName( - '[PROJECT]', - '[LOCATION]', - '[EVALUATION]', - '[EXECUTION]' - ); - - delete_execution_sample($formattedName); -} -// [END workloadmanager_v1_generated_WorkloadManager_DeleteExecution_sync] diff --git a/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/get_evaluation.php b/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/get_evaluation.php deleted file mode 100644 index 928dcd7349ce..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/get_evaluation.php +++ /dev/null @@ -1,71 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var Evaluation $response */ - $response = $workloadManagerClient->getEvaluation($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 = WorkloadManagerClient::evaluationName('[PROJECT]', '[LOCATION]', '[EVALUATION]'); - - get_evaluation_sample($formattedName); -} -// [END workloadmanager_v1_generated_WorkloadManager_GetEvaluation_sync] diff --git a/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/get_execution.php b/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/get_execution.php deleted file mode 100644 index e6490eed3403..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/get_execution.php +++ /dev/null @@ -1,76 +0,0 @@ -setName($formattedName); - - // Call the API and handle any network failures. - try { - /** @var Execution $response */ - $response = $workloadManagerClient->getExecution($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 = WorkloadManagerClient::executionName( - '[PROJECT]', - '[LOCATION]', - '[EVALUATION]', - '[EXECUTION]' - ); - - get_execution_sample($formattedName); -} -// [END workloadmanager_v1_generated_WorkloadManager_GetExecution_sync] diff --git a/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/get_location.php b/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/get_location.php deleted file mode 100644 index 4dd8e78e641d..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/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 workloadmanager_v1_generated_WorkloadManager_GetLocation_sync] diff --git a/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_evaluations.php b/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_evaluations.php deleted file mode 100644 index 1edf71c9733b..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_evaluations.php +++ /dev/null @@ -1,76 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $workloadManagerClient->listEvaluations($request); - - /** @var Evaluation $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 = WorkloadManagerClient::locationName('[PROJECT]', '[LOCATION]'); - - list_evaluations_sample($formattedParent); -} -// [END workloadmanager_v1_generated_WorkloadManager_ListEvaluations_sync] diff --git a/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_execution_results.php b/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_execution_results.php deleted file mode 100644 index 10119be227df..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_execution_results.php +++ /dev/null @@ -1,76 +0,0 @@ -setParent($parent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $workloadManagerClient->listExecutionResults($request); - - /** @var ExecutionResult $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $parent = '[PARENT]'; - - list_execution_results_sample($parent); -} -// [END workloadmanager_v1_generated_WorkloadManager_ListExecutionResults_sync] diff --git a/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_executions.php b/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_executions.php deleted file mode 100644 index 77c8445d1031..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_executions.php +++ /dev/null @@ -1,77 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $workloadManagerClient->listExecutions($request); - - /** @var Execution $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 = WorkloadManagerClient::evaluationName('[PROJECT]', '[LOCATION]', '[EVALUATION]'); - - list_executions_sample($formattedParent); -} -// [END workloadmanager_v1_generated_WorkloadManager_ListExecutions_sync] diff --git a/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_locations.php b/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_locations.php deleted file mode 100644 index f8541e067d2d..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_locations.php +++ /dev/null @@ -1,69 +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 workloadmanager_v1_generated_WorkloadManager_ListLocations_sync] diff --git a/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_rules.php b/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_rules.php deleted file mode 100644 index 6f635458dbaf..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_rules.php +++ /dev/null @@ -1,74 +0,0 @@ -setParent($formattedParent); - - // Call the API and handle any network failures. - try { - /** @var ListRulesResponse $response */ - $response = $workloadManagerClient->listRules($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 = WorkloadManagerClient::locationName('[PROJECT]', '[LOCATION]'); - - list_rules_sample($formattedParent); -} -// [END workloadmanager_v1_generated_WorkloadManager_ListRules_sync] diff --git a/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_scanned_resources.php b/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_scanned_resources.php deleted file mode 100644 index c130916085f8..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/list_scanned_resources.php +++ /dev/null @@ -1,75 +0,0 @@ -setParent($parent); - - // Call the API and handle any network failures. - try { - /** @var PagedListResponse $response */ - $response = $workloadManagerClient->listScannedResources($request); - - /** @var ScannedResource $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} - -/** - * Helper to execute the sample. - * - * This sample has been automatically generated and should be regarded as a code - * template only. It will require modifications to work: - * - It may require correct/in-range values for request initialization. - * - It may require specifying regional endpoints when creating the service client, - * please see the apiEndpoint client configuration option for more details. - */ -function callSample(): void -{ - $parent = '[PARENT]'; - - list_scanned_resources_sample($parent); -} -// [END workloadmanager_v1_generated_WorkloadManager_ListScannedResources_sync] diff --git a/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/run_evaluation.php b/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/run_evaluation.php deleted file mode 100644 index 321c5b2c2235..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/run_evaluation.php +++ /dev/null @@ -1,89 +0,0 @@ -setName($formattedName) - ->setExecutionId($executionId) - ->setExecution($execution); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $workloadManagerClient->runEvaluation($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var Execution $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 = WorkloadManagerClient::evaluationName('[PROJECT]', '[LOCATION]', '[EVALUATION]'); - $executionId = '[EXECUTION_ID]'; - - run_evaluation_sample($formattedName, $executionId); -} -// [END workloadmanager_v1_generated_WorkloadManager_RunEvaluation_sync] diff --git a/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/update_evaluation.php b/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/update_evaluation.php deleted file mode 100644 index 7621109e30c8..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/samples/V1/WorkloadManagerClient/update_evaluation.php +++ /dev/null @@ -1,74 +0,0 @@ -setUpdateMask($updateMask) - ->setEvaluation($evaluation); - - // Call the API and handle any network failures. - try { - /** @var OperationResponse $response */ - $response = $workloadManagerClient->updateEvaluation($request); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var Evaluation $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 workloadmanager_v1_generated_WorkloadManager_UpdateEvaluation_sync] diff --git a/owl-bot-staging/WorkloadManager/v1/src/V1/Client/WorkloadManagerClient.php b/owl-bot-staging/WorkloadManager/v1/src/V1/Client/WorkloadManagerClient.php deleted file mode 100644 index 41c8cf3466c8..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/src/V1/Client/WorkloadManagerClient.php +++ /dev/null @@ -1,747 +0,0 @@ - createEvaluationAsync(CreateEvaluationRequest $request, array $optionalArgs = []) - * @method PromiseInterface deleteEvaluationAsync(DeleteEvaluationRequest $request, array $optionalArgs = []) - * @method PromiseInterface deleteExecutionAsync(DeleteExecutionRequest $request, array $optionalArgs = []) - * @method PromiseInterface getEvaluationAsync(GetEvaluationRequest $request, array $optionalArgs = []) - * @method PromiseInterface getExecutionAsync(GetExecutionRequest $request, array $optionalArgs = []) - * @method PromiseInterface listEvaluationsAsync(ListEvaluationsRequest $request, array $optionalArgs = []) - * @method PromiseInterface listExecutionResultsAsync(ListExecutionResultsRequest $request, array $optionalArgs = []) - * @method PromiseInterface listExecutionsAsync(ListExecutionsRequest $request, array $optionalArgs = []) - * @method PromiseInterface listRulesAsync(ListRulesRequest $request, array $optionalArgs = []) - * @method PromiseInterface listScannedResourcesAsync(ListScannedResourcesRequest $request, array $optionalArgs = []) - * @method PromiseInterface runEvaluationAsync(RunEvaluationRequest $request, array $optionalArgs = []) - * @method PromiseInterface updateEvaluationAsync(UpdateEvaluationRequest $request, array $optionalArgs = []) - * @method PromiseInterface getLocationAsync(GetLocationRequest $request, array $optionalArgs = []) - * @method PromiseInterface listLocationsAsync(ListLocationsRequest $request, array $optionalArgs = []) - */ -final class WorkloadManagerClient -{ - use GapicClientTrait; - use ResourceHelperTrait; - - /** The name of the service. */ - private const SERVICE_NAME = 'google.cloud.workloadmanager.v1.WorkloadManager'; - - /** - * The default address of the service. - * - * @deprecated SERVICE_ADDRESS_TEMPLATE should be used instead. - */ - private const SERVICE_ADDRESS = 'workloadmanager.googleapis.com'; - - /** The address template of the service. */ - private const SERVICE_ADDRESS_TEMPLATE = 'workloadmanager.UNIVERSE_DOMAIN'; - - /** The default port of the service. */ - private const DEFAULT_SERVICE_PORT = 443; - - /** The name of the code generator, to be included in the agent header. */ - private const CODEGEN_NAME = 'gapic'; - - /** The default scopes required by the service. */ - public static $serviceScopes = [ - 'https://www.googleapis.com/auth/cloud-platform', - ]; - - private $operationsClient; - - private static function getClientDefaults() - { - return [ - 'serviceName' => self::SERVICE_NAME, - 'apiEndpoint' => self::SERVICE_ADDRESS . ':' . self::DEFAULT_SERVICE_PORT, - 'clientConfig' => __DIR__ . '/../resources/workload_manager_client_config.json', - 'descriptorsConfigPath' => __DIR__ . '/../resources/workload_manager_descriptor_config.php', - 'gcpApiConfigPath' => __DIR__ . '/../resources/workload_manager_grpc_config.json', - 'credentialsConfig' => [ - 'defaultScopes' => self::$serviceScopes, - ], - 'transportConfig' => [ - 'rest' => [ - 'restClientConfigPath' => __DIR__ . '/../resources/workload_manager_rest_client_config.php', - ], - ], - ]; - } - - /** - * 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 = $this->descriptors[$methodName]['longRunning'] ?? []; - $operation = new OperationResponse($operationName, $this->getOperationsClient(), $options); - $operation->reload(); - return $operation; - } - - /** - * Create the default operation client for the service. - * - * @param array $options ClientOptions for the client. - * - * @return OperationsClient - */ - private function createOperationsClient(array $options) - { - // Unset client-specific configuration options - unset($options['serviceName'], $options['clientConfig'], $options['descriptorsConfigPath']); - - if (isset($options['operationsClient'])) { - return $options['operationsClient']; - } - - return new OperationsClient($options); - } - - /** - * 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(string $project, string $location, string $keyRing, string $cryptoKey): string - { - return self::getPathTemplate('cryptoKey')->render([ - 'project' => $project, - 'location' => $location, - 'key_ring' => $keyRing, - 'crypto_key' => $cryptoKey, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a evaluation - * resource. - * - * @param string $project - * @param string $location - * @param string $evaluation - * - * @return string The formatted evaluation resource. - */ - public static function evaluationName(string $project, string $location, string $evaluation): string - { - return self::getPathTemplate('evaluation')->render([ - 'project' => $project, - 'location' => $location, - 'evaluation' => $evaluation, - ]); - } - - /** - * Formats a string containing the fully-qualified path to represent a execution - * resource. - * - * @param string $project - * @param string $location - * @param string $evaluation - * @param string $execution - * - * @return string The formatted execution resource. - */ - public static function executionName(string $project, string $location, string $evaluation, string $execution): string - { - return self::getPathTemplate('execution')->render([ - 'project' => $project, - 'location' => $location, - 'evaluation' => $evaluation, - 'execution' => $execution, - ]); - } - - /** - * 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(string $project, string $location): string - { - return self::getPathTemplate('location')->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} - * - evaluation: projects/{project}/locations/{location}/evaluations/{evaluation} - * - execution: projects/{project}/locations/{location}/evaluations/{evaluation}/executions/{execution} - * - 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(string $formattedName, ?string $template = null): array - { - return self::parseFormattedName($formattedName, $template); - } - - /** - * Constructor. - * - * @param array|ClientOptions $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 'workloadmanager.googleapis.com:443'. - * @type FetchAuthTokenInterface|CredentialsWrapper $credentials - * This option should only be used with a pre-constructed - * {@see FetchAuthTokenInterface} or {@see CredentialsWrapper} object. Note that - * when one of these objects are provided, any settings in $credentialsConfig will - * be ignored. - * **Important**: If you are providing a path to a credentials file, or a decoded - * credentials file as a PHP array, this usage is now DEPRECATED. Providing an - * unvalidated credential configuration to Google APIs can compromise the security - * of your systems and data. It is recommended to create the credentials explicitly - * ``` - * use Google\Auth\Credentials\ServiceAccountCredentials; - * use Google\Cloud\WorkloadManager\V1\WorkloadManagerClient; - * $creds = new ServiceAccountCredentials($scopes, $json); - * $options = new WorkloadManagerClient(['credentials' => $creds]); - * ``` - * {@see - * https://cloud.google.com/docs/authentication/external/externally-sourced-credentials} - * @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. - * @type false|LoggerInterface $logger - * A PSR-3 compliant logger. If set to false, logging is disabled, ignoring the - * 'GOOGLE_SDK_PHP_LOGGING' environment flag - * @type string $universeDomain - * The service domain for the client. Defaults to 'googleapis.com'. - * } - * - * @throws ValidationException - */ - public function __construct(array|ClientOptions $options = []) - { - $clientOptions = $this->buildClientOptions($options); - $this->setClientOptions($clientOptions); - $this->operationsClient = $this->createOperationsClient($clientOptions); - } - - /** Handles execution of the async variants for each documented method. */ - public function __call($method, $args) - { - if (substr($method, -5) !== 'Async') { - trigger_error('Call to undefined method ' . __CLASS__ . "::$method()", E_USER_ERROR); - } - - array_unshift($args, substr($method, 0, -5)); - return call_user_func_array([$this, 'startAsyncCall'], $args); - } - - /** - * Creates a new Evaluation in a given project and location. - * - * The async variant is {@see WorkloadManagerClient::createEvaluationAsync()} . - * - * @example samples/V1/WorkloadManagerClient/create_evaluation.php - * - * @param CreateEvaluationRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function createEvaluation(CreateEvaluationRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('CreateEvaluation', $request, $callOptions)->wait(); - } - - /** - * Deletes a single Evaluation. - * - * The async variant is {@see WorkloadManagerClient::deleteEvaluationAsync()} . - * - * @example samples/V1/WorkloadManagerClient/delete_evaluation.php - * - * @param DeleteEvaluationRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function deleteEvaluation(DeleteEvaluationRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('DeleteEvaluation', $request, $callOptions)->wait(); - } - - /** - * Deletes a single Execution. - * - * The async variant is {@see WorkloadManagerClient::deleteExecutionAsync()} . - * - * @example samples/V1/WorkloadManagerClient/delete_execution.php - * - * @param DeleteExecutionRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function deleteExecution(DeleteExecutionRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('DeleteExecution', $request, $callOptions)->wait(); - } - - /** - * Gets details of a single Evaluation. - * - * The async variant is {@see WorkloadManagerClient::getEvaluationAsync()} . - * - * @example samples/V1/WorkloadManagerClient/get_evaluation.php - * - * @param GetEvaluationRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Evaluation - * - * @throws ApiException Thrown if the API call fails. - */ - public function getEvaluation(GetEvaluationRequest $request, array $callOptions = []): Evaluation - { - return $this->startApiCall('GetEvaluation', $request, $callOptions)->wait(); - } - - /** - * Gets details of a single Execution. - * - * The async variant is {@see WorkloadManagerClient::getExecutionAsync()} . - * - * @example samples/V1/WorkloadManagerClient/get_execution.php - * - * @param GetExecutionRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Execution - * - * @throws ApiException Thrown if the API call fails. - */ - public function getExecution(GetExecutionRequest $request, array $callOptions = []): Execution - { - return $this->startApiCall('GetExecution', $request, $callOptions)->wait(); - } - - /** - * Lists Evaluations in a given project and location. - * - * The async variant is {@see WorkloadManagerClient::listEvaluationsAsync()} . - * - * @example samples/V1/WorkloadManagerClient/list_evaluations.php - * - * @param ListEvaluationsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listEvaluations(ListEvaluationsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListEvaluations', $request, $callOptions); - } - - /** - * Lists the result of a single evaluation. - * - * The async variant is {@see WorkloadManagerClient::listExecutionResultsAsync()} . - * - * @example samples/V1/WorkloadManagerClient/list_execution_results.php - * - * @param ListExecutionResultsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listExecutionResults(ListExecutionResultsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListExecutionResults', $request, $callOptions); - } - - /** - * Lists Executions in a given project and location. - * - * The async variant is {@see WorkloadManagerClient::listExecutionsAsync()} . - * - * @example samples/V1/WorkloadManagerClient/list_executions.php - * - * @param ListExecutionsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listExecutions(ListExecutionsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListExecutions', $request, $callOptions); - } - - /** - * Lists rules in a given project. - * - * The async variant is {@see WorkloadManagerClient::listRulesAsync()} . - * - * @example samples/V1/WorkloadManagerClient/list_rules.php - * - * @param ListRulesRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 ListRulesResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listRules(ListRulesRequest $request, array $callOptions = []): ListRulesResponse - { - return $this->startApiCall('ListRules', $request, $callOptions)->wait(); - } - - /** - * List all scanned resources for a single Execution. - * - * The async variant is {@see WorkloadManagerClient::listScannedResourcesAsync()} . - * - * @example samples/V1/WorkloadManagerClient/list_scanned_resources.php - * - * @param ListScannedResourcesRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listScannedResources(ListScannedResourcesRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListScannedResources', $request, $callOptions); - } - - /** - * Creates a new Execution in a given project and location. - * - * The async variant is {@see WorkloadManagerClient::runEvaluationAsync()} . - * - * @example samples/V1/WorkloadManagerClient/run_evaluation.php - * - * @param RunEvaluationRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function runEvaluation(RunEvaluationRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('RunEvaluation', $request, $callOptions)->wait(); - } - - /** - * Updates the parameters of a single Evaluation. - * - * The async variant is {@see WorkloadManagerClient::updateEvaluationAsync()} . - * - * @example samples/V1/WorkloadManagerClient/update_evaluation.php - * - * @param UpdateEvaluationRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 OperationResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function updateEvaluation(UpdateEvaluationRequest $request, array $callOptions = []): OperationResponse - { - return $this->startApiCall('UpdateEvaluation', $request, $callOptions)->wait(); - } - - /** - * Gets information about a location. - * - * The async variant is {@see WorkloadManagerClient::getLocationAsync()} . - * - * @example samples/V1/WorkloadManagerClient/get_location.php - * - * @param GetLocationRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 Location - * - * @throws ApiException Thrown if the API call fails. - */ - public function getLocation(GetLocationRequest $request, array $callOptions = []): Location - { - return $this->startApiCall('GetLocation', $request, $callOptions)->wait(); - } - - /** - * Lists information about the supported locations for this service. - * This method can be called in two ways: - * - * * **List all public locations:** Use the path `GET /v1/locations`. - * * **List project-visible locations:** Use the path - * `GET /v1/projects/{project_id}/locations`. This may include public - * locations as well as private or other locations specifically visible - * to the project. - * - * The async variant is {@see WorkloadManagerClient::listLocationsAsync()} . - * - * @example samples/V1/WorkloadManagerClient/list_locations.php - * - * @param ListLocationsRequest $request A request to house fields associated with the call. - * @param array $callOptions { - * 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 PagedListResponse - * - * @throws ApiException Thrown if the API call fails. - */ - public function listLocations(ListLocationsRequest $request, array $callOptions = []): PagedListResponse - { - return $this->startApiCall('ListLocations', $request, $callOptions); - } -} diff --git a/owl-bot-staging/WorkloadManager/v1/src/V1/gapic_metadata.json b/owl-bot-staging/WorkloadManager/v1/src/V1/gapic_metadata.json deleted file mode 100644 index 528f5cd3ba5c..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/src/V1/gapic_metadata.json +++ /dev/null @@ -1,88 +0,0 @@ -{ - "schema": "1.0", - "comment": "This file maps proto services\/RPCs to the corresponding library clients\/methods", - "language": "php", - "protoPackage": "google.cloud.workloadmanager.v1", - "libraryPackage": "Google\\Cloud\\WorkloadManager\\V1", - "services": { - "WorkloadManager": { - "clients": { - "grpc": { - "libraryClient": "WorkloadManagerGapicClient", - "rpcs": { - "CreateEvaluation": { - "methods": [ - "createEvaluation" - ] - }, - "DeleteEvaluation": { - "methods": [ - "deleteEvaluation" - ] - }, - "DeleteExecution": { - "methods": [ - "deleteExecution" - ] - }, - "GetEvaluation": { - "methods": [ - "getEvaluation" - ] - }, - "GetExecution": { - "methods": [ - "getExecution" - ] - }, - "ListEvaluations": { - "methods": [ - "listEvaluations" - ] - }, - "ListExecutionResults": { - "methods": [ - "listExecutionResults" - ] - }, - "ListExecutions": { - "methods": [ - "listExecutions" - ] - }, - "ListRules": { - "methods": [ - "listRules" - ] - }, - "ListScannedResources": { - "methods": [ - "listScannedResources" - ] - }, - "RunEvaluation": { - "methods": [ - "runEvaluation" - ] - }, - "UpdateEvaluation": { - "methods": [ - "updateEvaluation" - ] - }, - "GetLocation": { - "methods": [ - "getLocation" - ] - }, - "ListLocations": { - "methods": [ - "listLocations" - ] - } - } - } - } - } - } -} \ No newline at end of file diff --git a/owl-bot-staging/WorkloadManager/v1/src/V1/resources/workload_manager_client_config.json b/owl-bot-staging/WorkloadManager/v1/src/V1/resources/workload_manager_client_config.json deleted file mode 100644 index dd44e952f80f..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/src/V1/resources/workload_manager_client_config.json +++ /dev/null @@ -1,114 +0,0 @@ -{ - "interfaces": { - "google.cloud.workloadmanager.v1.WorkloadManager": { - "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": { - "CreateEvaluation": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "DeleteEvaluation": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "DeleteExecution": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "GetEvaluation": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "GetExecution": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListEvaluations": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListExecutionResults": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListExecutions": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListRules": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "ListScannedResources": { - "timeout_millis": 60000, - "retry_codes_name": "retry_policy_1_codes", - "retry_params_name": "retry_policy_1_params" - }, - "RunEvaluation": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_1_params" - }, - "UpdateEvaluation": { - "timeout_millis": 60000, - "retry_codes_name": "no_retry_1_codes", - "retry_params_name": "no_retry_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/WorkloadManager/v1/src/V1/resources/workload_manager_descriptor_config.php b/owl-bot-staging/WorkloadManager/v1/src/V1/resources/workload_manager_descriptor_config.php deleted file mode 100644 index e7df68739353..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/src/V1/resources/workload_manager_descriptor_config.php +++ /dev/null @@ -1,280 +0,0 @@ - [ - 'google.cloud.workloadmanager.v1.WorkloadManager' => [ - 'CreateEvaluation' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\WorkloadManager\V1\Evaluation', - 'metadataReturnType' => '\Google\Cloud\WorkloadManager\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'DeleteEvaluation' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\WorkloadManager\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'DeleteExecution' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Protobuf\GPBEmpty', - 'metadataReturnType' => '\Google\Cloud\WorkloadManager\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'RunEvaluation' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\WorkloadManager\V1\Execution', - 'metadataReturnType' => '\Google\Cloud\WorkloadManager\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'UpdateEvaluation' => [ - 'longRunning' => [ - 'operationReturnType' => '\Google\Cloud\WorkloadManager\V1\Evaluation', - 'metadataReturnType' => '\Google\Cloud\WorkloadManager\V1\OperationMetadata', - 'initialPollDelayMillis' => '500', - 'pollDelayMultiplier' => '1.5', - 'maxPollDelayMillis' => '5000', - 'totalPollTimeoutMillis' => '300000', - ], - 'callType' => \Google\ApiCore\Call::LONGRUNNING_CALL, - 'headerParams' => [ - [ - 'keyName' => 'evaluation.name', - 'fieldAccessors' => [ - 'getEvaluation', - 'getName', - ], - ], - ], - ], - 'GetEvaluation' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\WorkloadManager\V1\Evaluation', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'GetExecution' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\WorkloadManager\V1\Execution', - 'headerParams' => [ - [ - 'keyName' => 'name', - 'fieldAccessors' => [ - 'getName', - ], - ], - ], - ], - 'ListEvaluations' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getEvaluations', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\WorkloadManager\V1\ListEvaluationsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListExecutionResults' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getExecutionResults', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\WorkloadManager\V1\ListExecutionResultsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListExecutions' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getExecutions', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\WorkloadManager\V1\ListExecutionsResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListRules' => [ - 'callType' => \Google\ApiCore\Call::UNARY_CALL, - 'responseType' => 'Google\Cloud\WorkloadManager\V1\ListRulesResponse', - 'headerParams' => [ - [ - 'keyName' => 'parent', - 'fieldAccessors' => [ - 'getParent', - ], - ], - ], - ], - 'ListScannedResources' => [ - 'pageStreaming' => [ - 'requestPageTokenGetMethod' => 'getPageToken', - 'requestPageTokenSetMethod' => 'setPageToken', - 'requestPageSizeGetMethod' => 'getPageSize', - 'requestPageSizeSetMethod' => 'setPageSize', - 'responsePageTokenGetMethod' => 'getNextPageToken', - 'resourcesGetMethod' => 'getScannedResources', - ], - 'callType' => \Google\ApiCore\Call::PAGINATED_CALL, - 'responseType' => 'Google\Cloud\WorkloadManager\V1\ListScannedResourcesResponse', - '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' => [ - 'cryptoKey' => 'projects/{project}/locations/{location}/keyRings/{key_ring}/cryptoKeys/{crypto_key}', - 'evaluation' => 'projects/{project}/locations/{location}/evaluations/{evaluation}', - 'execution' => 'projects/{project}/locations/{location}/evaluations/{evaluation}/executions/{execution}', - 'location' => 'projects/{project}/locations/{location}', - ], - ], - ], -]; diff --git a/owl-bot-staging/WorkloadManager/v1/src/V1/resources/workload_manager_rest_client_config.php b/owl-bot-staging/WorkloadManager/v1/src/V1/resources/workload_manager_rest_client_config.php deleted file mode 100644 index 5977c87e8787..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/src/V1/resources/workload_manager_rest_client_config.php +++ /dev/null @@ -1,242 +0,0 @@ - [ - '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.cloud.workloadmanager.v1.WorkloadManager' => [ - 'CreateEvaluation' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/evaluations', - 'body' => 'evaluation', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - 'queryParams' => [ - 'evaluation_id', - ], - ], - 'DeleteEvaluation' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/evaluations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'DeleteExecution' => [ - 'method' => 'delete', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/evaluations/*/executions/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetEvaluation' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/evaluations/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'GetExecution' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/evaluations/*/executions/*}', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'ListEvaluations' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/evaluations', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListExecutionResults' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/evaluations/*/executions/*}/results', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListExecutions' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/evaluations/*}/executions', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListRules' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*}/rules', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'ListScannedResources' => [ - 'method' => 'get', - 'uriTemplate' => '/v1/{parent=projects/*/locations/*/evaluations/*/executions/*}/scannedResources', - 'placeholders' => [ - 'parent' => [ - 'getters' => [ - 'getParent', - ], - ], - ], - ], - 'RunEvaluation' => [ - 'method' => 'post', - 'uriTemplate' => '/v1/{name=projects/*/locations/*/evaluations/*}/executions:run', - 'body' => '*', - 'placeholders' => [ - 'name' => [ - 'getters' => [ - 'getName', - ], - ], - ], - ], - 'UpdateEvaluation' => [ - 'method' => 'patch', - 'uriTemplate' => '/v1/{evaluation.name=projects/*/locations/*/evaluations/*}', - 'body' => 'evaluation', - 'placeholders' => [ - 'evaluation.name' => [ - 'getters' => [ - 'getEvaluation', - 'getName', - ], - ], - ], - 'queryParams' => [ - 'update_mask', - ], - ], - ], - '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/WorkloadManager/v1/tests/Unit/V1/Client/WorkloadManagerClientTest.php b/owl-bot-staging/WorkloadManager/v1/tests/Unit/V1/Client/WorkloadManagerClientTest.php deleted file mode 100644 index 6c81198d74ae..000000000000 --- a/owl-bot-staging/WorkloadManager/v1/tests/Unit/V1/Client/WorkloadManagerClientTest.php +++ /dev/null @@ -1,1444 +0,0 @@ -getMockBuilder(CredentialsWrapper::class)->disableOriginalConstructor()->getMock(); - } - - /** @return WorkloadManagerClient */ - private function createClient(array $options = []) - { - $options += [ - 'credentials' => $this->createCredentials(), - ]; - return new WorkloadManagerClient($options); - } - - /** @test */ - public function createEvaluationTest() - { - $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/createEvaluationTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $description = 'description-1724546052'; - $schedule = 'schedule-697920873'; - $customRulesBucket = 'customRulesBucket2000095296'; - $kmsKey = 'kmsKey-591635343'; - $expectedResponse = new Evaluation(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $expectedResponse->setSchedule($schedule); - $expectedResponse->setCustomRulesBucket($customRulesBucket); - $expectedResponse->setKmsKey($kmsKey); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createEvaluationTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $evaluationId = 'evaluationId-257994498'; - $evaluation = new Evaluation(); - $request = (new CreateEvaluationRequest()) - ->setParent($formattedParent) - ->setEvaluationId($evaluationId) - ->setEvaluation($evaluation); - $response = $gapicClient->createEvaluation($request); - $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.workloadmanager.v1.WorkloadManager/CreateEvaluation', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getEvaluationId(); - $this->assertProtobufEquals($evaluationId, $actualValue); - $actualValue = $actualApiRequestObject->getEvaluation(); - $this->assertProtobufEquals($evaluation, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createEvaluationTest'); - $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 createEvaluationExceptionTest() - { - $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/createEvaluationTest'); - $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]'); - $evaluationId = 'evaluationId-257994498'; - $evaluation = new Evaluation(); - $request = (new CreateEvaluationRequest()) - ->setParent($formattedParent) - ->setEvaluationId($evaluationId) - ->setEvaluation($evaluation); - $response = $gapicClient->createEvaluation($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createEvaluationTest'); - 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 deleteEvaluationTest() - { - $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/deleteEvaluationTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteEvaluationTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->evaluationName('[PROJECT]', '[LOCATION]', '[EVALUATION]'); - $request = (new DeleteEvaluationRequest()) - ->setName($formattedName); - $response = $gapicClient->deleteEvaluation($request); - $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.workloadmanager.v1.WorkloadManager/DeleteEvaluation', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteEvaluationTest'); - $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 deleteEvaluationExceptionTest() - { - $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/deleteEvaluationTest'); - $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->evaluationName('[PROJECT]', '[LOCATION]', '[EVALUATION]'); - $request = (new DeleteEvaluationRequest()) - ->setName($formattedName); - $response = $gapicClient->deleteEvaluation($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteEvaluationTest'); - 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 deleteExecutionTest() - { - $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/deleteExecutionTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $expectedResponse = new GPBEmpty(); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/deleteExecutionTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->executionName('[PROJECT]', '[LOCATION]', '[EVALUATION]', '[EXECUTION]'); - $request = (new DeleteExecutionRequest()) - ->setName($formattedName); - $response = $gapicClient->deleteExecution($request); - $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.workloadmanager.v1.WorkloadManager/DeleteExecution', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteExecutionTest'); - $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 deleteExecutionExceptionTest() - { - $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/deleteExecutionTest'); - $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->executionName('[PROJECT]', '[LOCATION]', '[EVALUATION]', '[EXECUTION]'); - $request = (new DeleteExecutionRequest()) - ->setName($formattedName); - $response = $gapicClient->deleteExecution($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/deleteExecutionTest'); - 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 getEvaluationTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $description = 'description-1724546052'; - $schedule = 'schedule-697920873'; - $customRulesBucket = 'customRulesBucket2000095296'; - $kmsKey = 'kmsKey-591635343'; - $expectedResponse = new Evaluation(); - $expectedResponse->setName($name2); - $expectedResponse->setDescription($description); - $expectedResponse->setSchedule($schedule); - $expectedResponse->setCustomRulesBucket($customRulesBucket); - $expectedResponse->setKmsKey($kmsKey); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->evaluationName('[PROJECT]', '[LOCATION]', '[EVALUATION]'); - $request = (new GetEvaluationRequest()) - ->setName($formattedName); - $response = $gapicClient->getEvaluation($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.workloadmanager.v1.WorkloadManager/GetEvaluation', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getEvaluationExceptionTest() - { - $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->evaluationName('[PROJECT]', '[LOCATION]', '[EVALUATION]'); - $request = (new GetEvaluationRequest()) - ->setName($formattedName); - try { - $gapicClient->getEvaluation($request); - // 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 getExecutionTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $name2 = 'name2-1052831874'; - $evaluationId = 'evaluationId-257994498'; - $expectedResponse = new Execution(); - $expectedResponse->setName($name2); - $expectedResponse->setEvaluationId($evaluationId); - $transport->addResponse($expectedResponse); - // Mock request - $formattedName = $gapicClient->executionName('[PROJECT]', '[LOCATION]', '[EVALUATION]', '[EXECUTION]'); - $request = (new GetExecutionRequest()) - ->setName($formattedName); - $response = $gapicClient->getExecution($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.workloadmanager.v1.WorkloadManager/GetExecution', $actualFuncCall); - $actualValue = $actualRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function getExecutionExceptionTest() - { - $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->executionName('[PROJECT]', '[LOCATION]', '[EVALUATION]', '[EXECUTION]'); - $request = (new GetExecutionRequest()) - ->setName($formattedName); - try { - $gapicClient->getExecution($request); - // 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 listEvaluationsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $evaluationsElement = new Evaluation(); - $evaluations = [ - $evaluationsElement, - ]; - $expectedResponse = new ListEvaluationsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setEvaluations($evaluations); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $request = (new ListEvaluationsRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listEvaluations($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getEvaluations()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.workloadmanager.v1.WorkloadManager/ListEvaluations', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listEvaluationsExceptionTest() - { - $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]'); - $request = (new ListEvaluationsRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listEvaluations($request); - // 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 listExecutionResultsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $executionResultsElement = new ExecutionResult(); - $executionResults = [ - $executionResultsElement, - ]; - $expectedResponse = new ListExecutionResultsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setExecutionResults($executionResults); - $transport->addResponse($expectedResponse); - // Mock request - $parent = 'parent-995424086'; - $request = (new ListExecutionResultsRequest()) - ->setParent($parent); - $response = $gapicClient->listExecutionResults($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getExecutionResults()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.workloadmanager.v1.WorkloadManager/ListExecutionResults', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($parent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listExecutionResultsExceptionTest() - { - $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 - $parent = 'parent-995424086'; - $request = (new ListExecutionResultsRequest()) - ->setParent($parent); - try { - $gapicClient->listExecutionResults($request); - // 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 listExecutionsTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $executionsElement = new Execution(); - $executions = [ - $executionsElement, - ]; - $expectedResponse = new ListExecutionsResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setExecutions($executions); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->evaluationName('[PROJECT]', '[LOCATION]', '[EVALUATION]'); - $request = (new ListExecutionsRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listExecutions($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getExecutions()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.workloadmanager.v1.WorkloadManager/ListExecutions', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listExecutionsExceptionTest() - { - $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->evaluationName('[PROJECT]', '[LOCATION]', '[EVALUATION]'); - $request = (new ListExecutionsRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listExecutions($request); - // 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 listRulesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $expectedResponse = new ListRulesResponse(); - $transport->addResponse($expectedResponse); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $request = (new ListRulesRequest()) - ->setParent($formattedParent); - $response = $gapicClient->listRules($request); - $this->assertEquals($expectedResponse, $response); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.workloadmanager.v1.WorkloadManager/ListRules', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listRulesExceptionTest() - { - $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]'); - $request = (new ListRulesRequest()) - ->setParent($formattedParent); - try { - $gapicClient->listRules($request); - // 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 listScannedResourcesTest() - { - $transport = $this->createTransport(); - $gapicClient = $this->createClient([ - 'transport' => $transport, - ]); - $this->assertTrue($transport->isExhausted()); - // Mock response - $nextPageToken = ''; - $scannedResourcesElement = new ScannedResource(); - $scannedResources = [ - $scannedResourcesElement, - ]; - $expectedResponse = new ListScannedResourcesResponse(); - $expectedResponse->setNextPageToken($nextPageToken); - $expectedResponse->setScannedResources($scannedResources); - $transport->addResponse($expectedResponse); - // Mock request - $parent = 'parent-995424086'; - $request = (new ListScannedResourcesRequest()) - ->setParent($parent); - $response = $gapicClient->listScannedResources($request); - $this->assertEquals($expectedResponse, $response->getPage()->getResponseObject()); - $resources = iterator_to_array($response->iterateAllElements()); - $this->assertSame(1, count($resources)); - $this->assertEquals($expectedResponse->getScannedResources()[0], $resources[0]); - $actualRequests = $transport->popReceivedCalls(); - $this->assertSame(1, count($actualRequests)); - $actualFuncCall = $actualRequests[0]->getFuncCall(); - $actualRequestObject = $actualRequests[0]->getRequestObject(); - $this->assertSame('/google.cloud.workloadmanager.v1.WorkloadManager/ListScannedResources', $actualFuncCall); - $actualValue = $actualRequestObject->getParent(); - $this->assertProtobufEquals($parent, $actualValue); - $this->assertTrue($transport->isExhausted()); - } - - /** @test */ - public function listScannedResourcesExceptionTest() - { - $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 - $parent = 'parent-995424086'; - $request = (new ListScannedResourcesRequest()) - ->setParent($parent); - try { - $gapicClient->listScannedResources($request); - // 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 runEvaluationTest() - { - $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/runEvaluationTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name2 = 'name2-1052831874'; - $evaluationId = 'evaluationId-257994498'; - $expectedResponse = new Execution(); - $expectedResponse->setName($name2); - $expectedResponse->setEvaluationId($evaluationId); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/runEvaluationTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedName = $gapicClient->evaluationName('[PROJECT]', '[LOCATION]', '[EVALUATION]'); - $executionId = 'executionId-1217171550'; - $execution = new Execution(); - $request = (new RunEvaluationRequest()) - ->setName($formattedName) - ->setExecutionId($executionId) - ->setExecution($execution); - $response = $gapicClient->runEvaluation($request); - $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.workloadmanager.v1.WorkloadManager/RunEvaluation', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getName(); - $this->assertProtobufEquals($formattedName, $actualValue); - $actualValue = $actualApiRequestObject->getExecutionId(); - $this->assertProtobufEquals($executionId, $actualValue); - $actualValue = $actualApiRequestObject->getExecution(); - $this->assertProtobufEquals($execution, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/runEvaluationTest'); - $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 runEvaluationExceptionTest() - { - $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/runEvaluationTest'); - $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->evaluationName('[PROJECT]', '[LOCATION]', '[EVALUATION]'); - $executionId = 'executionId-1217171550'; - $execution = new Execution(); - $request = (new RunEvaluationRequest()) - ->setName($formattedName) - ->setExecutionId($executionId) - ->setExecution($execution); - $response = $gapicClient->runEvaluation($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/runEvaluationTest'); - 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 updateEvaluationTest() - { - $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/updateEvaluationTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $description = 'description-1724546052'; - $schedule = 'schedule-697920873'; - $customRulesBucket = 'customRulesBucket2000095296'; - $kmsKey = 'kmsKey-591635343'; - $expectedResponse = new Evaluation(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $expectedResponse->setSchedule($schedule); - $expectedResponse->setCustomRulesBucket($customRulesBucket); - $expectedResponse->setKmsKey($kmsKey); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/updateEvaluationTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $updateMask = new FieldMask(); - $evaluation = new Evaluation(); - $request = (new UpdateEvaluationRequest()) - ->setUpdateMask($updateMask) - ->setEvaluation($evaluation); - $response = $gapicClient->updateEvaluation($request); - $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.workloadmanager.v1.WorkloadManager/UpdateEvaluation', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getUpdateMask(); - $this->assertProtobufEquals($updateMask, $actualValue); - $actualValue = $actualApiRequestObject->getEvaluation(); - $this->assertProtobufEquals($evaluation, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateEvaluationTest'); - $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 updateEvaluationExceptionTest() - { - $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/updateEvaluationTest'); - $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(); - $evaluation = new Evaluation(); - $request = (new UpdateEvaluationRequest()) - ->setUpdateMask($updateMask) - ->setEvaluation($evaluation); - $response = $gapicClient->updateEvaluation($request); - $this->assertFalse($response->isDone()); - $this->assertNull($response->getResult()); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/updateEvaluationTest'); - 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); - $request = new GetLocationRequest(); - $response = $gapicClient->getLocation($request); - $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); - $request = new GetLocationRequest(); - try { - $gapicClient->getLocation($request); - // 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); - $request = new ListLocationsRequest(); - $response = $gapicClient->listLocations($request); - $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); - $request = new ListLocationsRequest(); - try { - $gapicClient->listLocations($request); - // 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 createEvaluationAsyncTest() - { - $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/createEvaluationTest'); - $incompleteOperation->setDone(false); - $transport->addResponse($incompleteOperation); - $name = 'name3373707'; - $description = 'description-1724546052'; - $schedule = 'schedule-697920873'; - $customRulesBucket = 'customRulesBucket2000095296'; - $kmsKey = 'kmsKey-591635343'; - $expectedResponse = new Evaluation(); - $expectedResponse->setName($name); - $expectedResponse->setDescription($description); - $expectedResponse->setSchedule($schedule); - $expectedResponse->setCustomRulesBucket($customRulesBucket); - $expectedResponse->setKmsKey($kmsKey); - $anyResponse = new Any(); - $anyResponse->setValue($expectedResponse->serializeToString()); - $completeOperation = new Operation(); - $completeOperation->setName('operations/createEvaluationTest'); - $completeOperation->setDone(true); - $completeOperation->setResponse($anyResponse); - $operationsTransport->addResponse($completeOperation); - // Mock request - $formattedParent = $gapicClient->locationName('[PROJECT]', '[LOCATION]'); - $evaluationId = 'evaluationId-257994498'; - $evaluation = new Evaluation(); - $request = (new CreateEvaluationRequest()) - ->setParent($formattedParent) - ->setEvaluationId($evaluationId) - ->setEvaluation($evaluation); - $response = $gapicClient->createEvaluationAsync($request)->wait(); - $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.workloadmanager.v1.WorkloadManager/CreateEvaluation', $actualApiFuncCall); - $actualValue = $actualApiRequestObject->getParent(); - $this->assertProtobufEquals($formattedParent, $actualValue); - $actualValue = $actualApiRequestObject->getEvaluationId(); - $this->assertProtobufEquals($evaluationId, $actualValue); - $actualValue = $actualApiRequestObject->getEvaluation(); - $this->assertProtobufEquals($evaluation, $actualValue); - $expectedOperationsRequestObject = new GetOperationRequest(); - $expectedOperationsRequestObject->setName('operations/createEvaluationTest'); - $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()); - } -}